refactor(docs): repair the illustration layer's token discipline - #263
Merged
Conversation
added 3 commits
July 10, 2026 20:23
The three inline-SVG illustration components carried a hardcoded #hex fallback on every design-token reference (var(--color-x, #hex)). Several had drifted stale — e.g. var(--color-bg-surface, #1c1916) when the token now resolves to #252525, and var(--color-border-default, #262320) vs the current #2e2e2e — so a missing token would have rendered the wrong colour. The FF token stylesheet (packages/ui/assets/css/index.css) is imported globally by the docs app, so these tokens are always defined and the hex fallbacks are dead backstops that can only drift. Removing them deletes 300+ hardcoded hex values and makes the stale-fallback class of bug impossible to reintroduce. Diagrams render identically.
The diagram components used the browser-default weights 600/500 instead of the Fluid Functionalism scale, whose medium/semibold map to 450/550 (packages/ui tokens). CSS declarations now reference var(--font-weight-medium|semibold); inline-SVG font-weight presentation attributes (which cannot parse var()) use the numeric FF weight 550. Existing FF weights (400/550/700) are unchanged. No visual redesign.
…kens The decorative node-in reveal in the three architecture illustrations is an FF choreo-tier entrance. Two already used var(--motion-choreo)/ var(--ease-spring) but re-declared a hardcoded 800ms / cubic-bezier fallback; AuthFlow used a fully raw 0.7s cubic-bezier(0.16,1,0.3,1). All three now consume var(--motion-choreo) var(--ease-spring) directly, removing the last raw duration+curve pair from the illustration layer. The long infinite pulse/dash loops (2-10s) have no motion-tier equivalent and are intentionally left untouched so the diagrams keep their exact timing.
Contributor
Author
Review — round 1Verdict: APPROVE Verified this is a pure token-correctness sweep, exactly as spec'd — no redesign, no security/logic surface touched. Blockingnone Improvementsnone Notes (verified, no action needed)
|
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.
What & why
Part of the Owlat next-layer UX plan (2026-07-10), workstream D — close the Fluid Functionalism gaps, implementing locked principle 4: one visual system — FF tokens only, zero hardcoded hex/duration/weight.
The
apps/docsillustration layer was the single biggest concentration of non-token values in the app. This is a token-correctness sweep, not a redesign — every diagram renders identically.Changes (three atomic commits)
AuthFlowIllustration,EmailPipelineIllustration,MtaArchitectureIllustration). Every token reference carried a hardcodedvar(--token, #hex)fallback and several had drifted stale — e.g.var(--color-bg-surface, #1c1916)when the token now resolves to#252525, andvar(--color-border-default, #262320)vs the current#2e2e2e. The FF token stylesheet (packages/ui/assets/css/index.css) is imported globally by the docs app, so these tokens are always defined and the hex fallbacks are dead backstops that can only drift stale. Removing them deletes 300+ hardcoded hex values and makes the stale-fallback class of bug impossible to reintroduce (refreshing the hex would just re-arm the same footgun).font-weight: 600/500→var(--font-weight-semibold|medium)(FF 550/450) in CSS; inline-SVGfont-weight="600"presentation attributes (which cannot parsevar()) → numeric550. Existing FF weights (400/550/700) unchanged.var(--motion-choreo) var(--ease-spring)directly — removing the last raw duration+curve pair (AuthFlow's0.7s cubic-bezier(0.16,1,0.3,1)) and the redundant800ms/cubic-bezierfallbacks.Acceptance criteria
var(--token, #fallback)hex fallbacks remain in the touched files (grep-guard: 0)cubic-bezier/ hardcoded animation duration in the entrance reveals (grep-guard: 0)Deliberately out of scope (preserve visuals)
flood-color="#000"(SVG drop-shadow primitive) andDomainFlow's#c45a5aerror-red used directly incolor/color-mix— tokenizing it would change the exact rendered colour.--motion-choreo= 800ms); routing them through a tier would drastically change speed, so they are left untouched.Preserved behavior
apps/docsdiagram components.Test notes
Primarily visual; enforced by grep-guard at review/CI. Verified locally: 0 stale hex fallbacks, 0 non-FF weights, 0 raw cubic-bezier in the touched files;
oxlintclean on both changed directories.Auto-merge pipeline: squash-merges on reviewer approval + green CI.