发布

  • 0.3.0 2a19f5dd97

    feat: add token-like-ignored lint rule for silently dropped frontmatter keys (#105)

    frostbyte_neo 发布于 2026-06-15 20:27:02 +00:00 | 22 次提交 在此版本后已推送到 main

    Closes #100

    Add a new token-like-ignored lint rule that warns when a top-level YAML
    key is not part of the recognized export schema and its value looks like a
    design-token map (hex colors, CSS dimensions, or typography property names).
    These keys are silently dropped by design.md export, misleading users into
    thinking their color palette or type scale was exported.

    • Extend ParsedDesignSystem with rawValues so the parser carries all
      raw YAML values through to the model layer
    • Extend DesignSystemState with unknownKeyValues populated by ModelHandler
    • New rule token-like-ignored in linter/rules/token-like-ignored.ts
    • 10 tests covering hex color maps, font maps, dimension maps, flat scalars,
      non-token objects, nested maps, and multi-key scenarios
    • Register rule in DEFAULT_RULE_DESCRIPTORS and re-export from public API
    • Update hardcoded rule-count assertions in types.test.ts and spec.test.ts

    Co-authored-by: Matt Van Horn 455140+mvanhorn@users.noreply.github.com

    下载附件