diff --git a/.jules/palette.md b/.jules/palette.md index 9e763934..61f4e13e 100644 --- a/.jules/palette.md +++ b/.jules/palette.md @@ -99,3 +99,6 @@ ## 2026-07-01 - Prevent Focus Stealing in Search Filter Buttons **Learning:** In hybrid mouse/keyboard search interfaces (like VS Code Webviews), clicking interactive elements like filter buttons steals DOM focus from the primary search input. This forces users to manually click back into the input or hit Tab before they can resume typing. **Action:** When implementing filter or scope toggle buttons that don't need their own text-input focus, attach a `mousedown` event listener that calls `e.preventDefault()`. This prevents the browser's default focus transition before it even fires, ensuring the user's cursor remains firmly anchored in the main search input. +## 2026-07-02 - ARIA Combobox for Search Results +**Learning:** In custom Webview search interfaces, using keyboard arrow keys to navigate a list of `.result-item` divs visually highlights them, but screen readers remain completely silent because focus never actually moves to the elements. +**Action:** When implementing arrow key navigation for a search input, always use the ARIA Combobox pattern: apply `role="combobox"`, `aria-expanded`, and `aria-activedescendant` to the input, pair it with a `role="listbox"`, and give each result item `role="option"` with a unique ID to ensure screen readers announce the highlighted item. diff --git a/vscode-extension/src/test/suite/reference-code-lens.test.ts b/vscode-extension/src/test/suite/reference-code-lens.test.ts index c8138687..f9c8cf5a 100644 --- a/vscode-extension/src/test/suite/reference-code-lens.test.ts +++ b/vscode-extension/src/test/suite/reference-code-lens.test.ts @@ -109,7 +109,7 @@ suite('ReferenceCodeLens Test Suite', () => { assert.ok(Array.isArray(lenses), 'Should return an array even on error'); }); - test('Provider should provide code lenses for supported symbol kinds', async () => { + test('Provider should provide code lenses for supported symbol kinds', async function () { this.timeout(5000); // Increase timeout for this test as the TS language server can be slow to initialize in CI // Create a test document with a class const testContent = ` diff --git a/vscode-extension/src/webviews/search-view.html b/vscode-extension/src/webviews/search-view.html index a4ce6685..434493d8 100644 --- a/vscode-extension/src/webviews/search-view.html +++ b/vscode-extension/src/webviews/search-view.html @@ -344,12 +344,12 @@ - +
-
+