aptechka 0.3.1 → 0.4.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.
Files changed (140) hide show
  1. package/lib/{Damped-BvkThM-2.cjs → Damped-B0eRyTcV.cjs} +1 -1
  2. package/lib/{Damped-DEHDBwBz.js → Damped-Do9H-LKf.js} +1 -1
  3. package/lib/{Derived-Bc88XJ8J.js → Derived-Dbjm-dob.js} +1 -1
  4. package/lib/{Derived-SjPdLJiZ.cjs → Derived-vGokdC4b.cjs} +1 -1
  5. package/lib/{SourceManager-CI6NfLzW.cjs → SourceManager-CzcqsC3z.cjs} +1 -1
  6. package/lib/{SourceManager-BoP9RAJr.js → SourceManager-noBYGNeX.js} +1 -1
  7. package/lib/{Store-JOKrNVEr.js → Store-DdDuj5hz.js} +42 -41
  8. package/lib/Store-Dis8QUAR.cjs +1 -0
  9. package/lib/{Viewport-COsaberc.cjs → Viewport-CRLSlcoi.cjs} +1 -1
  10. package/lib/{Viewport-CXY5xcGJ.js → Viewport-VSV_isot.js} +1 -1
  11. package/lib/{WheelControls-BJdZsEkS.js → WheelControls-BqO_fTyY.js} +1 -1
  12. package/lib/{WheelControls-CctFwJwY.cjs → WheelControls-fiz52vcl.cjs} +1 -1
  13. package/lib/abstract-elements/index.cjs +1 -1
  14. package/lib/abstract-elements/index.js +2 -2
  15. package/lib/animation/index.cjs +1 -1
  16. package/lib/animation/index.js +2 -2
  17. package/lib/attribute/index.cjs +1 -1
  18. package/lib/attribute/index.js +2 -2
  19. package/lib/canvas/index.cjs +1 -1
  20. package/lib/canvas/index.js +3 -3
  21. package/lib/controls/index.cjs +1 -1
  22. package/lib/controls/index.js +2 -2
  23. package/lib/{createStylesheet-De-6zF24.cjs → createStylesheet-B4vLzvah.cjs} +1 -1
  24. package/lib/{createStylesheet-CYZlwj0H.js → createStylesheet-CR-XQRVT.js} +1 -1
  25. package/lib/device/index.cjs +1 -1
  26. package/lib/device/index.js +1 -1
  27. package/lib/dom-0S_WDL4g.js +42 -0
  28. package/lib/dom-JBOkFLTh.cjs +1 -0
  29. package/lib/element-constructor/ElementConstructor.d.ts +2 -0
  30. package/lib/element-constructor/index.cjs +1 -1
  31. package/lib/element-constructor/index.js +113 -114
  32. package/lib/element-resizer/index.cjs +1 -1
  33. package/lib/element-resizer/index.js +1 -1
  34. package/lib/en3/core/en3.d.ts +2 -1
  35. package/lib/en3/index.cjs +1 -1
  36. package/lib/en3/index.js +6 -6
  37. package/lib/image/index.cjs +1 -1
  38. package/lib/image/index.js +1 -1
  39. package/lib/{index-8MIh-Dcx.js → index-D-FPaxdJ.js} +3 -3
  40. package/lib/{index-CHamNqUl.cjs → index-MKoD8NCT.cjs} +1 -1
  41. package/lib/intersector/index.cjs +1 -1
  42. package/lib/intersector/index.js +1 -1
  43. package/lib/ladder/index.cjs +1 -1
  44. package/lib/ladder/index.js +1 -1
  45. package/lib/layout-box/index.cjs +1 -1
  46. package/lib/layout-box/index.js +1 -1
  47. package/lib/media/index.cjs +1 -1
  48. package/lib/media/index.js +1 -1
  49. package/lib/modal/index.cjs +1 -1
  50. package/lib/modal/index.js +3 -3
  51. package/lib/popover/index.cjs +1 -1
  52. package/lib/popover/index.js +1 -1
  53. package/lib/resized/index.cjs +1 -1
  54. package/lib/resized/index.js +1 -1
  55. package/lib/router/index.cjs +1 -1
  56. package/lib/router/index.js +93 -98
  57. package/lib/scroll/ScrollElement.d.ts +0 -22
  58. package/lib/scroll/index.cjs +1 -1
  59. package/lib/scroll/index.js +103 -127
  60. package/lib/scroll-entries/index.cjs +1 -1
  61. package/lib/scroll-entries/index.js +16 -17
  62. package/lib/select/index.cjs +1 -1
  63. package/lib/select/index.js +1 -1
  64. package/lib/source/index.cjs +1 -1
  65. package/lib/source/index.js +2 -2
  66. package/lib/store/Store.d.ts +1 -0
  67. package/lib/store/index.cjs +1 -1
  68. package/lib/store/index.js +119 -48
  69. package/lib/studio/index.cjs +1 -1
  70. package/lib/studio/index.js +17 -17
  71. package/lib/tags-D3-tO-m6.cjs +1 -0
  72. package/lib/tags-D9nd9mMM.js +846 -0
  73. package/lib/theme/index.cjs +1 -1
  74. package/lib/theme/index.js +2 -2
  75. package/lib/utils/dom.d.ts +1 -0
  76. package/lib/utils/index.cjs +1 -1
  77. package/lib/utils/index.d.ts +1 -1
  78. package/lib/utils/index.js +68 -67
  79. package/lib/video/index.cjs +1 -1
  80. package/lib/video/index.js +1 -1
  81. package/package.json +1 -65
  82. package/lib/ComponentElement-CIl1lnep.cjs +0 -1
  83. package/lib/ComponentElement-CzGRgBvs.js +0 -76
  84. package/lib/Composed-ClTo1f0b.js +0 -79
  85. package/lib/Composed-Mdr4ZFbI.cjs +0 -1
  86. package/lib/ElementConstructor-C_HDpVEZ.cjs +0 -1
  87. package/lib/ElementConstructor-ChgHpqb6.js +0 -326
  88. package/lib/Store-D0_rDIsE.cjs +0 -1
  89. package/lib/animation/hooks/index.cjs +0 -1
  90. package/lib/animation/hooks/index.d.ts +0 -9
  91. package/lib/animation/hooks/index.js +0 -32
  92. package/lib/attribute/hooks/index.d.ts +0 -3
  93. package/lib/controls/hooks/index.d.ts +0 -1
  94. package/lib/createStore-BSUQyZjo.js +0 -15
  95. package/lib/createStore-D61G4jpF.cjs +0 -1
  96. package/lib/dom-BY7JhTx5.js +0 -24
  97. package/lib/dom-qY2LdCVL.cjs +0 -1
  98. package/lib/element-resizer/hooks/index.cjs +0 -1
  99. package/lib/element-resizer/hooks/index.d.ts +0 -5
  100. package/lib/element-resizer/hooks/index.js +0 -12
  101. package/lib/instantiate-CXUQ7AmI.js +0 -72
  102. package/lib/instantiate-D63dC3Vr.cjs +0 -1
  103. package/lib/intersector/hooks/index.cjs +0 -1
  104. package/lib/intersector/hooks/index.d.ts +0 -5
  105. package/lib/intersector/hooks/index.js +0 -12
  106. package/lib/jsx/ComponentElement.d.ts +0 -26
  107. package/lib/jsx/h.d.ts +0 -4
  108. package/lib/jsx/hooks/attachInternals.d.ts +0 -1
  109. package/lib/jsx/hooks/attachShadow.d.ts +0 -1
  110. package/lib/jsx/hooks/attachStylesheet.d.ts +0 -3
  111. package/lib/jsx/hooks/createContext.d.ts +0 -2
  112. package/lib/jsx/hooks/createStore.d.ts +0 -4
  113. package/lib/jsx/hooks/index.cjs +0 -1
  114. package/lib/jsx/hooks/index.d.ts +0 -8
  115. package/lib/jsx/hooks/index.js +0 -73
  116. package/lib/jsx/hooks/onConnect.d.ts +0 -3
  117. package/lib/jsx/hooks/onDisconnect.d.ts +0 -3
  118. package/lib/jsx/hooks/withCurrentComponent.d.ts +0 -3
  119. package/lib/jsx/index.cjs +0 -1
  120. package/lib/jsx/index.d.ts +0 -5
  121. package/lib/jsx/index.js +0 -27
  122. package/lib/jsx/instantiate.d.ts +0 -1
  123. package/lib/jsx/register.d.ts +0 -1
  124. package/lib/jsx/render.d.ts +0 -1
  125. package/lib/jsx/type.d.ts +0 -186
  126. package/lib/onConnect-CNMynOhK.js +0 -9
  127. package/lib/onConnect-DyAwFqQQ.cjs +0 -1
  128. package/lib/store/hooks/index.cjs +0 -1
  129. package/lib/store/hooks/index.d.ts +0 -7
  130. package/lib/store/hooks/index.js +0 -26
  131. package/lib/tags-DSmoyoPZ.js +0 -485
  132. package/lib/tags-Di21YbUL.cjs +0 -1
  133. package/lib/ticker/hooks/index.cjs +0 -1
  134. package/lib/ticker/hooks/index.d.ts +0 -6
  135. package/lib/ticker/hooks/index.js +0 -23
  136. package/lib/window-resizer/hooks/index.cjs +0 -1
  137. package/lib/window-resizer/hooks/index.d.ts +0 -3
  138. package/lib/window-resizer/hooks/index.js +0 -9
  139. package/lib/withCurrentComponent-BDsFmjJ9.cjs +0 -1
  140. package/lib/withCurrentComponent-DIBND_yO.js +0 -7
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../Store-D0_rDIsE.cjs");const r=require("../browser-CpzFX2xg.cjs"),t=require("../tags-Di21YbUL.cjs"),a=require("../createTheme-B_W5dUY9.cjs"),e=a.createTheme({colorDark:"#1c1c1c",colorDarkAux:"#282828",colorLight:"#ffffff",colorActive:"#00E5B0",tweakerWidth:"500px",tweakerOffset:"20px",tweakerFolderHeight:"40px",heightInput:"30px",borderRadius:"12px",gapLarge:"16px",gapMedium:"12px",gapSmall:"8px",gapExtraSmall:"4px",fontSizeLarge:"20px",fontSizeMedium:"16px",fontSizeSmall:"14px",durationShort:"0.2s"},{prefix:"aptechka-"});r.isBrowser&&document.head.appendChild(t.style({":root":e.style}).node);exports.aptechkaTheme=e;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../Store-Dis8QUAR.cjs");const r=require("../browser-CpzFX2xg.cjs"),t=require("../tags-D3-tO-m6.cjs"),a=require("../createTheme-B_W5dUY9.cjs"),e=a.createTheme({colorDark:"#1c1c1c",colorDarkAux:"#282828",colorLight:"#ffffff",colorActive:"#00E5B0",tweakerWidth:"500px",tweakerOffset:"20px",tweakerFolderHeight:"40px",heightInput:"30px",borderRadius:"12px",gapLarge:"16px",gapMedium:"12px",gapSmall:"8px",gapExtraSmall:"4px",fontSizeLarge:"20px",fontSizeMedium:"16px",fontSizeSmall:"14px",durationShort:"0.2s"},{prefix:"aptechka-"});r.isBrowser&&document.head.appendChild(t.style({":root":e.style}).node);exports.aptechkaTheme=e;
@@ -1,6 +1,6 @@
1
- import "../Store-JOKrNVEr.js";
1
+ import "../Store-DdDuj5hz.js";
2
2
  import { i as e } from "../browser-0zX67oeU.js";
3
- import { aC as r } from "../tags-DSmoyoPZ.js";
3
+ import { aD as r } from "../tags-D9nd9mMM.js";
4
4
  import { c as o } from "../createTheme-D0IoYkYN.js";
5
5
  const t = o(
6
6
  {
@@ -2,3 +2,4 @@ export declare function findParentElement<T extends CustomElementConstructor>(el
2
2
  export type ElementOrSelector<T extends Element = Element> = string | T;
3
3
  export declare function getElement<T extends Element>(elementOrSelector: ElementOrSelector<T> | undefined, from?: Document): T | null | undefined;
4
4
  export declare function findScrollParentElement(node: Node | null, _initial?: Node | null): HTMLElement;
5
+ export declare function getAllParentElements(node: Node): HTMLElement[];
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("../attributes-Bf2svn4j.cjs"),x=require("../browser-CpzFX2xg.cjs"),p=require("../dom-qY2LdCVL.cjs"),a=require("../easings-DsS5-Kqc.cjs"),y=require("../events-Crwi8fz6.cjs"),E=require("../file-EevnUtRj.cjs"),g=require("../function-MthRj-GJ.cjs"),h=require("../layout-8ryRAMGJ.cjs"),o=require("../math-GDWEqu7y.cjs"),f=require("../number-yVpzMdbQ.cjs"),u=require("../object-BZELAoVj.cjs"),I=require("../polyfills-CrcS4RcO.cjs"),l=require("../string-vBu90jhV.cjs"),C=require("../style-At6aDoqG.cjs");function S(t,e,...n){return[...t.slice(0,e),...n,...t.slice(e)]}function w(t,e){const n=t.measureText(e),i=n.actualBoundingBoxAscent+n.actualBoundingBoxDescent,s=n.width;return{height:i,width:s}}function Q(t){return Math.floor(t)+.5}function T(t,e,n,i,s,r){let m=t/e,O=n/i,c=0,d=0;return s=typeof s=="undefined"?.5:s,r=typeof r=="undefined"?.5:r,m>O?(c=i,d=i*m):(d=n,c=n/m),[(n-d)*s,(i-c)*r,d,c]}function v(t,e){return t.x<e.x+e.width&&t.x>e.x&&t.y<e.y+e.height&&t.y>e.y}function q(t,e){return Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2)<e.radius}function D(t,e,n=!1){let i=t.x-e.width/2,s=e.height/2-t.y;return n&&(i=i/(e.width/2),s=s/(e.height/2)),{x:i,y:s}}function P(t,e){const n=t.x/e.x,i=t.y/e.y;return{x:n,y:i}}function R(t,e){return e=e||{x:0,y:0,width:document.documentElement.offsetWidth,height:innerHeight},{x:(t.x-e.x)/e.width*e.width,y:(t.y-e.y)/e.height*e.height}}function A(...t){const e={};return Array.from(document.styleSheets).forEach(n=>{Array.from(n.cssRules).forEach(i=>{i instanceof CSSStyleRule&&i.selectorText===":root"&&t.forEach(s=>{const r=i.styleMap.get(s);r?e[s]=r.toString():console.warn(`variable named ${s} not found`)})})}),e}function N(t){const e=window.atob(t);return decodeURIComponent(window.escape(e))}function z(t){const e=window.unescape(encodeURIComponent(t));return window.btoa(e)}exports.parseAttribute=b.parseAttribute;exports.parseAttributeValue=b.parseAttributeValue;exports.isBrowser=x.isBrowser;exports.findParentElement=p.findParentElement;exports.findScrollParentElement=p.findScrollParentElement;exports.getElement=p.getElement;exports.easeInCubic=a.easeInCubic;exports.easeInExpo=a.easeInExpo;exports.easeInOutCubic=a.easeInOutCubic;exports.easeInOutExpo=a.easeInOutExpo;exports.easeInOutQuad=a.easeInOutQuad;exports.easeInOutQuart=a.easeInOutQuart;exports.easeInOutQuint=a.easeInOutQuint;exports.easeInQuad=a.easeInQuad;exports.easeInQuart=a.easeInQuart;exports.easeInQuint=a.easeInQuint;exports.easeOutCubic=a.easeOutCubic;exports.easeOutExpo=a.easeOutExpo;exports.easeOutQuad=a.easeOutQuad;exports.easeOutQuart=a.easeOutQuart;exports.easeOutQuint=a.easeOutQuint;exports.linear=a.linear;exports.dispatchSizeChangeEvent=y.dispatchSizeChangeEvent;exports.createJSONAndSave=E.createJSONAndSave;exports.debounce=g.debounce;exports.throttle=g.throttle;exports.getCumulativeOffsetLeft=h.getCumulativeOffsetLeft;exports.getCumulativeOffsetTop=h.getCumulativeOffsetTop;exports.getCumulativePosition=h.getCumulativePosition;exports.calculateDistance=o.calculateDistance;exports.calculateDistanceWithRadius=o.calculateDistanceWithRadius;exports.clamp=o.clamp;exports.damp=o.damp;exports.lerp=o.lerp;exports.mapRange=o.mapRange;exports.round=o.round;exports.smootherstep=o.smootherstep;exports.smoothstep=o.smoothstep;exports.step=o.step;exports.preciseNumber=f.preciseNumber;exports.roundNumberTo=f.roundNumberTo;exports.cloneDeep=u.cloneDeep;exports.compareObjects=u.compareObjects;exports.isESClass=u.isESClass;exports.isNullish=u.isNullish;exports.isObject=u.isObject;exports.mergeDeep=u.mergeDeep;exports.mixin=u.mixin;exports.omit=u.omit;exports.pick=u.pick;exports.nullishCoalescing=I.nullishCoalescing;exports.camelToKebab=l.camelToKebab;exports.capitalize=l.capitalize;exports.generateId=l.generateId;exports.kebabToCamel=l.kebabToCamel;exports.snakeToDotted=l.snakeToDotted;exports.toPascalCase=l.toPascalCase;exports.uncapitalize=l.uncapitalize;exports.getElementTransitionDurationMS=C.getElementTransitionDurationMS;exports.getElementTransitionDurationS=C.getElementTransitionDurationS;exports.cover=T;exports.decode=z;exports.dotCircleCollision=q;exports.dotRectCollision=v;exports.encode=N;exports.fixPosition=Q;exports.getPointerPosition=R;exports.getRootVariables=A;exports.insert=S;exports.measureText=w;exports.normalize=P;exports.screenToCartesian=D;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("../attributes-Bf2svn4j.cjs"),x=require("../browser-CpzFX2xg.cjs"),m=require("../dom-JBOkFLTh.cjs"),a=require("../easings-DsS5-Kqc.cjs"),y=require("../events-Crwi8fz6.cjs"),E=require("../file-EevnUtRj.cjs"),b=require("../function-MthRj-GJ.cjs"),h=require("../layout-8ryRAMGJ.cjs"),o=require("../math-GDWEqu7y.cjs"),f=require("../number-yVpzMdbQ.cjs"),u=require("../object-BZELAoVj.cjs"),I=require("../polyfills-CrcS4RcO.cjs"),l=require("../string-vBu90jhV.cjs"),C=require("../style-At6aDoqG.cjs");function S(t,e,...n){return[...t.slice(0,e),...n,...t.slice(e)]}function w(t,e){const n=t.measureText(e),i=n.actualBoundingBoxAscent+n.actualBoundingBoxDescent,s=n.width;return{height:i,width:s}}function Q(t){return Math.floor(t)+.5}function T(t,e,n,i,s,r){let p=t/e,O=n/i,c=0,d=0;return s=typeof s=="undefined"?.5:s,r=typeof r=="undefined"?.5:r,p>O?(c=i,d=i*p):(d=n,c=n/p),[(n-d)*s,(i-c)*r,d,c]}function P(t,e){return t.x<e.x+e.width&&t.x>e.x&&t.y<e.y+e.height&&t.y>e.y}function v(t,e){return Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2)<e.radius}function q(t,e,n=!1){let i=t.x-e.width/2,s=e.height/2-t.y;return n&&(i=i/(e.width/2),s=s/(e.height/2)),{x:i,y:s}}function D(t,e){const n=t.x/e.x,i=t.y/e.y;return{x:n,y:i}}function R(t,e){return e=e||{x:0,y:0,width:document.documentElement.offsetWidth,height:innerHeight},{x:(t.x-e.x)/e.width*e.width,y:(t.y-e.y)/e.height*e.height}}function A(...t){const e={};return Array.from(document.styleSheets).forEach(n=>{Array.from(n.cssRules).forEach(i=>{i instanceof CSSStyleRule&&i.selectorText===":root"&&t.forEach(s=>{const r=i.styleMap.get(s);r?e[s]=r.toString():console.warn(`variable named ${s} not found`)})})}),e}function N(t){const e=window.atob(t);return decodeURIComponent(window.escape(e))}function z(t){const e=window.unescape(encodeURIComponent(t));return window.btoa(e)}exports.parseAttribute=g.parseAttribute;exports.parseAttributeValue=g.parseAttributeValue;exports.isBrowser=x.isBrowser;exports.findParentElement=m.findParentElement;exports.findScrollParentElement=m.findScrollParentElement;exports.getAllParentElements=m.getAllParentElements;exports.getElement=m.getElement;exports.easeInCubic=a.easeInCubic;exports.easeInExpo=a.easeInExpo;exports.easeInOutCubic=a.easeInOutCubic;exports.easeInOutExpo=a.easeInOutExpo;exports.easeInOutQuad=a.easeInOutQuad;exports.easeInOutQuart=a.easeInOutQuart;exports.easeInOutQuint=a.easeInOutQuint;exports.easeInQuad=a.easeInQuad;exports.easeInQuart=a.easeInQuart;exports.easeInQuint=a.easeInQuint;exports.easeOutCubic=a.easeOutCubic;exports.easeOutExpo=a.easeOutExpo;exports.easeOutQuad=a.easeOutQuad;exports.easeOutQuart=a.easeOutQuart;exports.easeOutQuint=a.easeOutQuint;exports.linear=a.linear;exports.dispatchSizeChangeEvent=y.dispatchSizeChangeEvent;exports.createJSONAndSave=E.createJSONAndSave;exports.debounce=b.debounce;exports.throttle=b.throttle;exports.getCumulativeOffsetLeft=h.getCumulativeOffsetLeft;exports.getCumulativeOffsetTop=h.getCumulativeOffsetTop;exports.getCumulativePosition=h.getCumulativePosition;exports.calculateDistance=o.calculateDistance;exports.calculateDistanceWithRadius=o.calculateDistanceWithRadius;exports.clamp=o.clamp;exports.damp=o.damp;exports.lerp=o.lerp;exports.mapRange=o.mapRange;exports.round=o.round;exports.smootherstep=o.smootherstep;exports.smoothstep=o.smoothstep;exports.step=o.step;exports.preciseNumber=f.preciseNumber;exports.roundNumberTo=f.roundNumberTo;exports.cloneDeep=u.cloneDeep;exports.compareObjects=u.compareObjects;exports.isESClass=u.isESClass;exports.isNullish=u.isNullish;exports.isObject=u.isObject;exports.mergeDeep=u.mergeDeep;exports.mixin=u.mixin;exports.omit=u.omit;exports.pick=u.pick;exports.nullishCoalescing=I.nullishCoalescing;exports.camelToKebab=l.camelToKebab;exports.capitalize=l.capitalize;exports.generateId=l.generateId;exports.kebabToCamel=l.kebabToCamel;exports.snakeToDotted=l.snakeToDotted;exports.toPascalCase=l.toPascalCase;exports.uncapitalize=l.uncapitalize;exports.getElementTransitionDurationMS=C.getElementTransitionDurationMS;exports.getElementTransitionDurationS=C.getElementTransitionDurationS;exports.cover=T;exports.decode=z;exports.dotCircleCollision=v;exports.dotRectCollision=P;exports.encode=N;exports.fixPosition=Q;exports.getPointerPosition=R;exports.getRootVariables=A;exports.insert=S;exports.measureText=w;exports.normalize=D;exports.screenToCartesian=q;
@@ -6,7 +6,7 @@ export { dotRectCollision, dotCircleCollision } from './collisions';
6
6
  export { screenToCartesian, normalize, getPointerPosition } from './coordinates';
7
7
  export { getRootVariables } from './cssom';
8
8
  export { encode, decode } from './decoding';
9
- export { findParentElement, getElement, findScrollParentElement, type ElementOrSelector, } from './dom';
9
+ export { findParentElement, getElement, findScrollParentElement, getAllParentElements, type ElementOrSelector, } from './dom';
10
10
  export { linear, easeInQuad, easeOutQuad, easeInOutQuad, easeInCubic, easeOutCubic, easeInOutCubic, easeInQuart, easeOutQuart, easeInOutQuart, easeInQuint, easeOutQuint, easeInOutQuint, easeInExpo, easeOutExpo, easeInOutExpo, type EasingFunction, } from './easings';
11
11
  export { dispatchSizeChangeEvent } from './events';
12
12
  export { createJSONAndSave } from './file';
@@ -1,17 +1,17 @@
1
1
  import { a as S, p as I } from "../attributes-69we3byR.js";
2
2
  import { i as Q } from "../browser-0zX67oeU.js";
3
- import { f as D, a as T, g as P } from "../dom-BY7JhTx5.js";
4
- import { c as k, n as B, f as M, p as N, b as j, i as z, m as U, e as V, g as q, j as J, d as K, o as $, a as F, h as G, k as W, l as X } from "../easings-BKi40vHz.js";
5
- import { d as Z } from "../events-_C2CztxR.js";
6
- import { c as H } from "../file-lxi_oXJf.js";
7
- import { d as ee, t as te } from "../function-C10DGppn.js";
8
- import { g as se, a as ne, b as oe } from "../layout-HoBT_Da2.js";
9
- import { e as re, f as ue, c as le, d as ce, l as de, m as me, r as pe, b as fe, a as xe, s as he } from "../math-BOBiC4TN.js";
10
- import { p as be, r as ye } from "../number-Bo5RdrA1.js";
11
- import { c as Ce, d as Oe, i as Ee, b as Se, a as Ie, m as Re, e as Qe, o as ve, p as De } from "../object-R34VLqhp.js";
12
- import { n as Pe } from "../polyfills-DJUYczFm.js";
13
- import { c as ke, a as Be, g as Me, k as Ne, s as je, t as ze, u as Ue } from "../string-3lAkpJJP.js";
14
- import { g as qe, a as Je } from "../style-j2TwriJ_.js";
3
+ import { f as D, b as P, a as T, g as A } from "../dom-0S_WDL4g.js";
4
+ import { c as B, n as M, f as N, p as j, b as z, i as U, m as V, e as q, g as J, j as K, d as $, o as F, a as G, h as W, k as X, l as Y } from "../easings-BKi40vHz.js";
5
+ import { d as _ } from "../events-_C2CztxR.js";
6
+ import { c as L } from "../file-lxi_oXJf.js";
7
+ import { d as te, t as ae } from "../function-C10DGppn.js";
8
+ import { g as ne, a as oe, b as ie } from "../layout-HoBT_Da2.js";
9
+ import { e as ue, f as le, c as ce, d as de, l as me, m as pe, r as fe, b as xe, a as he, s as ge } from "../math-BOBiC4TN.js";
10
+ import { p as ye, r as we } from "../number-Bo5RdrA1.js";
11
+ import { c as Ee, d as Oe, i as Se, b as Ie, a as Re, m as Qe, e as ve, o as De, p as Pe } from "../object-R34VLqhp.js";
12
+ import { n as Ae } from "../polyfills-DJUYczFm.js";
13
+ import { c as Be, a as Me, g as Ne, k as je, s as ze, t as Ue, u as Ve } from "../string-3lAkpJJP.js";
14
+ import { g as Je, a as Ke } from "../style-j2TwriJ_.js";
15
15
  function c(t, e, ...a) {
16
16
  return [...t.slice(0, e), ...a, ...t.slice(e)];
17
17
  }
@@ -79,76 +79,77 @@ function C(t) {
79
79
  return window.btoa(e);
80
80
  }
81
81
  export {
82
- re as calculateDistance,
83
- ue as calculateDistanceWithRadius,
84
- ke as camelToKebab,
85
- Be as capitalize,
86
- le as clamp,
87
- Ce as cloneDeep,
82
+ ue as calculateDistance,
83
+ le as calculateDistanceWithRadius,
84
+ Be as camelToKebab,
85
+ Me as capitalize,
86
+ ce as clamp,
87
+ Ee as cloneDeep,
88
88
  Oe as compareObjects,
89
89
  p as cover,
90
- H as createJSONAndSave,
91
- ce as damp,
92
- ee as debounce,
90
+ L as createJSONAndSave,
91
+ de as damp,
92
+ te as debounce,
93
93
  C as decode,
94
- Z as dispatchSizeChangeEvent,
94
+ _ as dispatchSizeChangeEvent,
95
95
  x as dotCircleCollision,
96
96
  f as dotRectCollision,
97
- k as easeInCubic,
98
- B as easeInExpo,
99
- M as easeInOutCubic,
100
- N as easeInOutExpo,
101
- j as easeInOutQuad,
102
- z as easeInOutQuart,
103
- U as easeInOutQuint,
104
- V as easeInQuad,
105
- q as easeInQuart,
106
- J as easeInQuint,
107
- K as easeOutCubic,
108
- $ as easeOutExpo,
109
- F as easeOutQuad,
110
- G as easeOutQuart,
111
- W as easeOutQuint,
97
+ B as easeInCubic,
98
+ M as easeInExpo,
99
+ N as easeInOutCubic,
100
+ j as easeInOutExpo,
101
+ z as easeInOutQuad,
102
+ U as easeInOutQuart,
103
+ V as easeInOutQuint,
104
+ q as easeInQuad,
105
+ J as easeInQuart,
106
+ K as easeInQuint,
107
+ $ as easeOutCubic,
108
+ F as easeOutExpo,
109
+ G as easeOutQuad,
110
+ W as easeOutQuart,
111
+ X as easeOutQuint,
112
112
  w as encode,
113
113
  D as findParentElement,
114
- T as findScrollParentElement,
114
+ P as findScrollParentElement,
115
115
  m as fixPosition,
116
- Me as generateId,
117
- se as getCumulativeOffsetLeft,
118
- ne as getCumulativeOffsetTop,
119
- oe as getCumulativePosition,
120
- P as getElement,
121
- qe as getElementTransitionDurationMS,
122
- Je as getElementTransitionDurationS,
116
+ Ne as generateId,
117
+ T as getAllParentElements,
118
+ ne as getCumulativeOffsetLeft,
119
+ oe as getCumulativeOffsetTop,
120
+ ie as getCumulativePosition,
121
+ A as getElement,
122
+ Je as getElementTransitionDurationMS,
123
+ Ke as getElementTransitionDurationS,
123
124
  b as getPointerPosition,
124
125
  y as getRootVariables,
125
126
  c as insert,
126
127
  Q as isBrowser,
127
- Ee as isESClass,
128
- Se as isNullish,
129
- Ie as isObject,
130
- Ne as kebabToCamel,
131
- de as lerp,
132
- X as linear,
133
- me as mapRange,
128
+ Se as isESClass,
129
+ Ie as isNullish,
130
+ Re as isObject,
131
+ je as kebabToCamel,
132
+ me as lerp,
133
+ Y as linear,
134
+ pe as mapRange,
134
135
  d as measureText,
135
- Re as mergeDeep,
136
- Qe as mixin,
136
+ Qe as mergeDeep,
137
+ ve as mixin,
137
138
  g as normalize,
138
- Pe as nullishCoalescing,
139
- ve as omit,
139
+ Ae as nullishCoalescing,
140
+ De as omit,
140
141
  S as parseAttribute,
141
142
  I as parseAttributeValue,
142
- De as pick,
143
- be as preciseNumber,
144
- pe as round,
145
- ye as roundNumberTo,
143
+ Pe as pick,
144
+ ye as preciseNumber,
145
+ fe as round,
146
+ we as roundNumberTo,
146
147
  h as screenToCartesian,
147
- fe as smootherstep,
148
- xe as smoothstep,
149
- je as snakeToDotted,
150
- he as step,
151
- te as throttle,
152
- ze as toPascalCase,
153
- Ue as uncapitalize
148
+ xe as smootherstep,
149
+ he as smoothstep,
150
+ ze as snakeToDotted,
151
+ ge as step,
152
+ ae as throttle,
153
+ Ue as toPascalCase,
154
+ Ve as uncapitalize
154
155
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("../custom-element/index.cjs");require("../window-resizer/index.cjs");require("../Store-D0_rDIsE.cjs");const o=require("../source/index.cjs");var l=Object.defineProperty,a=Object.getOwnPropertyDescriptor,m=(s,t,n,r)=>{for(var e=r>1?void 0:r?a(t,n):t,i=s.length-1,u;i>=0;i--)(u=s[i])&&(e=(r?u(t,n,e):u(e))||e);return r&&e&&l(t,n,e),e};exports.VideoElement=class extends o.SourceElement{connectedCallback(){super.connectedCallback(),this.captureEvent.subscribe(()=>{this.hasAttribute("e-autoplay")&&this.consumerElement.play()}),this.releaseEvent.subscribe(()=>{this.hasAttribute("e-autoplay")&&(this.consumerElement.pause(),this.hasAttribute("replay")&&(this.consumerElement.currentTime=0))})}createConsumer(){return document.createElement("video")}consumeSource(t){this.consumerElement.src=t||""}};exports.VideoElement=m([c.define("e-video")],exports.VideoElement);
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("../custom-element/index.cjs");require("../window-resizer/index.cjs");require("../Store-Dis8QUAR.cjs");const o=require("../source/index.cjs");var l=Object.defineProperty,a=Object.getOwnPropertyDescriptor,m=(s,t,n,r)=>{for(var e=r>1?void 0:r?a(t,n):t,i=s.length-1,u;i>=0;i--)(u=s[i])&&(e=(r?u(t,n,e):u(e))||e);return r&&e&&l(t,n,e),e};exports.VideoElement=class extends o.SourceElement{connectedCallback(){super.connectedCallback(),this.captureEvent.subscribe(()=>{this.hasAttribute("e-autoplay")&&this.consumerElement.play()}),this.releaseEvent.subscribe(()=>{this.hasAttribute("e-autoplay")&&(this.consumerElement.pause(),this.hasAttribute("replay")&&(this.consumerElement.currentTime=0))})}createConsumer(){return document.createElement("video")}consumeSource(t){this.consumerElement.src=t||""}};exports.VideoElement=m([c.define("e-video")],exports.VideoElement);
@@ -1,6 +1,6 @@
1
1
  import { define as u } from "../custom-element/index.js";
2
2
  import "../window-resizer/index.js";
3
- import "../Store-JOKrNVEr.js";
3
+ import "../Store-DdDuj5hz.js";
4
4
  import { SourceElement as l } from "../source/index.js";
5
5
  var m = Object.defineProperty, a = Object.getOwnPropertyDescriptor, p = (t, r, i, s) => {
6
6
  for (var e = s > 1 ? void 0 : s ? a(r, i) : r, n = t.length - 1, o; n >= 0; n--)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aptechka",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/denisavitski/aptechka.git"
@@ -33,11 +33,6 @@
33
33
  "default": "./lib/animation/index.js",
34
34
  "types": "./lib/animation/index.d.ts"
35
35
  },
36
- "./animation/hooks": {
37
- "require": "./lib/animation/hooks/index.cjs",
38
- "default": "./lib/animation/hooks/index.js",
39
- "types": "./lib/animation/hooks/index.d.ts"
40
- },
41
36
  "./attribute": {
42
37
  "require": "./lib/attribute/index.cjs",
43
38
  "default": "./lib/attribute/index.js",
@@ -83,11 +78,6 @@
83
78
  "default": "./lib/element-resizer/index.js",
84
79
  "types": "./lib/element-resizer/index.d.ts"
85
80
  },
86
- "./element-resizer/hooks": {
87
- "require": "./lib/element-resizer/hooks/index.cjs",
88
- "default": "./lib/element-resizer/hooks/index.js",
89
- "types": "./lib/element-resizer/hooks/index.d.ts"
90
- },
91
81
  "./en3": {
92
82
  "require": "./lib/en3/index.cjs",
93
83
  "default": "./lib/en3/index.js",
@@ -103,21 +93,6 @@
103
93
  "default": "./lib/intersector/index.js",
104
94
  "types": "./lib/intersector/index.d.ts"
105
95
  },
106
- "./intersector/hooks": {
107
- "require": "./lib/intersector/hooks/index.cjs",
108
- "default": "./lib/intersector/hooks/index.js",
109
- "types": "./lib/intersector/hooks/index.d.ts"
110
- },
111
- "./jsx": {
112
- "require": "./lib/jsx/index.cjs",
113
- "default": "./lib/jsx/index.js",
114
- "types": "./lib/jsx/index.d.ts"
115
- },
116
- "./jsx/hooks": {
117
- "require": "./lib/jsx/hooks/index.cjs",
118
- "default": "./lib/jsx/hooks/index.js",
119
- "types": "./lib/jsx/hooks/index.d.ts"
120
- },
121
96
  "./ladder": {
122
97
  "require": "./lib/ladder/index.cjs",
123
98
  "default": "./lib/ladder/index.js",
@@ -203,11 +178,6 @@
203
178
  "default": "./lib/store/index.js",
204
179
  "types": "./lib/store/index.d.ts"
205
180
  },
206
- "./store/hooks": {
207
- "require": "./lib/store/hooks/index.cjs",
208
- "default": "./lib/store/hooks/index.js",
209
- "types": "./lib/store/hooks/index.d.ts"
210
- },
211
181
  "./studio": {
212
182
  "require": "./lib/studio/index.cjs",
213
183
  "default": "./lib/studio/index.js",
@@ -223,11 +193,6 @@
223
193
  "default": "./lib/ticker/index.js",
224
194
  "types": "./lib/ticker/index.d.ts"
225
195
  },
226
- "./ticker/hooks": {
227
- "require": "./lib/ticker/hooks/index.cjs",
228
- "default": "./lib/ticker/hooks/index.js",
229
- "types": "./lib/ticker/hooks/index.d.ts"
230
- },
231
196
  "./utils": {
232
197
  "require": "./lib/utils/index.cjs",
233
198
  "default": "./lib/utils/index.js",
@@ -242,11 +207,6 @@
242
207
  "require": "./lib/window-resizer/index.cjs",
243
208
  "default": "./lib/window-resizer/index.js",
244
209
  "types": "./lib/window-resizer/index.d.ts"
245
- },
246
- "./window-resizer/hooks": {
247
- "require": "./lib/window-resizer/hooks/index.cjs",
248
- "default": "./lib/window-resizer/hooks/index.js",
249
- "types": "./lib/window-resizer/hooks/index.d.ts"
250
210
  }
251
211
  },
252
212
  "typesVersions": {
@@ -257,9 +217,6 @@
257
217
  "animation": [
258
218
  "lib/animation/index.d.ts"
259
219
  ],
260
- "animation/hooks": [
261
- "lib/animation/hooks/index.d.ts"
262
- ],
263
220
  "attribute": [
264
221
  "lib/attribute/index.d.ts"
265
222
  ],
@@ -290,9 +247,6 @@
290
247
  "element-resizer": [
291
248
  "lib/element-resizer/index.d.ts"
292
249
  ],
293
- "element-resizer/hooks": [
294
- "lib/element-resizer/hooks/index.d.ts"
295
- ],
296
250
  "en3": [
297
251
  "lib/en3/index.d.ts"
298
252
  ],
@@ -302,15 +256,6 @@
302
256
  "intersector": [
303
257
  "lib/intersector/index.d.ts"
304
258
  ],
305
- "intersector/hooks": [
306
- "lib/intersector/hooks/index.d.ts"
307
- ],
308
- "jsx": [
309
- "lib/jsx/index.d.ts"
310
- ],
311
- "jsx/hooks": [
312
- "lib/jsx/hooks/index.d.ts"
313
- ],
314
259
  "ladder": [
315
260
  "lib/ladder/index.d.ts"
316
261
  ],
@@ -362,9 +307,6 @@
362
307
  "store": [
363
308
  "lib/store/index.d.ts"
364
309
  ],
365
- "store/hooks": [
366
- "lib/store/hooks/index.d.ts"
367
- ],
368
310
  "studio": [
369
311
  "lib/studio/index.d.ts"
370
312
  ],
@@ -374,9 +316,6 @@
374
316
  "ticker": [
375
317
  "lib/ticker/index.d.ts"
376
318
  ],
377
- "ticker/hooks": [
378
- "lib/ticker/hooks/index.d.ts"
379
- ],
380
319
  "utils": [
381
320
  "lib/utils/index.d.ts"
382
321
  ],
@@ -385,9 +324,6 @@
385
324
  ],
386
325
  "window-resizer": [
387
326
  "lib/window-resizer/index.d.ts"
388
- ],
389
- "window-resizer/hooks": [
390
- "lib/window-resizer/hooks/index.d.ts"
391
327
  ]
392
328
  }
393
329
  },
@@ -1 +0,0 @@
1
- "use strict";var b=Object.defineProperty,k=Object.defineProperties;var x=Object.getOwnPropertyDescriptors;var u=Object.getOwnPropertySymbols;var v=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable;var E=(n,e,t)=>e in n?b(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,C=(n,e)=>{for(var t in e||(e={}))v.call(e,t)&&E(n,t,e[t]);if(u)for(var t of u(e))f.call(e,t)&&E(n,t,e[t]);return n},m=(n,e)=>k(n,x(e));var p=(n,e,t)=>{if(!e.has(n))throw TypeError("Cannot "+t)};var c=(n,e,t)=>(p(n,e,"read from private field"),t?t.call(n):e.get(n)),s=(n,e,t)=>{if(e.has(n))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(n):e.set(n,t)};const S=require("./ElementConstructor-C_HDpVEZ.cjs");exports.currentComponentElement=null;const d={value:null};exports.contextStack=[];var a,l,i,h,r;class g extends HTMLElement{constructor(t){super();s(this,a,new Set);s(this,l,new Set);s(this,i,new Map);s(this,h,()=>{exports.contextStack.push(c(this,i))});s(this,r,()=>{exports.contextStack=exports.contextStack.filter(t=>t!==c(this,i))});exports.currentComponentElement=this,c(this,h).call(this);const o=t==null?void 0:t.tag(m(C({},t.attributes),{children:t.children}));new S.ElementConstructor(this,C({children:o},d.value)),exports.currentComponentElement=null,d.value=null,c(this,r).call(this)}addConnectCallback(t){c(this,a).add(t)}addDisconnectCallback(t){c(this,l).add(t)}createContext(t,o){c(this,i).set(t,o)}connectedCallback(){exports.currentComponentElement=this,c(this,a).forEach(t=>{const o=t(this);o&&c(this,l).add(o)}),exports.currentComponentElement=null,this.addEventListener("beforeChildrenChange",c(this,h)),this.addEventListener("afterChildrenChange",c(this,r))}disconnectedCallback(){c(this,l).forEach(t=>{t(this)}),this.removeEventListener("beforeChildrenChange",c(this,h)),this.removeEventListener("afterChildrenChange",c(this,r))}}a=new WeakMap,l=new WeakMap,i=new WeakMap,h=new WeakMap,r=new WeakMap;exports.ComponentElement=g;exports.nextComponentAttributes=d;
@@ -1,76 +0,0 @@
1
- var k = Object.defineProperty, x = Object.defineProperties;
2
- var g = Object.getOwnPropertyDescriptors;
3
- var b = Object.getOwnPropertySymbols;
4
- var m = Object.prototype.hasOwnProperty, L = Object.prototype.propertyIsEnumerable;
5
- var E = (n, e, t) => e in n ? k(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, C = (n, e) => {
6
- for (var t in e || (e = {}))
7
- m.call(e, t) && E(n, t, e[t]);
8
- if (b)
9
- for (var t of b(e))
10
- L.call(e, t) && E(n, t, e[t]);
11
- return n;
12
- }, f = (n, e) => x(n, g(e));
13
- var w = (n, e, t) => {
14
- if (!e.has(n))
15
- throw TypeError("Cannot " + t);
16
- };
17
- var s = (n, e, t) => (w(n, e, "read from private field"), t ? t.call(n) : e.get(n)), l = (n, e, t) => {
18
- if (e.has(n))
19
- throw TypeError("Cannot add the same private member more than once");
20
- e instanceof WeakSet ? e.add(n) : e.set(n, t);
21
- };
22
- import { E as p } from "./ElementConstructor-ChgHpqb6.js";
23
- let r = null;
24
- const v = {
25
- value: null
26
- };
27
- let u = [];
28
- var d, h, c, a, o;
29
- class A extends HTMLElement {
30
- constructor(t) {
31
- super();
32
- l(this, d, /* @__PURE__ */ new Set());
33
- l(this, h, /* @__PURE__ */ new Set());
34
- l(this, c, /* @__PURE__ */ new Map());
35
- l(this, a, () => {
36
- u.push(s(this, c));
37
- });
38
- l(this, o, () => {
39
- u = u.filter((t) => t !== s(this, c));
40
- });
41
- r = this, s(this, a).call(this);
42
- const i = t == null ? void 0 : t.tag(f(C({}, t.attributes), {
43
- children: t.children
44
- }));
45
- new p(this, C({
46
- children: i
47
- }, v.value)), r = null, v.value = null, s(this, o).call(this);
48
- }
49
- addConnectCallback(t) {
50
- s(this, d).add(t);
51
- }
52
- addDisconnectCallback(t) {
53
- s(this, h).add(t);
54
- }
55
- createContext(t, i) {
56
- s(this, c).set(t, i);
57
- }
58
- connectedCallback() {
59
- r = this, s(this, d).forEach((t) => {
60
- const i = t(this);
61
- i && s(this, h).add(i);
62
- }), r = null, this.addEventListener("beforeChildrenChange", s(this, a)), this.addEventListener("afterChildrenChange", s(this, o));
63
- }
64
- disconnectedCallback() {
65
- s(this, h).forEach((t) => {
66
- t(this);
67
- }), this.removeEventListener("beforeChildrenChange", s(this, a)), this.removeEventListener("afterChildrenChange", s(this, o));
68
- }
69
- }
70
- d = new WeakMap(), h = new WeakMap(), c = new WeakMap(), a = new WeakMap(), o = new WeakMap();
71
- export {
72
- A as C,
73
- u as a,
74
- r as c,
75
- v as n
76
- };
@@ -1,79 +0,0 @@
1
- var g = (e, r, s) => {
2
- if (!r.has(e))
3
- throw TypeError("Cannot " + s);
4
- };
5
- var t = (e, r, s) => (g(e, r, "read from private field"), s ? s.call(e) : r.get(e)), n = (e, r, s) => {
6
- if (r.has(e))
7
- throw TypeError("Cannot add the same private member more than once");
8
- r instanceof WeakSet ? r.add(e) : r.set(e, s);
9
- }, f = (e, r, s, c) => (g(e, r, "write to private field"), c ? c.call(e, s) : r.set(e, s), s);
10
- import { S as m } from "./Store-JOKrNVEr.js";
11
- import { d as E } from "./function-C10DGppn.js";
12
- var d;
13
- class P extends m {
14
- constructor(s, c, u) {
15
- super(null, u);
16
- n(this, d, void 0);
17
- f(this, d, s.subscribe((o) => {
18
- const a = [];
19
- o.current.forEach((C, l) => {
20
- var x;
21
- o.current[l] === ((x = o.previous) == null ? void 0 : x[l]) && this.current[l] ? a.push(this.current[l]) : a.push(c(C, l));
22
- }), this.current = a;
23
- }));
24
- }
25
- close() {
26
- super.close(), t(this, d).call(this);
27
- }
28
- }
29
- d = new WeakMap();
30
- var b, h, i;
31
- class R extends m {
32
- constructor(s, c, u) {
33
- super(s, u);
34
- n(this, b, void 0);
35
- n(this, h, void 0);
36
- n(this, i, 0);
37
- f(this, h, new m(!1)), f(this, b, c), u != null && u.manualControl || this.refetch();
38
- }
39
- get isPending() {
40
- return t(this, h);
41
- }
42
- /**
43
- * Calls fetcher again and sets isPending to true.
44
- */
45
- refetch() {
46
- t(this, h).current = !0, f(this, i, t(this, i) + 1);
47
- const s = t(this, i);
48
- t(this, b).call(this).then((c) => {
49
- s === t(this, i) && (t(this, h).current = !1, this.current = c);
50
- });
51
- }
52
- }
53
- b = new WeakMap(), h = new WeakMap(), i = new WeakMap();
54
- var p;
55
- class S extends m {
56
- constructor(s, c, u) {
57
- super(null, u);
58
- n(this, p, []);
59
- const o = E(() => {
60
- this.current = c();
61
- }, 0);
62
- s.forEach((a) => {
63
- t(this, p).push(
64
- a.subscribe(() => {
65
- o();
66
- })
67
- );
68
- });
69
- }
70
- close() {
71
- super.close(), t(this, p).forEach((s) => s());
72
- }
73
- }
74
- p = new WeakMap();
75
- export {
76
- S as C,
77
- P as D,
78
- R
79
- };
@@ -1 +0,0 @@
1
- "use strict";var g=(r,s,e)=>{if(!s.has(r))throw TypeError("Cannot "+e)};var t=(r,s,e)=>(g(r,s,"read from private field"),e?e.call(r):s.get(r)),h=(r,s,e)=>{if(s.has(r))throw TypeError("Cannot add the same private member more than once");s instanceof WeakSet?s.add(r):s.set(r,e)},a=(r,s,e,c)=>(g(r,s,"write to private field"),c?c.call(r,e):s.set(r,e),e);const x=require("./Store-D0_rDIsE.cjs"),v=require("./function-MthRj-GJ.cjs");var d;class C extends x.Store{constructor(e,c,u){super(null,u);h(this,d,void 0);a(this,d,e.subscribe(o=>{const l=[];o.current.forEach((m,f)=>{var S;o.current[f]===((S=o.previous)==null?void 0:S[f])&&this.current[f]?l.push(this.current[f]):l.push(c(m,f))}),this.current=l}))}close(){super.close(),t(this,d).call(this)}}d=new WeakMap;var b,n,i;class E extends x.Store{constructor(e,c,u){super(e,u);h(this,b,void 0);h(this,n,void 0);h(this,i,0);a(this,n,new x.Store(!1)),a(this,b,c),u!=null&&u.manualControl||this.refetch()}get isPending(){return t(this,n)}refetch(){t(this,n).current=!0,a(this,i,t(this,i)+1);const e=t(this,i);t(this,b).call(this).then(c=>{e===t(this,i)&&(t(this,n).current=!1,this.current=c)})}}b=new WeakMap,n=new WeakMap,i=new WeakMap;var p;class q extends x.Store{constructor(e,c,u){super(null,u);h(this,p,[]);const o=v.debounce(()=>{this.current=c()},0);e.forEach(l=>{t(this,p).push(l.subscribe(()=>{o()}))})}close(){super.close(),t(this,p).forEach(e=>e())}}p=new WeakMap;exports.Composed=q;exports.DerivedArray=C;exports.Resource=E;
@@ -1 +0,0 @@
1
- "use strict";var $=(l,e,s)=>{if(!e.has(l))throw TypeError("Cannot "+s)};var n=(l,e,s)=>($(l,e,"read from private field"),s?s.call(l):e.get(l)),r=(l,e,s)=>{if(e.has(l))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(l):e.set(l,s)},Q=(l,e,s,t)=>($(l,e,"write to private field"),t?t.call(l,s):e.set(l,s),s);var a=(l,e,s)=>($(l,e,"access private method"),s);const m=require("./Store-D0_rDIsE.cjs"),re=require("./browser-CpzFX2xg.cjs"),X=require("./object-BZELAoVj.cjs"),R=require("./string-vBu90jhV.cjs"),fe=require("./connector/index.cjs"),ce=new Set(["animate","animateMotion","animateTransform","circle","clipPath","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","foreignObject","g","image","line","linearGradient","listener","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialGradient","rect","set","solidColor","stop","svg","switch","symbol","text","textPath","title","tspan","view"]);var f,h,d,T,Z,w,_,v,O,S,z,A,j,M,ee,x,te,D,se,y,J,b,V,k,ie,q,ne,E,K,g,L,p,Y,H,oe,F,ae,C,I,N,U,P,B;const G=class G{constructor(...e){r(this,T);r(this,w);r(this,v);r(this,S);r(this,A);r(this,M);r(this,x);r(this,D);r(this,y);r(this,b);r(this,k);r(this,q);r(this,E);r(this,g);r(this,p);r(this,H);r(this,F);r(this,C);r(this,N);r(this,f,void 0);r(this,h,new Set);r(this,d,new Set);r(this,P,()=>{n(this,h).forEach(e=>{e()}),n(this,h).clear()});r(this,B,e=>{n(this,d).forEach(s=>{s(e)}),n(this,d).clear()});const s=e[0],t=e[1];Q(this,f,a(this,T,Z).call(this,s,t==null?void 0:t.forceSvg)),a(this,v,O).call(this,t)}get node(){return n(this,f)}};f=new WeakMap,h=new WeakMap,d=new WeakMap,T=new WeakSet,Z=function(e,s){let t=null;if(e instanceof Node)t=e;else if(typeof e=="string")if(!e.includes("<")&&e.includes("-"))t=new(customElements.get(e));else if(e.includes("<")){const i=document.createElement("div");i.innerHTML=e,t=i.firstElementChild}else ce.has(e)||s?t=document.createElementNS("http://www.w3.org/2000/svg",e):t=document.createElement(e);else t=document.createElement("div");return t},w=new WeakSet,_=function(e){return e instanceof HTMLElement||e instanceof SVGElement},v=new WeakSet,O=function(e){if(!e)return;const s=a(this,w,_).call(this,n(this,f)),t=e.ref;delete e.ref,e!=null&&e.onConnect&&(n(this,h).add(e.onConnect),delete e.onConnect),e!=null&&e.onDisconnect&&(n(this,d).add(e.onDisconnect),delete e.onDisconnect);let i,o;for(const c in e){const u=e[c];c==="class"&&s?a(this,S,z).call(this,u):c==="style"&&s?a(this,x,te).call(this,u):c==="lightChildren"?a(this,g,L).call(this,n(this,f),u):c==="children"?a(this,g,L).call(this,n(this,f)instanceof Element?n(this,f).shadowRoot||n(this,f):n(this,f),u):c.startsWith("on")?(o||(o={}),o[c]=u):(i||(i={}),i[c]=u)}if(a(this,q,ne).call(this,i),a(this,k,ie).call(this,o),t&&(typeof t=="function"?t(n(this,f)):t.current=n(this,f)),re.isBrowser&&(n(this,d).size||n(this,h).size)){const c=n(this,f)instanceof DocumentFragment?n(this,f).firstChild:n(this,f);fe.connector.subscribe(c,{connectCallback:n(this,P),disconnectCallback:n(this,B),unsubscribeAfterDisconnect:!0,maxWaitSec:20})}},S=new WeakSet,z=function(e){const s=n(this,f);if(e){if(typeof e=="string")s.classList.add(e);else if(Array.isArray(e))e.forEach(t=>{a(this,S,z).call(this,t)});else if(typeof e=="object")if(e instanceof m.Store)a(this,A,j).call(this,e);else for(const t in e){const i=e[t];i instanceof m.Store?a(this,M,ee).call(this,t,i):i?s.classList.add(t):s.classList.remove(t)}}else return},A=new WeakSet,j=function(e){const s=n(this,f);n(this,d).add(e.subscribe(({current:t,previous:i})=>{i&&[i].flat().forEach(o=>{o&&s.classList.remove(o)}),t&&[t].flat().forEach(o=>{o&&s.classList.add(o)})}))},M=new WeakSet,ee=function(e,s){const t=n(this,f);n(this,d).add(s.subscribe(({current:i})=>{i?t.classList.add(e):t.classList.remove(e)}))},x=new WeakSet,te=function(e){if(!e)return;const s=n(this,f);s.tagName==="style"||s.tagName==="STYLE"?a(this,y,J).call(this,e):a(this,D,se).call(this,e)},D=new WeakSet,se=function(e){for(const s in e){const t=s,i=e[t];i instanceof m.Store?n(this,d).add(i.subscribe(({current:o})=>{a(this,b,V).call(this,t,o)})):a(this,b,V).call(this,t,i)}},y=new WeakSet,J=function(e){const s=n(this,f);for(const t in e){const i=e[t];if(typeof i=="object"&&!(i instanceof m.Store))s.appendChild(document.createTextNode(`${t} {`)),a(this,y,J).call(this,i),s.appendChild(document.createTextNode("}"));else if(i instanceof m.Store){const o=document.createTextNode("");n(this,d).add(i.subscribe(c=>{c.current?o.nodeValue=`${R.camelToKebab(t)}: ${c.current};`:o.nodeValue=""})),s.appendChild(o)}else s.appendChild(document.createTextNode(`${R.camelToKebab(t)}: ${i};`))}},b=new WeakSet,V=function(e,s){const t=n(this,f);e.includes("--")?s?t.style.setProperty(e,s):t.style.removeProperty(e):s?t.style[e]=s:t.style[e]=""},k=new WeakSet,ie=function(e){if(!e)return;const s=n(this,f);for(const t in e){const i=t,o=R.uncapitalize(i.split("on").slice(1).join("on")),c=e[i];typeof c=="object"?s.addEventListener(o,c.callback,c.options):typeof c=="function"&&s.addEventListener(o,c)}},q=new WeakSet,ne=function(e){for(const s in e){const t=e[s];t instanceof m.Store?n(this,d).add(t.subscribe(({current:i})=>{a(this,E,K).call(this,s,i)})):a(this,E,K).call(this,s,t)}},E=new WeakSet,K=function(e,s){var i,o;const t=n(this,f);e in t&&!((o=(i=t.constructor)==null?void 0:i.observedAttributes)!=null&&o.includes(e))?s!=null&&(t[e]=s.toString()):s!=null&&t.setAttribute(e,s.toString())},g=new WeakSet,L=function(e,s){s&&(s=[s].flat(),s.forEach(t=>{if(t instanceof m.Store){const i=document.createElement("div");i.style.display="contents",e.appendChild(i),n(this,d).add(t.subscribe(({current:o})=>{i.dispatchEvent(new CustomEvent("beforeChildrenChange",{bubbles:!0,composed:!0})),a(this,F,ae).call(this,i,a(this,H,oe).call(this,o),Array.from(i.childNodes)),i.dispatchEvent(new CustomEvent("afterChildrenChange",{bubbles:!0,composed:!0}))}))}else if(t instanceof G)a(this,p,Y).call(this,e,t.node);else if(t instanceof Function)a(this,g,L).call(this,e,X.isESClass(t)?new t:t());else{const i=a(this,N,U).call(this,t);i instanceof Node&&a(this,p,Y).call(this,e,i)}}))},p=new WeakSet,Y=function(e,s){!(e instanceof ShadowRoot)&&s instanceof HTMLElement&&s.tagName==="STYLE"?(n(this,h).add(()=>{[...document.head.querySelectorAll("style")].find(i=>i.outerHTML===s.outerHTML)||document.head.appendChild(s)}),n(this,d).add(()=>{s.remove()})):e.appendChild(s)},H=new WeakSet,oe=function(e){return[e].flat().map(t=>t instanceof G?t.node:typeof t=="function"?X.isESClass(t)?new t:t():a(this,N,U).call(this,t)).flat().filter(Boolean)},F=new WeakSet,ae=function(e,s,t){t.length>s.length&&t.forEach(i=>{s.find(o=>a(this,C,I).call(this,i,o))||(e.removeChild(i),t=t.filter(o=>o!==i))}),t.forEach((i,o)=>{if(o<s.length){const c=s[o];a(this,C,I).call(this,i,c)||e.replaceChild(c,i)}else e.removeChild(i)});for(let i=t.length;i<s.length;i++)e.appendChild(s[i])},C=new WeakSet,I=function(e,s){return s?s instanceof Node?e.isEqualNode(s):e.textContent===s.toString():!1},N=new WeakSet,U=function(e){if(e instanceof Node)return e;if(e!=null){const s=String(e);if(s.trim().startsWith("<")&&s.trim().endsWith(">")){const t=document.createElement("div");return t.innerHTML=s,t.firstElementChild}else return document.createTextNode(s)}else return},P=new WeakMap,B=new WeakMap;let W=G;exports.ElementConstructor=W;