Comments (14)
@FL3NKEY thanks for the recommendation. We want to use the library for a large React app, so abstraction is a minimum requirement. However, this is not possible due to the fixed CSS class names. This means that the library cannot simply be replaced later if problems arise.
I'm on my way to the React Conference in Amsterdam/NL. When I get back I'll take care of the PR.
from body-scroll-lock.
thanks for the code - happy for you to create the PR.
Once you create it, I'll try to have it reviewed quickly.
from body-scroll-lock.
You are welcome.
https://github.com/FL3NKEY/scroll-lock
from body-scroll-lock.
Can't wait for the PR. I need this as well! :)
@martinkutter Any progress?
from body-scroll-lock.
@martinkutter updated, check out 🤗
from body-scroll-lock.
Sorry for the delay. Let me look at the solution from @FL3NKEY next week and I'll get back to you.
from body-scroll-lock.
@martinkutter 👍 let me know how it goes - if you end up not putting a PR through, I'll adapt your suggestion and create a PR for body-scroll-lock.
from body-scroll-lock.
Thanks for your patience 😅. I created a PR. #14
@willmcpo please have a look and if everything fits I would be happy about a suggestion for the docs.
from body-scroll-lock.
@martinkutter what's the problem using my library?
from body-scroll-lock.
@FL3NKEY As I mentioned before, we use this library in a large React application based on plugins. For example, a normal use case is that one component activates the scrolllock, then a second component is mounted, which also activates the scrolllock. If the first component deactivates the scrolllock, it is not considered that it is still needed by the second component. So I decided to continue using this library, which can handle it correctly.
from body-scroll-lock.
@martinkutter oh, i got it, work at that 🤗
from body-scroll-lock.
from body-scroll-lock.
@martinkutter thanks I've reviewed it and no problems with the delay 👍
from body-scroll-lock.
PR #14 pending minor change and then will merge
from body-scroll-lock.
Related Issues (20)
- Header Logo doesn't change to stacked version on Mobile
- Scroll bar width calculated incorrectly HOT 3
- Enabling and clearing body scroll don't work on iOS 15.1
- The scroll lock does not work if you swipe with two fingers at the same time
- Still able to scroll HOT 5
- Doesn't seem to lock HTML tag scrolling HOT 2
- iOS Devices: "restorePositionSetting" can run before "setPositionFixed"
- Inset of iOS devices is scrollable on modals HOT 1
- The content is twitching 15px from the right on MacOS Safari HOT 3
- Black bar at bottom when safari toolbar is hidden on iOS 15
- The package is not tree-shakeable due to side-effects
- Is this package dead/abandoned? HOT 18
- Define a custom base element (not body) HOT 1
- iOS 16 Safari has width/size issues with wide content HOT 2
- This fork from vercel seems to fix some issues HOT 1
- Add example using React hooks HOT 1
- On IOS disableBodyScroll() makes element.scrollIntoView() not working HOT 1
- ESM build broken, causes scroll-to-top on iOS HOT 3
- Using logical css property instead of padding-right
- scroll reset happens when use disableBodyScroll HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from body-scroll-lock.