Bug: .glightbox-open hides element overflowing edge of body container
wontfix
**Describe the bug**
A clear and concise description of what the bug is.
The `.glightbox-open` class, which is used to prevent scrolling when glightbox is opened:
https://github.com/biati-digital/glightbox/blob/e52876cf808dbab73419f653e6559b396a35c8df/src/postcss/glightbox.css#L406
is currently being added to both the HTML element and the body element:
https://github.com/biati-digital/glightbox/blob/e52876cf808dbab73419f653e6559b396a35c8df/src/js/glightbox.js#L200
And it hides all elements in body that overflow their container, causing "background flashes" as elements disappear then reappear when opening and closing GLightbox.
Could we either remove the class from the body element (adding it to html should do the trick?), or switch to [`overflow: clip`](https://enlear.academy/the-fastest-way-to-hide-overflow-fb2e2b8183d4) instead?
**Are you able to reproduce the bug in the demo site**
Yes|No.
**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
**Expected behavior**
A clear and concise description of what you expected to happen.
**Post the code you are using**
Help me solve issues faster, if I can copy paste your code I can try to reproduce and fix the bug faster.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Desktop:**
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]
**Smartphone:**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]
1 条评论