From 8a75c15557f489ee7f33ad65178d602e36609bbc Mon Sep 17 00:00:00 2001 From: Olabode Felix Akinyemi <80841202+akinshaywai@users.noreply.github.com> Date: Wed, 15 Apr 2026 09:31:24 +0100 Subject: [PATCH] Merge pull request #454 from akinshaywai/fix/a11y-config-panel-labels fix(a11y): add accessible labels to ConfigPanel inputs and icon buttons --- .../extension/src/components/ConfigPanel.tsx | 33 ++++++++++++++++--- 1 file changed, 28 insertions(+), 5 deletions(-) diff --git a/packages/extension/src/components/ConfigPanel.tsx b/packages/extension/src/components/ConfigPanel.tsx index eae206c..bdbc9f0 100644 --- a/packages/extension/src/components/ConfigPanel.tsx +++ b/packages/extension/src/components/ConfigPanel.tsx @@ -123,6 +123,7 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) { size="icon-sm" onClick={onClose} className="absolute top-2 right-3 cursor-pointer" + aria-label="Back" > @@ -130,12 +131,15 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) { {/* User Auth Token Section */}
- +

Give a website the ability to call this extension.

setShowToken(!showToken)} disabled={!userAuthToken} + aria-label={showToken ? 'Hide token' : 'Show token'} + aria-pressed={showToken} > {showToken ? : } @@ -161,9 +167,13 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) { className="h-8 w-8 shrink-0 cursor-pointer" onClick={handleCopyToken} disabled={!userAuthToken} + aria-label="Copy token" > {copied ? : } + + {copied ? 'Token copied' : ''} +
@@ -178,8 +188,11 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) {
- + setBaseURL(e.target.value)} @@ -204,8 +217,11 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) { )}
- + setModel(e.target.value)} @@ -214,9 +230,12 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) {
- +
setShowApiKey(!showApiKey)} + aria-label={showApiKey ? 'Hide API key' : 'Show API key'} > {showApiKey ? : } @@ -260,8 +280,11 @@ export function ConfigPanel({ config, onSave, onClose }: ConfigPanelProps) { {advancedOpen && ( <>
- +