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

v2: inconsistent switch states #467

Closed
mpldr opened this issue Feb 23, 2024 · 5 comments · Fixed by #472 or #478
Closed

v2: inconsistent switch states #467

mpldr opened this issue Feb 23, 2024 · 5 comments · Fixed by #472 or #478

Comments

@mpldr
Copy link

mpldr commented Feb 23, 2024

Describe the issue

The switches as shown in the docs have an inconsistency in the "knob position". The off-state has a different "border" width, than the on-state

Current Behavior

2024-02-23-11-42-48

Expected Behavior

Consistent spacing

2024-02-23-11-42-48

Reproduction URL

https://picocss.com/docs/forms/switch

Environment

Reproduced on Firefox and Chromium

Mozilla/5.0 (X11; Linux x86_64; rv:122.0) Gecko/20100101 Firefox/122.0

and

Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36

@mpldr
Copy link
Author

mpldr commented Feb 23, 2024

Subtle, but it really bugs me. And unfortunately I can't unsee it ^^

@lucaslarroche lucaslarroche mentioned this issue Mar 3, 2024
@lucaslarroche lucaslarroche linked a pull request Mar 3, 2024 that will close this issue
@mpldr
Copy link
Author

mpldr commented Mar 3, 2024

I know, this sounds borderline nitpicky, but it's still not the same. Speaking in terms of pixels, the left gap is (on my 1440p monitor at 100% scaling) 3px, while the right one is 4px. Yes, I know this sounds dumb, and it probably is. I have also noticed that the switch isn't a circle, but an oval. It's not 50% either, that is slightly oval in the other direction.

I'm sorry, this feels like such a stupid thing, but it for some reason really bugs me.

@mpldr
Copy link
Author

mpldr commented Mar 3, 2024

Maybe I just shouldn't use a switch…

@lucaslarroche
Copy link
Member

@mpldr, you're right. I looked closer, and the thumb is not round, and the borders are not consistent.
I will publish a patch

@lucaslarroche lucaslarroche mentioned this issue Mar 3, 2024
@lucaslarroche
Copy link
Member

@mpldr, done with v2.0.6

Screen.Recording.2024-03-03.at.22.16.32.mov

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 a pull request may close this issue.

2 participants