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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@adam-milo/tokens

v1.0.1

Published

Design tokens for the Adam Milo Design System

Readme

@adam-milo/tokens

Design tokens for the Adam Milo Design System (Smart V2).

Installation

npm install @adam-milo/tokens

Usage

JavaScript/TypeScript

import { colors, spacing, fontSize } from '@adam-milo/tokens';
// Or import everything
import tokens from '@adam-milo/tokens';

console.log(colors.action); // '#272643'
console.log(spacing[4]); // '1rem'
console.log(fontSize['title-8']); // ['1rem', { lineHeight: '1.2', fontWeight: '700' }]

CSS Variables

Import the CSS file to use design tokens as CSS custom properties:

/* In your main CSS file */
@import '@adam-milo/tokens/tokens.css';

/* Now you can use the tokens */
.my-component {
  color: var(--color-text);
  padding: var(--spacing-4);
  font-size: var(--font-size-8);
  border-radius: var(--radius-md);
}

Or in your HTML:

<link rel="stylesheet" href="node_modules/@adam-milo/tokens/dist/tokens.css" />

Or import in JavaScript (for bundlers like Vite/Webpack):

import '@adam-milo/tokens/tokens.css';

Selective Imports

import { colors } from '@adam-milo/tokens/colors';
import { spacing } from '@adam-milo/tokens/spacing';
import { fontSize } from '@adam-milo/tokens/typography';

Tokens

Colors

  • Main Colors: text, action, clickable, popup, error, toggle, secondary, card
  • Greys: bg, bgSecondary, border, iconSecondary, systemText, grey-07
  • Legacy Colors: primary, secondary, neutral, success, danger (with 50-950 shades)
  • Gradients: primary gradient

CSS Variables:

  • --color-text, --color-action, --color-clickable, etc.

Spacing

Spacing scale from 0 to 16 (0, 0.5, 1, 1.5, 2, 2.5, 3, 3.5, 4, 5, 6, 7, 8, 10, 11, 12, 14, 16) All values in rem units.

CSS Variables:

  • --spacing-0-5, --spacing-1, --spacing-2, --spacing-4, etc.

Border Radius

Scale: sm, default, md, lg, xl, 2xl, 3xl, 4xl

CSS Variables:

  • --radius-sm, --radius-default, --radius-md, --radius-lg, etc.

Typography

  • Smart V2 Scale: title-1 through title-10, text-1 through text-10
  • Font Family: Almoni DL AAA
  • Legacy: h1, h2, h3, h4, body-lg, body, body-sm, caption

CSS Variables:

  • --font-size-1 through --font-size-10

TypeScript

Full TypeScript support with exported types:

import type { Colors, Spacing, FontSize } from '@adam-milo/tokens';

Formats

This package exports tokens in multiple formats:

  1. JavaScript/TypeScript - For programmatic use in React, Node.js, etc.
  2. CSS Custom Properties - For use in any CSS framework (React, Vue, Angular, vanilla)

Use Cases

React Components (JavaScript)

import { colors, spacing } from '@adam-milo/tokens';

const buttonStyles = {
  backgroundColor: colors.action,
  padding: spacing[4],
};

Vanilla CSS

@import '@adam-milo/tokens/tokens.css';

.button {
  background-color: var(--color-action);
  padding: var(--spacing-4);
}

Tailwind Configuration

import { colors, spacing } from '@adam-milo/tokens';

export default {
  theme: {
    extend: {
      colors,
      spacing,
    },
  },
};

License

MIT