earthnut 0.0.0 → 0.0.1
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.
- package/BackgroundRipple/index.cjs +1 -0
- package/BackgroundRipple/index.mjs +1 -0
- package/LICENSE +25 -0
- package/Layout/index.cjs +1 -0
- package/Layout/index.mjs +1 -0
- package/README.md +9 -5
- package/components/button/button.d.ts +5 -0
- package/components/button/index.d.ts +3 -0
- package/components/button/style/index.d.ts +1 -0
- package/components/index.d.ts +3 -0
- package/components/layout/content.d.ts +11 -0
- package/components/layout/footer.d.ts +16 -0
- package/components/layout/header.d.ts +18 -0
- package/components/layout/index.d.ts +2 -0
- package/components/layout/layout.d.ts +50 -0
- package/components/layout/sideBar.d.ts +24 -0
- package/components/layout/types.d.ts +71 -0
- package/components/menu/index.d.ts +0 -0
- package/components/menu/menu.d.ts +0 -0
- package/components/menu/style/index.d.ts +0 -0
- package/components/ripples/RipplesEle.d.ts +36 -0
- package/components/ripples/index.d.ts +4 -0
- package/components/ripples/style/index.d.ts +0 -0
- package/components/ripples/types.d.ts +11 -0
- package/components/ripples/useOptionUpdate.d.ts +5 -0
- package/customHooks/index.d.ts +5 -0
- package/customHooks/useAnimationFrame.d.ts +42 -0
- package/customHooks/useInputIsComposing.d.ts +46 -0
- package/customHooks/useRipples/buildBackground/default-background/_createImageData.d.ts +7 -0
- package/customHooks/useRipples/buildBackground/default-background/circleDataList.d.ts +18 -0
- package/customHooks/useRipples/buildBackground/default-background/createCanvasElementBySize.d.ts +2 -0
- package/customHooks/useRipples/buildBackground/default-background/createDefault.d.ts +2 -0
- package/customHooks/useRipples/buildBackground/default-background/index.d.ts +10 -0
- package/customHooks/useRipples/buildBackground/loadImage.d.ts +13 -0
- package/customHooks/useRipples/buildBackground/runSide.d.ts +9 -0
- package/customHooks/useRipples/buildBackground/type.d.ts +27 -0
- package/customHooks/useRipples/buildBackground/utils/bindImage.d.ts +3 -0
- package/customHooks/useRipples/buildBackground/utils/createCanvasElement.d.ts +3 -0
- package/customHooks/useRipples/buildBackground/utils/createImageBySrc.d.ts +2 -0
- package/customHooks/useRipples/buildBackground/utils/getBackgroundStyle.d.ts +3 -0
- package/customHooks/useRipples/buildBackground/utils/hideCssBackground.d.ts +10 -0
- package/customHooks/useRipples/buildBackground/utils/restore-css-background.d.ts +7 -0
- package/customHooks/useRipples/callback/destroy.d.ts +3 -0
- package/customHooks/useRipples/callback/drop.d.ts +3 -0
- package/customHooks/useRipples/callback/fade.d.ts +3 -0
- package/customHooks/useRipples/callback/reload-background.d.ts +6 -0
- package/customHooks/useRipples/callback/scale.d.ts +2 -0
- package/customHooks/useRipples/index.d.ts +40 -0
- package/customHooks/useRipples/init/index.d.ts +5 -0
- package/customHooks/useRipples/init/initEvent.d.ts +5 -0
- package/customHooks/useRipples/init/initShaders.d.ts +7 -0
- package/customHooks/useRipples/init/initTexture.d.ts +7 -0
- package/customHooks/useRipples/render/computeTextureBoundaries.d.ts +3 -0
- package/customHooks/useRipples/render/draw.d.ts +7 -0
- package/customHooks/useRipples/render/drawQuad.d.ts +7 -0
- package/customHooks/useRipples/render/dropAtPointer.d.ts +7 -0
- package/customHooks/useRipples/render/index.d.ts +6 -0
- package/customHooks/useRipples/render/swapBufferIndices.d.ts +5 -0
- package/customHooks/useRipples/render/update.d.ts +5 -0
- package/customHooks/useRipples/rippersData/defaultData.d.ts +5 -0
- package/customHooks/useRipples/rippersData/fadeData.d.ts +29 -0
- package/customHooks/useRipples/rippersData/index.d.ts +40 -0
- package/customHooks/useRipples/rippersData/loadConfig.d.ts +19 -0
- package/customHooks/useRipples/rippersData/renderData.d.ts +72 -0
- package/customHooks/useRipples/rippersData/useOptions.d.ts +81 -0
- package/customHooks/useRipples/rippersData/vertexSource.d.ts +28 -0
- package/customHooks/useRipples/ripple.html.d.ts +6 -0
- package/customHooks/useRipples/ripplesClass.d.ts +51 -0
- package/customHooks/useRipples/tools.d.ts +31 -0
- package/customHooks/useRipples/types.d.ts +192 -0
- package/customHooks/useTimeId.d.ts +55 -0
- package/dog.d.ts +3 -0
- package/index.cjs +1 -0
- package/index.d.ts +5 -0
- package/index.js.LICENSE.txt +79 -0
- package/index.mjs +1 -0
- package/package.json +87 -14
- package/styles/common.css +360 -0
- package/styles/common.scss +444 -0
- package/useAnimationFrame/index.cjs +1 -0
- package/useAnimationFrame/index.mjs +1 -0
- package/useInputIsComposing/index.cjs +1 -0
- package/useInputIsComposing/index.mjs +1 -0
- package/useRipples/index.cjs +1 -0
- package/useRipples/index.mjs +1 -0
- package/useTimeId/index.cjs +1 -0
- package/useTimeId/index.mjs +1 -0
- package/index.js +0 -1
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `input` 类型收缩
|
|
3
|
+
*
|
|
4
|
+
* @packageDocumentation
|
|
5
|
+
* @module @a-type-of-js/isType
|
|
6
|
+
* @license MIT
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* 检测 Javascript 数据类型工具之: array
|
|
11
|
+
*
|
|
12
|
+
* @packageDocumentation
|
|
13
|
+
* @module @a-type-of-js/array
|
|
14
|
+
* @license MIT
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* 检测 Javascript 数据类型工具之: boolean
|
|
19
|
+
*
|
|
20
|
+
* @packageDocumentation
|
|
21
|
+
* @module @a-type-of-js/boolean
|
|
22
|
+
* @license MIT
|
|
23
|
+
*/
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* 检测 Javascript 数据类型工具之: null
|
|
27
|
+
*
|
|
28
|
+
* @packageDocumentation
|
|
29
|
+
* @module @a-type-of-js/null
|
|
30
|
+
* @license MIT
|
|
31
|
+
*/
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* 检测 Javascript 数据类型工具之: number
|
|
35
|
+
*
|
|
36
|
+
* @packageDocumentation
|
|
37
|
+
* @module @a-type-of-js/number
|
|
38
|
+
* @license MIT
|
|
39
|
+
*/
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* 检测 Javascript 数据类型工具之: object
|
|
43
|
+
*
|
|
44
|
+
* @packageDocumentation
|
|
45
|
+
* @module @a-type-of-js/object
|
|
46
|
+
* @license MIT
|
|
47
|
+
*/
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* 检测 Javascript 数据类型工具之: string
|
|
51
|
+
*
|
|
52
|
+
* @packageDocumentation
|
|
53
|
+
* @module @a-type-of-js/string
|
|
54
|
+
* @license MIT
|
|
55
|
+
*/
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* 获取随机字符串
|
|
59
|
+
*
|
|
60
|
+
* @packageDocumentation
|
|
61
|
+
* @module @a-js-tools/get-random-string
|
|
62
|
+
* @license MIT
|
|
63
|
+
*/
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* 过去随机数
|
|
67
|
+
*
|
|
68
|
+
* @packageDocumentation
|
|
69
|
+
* @module @a-js-tools/get-random-number
|
|
70
|
+
* @license MIT
|
|
71
|
+
*/
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* 防抖和节流
|
|
75
|
+
*
|
|
76
|
+
* @packageDocumentation
|
|
77
|
+
* @module @a-js-tools/performance
|
|
78
|
+
* @license MIT
|
|
79
|
+
*/
|
package/index.mjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import*as e from"a-type-of-js";import*as t from"xcn";import*as r from"react";import*as n from"a-element-inline-style";import*as i from"a-js-tools";var o={56:(e,t,r)=>{e.exports=function(e){var t=r.nc;t&&e.setAttribute("nonce",t)}},72:e=>{var t=[];function r(e){for(var r=-1,n=0;n<t.length;n++)if(t[n].identifier===e){r=n;break}return r}function n(e,n){for(var o={},a=[],u=0;u<e.length;u++){var l=e[u],s=n.base?l[0]+n.base:l[0],c=o[s]||0,f="".concat(s," ").concat(c);o[s]=c+1;var d=r(f),p={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==d)t[d].references++,t[d].updater(p);else{var h=i(p,n);n.byIndex=u,t.splice(u,0,{identifier:f,updater:h,references:1})}a.push(f)}return a}function i(e,t){var r=t.domAPI(t);return r.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;r.update(e=t)}else r.remove()}}e.exports=function(e,i){var o=n(e=e||[],i=i||{});return function(e){e=e||[];for(var a=0;a<o.length;a++){var u=r(o[a]);t[u].references--}for(var l=n(e,i),s=0;s<o.length;s++){var c=r(o[s]);0===t[c].references&&(t[c].updater(),t.splice(c,1))}o=l}}},109:(e,t,r)=>{r.d(t,{A:()=>u});var n=r(601),i=r.n(n),o=r(314),a=r.n(o)()(i());a.push([e.id,".en-ripple-container{width:100%;height:100%;position:relative;top:0px;left:0px;z-index:1}",""]);const u=a},113:e=>{e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},153:(e,t,r)=>{r.d(t,{z:()=>T});var n=r(649),i=r(707),o=r(362),a=r(411),u=r(72),l=r.n(u),s=r(825),c=r.n(s),f=r(659),d=r.n(f),p=r(56),h=r.n(p),y=r(540),m=r.n(y),v=r(113),g=r.n(v),b=r(109),w={};function E(e){return E="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},E(e)}w.styleTagTransform=g(),w.setAttributes=h(),w.insert=d().bind(null,"head"),w.domAPI=c(),w.insertStyleElement=m(),l()(b.A,w),b.A&&b.A.locals&&b.A.locals;var R=["children","style"];function S(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function P(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?S(Object(r),!0).forEach((function(t){O(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):S(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function O(e,t,r){return(t=function(e){var t=function(e){if("object"!=E(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=E(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==E(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var T=(0,n.forwardRef)((function(e,t){var r=e.children,u=e.style,l=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],-1===t.indexOf(r)&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,R),s=(0,n.useRef)(null),c=(0,i.n)(s,l);return function(e,t){(0,n.useEffect)((function(){if(t.option&&e.current){var r=t.option;Object.keys(e.current.defaults).forEach((function(t){!(0,o.isUndefined)(r[t])&&e.current&&e.current.set(t,r[t])}))}}),[t.option])}(c,l),(0,n.useImperativeHandle)(t,(function(){return{toggleState:function(){var e;null===(e=c.current)||void 0===e||e.changePlayingState()},get state(){var e,t;return null!==(e=null===(t=c.current)||void 0===t?void 0:t.options.playingState)&&void 0!==e&&e},pause:function(){var e;null===(e=c.current)||void 0===e||e.pause()},set:function(e){if(!(0,o.isUndefined)(e))for(var t=Object.keys(e),r=0,n=t.length;r<n;r++){var i,a=t[r];null===(i=c.current)||void 0===i||i.set(a,e[a])}}}})),n.default.createElement("div",{className:(0,a.xcn)("en-ripple-container"),style:P({backgroundRepeat:"round"},u)},n.default.createElement("canvas",{ref:s,"data-earthnut-ui":"canvas"}),r)}));T.displayName="en-background-ripple"},195:(e,t,r)=>{r.d(t,{t:()=>i});var n=r(649);function i(e){var t=(0,n.useRef)(!1);return(0,n.useEffect)((function(){var r=e.current;if(r){var n=function(){return t.current=!0},i=function(){return t.current=!1};return r.addEventListener("compositionstart",n),r.addEventListener("compositionend",i),function(){r.removeEventListener("compositionstart",n),r.removeEventListener("compositionend",i)}}}),[]),t}},314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r="",n=void 0!==t[5];return t[4]&&(r+="@supports (".concat(t[4],") {")),t[2]&&(r+="@media ".concat(t[2]," {")),n&&(r+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),r+=e(t),n&&(r+="}"),t[2]&&(r+="}"),t[4]&&(r+="}"),r})).join("")},t.i=function(e,r,n,i,o){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(n)for(var u=0;u<this.length;u++){var l=this[u][0];null!=l&&(a[l]=!0)}for(var s=0;s<e.length;s++){var c=[].concat(e[s]);n&&a[c[0]]||(void 0!==o&&(void 0===c[5]||(c[1]="@layer".concat(c[5].length>0?" ".concat(c[5]):""," {").concat(c[1],"}")),c[5]=o),r&&(c[2]?(c[1]="@media ".concat(c[2]," {").concat(c[1],"}"),c[2]=r):c[2]=r),i&&(c[4]?(c[1]="@supports (".concat(c[4],") {").concat(c[1],"}"),c[4]=i):c[4]="".concat(i)),t.push(c))}},t}},362:(t,r,n)=>{var i,o;t.exports=(i={isBoolean:()=>e.isBoolean,isEmptyArray:()=>e.isEmptyArray,isFalse:()=>e.isFalse,isNull:()=>e.isNull,isNumber:()=>e.isNumber,isTrue:()=>e.isTrue,isUndefined:()=>e.isUndefined,isZero:()=>e.isZero},o={},n.d(o,i),o)},363:(e,t,r)=>{r.d(t,{wb:()=>B,Ht:()=>A,zE:()=>j,n5:()=>R,AX:()=>O,PE:()=>B,A1:()=>A,cZ:()=>j,KL:()=>R,nb:()=>O});var n=r(649),i=r(411),o=r(72),a=r.n(o),u=r(825),l=r.n(u),s=r(659),c=r.n(s),f=r(56),d=r.n(f),p=r(540),h=r.n(p),y=r(113),m=r.n(y),v=r(384),g={};g.styleTagTransform=m(),g.setAttributes=d(),g.insert=c().bind(null,"head"),g.domAPI=l(),g.insertStyleElement=h(),a()(v.A,g);const b=v.A&&v.A.locals?v.A.locals:void 0;var w=["className","children","height","noSticky"];function E(){return E=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},E.apply(null,arguments)}var R=n.default.forwardRef((function(e,t){var r=e.className,o=e.children,a=(e.height,e.noSticky,function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],-1===t.indexOf(r)&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,w));return n.default.createElement("div",E({ref:t,className:(0,i.xcn)(b["en-layout-header"],r)},a,{"data-earthnut-ui":"layout-header"}),o)}));R.displayName="LayoutHeader";var S=["className","width","right","full"];function P(){return P=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},P.apply(null,arguments)}var O=n.default.forwardRef((function(e,t){var r=e.className,o=(e.width,e.right,e.full,function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],-1===t.indexOf(r)&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,S));return n.default.createElement("div",P({className:(0,i.xcn)(b["en-layout-side"],r),ref:t},o,{"data-earthnut-ui":"layout-side-bar"}))}));O.displayName="LayoutSideBar";var T=["className"];function x(){return x=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},x.apply(null,arguments)}var A=n.default.forwardRef((function(e,t){var r=e.className,o=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],-1===t.indexOf(r)&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,T);return n.default.createElement("main",x({ref:t,className:(0,i.xcn)(b["en-layout-main"],r)},o,{"data-earthnut-ui":"layout-content"}))}));A.displayName="LayoutContent";var k=["className","height"];function D(){return D=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},D.apply(null,arguments)}var j=n.default.forwardRef((function(e,t){var r=e.className,o=(e.height,function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],-1===t.indexOf(r)&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,k));return n.default.createElement("div",D({ref:t},o,{className:(0,i.xcn)(b["en-layout-footer"],r),"data-earthnut-ui":"layout-footer"}))}));j.displayName="LayoutFooter";var _=r(362);function F(e){return F="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},F(e)}var I=["className","children","style","width","height"];function N(){return N=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},N.apply(null,arguments)}function L(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function C(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?L(Object(r),!0).forEach((function(t){U(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):L(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function U(e,t,r){return(t=function(e){var t=function(e){if("object"!=F(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=F(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==F(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var B=n.forwardRef((function(e,t){var r,o,a,u,l=e.className,s=e.children,c=e.style,f=e.width,d=void 0===f?"100vw":f,p=e.height,h=void 0===p?"100vh":p,y=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],-1===t.indexOf(r)&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,I),m="simple",v="",g=!1,w=!1,E=!1,S=!1,P=150,T="2.8rem",x="2rem",k=!1;n.Children.forEach(s,(function(e){if(n.isValidElement(e))if(g||e.type!==R)if(w||e.type!==O)E||e.type!==A?E||e.type!==B?S||e.type!==j||(x=e.props.height||x,u=e,S=!0):(a=n.createElement("main",{"data-earthnut-ui":"layout-content",className:(0,i.xcn)(b["en-layout-main"])},e),E=!0):(a=e,E=!0);else{var t=e.props;P=t.width||P,m=t.right&&t.full?"side-right-full":t.right?"side-right":t.full?"side-full":"simple",k=(0,_.isTrue)(t.full),o=e,w=!0}else{var l=e.props;T=l.height||T,v=l.noSticky?b["en-layout-header-no-sticky"]:"",r=e,g=!0}}));var D=g&&w&&E&&S&&b["en-layout-".concat(m,"-all")]||g&&E&&w&&b["en-layout-".concat(m,"-no-footer")]||w&&E&&S&&b["en-layout-".concat(m,"-no-header")]||E&&S&&b["en-layout-only-footer"]||E&&g&&b["en-layout-only-header"]||E&&w&&(k=!0)&&b["en-layout-".concat(m,"-only-side")]||"";return n.createElement("div",N({ref:t,className:(0,i.xcn)(b["en-layout"],k&&b["en-layout-side-full"],D,v,l),style:C({"--layout-width":X(d),"--layout-height":X(h),"--layout-side-bar-width":X(P),"--layout-header-height":X(T),"--layout-footer-height":X(x)},c)},y,{"data-earthnut-ui":"layout"}),/side.*full/.test(m)?n.createElement(n.Fragment,null,o,r,a,u):n.createElement(n.Fragment,null,r,S?n.createElement("div",{className:(0,i.xcn)(b["en-layout-content"]),"data-earthnut-ui":"layout-with-foot-content"},o,a):n.createElement(n.Fragment,null,o,a),u))}));function X(e){return(0,_.isNumber)(e)||parseInt(e)===Number(e)?e+"px":e||0}B.displayName="Layout"},384:(e,t,r)=>{r.d(t,{A:()=>u});var n=r(601),i=r.n(n),o=r(314),a=r.n(o)()(i());a.push([e.id,'.LcdTDTWWkxGZFXQc8XNV{width:var(--layout-width);height:var(--layout-height);overflow-x:hidden;overflow-y:auto}.CxCt7n1zXeDfFdmgQAme{grid-area:header;position:sticky;top:0px;left:0px;z-index:10;height:var(--layout-header-height);box-shadow:0 4px 13px -3px rgba(0,0,0,.1019607843);overflow:hidden}.E2socS6t6fugHzd2ATQy{position:sticky;left:0;z-index:8;grid-area:side;overflow-x:hidden;overflow-y:auto}.k2yu7eCpEzToH_ynBglg{grid-area:content}.zWuykaXyereS6ELF7SHy{grid-area:footer;height:var(--layout-footer-height);box-shadow:0 -1px 13px 0px rgba(0,0,0,.1019607843);overflow:hidden}.O6AnGNbL5r3nPmEFEv73>.CxCt7n1zXeDfFdmgQAme{position:relative;z-index:2}.O6AnGNbL5r3nPmEFEv73.ognI7wqsq0lXqSVkJ0cj>.r_iQ4e7myBc0DSPRkp2u>.E2socS6t6fugHzd2ATQy,.O6AnGNbL5r3nPmEFEv73.Sax5A5AqDPokwTlrUZu5>.r_iQ4e7myBc0DSPRkp2u>.E2socS6t6fugHzd2ATQy{top:0;min-height:calc(var(--layout-height) - var(--layout-footer-height) - var(--layout-header-height));max-height:var(--layout-height)}.O6AnGNbL5r3nPmEFEv73.Wz4q5vQzeOw8RbDr0rOF>.E2socS6t6fugHzd2ATQy,.O6AnGNbL5r3nPmEFEv73.GkLVEZcHiQyvuSh0RLU5>.E2socS6t6fugHzd2ATQy{top:0;min-height:calc(var(--layout-height) - var(--layout-footer-height));max-height:var(--layout-height)}.rZPYzoPjyQP7sDeJbPjp>.E2socS6t6fugHzd2ATQy{top:0;height:var(--layout-height)}.ognI7wqsq0lXqSVkJ0cj>.r_iQ4e7myBc0DSPRkp2u,.Sax5A5AqDPokwTlrUZu5>.r_iQ4e7myBc0DSPRkp2u{display:grid;grid-template-rows:calc(var(--layout-height) - var(--layout-header-height) - var(--layout-footer-height)) auto;min-height:calc(100% - var(--layout-header-height) - var(--layout-footer-height))}.ognI7wqsq0lXqSVkJ0cj>.r_iQ4e7myBc0DSPRkp2u>.E2socS6t6fugHzd2ATQy,.Sax5A5AqDPokwTlrUZu5>.r_iQ4e7myBc0DSPRkp2u>.E2socS6t6fugHzd2ATQy{top:var(--layout-header-height);min-height:calc(var(--layout-height) - var(--layout-header-height) - var(--layout-footer-height));max-height:calc(var(--layout-height) - var(--layout-header-height))}.ognI7wqsq0lXqSVkJ0cj>.r_iQ4e7myBc0DSPRkp2u,.UhPmIL0kNAGv5201kGbo>.r_iQ4e7myBc0DSPRkp2u{grid-template-columns:var(--layout-side-bar-width) auto;grid-template-areas:"side content" ". content"}.Sax5A5AqDPokwTlrUZu5>.r_iQ4e7myBc0DSPRkp2u,.Nkg7pjNAPCenCQZY8gLg>.r_iQ4e7myBc0DSPRkp2u{grid-template-columns:auto var(--layout-side-bar-width);grid-template-areas:"content side" "content ."}.XRYEv9hWhdcl2OHap6fQ,.SmA7SjLAZLofOenJZAWg{display:grid;grid-template-rows:var(--layout-header-height) auto var(--layout-footer-height);gap:0px}.XRYEv9hWhdcl2OHap6fQ{grid-template-columns:var(--layout-side-bar-width) auto;grid-template-areas:"side header" "side content" "side footer"}.SmA7SjLAZLofOenJZAWg{grid-template-columns:auto var(--layout-side-bar-width);grid-template-areas:"header side" "content side" "footer side"}.UhPmIL0kNAGv5201kGbo>.r_iQ4e7myBc0DSPRkp2u,.Nkg7pjNAPCenCQZY8gLg>.r_iQ4e7myBc0DSPRkp2u{display:grid;grid-template-rows:auto}.UhPmIL0kNAGv5201kGbo>.r_iQ4e7myBc0DSPRkp2u>.E2socS6t6fugHzd2ATQy,.Nkg7pjNAPCenCQZY8gLg>.r_iQ4e7myBc0DSPRkp2u>.E2socS6t6fugHzd2ATQy{top:0;min-height:calc(var(--layout-height) - var(--layout-footer-height));max-height:var(--layout-height)}.UT3CcVcTx9pLwV2GGFGi,.tzvYxycvFA9rcOf26LP7{display:grid;grid-template-rows:auto var(--layout-footer-height);gap:0px}.UT3CcVcTx9pLwV2GGFGi{grid-template-columns:var(--layout-side-bar-width) auto;grid-template-areas:"side content" "side footer"}.tzvYxycvFA9rcOf26LP7{grid-template-columns:auto var(--layout-side-bar-width);grid-template-areas:"content side" "footer side"}.Wz4q5vQzeOw8RbDr0rOF,.GkLVEZcHiQyvuSh0RLU5{display:grid;grid-template-rows:var(--layout-header-height) auto;min-height:calc(100% - var(--layout-header-height));gap:0px}.Wz4q5vQzeOw8RbDr0rOF>.E2socS6t6fugHzd2ATQy,.GkLVEZcHiQyvuSh0RLU5>.E2socS6t6fugHzd2ATQy{top:var(--layout-header-height);height:calc(var(--layout-height) - var(--layout-header-height))}.Wz4q5vQzeOw8RbDr0rOF{grid-template-columns:var(--layout-side-bar-width) auto;grid-template-areas:"header header" "side content" ". content"}.GkLVEZcHiQyvuSh0RLU5{grid-template-columns:auto var(--layout-side-bar-width);grid-template-areas:"header header" "content side" "content ."}.cFlRZr9kGWMtc0nRYCWE,.DzmD_4Su8YXCKKIwXjG1{display:grid;grid-template-rows:var(--layout-header-height) auto;gap:0px}.cFlRZr9kGWMtc0nRYCWE>.k2yu7eCpEzToH_ynBglg,.DzmD_4Su8YXCKKIwXjG1>.k2yu7eCpEzToH_ynBglg{min-height:calc(var(--layout-height) - var(--layout-header-height))}.cFlRZr9kGWMtc0nRYCWE{grid-template-columns:var(--layout-side-bar-width) auto;grid-template-areas:"side header" "side content"}.DzmD_4Su8YXCKKIwXjG1{grid-template-columns:auto var(--layout-side-bar-width);grid-template-areas:"header side" "content side"}.sm5xSKZmdrGS3a6b5rcN{display:grid;grid-template-rows:auto var(--layout-footer-height);grid-template-columns:1fr;gap:0px;grid-template-areas:"content" "footer"}.qxhkwYH_Y7uyvMDH8JyZ{display:grid;grid-template-rows:var(--layout-header-height) auto;grid-template-columns:1fr;gap:0px;grid-template-areas:"header" "content"}.sAEoDcBqMzkziXXvgv8X,.jxy4KSYJK23WN2rx2CDS,.wVTitTPpRyG8XfbxJGhy,.mKVYywd6gr5_u2naW5_u{display:grid;grid-template-rows:100%;grid-template-columns:var(--layout-side-bar-width) auto;gap:0px;grid-template-areas:"side content" ". content"}.mKVYywd6gr5_u2naW5_u,.jxy4KSYJK23WN2rx2CDS{grid-template-areas:"content side" "content .";grid-template-columns:auto var(--layout-side-bar-width)}',""]),a.locals={"en-layout":"LcdTDTWWkxGZFXQc8XNV","en-layout-header":"CxCt7n1zXeDfFdmgQAme","en-layout-side":"E2socS6t6fugHzd2ATQy","en-layout-main":"k2yu7eCpEzToH_ynBglg","en-layout-footer":"zWuykaXyereS6ELF7SHy","en-layout-header-no-sticky":"O6AnGNbL5r3nPmEFEv73","en-layout-simple-all":"ognI7wqsq0lXqSVkJ0cj","en-layout-content":"r_iQ4e7myBc0DSPRkp2u","en-layout-side-right-all":"Sax5A5AqDPokwTlrUZu5","en-layout-simple-no-footer":"Wz4q5vQzeOw8RbDr0rOF","en-layout-side-right-no-footer":"GkLVEZcHiQyvuSh0RLU5","en-layout-side-full":"rZPYzoPjyQP7sDeJbPjp","en-layout-simple-no-header":"UhPmIL0kNAGv5201kGbo","en-layout-side-right-no-header":"Nkg7pjNAPCenCQZY8gLg","en-layout-side-full-all":"XRYEv9hWhdcl2OHap6fQ","en-layout-side-right-full-all":"SmA7SjLAZLofOenJZAWg","en-layout-side-full-no-header":"UT3CcVcTx9pLwV2GGFGi","en-layout-side-right-full-no-header":"tzvYxycvFA9rcOf26LP7","en-layout-side-full-no-footer":"cFlRZr9kGWMtc0nRYCWE","en-layout-side-right-full-no-footer":"DzmD_4Su8YXCKKIwXjG1","en-layout-only-footer":"sm5xSKZmdrGS3a6b5rcN","en-layout-only-header":"qxhkwYH_Y7uyvMDH8JyZ","en-layout-simple-only-side":"sAEoDcBqMzkziXXvgv8X","en-layout-side-right-only-side":"jxy4KSYJK23WN2rx2CDS","en-layout-side-full-only-side":"wVTitTPpRyG8XfbxJGhy","en-layout-side-right-full-only-side":"mKVYywd6gr5_u2naW5_u"};const u=a},411:(e,r,n)=>{var i,o;e.exports=(i={xcn:()=>t.xcn},o={},n.d(o,i),o)},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},552:(e,t,r)=>{r.d(t,{O:()=>i});var n=r(649);function i(){var e=(0,n.useRef)(void 0);return(0,n.useEffect)((function(){return function(){e.current&&clearTimeout(e.current)}}),[]),e}},601:e=>{e.exports=function(e){return e[1]}},615:(e,t,r)=>{r.d(t,{M:()=>i});var n=r(649);function i(){var e=(0,n.useRef)(0);return(0,n.useEffect)((function(){return function(){e.current&&window.cancelAnimationFrame(e.current)}}),[]),e}},649:(e,t,n)=>{var i,o;e.exports=(i={Children:()=>r.Children,Fragment:()=>r.Fragment,createElement:()=>r.createElement,default:()=>r.default,forwardRef:()=>r.forwardRef,isValidElement:()=>r.isValidElement,useEffect:()=>r.useEffect,useImperativeHandle:()=>r.useImperativeHandle,useRef:()=>r.useRef},o={},n.d(o,i),o)},659:e=>{var t={};e.exports=function(e,r){var n=function(e){if(void 0===t[e]){var r=document.querySelector(e);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}t[e]=r}return t[e]}(e);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(r)}},707:(e,t,r)=>{r.d(t,{n:()=>We});var o=r(649);const a=(u={setStyle:()=>n.setStyle},l={},r.d(l,u),l);var u,l,s=r(362);function c(e,t,r,n){function i(e,t){var n=r.createShader(e);if(r.shaderSource(n,t),r.compileShader(n),!r.getShaderParameter(n,r.COMPILE_STATUS))throw new Error("compile error: "+r.getShaderInfoLog(n));return n}var o,a={id:r.createProgram(),uniforms:{},locations:{}};if(r.attachShader(a.id,i(r.VERTEX_SHADER,e)),r.attachShader(a.id,i(r.FRAGMENT_SHADER,t)),r.linkProgram(a.id),!r.getProgramParameter(a.id,r.LINK_STATUS))throw new Error("link error: "+r.getProgramInfoLog(a.id));r.useProgram(a.id),r.enableVertexAttribArray(0);for(var u=e+t,l=/uniform (\w+) (\w+)/g;!(0,s.isNull)(o=l.exec(u));){var c=o[2];a.locations[c]=r.getUniformLocation(a.id,c)}return a}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=this.gl;r.activeTexture(r.TEXTURE0+(t||0)),r.bindTexture(r.TEXTURE_2D,e)}function d(){var e=this,t=function(){return e.initState=!1,null};if(!this.gl)return t();var r=this.gl,n=Object.fromEntries(["OES_texture_float","OES_texture_half_float","OES_texture_float_linear","OES_texture_half_float_linear"].reduce((function(e,t){var n=r.getExtension(t);return n&&e.push([t,n]),e}),[]));if(!n.OES_texture_float)return t();var i=[];function o(e,t,r){var i="OES_texture_"+e,o=i+"_linear",a=o in n;return{type:t,linearSupport:a,arrayType:r,extensions:a?[i,o]:[i]}}i.push(o("float",r.FLOAT,Float32Array)),n.OES_texture_half_float&&i.push(o("half_float",n.OES_texture_half_float.HALF_FLOAT_OES,null));var a=r.createTexture(),u=r.createFramebuffer();r.bindFramebuffer(r.FRAMEBUFFER,u),r.bindTexture(r.TEXTURE_2D,a),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_MIN_FILTER,r.NEAREST),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_MAG_FILTER,r.NEAREST),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_WRAP_S,r.CLAMP_TO_EDGE),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_WRAP_T,r.CLAMP_TO_EDGE);for(var l=null,s=0;s<i.length;s++)if(r.texImage2D(r.TEXTURE_2D,0,r.RGBA,32,32,0,r.RGBA,i[s].type,null),r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,a,0),r.checkFramebufferStatus(r.FRAMEBUFFER)===r.FRAMEBUFFER_COMPLETE){l=i[s];break}return l}function p(e){return p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p(e)}function h(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,v(n.key),n)}}function y(e,t,r){return t&&h(e.prototype,t),r&&h(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function m(e,t,r){return(t=v(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function v(e){var t=function(e){if("object"!=p(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=p(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==p(t)?t:t+""}var g=y((function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),m(this,"canvas",void 0),m(this,"gl",void 0),m(this,"config",void 0),m(this,"initState",!0),this.canvas=t;var r=t.getContext("webgl");if((0,s.isNull)(r))return this.initState=!1,void(this.config=null);this.gl=r,this.config=Reflect.apply(d,this,[])}));const b=(e=>{var t={};return r.d(t,e),t})({debounce:()=>i.debounce,enArr:()=>i.enArr,getRandomInt:()=>i.getRandomInt});var w,E={imageUrl:"",resolution:360,dropRadius:12,perturbance:.01,interactive:!0,crossOrigin:"no-cors",playingState:!0,accelerating:1,raindropsTimeInterval:3600,idleFluctuations:!0};function R(e){return R="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},R(e)}function S(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,P(n.key),n)}}function P(e){var t=function(e){if("object"!=R(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=R(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==R(t)?t:t+""}function O(e){return O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},O(e)}function T(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,x(n.key),n)}}function x(e){var t=function(e){if("object"!=O(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=O(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==O(t)?t:t+""}function A(e,t,r){return e.set(D(e,t),r),r}function k(e,t){return e.get(D(e,t))}function D(e,t,r){if("function"==typeof e?e===t:e.has(t))return arguments.length<3?t:r;throw new TypeError("Private element is not present on this object")}function j(e){return function(e){if(Array.isArray(e))return _(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return _(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?_(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}Object.freeze(E),new(function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var t=function(){};return Object.setPrototypeOf(t,this),Object.defineProperties(t,{info:{value:function(){},configurable:!1,writable:!1},warn:{value:function(){},configurable:!1,writable:!1},error:{value:function(){},configurable:!1,writable:!1},type:{value:!1,configurable:!1,writable:!1}}),t},(t=[{key:"clear",value:function(){}}])&&S(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}())({name:"earthnut",type:!1});var F=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t={list:[],diameter:48,radius:0,cells:0};t.diameter%2!=0&&t.diameter++;var r=t.diameter,n=t.list,i=r/2;t.radius=i,t.cells=Math.pow(r,2);for(var o=0;o<r;o++){n[o]=[];for(var a=0;a<r;a++)n[o][a]=[0,0,0,0]}for(var u=0;u<=i;u++)for(var l=u;l<=i;l++){var s=n[u][l],c=function(){return(0,b.getRandomInt)(255,190)};s[0]=c(),s[1]=c(),s[2]=c(),s[3]=Math.ceil(Math.sqrt(Math.pow(u,2)+Math.pow(l,2)))<=i?(0,b.getRandomInt)(120,180):(0,b.getRandomInt)(160,240)}for(var f=0;f<=i;f++)for(var d=0;d<=f;d++)n[f][d]=n[d][f];for(var p=i;p<r;p++)for(var h=0;h<=i;h++)n[p][h]=n[r-p][h];for(var y=0;y<i;y++)for(var m=i;m<r;m++)n[y][m]=n[y][r-m];for(var v=i;v<r;v++)for(var g=i;g<r;g++)n[v][g]=n[v][r-g];var w=e%r;return t.list=[].concat(j(n.slice(w)),j(n.slice(0,w))),t},I=new(w=new WeakMap,function(){return e=function e(){var t,r,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),function(e,t,r){(function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")})(e,t),t.set(e,r)}(this,w,1),t=this,r="data",n=F(),(r=x(r))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n},(t=[{key:"build",value:function(){k(w,this)>100&&A(w,this,0),this.data=F(A(w,this,k(w,this)+3))}}])&&T(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}());function N(e,t){var r=document.createElement("canvas"),n=document.createElement("canvas"),i=r.getContext("2d"),o=n.getContext("2d");return(0,s.isNull)(i)||(0,s.isNull)(o)?r:(r.width=n.width=e,r.height=n.height=t,i.clearRect(0,0,e,t),o.clearRect(0,0,e,t),i.globalAlpha=1,i.putImageData(function(e,t){Date.now();for(var r=new ImageData(e,t),n=r.data,i=I.data,o=i.diameter,a=i.list,u=e*o,l=0;l<n.length;l+=4){var s=l/4%u,c=s%e%o,f=Math.floor(s/e),d=a[c][f];n[l]=d[0],n[l+1]=d[1],n[l+2]=d[2],n[l+3]=d[3]}return r}(e,t),0,0),o.fillStyle="#ffffff",o.fillRect(0,0,e,t),o.drawImage(r,0,0,e,t),o.globalCompositeOperation="source-over",n)}function L(){var e=this.fadeData,t=e.backgroundInfo,r=t.width,n=t.height;I.build(),e.toBeList.push(N(r,n)),e.run()}function C(){var e=this,t=this.renderData,r=this.options,n=this.fadeData;if((0,s.isNull)(t))Reflect.apply(L,this,[]);else{var i,o,a=t.lastUseStyle,u=n.backgroundInfo,l=u.width,c=u.height,f=r.imageUrl||(i=a.backgroundImage,o=/url\(["']?([^"']*)["']?\)/.exec(i),(0,s.isNull)(o)?null:o[1]);if(t.imageSource=f,f){var d=function(e,t,r){var n=new Image(t,r);return n.width=t,n.height=r,n.src=e,n}(f,l,c);d.onload=function(){clearTimeout(n.transparentId),n.toBeList=n.toBeList.filter((function(e){return"img"===e.tagName.toLowerCase()&&e.getAttribute("src")!==f&&e.width===l&&e.height===c})),n.toBeList.push(d),n.run()},d.onerror=function(){Reflect.apply(L,e,[])},d.crossOrigin=r.crossOrigin}else Reflect.apply(L,this,[])}}function U(){var e=this.renderData;if(!(0,s.isNull)(e)){var t=e.parentElement;t&&[["background-image","none"],["background-color","transparent"]].forEach((function(e){return t.style.setProperty(e[0],e[1],"important")}))}}function B(e){var t=window.getComputedStyle(e),r=e.style;return{inlineBackground:r.background,inlineBackgroundColor:r.backgroundColor,inlineBackgroundImage:r.backgroundImage,backgroundColor:t.backgroundColor,backgroundImage:t.backgroundImage,backgroundSize:t.backgroundSize,backgroundPosition:t.backgroundPosition,backgroundRepeat:t.backgroundRepeat,backgroundClip:t.backgroundClip,backgroundOrigin:t.backgroundOrigin,backgroundAttachment:t.backgroundAttachment,position:t.position}}function X(e){return X="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},X(e)}function z(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,W(n.key),n)}}function M(e,t,r){return t&&z(e.prototype,t),r&&z(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function G(e,t,r){return(t=W(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function W(e){var t=function(e){if("object"!=X(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=X(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==X(t)?t:t+""}var H=M((function e(t,r,n){var i,o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),G(this,"quad",null),G(this,"lastRaindropsFallTime",0),G(this,"parentElement",void 0),G(this,"mutationObserver",void 0),G(this,"resizeObserver",void 0),G(this,"renderProgram",void 0),G(this,"imageSource",""),G(this,"dropProgram",void 0),G(this,"updateProgram",void 0),G(this,"textures",[]),G(this,"backgroundTexture",[]),G(this,"textureDelta",void 0),G(this,"framebuffers",[]),G(this,"bufferWriteIndex",0),G(this,"bufferReadIndex",1),G(this,"originStyle",void 0),G(this,"lastUseStyle",void 0),G(this,"events",{}),G(this,"animationFrameId",0),this.parentElement=null!==(i=t.parentElement)&&void 0!==i?i:document.body,Reflect.apply(U,n,[]),this.originStyle=this.lastUseStyle=B(this.parentElement),this.mutationObserver=new MutationObserver((function(e){e.forEach((function(e){var t,i;if(e.target===o.parentElement&&"attributes"===e.type&&n.options.visible){var a=Object.values(o.lastUseStyle),u=B(o.parentElement),l=Object.values(u);if((0,s.isEmptyArray)(b.enArr.difference(a,l)))return;var c="none"===(i=u.backgroundImage)||""===i,f="rgba(0, 0, 0, 0)"===(t=u.backgroundColor)||"#ffffffff"===t||"transport"===t;if(c&&f)return;o.lastUseStyle=u,Reflect.apply(r,n,[]),Reflect.apply(U,n,[])}}))})),this.mutationObserver.observe(this.parentElement,{subtree:!0,attributes:!0,attributeFilter:["class","style"]}),this.resizeObserver=new ResizeObserver((function(){Reflect.apply(r,n,[])})),this.resizeObserver.observe(this.parentElement)}));function Q(){var e=this.renderData,t=this.fadeData;if(!(0,s.isNull)(e)){var r,n,i,o=e.parentElement,a=window.getComputedStyle(o),u=a.backgroundSize,l=a.backgroundAttachment,c=a.backgroundPosition,f=/\s+/.test(r=c)?r.replace(/center/,"50%").replace(/top|left/,"0%").replace(/bottom/,"100%").replace(/\s+/," ").split(" "):Y(r)?[r,"50%"]:{center:["50%","50%"],top:["50%","0%"],bottom:["50%","100%"],left:["0%","50%"],right:["100%","50%"]}[r],d={left:0,top:0,width:0,height:0};"fixed"===l?(d.height=window.innerHeight,d.left=window.screenX,d.top=window.screenY,d.width=window.innerWidth):(d.left=0,d.top=0,d.width=o.scrollWidth,d.height=o.scrollHeight);var p=t.backgroundInfo||{width:100,height:100},h=p.width,y=p.height;if("cover"===u){var m=Math.max(d.width/h,d.height/y);n=h*m,i=y*m}else if("contain"===u){var v=Math.min(d.width/h,d.height/y);n=h*v,i=y*v}else{var g=u.split(" ");n=g[0]||"",i=g[1]||n,Y(n)?n=d.width*parseFloat(n)/100:"auto"!==n&&(n=parseFloat(n)),Y(i)?i=d.height*parseFloat(i)/100:"auto"!==i&&(i=parseFloat(i)),"auto"===n&&"auto"===i?(n=h,i=y):("auto"===n&&(n=h*(Number(i)/y)),"auto"===i&&(i=y*(Number(n)/h)))}var b=f&&f[0]||"0%",w=f&&f[1]||"0%";b=Y(b)?(d.left+(d.width-Number(n))*parseFloat(b)/100).toString():(d.left+parseFloat(b)).toString(),w=Y(w)?(d.top+(d.height-Number(i))*parseFloat(w)/100).toString():(d.top+parseFloat(w)).toString(),e.renderProgram.uniforms.topLeft=new Float32Array([(o.offsetLeft-Number(b))/n,(o.offsetTop-Number(w))/i]),e.renderProgram.uniforms.bottomRight=new Float32Array([e.renderProgram.uniforms.topLeft[0]+o.clientWidth/n,e.renderProgram.uniforms.topLeft[1]+o.clientHeight/i]);var E=Math.max(this.canvas.width,this.canvas.height);e.renderProgram.uniforms.containerRatio=new Float32Array([this.canvas.width/E,this.canvas.height/E])}}function Y(e){return e.endsWith("%")}function q(){var e=this.gl,t=this.renderData;(0,s.isNull)(t)||(e.bindBuffer(e.ARRAY_BUFFER,t.quad),e.vertexAttribPointer(0,2,e.FLOAT,!1,0,0),e.drawArrays(e.TRIANGLE_FAN,0,4))}function Z(){var e=this.gl,t=this.renderData,r=this.options;if(!(0,s.isNull)(t)){var n=t.textures,i=t.backgroundTexture,o=r.perturbance;e.bindFramebuffer(e.FRAMEBUFFER,null),e.viewport(0,0,this.canvas.width,this.canvas.height),e.enable(e.BLEND),e.clear(e.COLOR_BUFFER_BIT|e.DEPTH_BUFFER_BIT),e.useProgram(t.renderProgram.id),Reflect.apply(f,this,[i,0]),Reflect.apply(f,this,[n[0],1]),e.uniform1f(t.renderProgram.locations.perturbance,o),e.uniform2fv(t.renderProgram.locations.topLeft,t.renderProgram.uniforms.topLeft),e.uniform2fv(t.renderProgram.locations.bottomRight,t.renderProgram.uniforms.bottomRight),e.uniform2fv(t.renderProgram.locations.containerRatio,t.renderProgram.uniforms.containerRatio),e.uniform1i(t.renderProgram.locations.samplerBackground,0),e.uniform1i(t.renderProgram.locations.samplerRipples,1),Reflect.apply(q,this,[]),e.disable(e.BLEND)}}function V(){var e=this.renderData;if(!(0,s.isNull)(e)){var t=e.bufferWriteIndex,r=e.bufferReadIndex;e.bufferWriteIndex=1-t,e.bufferReadIndex=1-r}}function K(){var e=this.gl,t=this.renderData,r=this.options;if(!(0,s.isNull)(t)){var n=t.updateProgram,i=t.textures,o=t.framebuffers,a=t.bufferWriteIndex,u=t.bufferReadIndex,l=r.resolution;e.viewport(0,0,l,l),e.bindFramebuffer(e.FRAMEBUFFER,o[a]),Reflect.apply(f,this,[i[u]]),e.useProgram(n.id),Reflect.apply(q,this,[]),Reflect.apply(V,this,[])}}function J(){var e=this,t=this.renderData,r=this.options,n=this.fadeData;if(!(0,s.isNull)(t)){var i=t.parentElement,o=n.isTransitioning,a=r.running,u=r.idleFluctuations,l=r.lastRunningState,c=getComputedStyle(i);n.backgroundInfo={width:parseInt(c.width),height:parseInt(c.height)},Reflect.apply(Q,this,[]),a?(l||(r.lastRunningState=!0,this.show()),u&&this.raindropsFall(),o&&this.fade(),Reflect.apply(K,this,[]),Reflect.apply(Z,this,[])):l&&(r.lastRunningState=!1,this.hide()),t.animationFrameId=requestAnimationFrame((function(){return Reflect.apply(J,e,[])}))}}function $(e,t,r){var n=this.renderData;if(!(0,s.isNull)(n)){var i=n.parentElement,o=window.getComputedStyle(i),a=parseInt(o.borderLeftWidth)||0,u=parseInt(o.borderTopWidth)||0,l=i.getBoundingClientRect(),c=e.clientX-l.left-a,f=e.clientY-l.top-u;this.drop(c,f,t,r)}}function ee(){var e=this,t=this.renderData,r=this.options;if(!(0,s.isNull)(t)){var n=t.parentElement,i=t.events,o=function(n){var i=arguments.length>1&&void 0!==arguments[1]&&arguments[1];r.visible&&r.running&&r.interactive&&(t.lastRaindropsFallTime=Date.now(),Reflect.apply($,e,[n,r.dropRadius*(i?1.5:1),i?.03:.01]))};i.mousemove=function(e){for(var t=r.accelerating;t--;)o(e)},i.touchmove=i.touchstart=function(e){for(var t=e.touches,r=0;r<t.length;r++)o(t[r])},i.mousedown=function(e){return o(e,!0)},Object.keys(i).forEach((function(e){return null==n?void 0:n.addEventListener(e,i[e],{passive:!0})}))}}var te="\n attribute vec2 vertex;\n varying vec2 coord;\n void main() {\n coord = vertex * 0.5 + 0.5;\n gl_Position = vec4(vertex, 0.0, 1.0);\n }";function re(){var e=this.gl,t=this.renderData;if(!(0,s.isNull)(t)){var r=t.textureDelta;t.dropProgram=c(te,"precision highp float;\n\n const float PI = 3.141592653589793;\n uniform sampler2D texture;\n uniform vec2 center;\n uniform float radius;\n uniform float strength;\n\n varying vec2 coord;\n\n void main() {\n vec4 info = texture2D(texture, coord);\n\n float drop = max(0.0, 1.0 - length(center * 0.5 + 0.5 - coord) / radius);\n drop = 0.5 - cos(drop * PI) * 0.5;\n info.r += drop * strength;\n gl_FragColor = info;\n }",e);var n=t.updateProgram=c(te,"\n precision highp float;\n\n uniform sampler2D texture;\n uniform vec2 delta;\n\n varying vec2 coord;\n\n void main() {\n vec4 info = texture2D(texture, coord);\n \n vec2 dx = vec2(delta.x, 0.0);\n vec2 dy = vec2(0.0, delta.y);\n \n float average = (\n texture2D(texture, coord - dx).r +\n texture2D(texture, coord - dy).r +\n texture2D(texture, coord + dx).r +\n texture2D(texture, coord + dy).r\n ) * 0.25;\n \n info.g += (average - info.r) * 2.0;\n info.g *= 0.995;\n info.r += info.g;\n \n gl_FragColor = info;\n }\n ",this.gl);e.uniform2fv(n.locations.delta,r),t.renderProgram=c("\n precision highp float;\n\n attribute vec2 vertex;\n uniform vec2 topLeft;\n uniform vec2 bottomRight;\n uniform vec2 containerRatio;\n varying vec2 ripplesCoord;\n varying vec2 backgroundCoord;\n void main() {\n backgroundCoord = mix(topLeft, bottomRight, vertex * 0.5 + 0.5);\n backgroundCoord.y = 1.0 - backgroundCoord.y;\n ripplesCoord = vec2(vertex.x, -vertex.y) * containerRatio * 0.5 + 0.5;\n gl_Position = vec4(vertex.x, -vertex.y, 0.0, 1.0);\n }\n ","\n precision highp float;\n\n uniform sampler2D samplerBackground;\n uniform sampler2D samplerRipples;\n uniform vec2 delta;\n\n uniform float perturbance;\n varying vec2 ripplesCoord;\n varying vec2 backgroundCoord;\n\n void main() {\n float height = texture2D(samplerRipples, ripplesCoord).r;\n float heightX = texture2D(samplerRipples, vec2(ripplesCoord.x + delta.x, ripplesCoord.y)).r;\n float heightY = texture2D(samplerRipples, vec2(ripplesCoord.x, ripplesCoord.y + delta.y)).r;\n vec3 dx = vec3(delta.x, heightX - height, 0.0);\n vec3 dy = vec3(0.0, heightY - height, delta.y);\n vec2 offset = -normalize(cross(dy, dx)).xz;\n float specular = pow(max(0.0, dot(offset, normalize(vec2(-0.6, 1.0)))), 4.0);\n gl_FragColor = texture2D(samplerBackground, backgroundCoord + offset * perturbance) + specular;\n }",e),e.uniform2fv(t.renderProgram.locations.delta,r)}}function ne(){var e=this.gl,t=this.renderData;if(!(0,s.isNull)(t)){var r=t.backgroundTexture=e.createTexture();e.bindTexture(e.TEXTURE_2D,r),e.pixelStorei(e.UNPACK_FLIP_Y_WEBGL,1),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR)}}function ie(e){var t=this.gl,r=this.renderData,n=this.fadeData;if(!(0,s.isNull)(r)){var i=r.backgroundTexture,o=n.backgroundInfo,a=o.width,u=o.height,l=function(e){return(0,s.isZero)(e&e-1)},c=l(a)&&l(u)?t.REPEAT:t.CLAMP_TO_EDGE;t.bindTexture(t.TEXTURE_2D,i),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,c),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,c),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,t.RGBA,t.UNSIGNED_BYTE,e)}}function oe(){var e=this,t=this.renderData,r=this.options,n=this.fadeData;if(!(0,s.isNull)(t)&&this.config){var i=t.textures,o=t.framebuffers,a=r.resolution,u=this.gl,l=1/a;t.textureDelta=new Float32Array([l,l]),this.config.extensions.forEach((function(e){return u.getExtension(e)}));for(var c=this.config.arrayType,f=c?new c(a*a*4):null,d=this.config,p=0;p<2;p++){var h=u.createTexture(),y=u.createFramebuffer();u.bindFramebuffer(u.FRAMEBUFFER,y),u.bindTexture(u.TEXTURE_2D,h),u.texParameteri(u.TEXTURE_2D,u.TEXTURE_MIN_FILTER,d.linearSupport?u.LINEAR:u.NEAREST),u.texParameteri(u.TEXTURE_2D,u.TEXTURE_MAG_FILTER,d.linearSupport?u.LINEAR:u.NEAREST),u.texParameteri(u.TEXTURE_2D,u.TEXTURE_WRAP_S,u.CLAMP_TO_EDGE),u.texParameteri(u.TEXTURE_2D,u.TEXTURE_WRAP_T,u.CLAMP_TO_EDGE),u.texImage2D(u.TEXTURE_2D,0,u.RGBA,a,a,0,u.RGBA,d.type,f),u.framebufferTexture2D(u.FRAMEBUFFER,u.COLOR_ATTACHMENT0,u.TEXTURE_2D,h,0),i.push(h),o.push(y)}t.quad=u.createBuffer(),u.bindBuffer(u.ARRAY_BUFFER,t.quad),u.bufferData(u.ARRAY_BUFFER,new Float32Array([-1,-1,1,-1,1,1,-1,1]),u.STATIC_DRAW),Reflect.apply(re,this,[]),Reflect.apply(ne,this,[]),Reflect.apply(L,this,[]),Reflect.apply(C,this,[]),u.clearColor(0,0,0,0),u.blendFunc(u.SRC_ALPHA,u.ONE_MINUS_SRC_ALPHA),r.visible=!0,r.running=!0,Reflect.apply(ee,this,[]),Reflect.apply(ie,this,[n.lastDrawImage]),t.animationFrameId=requestAnimationFrame((function(){return Reflect.apply(J,e,[])}))}}function ae(){var e=this.renderData,t=this.fadeData;if(!(0,s.isNull)(e)){var r=e.parentElement,n=t.backgroundInfo,i=r.offsetWidth,o=r.offsetHeight;this.canvas.width=n.width=i,this.canvas.height=n.height=o,Reflect.apply(C,this,[])}}function ue(){var e=this.renderData;if(!(0,s.isNull)(e)){var t=e.parentElement,r=e.originStyle;t.style.setProperty("background-image",r.inlineBackgroundImage),t.style.setProperty("background-color",r.inlineBackgroundColor)}}function le(){var e=this.renderData,t=this.fadeData;if(!(0,s.isNull)(e)){if(e.animationFrameId&&window.cancelAnimationFrame(e.animationFrameId),t.transparentId&&clearTimeout(t.transparentId),null!=e&&e.parentElement&&null!=e&&e.events){var r,n,i,o=e.parentElement,a=e.events;Object.keys(a).forEach((function(e){return o.removeEventListener&&o.removeEventListener(e,a[e])})),o.removeAttribute&&o.removeAttribute("data-ripples"),null===(r=e.mutationObserver)||void 0===r||r.takeRecords(),null===(n=e.mutationObserver)||void 0===n||n.disconnect(),e.mutationObserver=null,null===(i=e.resizeObserver)||void 0===i||i.disconnect(),e.resizeObserver=null}this.gl=null,Reflect.apply(ue,this,[]),Object.keys(e).forEach((function(t){return e[t]=null})),this.renderData=null,this.gl&&(this.gl=null)}}function se(e,t,r,n){var i=this.renderData,o=this.options,a=this.gl;if(!(0,s.isNull)(i)){var u=i.parentElement,l=i.dropProgram,c=i.textures,d=i.framebuffers,p=i.bufferWriteIndex,h=i.bufferReadIndex,y=o.resolution,m=u.offsetWidth,v=u.offsetHeight,g=Math.max(m,v);r/=g;var b=new Float32Array([(2*e-m)/g,(v-2*t)/g]);a.viewport(0,0,y,y),a.bindFramebuffer(a.FRAMEBUFFER,d[p]),Reflect.apply(f,this,[c[h]]),a.useProgram(l.id),a.uniform2fv(l.locations.center,b),a.uniform1f(l.locations.radius,r),a.uniform1f(l.locations.strength,n),Reflect.apply(q,this,[]),Reflect.apply(V,this,[])}}function ce(e){return ce="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ce(e)}function fe(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,pe(n.key),n)}}function de(e,t,r){return(t=pe(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function pe(e){var t=function(e){if("object"!=ce(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=ce(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ce(t)?t:t+""}function he(e,t,r){(function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")})(e,t),t.set(e,r)}function ye(e,t){return e.get(ve(e,t))}function me(e,t,r){return e.set(ve(e,t),r),r}function ve(e,t,r){if("function"==typeof e?e===t:e.has(t))return arguments.length<3?t:r;throw new TypeError("Private element is not present on this object")}var ge=new WeakMap,be=new WeakMap,we=new WeakMap,Ee=new WeakMap,Re=new WeakMap,Se=new WeakMap,Pe=new WeakMap,Oe=function(){return e=function e(t){var r;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),he(this,ge,E.accelerating),he(this,be,E.interactive),he(this,we,E.resolution),he(this,Ee,E.perturbance),he(this,Re,E.dropRadius),de(this,"imageUrl",E.imageUrl),he(this,Se,E.idleFluctuations),he(this,Pe,E.raindropsTimeInterval),de(this,"crossOrigin","no-cors"),de(this,"visible",!1),de(this,"running",!1),de(this,"lastRunningState",!1),this.perturbance=t.perturbance,this.resolution=t.resolution,this.raindropsTimeInterval=t.raindropsTimeInterval,this.accelerating=t.accelerating,this.interactive=t.interactive,this.dropRadius=t.dropRadius,this.imageUrl=t.imageUrl,this.idleFluctuations=t.idleFluctuations,this.running=Boolean(null===(r=t.playingState)||void 0===r||r),this.crossOrigin=t.crossOrigin},(t=[{key:"accelerating",get:function(){return ye(ge,this)},set:function(e){e>100||e<2||me(ge,this,e)}},{key:"interactive",get:function(){return ye(be,this)},set:function(e){(0,s.isBoolean)(e)&&me(be,this,e)}},{key:"resolution",get:function(){return ye(we,this)},set:function(e){e<100||e>550||me(we,this,e)}},{key:"perturbance",get:function(){return ye(Ee,this)},set:function(e){e<1e-4||e>1||me(Ee,this,e)}},{key:"dropRadius",get:function(){return ye(Re,this)},set:function(e){!isFinite(e)||e<10||me(Re,this,e)}},{key:"idleFluctuations",get:function(){return ye(Se,this)},set:function(e){(0,s.isBoolean)(e)&&me(Se,this,e)}},{key:"raindropsTimeInterval",get:function(){return ye(Pe,this)},set:function(e){e<10||e>12e3||me(Pe,this,e)}},{key:"playingState",get:function(){return this.running},set:function(e){this.running=Boolean(null==e||e)}}])&&fe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function Te(){var e=this,t=this.options,r=this.fadeData;r.transparentId=setTimeout((function(){if(clearTimeout(r.transparentId),r.isTransitioning)return Reflect.apply(Te,e,[]);r.drawProgress=0,r.isTransitioning=!0}),2*t.raindropsTimeInterval)}function xe(){var e=this.renderData,t=this.fadeData,r=t.toBeList,n=t.drawProgress,i=t.lastDrawImage,o=t.backgroundInfo;if(!(0,s.isNull)(e)&&!(0,s.isEmptyArray)(r)){if(t.drawProgress>1e3)return t.isTransitioning=!1,t.lastDrawImage=r.shift(),Reflect.apply(ie,this,[t.lastDrawImage]),void((0,s.isEmptyArray)(r)||Reflect.apply(Te,this,[]));t.drawProgress+=18;var a=document.createElement("canvas"),u=a.getContext("2d");if(!((0,s.isNull)(u)||(0,s.isNull)(i)||(0,s.isEmptyArray)(r))){var l=o.width,c=o.height;a.width=l,a.height=c,u.clearRect(0,0,l,c),u.drawImage(i,0,0,l,c),u.globalAlpha=n/1e3,u.drawImage(r[0],0,0,l,c),u.globalAlpha=1,Reflect.apply(ie,this,[a])}}}function Ae(e){return Ae="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ae(e)}function ke(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,je(n.key),n)}}function De(e,t,r){return(t=je(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function je(e){var t=function(e){if("object"!=Ae(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=Ae(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ae(t)?t:t+""}var _e=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),De(this,"backgroundInfo",{width:0,height:0}),De(this,"transparentId",setTimeout(Boolean)),De(this,"lastDrawImage",void 0),De(this,"toBeList",[]),De(this,"drawProgress",0),De(this,"isTransitioning",!1);var r,n,i=t.renderData;if((0,s.isNull)(i))r=10,n=10;else{var o=getComputedStyle(i.parentElement);r=parseInt(o.width),n=parseInt(o.height)}this.backgroundInfo={width:r,height:n},this.lastDrawImage=N(r,n)},(t=[{key:"run",value:function(){this.isTransitioning||(this.drawProgress=0,this.isTransitioning=!0)}}])&&ke(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function Fe(e){return Fe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Fe(e)}function Ie(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ne(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ie(Object(r),!0).forEach((function(t){Xe(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ie(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Le(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,ze(n.key),n)}}function Ce(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Ce=function(){return!!e})()}function Ue(e){return Ue=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Ue(e)}function Be(e,t){return Be=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Be(e,t)}function Xe(e,t,r){return(t=ze(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ze(e){var t=function(e){if("object"!=Fe(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=Fe(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Fe(t)?t:t+""}var Me=new WeakMap,Ge=function(e){function t(e,r){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Xe(n=function(e,t,r){return t=Ue(t),function(e,t){if(t&&("object"==Fe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Ce()?Reflect.construct(t,r||[],Ue(e).constructor):t.apply(e,r))}(this,t,[e]),"renderData",null),Xe(n,"options",void 0),Xe(n,"fadeData",void 0),Xe(n,"defaults",E),Xe(n,"initialized",!1),function(e,t,r){(function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")})(e,t),t.set(e,r)}(n,Me,(0,b.debounce)(ae,{this:n})),Object.defineProperties(n,{defaults:{value:n.defaults,writable:!1,enumerable:!1,configurable:!1}}),n.options=new Oe(Ne(Ne({},n.defaults),r)),n.renderData=new H(e,n.reloadBackground,n),n.fadeData=new _e(n),(0,s.isFalse)(n.initState)||(0,s.isNull)(e.parentElement)||(0,s.isNull)(n.config)||(0,s.isNull)(n.gl)?n.initState=!1:(function(e){var t=e.parentElement;e.width=t.clientWidth,e.height=t.clientHeight,(0,a.setStyle)(e,{position:"absolute",left:0,top:0,right:0,bottom:0,zIndex:-1,pointerEvents:"none"})}(e),Reflect.apply(oe,n,[])),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Be(e,t)}(t,e),r=t,n=[{key:"raindropsFall",value:function(){var e=this.renderData,t=this.options,r=this.fadeData;if(!(0,s.isNull)(e)){var n=r.backgroundInfo,i=e.lastRaindropsFallTime,o=t.raindropsTimeInterval,a=t.dropRadius,u=Date.now();if(!(u-i<o)){e.lastRaindropsFallTime=u;var l=function(e){return(0,b.getRandomInt)(e)},c=n.width,f=n.height;this.drop(l(c),l(f),a,.03)}}}},{key:"drop",value:function(e,t,r,n){Reflect.apply(se,this,[e,t,r,n])}},{key:"fade",value:function(){Reflect.apply(xe,this,[])}},{key:"reloadBackground",value:function(){var e,t;(e=Me,t=this,e.get(function(e,t,r){if("function"==typeof e?e===t:e.has(t))return arguments.length<3?t:r;throw new TypeError("Private element is not present on this object")}(e,t))).call(this)}},{key:"destroy",value:function(){Reflect.apply(le,this,[])}},{key:"show",value:function(){this.options.visible=!0,this.canvas.style.visibility="visible",Reflect.apply(U,this,[])}},{key:"hide",value:function(){this.options.visible=!1,this.canvas.style.visibility="hidden",Reflect.apply(ue,this,[])}},{key:"pause",value:function(){this.options.running=!1}},{key:"play",value:function(){this.options.running=!0}},{key:"changePlayingState",value:function(){var e=this.options;e.running=!e.running}},{key:"set",value:function(e,t){"imageUrl"===e?(this.options.imageUrl=t,Reflect.apply(C,this,[])):this.options[e]=t}}],n&&Le(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(g);function We(e,t){var r=(0,o.useRef)(null);return(0,o.useEffect)((function(){if(!(0,s.isNull)(e.current))return r.current=new Ge(e.current,t&&t.option),function(){var e,t;return null!==(e=null===(t=r.current)||void 0===t?void 0:t.destroy())&&void 0!==e?e:void 0}}),[]),r}},825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(r){!function(e,t,r){var n="";r.supports&&(n+="@supports (".concat(r.supports,") {")),r.media&&(n+="@media ".concat(r.media," {"));var i=void 0!==r.layer;i&&(n+="@layer".concat(r.layer.length>0?" ".concat(r.layer):""," {")),n+=r.css,i&&(n+="}"),r.media&&(n+="}"),r.supports&&(n+="}");var o=r.sourceMap;o&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}}},a={};function u(e){var t=a[e];if(void 0!==t)return t.exports;var r=a[e]={id:e,exports:{}};return o[e](r,r.exports,u),r.exports}u.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return u.d(t,{a:t}),t},u.d=(e,t)=>{for(var r in t)u.o(t,r)&&!u.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},u.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),u.nc=void 0;var l=u(153),s=u(363),c=u(195),f=u(552),d=u(615),p=u(707);const h=c.t,y=p.n,m=f.O;export{h as useInputIsComposing,y as useRipples,m as useTimeId};export const BackgroundRipple=l.z;export const EnLayout=s.wb;export const EnLayoutContent=s.Ht;export const EnLayoutFooter=s.zE;export const EnLayoutHeader=s.n5;export const EnLayoutSideBar=s.AX;export const Layout=s.PE;export const LayoutContent=s.A1;export const LayoutFooter=s.cZ;export const LayoutHeader=s.KL;export const LayoutSideBar=s.nb;export const useAnimationFrameId=d.M;
|
package/package.json
CHANGED
|
@@ -1,29 +1,102 @@
|
|
|
1
1
|
{
|
|
2
|
+
"main": "index.cjs",
|
|
3
|
+
"module": "index.mjs",
|
|
4
|
+
"types": "index.d.ts",
|
|
5
|
+
"author": {
|
|
6
|
+
"name": "🥜",
|
|
7
|
+
"email": "earthnut.dev@outlook.com",
|
|
8
|
+
"url": "https://earthnut.dev"
|
|
9
|
+
},
|
|
10
|
+
"type": "module",
|
|
2
11
|
"name": "earthnut",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
"
|
|
12
|
+
"version": "0.0.1",
|
|
13
|
+
"description": "earthnut 的 react ui",
|
|
14
|
+
"overrides": {
|
|
15
|
+
"css-loader": "6.11.0"
|
|
16
|
+
},
|
|
17
|
+
"dependencies": {
|
|
18
|
+
"@qqi/log": "^0.0.2",
|
|
19
|
+
"a-element-inline-style": "^0.0.1",
|
|
20
|
+
"a-js-tools": "^1.0.5",
|
|
21
|
+
"a-type-of-js": "^1.0.2",
|
|
22
|
+
"eslint-plugin-jsdoc": "^51.3.1",
|
|
23
|
+
"xcn": "^0.1.1"
|
|
7
24
|
},
|
|
8
|
-
"author": "lmssee <lmssee@outlook.com> (https://lmssee.com)",
|
|
9
|
-
"homepage": "https://lmssee.com/iggg",
|
|
10
|
-
"license": "ISC",
|
|
11
|
-
"description": "iggg",
|
|
12
25
|
"files": [
|
|
13
|
-
"
|
|
26
|
+
"BackgroundRipple",
|
|
27
|
+
"components",
|
|
28
|
+
"customHooks",
|
|
29
|
+
"Layout",
|
|
30
|
+
"styles",
|
|
31
|
+
"useAnimationFrame",
|
|
32
|
+
"useInputIsComposing",
|
|
33
|
+
"useRipples",
|
|
34
|
+
"useTimeId",
|
|
35
|
+
"index.cjs",
|
|
36
|
+
"index.cjs.map",
|
|
37
|
+
"dog.d.ts",
|
|
38
|
+
"index.d.ts",
|
|
39
|
+
"index.js.LICENSE.txt",
|
|
40
|
+
"index.mjs"
|
|
14
41
|
],
|
|
15
|
-
"
|
|
16
|
-
"
|
|
42
|
+
"exports": {
|
|
43
|
+
".": {
|
|
44
|
+
"types": "./index.d.ts",
|
|
45
|
+
"require": "./index.cjs",
|
|
46
|
+
"import": "./index.mjs"
|
|
47
|
+
},
|
|
48
|
+
"./BackgroundRipple": {
|
|
49
|
+
"types": "./components/ripples/index.d.ts",
|
|
50
|
+
"require": "./BackgroundRipple/index.cjs",
|
|
51
|
+
"import": "./BackgroundRipple/index.mjs"
|
|
52
|
+
},
|
|
53
|
+
"./useTimeId": {
|
|
54
|
+
"types": "./customHooks/useTimeId.d.ts",
|
|
55
|
+
"require": "./useTimeId/index.cjs",
|
|
56
|
+
"import": "./useTimeId/index.mjs"
|
|
57
|
+
},
|
|
58
|
+
"./useAnimationFrame": {
|
|
59
|
+
"types": "./customHooks/useAnimationFrame.d.ts",
|
|
60
|
+
"require": "./useAnimationFrame/index.cjs",
|
|
61
|
+
"import": "./useAnimationFrame/index.mjs"
|
|
62
|
+
},
|
|
63
|
+
"./useRipples": {
|
|
64
|
+
"types": "./customHooks/useRipples/index.d.ts",
|
|
65
|
+
"require": "./useRipples/index.cjs",
|
|
66
|
+
"import": "./useRipples/index.mjs"
|
|
67
|
+
},
|
|
68
|
+
"./useInputIsComposing": {
|
|
69
|
+
"types": "./customHooks/useInputIsComposing.d.ts",
|
|
70
|
+
"require": "./useInputIsComposing/index.cjs",
|
|
71
|
+
"import": "./useInputIsComposing/index.mjs"
|
|
72
|
+
},
|
|
73
|
+
"./layout": {
|
|
74
|
+
"types": "./components/layout/index.d.ts",
|
|
75
|
+
"require": "./Layout/index.cjs",
|
|
76
|
+
"import": "./Layout/index.mjs"
|
|
77
|
+
},
|
|
78
|
+
"./scss": "./styles/common.scss",
|
|
79
|
+
"./css": "./styles/common.css"
|
|
17
80
|
},
|
|
18
81
|
"keywords": [
|
|
19
|
-
"
|
|
82
|
+
"earthnut"
|
|
20
83
|
],
|
|
84
|
+
"homepage": "https://earthnut.dev/",
|
|
85
|
+
"bugs": {
|
|
86
|
+
"url": "https://github.com/earthnutDev/earthnut/issues",
|
|
87
|
+
"email": "earthnut.dev@outlook.com"
|
|
88
|
+
},
|
|
21
89
|
"repository": {
|
|
22
90
|
"type": "git",
|
|
23
|
-
"url": "git+https://github.com/
|
|
91
|
+
"url": "git+https://github.com/earthnutDev/earthnut.git"
|
|
24
92
|
},
|
|
25
93
|
"publishConfig": {
|
|
26
94
|
"access": "public",
|
|
27
|
-
"registry": "https://registry.npmjs.org"
|
|
95
|
+
"registry": "https://registry.npmjs.org/"
|
|
96
|
+
},
|
|
97
|
+
"license": "MIT",
|
|
98
|
+
"peerDependencies": {
|
|
99
|
+
"react": ">= 17",
|
|
100
|
+
"react-dom": ">= 17"
|
|
28
101
|
}
|
|
29
102
|
}
|