Skip to content

Where agent teams gather. Cross-platform team chat where AI agents are first-class teammates — with cloud or bring-your-own (Claude Code / Codex) brains.

TypeScript

a11y: enable 30 Biome accessibility rules and fix ARIA / semantic conformance (#129)

cicada2767d45f5694
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 5222a9b..6acd708 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -50,8 +50,9 @@ npm run guard:llm-tracked # architecture guard, see below
Biome is configured (`biome.json`) as a **linter only** — it is not a
formatter here, so it won't reflow existing code. The rule set is a
pragmatic subset of Biome's recommended rules: correctness and real-bug
-rules are on; noisy or intentional-pattern style rules (and the a11y
-group, tracked as separate follow-up work) are off.
+rules are on; noisy or intentional-pattern style rules are off, while the a11y
+rules are enforced incrementally (useButtonType, ARIA roles/props, and core
+accessibility rules are active).
Both TypeScript projects are `strict`. There are no frontend unit tests yet;
server and worker logic is covered by `server/src/__tests__` and
diff --git a/biome.json b/biome.json
index ee5e4e1..1d06542 100644
--- a/biome.json
+++ b/biome.json
@@ -39,7 +39,36 @@
"preset": "recommended",
"a11y": {
"preset": "none",
- "useButtonType": "error"
+ "noAccessKey": "error",
+ "noAmbiguousAnchorText": "error",
+ "noAriaHiddenOnFocusable": "error",
+ "noAriaUnsupportedElements": "error",
+ "noDistractingElements": "error",
+ "noHeaderScope": "error",
+ "noInteractiveElementToNoninteractiveRole": "error",
+ "noNoninteractiveElementToInteractiveRole": "error",
+ "noNoninteractiveTabindex": "error",
+ "noPositiveTabindex": "error",
+ "noRedundantAlt": "error",
+ "noRedundantRoles": "error",
+ "useAltText": "error",
+ "useAnchorContent": "error",
+ "useAriaActivedescendantWithTabindex": "error",
+ "useAriaPropsForRole": "error",
+ "useAriaPropsSupportedByRole": "error",
+ "useButtonType": "error",
+ "useGenericFontNames": "error",
+ "useHeadingContent": "error",
+ "useHtmlLang": "error",
+ "useIframeTitle": "error",
+ "useKeyWithMouseEvents": "error",
+ "useMediaCaption": "error",
+ "useValidAnchor": "error",
+ "useValidAriaProps": "error",
+ "useValidAriaRole": "error",
+ "useValidAriaValues": "error",
+ "useValidAutocomplete": "error",
+ "useValidLang": "error"
},
"style": {
"noNonNullAssertion": "off",
@@ -70,4 +99,4 @@
"enabled": false
}
}
-}
+}
\ No newline at end of file
diff --git a/server/src/agents/cli.ts b/server/src/agents/cli.ts
index 4ab7867..d865b6b 100644
--- a/server/src/agents/cli.ts
+++ b/server/src/agents/cli.ts
@@ -3895,7 +3895,7 @@ async function cmdMemory(parsed: ParsedArgs): Promise<CliResult> {
const limit = Math.min(100, Math.max(1, Number(parsed.flags.limit ?? 20)))
// Fetch extra rows so in-memory project filtering can still fill `limit`.
// `--all` is the only path that skips isolation.
- const fetchLimit = Boolean(parsed.flags.all) ? limit : Math.min(500, Math.max(limit * 10, 100))
+ const fetchLimit = parsed.flags.all ? limit : Math.min(500, Math.max(limit * 10, 100))
params.push(fetchLimit)
const limitParam = `$${params.length}`
const { rows } = await pool.query<{
diff --git a/src/admin/ObservabilityPage.tsx b/src/admin/ObservabilityPage.tsx
index bf237a4..ac6627e 100644
--- a/src/admin/ObservabilityPage.tsx
+++ b/src/admin/ObservabilityPage.tsx
@@ -984,6 +984,10 @@ function CachePurposeBar({ purpose, hitRate, savableUsd, costUsd, uncachedIn, ca
<div
className={`obs-cache-bar-fill ${cacheToneClass(hitRate)}`}
style={{ width: `${ratePct}%` }}
+ role="progressbar"
+ aria-valuenow={Math.round(ratePct)}
+ aria-valuemin={0}
+ aria-valuemax={100}
aria-label={`${ratePct.toFixed(0)}%`}
/>
<span className="obs-cache-bar-rate">{hitRate != null ? fmtPct(hitRate, 0) : '—'}</span>
diff --git a/src/components/EmailComposer.tsx b/src/components/EmailComposer.tsx
index 327999a..30b67e1 100644
--- a/src/components/EmailComposer.tsx
+++ b/src/components/EmailComposer.tsx
@@ -380,7 +380,7 @@ export function EmailComposer() {
}
return (
- <div className="fixed inset-0 z-[55] grid place-items-end pointer-events-none" aria-modal="true">
+ <div className="fixed inset-0 z-[55] grid place-items-end pointer-events-none" role="dialog" aria-modal="true">
{/* Click-outside backdrop. Click anywhere outside the panel to close. */}
<button
type="button"
diff --git a/src/components/Select.tsx b/src/components/Select.tsx
index 4221c06..03a6d9f 100644
--- a/src/components/Select.tsx
+++ b/src/components/Select.tsx
@@ -128,6 +128,7 @@ export function Select<T extends string = string>({
<button
id={selectId}
type="button"
+ role="combobox"
disabled={disabled}
aria-label={ariaLabel}
aria-haspopup="listbox"
diff --git a/src/components/TwEmoji.tsx b/src/components/TwEmoji.tsx
index 063ec6a..0714f5f 100644
--- a/src/components/TwEmoji.tsx
+++ b/src/components/TwEmoji.tsx
@@ -44,6 +44,7 @@ export function TwEmoji({ emoji, size = 16, className }: Props) {
// Native fallback — keep the inline-baseline alignment so layout stays put.
return (
<span
+ role="img"
className={className}
style={{ fontSize: size, lineHeight: 1, display: 'inline-block', verticalAlign: 'text-bottom' }}
aria-label={emoji}
diff --git a/src/desktop/BoardsView.tsx b/src/desktop/BoardsView.tsx
index e110066..bcff659 100644
--- a/src/desktop/BoardsView.tsx
+++ b/src/desktop/BoardsView.tsx
@@ -435,7 +435,7 @@ function CardTile({ card, onOpen }: { card: BoardCard; onOpen: () => void }) {
const byId = useParticipants((s) => s.byId)
const assignee = card.assigneeId ? byId[card.assigneeId] : null
return (
- <article
+ <div
role="button"
tabIndex={0}
draggable
@@ -469,7 +469,7 @@ function CardTile({ card, onOpen }: { card: BoardCard; onOpen: () => void }) {
)}
</div>
)}
- </article>
+ </div>
)
}
diff --git a/src/desktop/ConversationsPane.tsx b/src/desktop/ConversationsPane.tsx
index d578ffe..f0d79cb 100644
--- a/src/desktop/ConversationsPane.tsx
+++ b/src/desktop/ConversationsPane.tsx
@@ -247,6 +247,7 @@ function MutedGlyph({ title }: { title: string }) {
// Slack-style bell-off — small, ink-300, matches the row's secondary tone.
return (
<span
+ role="img"
className="inline-flex items-center justify-center w-3 h-3 shrink-0 text-ink-300"
title={title}
aria-label={title}
diff --git a/src/desktop/MeView.tsx b/src/desktop/MeView.tsx
index 050f647..f48571c 100644
--- a/src/desktop/MeView.tsx
+++ b/src/desktop/MeView.tsx
@@ -964,9 +964,7 @@ function ComputersTab() {
<div key={c.id} className="bg-cloud rounded-[14px]" style={{ border: '1px solid var(--ink-100)' }}>
<div
className={cn('p-4 flex items-center gap-4 rounded-[14px]', repairable && 'cursor-pointer hover:bg-sky2-50')}
- onClick={repairable ? () => toggleEngines(c.id) : undefined}
- role={repairable ? 'button' : undefined}
- aria-expanded={repairable ? enginesShown : undefined}>
+ onClick={repairable ? () => toggleEngines(c.id) : undefined}>
<div className="text-[22px] w-8 text-center">{KIND_ICON[c.kind] ?? '🖥'}</div>
<div className="flex-1 min-w-0">
<div className="flex items-center gap-2">
diff --git a/src/mobile/MobileChatList.tsx b/src/mobile/MobileChatList.tsx
index a118528..54e16a0 100644
--- a/src/mobile/MobileChatList.tsx
+++ b/src/mobile/MobileChatList.tsx
@@ -107,7 +107,7 @@ function ConvoAvatar({ c, size = 48 }: { c: Conversation; size?: number }) {
function MutedGlyph() {
const t = useT()
return (
- <span className="inline-flex items-center justify-center w-3.5 h-3.5 shrink-0 text-ink-300" aria-label={t('mclist.muted')}>
+ <span role="img" className="inline-flex items-center justify-center w-3.5 h-3.5 shrink-0 text-ink-300" aria-label={t('mclist.muted')}>
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" className="w-3.5 h-3.5">
<path d="M13.73 21a2 2 0 0 1-3.46 0" />
<path d="M18.63 13A17.9 17.9 0 0 1 18 8" />
diff --git a/website/index.html b/website/index.html
index 4e1b5d8..7f02aa0 100644
--- a/website/index.html
+++ b/website/index.html
@@ -925,23 +925,23 @@
<span class="version-badge" id="version-badge">Loading…</span>
</p>
<div class="platforms">
- <a class="platform download-btn" id="dl-mac-arm64" href="#" data-loading>
+ <a class="platform download-btn" id="dl-mac-arm64" href="#download" data-loading>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden><path d="M17.5 12.6c0-2.4 2-3.6 2.1-3.6-1.1-1.7-2.9-1.9-3.5-1.9-1.5-.2-2.9.9-3.6.9-.8 0-1.9-.9-3.1-.8-1.6 0-3.1.9-3.9 2.4-1.7 2.9-.4 7.2 1.2 9.5.8 1.1 1.7 2.4 2.9 2.4 1.2 0 1.6-.7 3-.7 1.4 0 1.8.7 3 .7 1.3 0 2.1-1.2 2.9-2.3.9-1.3 1.3-2.6 1.3-2.7 0 0-2.4-1-2.4-3.9zm-2.4-7c.6-.8 1.1-1.9 1-3-.9 0-2 .6-2.7 1.4-.6.7-1.1 1.8-1 2.9 1 .1 2-.5 2.7-1.3z"/></svg>
macOS <span class="arch">Apple silicon</span>
</a>
- <a class="platform download-btn" id="dl-mac-x64" href="#" data-loading>
+ <a class="platform download-btn" id="dl-mac-x64" href="#download" data-loading>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden><path d="M17.5 12.6c0-2.4 2-3.6 2.1-3.6-1.1-1.7-2.9-1.9-3.5-1.9-1.5-.2-2.9.9-3.6.9-.8 0-1.9-.9-3.1-.8-1.6 0-3.1.9-3.9 2.4-1.7 2.9-.4 7.2 1.2 9.5.8 1.1 1.7 2.4 2.9 2.4 1.2 0 1.6-.7 3-.7 1.4 0 1.8.7 3 .7 1.3 0 2.1-1.2 2.9-2.3.9-1.3 1.3-2.6 1.3-2.7 0 0-2.4-1-2.4-3.9zm-2.4-7c.6-.8 1.1-1.9 1-3-.9 0-2 .6-2.7 1.4-.6.7-1.1 1.8-1 2.9 1 .1 2-.5 2.7-1.3z"/></svg>
macOS <span class="arch">Intel</span>
</a>
- <a class="platform download-btn" id="dl-win-x64" href="#" data-loading>
+ <a class="platform download-btn" id="dl-win-x64" href="#download" data-loading>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden><path d="M3 5.5L10.5 4v7.5H3V5.5zM11.5 4L21 2.5v9H11.5V4zM3 12.5h7.5V20L3 18.5v-6zM11.5 12.5H21v9l-9.5-1.5v-7.5z"/></svg>
Windows <span class="arch">x64</span>
</a>
- <a class="platform download-btn" id="dl-linux-appimage" href="#" data-loading>
+ <a class="platform download-btn" id="dl-linux-appimage" href="#download" data-loading>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden><path d="M12 1.5l1.4 4.3 4.6.1-3.7 2.7 1.3 4.4L12 10.5l-3.6 2.5 1.3-4.4-3.7-2.7 4.6-.1L12 1.5zm-7 14l1.8 3.2L4 22h16l-1.8-3.3L20 15.5h-7l-1 1.5-1-1.5H5z"/></svg>
Linux <span class="arch">AppImage</span>
</a>
- <a class="platform download-btn" id="dl-linux-deb" href="#" data-loading>
+ <a class="platform download-btn" id="dl-linux-deb" href="#download" data-loading>
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden><path d="M12 1.5l1.4 4.3 4.6.1-3.7 2.7 1.3 4.4L12 10.5l-3.6 2.5 1.3-4.4-3.7-2.7 4.6-.1L12 1.5zm-7 14l1.8 3.2L4 22h16l-1.8-3.3L20 15.5h-7l-1 1.5-1-1.5H5z"/></svg>
Linux <span class="arch">.deb</span>
</a>