Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Marks or Thumb off center #264

Open
nickcanarelli opened this issue Jun 20, 2022 · 2 comments
Open

Marks or Thumb off center #264

nickcanarelli opened this issue Jun 20, 2022 · 2 comments
Labels

Comments

@nickcanarelli
Copy link

nickcanarelli commented Jun 20, 2022

Description

The actual value on the slider is at the beginning of the thumb and not the center? Seems like an odd user experience to think the center is the value when instead its the beginning of the thumb.

When actually centering the thumb and mark to the appropriate value, there is an excess of track at the end.

Steps to reproduce:

  1. Remove:
  left: 50%;
  -webkit-transform: translateX(-50%);
  transform: translateX(-50%);

from .example-thumb

CodeSandbox

Please provide a CodeSandbox that clearly reproduces the issue. Issues without a CodeSandbox are less likely to get resolved quickly.

Edit zillow/react-slider

@axelboc
Copy link

axelboc commented Jun 23, 2022

We found this a bit odd as well, but a simple workaround if to add margin to the track (half of the size of the thumb on either side):

.track {
  0 calc(var(--thumb-size) / 2)
}

@stale
Copy link

stale bot commented Nov 2, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Nov 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants