🎨 Palette: Make Asset Upload Buttons Keyboard Accessible#265
🎨 Palette: Make Asset Upload Buttons Keyboard Accessible#265thebearwithabite wants to merge 1 commit into
Conversation
Co-authored-by: thebearwithabite <216692431+thebearwithabite@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
There was a problem hiding this comment.
Pull request overview
This PR improves keyboard accessibility for asset upload/replace controls in the VEO Asset Library by making the hidden file inputs focusable again and visually revealing their custom label UI on keyboard focus. It also includes a pnpm-lock.yaml update (including @microsoft/eslint-formatter-sarif) and a Palette journal entry documenting the accessibility pattern.
Changes:
- Updated
AssetLibrary.tsxfile inputs fromhidden→sr-onlyand addedfocus-withinstyles on wrapping labels to display focus rings / reveal hover-only UI for keyboard users. - Updated
frontend_v2/pnpm-lock.yamlto include@microsoft/eslint-formatter-sarifand its dependency graph. - Added a new Palette journal entry capturing the “hidden file input in label wrapper” accessibility lesson and recommended Tailwind classes.
Reviewed changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| frontend_v2/src/components/veo/AssetLibrary.tsx | Restores keyboard focusability for upload/replace file inputs and adds focus-visible styling via focus-within on labels. |
| frontend_v2/pnpm-lock.yaml | Adds SARIF ESLint formatter (and pulls in an additional deprecated ESLint major version). |
| .jules/palette.md | Documents the accessibility learning/action for hidden file input wrappers. |
Files not reviewed (1)
- frontend_v2/pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <input | ||
| type="file" | ||
| className="hidden" | ||
| className="sr-only" |
| '@eslint/js': | ||
| specifier: ^9.39.1 | ||
| version: 9.39.2 | ||
| '@microsoft/eslint-formatter-sarif': | ||
| specifier: ^3.1.0 | ||
| version: 3.1.0 |
| eslint@8.57.1: | ||
| resolution: {integrity: sha512-ypowyDxpVSYpkXr9WPv2PAZCtNip1Mv5KTW0SCurXv/9iOpcrH9PaqUElksqEB6pChqHGDRCFTyrZlGhnLNGiA==} | ||
| engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} | ||
| deprecated: This version is no longer supported. Please see https://eslint.org/version-support for other options. | ||
| hasBin: true | ||
|
|
💡 What: Changed file input classes from
hiddentosr-onlyand addedfocus-withinstyles to their parent labels inAssetLibrary.tsx.🎯 Why: Previously, the upload and replace buttons on asset cards were completely inaccessible to keyboard users because
hiddenremoved the inputs from the tab order, and the custom labels only appeared on mouse hover.📸 Before/After: Upload buttons now appear and show a clear focus ring when navigating to an asset card via the Tab key.
♿ Accessibility: Restored the file inputs to the accessibility tree and ensured custom UI wrappers visually reveal themselves when their internal inputs receive focus, complying with WCAG 2.1 SC 2.1.1 (Keyboard).
PR created automatically by Jules for task 5093219214749351141 started by @thebearwithabite