Skip to content

Combobox theming ​

The values listed below are exposed as --rozie-combobox-* custom properties, each with a built-in fallback, so Combobox works with zero configuration and re-skins by remapping tokens. The structural rules compile per-leaf and are not consumer-overridable.

css
:root {
  --rozie-combobox-width: 16rem;
  --rozie-combobox-accent: #0066cc;
  --rozie-combobox-input-padding: 0.5rem 0.75rem;
  --rozie-combobox-focus-ring-width: 3px;
}

Tokens ​

layout / typography ​

TokenDefault
--rozie-combobox-width16rem
--rozie-combobox-fontinherit

accent — the single color most consumers will set; focus ring + selected option derive from it

TokenDefault
--rozie-combobox-accent#0066cc

input box model ​

TokenDefault
--rozie-combobox-input-padding0.5rem 0.75rem
--rozie-combobox-colorinherit
--rozie-combobox-bg#fff
--rozie-combobox-border-width1px
--rozie-combobox-border-colorrgba(0, 0, 0, 0.25)
--rozie-combobox-radius0.5rem

focus ring ​

TokenDefault
--rozie-combobox-focus-ring-width3px
--rozie-combobox-focus-ring-colorrgba(0, 102, 204, 0.25)

disabled ​

TokenDefault
--rozie-combobox-disabled-opacity0.55
--rozie-combobox-disabled-bgrgba(0, 0, 0, 0.04)
TokenDefault
--rozie-combobox-list-gap0.25rem
--rozie-combobox-list-padding0.25rem
--rozie-combobox-list-max-height16rem
--rozie-combobox-list-bg#fff
--rozie-combobox-list-border-colorrgba(0, 0, 0, 0.15)
--rozie-combobox-list-shadow0 10px 24px rgba(0, 0, 0, 0.16)

option ​

TokenDefault
--rozie-combobox-option-padding0.4rem 0.6rem
--rozie-combobox-option-radius0.375rem
--rozie-combobox-option-active-bgrgba(0, 102, 204, 0.12)
--rozie-combobox-option-selected-weight600
--rozie-combobox-option-disabled-opacity0.45
--rozie-combobox-option-colorinherit

group heading — the label rendered above a <optgroup>-style block of options when the options array is grouped

TokenDefault
--rozie-combobox-group-heading-colorrgba(0, 0, 0, 0.5)
--rozie-combobox-group-heading-letter-spacing0.03em
--rozie-combobox-group-heading-margin-top0
--rozie-combobox-group-heading-padding0.35rem 0.6rem 0.15rem
--rozie-combobox-group-heading-size0.75rem
--rozie-combobox-group-heading-transformuppercase
--rozie-combobox-group-heading-weight600

empty state — rendered when the filtered options list has zero entries ​

TokenDefault
--rozie-combobox-empty-colorrgba(0, 0, 0, 0.5)
--rozie-combobox-empty-padding0.5rem 0.6rem

overflow — the "+N more" affordance shown when the selection exceeds the visible chip count

TokenDefault
--rozie-combobox-more-colorrgba(0, 0, 0, 0.55)
--rozie-combobox-more-size0.875rem

creatable — the trailing "Create …" row shown when creatable is set and the typed query matches no option (see the Creatable section of the component docs). Reads as interactive; -color defaults through --rozie-combobox-accent (the same accent every selected/focused state already derives from) so it reads as an affordance, not a plain row; -bg is transparent by default, matching the "+N more" row's own chrome-free treatment.

TokenDefault
--rozie-combobox-create-bgtransparent

chip rail — the selected-value chips rendered inside the control, before the input, when multiple is set. Mirrors @rozie-ui/tags' own chip theme: --rozie-combobox-chip-size sets the chip's font-size (Tags' equivalent of chip-font-size), and the single --rozie-combobox-chip-remove-size token drives BOTH the width and the height of the round remove button, same as Tags.

TokenDefault
--rozie-combobox-chips-padding0.35rem 0.45rem 0 0.45rem
--rozie-combobox-chip-gap0.4rem
--rozie-combobox-chip-bgrgba(0, 102, 204, 0.12)
--rozie-combobox-chip-colorinherit
--rozie-combobox-chip-radius0.375rem
--rozie-combobox-chip-padding0.15rem 0.5rem
--rozie-combobox-chip-size0.85rem
--rozie-combobox-chip-remove-colorcurrentColor
--rozie-combobox-chip-remove-size1.1rem

inline chip layout — chipLayout="inline" (with multiple) puts the chips and the input on one wrapping row inside a single bordered field. --rozie-combobox-inline-padding pads that field, --rozie-combobox-inline-input-min-width is the narrowest the input gets before it wraps onto the next row, and --rozie-combobox-inline-input-padding pads the (borderless) input.

TokenDefault
--rozie-combobox-inline-padding0.3rem 0.45rem
--rozie-combobox-inline-input-min-width6rem
--rozie-combobox-inline-input-padding0.2rem 0.25rem

state-dependent — declared initial on purpose. The component reads this token with a DIFFERENT local fallback at each read site (resting input falls back through --rozie-combobox-border-color, the :focus rule falls back through --rozie-combobox-focus-border-color), so declaring a single frozen value here would collapse the focus-state transition. initial resets the custom property to the guaranteed-invalid value, which makes every var() substitute its OWN local fallback — exactly today's render output, but now discoverable and overridable.

TokenDefault
--rozie-combobox-input-underlineinitial

Defaulted where Combobox reads them ​

Public, but declared nowhere by base.css: the fallback below applies only while no scope sets the token, and it is resolved at the component itself — so it follows a value set on any ancestor (a token it defaults to included).

TokenDefault
--rozie-combobox-chip-remove-hover-colorvar(--rozie-combobox-accent, #0066cc)
--rozie-combobox-create-colorvar(--rozie-combobox-accent, #0066cc)
--rozie-combobox-focus-border-colorvar(--rozie-combobox-accent, #0066cc)
--rozie-combobox-option-selected-colorvar(--rozie-combobox-accent, #0066cc)

Design-system bridges ​

Each package ships token presets that map Combobox's tokens onto a known design system's published CSS variables — import base.css first, then a bridge:

ts
import '@rozie-ui/combobox-react/themes/base.css';
import '@rozie-ui/combobox-react/themes/bootstrap.css';
import '@rozie-ui/combobox-react/themes/material.css';
import '@rozie-ui/combobox-react/themes/shadcn.css';

See also ​

Pre-1.0 — APIs may change between minor versions.