New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

tua-body-scroll-lock

Package Overview
Dependencies
Maintainers
2
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tua-body-scroll-lock - npm Package Compare versions

Comparing version 0.2.0-0 to 0.2.0

2

dist/tua-bsl.esm.js
/**
* tua-body-scroll-lock v0.2.0-0
* tua-body-scroll-lock v0.2.0
* (c) 2019 Evinma, BuptStEve

@@ -4,0 +4,0 @@ * @license MIT

/**
* tua-body-scroll-lock v0.2.0-0
* tua-body-scroll-lock v0.2.0
* (c) 2019 Evinma, BuptStEve

@@ -4,0 +4,0 @@ * @license MIT

@@ -1,1 +0,1 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).bodyScrollLock={})}(this,function(e){"use strict";function r(i){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},t=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),t.forEach(function(e){var t,o,n;t=i,n=r[o=e],o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n})}return i}var o,n=0,l=0,i=null,c=!1,s="undefined"==typeof window,d=[],u=!s&&document.querySelector.bind(document);if(!s){var t="__TUA_BSL_TEST_PASSIVE__",f={get passive(){o={passive:!1}}};window.addEventListener(t,null,f),window.removeEventListener(t,null,f)}function a(){var e=navigator.userAgent,t=/(iPad).*OS\s([\d_]+)/.test(e),o=!t&&/(iPhone\sOS)\s([\d_]+)/.test(e),n=/(Android);?[\s/]+([\d.]+)?/.test(e);return{os:n?"android":"ios",ios:o||t,ipad:t,iphone:o,android:n}}function h(e){e.cancelable&&e.preventDefault()}e.lock=function(t){s||(a().ios?(t&&-1===d.indexOf(t)&&(t.ontouchstart=function(e){l=e.targetTouches[0].clientY},t.ontouchmove=function(e){1===e.targetTouches.length&&function(e,t){var o=e.targetTouches[0].clientY-l;if(t){var n=t.scrollTop,i=t.scrollHeight,r=t.clientHeight;if(0<o&&0===n||o<0&&i<=n+r+1)return h(e)}e.stopPropagation()}(e,t)},d.push(t)),c||(document.addEventListener("touchmove",h,o),c=!0)):n<=0&&(i=a().android?function(){var e=u("html"),t=u("body"),o=e.scrollTop||t.scrollTop,n=r({},e.style),i=r({},t.style);return e.style.height="100%",e.style.overflow="hidden",t.style.top="-".concat(o,"px"),t.style.width="100%",t.style.position="fixed",t.style.overflow="hidden",function(){e.style.height=n.height||"",e.style.overflow=n.overflow||"",["top","width","height","overflow","position"].forEach(function(e){t.style[e]=i[e]||""}),window.scrollTo(0,o)}}():function(){var t=u("body"),o=r({},t.style),e=window.innerWidth-document.body.clientWidth;return t.style.overflow="hidden",t.style.boxSizing="border-box",t.style.paddingRight="".concat(e,"px"),function(){["overflow","boxSizing","paddingRight"].forEach(function(e){t.style[e]=o[e]||""})}}()),n+=1)},e.unlock=function(e){if(!(s||0<(n-=1)))if(a().ios){var t=d.indexOf(e);-1!==t&&(e.ontouchmove=null,e.ontouchstart=null,d.splice(t,1)),c&&(document.removeEventListener("touchmove",h,o),c=!1)}else n<=0&&"function"==typeof i&&i()},Object.defineProperty(e,"__esModule",{value:!0})});
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).bodyScrollLock={})}(this,function(e){"use strict";function r(i){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},t=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),t.forEach(function(e){var t,o,n;t=i,n=r[o=e],o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n})}return i}var o,n=0,l=0,i=null,c=!1,s="undefined"==typeof window,d=[],u=!s&&document.querySelector.bind(document);if(!s){var t="__TUA_BSL_TEST_PASSIVE__",f={get passive(){o={passive:!1}}};window.addEventListener(t,null,f),window.removeEventListener(t,null,f)}var a=function(){var e=navigator.userAgent,t=/(iPad).*OS\s([\d_]+)/.test(e),o=!t&&/(iPhone\sOS)\s([\d_]+)/.test(e),n=/(Android);?[\s/]+([\d.]+)?/.test(e);return{os:n?"android":"ios",ios:o||t,ipad:t,iphone:o,android:n}},h=function(e){e.cancelable&&e.preventDefault()};e.lock=function(t){s||(a().ios?(t&&-1===d.indexOf(t)&&(t.ontouchstart=function(e){l=e.targetTouches[0].clientY},t.ontouchmove=function(e){1===e.targetTouches.length&&function(e,t){var o=e.targetTouches[0].clientY-l;if(t){var n=t.scrollTop,i=t.scrollHeight,r=t.clientHeight;if(0<o&&0===n||o<0&&i<=n+r+1)return h(e)}e.stopPropagation()}(e,t)},d.push(t)),c||(document.addEventListener("touchmove",h,o),c=!0)):n<=0&&(i=a().android?function(){var e=u("html"),t=u("body"),o=e.scrollTop||t.scrollTop,n=r({},e.style),i=r({},t.style);return e.style.height="100%",e.style.overflow="hidden",t.style.top="-".concat(o,"px"),t.style.width="100%",t.style.position="fixed",t.style.overflow="hidden",function(){e.style.height=n.height||"",e.style.overflow=n.overflow||"",["top","width","height","overflow","position"].forEach(function(e){t.style[e]=i[e]||""}),window.scrollTo(0,o)}}():function(){var t=u("body"),o=r({},t.style),e=window.innerWidth-document.body.clientWidth;return t.style.overflow="hidden",t.style.boxSizing="border-box",t.style.paddingRight="".concat(e,"px"),function(){["overflow","boxSizing","paddingRight"].forEach(function(e){t.style[e]=o[e]||""})}}()),n+=1)},e.unlock=function(e){if(!(s||0<(n-=1)))if(a().ios){var t=d.indexOf(e);-1!==t&&(e.ontouchmove=null,e.ontouchstart=null,d.splice(t,1)),c&&(document.removeEventListener("touchmove",h,o),c=!1)}else n<=0&&"function"==typeof i&&i()},Object.defineProperty(e,"__esModule",{value:!0})});
{
"name": "tua-body-scroll-lock",
"version": "0.2.0-0",
"version": "0.2.0",
"description": "🔐Body scroll locking that just works with everything",

@@ -5,0 +5,0 @@ "main": "dist/tua-bsl.umd.js",

@@ -95,3 +95,3 @@ # tua-body-scroll-lock

<!-- prettier-ignore -->
<table><tr><td align="center"><a href="https://github.com/evinma"><img src="https://avatars2.githubusercontent.com/u/16096567?v=4" width="100px;" alt="evinma"/><br /><sub><b>evinma</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Documentation">📖</a></td><td align="center"><a href="https://buptsteve.github.io"><img src="https://avatars2.githubusercontent.com/u/11501493?v=4" width="100px;" alt="StEve Young"/><br /><sub><b>StEve Young</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=BuptStEve" title="Documentation">📖</a> <a href="#infra-BuptStEve" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a></td><td align="center"><a href="https://github.com/li2go"><img src="https://avatars2.githubusercontent.com/u/11485337?v=4" width="100px;" alt="li2go"/><br /><sub><b>li2go</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Ali2go" title="Bug reports">🐛</a></td><td align="center"><a href="https://github.com/feitiange"><img src="https://avatars3.githubusercontent.com/u/7125157?v=4" width="100px;" alt="songyan,Wang"/><br /><sub><b>songyan,Wang</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Afeitiange" title="Bug reports">🐛</a></td></tr></table>
<table><tr><td align="center"><a href="https://github.com/evinma"><img src="https://avatars2.githubusercontent.com/u/16096567?v=4" width="100px;" alt="evinma"/><br /><sub><b>evinma</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Documentation">📖</a> <a href="#infra-evinma" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a> <a href="#translation-evinma" title="Translation">🌍</a></td><td align="center"><a href="https://buptsteve.github.io"><img src="https://avatars2.githubusercontent.com/u/11501493?v=4" width="100px;" alt="StEve Young"/><br /><sub><b>StEve Young</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=BuptStEve" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=BuptStEve" title="Documentation">📖</a> <a href="#infra-BuptStEve" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a> <a href="#translation-BuptStEve" title="Translation">🌍</a></td><td align="center"><a href="https://github.com/li2go"><img src="https://avatars2.githubusercontent.com/u/11485337?v=4" width="100px;" alt="li2go"/><br /><sub><b>li2go</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=li2go" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Ali2go" title="Bug reports">🐛</a></td><td align="center"><a href="https://github.com/feitiange"><img src="https://avatars3.githubusercontent.com/u/7125157?v=4" width="100px;" alt="songyan,Wang"/><br /><sub><b>songyan,Wang</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=feitiange" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Afeitiange" title="Bug reports">🐛</a></td></tr></table>

@@ -98,0 +98,0 @@ <!-- ALL-CONTRIBUTORS-LIST:END -->

@@ -95,3 +95,3 @@ # tua-body-scroll-lock

<!-- prettier-ignore -->
<table><tr><td align="center"><a href="https://github.com/evinma"><img src="https://avatars2.githubusercontent.com/u/16096567?v=4" width="100px;" alt="evinma"/><br /><sub><b>evinma</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Documentation">📖</a></td><td align="center"><a href="https://buptsteve.github.io"><img src="https://avatars2.githubusercontent.com/u/11501493?v=4" width="100px;" alt="StEve Young"/><br /><sub><b>StEve Young</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=BuptStEve" title="Documentation">📖</a> <a href="#infra-BuptStEve" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a></td><td align="center"><a href="https://github.com/li2go"><img src="https://avatars2.githubusercontent.com/u/11485337?v=4" width="100px;" alt="li2go"/><br /><sub><b>li2go</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Ali2go" title="Bug reports">🐛</a></td><td align="center"><a href="https://github.com/feitiange"><img src="https://avatars3.githubusercontent.com/u/7125157?v=4" width="100px;" alt="songyan,Wang"/><br /><sub><b>songyan,Wang</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Afeitiange" title="Bug reports">🐛</a></td></tr></table>
<table><tr><td align="center"><a href="https://github.com/evinma"><img src="https://avatars2.githubusercontent.com/u/16096567?v=4" width="100px;" alt="evinma"/><br /><sub><b>evinma</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=evinma" title="Documentation">📖</a> <a href="#infra-evinma" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a> <a href="#translation-evinma" title="Translation">🌍</a></td><td align="center"><a href="https://buptsteve.github.io"><img src="https://avatars2.githubusercontent.com/u/11501493?v=4" width="100px;" alt="StEve Young"/><br /><sub><b>StEve Young</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=BuptStEve" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=BuptStEve" title="Documentation">📖</a> <a href="#infra-BuptStEve" title="Infrastructure (Hosting, Build-Tools, etc)">🚇</a> <a href="#translation-BuptStEve" title="Translation">🌍</a></td><td align="center"><a href="https://github.com/li2go"><img src="https://avatars2.githubusercontent.com/u/11485337?v=4" width="100px;" alt="li2go"/><br /><sub><b>li2go</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=li2go" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Ali2go" title="Bug reports">🐛</a></td><td align="center"><a href="https://github.com/feitiange"><img src="https://avatars3.githubusercontent.com/u/7125157?v=4" width="100px;" alt="songyan,Wang"/><br /><sub><b>songyan,Wang</b></sub></a><br /><a href="https://github.com/tuateam/tua-body-scroll-lock/commits?author=feitiange" title="Code">💻</a> <a href="https://github.com/tuateam/tua-body-scroll-lock/issues?q=author%3Afeitiange" title="Bug reports">🐛</a></td></tr></table>

@@ -98,0 +98,0 @@ <!-- ALL-CONTRIBUTORS-LIST:END -->

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc