Skip to content

fix: Increase pointer target of expandable section navigation trigger - #4876

Open
Harsh-Anand-Singh wants to merge 5 commits into
mainfrom
fix-expandable-navigation-pointer-target
Open

fix: Increase pointer target of expandable section navigation trigger#4876
Harsh-Anand-Singh wants to merge 5 commits into
mainfrom
fix-expandable-navigation-pointer-target

Conversation

@Harsh-Anand-Singh

@Harsh-Anand-Singh Harsh-Anand-Singh commented Aug 6, 2026

Copy link
Copy Markdown
Member

Description

The expand chevron in the expandable section navigation variant (used by side navigation expandable link groups) has a ~12px pointer target, failing WCAG 2.5.8 Target Size (Minimum, 24x24px).

The header wrapper already shows cursor: pointer but had no click handler. This change makes it handle pointer clicks, deferring to interactive descendants (expand button, header link), so the effective target becomes the whole header row.

Related links, issue #, if available: n/a

How has this been tested?

  • All existing unit tests for expandable-section and side-navigation pass
  • Verified in browser (one-theme, side navigation permutations): dead-space clicks toggle, button click toggles once, link click navigates without toggling, nothing extends outside the component
Review checklist

The following items are to be evaluated by the author(s) and the reviewer(s).

Correctness

  • Changes include appropriate documentation updates.
  • Changes are backward-compatible if not indicated, see CONTRIBUTING.md.
  • Changes do not include unsupported browser features, see CONTRIBUTING.md.
  • Changes were manually tested for accessibility, see accessibility guidelines.

Security

Testing

  • Changes are covered with new/existing unit tests?
  • Changes are covered with new/existing integration tests?

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@codecov

codecov Bot commented Aug 6, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.64%. Comparing base (523ea64) to head (7e8857d).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4876   +/-   ##
=======================================
  Coverage   97.64%   97.64%           
=======================================
  Files         958      958           
  Lines       31238    31242    +4     
  Branches    11530    11531    +1     
=======================================
+ Hits        30501    30505    +4     
  Misses        690      690           
  Partials       47       47           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread src/expandable-section/styles.scss Outdated

@SpyZzey SpyZzey left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this approach might have two flaws:

  1. It's inconsistent and not transparent to the user. The behavior can change depending content without a visual clue (might need to be checked with a designer).
  2. The accessibility issue still persists for places where there is a button or link inside the expandable section.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants