Repository navigation
fix(website): Download Workflow label and white outline on the workflow page button - #21086
Conversation
|
Important Review skippedReview was skipped due to path filters ⛔ Files ignored due to path filters: 1
CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
🧩 Custom Nodes Ecosystem Matrix: 🟡 Withheld — could not measureExecutes the frontend JS of every registry pack that ships any, against this change, in both renderers. The eight This candidate changes nothing the matrix measures, so every expensive stage was skipped. Reproduce locally# build one shard's fixture, then run it
python3 scripts/registry-census/build_matrix.py --shard 1/4
MATRIX_RENDERER=vue MATRIX_VUE=1 \
npx vitest run --config vitest.matrix.config.mts
Full docs: scripts/registry-census/README.md 🌾 Fallow: ✅ PassedFallow audits the diff for duplication, complexity and dead code. It gates on new findings only, so when the audit completes, a red is something this PR introduced or moved — never inherited backlog. A red can also mean the audit itself did not finish; the details below say which happened. No new findings in the changed files. Reproduce locally# the base the gate compared against
npx fallow audit --root . --quiet --format json \
--changed-since de0f0e889ef2fa639a699f85da7fdc2c2830ccfb
Full docs: ADR-DEVEX-LINT-0015 🌐 Website E2ETip All tests passed.
🔗 Website PreviewWebsite Preview: https://comfy-website-preview-pr-21086.vercel.app Models is built and gated by PostHog (workshop-enabled), using staging Cloud. This commit: https://website-frontend-3c41v4sps-comfyui.vercel.app Last updated: 2026-10-15T11:06:12Z for |
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #21086 +/- ##
==========================================
- Coverage 86.44% 86.33% -0.12%
==========================================
Files 3703 3598 -105
Lines 176278 173040 -3238
Branches 48709 47606 -1103
==========================================
- Hits 152388 149396 -2992
+ Misses 21834 21744 -90
+ Partials 2056 1900 -156
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 105 files with indirect coverage changes 🚀 New features to boost your workflow:
|
|
Review requested — I applied the Clean on my pass, and your body matched what I found, so I'll save the reviewer the duplicate work:
One structural note I'd rather hand over than sit on, because I couldn't settle it by reading and I'm not claiming it's a problem. Not queueing yet: no review on the head. Once it comes back clean this is well inside what I merge myself — fixing small issues and landing straightforward website PRs is my job here, so it won't need a human on the button. |
|
On the Generated by Claude Code |
|
That settles it, and it settles it the right way — 149 pages rendered rather than a grep, with Your caveat is the interesting leftover: the divergence is latent in the data, not the code, so a future model entry shipping without a Still not queueing, and the reason is unchanged: Everything else is green and your verification matched mine, so this should be quick once the review lands. |
webreviewer-bot
left a comment
There was a problem hiding this comment.
APPROVE at 305f8d0c960817d68d311bd0d301ee5bacb4a468. Five files, +5/-5, all under apps/website/**. It renders correctly and the label assertion bites. Two TRIVIAL notes, neither blocking.
| Severity | Count |
|---|---|
| BLOCKER | 0 |
| SHOULD FIX | 0 |
| TRIVIAL | 2 |
Findings
- TRIVIAL —
javisible label is no longer contained in its ownaria-label(WCAG 2.5.3 Label in Name). Measured, whitespace-stripped and case-folded, from the three locale files at this head: en"Download Workflow"is inside"Download workflow JSON"(pass); zh-CN"下载工作流"is inside"下载工作流 JSON"(pass); ja"ワークフローをダウンロード"is not inside"ワークフロー JSONをダウンロード"(fail) —JSONsits betweenワークフローandを, so it is not a substring. The old ja label (ダウンロード) was contained, so this is a new mismatch rather than a pre-existing one. It is dormant:/hub/workflowsis inLOCALE_INVARIANT_EXTRA_PATHS(apps/website/src/config/routes.ts:141), so no/ja/or/zh-CN/workflow route exists and ja never renders this surface. I am not proposing Japanese wording — a Japanese reader should decide whether it is worth picking. - TRIVIAL — the variant is unpinned. Reverting
secondaryOutlineback tooutlineleavesWorkflowPage.test.tsat 9 passed (9) andvue-tsc --noEmitat exit 0. Nothing in the repo asserts this button's appearance. Perdocs/guidance/testing-principles.md:45-52the remedy would be a rendered assertion (computed style or geometry), never a class-name assertion — and jsdom cannot give you one, so this is a note, not a request. Where or whether it lands is your call.
Priority 1 — row geometry at 390x844: the wrap prediction was right, both of its premises were wrong
Built build:e2e at this head (NODE_ENV=production WORKSHOP_IN_BUILD=1 PUBLIC_WORKSHOP_CLOUD_ENV=test), served it with astro preview --port 4399, confirmed the new strings are in the served bundle (dist/_website/translations.TYeb43sh.js contains Download Workflow, 下载工作流, ワークフローをダウンロード; the old "downloadShort":"Download" is absent), then measured [data-testid="workflow-actions"] in Chromium with reducedMotion: 'reduce' on /hub/workflows/change-material/.
The container is flex flex-wrap items-center gap-2, 342px wide (x 24 to 366 inside the 390 viewport), gap: 8px.
390x844
| label | Download w x h | Try in Cloud w x h | row height | occupied | wraps? |
|---|---|---|---|---|---|
en Download Workflow |
219.05 x 44 | 172.09 x 44 | 96 | — (stacked) | yes |
zh-CN 下载工作流 |
113.00 x 44 | 172.09 x 44 | 44 | 293.09 / 342 | no |
ja ワークフローをダウンロード |
213.33 x 44 | 172.09 x 44 | 96 | — (stacked) | yes |
old en Download |
131.42 x 44 | 172.09 x 44 | 44 | 311.52 / 342 | no |
old zh-CN 下载 |
75.20 x 44 | 172.09 x 44 | 44 | 255.30 / 342 | no |
old ja ダウンロード |
125.13 x 44 | 172.09 x 44 | 44 | 305.22 / 342 | no |
Confirmed: the row does now wrap at 390px, in en and ja. Row height goes 44 to 96, so everything below the hero shifts down 52px.
Refuted, premise 1 — there was never 54px of slack; there was 30.49px. The 54px figure came from 390 - 335.5, which counts the page's own 24px right padding as available space. The flex container is 342px and the old row occupied 311.52px, so the real slack was 30.49px. "Download" to "Download Workflow" adds 87.63px, about 2.9x the slack. The wrap was never close.
Refuted, premise 2 — Japanese is not the worst case; English is. ja is 213.33px, en is 219.05px. ja did roughly double (125.13 to 213.33, +70%) as predicted, but English ends up the wider of the two. And zh-CN is the best case by a wide margin: at 113.00px it is narrower than the old English label and does not wrap at either viewport. "CJK glyphs are near full-width so ja must be worse" was wrong here — 下载工作流 is five glyphs against English's 17 characters.
Desktop 1280x800: no wrap in any locale. Container 1216px; en occupies 444px (Download 247.22 x 44 at x=32, Try in Cloud 188.78 x 44 at x=287.22), ja 437.33px, zh-CN 320.28px. Ample room.
Is the wrap acceptable? Yes. document.documentElement.scrollWidth stays 390 in every locale — nothing overflows the viewport. Nothing truncates or clips: scrollWidth == clientWidth on the button in all six cases, computed white-space: normal, overflow: visible, no ellipsis anywhere, and the button height stays exactly 44px, so the label never wraps to a second line inside the button. Tap targets are 44px tall at 113–247px wide — above the 44x44 preference, not merely the 24x24 floor. The container carries flex-wrap and both buttons carry max-w-full whitespace-normal h-auto min-h-11: this layout was built to wrap, and it reads as deliberate. The stack is left-aligned and ragged (219.05 then 172.09) rather than two equal full-width buttons, which is marginally less tidy, but it is a normal mobile result and not a defect.
Priority 2 — the variant
secondaryOutline exists at apps/website/src/components/ui/button/index.ts:22-23: border border-primary-warm-white/70 text-primary-warm-white uppercase ..., the same 1px border width as outline, so the swap causes no layout shift. Nothing falls back silently — I mutated the variant to secondaryOutlineTYPO and vue-tsc failed with TS2820 (exit 2), naming the valid union. Note this PR is the only consumer of secondaryOutline in the website app (2 matches repo-wide: the definition and this use site).
Contrast — measured from painted pixels, not from the declaration. outline-style is none in both the idle and focused states, so Chromium is not painting an adaptive ring and there is no outline-color trap here; the control boundary is a 1px solid border.
The declared border is oklab(0.952334 0.000316292 0.00288588 / 0.7). Reading that declaration as if it were RGB yields a fake 1.17:1 — worth stating, because that is the number a naive computed-style script reports. So I sampled the painted pixels instead: screenshot the button with a 6px margin, decode in-page via createImageBitmap + OffscreenCanvas, take the brightest pixel across the left border edge.
- Border vs page background: 7.82:1 — painted peak
rgb(177,175,177)against a sampled page background ofrgb(33,25,39)(--color-page: #211927). Independently, compositing#f0efedat alpha 0.7 over#211927givesrgb(178,175,178)→ 7.84:1, agreeing with the painted measurement to within one 8-bit step. - Label vs background: 14.82:1 —
rgb(240,239,237)onrgb(33,25,39); the button's own background isrgba(0,0,0,0), so the page is the correct backdrop. - Which WCAG case is this? The control is an
<a>with an accessible name and a visible 14.82:1 text label, so the border is not the only thing identifying the control — 1.4.11's 3:1 is not strictly engaged. It clears 3:1 regardless, at 7.82:1. It is a reduction from the old yellow border (#f2ff59, 15.59:1) and still comfortably above the line.
Hierarchy — exactly one filled-yellow control outside the site nav, at both viewports. I enumerated every element in document.body with computed background-color: rgb(242, 255, 89) and a box of at least 8x8:
- 390x844:
a"Run" 316 x 56 (insidediv[workflow-run-footer]) is the only one outside the nav; plusbutton[aria-label="Toggle menu"]40x40 insidediv[mobile-nav-cta], andspan[data-testid="example-chosen"]20x20 (a selection dot, not a control). - 1280x800:
a"Run" 462 x 56 is the only one outside the nav; plusa[aria-label="TRY CLOUD FOR FREE"]125.36x40, a 31.08x20 "110K" stars badge and a 24x24 glyph, all insidediv[desktop-nav-cta], and the same 20x20example-chosendot.
Run's 316x56 / 462x56 matches the figures from #20919 exactly, so the "one primary" resolution of #20627 is intact. closest('[data-testid="workflow-hero"]') was false for every yellow element — after this PR the hero row contains zero filled-yellow, so the only yellow in the hero is now gone entirely. Download and Try in Cloud still read as peers: both 44px tall, both rgb(240,239,237) text, both uppercase 700 at 14px desktop / 12px mobile. They are not identical variants (Download now has a 1px white border on a transparent background; Try in Cloud is ghost with an rgba(255,255,255,0.08) fill and a 0px border) — but that asymmetry predates this PR, and neither reads as disabled.
Focus visibility holds, measured rather than reasoned from Tailwind ordering. I keyboard-tabbed to the button (not .focus(), so :focus-visible genuinely matches). On focus border-top-color becomes rgb(242,255,89) and a 3px oklab(0.961087 -0.0735818 0.168014 / 0.5) ring appears — so focus-visible:border-primary-comfy-yellow does win over the variant's border-primary-warm-white/70. Idle-vs-idle control first: 0 diff pixels of 10912, then idle-vs-focused 822 / 10912. The focus paint is real, not decode noise.
Priority 3 — i18n
All three locales changed and are mutually consistent with their sibling workshop.workflow.download keys (zh 下载工作流 JSON / 下载工作流; ja ワークフロー JSONをダウンロード / ワークフローをダウンロード). Both read as plausible renderings of "Download Workflow" with correct word order — 下载 (download) + 工作流 (workflow), and Japanese object-marker を plus verb, matching the existing pattern in the same file. Nothing machine-mangled. The ja update is voluntary and good practice, not an obligation — see the mutation below.
Mutations (temp clone, each guarded with git diff --quiet HEAD before and after, each reverted and re-verified clean):
| mutation | command | result |
|---|---|---|
delete workshop.workflow.downloadShort from zh-CN/main.json:5107 |
vitest run src/i18n/translations.test.ts src/config/locales.test.ts src/templates/model-launch/modelLaunchPages.test.ts |
1 failed / 149 passed (150) — src/i18n/translations.test.ts > main.json catalog > includes Chinese copy for every eligible English message |
delete the same key from ja/main.json:4856 |
same command | 150 passed (150) — nothing fails |
So the ja-parity gap I filed as #20978 still holds at this ref: a deleted ja key is invisible to the suite. locale:check exits 0 in both cases and merely lists pending strings (the unmutated baseline already reports ja/main.json: 138 strings need translation).
One measured consequence worth knowing, non-blocking: with full git history present, locale:check detects that the English source string changed and lists workshop.workflow.downloadShort as pending for both zh-CN and ja (Pending: 140 translations, 0 prunable keys, 0 protected-token violations, exit 0). The next i18n: Update Website dispatch will therefore re-translate this key and replace the hand-written ja/zh wording. Expected pipeline behaviour — flagged only in case the exact phrasing was deliberate.
Priority 4 — does the test bite?
Yes. Reverting en/main.json:577 to "downloadShort": "Download":
vitest run src/components/workshop/WorkflowPage.test.ts
-> 1 failed | 8 passed (9)
-> FAIL WorkflowPage header > offers the download and Try in Cloud up top, leaving the run to the form
AssertionError: expected [ [ 'Download', ...(1) ], ...(1) ]
to deeply equal [ [ 'Download Workflow', ...(1) ], ...(1) ]
A named assertion fails for the right reason. Baseline is 9 passed (9) — non-zero collection, so this suite needed no <img> stub to collect on Windows. The variant mutation is the TRIVIAL above.
Blast radius
Credit to @mariana953 for answering routerId vs isWorkflowSlug by rendering rather than grepping — loading all 149 catalogue-linked /hub/models/<slug>/ pages and checking which component actually mounted is the right instinct, and the right level of paranoia for this surface. I verified 3 of those pages myself (beeble-switchx-image-edit, beeble-switchx-video-edit, bria-fibo-image-edit): each renders model-hero / model-detail, none renders workflow-hero, none contains the string "Download Workflow". I accept the remaining 146 on her measurement rather than repeating it.
Reading the dispatch confirms why that holds: ModelsPage.vue:168-170 uses isWorkflowSlug(slug) only to preload a chunk, while the component actually chosen is decided at :172 by model.routerId === undefined. So routerId is authoritative and isWorkflowSlug (models-catalogue.ts:206-208, slug.startsWith('workflows/')) is a performance hint. Her latent-divergence note is exactly right, and I record it as a fact rather than a finding: a future model entry shipped without a routerId would render WorkflowPage and pick up this label, while a workflows/-prefixed slug that has a routerId would merely waste a preload. Nothing in today's data does either. I am not asking for a guard — if one were ever wanted, the cheap shape is to derive both from a single predicate so the preload hint and the render decision cannot disagree. Leaving that to you.
Exposure
Label and variant change on an existing Hub workflow detail surface. No flag check touched — no default, no targeting, no rollout config in the diff. The surface is gated client-side by the PostHog flag workshop-workflows-enabled (src/scripts/posthog.ts:140-143), which I had to stub to render it at all; rollout state unknown from the repository. Separately, src/config/model-page-launch.ts:9 reads launchedWorkflowPages: boolean = false, which affects indexing only (indexing.ts:100,114) — the pages are emitted and reachable either way, they are noindex.
Reviewer gate
All five files are under apps/website/**. Ruleset 991238 ("ProtectMain", active) requires 1 approval from team 19423328 for apps/website/**; its other entry (**/* with !apps/website/**) matches no file here. So my approval alone satisfies the designated-reviewer requirement and no second team is needed. I have no read:org, so I cannot resolve that team id to a name.
CI
Read via the check-runs API, not gh pr checks. 114 check-runs at this SHA: 59 success, 55 skipped, 0 failure, 0 cancelled. The four ruleset-required contexts are green — test, lint-and-format, e2e-status (run 38722201684) and website-e2e (run 38722201463) — and all four parent runs report completed / success / run_attempt=1 at 305f8d0c. No superseded or duplicate-name reds to disentangle.
What I did not verify
- No human eyes on the rendered colour. I measured the border's painted contrast, not whether white-instead-of-yellow is the intended design. "Per design" rests on your word; I only confirmed it is legible and does not disturb the one-primary hierarchy.
- No screenshot baseline covers this.
apps/website/e2e/visual-responsive.spec.ts-snapshots/holds no workflow-page images, so nothing in CI would catch a future regression of this row — consistent with the variant being unpinned. - zh-CN and ja geometry is a substitution, not a route. Those locales have no workflow route (
routes.ts:141), so I measured by replacing the label's text node in the live-rendered button — same CSS, samePP Formulafont, same flex container, real layout. That answers "what would this label do here", not "what does production serve today", which for those locales is nothing. - I measured one workflow slug (
change-material), not all 32. Label width is slug-independent; the surrounding hero width is not, but the page shell is shared. - Built and measured on node v25.9.0 against a
>=26.8.2engine field, and I ran no full local e2e suite — CI's four greenwebsite-e2e-shards cover that.
|
Queueing this at webreviewer-bot's verdict is APPROVE with 0 BLOCKER and 0 SHOULD FIX — both counts, which is what lets me call it clean rather than just uncrashed. The two TRIVIALs are notes, and @mariana953 answered both inline with reasons I find sound: the ja label-in-name mismatch is dormant because Gates checked at the head rather than inferred: all five required checks present and The one real behaviour change is disclosed and measured: at 390px the row wraps in en and ja, row height 44→96, so content below the hero shifts down 52px. Verified non-breaking — Fixing minor issues and merging straightforward website PRs is my job here, so this doesn't need a human on the button. Note that enqueueing ends the review window — the queue won't re-read reviews once it accepts this, so if anyone wants another look, say so now and I'll pull it back out. |
Summary
The top download button on a Hub workflow page (next to "Try in Cloud") read only "Download" and used the yellow outline. It now reads "Download Workflow", which says what the visitor gets (requested by Charlene), and uses the white outline (
secondaryOutline), per design.workshop.workflow.downloadShort:WorkflowPage.vue: the button's variant changes fromoutline(yellow) tosecondaryOutline(white).workshop.workflow.download, "Download workflow JSON") does not change. The visible label is now the start of that name.flex-wrap).Verification
vitest run src/components/workshop: 88 files and 913 tests pass.WorkflowPage.test.tsnow expects the new visible label.PUBLIC_WORKSHOP_ENABLED=1 PUBLIC_WORKSHOP_WORKFLOWS_ENABLED=1, on/hub/workflows/change-material/at 1280px and 390px:mainthey read "DOWNLOAD" (yellow outline) and "TRY IN CLOUD".