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

Display issue when parent element is using display: inline-flex or display: flex #776

Open
tmszb opened this issue Feb 17, 2022 · 2 comments

Comments

@tmszb
Copy link

tmszb commented Feb 17, 2022

Hi,

There is an issue when using range slider when a container has display: inline-flex or display: flex CSS rule.

When this happens range slider's width looks like it would be set to 0. Elements are displayed but are squeezed.

I used exisiting example from contributing guidelines here: https://jsfiddle.net/IonDen/b79q0vnm and added display: inline-flex to show this behavior: https://jsfiddle.net/16jvpk8d/

@tmszb tmszb changed the title Display issue when parent element is using display: inline-flex Display issue when parent element is using display: inline-flex or display: flex Feb 17, 2022
@tmszb
Copy link
Author

tmszb commented Feb 17, 2022

This is how it looks:

range-slider

@tmszb
Copy link
Author

tmszb commented Feb 17, 2022

FYI - I found a workaround.

Setting flex-basis with a value of own choice on .irs class seems to fix the issue.

The other solution is to use width: 100% on the same class but only if it is set to 100%. Other values causes another unexpected behavior.

I am not sure however if any of the above solutions affects different scenarios of using this range slider.

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

No branches or pull requests

1 participant