# Terminal A dark command bar for showing CLI commands, plus a light token row and inline CLI references for prose. This is `terminal.css` in `@layer components`. The terminal sits on a **fixed dark surface in both light and dark mode**. It reads the `--terminal-*` slots, not the theme surfaces, so it stays dark when the rest of the page is light. This is intentional: a command bar should look like a terminal regardless of the page theme. (Contrast bare `
`, which uses `--bg-inverse` and flips with the theme.) ## The command bar ```html> elements install @elements/style``` Parts: | Class | Role | |---|---| | `.terminal` | The dark bar | | `.terminal > .prompt` | The dim, non-selectable prompt glyph | | `.terminal > .cmd` | The command text: selectable, scrolls horizontally if long | | `.terminal > .copy` | A dark copy button | **Copy is your JavaScript.** Add `is-copied` to the copy button to flip it into the confirmed state: it hides the `.default` span and shows the `.done` span (green). The class toggles the look; wiring the clipboard and toggling the class is your code. ## Caption `.caption` is a sans-serif label to sit above a terminal block: ```htmlInstall the design system:
…``` ## Token row `.token-row` is a light-surface variant for showing a labeled value with a copy button (an API key, a license token): ```htmlLicense token lic_xxxxxxxx``` | Class | Role | |---|---| | `.token-row` | Bordered soft-background row | | `.token-row > .key` | The mono label | | `.token-row > .val` | The mono value (truncates if long) | ## Inline CLI references For CLI mentions inside prose: - `.path`: an inline file path chip, e.g. `app/pages/home/template.html`. - `.cli`: an inline command with a `.prompt` glyph and a `.cmd`. ```htmlEdit app/pages/home/template.html and run >elements start.
```