@vitus-labs/hooks 0.44.0 → 0.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.browser.js","children":[{"name":"src","children":[{"uid":"e6f6-41","name":"useHover.ts"},{"uid":"e6f6-43","name":"useWindowResize.ts"},{"uid":"e6f6-45","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"e6f6-41":{"renderedLength":333,"gzipLength":179,"brotliLength":0,"mainUid":"e6f6-40"},"e6f6-43":{"renderedLength":635,"gzipLength":313,"brotliLength":0,"mainUid":"e6f6-42"},"e6f6-45":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e6f6-44"}},"nodeMetas":{"e6f6-40":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.browser.js":"e6f6-41"},"imported":[{"uid":"e6f6-46"}],"importedBy":[{"uid":"e6f6-44"}]},"e6f6-42":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.browser.js":"e6f6-43"},"imported":[{"uid":"e6f6-46"},{"uid":"e6f6-47"}],"importedBy":[{"uid":"e6f6-44"}]},"e6f6-44":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.browser.js":"e6f6-45"},"imported":[{"uid":"e6f6-40"},{"uid":"e6f6-42"}],"importedBy":[],"isEntry":true},"e6f6-46":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-40"},{"uid":"e6f6-42"}],"isExternal":true},"e6f6-47":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-42"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.browser.js","children":[{"name":"src","children":[{"uid":"93c3-41","name":"useHover.ts"},{"uid":"93c3-43","name":"useWindowResize.ts"},{"uid":"93c3-45","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"93c3-41":{"renderedLength":333,"gzipLength":179,"brotliLength":0,"mainUid":"93c3-40"},"93c3-43":{"renderedLength":635,"gzipLength":313,"brotliLength":0,"mainUid":"93c3-42"},"93c3-45":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"93c3-44"}},"nodeMetas":{"93c3-40":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.browser.js":"93c3-41"},"imported":[{"uid":"93c3-46"}],"importedBy":[{"uid":"93c3-44"}]},"93c3-42":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.browser.js":"93c3-43"},"imported":[{"uid":"93c3-46"},{"uid":"93c3-47"}],"importedBy":[{"uid":"93c3-44"}]},"93c3-44":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.browser.js":"93c3-45"},"imported":[{"uid":"93c3-40"},{"uid":"93c3-42"}],"importedBy":[],"isEntry":true},"93c3-46":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-40"},{"uid":"93c3-42"}],"isExternal":true},"93c3-47":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-42"}],"isExternal":true}},"env":{"rollup":"2.70.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.js","children":[{"name":"src","children":[{"uid":"e6f6-1","name":"useHover.ts"},{"uid":"e6f6-3","name":"useWindowResize.ts"},{"uid":"e6f6-5","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"e6f6-1":{"renderedLength":351,"gzipLength":184,"brotliLength":0,"mainUid":"e6f6-0"},"e6f6-3":{"renderedLength":486,"gzipLength":267,"brotliLength":0,"mainUid":"e6f6-2"},"e6f6-5":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e6f6-4"}},"nodeMetas":{"e6f6-0":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.js":"e6f6-1"},"imported":[{"uid":"e6f6-6"}],"importedBy":[{"uid":"e6f6-4"}]},"e6f6-2":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.js":"e6f6-3"},"imported":[{"uid":"e6f6-6"},{"uid":"e6f6-7"}],"importedBy":[{"uid":"e6f6-4"}]},"e6f6-4":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.js":"e6f6-5"},"imported":[{"uid":"e6f6-0"},{"uid":"e6f6-2"}],"importedBy":[],"isEntry":true},"e6f6-6":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-0"},{"uid":"e6f6-2"}],"isExternal":true},"e6f6-7":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-2"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.js","children":[{"name":"src","children":[{"uid":"93c3-1","name":"useHover.ts"},{"uid":"93c3-3","name":"useWindowResize.ts"},{"uid":"93c3-5","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"93c3-1":{"renderedLength":351,"gzipLength":184,"brotliLength":0,"mainUid":"93c3-0"},"93c3-3":{"renderedLength":486,"gzipLength":267,"brotliLength":0,"mainUid":"93c3-2"},"93c3-5":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"93c3-4"}},"nodeMetas":{"93c3-0":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.js":"93c3-1"},"imported":[{"uid":"93c3-6"}],"importedBy":[{"uid":"93c3-4"}]},"93c3-2":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.js":"93c3-3"},"imported":[{"uid":"93c3-6"},{"uid":"93c3-7"}],"importedBy":[{"uid":"93c3-4"}]},"93c3-4":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.js":"93c3-5"},"imported":[{"uid":"93c3-0"},{"uid":"93c3-2"}],"importedBy":[],"isEntry":true},"93c3-6":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-0"},{"uid":"93c3-2"}],"isExternal":true},"93c3-7":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-2"}],"isExternal":true}},"env":{"rollup":"2.70.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.module.js","children":[{"name":"src","children":[{"uid":"e6f6-9","name":"useHover.ts"},{"uid":"e6f6-11","name":"useWindowResize.ts"},{"uid":"e6f6-13","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"e6f6-9":{"renderedLength":333,"gzipLength":179,"brotliLength":0,"mainUid":"e6f6-8"},"e6f6-11":{"renderedLength":609,"gzipLength":301,"brotliLength":0,"mainUid":"e6f6-10"},"e6f6-13":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e6f6-12"}},"nodeMetas":{"e6f6-8":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.module.js":"e6f6-9"},"imported":[{"uid":"e6f6-14"}],"importedBy":[{"uid":"e6f6-12"}]},"e6f6-10":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.module.js":"e6f6-11"},"imported":[{"uid":"e6f6-14"},{"uid":"e6f6-15"}],"importedBy":[{"uid":"e6f6-12"}]},"e6f6-12":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.module.js":"e6f6-13"},"imported":[{"uid":"e6f6-8"},{"uid":"e6f6-10"}],"importedBy":[],"isEntry":true},"e6f6-14":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-8"},{"uid":"e6f6-10"}],"isExternal":true},"e6f6-15":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-10"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.module.js","children":[{"name":"src","children":[{"uid":"93c3-9","name":"useHover.ts"},{"uid":"93c3-11","name":"useWindowResize.ts"},{"uid":"93c3-13","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"93c3-9":{"renderedLength":333,"gzipLength":179,"brotliLength":0,"mainUid":"93c3-8"},"93c3-11":{"renderedLength":609,"gzipLength":301,"brotliLength":0,"mainUid":"93c3-10"},"93c3-13":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"93c3-12"}},"nodeMetas":{"93c3-8":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.module.js":"93c3-9"},"imported":[{"uid":"93c3-14"}],"importedBy":[{"uid":"93c3-12"}]},"93c3-10":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.module.js":"93c3-11"},"imported":[{"uid":"93c3-14"},{"uid":"93c3-15"}],"importedBy":[{"uid":"93c3-12"}]},"93c3-12":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.module.js":"93c3-13"},"imported":[{"uid":"93c3-8"},{"uid":"93c3-10"}],"importedBy":[],"isEntry":true},"93c3-14":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-8"},{"uid":"93c3-10"}],"isExternal":true},"93c3-15":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-10"}],"isExternal":true}},"env":{"rollup":"2.70.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.native.js","children":[{"name":"src","children":[{"uid":"e6f6-17","name":"useHover.ts"},{"uid":"e6f6-19","name":"useWindowResize.ts"},{"uid":"e6f6-21","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"e6f6-17":{"renderedLength":333,"gzipLength":179,"brotliLength":0,"mainUid":"e6f6-16"},"e6f6-19":{"renderedLength":635,"gzipLength":313,"brotliLength":0,"mainUid":"e6f6-18"},"e6f6-21":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e6f6-20"}},"nodeMetas":{"e6f6-16":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.native.js":"e6f6-17"},"imported":[{"uid":"e6f6-22"}],"importedBy":[{"uid":"e6f6-20"}]},"e6f6-18":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.native.js":"e6f6-19"},"imported":[{"uid":"e6f6-22"},{"uid":"e6f6-23"}],"importedBy":[{"uid":"e6f6-20"}]},"e6f6-20":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.native.js":"e6f6-21"},"imported":[{"uid":"e6f6-16"},{"uid":"e6f6-18"}],"importedBy":[],"isEntry":true},"e6f6-22":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-16"},{"uid":"e6f6-18"}],"isExternal":true},"e6f6-23":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-18"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.native.js","children":[{"name":"src","children":[{"uid":"93c3-17","name":"useHover.ts"},{"uid":"93c3-19","name":"useWindowResize.ts"},{"uid":"93c3-21","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"93c3-17":{"renderedLength":333,"gzipLength":179,"brotliLength":0,"mainUid":"93c3-16"},"93c3-19":{"renderedLength":635,"gzipLength":313,"brotliLength":0,"mainUid":"93c3-18"},"93c3-21":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"93c3-20"}},"nodeMetas":{"93c3-16":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.native.js":"93c3-17"},"imported":[{"uid":"93c3-22"}],"importedBy":[{"uid":"93c3-20"}]},"93c3-18":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.native.js":"93c3-19"},"imported":[{"uid":"93c3-22"},{"uid":"93c3-23"}],"importedBy":[{"uid":"93c3-20"}]},"93c3-20":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.native.js":"93c3-21"},"imported":[{"uid":"93c3-16"},{"uid":"93c3-18"}],"importedBy":[],"isEntry":true},"93c3-22":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-16"},{"uid":"93c3-18"}],"isExternal":true},"93c3-23":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-18"}],"isExternal":true}},"env":{"rollup":"2.70.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.umd.js","children":[{"name":"src","children":[{"uid":"e6f6-25","name":"useHover.ts"},{"uid":"e6f6-27","name":"useWindowResize.ts"},{"uid":"e6f6-29","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"e6f6-25":{"renderedLength":371,"gzipLength":186,"brotliLength":0,"mainUid":"e6f6-24"},"e6f6-27":{"renderedLength":514,"gzipLength":269,"brotliLength":0,"mainUid":"e6f6-26"},"e6f6-29":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e6f6-28"}},"nodeMetas":{"e6f6-24":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.umd.js":"e6f6-25"},"imported":[{"uid":"e6f6-30"}],"importedBy":[{"uid":"e6f6-28"}]},"e6f6-26":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.umd.js":"e6f6-27"},"imported":[{"uid":"e6f6-30"},{"uid":"e6f6-31"}],"importedBy":[{"uid":"e6f6-28"}]},"e6f6-28":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.umd.js":"e6f6-29"},"imported":[{"uid":"e6f6-24"},{"uid":"e6f6-26"}],"importedBy":[],"isEntry":true},"e6f6-30":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-24"},{"uid":"e6f6-26"}],"isExternal":true},"e6f6-31":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-26"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.umd.js","children":[{"name":"src","children":[{"uid":"93c3-25","name":"useHover.ts"},{"uid":"93c3-27","name":"useWindowResize.ts"},{"uid":"93c3-29","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"93c3-25":{"renderedLength":371,"gzipLength":186,"brotliLength":0,"mainUid":"93c3-24"},"93c3-27":{"renderedLength":514,"gzipLength":269,"brotliLength":0,"mainUid":"93c3-26"},"93c3-29":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"93c3-28"}},"nodeMetas":{"93c3-24":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.umd.js":"93c3-25"},"imported":[{"uid":"93c3-30"}],"importedBy":[{"uid":"93c3-28"}]},"93c3-26":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.umd.js":"93c3-27"},"imported":[{"uid":"93c3-30"},{"uid":"93c3-31"}],"importedBy":[{"uid":"93c3-28"}]},"93c3-28":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.umd.js":"93c3-29"},"imported":[{"uid":"93c3-24"},{"uid":"93c3-26"}],"importedBy":[],"isEntry":true},"93c3-30":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-24"},{"uid":"93c3-26"}],"isExternal":true},"93c3-31":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-26"}],"isExternal":true}},"env":{"rollup":"2.70.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.umd.min.js","children":[{"name":"src","children":[{"uid":"e6f6-33","name":"useHover.ts"},{"uid":"e6f6-35","name":"useWindowResize.ts"},{"uid":"e6f6-37","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"e6f6-33":{"renderedLength":371,"gzipLength":186,"brotliLength":0,"mainUid":"e6f6-32"},"e6f6-35":{"renderedLength":514,"gzipLength":269,"brotliLength":0,"mainUid":"e6f6-34"},"e6f6-37":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"e6f6-36"}},"nodeMetas":{"e6f6-32":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.umd.min.js":"e6f6-33"},"imported":[{"uid":"e6f6-38"}],"importedBy":[{"uid":"e6f6-36"}]},"e6f6-34":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.umd.min.js":"e6f6-35"},"imported":[{"uid":"e6f6-38"},{"uid":"e6f6-39"}],"importedBy":[{"uid":"e6f6-36"}]},"e6f6-36":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.umd.min.js":"e6f6-37"},"imported":[{"uid":"e6f6-32"},{"uid":"e6f6-34"}],"importedBy":[],"isEntry":true},"e6f6-38":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-32"},{"uid":"e6f6-34"}],"isExternal":true},"e6f6-39":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"e6f6-34"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-hooks.umd.min.js","children":[{"name":"src","children":[{"uid":"93c3-33","name":"useHover.ts"},{"uid":"93c3-35","name":"useWindowResize.ts"},{"uid":"93c3-37","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"93c3-33":{"renderedLength":371,"gzipLength":186,"brotliLength":0,"mainUid":"93c3-32"},"93c3-35":{"renderedLength":514,"gzipLength":269,"brotliLength":0,"mainUid":"93c3-34"},"93c3-37":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"93c3-36"}},"nodeMetas":{"93c3-32":{"id":"/src/useHover.ts","moduleParts":{"vitus-labs-hooks.umd.min.js":"93c3-33"},"imported":[{"uid":"93c3-38"}],"importedBy":[{"uid":"93c3-36"}]},"93c3-34":{"id":"/src/useWindowResize.ts","moduleParts":{"vitus-labs-hooks.umd.min.js":"93c3-35"},"imported":[{"uid":"93c3-38"},{"uid":"93c3-39"}],"importedBy":[{"uid":"93c3-36"}]},"93c3-36":{"id":"/src/index.ts","moduleParts":{"vitus-labs-hooks.umd.min.js":"93c3-37"},"imported":[{"uid":"93c3-32"},{"uid":"93c3-34"}],"importedBy":[],"isEntry":true},"93c3-38":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-32"},{"uid":"93c3-34"}],"isExternal":true},"93c3-39":{"id":"@vitus-labs/core","moduleParts":{},"imported":[],"importedBy":[{"uid":"93c3-34"}],"isExternal":true}},"env":{"rollup":"2.70.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-hooks.browser.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":[],"mappings":";;;MAQM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK;IACzC,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAE9C,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;IACzD,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;QACL,YAAY,EAAE,QAAQ;QACtB,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;MCLM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE;IAE9B,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAe,MAAM,CAAC,UAAU,CAAQ;QAC7C,MAAM,EAAe,MAAM,CAAC,WAAW,CAAS;KACjD,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAErD,MAAM,YAAY,GAAG,QAAQ,CAAC;QAC5B,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,CAAC,CAAA;IAEjB,SAAS,CAAC;QAGR,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;QAEtD,OAAO,MAAM,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;KACvE,EAAE,EAAE,CAAC,CAAA;IAEN,OAAO,UAAU,CAAA;AACnB;;;;"}
1
+ {"version":3,"file":"vitus-labs-hooks.browser.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":[],"mappings":";;;AAQA,MAAM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK,KAAI;IAC7C,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AAE9C,IAAA,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;AACzD,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;AACL,QAAA,YAAY,EAAE,QAAQ;AACtB,QAAA,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;ACLA,MAAM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE,KAC5B;AACF,IAAA,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAe,MAAM,CAAC,UAAU,CAAQ;QAC7C,MAAM,EAAe,MAAM,CAAC,WAAW,CAAS;AACjD,KAAA,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AAErD,IAAA,MAAM,YAAY,GAAG,QAAQ,CAAC,MAAK;AACjC,QAAA,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,CAAC,CAAA;IAEjB,SAAS,CAAC,MAAK;QAGb,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;AAEtD,QAAA,OAAO,MAAM,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;AACxE,KAAC,EAAE,EAAE,CAAC,CAAA;AAEN,IAAA,OAAO,UAAU,CAAA;AACnB;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-hooks.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":["useState","useCallback","throttle","useEffect"],"mappings":";;;;;;;MAQM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK;IACzC,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAGA,cAAQ,CAAC,OAAO,CAAC,CAAA;IAE9C,MAAM,QAAQ,GAAGC,iBAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;IACzD,MAAM,UAAU,GAAGA,iBAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;QACL,YAAY,EAAE,QAAQ;QACtB,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;MCLM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE;IAE9B,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAmC,KAAK;QAC7C,MAAM,EAAoC,MAAM;KACjD,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAGD,cAAQ,CAAC,OAAO,CAAC,CAAA;IAEhCE,aAAQ,CAAC;QAC5B,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,EAAC;IAEjBC,eAAS,CAAC;QACQ,OAAO,SAAS,CAAA;KAKjC,EAAE,EAAE,CAAC,CAAA;IAEN,OAAO,UAAU,CAAA;AACnB;;;;;"}
1
+ {"version":3,"file":"vitus-labs-hooks.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":["useState","useCallback","throttle","useEffect"],"mappings":";;;;;;;AAQA,MAAM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK,KAAI;IAC7C,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAGA,cAAQ,CAAC,OAAO,CAAC,CAAA;AAE9C,IAAA,MAAM,QAAQ,GAAGC,iBAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;AACzD,IAAA,MAAM,UAAU,GAAGA,iBAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;AACL,QAAA,YAAY,EAAE,QAAQ;AACtB,QAAA,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;ACLA,MAAM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE,KAC5B;AACF,IAAA,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAmC,KAAK;QAC7C,MAAM,EAAoC,MAAM;AACjD,KAAA,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAGD,cAAQ,CAAC,OAAO,CAAC,CAAA;AAErD,IAAqBE,aAAQ,CAAC,MAAK;AACjC,QAAA,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,EAAC;IAEjBC,eAAS,CAAC,MAAK;AACb,QAAgB,OAAO,SAAS,CAAA;AAKlC,KAAC,EAAE,EAAE,CAAC,CAAA;AAEN,IAAA,OAAO,UAAU,CAAA;AACnB;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-hooks.module.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":[],"mappings":";;;MAQM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK;IACzC,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAE9C,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;IACzD,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;QACL,YAAY,EAAE,QAAQ;QACtB,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;MCLM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE;IAE9B,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAmC,KAAK;QAC7C,MAAM,EAAoC,MAAM;KACjD,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAErD,MAAM,YAAY,GAAG,QAAQ,CAAC;QAC5B,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,CAAC,CAAA;IAEjB,SAAS,CAAC;QAGR,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;QAEtD,OAAO,MAAM,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;KACvE,EAAE,EAAE,CAAC,CAAA;IAEN,OAAO,UAAU,CAAA;AACnB;;;;"}
1
+ {"version":3,"file":"vitus-labs-hooks.module.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":[],"mappings":";;;AAQA,MAAM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK,KAAI;IAC7C,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AAE9C,IAAA,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;AACzD,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;AACL,QAAA,YAAY,EAAE,QAAQ;AACtB,QAAA,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;ACLA,MAAM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE,KAC5B;AACF,IAAA,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAmC,KAAK;QAC7C,MAAM,EAAoC,MAAM;AACjD,KAAA,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AAErD,IAAA,MAAM,YAAY,GAAG,QAAQ,CAAC,MAAK;AACjC,QAAA,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,CAAC,CAAA;IAEjB,SAAS,CAAC,MAAK;QAGb,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;AAEtD,QAAA,OAAO,MAAM,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;AACxE,KAAC,EAAE,EAAE,CAAC,CAAA;AAEN,IAAA,OAAO,UAAU,CAAA;AACnB;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-hooks.native.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":[],"mappings":";;;MAQM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK;IACzC,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAE9C,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;IACzD,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;QACL,YAAY,EAAE,QAAQ;QACtB,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;MCLM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE;IAE9B,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAe,MAAM,CAAC,UAAU,CAAQ;QAC7C,MAAM,EAAe,MAAM,CAAC,WAAW,CAAS;KACjD,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAErD,MAAM,YAAY,GAAG,QAAQ,CAAC;QAC5B,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,CAAC,CAAA;IAEjB,SAAS,CAAC;QAGR,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;QAEtD,OAAO,MAAM,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;KACvE,EAAE,EAAE,CAAC,CAAA;IAEN,OAAO,UAAU,CAAA;AACnB;;;;"}
1
+ {"version":3,"file":"vitus-labs-hooks.native.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":[],"mappings":";;;AAQA,MAAM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK,KAAI;IAC7C,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AAE9C,IAAA,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;AACzD,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;IAE5D,OAAO;QACL,KAAK;AACL,QAAA,YAAY,EAAE,QAAQ;AACtB,QAAA,YAAY,EAAE,UAAU;KACzB,CAAA;AACH;;ACLA,MAAM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE,KAC5B;AACF,IAAA,MAAM,OAAO,GAAG,OAAO;QACrB,KAAK,EAAe,MAAM,CAAC,UAAU,CAAQ;QAC7C,MAAM,EAAe,MAAM,CAAC,WAAW,CAAS;AACjD,KAAA,CAAC,CAAA;IAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AAErD,IAAA,MAAM,YAAY,GAAG,QAAQ,CAAC,MAAK;AACjC,QAAA,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;KACzB,EAAE,aAAa,CAAC,CAAA;IAEjB,SAAS,CAAC,MAAK;QAGb,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;AAEtD,QAAA,OAAO,MAAM,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,YAAY,EAAE,KAAK,CAAC,CAAA;AACxE,KAAC,EAAE,EAAE,CAAC,CAAA;AAEN,IAAA,OAAO,UAAU,CAAA;AACnB;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-hooks.umd.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":["useState","useCallback","throttle","useEffect"],"mappings":";;;;;;QAQM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK;MACzC,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAGA,cAAQ,CAAC,OAAO,CAAC,CAAA;MAE9C,MAAM,QAAQ,GAAGC,iBAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;MACzD,MAAM,UAAU,GAAGA,iBAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;MAE5D,OAAO;UACL,KAAK;UACL,YAAY,EAAE,QAAQ;UACtB,YAAY,EAAE,UAAU;OACzB,CAAA;EACH;;QCLM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE;MAE9B,MAAM,OAAO,GAAG,OAAO;UACrB,KAAK,EAAmC,KAAK;UAC7C,MAAM,EAAoC,MAAM;OACjD,CAAC,CAAA;MAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAGD,cAAQ,CAAC,OAAO,CAAC,CAAA;MAEhCE,aAAQ,CAAC;UAC5B,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;OACzB,EAAE,aAAa,EAAC;MAEjBC,eAAS,CAAC;UACQ,OAAO,SAAS,CAAA;OAKjC,EAAE,EAAE,CAAC,CAAA;MAEN,OAAO,UAAU,CAAA;EACnB;;;;;;;;;;;"}
1
+ {"version":3,"file":"vitus-labs-hooks.umd.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":["useState","useCallback","throttle","useEffect"],"mappings":";;;;;;AAQA,QAAM,QAAQ,GAAa,CAAC,OAAO,GAAG,KAAK,KAAI;MAC7C,MAAM,CAAC,KAAK,EAAE,WAAW,CAAC,GAAGA,cAAQ,CAAC,OAAO,CAAC,CAAA;EAE9C,IAAA,MAAM,QAAQ,GAAGC,iBAAW,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAA;EACzD,IAAA,MAAM,UAAU,GAAGA,iBAAW,CAAC,MAAM,WAAW,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAA;MAE5D,OAAO;UACL,KAAK;EACL,QAAA,YAAY,EAAE,QAAQ;EACtB,QAAA,YAAY,EAAE,UAAU;OACzB,CAAA;EACH;;ACLA,QAAM,eAAe,GAAoB,CACvC,aAAa,GAAG,GAAG,EACnB,EAAE,KAAK,GAAG,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE,GAAG,EAAE,KAC5B;EACF,IAAA,MAAM,OAAO,GAAG,OAAO;UACrB,KAAK,EAAmC,KAAK;UAC7C,MAAM,EAAoC,MAAM;EACjD,KAAA,CAAC,CAAA;MAEF,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAGD,cAAQ,CAAC,OAAO,CAAC,CAAA;EAErD,IAAqBE,aAAQ,CAAC,MAAK;EACjC,QAAA,aAAa,CAAC,OAAO,EAAE,CAAC,CAAA;OACzB,EAAE,aAAa,EAAC;MAEjBC,eAAS,CAAC,MAAK;EACb,QAAgB,OAAO,SAAS,CAAA;EAKlC,KAAC,EAAE,EAAE,CAAC,CAAA;EAEN,IAAA,OAAO,UAAU,CAAA;EACnB;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-hooks.umd.min.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":["initial","hover","handleHover","useState","onMouseEnter","useCallback","onMouseLeave","throttleDelay","width","height","getSize","windowSize","setWindowSize","throttle","useEffect"],"mappings":"4VAQ2B,CAACA,GAAU,KACpC,MAAOC,EAAOC,GAAeC,WAASH,GAKtC,MAAO,CACLC,MAAAA,EACAG,aALeC,eAAY,IAAMH,GAAY,IAAO,IAMpDI,aALiBD,eAAY,IAAMH,GAAY,IAAQ,wBCElB,CACvCK,EAAgB,KACdC,MAAAA,EAAQ,EAAGC,OAAAA,EAAS,GAAM,MAE5B,MAAMC,EAAU,MACdF,MAAwCA,EACxCC,OAA0CA,KAGrCE,EAAYC,GAAiBT,WAASO,GAc7C,OAZqBG,YAAS,KAC5BD,EAAcF,OACbH,GAEHO,aAAU,QAMP,IAEIH"}
1
+ {"version":3,"file":"vitus-labs-hooks.umd.min.js","sources":["../src/useHover.ts","../src/useWindowResize.ts"],"sourcesContent":["import { useState, useCallback } from 'react'\n\nexport type UseHover = (initialValue?: boolean) => {\n hover: boolean\n onMouseEnter: () => void\n onMouseLeave: () => void\n}\n\nconst useHover: UseHover = (initial = false) => {\n const [hover, handleHover] = useState(initial)\n\n const setHover = useCallback(() => handleHover(true), [])\n const unsetHover = useCallback(() => handleHover(false), [])\n\n return {\n hover,\n onMouseEnter: setHover,\n onMouseLeave: unsetHover,\n }\n}\n\nexport default useHover\n","import { useState, useEffect } from 'react'\nimport { throttle } from '@vitus-labs/core'\n\nexport type UseWindowResize = (\n throttleDelay?: number,\n defaultValues?: Partial<{\n width: number\n height: number\n }>\n) => {\n width: number\n height: number\n}\n\nconst useWindowResize: UseWindowResize = (\n throttleDelay = 200,\n { width = 0, height = 0 } = {}\n) => {\n const getSize = () => ({\n width: __CLIENT__ ? window.innerWidth : width,\n height: __CLIENT__ ? window.innerHeight : height,\n })\n\n const [windowSize, setWindowSize] = useState(getSize)\n\n const handleResize = throttle(() => {\n setWindowSize(getSize())\n }, throttleDelay)\n\n useEffect(() => {\n if (__SERVER__) return undefined\n\n window.addEventListener('resize', handleResize, false)\n\n return () => window.removeEventListener('resize', handleResize, false)\n }, []) // Empty array ensures that effect is only run on mount and unmount\n\n return windowSize\n}\n\nexport default useWindowResize\n"],"names":["initial","hover","handleHover","useState","onMouseEnter","useCallback","onMouseLeave","throttleDelay","width","height","getSize","windowSize","setWindowSize","throttle","useEffect"],"mappings":"4VAQ2B,CAACA,GAAU,KACpC,MAAOC,EAAOC,GAAeC,EAAQA,SAACH,GAKtC,MAAO,CACLC,MAAAA,EACAG,aALeC,EAAAA,aAAY,IAAMH,GAAY,IAAO,IAMpDI,aALiBD,EAAAA,aAAY,IAAMH,GAAY,IAAQ,wBCElB,CACvCK,EAAgB,KACdC,MAAAA,EAAQ,EAAGC,OAAAA,EAAS,GAAM,MAE5B,MAAMC,EAAU,KAAO,CACrBF,MAAwCA,EACxCC,OAA0CA,KAGrCE,EAAYC,GAAiBT,EAAQA,SAACO,GAc7C,OAZqBG,EAAAA,UAAS,KAC5BD,EAAcF,OACbH,GAEHO,EAAAA,WAAU,QAMP,IAEIH"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitus-labs/hooks",
3
- "version": "0.44.0",
3
+ "version": "0.45.0",
4
4
  "license": "MIT",
5
5
  "author": "Vit Bokisch <vit@bokisch.cz>",
6
6
  "maintainers": [
@@ -49,10 +49,10 @@
49
49
  "react": ">= 16.8"
50
50
  },
51
51
  "devDependencies": {
52
- "@vitus-labs/core": "^0.44.0",
53
- "@vitus-labs/tools-babel": "^0.27.0",
54
- "@vitus-labs/tools-rollup": "^0.27.0",
55
- "@vitus-labs/tools-typescript": "^0.27.0"
52
+ "@vitus-labs/core": "^0.45.0",
53
+ "@vitus-labs/tools-babel": "^0.28.0",
54
+ "@vitus-labs/tools-rollup": "^0.28.0",
55
+ "@vitus-labs/tools-typescript": "^0.28.0"
56
56
  },
57
- "gitHead": "ef9ce8b517dac9a4898aad62594c2340bd13d4dd"
57
+ "gitHead": "e1bfc71544ebfb48af761c319853179af006800d"
58
58
  }