Skip to content

docs(audit): pre-freeze API audit for v0.3.0 - #96

Closed
kiro-agent[bot] wants to merge 4 commits into
mainfrom
audit/api-freeze-v0.3.0-b
Closed

docs(audit): pre-freeze API audit for v0.3.0#96
kiro-agent[bot] wants to merge 4 commits into
mainfrom
audit/api-freeze-v0.3.0-b

Conversation

@kiro-agent

@kiro-agent kiro-agent Bot commented May 25, 2026

Copy link
Copy Markdown

This pull request was created by @kiro-agent on behalf of @jackgranatowski 👻

Comment with /kiro fix to address specific feedback or /kiro all to address everything.
Learn about Kiro autonomous agent


Summary

Full public API audit of SLASHED v0.3.0 before the token-API freeze. The audit reads every source file (core/*.css, active optional/*.css, all docs/*.md, demo.html, build config, scripts) and checks 25 items across 7 categories.

Key findings

🔴 Breaking (must fix before freeze)

  • A-1 .sf-frame--4-3 renders 3:2 (token --sf-ratio-photo = 3/2); .sf-frame--3-2 hardcodes same value. Class name is misleading — two classes produce identical output.
  • G-1 PUBLIC/INTERNAL contract in tokens.css header covers only ~30% of 608 tokens. Without precise boundary, SemVer freeze is unenforceable.

🟠 API hygiene (10 issues)

  • Stale fallback values (--sf-header-height 3.5rem vs declared 8rem)
  • Hardcoded z-index/opacity/border-width that have token equivalents
  • Asymmetric modifier scales across layout primitives (undocumented)
  • .sf-icon--boxed excluded from coverage, absent from demo
  • 3 macro classes undocumented in docs/macros.md
  • Docs referencing wrong file locations (layout.md, states.md)
  • Undeclared scoped flag tokens (--sf-is-active/current/pressed/open)
  • Deprecated tokens not listed centrally

✅ Solid

Layers, bundle topology, alias chains, naming prefix, keyframes, !important discipline, palette/theme-example consistency, tokens.md generation pipeline.

What was tested

  • Token declaration ↔ usage cross-check (grep-based)
  • Class coverage vs demo.html (Python script matching test logic)
  • Layer assignment vs bundle.config.json
  • package.json exports vs dist/ contents
  • Docs class mentions vs CSS definitions

Files changed

  • audits/audit-a.md (new, 309 lines)

Full audit of public API surface covering:
- Token declaration vs usage consistency
- Naming conventions and scale uniformity
- Class coverage and documentation sync
- Cascade layer correctness
- Bundle integrity
- Documentation freshness
- API freeze contract completeness

Findings: 2 breaking (A-1, G-1), 10 hygiene issues.

Co-authored-by: Jack Granatowski <contact@codeslash.net>
@jackgranatowski
jackgranatowski marked this pull request as draft May 26, 2026 07:57
…ove dead audit refs

- Add --sf-animation-spin, --sf-animation-shimmer presets
- Add --sf-state-pending-opacity: 0.7
- Add --sf-ratio-4-3, --sf-ratio-3-2; deprecate --sf-ratio-photo
- Add brand hover tokens (primary, secondary, tertiary, action, neutral)
- Fix --sf-animation-blink to use calc(1s * var(--sf-motion-scale))
- Add @Property registrations: --sf-is-active, --sf-is-current,
  --sf-is-pressed, --sf-is-open
- Update header comment: alias chain now describes 3 hops
- Replace audit section D9 refs in tokens.css, motion.css
- Remove dead audit reference in print.css
- Add --sf-alternate-gap, --sf-alternate-inner-gap to tokens.layout.css
- Update token-api snapshot with 16 new tokens
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants