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

@needless-ui/tokens

v0.6.3

Published

Design tokens for Needless UI in W3C DTCG format, compiled to CSS custom properties.

Readme

@needless-ui/tokens

Design tokens for Needless UI, written in the W3C Design Tokens format (DTCG 2025.10) and compiled to CSS custom properties.

Use

@import '@needless-ui/tokens/tokens.css';

.card {
  padding: var(--nui-space-4);
  border-radius: var(--nui-radius-lg);
  background: var(--nui-color-bg-subtle);
  color: var(--nui-color-text-default);
}
  • dist/tokens.css: custom properties with light and dark modes.
  • dist/tokens.json: every token resolved per mode, for docs and tooling.
  • src/**/*.tokens.json: the DTCG sources, for your own design token pipeline.

Modes

Light values apply by default, dark values when the OS prefers dark. Pin a mode on any element, and nest them freely:

<html data-nui-theme="dark">
  <aside data-nui-theme="light">…</aside>
</html>

Color scales

Each palette (neutral, accent, danger, success, warning) has 12 steps with fixed roles: 1–2 backgrounds, 3–5 element states, 6–8 borders, 9–10 solid fills, 11–12 text. The scales are generated by scripts/palette.ts, which fits every color into sRGB and checks the WCAG 2.2 contrast of each text/background pair before writing the files.

Components use the semantic aliases (--nui-color-accent-solid, --nui-color-bg-canvas, …), so overriding one alias restyles every component that uses it.

Springs

Motion tokens are springs. Each --nui-spring-* is a DTCG transition with its physics in $extensions["com.needlessui.spring"]:

"bouncy": {
  "$value": { "duration": { "value": 490, "unit": "ms" }, "delay": { "value": 0, "unit": "ms" }, "timingFunction": [0.62, 2.35, 0.21, 0.69] },
  "$extensions": { "com.needlessui.spring": { "stiffness": 300, "damping": 14, "mass": 1 } }
}

The $value is the closest cubic-bezier, for other DTCG tools. This package's compiler solves the spring instead and emits its settling time and exact curve: --nui-spring-bouncy: 889ms linear(0, 0.009 0.9%, …, 1). Use one in any transition, transition: transform var(--nui-spring-bouncy), or point --nui-motion at it to change how every component moves. Springs, like durations, collapse to 0.01ms under prefers-reduced-motion.

--nui-radius-scale and --nui-density multiply every component radius and every control size. The data-nui-* presets in @needless-ui/css set all three for a subtree.

Browser support

Colors are oklch() (Chrome and Edge 111, Firefox 113, Safari 15.4 and later); springs are linear() easings (Chrome and Edge 113, Firefox 112, Safari 17.2), and transitions that use one don't run in older browsers. The components need a little more; see the browser support guide.

License

MIT