Skip to content

Styling & Themes

Components accept an appearance prop — a JSON configuration object that controls colors, fonts, spacing, and other visual properties. The same tokens work identically in both React and Vue.

Prebuilt themes

Three prebuilt themes are included:

// Default - pill-shaped inputs, bold borders
<AddressEntry appearance={{ theme: 'default' }} />
// Minimal - square corners, subtle borders, compact
<AddressEntry appearance={{ theme: 'minimal' }} />
// Rounded - large radii, soft shadows, spacious
<AddressEntry appearance={{ theme: 'rounded' }} />

Overriding design tokens

Use variables to override individual tokens on top of a theme:

<AddressEntry
appearance={{
theme: 'minimal',
variables: {
colorPrimary: '#003366',
colorPrimaryHover: '#002244',
fontFamily: '"Inter", sans-serif',
borderRadius: '12px',
},
}}
/>

Available tokens

Colors

TokenDescription
colorPrimaryButton background, focus ring, active states
colorPrimaryHoverButton hover background
colorPrimaryTextText on primary background
colorBackgroundComponent background
colorTextPrimary text color
colorTextSecondaryPlaceholders, hints
colorBorderInput border
colorBorderFocusInput border on focus
colorErrorError text and borders
colorFocusRingFocus ring shadow (rgba recommended)
colorErrorFocusRingError focus ring
colorSuggestionHoverDropdown hover background
colorDividerDivider between suggestions
colorTextTertiaryAttribution text and logo color

Typography

TokenDescription
fontFamilyFont stack for all text
fontSizeBase font size
fontSizeSmallLabels, hints, errors
fontWeightNormalBody text and option labels
fontWeightMediumButton and label weight
fontSizeAttribution”Powered by Opendoor” text size

Spacing

TokenDescription
spacingStandard padding
spacingTightCompact spacing (icon gaps)
spacingWideSection margins, form field margins

Shape

TokenDescription
borderRadiusPill-shaped elements (input, buttons)
borderRadiusInnerDropdown, form inputs
borderWidthInput border width

Shadows

TokenDescription
shadowFocusFocus ring box-shadow
shadowDropdownSuggestion dropdown shadow

Sizing

TokenDescription
inputMinHeightInput wrapper minimum height
buttonHeightSubmit button height
buttonPaddingXButton horizontal padding

Card Selection

These tokens control selectable card components (radio cards, checkbox cards, image cards) used in DtcOnboardingFlow:

TokenDefaultDescription
colorCardBackground#ffffffBackground for selectable cards
colorCardBorder#e5e7ebBorder color for unselected cards
colorCardBorderSelected#235ca3Border color when a card is selected
colorCardBackgroundSelected#f0f5ffBackground when a card is selected

Need more control?

If the tokens don’t cover what you need, you can build your own components using client-js-core directly. See the Custom UI guide.