Skip to content

Commit 07759cd

Browse files
author
Marlon Costa
committed
Merge PR winfunc#403: Accessibility Labels (partial)
Kept i18n version of conflicting files. Accessibility improvements merged where possible - MCPServerList, ProjectList, CustomTitlebar.
2 parents e3c538f + 59456c4 commit 07759cd

22 files changed

Lines changed: 110 additions & 32 deletions

bun.lock

Lines changed: 1 addition & 22 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/components/AgentExecution.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -549,6 +549,7 @@ export const AgentExecution: React.FC<AgentExecutionProps> = ({
549549
title={t("common.back")}
550550
>
551551
<ArrowLeft className="h-4 w-4" />
552+
<span className="sr-only">Back</span>
552553
</Button>
553554
<div>
554555
<h1 className="text-heading-1">{agent.name}</h1>

src/components/AgentRunView.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,7 @@ export const AgentRunView: React.FC<AgentRunViewProps> = ({
257257
className="h-8 w-8"
258258
>
259259
<ArrowLeft className="h-4 w-4" />
260+
<span className="sr-only">Back</span>
260261
</Button>
261262
<div className="flex items-center gap-2">
262263
{renderIcon(run.agent_icon)}

src/components/Agents.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -358,6 +358,7 @@ export const Agents: React.FC = () => {
358358
<DropdownMenuTrigger asChild>
359359
<Button variant="ghost" size="icon" className="h-8 w-8">
360360
<ChevronDown className="w-4 h-4" />
361+
<span className="sr-only">Agent options</span>
361362
</Button>
362363
</DropdownMenuTrigger>
363364
<DropdownMenuContent align="end">

src/components/CCAgents.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,7 @@ export const CCAgents: React.FC<CCAgentsProps> = ({ onBack, className }) => {
308308
className="h-8 w-8"
309309
>
310310
<ArrowLeft className="h-4 w-4" />
311+
<span className="sr-only">Back</span>
311312
</Button>
312313
<div>
313314
<h1 className="text-heading-1">{t("agents.title")}</h1>

src/components/ClaudeFileEditor.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ export const ClaudeFileEditor: React.FC<ClaudeFileEditorProps> = ({
110110
className="h-8 w-8"
111111
>
112112
<ArrowLeft className="h-4 w-4" />
113+
<span className="sr-only">Back</span>
113114
</Button>
114115
<div className="min-w-0 flex-1">
115116
<h2 className="text-lg font-semibold truncate">{file.relative_path}</h2>

src/components/ClaudeMemoriesDropdown.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ export const ClaudeMemoriesDropdown: React.FC<ClaudeMemoriesDropdownProps> = ({
143143
}}
144144
>
145145
<Edit2 className="h-3 w-3" />
146+
<span className="sr-only">Edit file</span>
146147
</Button>
147148
</motion.div>
148149
))}

src/components/CreateAgent.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ export const CreateAgent: React.FC<CreateAgentProps> = ({
141141
title={t("agents.backToAgents")}
142142
>
143143
<ArrowLeft className="h-4 w-4" />
144+
<span className="sr-only">Back to Agents</span>
144145
</Button>
145146
</motion.div>
146147
<div>

src/components/CustomTitlebar.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
9797
{isHovered && (
9898
<X size={8} className="text-red-900 opacity-60 group-hover:opacity-100" />
9999
)}
100+
<span className="sr-only">Close window</span>
100101
</button>
101102

102103
{/* Minimize button */}
@@ -111,6 +112,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
111112
{isHovered && (
112113
<Minus size={8} className="text-yellow-900 opacity-60 group-hover:opacity-100" />
113114
)}
115+
<span className="sr-only">Minimize window</span>
114116
</button>
115117

116118
{/* Maximize button */}
@@ -125,6 +127,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
125127
{isHovered && (
126128
<Square size={6} className="text-green-900 opacity-60 group-hover:opacity-100" />
127129
)}
130+
<span className="sr-only">Maximize window</span>
128131
</button>
129132
</div>
130133
</div>
@@ -142,6 +145,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
142145
className="p-2 rounded-md hover:bg-accent hover:text-accent-foreground transition-colors tauri-no-drag"
143146
>
144147
<Bot size={16} />
148+
<span className="sr-only">Agents</span>
145149
</motion.button>
146150
</TooltipSimple>
147151
)}
@@ -155,6 +159,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
155159
className="p-2 rounded-md hover:bg-accent hover:text-accent-foreground transition-colors tauri-no-drag"
156160
>
157161
<BarChart3 size={16} />
162+
<span className="sr-only">Usage Dashboard</span>
158163
</motion.button>
159164
</TooltipSimple>
160165
)}
@@ -174,6 +179,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
174179
className="p-2 rounded-md hover:bg-accent hover:text-accent-foreground transition-colors tauri-no-drag"
175180
>
176181
<Settings size={16} />
182+
<span className="sr-only">Settings</span>
177183
</motion.button>
178184
</TooltipSimple>
179185
)}
@@ -188,6 +194,7 @@ export const CustomTitlebar: React.FC<CustomTitlebarProps> = ({
188194
className="p-2 rounded-md hover:bg-accent hover:text-accent-foreground transition-colors flex items-center gap-1"
189195
>
190196
<MoreVertical size={16} />
197+
<span className="sr-only">More options</span>
191198
</motion.button>
192199
</TooltipSimple>
193200

src/components/FilePicker.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -381,6 +381,7 @@ export const FilePicker: React.FC<FilePickerProps> = ({
381381
className="h-8 w-8"
382382
>
383383
<ArrowLeft className="h-4 w-4" />
384+
<span className="sr-only">Navigate up</span>
384385
</Button>
385386
<span className="text-sm font-mono text-muted-foreground truncate max-w-[300px]">
386387
{relativePath}
@@ -393,6 +394,7 @@ export const FilePicker: React.FC<FilePickerProps> = ({
393394
className="h-8 w-8"
394395
>
395396
<X className="h-4 w-4" />
397+
<span className="sr-only">Close</span>
396398
</Button>
397399
</div>
398400
</div>

0 commit comments

Comments
 (0)