Skip to content

v3.4.0

Latest

Choose a tag to compare

@jasonrundell jasonrundell released this 26 Feb 19:28
0fd7310

What's Changed

🚀 Enhancements

  • Refactored design tokens to DTCG Format Module 2025.10 specification #126 (@brainandbytejason)
    • Token file (common.tokens.json) now uses $type at group level and $value for all token values
    • Colors converted to structured objects with colorSpace, components, and hex
    • Font families converted to arrays per DTCG fontFamily type
    • Added fontFamilyToCss() utility for CSS output
    • All 10 consuming components updated to $value access patterns

🧪 Testing

  • Added Vitest test framework with 59 unit tests covering DTCG structure validation, fontFamilyToCss utility, and token access patterns

🏗️ Build

  • Fixed tsconfig.app.json to support JSON imports under composite: true mode
  • Resolved yaml@2 dependency for vitest/vite compatibility

🔩 Dependency Updates

⚠️ Breaking Changes

Token access patterns have changed. If you consume tokens directly:

Category Before (v3.3.x) After (v3.4.0)
Color Tokens.colors.primary.value Tokens.colors.primary.$value.hex
Dimension Tokens.sizes.xsmall.value Tokens.sizes.xsmall.$value.value
Dim. unit Tokens.sizes.xsmall.unit Tokens.sizes.xsmall.$value.unit
Font family Tokens.fonts.body.family Tokens.fonts.body.$value (array)

Full Changelog: v3.3.1...v3.4.0