Skip to content

Design System ​

A compact desktop interface shared by Doctor, Deploy and generated apps. Shared components live in @ossiframe/ui (packages/ui); module pages live in each module's ui/ folder.

Rules ​

  • Layout: resizable left sidebar (server selector, quick switcher, grouped pages, theme menu), a page header with server, connection state and actions, then the page. Pages sharing a section form one sidebar entry with tabs.
  • Dense tables and key-value panels, 4 px spacing scale, system font, monospace for commands, paths, host keys and output.
  • Light and dark themes from shared tokens; the default follows the OS.
  • Status uses icon plus label, never color alone. Text meets WCAG AA contrast (see below).
  • Distinct states: loading, empty, disconnected, unavailable, failed, stale (with age).
  • Never show success before the result is verified. On failure show the real exit code and a stderr excerpt.
  • Mutations show the plan before approval. Destructive actions sit in a separate danger zone and need typed confirmation.
  • Render remote output as text, never HTML.
  • Keyboard navigation and visible focus throughout. Transitions stay at or under 120 ms and respect reduced motion.
  • Do not copy Ploi or Forge layouts, names, icons or assets.

Stack ​

React 19, TypeScript, Tailwind CSS 4 (a dev dependency of each app, through @tailwindcss/vite), Radix dialog and dropdown menu primitives, lucide-react icons, class-variance-authority, clsx and tailwind-merge. All but Tailwind live in packages/ui; apps use icons re-exported from @ossiframe/ui. There is no shadcn/ui, Storybook or chart library. @xterm/xterm is a dependency of the app that includes ssh-terminal (Deploy).

Tokens ​

Defined in packages/ui/src/theme.css on :root and [data-theme="dark"], mapped to Tailwind colors (bg-surface, text-fg-muted, border-border).

TokenLightDarkUse
surface#ffffff#101012Page background
sidebar#f7f7f8#151518Sidebar background
raised#ffffff#1a1a1eMenus, dialogs
hover#f0f0f2#222227Hover and selected rows
border#e5e5e8#28282dDividers
border-strong#d4d4d9#36363dInputs, buttons
fg#18181b#ececf0Primary text
fg-muted#5c5c66#a3a3adSecondary text
fg-faint#6c6c76#8a8a94Hints, metadata
accent / accent-fg#4f5bd5 / #ffffff#8b93f2 / #101012Primary action
ok, warn, danger, info#1a7f37, #9a6700, #c62828, #0b63ce#3fb950, #d29922, #f26d6a, #5ea8ffStatus
focus#4f5bd5#8b93f2Focus ring

Type scale (Tailwind text-*): label 12 px, body 13 px (base), section 14 px, title 18 px, heading 20 px, metric 24 px. Radii: sm 4 px, md 6 px. cn() registers these sizes with tailwind-merge so they survive next to text-<color> classes.

The theme setting (System, Light, Dark) is stored in localStorage as ossiframe.theme and applied as data-theme on <html>; the dark: variant follows it.

Contrast ​

WCAG 2 contrast ratios of the token pairs above. AA needs 4.5:1 for body text.

PairLightDark
fg on surface17.7216.13
fg on hover15.5713.44
fg-muted on surface6.617.60
fg-muted on sidebar6.177.29
fg-faint on surface5.195.56
fg-faint on sidebar4.855.33
accent-fg on accent5.546.84
accent on surface5.546.84
ok on surface5.087.48
warn on surface4.877.53
danger on surface5.626.49
info on surface5.697.71

Known gap: border-strong on surface is 1.48 (light) and 1.59 (dark), below the 3:1 that WCAG 1.4.11 suggests for control boundaries. Inputs are identified by labels and placeholders; raising the border contrast is a follow-up.

Components (@ossiframe/ui) ​

  • Primitives: Button, IconButton, Input, Select, Textarea, Checkbox, Field, Badge, Kbd, Shortcut, Mono, Code, Skeleton.
  • Layout: PageHeader, Section, Toolbar, Tabs, DataTable (keyboard rows, selectedKey), KeyValue, Metric, StatTile, IconChip, Meter, Panel, MetricChart (optional area fill and current value), ResizeHandle and useResizable.
  • Status: Status, StatusBadge, StateBadge, SeverityBadge, Notice.
  • States: LoadingState, EmptyState, DisconnectedState, UnavailableState, ErrorState.
  • Dialogs and menus: Dialog, ConfirmDialog, ConfirmRemoveDialog, HostKeyDialog, HostKeyChangedDialog, CredentialDialog, Menu and its items.
  • Operations: OperationHeader, StepList, StepOutput, VerificationTable (passed, warning, failed, skipped, unknown), ApprovalLayout (ordered disclosure sections, collapsed technical details).
  • Shell: ServerWorkspace (props title, pages, welcome, onConnected, children), ServerForm, useWorkspaceNav and PageLink, and AssistProvider and AssistButton for the optional AI panel.

Module pages declare ModuleUi with optional group, section, icon and offline. offline: true keeps a page reachable while disconnected, for pages that show stored data or recovery guidance (provisioning Operation and History, Applications, Doctor Reports).

The component gallery opens at #gallery in development builds only.

Status colour, bars and tiles ​

  • Meter is a usage bar (role="meter"): accent below 75%, warning from 75%, danger from 90% (levelOf in @ossiframe/ui); filesystems use 85% and 95%. The value is also written as text.
  • StatTile is an icon chip, label, large value, optional sub-line and optional Meter, for a page's headline numbers. Panel is a bordered block for a group or chart.
  • Checkbox is drawn with tokens (.oss-checkbox in theme.css), identical in light and dark. Give its cell the same vertical padding as text cells to align it with the first line.
  • Monitoring opens with a health summary from assess (modules/linux-monitoring/ui/health.ts): CPU and memory warn at 75%, critical at 90%; swap warns at 50%; filesystems warn at 85%, critical at 95%. Missing values are reported as not checked, never guessed.
  • The terminal uses a 16-colour palette for light and dark, read from data-theme.

Keyboard ​

KeysAction
⌘K / Ctrl+KQuick switcher (servers and pages); arrows and Enter to choose
⌘\ / Ctrl+\Show or hide the sidebar
Arrow Up/Down, Home, EndMove through sidebar entries
Arrow Left/Right, Home, EndMove between tabs
Enter or SpaceOpen the focused table row
Arrow Left/Right, Home, End on a resize handleResize the sidebar or the AI panel
EscClose dialogs and menus

Global shortcuts are ignored while typing in inputs or the terminal.

Sidebar order follows pages in each app's src/modules.ts. Apps set grouping, titles and icon overrides.

  • Deploy:
    • Overview
    • Applications (shown while disconnected; a list, then per application the tabs Overview, Deploy, Repository, Releases, Environment, Settings)
    • Provisioning (tabs Software, Preflight, Plan, Operation, History; Operation and History stay reachable while disconnected)
    • Monitoring, Logs, Files, Tunnels, Terminal, Assistant
  • Doctor:
    • Overview (the combined inventory and assessment page)
    • Audit group: Diagnostics, Security, Network, Services, Software, Reports (Reports stays reachable while disconnected)
    • Monitoring, Logs, Assistant
    • No "apply fix" actions.
  • Generated apps: one entry per page of each selected module, except pages another module replaces (replaces).

Released under the MIT License.