react-component / react-component/slider

draggableTrack does not respect step prop

Open
#733 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
3.1k
Forks
768
Avg merge
11d 22h
Merged PRs (30d)
5

Description

draggableTrack, added in #722, doesn't respect the step prop, instead allowing users to drag the track to any value.

For example (see also this Codepen):

<Range
  allowCross={ false }
  draggableTrack
  max={100}
  min={0}
  step={5}
/>

This will only allow dragging the endpoints to multiples of 5, but the track can be dragged to other values; i.e. set to 0-10, then drag the track to 2-12.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with the Range example in the report or its linked CodePen, then trace the draggableTrack handling and how it applies the step prop. Done means dragging a track whose step is 5 keeps both endpoints on multiples of 5, matching endpoint dragging.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.