Extends scripts/audit-css.mjs to also report hardcoded hex colors
outside CSS custom-property defs (`--name: #xxx;`) and outside
`var(--token, #fallback)` token-default fallbacks (which are explicitly
allowed per repo design-system rules).
Initial run reports 4 violations — all intentional pre-cascade body
defaults in :root and html.dark that must be literal hex (no var()) so
the page renders correct colors before the cascade resolves the custom
props. Annotated each with an explanatory comment; values intentionally
mirror --foreground / --background. Future drift surfaces immediately.
UI audit doc §5 #10 updated to reflect the sweep is done and the 4 known
violations are documented.
Generated with [Devin](https://cli.devin.ai/docs)
Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Adds web/scripts/audit-css.mjs — surfaces classes that appear in many
rules (likely targets of style drift) and per-class !important counts
(specificity-fight indicators). Implements the script suggested by
docs/ui/UI_AUDIT.md §5 #7 / Pattern G.
Run: pnpm --filter @bytelyst/trading-web run audit:css
(or: cd web && npm run audit:css)
Initial run on src/index.css + src/App.css + src/layout-fixes.css
exposes the top hotspots:
- .positions-tab 22 rules, 26 !important
- .trade-plans-page 20 rules, 25 !important
- .history-tab 17 rules, 22 !important
- .trading-sidebar-logo 9 rules, 20 !important
These are the targets for the future Pattern G consolidation pass.
The script supports --threshold N and --json for tooling.
Generated with [Devin](https://cli.devin.ai/docs)
Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>