diff --git a/.jules/palette.md b/.jules/palette.md new file mode 100644 index 0000000..77a34f9 --- /dev/null +++ b/.jules/palette.md @@ -0,0 +1,3 @@ +## 2024-05-06 - Interactive Element Accessibility in Global Navigation +**Learning:** Disclosure widgets (like mobile menus and dropdowns) in global navigation often lack `aria-expanded` attributes, making their state opaque to screen readers. Additionally, icon-only buttons frequently lack explicit focus rings, rendering them inaccessible to keyboard users. +**Action:** Always include `aria-expanded` on any interactive disclosure widget and ensure explicit `focus-visible` styles (e.g., `focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent-500`) are applied to all interactive elements, particularly icon-only buttons. diff --git a/src/components/layout/Navbar.jsx b/src/components/layout/Navbar.jsx index de3fea5..3fee993 100644 --- a/src/components/layout/Navbar.jsx +++ b/src/components/layout/Navbar.jsx @@ -95,7 +95,9 @@ const Navbar = () => {
@@ -180,7 +185,7 @@ const Navbar = () => {
{/* Mobile Navigation */} -
+
{navLinks.map((link) => (