audiocnSolid

LCD Display

A dot-matrix screen for labelled readouts and settings, backlit in the light theme and glowing in the dark one, with dropdown values.

Model
Effort

Installation

$ pnpm dlx shadcn@latest add @audiocn-solid/lcd-display

Usage

import {
  LcdDisplay,
  LcdDisplayLabel,
  LcdDisplayRow,
  LcdDisplayValue,
} from "@/components/ui/lcd-display";
<LcdDisplay>
  <LcdDisplayRow>
    <LcdDisplayLabel>Tempo</LcdDisplayLabel>
    <LcdDisplayValue>128.0</LcdDisplayValue>
  </LcdDisplayRow>
</LcdDisplay>

The ink follows your theme's --primary. In light mode the display is backlit with dark pixels; in dark mode its ink glows on dark glass. Set appearance="light" or "dark" to keep one look across themes. Values briefly dim when their text changes.

Anatomy

<LcdDisplay>
  <LcdDisplayRow>
    <LcdDisplayLabel />
    <LcdDisplaySelect items={items} value={value} onValueChange={setValue}>
      <LcdDisplaySelectTrigger />
      <LcdDisplaySelectContent />
    </LcdDisplaySelect>
  </LcdDisplayRow>
  <LcdDisplaySeparator />
  <LcdDisplayStatus />
</LcdDisplay>

LcdDisplaySelect uses the local Kobalte Select, not Base UI. It accepts an items array of { value, label, disabled? } objects. Kobalte renders these options from items inside LcdDisplaySelectContent; there is no per-option JSX child API. A controlled value={null} leaves the selection empty. The select also supports defaultValue, onValueChange, and disabled.

The popup defaults to placement="bottom-end" and gutter={8}. Set placement or gutter on LcdDisplaySelect to adjust its position. Kobalte uses a combined placement value rather than Base UI's separate side, align, and offset props.

Examples

Inks

The primary variant follows --primary. Fixed variants are amber, green, cyan and red.

Primary128.0
Amber−12 dB
Green44.1 kHz
Cyan−3.0 dB
RedCLIP

Override the ink with [--lcd-display-ink:var(--chart-1)]. The glass, pixels and glow derive from that variable. The portalled popup copies the display's shared variables when it opens.

Dot-matrix font

The text is masked into dots by default. For a real dot-matrix face, use the docs-only Doto font and disable the mask with matrix={false}.

ModelOpus 5.5
EffortHigh

Theming

Variable or attributeMeaning
--lcd-display-inkDisplay colour, normally set by variant
--lcd-display-litLit pixels
--lcd-display-ink-dimLabels and separators
--lcd-display-ink-unlitUnlit dots
--lcd-display-glassScreen glass
--lcd-display-glowHalo around lit text
--lcd-display-bezel, --lcd-display-bezel-edgeBezel gradient
--lcd-display-fontDisplay font, defaults to var(--font-mono)
--lcd-display-pitchDot grid spacing, defaults to 2px
data-appearanceDisplay appearance and popup appearance
data-sizeDisplay size
data-variantDisplay ink variant and popup variant
data-matrixPresent while the dot mask is enabled
data-changedBriefly present after value or trigger text changes
data-stateStatus state: idle, busy or off

Accessibility

The display has role="group". Each select trigger is labelled by its row's LcdDisplayLabel, including custom label IDs. Set live on LcdDisplayValue to announce changes politely. The status pixel is hidden from assistive technology.

API reference

LcdDisplay

Prop

Type

LcdDisplayValue

Prop

Type

LcdDisplayStatus

Prop

Type

LcdDisplaySelectTrigger

placeholder is displayed when no option is selected. Children replace the selected value or placeholder text.

Prop

Type

LcdDisplaySelect

Prop

Type