Token Categories
Neo organizes design tokens into six main categories:Color Tokens
Contains all color definitions organized by purpose and context. Access via
theme.colors.brandfgOnBrand
fgPrimaryfgSecondary
bgPrimarybgSecondary
borderPrimary, borderSecondary, and borderTertiary are alpha-on-ink values (100% / 20% / 10% on black in light mode and white in dark mode). They blend with whatever surface sits behind them — verify appearance when drawing borders on non-default backgrounds.
borderPrimaryborderSecondaryborderTertiary
success/onSuccesswarning/onWarningdanger/onDanger
Button Color Tokens
Per-variant fills, foregrounds, and interaction colors for
NeoButton. Access via theme.buttonColors.primaryBg/primaryFg/primaryBgInteractionsecondaryTertiaryBgInteraction
Checkbox Color Tokens
Fill, border, and foreground tokens for
NeoCheckbox. Access via theme.checkboxColors.Spacing Tokens
Consistent spacing values for layouts and component padding.
extraSmallsmallmediumlargeextraLarge
Border Radius Tokens
Corner radius values that maintain visual consistency. Access via
theme.radii.extraSmallsmallmediumlargefull
Shadow Tokens
Elevation and depth definitions for components and overlays. Access via
theme.shadows.extraSmallsmallmedium
Typography Tokens
Complete type scale for clear information hierarchy.
header1header2header3header4body1body2labelbuttoncode
Duration Tokens
Animation durations for consistent timing and smooth interactions. Uses semantic values for flexible use across different components.
shortmediumlong
Using Design Tokens
Access design tokens through theneoCurrentThemeProvider:
Benefits
- Consistency: Ensures visual harmony across your application
- Maintainability: Update designs by changing token values, not individual components
- Scalability: Easy to maintain consistent design at any application size
- Flexibility: Switch between light/dark themes or completely different brand themes
- Developer Experience: Clear, semantic names make code more readable

