Repository navigation
feat(storybook): showcase all GoodWidget widgets with QA fixtures and theme overrides - #253
goodbounties-nanoclaw-agent[bot] wants to merge 4 commits into
Conversation
…A fixtures and theme overrides Adds the Showcase/Theme-overrides/QA three-way story split to CitizenClaimWidget, GoodReserveWidget, GovernanceWidget, AiCreditsWidget, SuperfluidCampaignWidget, and GoodDataWidget per issue #252, including MDX integrator docs and deterministic QA fixtures backing each widget's Playwright states spec. Co-Authored-By: Claude <noreply@anthropic.com> On-Behalf-Of: BountyCoder[onecli] (yaskkeryodtdijpv)
There was a problem hiding this comment.
🟡 Changes recommended
Several showcased overrides are ineffective, environment switching can retain stale data, and new playgrounds lack required Playwright coverage.
9 open findings
Card background controls do not affect AiCreditsHero · New Add Playwright smoke test for theme playground · New Add Playwright smoke test for theme playground · New Add Playwright smoke test for theme playground · New Add Playwright smoke test for theme playground · New Card controls do not theme ReserveSwapShell surfaces · New Environment changes do not refresh claim data · New Add Playwright smoke test for theme playground · New Card background overrides do not affect widget shell · New
What changed in this PR
Adds consistent Showcase, Theme Overrides, QA, and integrator documentation across the remaining widgets.
Changes:
- Adds theme playgrounds and widget guides.
- Reorganizes deterministic QA stories and updates Playwright story IDs.
- Adds environment and live-connector showcase controls.
| File | Description |
|---|---|
tests/widgets/superfluid-campaign-widget/states.spec.ts |
Updates QA story IDs. |
tests/widgets/governance-widget/onboarding.spec.ts |
Updates onboarding story IDs. |
tests/widgets/goodreserve-widget/states.spec.ts |
Updates Showcase and QA story IDs. |
tests/widgets/gooddata-widget/states.spec.ts |
Updates QA story IDs. |
examples/storybook/src/stories/superfluid-campaign-widget/SuperfluidCampaignWidgetThemeOverrides.stories.tsx |
Adds theme playground. |
examples/storybook/src/stories/superfluid-campaign-widget/SuperfluidCampaignWidgetApiContracts.stories.tsx |
Moves API contracts under QA. |
examples/storybook/src/stories/superfluid-campaign-widget/SuperfluidCampaignWidget.mdx |
Documents theme overrides. |
examples/storybook/src/stories/helpers/goodDataWidgetStories.tsx |
Registers and exposes the live connector. |
examples/storybook/src/stories/helpers/citizenClaimWidgetStories.tsx |
Adds environment and initial-tab inputs. |
examples/storybook/src/stories/governance-widget/GovernanceWidget.mdx |
Documents environment availability. |
examples/storybook/src/stories/governance-widget/GovernanceOnboarding.stories.tsx |
Moves onboarding stories under QA. |
examples/storybook/src/stories/goodreserve-widget/GoodReserveWidgetThemeOverrides.stories.tsx |
Adds theme playground. |
examples/storybook/src/stories/goodreserve-widget/GoodReserveWidgetShowcase.stories.tsx |
Retains live showcase stories. |
examples/storybook/src/stories/goodreserve-widget/GoodReserveWidgetQA.stories.tsx |
Adds deterministic reserve fixtures. |
examples/storybook/src/stories/goodreserve-widget/GoodReserveWidget.mdx |
Adds integrator documentation. |
examples/storybook/src/stories/gooddata-widget/GoodDataWidgetThemeOverrides.stories.tsx |
Adds theme playground. |
examples/storybook/src/stories/gooddata-widget/GoodDataWidgetShowcase.stories.tsx |
Adds live-connector showcase. |
examples/storybook/src/stories/gooddata-widget/GoodDataWidgetQA.stories.tsx |
Renames the QA namespace. |
examples/storybook/src/stories/gooddata-widget/GoodDataWidget.mdx |
Adds integrator documentation. |
examples/storybook/src/stories/citizen-claim-widget/CitizenClaimWidgetThemeOverrides.stories.tsx |
Adds theme playground. |
examples/storybook/src/stories/citizen-claim-widget/CitizenClaimWidgetShowcase.stories.tsx |
Adds environment controls. |
examples/storybook/src/stories/citizen-claim-widget/CitizenClaimWidget.mdx |
Documents controls and theming. |
examples/storybook/src/stories/ai-credits-widget/AiCreditsWidgetThemeOverrides.stories.tsx |
Adds theme playground. |
examples/storybook/src/stories/ai-credits-widget/AiCreditsWidgetShowcase.stories.tsx |
Removes the mock fixture from Showcase. |
examples/storybook/src/stories/ai-credits-widget/AiCreditsWidgetQA.stories.tsx |
Moves the mock fixture into QA. |
examples/storybook/src/stories/ai-credits-widget/AiCreditsWidget.mdx |
Updates showcase and QA guidance. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
| dark_Card: { | ||
| background: args.darkCardBackground, | ||
| borderColor: args.darkCardBorderColor, | ||
| }, | ||
| light_Card: { | ||
| background: args.lightCardBackground, | ||
| borderColor: args.lightCardBorderColor, | ||
| }, |
| export default meta | ||
| type Story = StoryObj<OverridesArgs> | ||
|
|
||
| export const Playground: Story = { |
| export default meta | ||
| type Story = StoryObj<OverridesArgs> | ||
|
|
||
| export const Playground: Story = { |
| export default meta | ||
| type Story = StoryObj<OverridesArgs> | ||
|
|
||
| export const Playground: Story = { |
| export default meta | ||
| type Story = StoryObj<OverridesArgs> | ||
|
|
||
| export const Playground: Story = { |
| <GoodReserveWidget | ||
| provider={provider} | ||
| mockState={reserveWidgetMockStates.idleBuy} | ||
| defaultTheme="dark" | ||
| themeOverrides={themeOverrides} |
| <CitizenClaimWidget | ||
| provider={provider} | ||
| environment="development" | ||
| environment={environment} |
| export default meta | ||
| type Story = StoryObj<OverridesArgs> | ||
|
|
||
| export const Playground: Story = { |
| <li> | ||
| <strong>dark_Card / light_Card</strong>: outer widget shell, ActionCard, the | ||
| LeaderboardSummary card, and each LeaderboardRow all cascade from this theme — | ||
| demonstrated below on the outer shell and ActionCard. | ||
| </li> |
|
Merge order note (per Olivia, Bounty Lead, 2026-10-21): hold this PR until #227 (Thales's AI Credits dashboard fixes) lands first — both touch |
|
@Abuchtela is interested in taking the GoodBounty follow-up for #253 (theme-control fixes, CitizenClaim environment remount, shared environment options, and QA evidence). Proposed ETA: November 2, 2026, subject to fork/write access and local test execution. Please confirm whether the bounty can be claimed here or requires a separate claim flow. |
|
@Abuchtela assignments for issues happens in the issues, not in the pull-requests. |
0xOlivanode
left a comment
There was a problem hiding this comment.
Bounty lead review for #264, at 4c5da5f.
Thanks @Ryjen1, this covers the bounty well, and thanks @Olisehgenesis for the review.
Checked against #264:
- Bug 1 background controls: Pass (wired to backgroundSurface/backgroundInput, visible in light and dark screenshots)
- Bug 1 copy correction: Partial (border-color copy on GoodReserve still inaccurate, see inline)
- Bug 2 environment remount: Pass, with tests
- Screenshots: Pass
- environmentOptions helper: Pass
- Optional smoke tests: Pass
- Scope (Storybook/docs/tests only): Pass
- Copilot: Pass, apart from the border-color question it left for a human (inline 1)
- Signed commits: Fail (8 of 14 unsigned: everything from Oct 30 and Nov 1)
- Required commands: Not verified (CI needs maintainer approval)
To finish:
- Resolve the GoodReserve border-color control (inline 1 and 2): confirm it reaches the swap shell and fix the copy, or wire/remove it. Relabelling a control that does nothing visible isn't enough under #264.
- Re-sign the unsigned commits (e.g. rebase with signing and force-push), as the contribution guide requires signed commits.
- Post the #264 handoff comment (what changed, what was tested, evidence, remaining risks), and a short acknowledgement of Oliseh's non-blocking follow-ups.
Inline 3 and 4 are nits.
Non-blocking, for a follow-up rather than this PR: the custom presets only recolour some accents, so the demo mixes violet (buttons, borders) with the default blue (titles, MAX, icons, links). And the docs callouts render in a serif font, which comes from the shared DocsLayout, not this PR. Both are worth a small polish issue.
@L03TJ3 once these are in, I'm happy to sign off. CI workflows need your approval to run.
| darkCardBorderColor: string | ||
| lightCardBackground: string | ||
| lightCardBorderColor: string | ||
| darkButtonBackground: string |
There was a problem hiding this comment.
This is the open question Copilot left for a human. The control says it “styles swap shell and amount card borders”, but ReserveAmountCard has borderWidth: 0, so it can’t style the amount panels. And in the committed screenshots (grw-theme-overrides-dark/light.png), the shell border doesn’t look like the
#7C3AED default either. It reads as the base grey/lavender, while the same control on AiCredits clearly shows violet borders. Can you check whether dark_Card.borderColor actually reaches ReserveSwapShell? If it does, fix the description to say shell only. If it doesn’t, wire it to a key that works, or remove it and note the limitation. #264 says relabelling a control that still does nothing isn’t enough.
| parameters: { layout: 'padded' }, | ||
| argTypes: { | ||
| darkCardBackground: { control: 'color', description: 'themes.dark_Card.background' }, | ||
| darkCardBorderColor: { control: 'color', description: 'themes.dark_Card.borderColor' }, |
There was a problem hiding this comment.
Same issue in the docs: amount cards have no border, so please correct this line to match whatever comment 1 ends up doing.
| @@ -104,21 +109,24 @@ function CitizenClaimWidgetStoryShell({ | |||
| return ( | |||
| <CitizenClaimWidget | |||
There was a problem hiding this comment.
Nit: key={environment} is set on both the wrapper div and the CitizenClaimWidget inside it (line 112). One is enough; the outer one already forces the remount. Also, data-testid moved from the widget onto the wrapper. Please confirm no existing tests or docs relied on it being on the widget.
There was a problem hiding this comment.
Nit: the address was made valid by appending a 0, which turns it into a different, arbitrary address. That’s fine for a mock, but a short comment saying it’s a placeholder (or a clearly fake address like 0x000...dEaD) would stop anyone treating it as a real account later.
* refactor(storybook): extract ENVIRONMENT_OPTIONS to shared helper * fix(storybook): add remount key on environment change in CitizenClaim stories * fix(storybook): wire background controls to correct base theme keys in Theme overrides * test(storybook): add Playwright smoke tests for theme overrides and showcase controls * test(storybook): verify CitizenClaim remount across environment switches with mock provider * docs(storybook): update GoodReserve MDX, document theme cascading, and add theme screenshots * docs(storybook): clarify backgroundSurfaceAlt limitation on GoodReserve token badges * test(storybook): verify dynamic in-place theme controls and environment remount * fix(storybook): split dark/light theme override background controls and capture full-page screenshots * fix(storybook): resolve blockers B1-B3 with deterministic showcase RPC fixtures and improved contrast * fix(storybook): account for Fuse 2-decimal scaling in daily-stats fixture * fix(storybook): restore Card border-color controls in theme overrides stories * fix(storybook): restore deterministic fixture provider for Superfluid theme playground * fix(storybook): memoize custodial fixture provider in ThemedSuperfluidStory * fix(storybook): remove no-op GoodReserve border controls * fix(storybook): simplify CitizenClaim fixture remount
| if (method === 'eth_chainId') { | ||
| const url = request.url() | ||
| let chainIdHex = '0xa4ec' // Celo (42220) | ||
| if (url.includes('fuse.io')) chainIdHex = '0x7a' // Fuse (122) |
| const url = request.url() | ||
| let chainIdHex = '0xa4ec' // Celo (42220) | ||
| if (url.includes('fuse.io')) chainIdHex = '0x7a' // Fuse (122) | ||
| if (url.includes('ankr.com')) chainIdHex = '0x32' // XDC (50) |
Linked issuesChecked at commit 756bba6 #252 [PLAN] Widget showcase in storybook · 10 of 11 met
|
# Conflicts: # examples/storybook/src/stories/goodreserve-widget/GoodReserveWidgetShowcase.stories.tsx # examples/storybook/src/stories/helpers/citizenClaimWidgetStories.tsx # examples/storybook/src/stories/helpers/superfluidCampaignWidgetStories.tsx


Closes #252
Summary
Adds the Showcase / Theme overrides / QA three-way story split to the remaining widgets per the plan in #252:
Each widget gets an MDX integrator doc, a deterministic QA fixture set backing its Playwright spec, and (where applicable) a Theme overrides playground scoped to the theme targets the widget actually renders.
Test plan
tsc --noEmitclean (only pre-existing baseline errors)eslintcleanAiCreditsWidget appkit connect wallettests caused byVITE_REOWN_PROJECT_IDnot being set in the CI/dev sandbox (pre-existing, unrelated to this change — confirmed zero diff on that spec file vs main)Note on commit signing
Commits on this branch show as unsigned in this environment — a known, long-standing issue in this org (same symptom previously seen on #148, #179, and #227; root cause not yet pinned down). Per the pattern used on #227, please squash-merge this PR rather than rebase-merge — GitHub signs the resulting squash commit itself at merge time, independent of the source branch's signature state, which satisfies main's "require signed commits" ruleset.
🤖 Generated by goodbounties-nanoclaw-agent
Summary by Sourcery
Organize the remaining Storybook widgets into documented Showcase, Theme overrides, and deterministic QA experiences with expanded Playwright coverage.
New Features:
Enhancements:
Documentation:
Tests: