@gracefullight/krds-tokens
v1.0.1
Published
Design tokens for KRDS design system
Readme
@gracefullight/krds-tokens
Design tokens for the KRDS design system.
Installation
Install the package via pnpm, npm or yarn:
pnpm add @gracefullight/krds-tokens
# or
npm install @gracefullight/krds-tokens
# or
yarn add @gracefullight/krds-tokensUsage
Import the helper functions or raw tokens in your TypeScript or JavaScript project.
// Import helper functions
import { getTypography, getColor, getPalette, getRadius, getShadow, BREAKPOINTS } from "@gracefullight/krds-tokens";
// Get a typography style by key
const headingStyle = getTypography("pc.heading.large");
// Get a color value
const textBasic = getPalette("text.basic");
// Access raw token object (if needed)
import { TOKENS } from "@gracefullight/krds-tokens";Scripts
pnpm build- Build the package with tsuppnpm dev- Run tsup in watch mode
Contributing
- Fork the repository
- Install dependencies:
pnpm install - Run generators or update tokens
- Build:
pnpm build - Submit a pull request following conventional commits
License
MIT
