🎨 Palette: Keyboard Accessibility for Interactive Cards#39
Conversation
Added `role="button"`, `tabIndex={0}`, and an `onKeyDown` handler to
`ProjectCard.jsx` and `ExperienceCard.jsx` to make the clickable
`motion.div` components accessible to keyboard users. Also added
`focus-visible:ring-2` styles to provide a visual focus indicator.
Included a journal entry in `.Jules/palette.md` to document this
learning. Fixed an ESLint configuration issue, a Vite configuration
issue, and a CSS import issue to ensure the build and linting pass.
Co-authored-by: Dev22603 <92785712+Dev22603@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. |
✅ Deploy Preview for dev-bachani ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
💡 What:
Added full keyboard accessibility to
ProjectCardandExperienceCardcomponents.🎯 Why:
The cards were interactive and clickable but used
div/motion.divelements. This made them inaccessible to users who rely on keyboards or assistive technologies, as they couldn't focus or activate the cards. By adding the correct ARIA role, tabIndex, and keydown handlers, we ensure all users can explore the portfolio's experiences and projects.📸 Before/After:
EnterorSpaceto open the card modal or link.♿ Accessibility:
role="button"to denote the element's interactive nature.tabIndex={0}to make the element focusable in sequential keyboard navigation.onKeyDownhandler to trigger theonClickaction onEnterorSpacekey presses.focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-primary)]for visual focus indication.Other Fixes:
@importabove@import "tailwindcss"inindex.css.__dirnamein a module environment.framer-motionimports as unused variables.PR created automatically by Jules for task 8712607938366300604 started by @Dev22603