npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@okja/chi-tokens

v0.5.2

Published

Chi Design System tokens - colors, typography, spacing, radius, shadow, motion

Downloads

1,085

Readme

@okja/chi-tokens

Low-level CSS design tokens for building themes. If you're building an application, use @okja/chi-themes instead.

This package provides the foundational design tokens consumed by @okja/chi-themes. It's useful if you're creating custom themes or need granular control over the design system.

Installation

npm install @okja/chi-tokens

Usage

@import '@okja/chi-tokens/tokens.css';
@import '@okja/chi-tokens/colors/grayscale.css';

Tokens are on :root and wrapped in @layer tokens.

Token Reference

Spacing

| Token | Value | |-------|-------| | --space-1 | 4px | | --space-2 | 8px | | --space-3 | 12px | | --space-4 | 16px | | --space-5 | 24px | | --space-6 | 32px | | --space-7 | 40px | | --space-8 | 48px | | --space-9 | 64px |

Typography

| Token | Value | |-------|-------| | --font-sans | system-ui, -apple-system, 'Segoe UI', sans-serif | | --font-serif | georgia, 'Times New Roman', serif | | --font-mono | 'SF Mono', monaco, 'Courier New', monospace | | --font-size-1 to --font-size-11 | 11px to 57px | | --font-weight-light/regular/medium/bold | 300/400/500/700 | | --line-height-1 to --line-height-11 | 16px to 64px |

Radius

| Token | Value | |-------|-------| | --radius-none | 0 | | --radius-xs | 4px | | --radius-sm | 8px | | --radius-md | 12px | | --radius-lg | 16px | | --radius-xl | 28px | | --radius-full | 9999px |

Shadow

| Token | Description | |-------|-------------| | --shadow-0 | none | | --shadow-1 | Subtle | | --shadow-2 | Low | | --shadow-3 | Medium | | --shadow-4 | High | | --shadow-5 | Highest |

Motion (M3 Expressive)

Spring Tokens (for JS animation libraries)

| Token | Damping | Stiffness | Use Case | |-------|---------|-----------|----------| | --spring-fast-spatial-* | 0.9 | 1400 | Small components (buttons, switches) | | --spring-default-spatial-* | 0.9 | 700 | Partial screen (sheets, drawers) | | --spring-slow-spatial-* | 0.9 | 300 | Full screen transitions | | --spring-fast-effects-* | 1.0 | 3800 | Small component color/opacity | | --spring-default-effects-* | 1.0 | 1600 | Partial screen effects | | --spring-slow-effects-* | 1.0 | 800 | Full screen effects |

Spatial springs allow overshoot (position, scale). Effects springs don't (color, opacity).

Duration Tokens (for CSS)

| Token | Value | |-------|-------| | --duration-instant | 0ms | | --duration-short1 to short4 | 50-200ms | | --duration-medium1 to medium4 | 250-400ms | | --duration-long1 to long4 | 450-600ms | | --duration-extra-long1 to extra-long4 | 700-1000ms |

Easing Tokens (for CSS)

| Token | Value | Use Case | |-------|-------|----------| | --easing-standard | cubic-bezier(0.2, 0, 0, 1) | Utility animations | | --easing-standard-accelerate | cubic-bezier(0.3, 0, 1, 1) | Exiting screen | | --easing-standard-decelerate | cubic-bezier(0, 0, 0, 1) | Entering screen | | --easing-emphasized | cubic-bezier(0.2, 0, 0, 1) | Expressive M3 animations | | --easing-emphasized-accelerate | cubic-bezier(0.3, 0, 0.8, 0.15) | Expressive exit | | --easing-emphasized-decelerate | cubic-bezier(0.05, 0.7, 0.1, 1) | Expressive enter |

Colors

| Token | Description | |-------|-------------| | --color-primary | Primary brand | | --color-on-primary | Text on primary | | --color-surface | Surface background | | --color-on-surface | Text on surface | | --color-error | Error states | | --color-outline | Borders |

Color Palettes

  • colors/grayscale.css - Neutral (default)
  • colors/blue.css - Corporate blue
  • colors/purple.css - Creative purple

Colors use light-dark() for automatic dark mode:

--color-surface: light-dark(oklch(99% 0.005 264deg), oklch(15% 0.005 264deg));

Architecture

  • CSS Cascade Layers - @layer tokens for clean cascade control
  • light-dark() function - Automatic dark mode colors
  • OKLCH color space - Perceptual uniformity
  • Scaling support - var(--scaling, 1) multiplier

Browser Support

Requires browsers supporting:

  • CSS light-dark() function
  • OKLCH color space
  • CSS Cascade Layers (@layer)

Supported: Chrome 123+, Safari 17.5+, Firefox 120+

License

MIT