Skip to content

a11y: PropertyCard nests buttons inside an <a>, breaking keyboard semantics #453

Description

@nanaf6203-bit

Summary

The whole PropertyCard is wrapped in a <Link>. Inner clickable elements (cart, favourite, compare toggle, "View") have stopPropagation but no equivalent in the keyboard activation model, leading to nested-interactive-element violations and screen readers being confused about how to focus.

Affected area

src/components/PropertyCard.tsx

Steps to reproduce

Tab into a card; focus moves to the <a> first, then elements inside have ambiguous tabindex; keyboard Enter on the inner buttons can both activate the link AND the inner button.

Expected behaviour

Make the card a <article> and provide an explicit "View details" link plus standalone buttons for cart/favorite/compare.

Acceptance criteria

  • Removing nested-interactive violations in axe-core.
  • Document the new interaction pattern.
  • Visual regression test keeps the layout.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programaccessibilityAccessibility (a11y) issuepriority/p1P1 — high priority, fix soon

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions