DES-374: Add lotus-audit-web skill (customer-facing web only)#7
Merged
Conversation
Mirrors the lotus-audit-ios architecture for JustPark's customer-facing
web surfaces. Same single Figma source of truth, same four-stage pipeline
(parallel extract → parallel analyse → optional sub-agents → assembly),
same gitignored repo-relative output with optional vault mirror via
LOTUS_AUDIT_MIRROR.
Customer-facing scope (per JustPark Jargon):
- frontend/web — main consumer SSR SPA (primary B2C)
- frontend/pay — Quick Pay, no-login payment flow
- justpark/resources/views/{mobile,site,bookings,listings,referrals,
auth,static,npp} — legacy PHP/Blade still serving consumer pages
- justpark/public/assets/scss/{app,site} — legacy SCSS asset pipeline
Explicitly excluded (operator/internal):
- Luna (host portal), Solar (internal ops), Terra (business accounts),
Enforcement, B2B components, browser-extension (internal dev tool),
qr utility, admin/call centre/dashboard Blade views, email templates
(different audit), justpark-ui itself (definitions, not consumers)
Storyblok-hosted pages (marketing landing, brand partner themes) are
out of scope for a code-based audit but flagged in the report. Notably:
Storyblok ALLOWS Lotus token overrides at runtime via the
CSS-custom-property surface exposed in _colors.scss — that's the
designed partner-theming mechanism. The audit's Scope section calls
this out as a future token-architecture question.
Files:
- .claude/skills/lotus-audit-web/SKILL.md — procedure + stage diagram
- .claude/skills/lotus-audit-web/apps.yaml — scan-target manifest
- .claude/skills/lotus-audit-web/scripts/
- fetch-figma-tokens.mjs — copy of iOS skill's fetcher (single Figma)
- parse-web-tokens.mjs — NEW: parses _colorPrimitives + _colors
(with CSS-var override-surface detection)
+ _spacing + _radius into structured JSON
- colour-parity.mjs — NEW: Figma semantic ↔ web _colors.scss
tokens, normalised name matching
- scan-web.mjs — NEW: per-app, per-file counter for .tsx /
.scss / .css / .blade.php; compliant /
legacy / hardcoded patterns
- token-candidates.mjs — NEW: web-flavoured candidate finder, with
CSS-context px detection + JSX inline
style detection
- build-report.mjs — NEW: assembles markdown report; per-app
rollup, mermaid pie + bar charts, full
Storyblok callout, Recommendations section
Smoke-test against the live repos (frontend HEAD + justpark HEAD, Lotus
Figma file focused): 1,210 files scanned across customer-facing apps,
13% top-line compliance, 14,329 hardcoded violations dominated by
5,299+ raw `Npx` SCSS values and 633+ hardcoded font-size declarations.
The latter confirms the known gap: web Lotus has no typography tokens.
Top findings the audit surfaces:
- `10px` × 997 and `20px` × 712 uses across web — both already exist on
iOS (spacingSemiSmall, spacingXMedium) but not in Figma's Padding
collection. Cross-platform divergence to resolve.
- 51 Figma semantic colour tokens have no web equivalent (mostly the
expanded Tertiary / Tapped / Link-* layer Figma added without web
catching up — same gap iOS has).
- Web radius scale is a perfect match with Figma (vs iOS's broken
radiusFull=32).
- Web is sRGB throughout — no P3 conversion needed.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
🚨 gitStream Monthly Automation Limit Reached 🚨 Your organization has exceeded the number of pull requests allowed for automation with gitStream. To continue automating your PR workflows and unlock additional features, please contact LinearB. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Jira: DES-374 — Lotus Design System (Epic)
Summary
Mirrors
lotus-audit-iosfor JustPark's customer-facing web surfaces. Same single Figma source of truth, same four-stage pipeline (parallel extract → parallel analyse → optional sub-agents → assembly), same gitignored repo-relative output with optional vault mirror.Customer-facing scope (per [[JustPark Jargon]])
frontend/web— main consumer SSR SPA (primary B2C)frontend/pay— Quick Pay, no-login payment flowjustpark/resources/views/{mobile,site,bookings,listings,referrals,auth,static,npp}— legacy PHP/Blade still serving consumer pagesjustpark/public/assets/scss/{app,site}— legacy SCSS asset pipelineExplicitly out of scope (deferred / different audit)
lotus-audit-web-portals.justpark-uiitself — it defines tokens, doesn't consume them.Storyblok callout (in the report)
Storyblok-hosted marketing pages + brand partner themes (NCP, O2) can't be scanned via code. Notably: Storyblok intentionally allows Lotus token overrides at runtime via the CSS-custom-property surface exposed in
_colors.scss— that's the designed partner-theming mechanism. The report's Scope section flags this as a future token-architecture question (which CSS variables are public override surface vs. internal).Architecture
Smoke-test (live repos + Figma)
Full pipeline ran end-to-end against
frontendHEAD +justparkHEAD with the Lotus Figma file focused. 353-line report, key headlines:NpxSCSS values and 633+ hardcodedfont-size:declarationsFindings already surfaced
10px× 997 and20px× 712 uses across web — both already exist on iOS (spacingSemiSmall,spacingXMedium) but not in Figma's Padding collection. Same cross-platform gap iOS already surfaced for 10pt.Tertiary/Tapped/Link-*semantic layer — same gap iOS has).radiusFull=32).Test plan
parse-web-tokens.mjsparses 26 primitives + 22 semantic + 9 spacing + 7 radius from@justpark/ui/src/scss/lotus/.colour-parity.mjscorrectly identifies match / mismatch / missing-web / web-only.scan-web.mjscorrectly counts compliant + legacy + hardcoded across .tsx + .scss + .blade.php in customer-facing apps.token-candidates.mjssurfaces10px× 997 as a "new-candidate" relative to existing Figma + web tokens.build-report.mjsassembles all sections, mermaid diagrams, Storyblok callout, recommendations./lotus-audit-web.Followups
lotus-audit-web-portals) — Luna + Solar + Terra + Enforcement.resources/views/emails/(343 files) needs its own scanner with inline-CSS-aware rules.🤖 Generated with Claude Code