From ffc3f3cbf85766b95db9228133b186442ab25509 Mon Sep 17 00:00:00 2001 From: smartcalsystems-sketch Date: Tue, 13 Oct 2026 23:48:06 +0530 Subject: [PATCH] fix: let PipelineBoard card content form its own accessible name (closes #694) Each pipeline card's had aria-label={`${title}, ${reward}`}, which overrides the link's visible content as far as assistive tech is concerned. The org/repo #N line -- the main way a maintainer identifies which issue a card is -- was never announced, only the title and reward the aria-label spelled out manually. Dropped the aria-label so the link's accessible name is computed from its actual visible content instead, which already includes the org/repo reference, the title, and the formatted reward -- nothing is lost, the repo reference is gained. --- .../maintainer/PipelineBoard.test.tsx | 24 +++++++++++++++++++ .../dashboard/maintainer/PipelineBoard.tsx | 1 - 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/src/app/dashboard/maintainer/PipelineBoard.test.tsx b/src/app/dashboard/maintainer/PipelineBoard.test.tsx index b053b8ef..64eb5ccc 100644 --- a/src/app/dashboard/maintainer/PipelineBoard.test.tsx +++ b/src/app/dashboard/maintainer/PipelineBoard.test.tsx @@ -30,6 +30,30 @@ function makeBounty(overrides: Partial = {}): Bounty { }; } +describe("PipelineBoard — card accessible name (#694)", () => { + it("announces the org/repo/issue reference as part of the link's accessible name", () => { + const bounty = makeBounty({ + org: "SmartDropLabs", + repo: "smartdrop-backend", + issueNumber: 42, + title: "Fix retry backoff jitter", + reward: 500, + asset: "USDC", + status: "open", + }); + render(); + + const link = screen.getByRole("link", { + name: /SmartDropLabs\/smartdrop-backend #42/, + }); + // The accessible name is computed from visible content (no aria-label + // override), so the title and reward are present too, not just the repo + // reference. + expect(link).toHaveAccessibleName(/Fix retry backoff jitter/); + expect(link).toHaveAccessibleName(/500/); + }); +}); + describe("PipelineBoard — merged column (#88)", () => { it("renders a bounty with status 'merged' in a visible pipeline column", () => { const merged = makeBounty({ id: "merged-1", title: "Merged, awaiting payout", status: "merged" }); diff --git a/src/app/dashboard/maintainer/PipelineBoard.tsx b/src/app/dashboard/maintainer/PipelineBoard.tsx index 331b44bd..7157b2b8 100644 --- a/src/app/dashboard/maintainer/PipelineBoard.tsx +++ b/src/app/dashboard/maintainer/PipelineBoard.tsx @@ -73,7 +73,6 @@ function PipelineColumn({ key={b.id} href={`/issues/${b.id}`} title={b.title} - aria-label={`${b.title}, ${formatCurrency(b.reward, b.asset)}`} className="block rounded-xl border border-slate-200 bg-white p-3 shadow-sm transition-colors hover:border-indigo-300 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-indigo-500 dark:border-slate-800 dark:bg-slate-900 dark:hover:border-indigo-700" >