Skip to content

fix(range): allow clicking the last tick to select the max value - #31652

Open
RaphaelFakhri wants to merge 1 commit into
ionic-team:mainfrom
RaphaelFakhri:fix/range-last-tick-click
Open

RaphaelFakhri wants to merge 1 commit into
ionic-team:mainfrom
RaphaelFakhri:fix/range-last-tick-click

Conversation

@RaphaelFakhri

Copy link
Copy Markdown

Issue number: resolves #30738


What is the current behavior?

ion-range handles clicks and taps on the slider track, and the tick marks set pointer-events: none. The last tick is drawn at the end of the track, so the part of it that sticks out past the track (half the tick in ios mode, all of it in md mode) passes the click to whatever is behind the range. Clicking that part of the last tick does nothing. Widening the ticks with ::part(tick) makes this easy to hit.

What is the new behavior?

  • Ticks receive pointer events in ios and md modes. Ticks are inside the slider element, so a click on any tick reaches the range gesture, and a click on the last tick selects the max value.
  • In md mode, the knob handle sets z-index: 2 so it stays above the ticks (z-index: 1). Without this, pressing the center of the knob hits the tick under it, and the knob handle no longer receives focus.
  • Adds an e2e test that clicks the part of the last tick outside the track and checks that ionChange emits the max value in both modes.

Does this introduce a breaking change?

  • Yes
  • No

Other information

  • The new test fails on main in both modes (no ionChange is emitted) and passes with this change.
  • The existing range screenshot tests in basic, label, states and item produce identical results with and without the md knob handle z-index change.

@RaphaelFakhri
RaphaelFakhri requested a review from a team as a code owner October 24, 2026 19:02
@vercel

vercel Bot commented Oct 24, 2026

Copy link
Copy Markdown

@RaphaelFakhri is attempting to deploy a commit to the Ionic Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions Bot added the package: core @ionic/core package label Oct 24, 2026

This branch has not been deployed

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

Labels

package: core @ionic/core package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: ion-range: Clicking/Tapping on the Last tick doesn't work

1 participant