Skip to Content
Theming

Theming

grannyshot-ui uses semantic tokens for all colors, enabling seamless dark mode support.

Dark Mode

Dark mode is class-based. Add class="dark" to your <html> element:

<html class="dark"> ... </html>

No provider or wrapper component is needed. This is compatible with next-themes  or any manual toggle.

Semantic Tokens

All components use semantic color tokens that automatically adapt to the theme:

Background

TokenLightDark
bgwhitegray.950
bg.subtlegray.50gray.900
bg.mutedgray.100gray.800

Foreground

TokenLightDark
fggray.950gray.50
fg.mutedgray.500gray.300
fg.subtlegray.400gray.500

Accent (Emerald)

TokenLightDark
accentemerald.500emerald.500
accent.hoveremerald.600emerald.400
accent.fgwhitewhite

Status

TokenLightDark
successemerald.600emerald.400
warningamber.500amber.400
errorred.500red.400
infoblue.500blue.400

CSS Variable Prefix

All CSS variables use the --gs- prefix:

var(--gs-colors-accent) var(--gs-colors-fg) var(--gs-spacing-4)
Last updated on