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

@dhcw/sr-tokens

v0.4.0

Published

DHCW Single Record Design System — design tokens. Outputs CSS custom properties, SCSS variables, and XAML ResourceDictionary from the canonical JSON token source.

Readme

@dhcw/sr-tokens

Design tokens for the DHCW Single Record Design System.

Transforms the canonical JSON token source (/foundations/tokens/) into consumable formats for all supported frameworks.

Note: the generated build/ directory is committed to the repo. The source of truth is still /foundations/tokens/ — build/ is the compiled output. It is tracked (rather than gitignored) so the outputs are visible without running a build, consumers using the workspace get the files immediately, and the Storybook/Pages deploy is reproducible. Re-run npm run build:tokens from the repo root after any change to the source tokens, then commit the regenerated build/.

Outputs

| File | Format | Target | |---|---|---| | build/css/tokens.css | CSS custom properties (:root) | HTML/CSS, Blazor, React, .NET 4.8 legacy | | build/css/tokens-dark.css | CSS custom properties ([data-theme="dark"]) | Dark mode — all web targets | | build/css/typography.css | Responsive .sr-type-* utility classes (mobile-first; desktop scale at ≥1024px) | HTML/CSS, Blazor, React — type scale (composites can't be single CSS vars). See DDR-011 | | build/scss/_tokens.scss | SCSS variables | Build-time consumption where Sass is used | | build/scss/_tokens-dark.scss | SCSS variables (dark) | Build-time dark mode | | build/xaml/Tokens.xaml | XAML ResourceDictionary | .NET MAUI | | build/xaml/Tokens.Dark.xaml | XAML ResourceDictionary (dark) | .NET MAUI dark mode | | build/json/tokens-flat.json | Flat key→value JSON | Tooling, CI, linting |

Usage

Build

cd packages/tokens
npm install
npm run build

Consume in HTML / CSS / Blazor / .NET 4.8

Copy or link build/css/tokens.css into your project:

<link rel="stylesheet" href="tokens.css">

Then reference tokens as CSS custom properties:

.button-primary {
  background-color: var(--sr-color-interactive-primary);
  color: var(--sr-color-text-inverse);
}

For dark mode, include tokens-dark.css and toggle data-theme="dark" on the root element.

Consume in .NET MAUI

Add build/xaml/Tokens.xaml to your ResourceDictionary:

<Application.Resources>
    <ResourceDictionary>
        <ResourceDictionary.MergedDictionaries>
            <ResourceDictionary Source="Tokens.xaml" />
        </ResourceDictionary.MergedDictionaries>
    </ResourceDictionary>
</Application.Resources>

Then reference tokens:

<Button BackgroundColor="{StaticResource SrColorInteractivePrimary}"
        TextColor="{StaticResource SrColorTextInverse}" />

Consume in SCSS

@use 'path/to/tokens' as sr;

.button-primary {
  background-color: sr.$sr-color-interactive-primary;
}

Token architecture

Global (Tier 1)          → Semantic (Tier 2)           → Component (Tier 3)
/primitives/color.json      /semantic/color.json           (future — per-component)
/primitives/spacing.json    /semantic/spacing.json
/primitives/typography.json /semantic/typography.json

Components reference semantic tokens only. Semantic tokens resolve to primitives. This allows theme switching (light/dark) by swapping the semantic layer.