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

@caioalfonso/kanso-styles

v1.0.1

Published

Optional stylesheet and design tokens for kanso-ui. Targets data-part / data-state only.

Readme

@caioalfonso/kanso-styles

The optional stylesheet and design tokens for kanso-ui. Entirely opt-in — the components work fully unstyled without it.

npm i @caioalfonso/kanso-styles
import '@caioalfonso/kanso-styles';           // tokens + base + every component

import '@caioalfonso/kanso-styles/tokens';    // or, piece by piece:
import '@caioalfonso/kanso-styles/base';      //   tokens and base are required,
import '@caioalfonso/kanso-styles/switch';    //   then one component at a time

tokens defines every custom property the component sheets read, and base carries the :focus-visible ring, the reduced-motion opt-out and the clipping that hides a form component's mirror input. A component sheet on its own gives you an unfocusable-looking control and a stray visible checkbox.

Theming

Every value is a CSS custom property under the --kanso- namespace, and every one is overridable. That is the whole theming API:

:root {
  --kanso-accent: oklch(55% 0.15 150);
  --kanso-radius: 6px;
}

The palette is deliberately neutral so it can be re-themed to anything. Light and dark both ship; dark applies on prefers-color-scheme unless you set data-theme yourself, and the library never writes data-theme — theme ownership stays with your app.

Contrast is measured, not assumed

Every colour pair in this package is converted OKLCh → sRGB → WCAG relative luminance and checked against its required ratio on every CI run. Text pairs must clear 4.5:1; anything that carries state — borders, focus rings, the switch thumb — must clear 3:1 per WCAG 2.2 SC 1.4.11.

Styling contract

The stylesheet only ever targets data-part, data-state, data-disabled and data-scope. There are no class names to depend on, which is also what makes your own CSS straightforward:

[data-scope='switch'] [data-part='thumb'][data-state='checked'] {
  /* your checked thumb */
}

Documentation

https://kansoui.caioalfonso.dev

MIT licensed.