
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
scroll-zoom-clamp
Advanced tools
This DOM utility prevents zooming components from hijacking mouse-wheel events and interfering with the natural scroll of a page.
By wrapping a child element with this component, wheel events are only propagated downstream if a modifier key is pressed (ctrl or meta key - ⌘, ⊞), otherwise a message is overlayed informing the user to do so by pressing the key.
import ScrollZoomClamp from 'scroll-zoom-clamp';
or using a script tag
<script src="//unpkg.com/scroll-zoom-clamp"></script>
then
// assuming a parentNode and a childNode element
parentNode.appendChild(
new ScrollZoomClamp(childNode).node
);
new ScrollZoomClamp(childNode, { configOptions })
Creates a new scroll zoom protection, wrapped around the childNode
element.
The following configuration options are available:
Config option | Description |
---|---|
message: str | Ability to customize the message shown when the zoom is blocked. Supports plain text or HTML content. |
Type | Attribute | Description |
---|---|---|
Getter | node | Returns the wrapper DOM element. |
If this project has helped you and you'd like to contribute back, you can always buy me a ☕!
FAQs
Prevent page scrolling interference by zooming components
The npm package scroll-zoom-clamp receives a total of 81 weekly downloads. As such, scroll-zoom-clamp popularity was classified as not popular.
We found that scroll-zoom-clamp demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.