data-theme attribute on the root element.
Color system
All colors are defined as CSS custom properties inglobals.css. The Tailwind preset maps Tailwind class names to these properties.
Accent colors
The primary brand color is electric blue (#4242fc), inspired by Gadget’s visual identity.
Tailwind classes:
Surface colors
Layered backgrounds for cards, modals, and overlays.
Tailwind classes:
Text colors
Semantic foreground colors for readability hierarchy.
Tailwind classes:
Border colors
Tailwind classes:
Semantic colors
Status indicators for success, error, warning states.
Tailwind classes:
Typography
Two font families are included: Inter for UI text and Inconsolata for code.Font families
Tailwind classes:
Font loading
Fonts are loaded via @fontsource when you import global styles:Border radius
Rounded corners use a 6px base with three modifiers.
Tailwind classes:
Shadows
Neo-skeuomorphic shadows with inset highlights and ambient shadows.
Example values (dark theme):
Theme switching
Toggle between dark and light modes by setting thedata-theme attribute on the root element (or any parent container).
Default theme
Dark mode is the default. No attribute is required:Switching themes
Setdata-theme="light" to activate light mode:
React example
Manage theme state and apply to a container:ThemeToggle.tsx
Persist theme preference
Store the theme in localStorage:useTheme.ts
App.tsx
Customizing tokens
Override CSS variables to customize the design system:custom.css
globals.css
Component variants
Many components use design tokens viaclass-variance-authority. For example, the Button component:
Button component (excerpt)
Next steps
Setup
Configure Tailwind and import global styles
Components
Browse available components and variants
