Bumps version from 0.3.0 to 0.4.0. All changes since 0.3.0:
Bug Fixes
- Missing design files fail gracefully instead of throwing a stack trace. Reading a non-existent or unreadable file now outputs a clean error message and structured JSON with exit code 2. (#123, #145, @rmyndharis, @Emp1500) Fixes #132.
- Successful exports always return exit code 0. Export command exit codes are now decoupled from source document linter warnings or errors, ensuring valid serialized builds pass pipeline gates. (#126, #152, @rmyndharis, @arpitjain099)
- Tailwind CSS exports end with exactly one trailing newline. Serializing to
css-tailwindno longer appends an extra empty line that caused strict repository formatting checks to fail. (#151, #140, #144, @sudarshandev-llm, @drmikecrypto, @Jalendar10) Fixes #139. - Reading from an interactive terminal prints a usage hint. When running a command with
-as the input path from a TTY, the CLI printsReading from stdin... Press Ctrl+D when doneto prevent silent freezing. (#146, @Emp1500) - Gradian angle units in colors parse correctly. Angles like
100gradnow correctly take precedence over radian matching, producing accurate color computations and contrast metrics. (#120, @rmyndharis) - CSS
color-mix()requires explicit percentage weight values. Bare numbers are now rejected instead of producing inaccurate color blends. (#120, @rmyndharis) - Line terminators in font family names are escaped in Tailwind v4 exports. (#122, @rmyndharis)
- Specification documentation resolves reliably from bundled CLI installations. The CLI command
npx @google/design.md specno longer throws errors when executed from npm installations. (#118, #157, @rmyndharis, @SyedaQurratAI) - Primitive types render correctly directly from specification configuration. (#131, @juliosuas)
- Bounded token validation performance on adversarial inputs. Cap dimension string parsing lengths, limit recursion depth in nested colors, and optimize string distance checks to prevent CPU spikes or call stack errors on malformed documents. (#121, @rmyndharis)
Features
- Optional
omittedfrontmatter key suppresses linter warnings. Design authors can explicitly list skipped categories (likespacingorrounded) as bare strings or structured objects with reasons, silencing expected-missing linter warnings. (#155, #113, #147, @zachshallbetter, @mvanhorn, @sudarshandev-llm) Fixes #78. - CSS custom properties export format. Serializes design system tokens directly into standard CSS variables within a
:rootselector using--format css-vars, with optional naming prefix support via--prefix. (#109, @mvanhorn) - Typography sub-property linting. The linter now reports warnings for unrecognized or misspelled property fields inside typography token mappings. (#125, @rmyndharis)
- Token name collision detection. The linter detects and reports naming collisions occurring between flattened dot-notation keys and nested YAML groups. (#150, @Arshgill01)
- Data-driven type definitions in specification. Specification documentation dynamically generated from primitive configuration schemas. (#117, @Emp1500) Fixes #97.
Docs
- Updated README to match runtime linter JSON output fields (
infosvsinfo) and align the active rules count to eleven. (#119, @rmyndharis) - Declared supported Node runtime compatibility requirement (
"engines": { "node": ">=18.0.0" }) in package metadata. (#124, @rmyndharis)
Contributors
Thank you to the contributors who made this release possible:
- @rmyndharis (#118, #119, #120, #121, #122, #123, #124, #125, #126)
- @Emp1500 (#117, #145, #146)
- @mvanhorn (#109, #113, #155)
- @sudarshandev-llm (#147, #151, #155)
- @zachshallbetter (#155)
- @juliosuas (#131)
- @Arshgill01 (#150)
- @arpitjain099 (#152)
- @SyedaQurratAI (#157)
- @drmikecrypto (#140)
- @Jalendar10 (#144)