aptechka 0.14.0 → 0.16.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 (83) hide show
  1. package/lib/{Animation-De9aUv3b.cjs → Animation-DI864E0i.cjs} +1 -1
  2. package/lib/{Animation-NAGXiFv5.js → Animation-w6BLTCum.js} +1 -1
  3. package/lib/{Damped-DbJKrUIf.js → Damped-DEHDEq-b.js} +1 -1
  4. package/lib/{Damped-DYJ6Z0xo.cjs → Damped-ipnDc0iX.cjs} +1 -1
  5. package/lib/Store-CDb6RMce.cjs +1 -0
  6. package/lib/Store-OTdcl6SX.js +134 -0
  7. package/lib/{Tweened-BkkD9s4n.cjs → Tweened-B1TfANfR.cjs} +1 -1
  8. package/lib/{Tweened-DOSHLCZa.js → Tweened-C52xXDLY.js} +1 -1
  9. package/lib/{Viewport-Cv4TRGiv.cjs → Viewport-BDPsnAF4.cjs} +1 -1
  10. package/lib/{Viewport-B55BvLsV.js → Viewport-taEXS8Uv.js} +1 -1
  11. package/lib/animation/index.cjs +1 -1
  12. package/lib/animation/index.js +3 -3
  13. package/lib/attribute/index.cjs +1 -1
  14. package/lib/attribute/index.js +1 -1
  15. package/lib/canvas/index.cjs +1 -7
  16. package/lib/canvas/index.js +49 -48
  17. package/lib/class-linked-status/index.cjs +1 -1
  18. package/lib/class-linked-status/index.js +1 -1
  19. package/lib/controls/index.cjs +1 -1
  20. package/lib/controls/index.js +2 -2
  21. package/lib/css-property/index.cjs +1 -1
  22. package/lib/css-property/index.js +1 -1
  23. package/lib/dev/index.cjs +1 -1
  24. package/lib/dev/index.js +1 -1
  25. package/lib/device/index.cjs +1 -1
  26. package/lib/device/index.js +1 -1
  27. package/lib/en3/index.cjs +8 -1
  28. package/lib/en3/index.js +372 -4
  29. package/lib/image/index.cjs +1 -1
  30. package/lib/image/index.js +1 -1
  31. package/lib/jss-CjccJC-K.js +21 -0
  32. package/lib/jss-GJLvaNfT.cjs +1 -0
  33. package/lib/ladder/index.cjs +1 -1
  34. package/lib/ladder/index.js +1 -1
  35. package/lib/media/index.cjs +1 -1
  36. package/lib/media/index.js +1 -1
  37. package/lib/need_redo_tweaker/index.cjs +4 -4
  38. package/lib/need_redo_tweaker/index.js +838 -460
  39. package/lib/pointer/index.cjs +1 -1
  40. package/lib/pointer/index.js +2 -2
  41. package/lib/popover/index.cjs +1 -1
  42. package/lib/popover/index.js +15 -21
  43. package/lib/scroll/index.cjs +1 -1
  44. package/lib/scroll/index.js +576 -608
  45. package/lib/sequence/index.cjs +1 -1
  46. package/lib/sequence/index.js +1 -1
  47. package/lib/source/index.cjs +2 -2
  48. package/lib/source/index.js +154 -62
  49. package/lib/store/index.cjs +1 -1
  50. package/lib/store/index.js +71 -37
  51. package/lib/utils/index.cjs +1 -1
  52. package/lib/utils/index.js +59 -56
  53. package/lib/video/index.cjs +1 -1
  54. package/lib/video/index.js +1 -1
  55. package/package.json +1 -34
  56. package/lib/Composed-C_4slJQ6.cjs +0 -1
  57. package/lib/Composed-CfWa-69I.js +0 -31
  58. package/lib/Derived-BIBU-y7Z.cjs +0 -1
  59. package/lib/Derived-Vo_RsJfi.js +0 -23
  60. package/lib/SourceManager-B6wZpXUZ.js +0 -104
  61. package/lib/SourceManager-CfHcGLUa.cjs +0 -1
  62. package/lib/Store-C46i0nvr.js +0 -137
  63. package/lib/Store-npaZHvX4.cjs +0 -1
  64. package/lib/createStylesheet-C68ja-RS.js +0 -8
  65. package/lib/createStylesheet-Csfmh-MH.cjs +0 -1
  66. package/lib/element-constructor/index.cjs +0 -1
  67. package/lib/element-constructor/index.js +0 -135
  68. package/lib/en3/helpers/index.cjs +0 -1
  69. package/lib/en3/helpers/index.js +0 -1870
  70. package/lib/en3/libs/index.cjs +0 -1
  71. package/lib/en3/libs/index.js +0 -200
  72. package/lib/en3/loaders/index.cjs +0 -1
  73. package/lib/en3/loaders/index.js +0 -1742
  74. package/lib/en3/misc/index.cjs +0 -10
  75. package/lib/en3/misc/index.js +0 -110
  76. package/lib/en3/utils/index.cjs +0 -1
  77. package/lib/en3/utils/index.js +0 -20
  78. package/lib/en3-C1fLmsjs.cjs +0 -8
  79. package/lib/en3-sK9Z-fp2.js +0 -344
  80. package/lib/tags-6_ETuR75.cjs +0 -1
  81. package/lib/tags-zft1DGBz.js +0 -833
  82. package/lib/traverseMaterials-BlZbRhgW.js +0 -29
  83. package/lib/traverseMaterials-CD_3_56D.cjs +0 -1
@@ -1 +1 @@
1
- "use strict";var x=s=>{throw TypeError(s)};var I=(s,n,e)=>n.has(s)||x("Cannot "+e);var t=(s,n,e)=>(I(s,n,"read from private field"),e?e.call(s):n.get(s)),c=(s,n,e)=>n.has(s)?x("Cannot add the same private member more than once"):n instanceof WeakSet?n.add(s):n.set(s,e),l=(s,n,e,i)=>(I(s,n,"write to private field"),i?i.call(s,e):n.set(s,e),e);var L=(s,n,e)=>new Promise((i,f)=>{var w=o=>{try{u(e.next(o))}catch(r){f(r)}},y=o=>{try{u(e.throw(o))}catch(r){f(r)}},u=o=>o.done?i(o.value):Promise.resolve(o.value).then(w,y);u((e=e.apply(s,n)).next())});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const B=require("../canvas/index.cjs"),P=require("../css-property/index.cjs"),R=require("../element-resizer/index.cjs");require("../window-resizer/index.cjs");require("../Store-npaZHvX4.cjs");const H=require("../browser-CpzFX2xg.cjs"),z=require("../canvas-CU5Xjahf.cjs"),M=require("../source/index.cjs");function W(s){const n=s.match(/\{([\d-]+)\}/);if(n){const e=n[1].split("-");if(e.length===2){const i=parseInt(e[0],10),f=parseInt(e[1],10);return{start:i,end:f}}}return null}var h,b,S,m,d,g,E,p,a,v;class k extends M.SourceElement{constructor(e){super();c(this,h,[]);c(this,b,new P.CSSProperty(this,"--fit","contain"));c(this,S,new P.CSSProperty(this,"--autoplay",!1));c(this,m,new P.CSSProperty(this,"--offset-x",.5));c(this,d,new P.CSSProperty(this,"--offset-y",.5));c(this,g,null);c(this,E,0);c(this,p,1);c(this,a,()=>{if(t(this,h).length){const e=t(this,h)[0];t(this,b).current==="cover"?l(this,g,z.cover(e.naturalWidth,e.naturalHeight,this.consumerElement.width,this.consumerElement.height,t(this,m).current,t(this,d).current)):l(this,g,z.contain(e.naturalWidth,e.naturalHeight,this.consumerElement.width,this.consumerElement.height,t(this,m).current,t(this,d).current))}});c(this,v,e=>{if(this.status.isFalse("loaded")||!t(this,g))return;e.detail.context.clearRect(0,0,e.detail.width,e.detail.height);const i=t(this,h)[t(this,E)];i&&e.detail.context.drawImage(i,...t(this,g)),t(this,S).current&&l(this,E,(t(this,E)+1)%t(this,h).length)});H.isBrowser&&(l(this,p,parseInt(((e==null?void 0:e.pad)||this.getAttribute("pad")||"1").toString())),t(this,b).subscribe(t(this,a)),t(this,m).subscribe(t(this,a)),t(this,d).subscribe(t(this,a)),this.addEventListener("sourceCapture",i=>{this.consumerElement.addEventListener("canvasRender",t(this,v))}),this.addEventListener("sourceRelease",i=>{this.consumerElement.removeEventListener("canvasRender",t(this,v))}))}setProgress(e){t(this,h).length&&l(this,E,Math.floor((t(this,h).length-1)*e))}connectedCallback(){super.connectedCallback(),t(this,S).observe(),t(this,b).observe(),t(this,m).observe(),t(this,d).observe(),R.elementResizer.subscribe(this,t(this,a))}disconnectedCallback(){super.disconnectedCallback(),t(this,S).unobserve(),t(this,b).unobserve(),t(this,m).unobserve(),t(this,d).unobserve(),l(this,h,[]),R.elementResizer.unsubscribe(t(this,a)),this.consumerElement.removeEventListener("canvasRender",t(this,v))}createConsumer(){return new B.CanvasElement}consumeSource(e){return L(this,null,function*(){var i,f,w,y;if(e){this.consumerElement.removeEventListener("canvasRender",t(this,v));const u=[],o=W(e);if(o)for(let r=o.start;r<=o.end;r++){const q=e.replace(/\{([^}]+)\}/,r.toString().padStart(t(this,p),"0")),C=new Image;C.src=q,u.push(C)}else{const r=new Image;r.src=e,u.push(r)}try{yield Promise.all(u.map((r,q)=>new Promise((C,_)=>{r.onload=()=>{C()},r.onerror=j=>{_(`${r.src} Image not found`)}}))),l(this,h,u),t(this,a).call(this),(f=(i=this.consumerElement).onload)==null||f.call(i,new Event("load")),this.isLazy||this.consumerElement.addEventListener("canvasRender",t(this,v))}catch(r){console.error(r),(y=(w=this.consumerElement).onerror)==null||y.call(w,new Event("error"))}}})}}h=new WeakMap,b=new WeakMap,S=new WeakMap,m=new WeakMap,d=new WeakMap,g=new WeakMap,E=new WeakMap,p=new WeakMap,a=new WeakMap,v=new WeakMap;customElements.get("e-sequence")||customElements.define("e-sequence",k);exports.SequenceElement=k;
1
+ "use strict";var x=s=>{throw TypeError(s)};var I=(s,n,e)=>n.has(s)||x("Cannot "+e);var t=(s,n,e)=>(I(s,n,"read from private field"),e?e.call(s):n.get(s)),c=(s,n,e)=>n.has(s)?x("Cannot add the same private member more than once"):n instanceof WeakSet?n.add(s):n.set(s,e),l=(s,n,e,i)=>(I(s,n,"write to private field"),i?i.call(s,e):n.set(s,e),e);var L=(s,n,e)=>new Promise((i,f)=>{var w=o=>{try{u(e.next(o))}catch(r){f(r)}},y=o=>{try{u(e.throw(o))}catch(r){f(r)}},u=o=>o.done?i(o.value):Promise.resolve(o.value).then(w,y);u((e=e.apply(s,n)).next())});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const B=require("../canvas/index.cjs"),P=require("../css-property/index.cjs"),R=require("../element-resizer/index.cjs");require("../window-resizer/index.cjs");require("../Store-CDb6RMce.cjs");const H=require("../browser-CpzFX2xg.cjs"),z=require("../canvas-CU5Xjahf.cjs"),M=require("../source/index.cjs");function W(s){const n=s.match(/\{([\d-]+)\}/);if(n){const e=n[1].split("-");if(e.length===2){const i=parseInt(e[0],10),f=parseInt(e[1],10);return{start:i,end:f}}}return null}var h,b,S,m,d,g,E,p,a,v;class k extends M.SourceElement{constructor(e){super();c(this,h,[]);c(this,b,new P.CSSProperty(this,"--fit","contain"));c(this,S,new P.CSSProperty(this,"--autoplay",!1));c(this,m,new P.CSSProperty(this,"--offset-x",.5));c(this,d,new P.CSSProperty(this,"--offset-y",.5));c(this,g,null);c(this,E,0);c(this,p,1);c(this,a,()=>{if(t(this,h).length){const e=t(this,h)[0];t(this,b).current==="cover"?l(this,g,z.cover(e.naturalWidth,e.naturalHeight,this.consumerElement.width,this.consumerElement.height,t(this,m).current,t(this,d).current)):l(this,g,z.contain(e.naturalWidth,e.naturalHeight,this.consumerElement.width,this.consumerElement.height,t(this,m).current,t(this,d).current))}});c(this,v,e=>{if(this.status.isFalse("loaded")||!t(this,g))return;e.detail.context.clearRect(0,0,e.detail.width,e.detail.height);const i=t(this,h)[t(this,E)];i&&e.detail.context.drawImage(i,...t(this,g)),t(this,S).current&&l(this,E,(t(this,E)+1)%t(this,h).length)});H.isBrowser&&(l(this,p,parseInt(((e==null?void 0:e.pad)||this.getAttribute("pad")||"1").toString())),t(this,b).subscribe(t(this,a)),t(this,m).subscribe(t(this,a)),t(this,d).subscribe(t(this,a)),this.addEventListener("sourceCapture",i=>{this.consumerElement.addEventListener("canvasRender",t(this,v))}),this.addEventListener("sourceRelease",i=>{this.consumerElement.removeEventListener("canvasRender",t(this,v))}))}setProgress(e){t(this,h).length&&l(this,E,Math.floor((t(this,h).length-1)*e))}connectedCallback(){super.connectedCallback(),t(this,S).observe(),t(this,b).observe(),t(this,m).observe(),t(this,d).observe(),R.elementResizer.subscribe(this,t(this,a))}disconnectedCallback(){super.disconnectedCallback(),t(this,S).unobserve(),t(this,b).unobserve(),t(this,m).unobserve(),t(this,d).unobserve(),l(this,h,[]),R.elementResizer.unsubscribe(t(this,a)),this.consumerElement.removeEventListener("canvasRender",t(this,v))}createConsumer(){return new B.CanvasElement}consumeSource(e){return L(this,null,function*(){var i,f,w,y;if(e){this.consumerElement.removeEventListener("canvasRender",t(this,v));const u=[],o=W(e);if(o)for(let r=o.start;r<=o.end;r++){const q=e.replace(/\{([^}]+)\}/,r.toString().padStart(t(this,p),"0")),C=new Image;C.src=q,u.push(C)}else{const r=new Image;r.src=e,u.push(r)}try{yield Promise.all(u.map((r,q)=>new Promise((C,_)=>{r.onload=()=>{C()},r.onerror=j=>{_(`${r.src} Image not found`)}}))),l(this,h,u),t(this,a).call(this),(f=(i=this.consumerElement).onload)==null||f.call(i,new Event("load")),this.isLazy||this.consumerElement.addEventListener("canvasRender",t(this,v))}catch(r){console.error(r),(y=(w=this.consumerElement).onerror)==null||y.call(w,new Event("error"))}}})}}h=new WeakMap,b=new WeakMap,S=new WeakMap,m=new WeakMap,d=new WeakMap,g=new WeakMap,E=new WeakMap,p=new WeakMap,a=new WeakMap,v=new WeakMap;customElements.get("e-sequence")||customElements.define("e-sequence",k);exports.SequenceElement=k;
@@ -23,7 +23,7 @@ import { CanvasElement as z } from "../canvas/index.js";
23
23
  import { CSSProperty as I } from "../css-property/index.js";
24
24
  import { elementResizer as k } from "../element-resizer/index.js";
25
25
  import "../window-resizer/index.js";
26
- import "../Store-C46i0nvr.js";
26
+ import "../Store-OTdcl6SX.js";
27
27
  import { i as B } from "../browser-0zX67oeU.js";
28
28
  import { c as H, a as W } from "../canvas-DeZ0SLUJ.js";
29
29
  import { SourceElement as A } from "../source/index.js";
@@ -1,5 +1,5 @@
1
- "use strict";var k=i=>{throw TypeError(i)};var y=(i,r,t)=>r.has(i)||k("Cannot "+t);var e=(i,r,t)=>(y(i,r,"read from private field"),t?t.call(i):r.get(i)),a=(i,r,t)=>r.has(i)?k("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(i):r.set(i,t),u=(i,r,t,o)=>(y(i,r,"write to private field"),o?o.call(i,t):r.set(i,t),t),p=(i,r,t)=>(y(i,r,"access private method"),t);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const C=require("../SourceManager-CfHcGLUa.cjs"),w=require("../loading/index.cjs"),A=require("../class-linked-status/index.cjs"),q=require("../browser-CpzFX2xg.cjs"),x=require("../string-DhgS_iFl.cjs");let T=0;var h,s,c,f,l,d,n,g,m,v,E,b,L;class z extends HTMLElement{constructor(){super();a(this,m);a(this,h,null);a(this,s,null);a(this,c,!1);a(this,f,!1);a(this,l,!1);a(this,d,"");a(this,n,new A.ClassLinkedStatus(this,{loading:!1,loaded:!1,error:!1}));a(this,g,null);a(this,E,t=>{const o=t[0];e(this,l)&&(!e(this,f)||this.hasAttribute("reload-source"))&&o.isIntersecting&&(e(this,h).current&&e(this,h).current!==e(this,h).previous&&p(this,m,v).call(this,e(this,h).current),u(this,f,!0)),o.isIntersecting?this.dispatchEvent(new CustomEvent("sourceCapture")):(this.hasAttribute("reload-source")&&p(this,m,v).call(this,void 0),this.dispatchEvent(new CustomEvent("sourceRelease")))});a(this,b,()=>{e(this,n).set("loaded",!0),e(this,n).set("error",!1),e(this,n).set("loading",!1),!e(this,l)&&!e(this,c)&&w.loading.setLoaded(e(this,d),1),u(this,c,!0)});a(this,L,t=>{e(this,n).set("loaded",!1),e(this,n).set("error",!0),e(this,n).set("loading",!1),!e(this,l)&&!e(this,c)&&w.loading.setError(e(this,d),t),u(this,c,!0)});q.isBrowser&&(u(this,d,`source-consumer-${++T}`),u(this,g,new IntersectionObserver(e(this,E))))}get consumerElement(){return e(this,s)}get sourceManager(){return e(this,h)}get status(){return e(this,n)}get isLazy(){return e(this,l)}connectedCallback(){const t=this.getAttribute("srcset");t&&(u(this,s,this.createConsumer()),e(this,s).style.cssText=`
1
+ "use strict";var G=o=>{throw TypeError(o)};var $=(o,r,e)=>r.has(o)||G("Cannot "+e);var t=(o,r,e)=>($(o,r,"read from private field"),e?e.call(o):r.get(o)),a=(o,r,e)=>r.has(o)?G("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(o):r.set(o,e),i=(o,r,e,s)=>($(o,r,"write to private field"),s?s.call(o,e):r.set(o,e),e),V=(o,r,e)=>($(o,r,"access private method"),e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Z=require("../order/index.cjs"),K=require("../window-resizer/index.cjs"),J=require("../Store-CDb6RMce.cjs"),B=require("../loading/index.cjs"),W=require("../class-linked-status/index.cjs"),X=require("../browser-CpzFX2xg.cjs"),Y=require("../string-DhgS_iFl.cjs");var R,k,C,g,l,x,v;class N{constructor(r){a(this,R);a(this,k);a(this,C);a(this,g);a(this,l);a(this,x);a(this,v);i(this,R,r);const e=r.indexOf("?");e>=0&&(r=r.slice(0,e));const s=r.split(".");i(this,k,s[0]);const d=/\d+x/g,c=s.find(p=>p.match(d));i(this,C,c?parseInt(c):1);const E=/\d+max/g,P=/\d+min/g,n=/\d+mar/g,y=/\d+mir/g,H=s.find(p=>p.match(E)),D=s.find(p=>p.match(P)),j=s.find(p=>p.match(n)),F=s.find(p=>p.match(y));j?(i(this,l,parseInt(j)),i(this,x,"max"),i(this,g,`(max-aspect-ratio: ${t(this,l)})`)):F?(i(this,l,parseInt(F)),i(this,x,"max"),i(this,g,`(min-aspect-ratio: ${t(this,l)})`)):H?(i(this,l,parseInt(H)),i(this,x,"max"),i(this,g,`(max-width: ${t(this,l)}px)`)):D?(i(this,l,parseInt(D)),i(this,g,`(min-width: ${t(this,l)}px)`),i(this,x,"min")):(i(this,l,0),i(this,g,`(min-width: ${t(this,l)}px)`),i(this,x,"min")),i(this,v,"."+s[s.length-1])}get url(){return t(this,R)}get name(){return t(this,k)}get density(){return t(this,C)}get query(){return t(this,g)}get extension(){return t(this,v)}get queryType(){return t(this,x)}get queryValue(){return t(this,l)}}R=new WeakMap,k=new WeakMap,C=new WeakMap,g=new WeakMap,l=new WeakMap,x=new WeakMap,v=new WeakMap;var b;class Q{constructor(r){a(this,b);i(this,b,new Map);const e=typeof r=="string"?r.trim().split(",").map(n=>n.trim()).filter(n=>!!n):r,s=[];e.forEach(n=>{const y=new N(n);s.push([y.query,y])});const d=s.filter(n=>n[1].queryType.includes("max")).sort((n,y)=>y[1].queryValue-n[1].queryValue),c=s.filter(n=>n[1].queryType.includes("min")&&n[1].queryValue!==0).sort((n,y)=>n[1].queryValue-y[1].queryValue),E=s.filter(n=>n[0]==="(min-width: 0px)");(E?[...E,...d,...c]:[...d,...c]).forEach(n=>{t(this,b).has(n[0])||t(this,b).set(n[0],[]),t(this,b).get(n[0]).push(n[1])})}get mediaBuckets(){return t(this,b)}}b=new WeakMap;var A,I;class U extends J.Store{constructor(e){super(void 0);a(this,A);a(this,I,()=>{let e;t(this,A).mediaBuckets.forEach((c,E)=>{matchMedia(E).matches&&(e=c)});let s,d=0;e==null||e.forEach(c=>{c.density>d&&c.density<=Math.max(devicePixelRatio,1)&&(d=c.density,s=c)}),e!=null&&e.length&&!s&&(s=e[0]),this.current=s});i(this,A,new Q(e.srcset))}close(){super.close(),this.disconnect()}connect(){K.windowResizer.subscribe(t(this,I),Z.RESIZE_ORDER.SOURCE_MANAGER)}disconnect(){K.windowResizer.unsubscribe(t(this,I))}}A=new WeakMap,I=new WeakMap;let tt=0;var m,h,q,S,f,w,u,M,L,z,O,T,_;class et extends HTMLElement{constructor(){super();a(this,L);a(this,m,null);a(this,h,null);a(this,q,!1);a(this,S,!1);a(this,f,!1);a(this,w,"");a(this,u,new W.ClassLinkedStatus(this,{loading:!1,loaded:!1,error:!1}));a(this,M,null);a(this,O,e=>{const s=e[0];t(this,f)&&(!t(this,S)||this.hasAttribute("reload-source"))&&s.isIntersecting&&(t(this,m).current&&t(this,m).current!==t(this,m).previous&&V(this,L,z).call(this,t(this,m).current),i(this,S,!0)),s.isIntersecting?this.dispatchEvent(new CustomEvent("sourceCapture")):(this.hasAttribute("reload-source")&&V(this,L,z).call(this,void 0),this.dispatchEvent(new CustomEvent("sourceRelease")))});a(this,T,()=>{t(this,u).set("loaded",!0),t(this,u).set("error",!1),t(this,u).set("loading",!1),!t(this,f)&&!t(this,q)&&B.loading.setLoaded(t(this,w),1),i(this,q,!0)});a(this,_,e=>{t(this,u).set("loaded",!1),t(this,u).set("error",!0),t(this,u).set("loading",!1),!t(this,f)&&!t(this,q)&&B.loading.setError(t(this,w),e),i(this,q,!0)});X.isBrowser&&(i(this,w,`source-consumer-${++tt}`),i(this,M,new IntersectionObserver(t(this,O))))}get consumerElement(){return t(this,h)}get sourceManager(){return t(this,m)}get status(){return t(this,u)}get isLazy(){return t(this,f)}connectedCallback(){const e=this.getAttribute("srcset");e&&(i(this,h,this.createConsumer()),t(this,h).style.cssText=`
2
2
  display: block;
3
3
  width: 100%;
4
4
  height: 100%;
5
- `,e(this,s).classList.add("source-consumer"),Array.from(this.attributes).forEach(o=>{if(o.name!=="srcset"){const S=o.nodeValue||"",M=x.kebabToCamel(o.name);M in e(this,s)&&(e(this,s)[M]=S||!0)}}),this.appendChild(e(this,s)),u(this,h,new C.SourceManager({srcset:t})),u(this,l,this.hasAttribute("lazy")),e(this,h).subscribe(o=>{(!e(this,l)||e(this,l)&&e(this,f))&&p(this,m,v).call(this,o.current)}),e(this,g).observe(this),e(this,h).connect())}disconnectedCallback(){e(this,g).disconnect(),e(this,h).close(),e(this,s).onloadeddata=null,e(this,s).onload=null,e(this,s).onerror=null,e(this,s).remove(),e(this,n).reset()}}h=new WeakMap,s=new WeakMap,c=new WeakMap,f=new WeakMap,l=new WeakMap,d=new WeakMap,n=new WeakMap,g=new WeakMap,m=new WeakSet,v=function(t){if(e(this,s).onloadeddata=null,e(this,s).onload=null,e(this,s).onerror=null,e(this,n).set("loaded",!1),e(this,n).set("error",!1),e(this,n).set("loading",!1),t){const o=this.hasAttribute("keep-source-parameters");e(this,n).set("loading",!0);const S=o?t.url:t.name+t.extension;this.consumeSource(S),!e(this,l)&&!e(this,c)&&w.loading.setTotal(e(this,d),1),e(this,s).onloadeddata=()=>{e(this,b).call(this)},e(this,s).onload=()=>{e(this,b).call(this)},e(this,s).onerror=()=>{e(this,L).call(this,S)}}else this.consumeSource(null)},E=new WeakMap,b=new WeakMap,L=new WeakMap;exports.Source=C.Source;exports.SourceManager=C.SourceManager;exports.SourceSet=C.SourceSet;exports.SourceElement=z;
5
+ `,t(this,h).classList.add("source-consumer"),Array.from(this.attributes).forEach(s=>{if(s.name!=="srcset"){const d=s.nodeValue||"",c=Y.kebabToCamel(s.name);c in t(this,h)&&(t(this,h)[c]=d||!0)}}),this.appendChild(t(this,h)),i(this,m,new U({srcset:e})),i(this,f,this.hasAttribute("lazy")),t(this,m).subscribe(s=>{(!t(this,f)||t(this,f)&&t(this,S))&&V(this,L,z).call(this,s.current)}),t(this,M).observe(this),t(this,m).connect())}disconnectedCallback(){t(this,M).disconnect(),t(this,m).close(),t(this,h).onloadeddata=null,t(this,h).onload=null,t(this,h).onerror=null,t(this,h).remove(),t(this,u).reset()}}m=new WeakMap,h=new WeakMap,q=new WeakMap,S=new WeakMap,f=new WeakMap,w=new WeakMap,u=new WeakMap,M=new WeakMap,L=new WeakSet,z=function(e){if(t(this,h).onloadeddata=null,t(this,h).onload=null,t(this,h).onerror=null,t(this,u).set("loaded",!1),t(this,u).set("error",!1),t(this,u).set("loading",!1),e){const s=this.hasAttribute("keep-source-parameters");t(this,u).set("loading",!0);const d=s?e.url:e.name+e.extension;this.consumeSource(d),!t(this,f)&&!t(this,q)&&B.loading.setTotal(t(this,w),1),t(this,h).onloadeddata=()=>{t(this,T).call(this)},t(this,h).onload=()=>{t(this,T).call(this)},t(this,h).onerror=()=>{t(this,_).call(this,d)}}else this.consumeSource(null)},O=new WeakMap,T=new WeakMap,_=new WeakMap;exports.Source=N;exports.SourceElement=et;exports.SourceManager=U;exports.SourceSet=Q;
@@ -1,97 +1,189 @@
1
- var y = (i) => {
2
- throw TypeError(i);
1
+ var K = (h) => {
2
+ throw TypeError(h);
3
3
  };
4
- var L = (i, r, s) => r.has(i) || y("Cannot " + s);
5
- var t = (i, r, s) => (L(i, r, "read from private field"), s ? s.call(i) : r.get(i)), a = (i, r, s) => r.has(i) ? y("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(i) : r.set(i, s), u = (i, r, s, n) => (L(i, r, "write to private field"), n ? n.call(i, s) : r.set(i, s), s), v = (i, r, s) => (L(i, r, "access private method"), s);
6
- import { S as A } from "../SourceManager-B6wZpXUZ.js";
7
- import { a as $, b as j } from "../SourceManager-B6wZpXUZ.js";
8
- import { loading as k } from "../loading/index.js";
9
- import { ClassLinkedStatus as x } from "../class-linked-status/index.js";
10
- import { i as M } from "../browser-0zX67oeU.js";
11
- import { k as T } from "../string-f0Dnk0L1.js";
12
- let z = 0;
13
- var h, e, c, f, l, d, o, m, p, S, C, g, E;
14
- class P extends HTMLElement {
4
+ var O = (h, r, e) => r.has(h) || K("Cannot " + e);
5
+ var t = (h, r, e) => (O(h, r, "read from private field"), e ? e.call(h) : r.get(h)), a = (h, r, e) => r.has(h) ? K("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(h) : r.set(h, e), i = (h, r, e, s) => (O(h, r, "write to private field"), s ? s.call(h, e) : r.set(h, e), e), V = (h, r, e) => (O(h, r, "access private method"), e);
6
+ import { RESIZE_ORDER as Q } from "../order/index.js";
7
+ import { windowResizer as N } from "../window-resizer/index.js";
8
+ import { S as U } from "../Store-OTdcl6SX.js";
9
+ import { loading as P } from "../loading/index.js";
10
+ import { ClassLinkedStatus as Z } from "../class-linked-status/index.js";
11
+ import { i as j } from "../browser-0zX67oeU.js";
12
+ import { k as J } from "../string-f0Dnk0L1.js";
13
+ var M, A, I, g, u, y, R;
14
+ class W {
15
+ constructor(r) {
16
+ a(this, M);
17
+ a(this, A);
18
+ a(this, I);
19
+ a(this, g);
20
+ a(this, u);
21
+ a(this, y);
22
+ a(this, R);
23
+ i(this, M, r);
24
+ const e = r.indexOf("?");
25
+ e >= 0 && (r = r.slice(0, e));
26
+ const s = r.split(".");
27
+ i(this, A, s[0]);
28
+ const d = /\d+x/g, c = s.find((p) => p.match(d));
29
+ i(this, I, c ? parseInt(c) : 1);
30
+ const q = /\d+max/g, H = /\d+min/g, n = /\d+mar/g, x = /\d+mir/g, D = s.find((p) => p.match(q)), _ = s.find((p) => p.match(H)), F = s.find((p) => p.match(n)), G = s.find((p) => p.match(x));
31
+ F ? (i(this, u, parseInt(F)), i(this, y, "max"), i(this, g, `(max-aspect-ratio: ${t(this, u)})`)) : G ? (i(this, u, parseInt(G)), i(this, y, "max"), i(this, g, `(min-aspect-ratio: ${t(this, u)})`)) : D ? (i(this, u, parseInt(D)), i(this, y, "max"), i(this, g, `(max-width: ${t(this, u)}px)`)) : _ ? (i(this, u, parseInt(_)), i(this, g, `(min-width: ${t(this, u)}px)`), i(this, y, "min")) : (i(this, u, 0), i(this, g, `(min-width: ${t(this, u)}px)`), i(this, y, "min")), i(this, R, "." + s[s.length - 1]);
32
+ }
33
+ get url() {
34
+ return t(this, M);
35
+ }
36
+ get name() {
37
+ return t(this, A);
38
+ }
39
+ get density() {
40
+ return t(this, I);
41
+ }
42
+ get query() {
43
+ return t(this, g);
44
+ }
45
+ get extension() {
46
+ return t(this, R);
47
+ }
48
+ get queryType() {
49
+ return t(this, y);
50
+ }
51
+ get queryValue() {
52
+ return t(this, u);
53
+ }
54
+ }
55
+ M = new WeakMap(), A = new WeakMap(), I = new WeakMap(), g = new WeakMap(), u = new WeakMap(), y = new WeakMap(), R = new WeakMap();
56
+ var b;
57
+ class X {
58
+ constructor(r) {
59
+ a(this, b);
60
+ i(this, b, /* @__PURE__ */ new Map());
61
+ const e = typeof r == "string" ? r.trim().split(",").map((n) => n.trim()).filter((n) => !!n) : r, s = [];
62
+ e.forEach((n) => {
63
+ const x = new W(n);
64
+ s.push([x.query, x]);
65
+ });
66
+ const d = s.filter((n) => n[1].queryType.includes("max")).sort((n, x) => x[1].queryValue - n[1].queryValue), c = s.filter((n) => n[1].queryType.includes("min") && n[1].queryValue !== 0).sort((n, x) => n[1].queryValue - x[1].queryValue), q = s.filter((n) => n[0] === "(min-width: 0px)");
67
+ (q ? [...q, ...d, ...c] : [...d, ...c]).forEach((n) => {
68
+ t(this, b).has(n[0]) || t(this, b).set(n[0], []), t(this, b).get(n[0]).push(n[1]);
69
+ });
70
+ }
71
+ get mediaBuckets() {
72
+ return t(this, b);
73
+ }
74
+ }
75
+ b = new WeakMap();
76
+ var S, v;
77
+ class Y extends U {
78
+ constructor(e) {
79
+ super(void 0);
80
+ a(this, S);
81
+ a(this, v, () => {
82
+ let e;
83
+ t(this, S).mediaBuckets.forEach((c, q) => {
84
+ matchMedia(q).matches && (e = c);
85
+ });
86
+ let s, d = 0;
87
+ e == null || e.forEach((c) => {
88
+ c.density > d && c.density <= Math.max(devicePixelRatio, 1) && (d = c.density, s = c);
89
+ }), e != null && e.length && !s && (s = e[0]), this.current = s;
90
+ });
91
+ i(this, S, new X(e.srcset));
92
+ }
93
+ close() {
94
+ super.close(), this.disconnect();
95
+ }
96
+ connect() {
97
+ N.subscribe(t(this, v), Q.SOURCE_MANAGER);
98
+ }
99
+ disconnect() {
100
+ N.unsubscribe(t(this, v));
101
+ }
102
+ }
103
+ S = new WeakMap(), v = new WeakMap();
104
+ let tt = 0;
105
+ var m, o, E, k, f, w, l, C, L, $, z, T, B;
106
+ class ct extends HTMLElement {
15
107
  constructor() {
16
108
  super();
17
- a(this, p);
18
- a(this, h, null);
19
- a(this, e, null);
20
- a(this, c, !1);
109
+ a(this, L);
110
+ a(this, m, null);
111
+ a(this, o, null);
112
+ a(this, E, !1);
113
+ a(this, k, !1);
21
114
  a(this, f, !1);
22
- a(this, l, !1);
23
- a(this, d, "");
24
- a(this, o, new x(this, {
115
+ a(this, w, "");
116
+ a(this, l, new Z(this, {
25
117
  loading: !1,
26
118
  loaded: !1,
27
119
  error: !1
28
120
  }));
29
- a(this, m, null);
30
- a(this, C, (s) => {
31
- const n = s[0];
32
- t(this, l) && (!t(this, f) || this.hasAttribute("reload-source")) && n.isIntersecting && (t(this, h).current && t(this, h).current !== t(this, h).previous && v(this, p, S).call(this, t(this, h).current), u(this, f, !0)), n.isIntersecting ? this.dispatchEvent(new CustomEvent("sourceCapture")) : (this.hasAttribute("reload-source") && v(this, p, S).call(this, void 0), this.dispatchEvent(new CustomEvent("sourceRelease")));
121
+ a(this, C, null);
122
+ a(this, z, (e) => {
123
+ const s = e[0];
124
+ t(this, f) && (!t(this, k) || this.hasAttribute("reload-source")) && s.isIntersecting && (t(this, m).current && t(this, m).current !== t(this, m).previous && V(this, L, $).call(this, t(this, m).current), i(this, k, !0)), s.isIntersecting ? this.dispatchEvent(new CustomEvent("sourceCapture")) : (this.hasAttribute("reload-source") && V(this, L, $).call(this, void 0), this.dispatchEvent(new CustomEvent("sourceRelease")));
33
125
  });
34
- a(this, g, () => {
35
- t(this, o).set("loaded", !0), t(this, o).set("error", !1), t(this, o).set("loading", !1), !t(this, l) && !t(this, c) && k.setLoaded(t(this, d), 1), u(this, c, !0);
126
+ a(this, T, () => {
127
+ t(this, l).set("loaded", !0), t(this, l).set("error", !1), t(this, l).set("loading", !1), !t(this, f) && !t(this, E) && P.setLoaded(t(this, w), 1), i(this, E, !0);
36
128
  });
37
- a(this, E, (s) => {
38
- t(this, o).set("loaded", !1), t(this, o).set("error", !0), t(this, o).set("loading", !1), !t(this, l) && !t(this, c) && k.setError(t(this, d), s), u(this, c, !0);
129
+ a(this, B, (e) => {
130
+ t(this, l).set("loaded", !1), t(this, l).set("error", !0), t(this, l).set("loading", !1), !t(this, f) && !t(this, E) && P.setError(t(this, w), e), i(this, E, !0);
39
131
  });
40
- M && (u(this, d, `source-consumer-${++z}`), u(this, m, new IntersectionObserver(
41
- t(this, C)
132
+ j && (i(this, w, `source-consumer-${++tt}`), i(this, C, new IntersectionObserver(
133
+ t(this, z)
42
134
  )));
43
135
  }
44
136
  get consumerElement() {
45
- return t(this, e);
137
+ return t(this, o);
46
138
  }
47
139
  get sourceManager() {
48
- return t(this, h);
140
+ return t(this, m);
49
141
  }
50
142
  get status() {
51
- return t(this, o);
143
+ return t(this, l);
52
144
  }
53
145
  get isLazy() {
54
- return t(this, l);
146
+ return t(this, f);
55
147
  }
56
148
  connectedCallback() {
57
- const s = this.getAttribute("srcset");
58
- s && (u(this, e, this.createConsumer()), t(this, e).style.cssText = `
149
+ const e = this.getAttribute("srcset");
150
+ e && (i(this, o, this.createConsumer()), t(this, o).style.cssText = `
59
151
  display: block;
60
152
  width: 100%;
61
153
  height: 100%;
62
- `, t(this, e).classList.add("source-consumer"), Array.from(this.attributes).forEach((n) => {
63
- if (n.name !== "srcset") {
64
- const b = n.nodeValue || "", w = T(n.name);
65
- w in t(this, e) && (t(this, e)[w] = b || !0);
154
+ `, t(this, o).classList.add("source-consumer"), Array.from(this.attributes).forEach((s) => {
155
+ if (s.name !== "srcset") {
156
+ const d = s.nodeValue || "", c = J(s.name);
157
+ c in t(this, o) && (t(this, o)[c] = d || !0);
66
158
  }
67
- }), this.appendChild(t(this, e)), u(this, h, new A({
68
- srcset: s
69
- })), u(this, l, this.hasAttribute("lazy")), t(this, h).subscribe((n) => {
70
- (!t(this, l) || t(this, l) && t(this, f)) && v(this, p, S).call(this, n.current);
71
- }), t(this, m).observe(this), t(this, h).connect());
159
+ }), this.appendChild(t(this, o)), i(this, m, new Y({
160
+ srcset: e
161
+ })), i(this, f, this.hasAttribute("lazy")), t(this, m).subscribe((s) => {
162
+ (!t(this, f) || t(this, f) && t(this, k)) && V(this, L, $).call(this, s.current);
163
+ }), t(this, C).observe(this), t(this, m).connect());
72
164
  }
73
165
  disconnectedCallback() {
74
- t(this, m).disconnect(), t(this, h).close(), t(this, e).onloadeddata = null, t(this, e).onload = null, t(this, e).onerror = null, t(this, e).remove(), t(this, o).reset();
166
+ t(this, C).disconnect(), t(this, m).close(), t(this, o).onloadeddata = null, t(this, o).onload = null, t(this, o).onerror = null, t(this, o).remove(), t(this, l).reset();
75
167
  }
76
168
  }
77
- h = new WeakMap(), e = new WeakMap(), c = new WeakMap(), f = new WeakMap(), l = new WeakMap(), d = new WeakMap(), o = new WeakMap(), m = new WeakMap(), p = new WeakSet(), S = function(s) {
78
- if (t(this, e).onloadeddata = null, t(this, e).onload = null, t(this, e).onerror = null, t(this, o).set("loaded", !1), t(this, o).set("error", !1), t(this, o).set("loading", !1), s) {
79
- const n = this.hasAttribute("keep-source-parameters");
80
- t(this, o).set("loading", !0);
81
- const b = n ? s.url : s.name + s.extension;
82
- this.consumeSource(b), !t(this, l) && !t(this, c) && k.setTotal(t(this, d), 1), t(this, e).onloadeddata = () => {
83
- t(this, g).call(this);
84
- }, t(this, e).onload = () => {
85
- t(this, g).call(this);
86
- }, t(this, e).onerror = () => {
87
- t(this, E).call(this, b);
169
+ m = new WeakMap(), o = new WeakMap(), E = new WeakMap(), k = new WeakMap(), f = new WeakMap(), w = new WeakMap(), l = new WeakMap(), C = new WeakMap(), L = new WeakSet(), $ = function(e) {
170
+ if (t(this, o).onloadeddata = null, t(this, o).onload = null, t(this, o).onerror = null, t(this, l).set("loaded", !1), t(this, l).set("error", !1), t(this, l).set("loading", !1), e) {
171
+ const s = this.hasAttribute("keep-source-parameters");
172
+ t(this, l).set("loading", !0);
173
+ const d = s ? e.url : e.name + e.extension;
174
+ this.consumeSource(d), !t(this, f) && !t(this, E) && P.setTotal(t(this, w), 1), t(this, o).onloadeddata = () => {
175
+ t(this, T).call(this);
176
+ }, t(this, o).onload = () => {
177
+ t(this, T).call(this);
178
+ }, t(this, o).onerror = () => {
179
+ t(this, B).call(this, d);
88
180
  };
89
181
  } else
90
182
  this.consumeSource(null);
91
- }, C = new WeakMap(), g = new WeakMap(), E = new WeakMap();
183
+ }, z = new WeakMap(), T = new WeakMap(), B = new WeakMap();
92
184
  export {
93
- $ as Source,
94
- P as SourceElement,
95
- A as SourceManager,
96
- j as SourceSet
185
+ W as Source,
186
+ ct as SourceElement,
187
+ Y as SourceManager,
188
+ X as SourceSet
97
189
  };
@@ -1 +1 @@
1
- "use strict";var f=e=>{throw TypeError(e)};var S=(e,t,r)=>t.has(e)||f("Cannot "+r);var s=(e,t,r)=>(S(e,t,"read from private field"),r?r.call(e):t.get(e)),h=(e,t,r)=>t.has(e)?f("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),d=(e,t,r,i)=>(S(e,t,"write to private field"),i?i.call(e,r):t.set(e,r),r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../Store-npaZHvX4.cjs"),y=require("../Derived-BIBU-y7Z.cjs"),D=require("../Composed-C_4slJQ6.cjs");var a;class x extends o.Store{constructor(r,i,u){super(null,u);h(this,a);d(this,a,r.subscribe(v=>{this.current=v.current.map((g,b,m)=>i(g,b,m))}))}close(){super.close(),s(this,a).call(this)}}a=new WeakMap;var l,c,n;class C extends o.Store{constructor(r,i,u){super(r,u);h(this,l);h(this,c);h(this,n,0);d(this,c,new o.Store(!1)),d(this,l,i),u!=null&&u.manualControl||this.refetch()}get isPending(){return s(this,c)}refetch(){s(this,c).current=!0,d(this,n,s(this,n)+1);const r=s(this,n);s(this,l).call(this).then(i=>{r===s(this,n)&&(s(this,c).current=!1,this.current=i)})}}l=new WeakMap,c=new WeakMap,n=new WeakMap;exports.Store=o.Store;exports.activeStores=o.activeStores;exports.storeRegistry=o.storeRegistry;exports.Derived=y.Derived;exports.Composed=D.Composed;exports.DerivedArray=x;exports.Resource=C;
1
+ "use strict";var g=r=>{throw TypeError(r)};var v=(r,s,e)=>s.has(r)||g("Cannot "+e);var c=(r,s,e)=>(v(r,s,"read from private field"),e?e.call(r):s.get(r)),n=(r,s,e)=>s.has(r)?g("Cannot add the same private member more than once"):s instanceof WeakSet?s.add(r):s.set(r,e),h=(r,s,e,t)=>(v(r,s,"write to private field"),t?t.call(r,e):s.set(r,e),e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../Store-CDb6RMce.cjs"),m=require("../function-MthRj-GJ.cjs");var d;class D extends i.Store{constructor(e,t,u){super(null,u);n(this,d);h(this,d,e.subscribe(a=>{this.current=t(a.current)}))}close(){super.close(),c(this,d).call(this)}}d=new WeakMap;var b;class R extends i.Store{constructor(e,t,u){super(null,u);n(this,b);h(this,b,e.subscribe(a=>{this.current=a.current.map((p,x,y)=>t(p,x,y))}))}close(){super.close(),c(this,b).call(this)}}b=new WeakMap;var f,o,l;class C extends i.Store{constructor(e,t,u){super(e,u);n(this,f);n(this,o);n(this,l,0);h(this,o,new i.Store(!1)),h(this,f,t),u!=null&&u.manualControl||this.refetch()}get isPending(){return c(this,o)}refetch(){c(this,o).current=!0,h(this,l,c(this,l)+1);const e=c(this,l);c(this,f).call(this).then(t=>{e===c(this,l)&&(c(this,o).current=!1,this.current=t)})}}f=new WeakMap,o=new WeakMap,l=new WeakMap;var S;class P extends i.Store{constructor(e,t,u){super(null,u);n(this,S,[]);const a=m.debounce(()=>{this.current=t()},0);e.forEach(p=>{c(this,S).push(p.subscribe(()=>{a()}))})}close(){super.close(),c(this,S).forEach(e=>e())}}S=new WeakMap;exports.Store=i.Store;exports.activeStores=i.activeStores;exports.storeRegistry=i.storeRegistry;exports.Composed=P;exports.Derived=D;exports.DerivedArray=R;exports.Resource=C;
@@ -1,53 +1,87 @@
1
- var d = (e) => {
1
+ var x = (e) => {
2
2
  throw TypeError(e);
3
3
  };
4
- var m = (e, s, r) => s.has(e) || d("Cannot " + r);
5
- var t = (e, s, r) => (m(e, s, "read from private field"), r ? r.call(e) : s.get(e)), u = (e, s, r) => s.has(e) ? d("Cannot add the same private member more than once") : s instanceof WeakSet ? s.add(e) : s.set(e, r), a = (e, s, r, c) => (m(e, s, "write to private field"), c ? c.call(e, r) : s.set(e, r), r);
6
- import { S as l } from "../Store-C46i0nvr.js";
7
- import { a as P, s as R } from "../Store-C46i0nvr.js";
8
- import { D as A } from "../Derived-Vo_RsJfi.js";
9
- import { C as k } from "../Composed-CfWa-69I.js";
10
- var o;
11
- class D extends l {
12
- constructor(r, c, h) {
13
- super(null, h);
14
- u(this, o);
15
- a(this, o, r.subscribe((x) => {
16
- this.current = x.current.map((p, b, g) => c(p, b, g));
4
+ var g = (e, r, s) => r.has(e) || x("Cannot " + s);
5
+ var c = (e, r, s) => (g(e, r, "read from private field"), s ? s.call(e) : r.get(e)), i = (e, r, s) => r.has(e) ? x("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(e) : r.set(e, s), h = (e, r, s, t) => (g(e, r, "write to private field"), t ? t.call(e, s) : r.set(e, s), s);
6
+ import { S as a } from "../Store-OTdcl6SX.js";
7
+ import { a as k, s as q } from "../Store-OTdcl6SX.js";
8
+ import { d as y } from "../function-C10DGppn.js";
9
+ var d;
10
+ class I extends a {
11
+ constructor(s, t, u) {
12
+ super(null, u);
13
+ i(this, d);
14
+ h(this, d, s.subscribe((l) => {
15
+ this.current = t(l.current);
17
16
  }));
18
17
  }
19
18
  close() {
20
- super.close(), t(this, o).call(this);
19
+ super.close(), c(this, d).call(this);
21
20
  }
22
21
  }
23
- o = new WeakMap();
24
- var f, i, n;
25
- class S extends l {
26
- constructor(r, c, h) {
27
- super(r, h);
28
- u(this, f);
29
- u(this, i);
30
- u(this, n, 0);
31
- a(this, i, new l(!1)), a(this, f, c), h != null && h.manualControl || this.refetch();
22
+ d = new WeakMap();
23
+ var f;
24
+ class P extends a {
25
+ constructor(s, t, u) {
26
+ super(null, u);
27
+ i(this, f);
28
+ h(this, f, s.subscribe((l) => {
29
+ this.current = l.current.map((m, v, S) => t(m, v, S));
30
+ }));
31
+ }
32
+ close() {
33
+ super.close(), c(this, f).call(this);
34
+ }
35
+ }
36
+ f = new WeakMap();
37
+ var b, n, o;
38
+ class R extends a {
39
+ constructor(s, t, u) {
40
+ super(s, u);
41
+ i(this, b);
42
+ i(this, n);
43
+ i(this, o, 0);
44
+ h(this, n, new a(!1)), h(this, b, t), u != null && u.manualControl || this.refetch();
32
45
  }
33
46
  get isPending() {
34
- return t(this, i);
47
+ return c(this, n);
35
48
  }
36
49
  refetch() {
37
- t(this, i).current = !0, a(this, n, t(this, n) + 1);
38
- const r = t(this, n);
39
- t(this, f).call(this).then((c) => {
40
- r === t(this, n) && (t(this, i).current = !1, this.current = c);
50
+ c(this, n).current = !0, h(this, o, c(this, o) + 1);
51
+ const s = c(this, o);
52
+ c(this, b).call(this).then((t) => {
53
+ s === c(this, o) && (c(this, n).current = !1, this.current = t);
41
54
  });
42
55
  }
43
56
  }
44
- f = new WeakMap(), i = new WeakMap(), n = new WeakMap();
57
+ b = new WeakMap(), n = new WeakMap(), o = new WeakMap();
58
+ var p;
59
+ class w extends a {
60
+ constructor(s, t, u) {
61
+ super(null, u);
62
+ i(this, p, []);
63
+ const l = y(() => {
64
+ this.current = t();
65
+ }, 0);
66
+ s.forEach((m) => {
67
+ c(this, p).push(
68
+ m.subscribe(() => {
69
+ l();
70
+ })
71
+ );
72
+ });
73
+ }
74
+ close() {
75
+ super.close(), c(this, p).forEach((s) => s());
76
+ }
77
+ }
78
+ p = new WeakMap();
45
79
  export {
46
- k as Composed,
47
- A as Derived,
48
- D as DerivedArray,
49
- S as Resource,
50
- l as Store,
51
- P as activeStores,
52
- R as storeRegistry
80
+ w as Composed,
81
+ I as Derived,
82
+ P as DerivedArray,
83
+ R as Resource,
84
+ a as Store,
85
+ k as activeStores,
86
+ q as storeRegistry
53
87
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("../attributes-Bf2svn4j.cjs"),S=require("../browser-CpzFX2xg.cjs"),l=require("../canvas-CU5Xjahf.cjs"),d=require("../coordinates-D8Np3cPD.cjs"),p=require("../dom-JBOkFLTh.cjs"),a=require("../easings-DsS5-Kqc.cjs"),f=require("../file-C9BbxzVU.cjs"),C=require("../function-MthRj-GJ.cjs"),I=require("../gestures-DHLrn6Q8.cjs"),g=require("../layout-8ryRAMGJ.cjs"),s=require("../math-GDWEqu7y.cjs"),m=require("../polyfills-CM4SCDTt.cjs"),r=require("../object-CCiXnER2.cjs"),u=require("../string-DhgS_iFl.cjs"),O=require("../style-At6aDoqG.cjs"),h=require("../url-C3dWnJQg.cjs");function y(t,e,...n){return[...t.slice(0,e),...n,...t.slice(e)]}function P(t,e){const n=t.length;e=e%n;const i=new Array(n);for(let o=0;o<n;o++){const c=(o+e)%n;i[c]=t[o]}return i}function T(t,e=2){if(!+t)return"0 Bytes";const n=1024,i=e<0?0:e,o=["Bytes","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],c=Math.floor(Math.log(t)/Math.log(n));return`${parseFloat((t/Math.pow(n,c)).toFixed(i))} ${o[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 w(t,e){return Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2)<e.radius}function E(t,e){const n=t.styleMap.get(e);if(n){const i=n.toString();return i.startsWith("var")?E(t,i.slice(4,-1)):i}}function x(...t){const e={};return Array.from(document.styleSheets).forEach(n=>{Array.from(n.cssRules).forEach(i=>{i instanceof CSSStyleRule&&i.selectorText===":root"&&t.forEach(o=>{const c=E(i,o);c&&(e[o]=c)})})}),t.forEach(n=>{e[n]||console.warn(`variable named ${n} not found`)}),e}function B(t){const e=window.atob(t);return decodeURIComponent(window.escape(e))}function Q(t){const e=window.unescape(encodeURIComponent(t));return window.btoa(e)}function q(t){return new Promise(e=>{setTimeout(()=>{e()},t)})}exports.parseAttribute=b.parseAttribute;exports.parseAttributeValue=b.parseAttributeValue;exports.isBrowser=S.isBrowser;exports.contain=l.contain;exports.cover=l.cover;exports.fixPosition=l.fixPosition;exports.measureText=l.measureText;exports.getPointerPosition=d.getPointerPosition;exports.normalize=d.normalize;exports.screenToCartesian=d.screenToCartesian;exports.findParentElement=p.findParentElement;exports.findScrollParentElement=p.findScrollParentElement;exports.getAllParentElements=p.getAllParentElements;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.createJSONAndSave=f.createJSONAndSave;exports.dispatchBeforeSizeChangeEvent=f.dispatchBeforeSizeChangeEvent;exports.dispatchSizeChangeEvent=f.dispatchSizeChangeEvent;exports.debounce=C.debounce;exports.throttle=C.throttle;exports.setupDrag=I.setupDrag;exports.getCumulativeOffsetLeft=g.getCumulativeOffsetLeft;exports.getCumulativeOffsetTop=g.getCumulativeOffsetTop;exports.getCumulativePosition=g.getCumulativePosition;exports.calculateDistance=s.calculateDistance;exports.calculateDistanceWithRadius=s.calculateDistanceWithRadius;exports.clamp=s.clamp;exports.damp=s.damp;exports.lerp=s.lerp;exports.mapRange=s.mapRange;exports.round=s.round;exports.smootherstep=s.smootherstep;exports.smoothstep=s.smoothstep;exports.step=s.step;exports.nullishCoalescing=m.nullishCoalescing;exports.preciseNumber=m.preciseNumber;exports.roundNumberTo=m.roundNumberTo;exports.toStep=m.toStep;exports.cloneDeep=r.cloneDeep;exports.compareObjects=r.compareObjects;exports.isESClass=r.isESClass;exports.isNullish=r.isNullish;exports.isObject=r.isObject;exports.mergeDeep=r.mergeDeep;exports.mixin=r.mixin;exports.omit=r.omit;exports.pick=r.pick;exports.camelToKebab=u.camelToKebab;exports.capitalize=u.capitalize;exports.generateId=u.generateId;exports.isUppercase=u.isUppercase;exports.kebabToCamel=u.kebabToCamel;exports.snakeToDotted=u.snakeToDotted;exports.toPascalCase=u.toPascalCase;exports.uncapitalize=u.uncapitalize;exports.getElementTransitionDurationMS=O.getElementTransitionDurationMS;exports.getElementTransitionDurationS=O.getElementTransitionDurationS;exports.changeHistory=h.changeHistory;exports.normalizeBase=h.normalizeBase;exports.splitPath=h.splitPath;exports.decode=Q;exports.dotCircleCollision=w;exports.dotRectCollision=v;exports.encode=B;exports.formatBytes=T;exports.getRootVariables=x;exports.insert=y;exports.shiftArray=P;exports.wait=q;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("../attributes-Bf2svn4j.cjs"),y=require("../browser-CpzFX2xg.cjs"),l=require("../canvas-CU5Xjahf.cjs"),d=require("../coordinates-D8Np3cPD.cjs"),p=require("../dom-JBOkFLTh.cjs"),a=require("../easings-DsS5-Kqc.cjs"),f=require("../file-C9BbxzVU.cjs"),C=require("../function-MthRj-GJ.cjs"),I=require("../gestures-DHLrn6Q8.cjs"),O=require("../jss-GJLvaNfT.cjs"),g=require("../layout-8ryRAMGJ.cjs"),s=require("../math-GDWEqu7y.cjs"),m=require("../polyfills-CM4SCDTt.cjs"),r=require("../object-CCiXnER2.cjs"),u=require("../string-DhgS_iFl.cjs"),S=require("../style-At6aDoqG.cjs"),h=require("../url-C3dWnJQg.cjs");function T(t,e,...n){return[...t.slice(0,e),...n,...t.slice(e)]}function P(t,e){const n=t.length;e=e%n;const i=new Array(n);for(let o=0;o<n;o++){const c=(o+e)%n;i[c]=t[o]}return i}function v(t,e=2){if(!+t)return"0 Bytes";const n=1024,i=e<0?0:e,o=["Bytes","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],c=Math.floor(Math.log(t)/Math.log(n));return`${parseFloat((t/Math.pow(n,c)).toFixed(i))} ${o[c]}`}function w(t,e){return t.x<e.x+e.width&&t.x>e.x&&t.y<e.y+e.height&&t.y>e.y}function x(t,e){return Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2)<e.radius}function E(t,e){const n=t.styleMap.get(e);if(n){const i=n.toString();return i.startsWith("var")?E(t,i.slice(4,-1)):i}}function q(...t){const e={};return Array.from(document.styleSheets).forEach(n=>{Array.from(n.cssRules).forEach(i=>{i instanceof CSSStyleRule&&i.selectorText===":root"&&t.forEach(o=>{const c=E(i,o);c&&(e[o]=c)})})}),t.forEach(n=>{e[n]||console.warn(`variable named ${n} not found`)}),e}function B(t){const e=window.atob(t);return decodeURIComponent(window.escape(e))}function Q(t){const e=window.unescape(encodeURIComponent(t));return window.btoa(e)}function D(t){return new Promise(e=>{setTimeout(()=>{e()},t)})}exports.parseAttribute=b.parseAttribute;exports.parseAttributeValue=b.parseAttributeValue;exports.isBrowser=y.isBrowser;exports.contain=l.contain;exports.cover=l.cover;exports.fixPosition=l.fixPosition;exports.measureText=l.measureText;exports.getPointerPosition=d.getPointerPosition;exports.normalize=d.normalize;exports.screenToCartesian=d.screenToCartesian;exports.findParentElement=p.findParentElement;exports.findScrollParentElement=p.findScrollParentElement;exports.getAllParentElements=p.getAllParentElements;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.createJSONAndSave=f.createJSONAndSave;exports.dispatchBeforeSizeChangeEvent=f.dispatchBeforeSizeChangeEvent;exports.dispatchSizeChangeEvent=f.dispatchSizeChangeEvent;exports.debounce=C.debounce;exports.throttle=C.throttle;exports.setupDrag=I.setupDrag;exports.createStylesheet=O.createStylesheet;exports.styleToString=O.styleToString;exports.getCumulativeOffsetLeft=g.getCumulativeOffsetLeft;exports.getCumulativeOffsetTop=g.getCumulativeOffsetTop;exports.getCumulativePosition=g.getCumulativePosition;exports.calculateDistance=s.calculateDistance;exports.calculateDistanceWithRadius=s.calculateDistanceWithRadius;exports.clamp=s.clamp;exports.damp=s.damp;exports.lerp=s.lerp;exports.mapRange=s.mapRange;exports.round=s.round;exports.smootherstep=s.smootherstep;exports.smoothstep=s.smoothstep;exports.step=s.step;exports.nullishCoalescing=m.nullishCoalescing;exports.preciseNumber=m.preciseNumber;exports.roundNumberTo=m.roundNumberTo;exports.toStep=m.toStep;exports.cloneDeep=r.cloneDeep;exports.compareObjects=r.compareObjects;exports.isESClass=r.isESClass;exports.isNullish=r.isNullish;exports.isObject=r.isObject;exports.mergeDeep=r.mergeDeep;exports.mixin=r.mixin;exports.omit=r.omit;exports.pick=r.pick;exports.camelToKebab=u.camelToKebab;exports.capitalize=u.capitalize;exports.generateId=u.generateId;exports.isUppercase=u.isUppercase;exports.kebabToCamel=u.kebabToCamel;exports.snakeToDotted=u.snakeToDotted;exports.toPascalCase=u.toPascalCase;exports.uncapitalize=u.uncapitalize;exports.getElementTransitionDurationMS=S.getElementTransitionDurationMS;exports.getElementTransitionDurationS=S.getElementTransitionDurationS;exports.changeHistory=h.changeHistory;exports.normalizeBase=h.normalizeBase;exports.splitPath=h.splitPath;exports.decode=Q;exports.dotCircleCollision=x;exports.dotRectCollision=w;exports.encode=B;exports.formatBytes=v;exports.getRootVariables=q;exports.insert=T;exports.shiftArray=P;exports.wait=D;