ni / nimble

The NI Nimble Design System
https://nimble.ni.dev
MIT License
32 stars 8 forks source link

Create theme-unaware high-level tokens #2282

Open rajsite opened 3 months ago

rajsite commented 3 months ago

🙋 Feature Request

😯 Problem to Solve

We currently have:

We should consider having:

Use-cases:

💁 Proposed Solution

Partially described above but we need to determine:

📋 Tasks

jattasNI commented 3 months ago

https://github.com/ni/nimble/pull/2305/files/2699ec4760c024a1d150cea9b3df50c01992c46c revealed some of the challenges in doing this:

  1. we need hierarchy in base tokens to avoid duplicating hex values and to provide clarity about which tokens are atomic color values and which are mapping to component parts / variants
  2. we need a naming scheme that incorporates the many subtle parts / variants / themes / token types
  3. we want a way to simplify the theme-aware token creation so that it doesn't require a single file importing hundreds of base tokens and manually mapping them