aptechka 0.82.5 → 0.83.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 (141) hide show
  1. package/lib/{Animation-DxtCzFP3.js → Animation-BzTjZIE-.js} +2 -2
  2. package/lib/{Animation-jmvFcNfM.cjs → Animation-C39Ah-LM.cjs} +1 -1
  3. package/lib/{Composed-DtS09lSU.js → Composed-C-mnUGX6.js} +2 -2
  4. package/lib/{Composed-CSeUTRCg.cjs → Composed-RFcm2x5c.cjs} +1 -1
  5. package/lib/{Damped-DMnIOXpC.js → Damped-CRusiRIV.js} +2 -2
  6. package/lib/{Damped-77Urmi3q.cjs → Damped-Prr0iKu1.cjs} +1 -1
  7. package/lib/{DerivedArray-B8A0-8uT.cjs → DerivedArray-DdCR-Oy7.cjs} +1 -1
  8. package/lib/{DerivedArray-DG9iR0mf.js → DerivedArray-opbeygTL.js} +1 -1
  9. package/lib/{DragControls-BlL26P1V.cjs → DragControls-8rNZwQrs.cjs} +1 -1
  10. package/lib/{DragControls-DCC8iEOR.js → DragControls-DBNdMBA4.js} +4 -4
  11. package/lib/{LocalLinks-Bua7BGRF.cjs → LocalLinks-BxhSFv_Q.cjs} +1 -1
  12. package/lib/{LocalLinks-TQkTpAMx.js → LocalLinks-DRAQ-fxE.js} +3 -3
  13. package/lib/{PageAnnouncerElement-sfh0_4vl.js → PageAnnouncerElement-0LxZjtVH.js} +1 -1
  14. package/lib/{PageAnnouncerElement-C4k2kDJ5.cjs → PageAnnouncerElement-AQ0Ja6HM.cjs} +1 -1
  15. package/lib/{PageScroll-cQ3B5-6N.js → PageScroll-0LxFblry.js} +1 -1
  16. package/lib/{PageScroll-C7QBpx0G.cjs → PageScroll-BXJUQwG7.cjs} +1 -1
  17. package/lib/{SourceElement-TzgPNQOd.cjs → SourceElement-BHqPFbna.cjs} +1 -1
  18. package/lib/{SourceElement-BQ7g2KWK.js → SourceElement-DjbHjynf.js} +2 -2
  19. package/lib/{Store-1JrMCgdX.cjs → Store-Blf4msDz.cjs} +1 -1
  20. package/lib/{Store-CgQ3ReoB.js → Store-ZThXYBQd.js} +1 -1
  21. package/lib/{Tweened-lT68VACv.js → Tweened-Bw1Cn1PJ.js} +2 -2
  22. package/lib/{Tweened-CXQrFQth.cjs → Tweened-DWtk9E-O.cjs} +1 -1
  23. package/lib/{Viewport-Cx50Hufs.cjs → Viewport-BxCr0GlB.cjs} +1 -1
  24. package/lib/{Viewport-DGnJ31b4.js → Viewport-Dt-d9DPi.js} +2 -2
  25. package/lib/accordion/index.cjs +1 -1
  26. package/lib/accordion/index.js +1 -1
  27. package/lib/animation/index.cjs +1 -1
  28. package/lib/animation/index.js +3 -3
  29. package/lib/api-fetcher/index.cjs +1 -0
  30. package/lib/api-fetcher/index.d.ts +16 -0
  31. package/lib/api-fetcher/index.js +100 -0
  32. package/lib/attribute/index.cjs +1 -1
  33. package/lib/attribute/index.js +3 -3
  34. package/lib/billboard/index.cjs +1 -1
  35. package/lib/billboard/index.js +2 -2
  36. package/lib/canvas/index.cjs +1 -1
  37. package/lib/canvas/index.js +2 -2
  38. package/lib/controls/index.cjs +1 -1
  39. package/lib/controls/index.js +1 -1
  40. package/lib/css-property/index.cjs +1 -1
  41. package/lib/css-property/index.js +3 -3
  42. package/lib/css-value-parser/index.cjs +1 -1
  43. package/lib/css-value-parser/index.js +1 -1
  44. package/lib/dev/index.cjs +1 -1
  45. package/lib/dev/index.js +2 -2
  46. package/lib/device/index.cjs +1 -1
  47. package/lib/device/index.js +1 -1
  48. package/lib/dom-BETkVSSZ.js +82 -0
  49. package/lib/dom-CBLlqORw.cjs +1 -0
  50. package/lib/element-linked-store/index.cjs +1 -1
  51. package/lib/element-linked-store/index.js +2 -2
  52. package/lib/element-resizer/index.cjs +1 -1
  53. package/lib/element-resizer/index.js +2 -2
  54. package/lib/en3/index.cjs +1 -1
  55. package/lib/en3/index.js +2 -2
  56. package/lib/iframe/index.cjs +1 -1
  57. package/lib/iframe/index.js +3 -3
  58. package/lib/image/index.cjs +1 -1
  59. package/lib/image/index.js +4 -4
  60. package/lib/{index-CKTweR3M.cjs → index-OE2INULi.cjs} +1 -1
  61. package/lib/{index-LReFyN6i.js → index-e9eDuagL.js} +1 -1
  62. package/lib/intersector/index.cjs +1 -1
  63. package/lib/intersector/index.js +2 -2
  64. package/lib/jsx/index.cjs +1 -1
  65. package/lib/jsx/index.js +6 -6
  66. package/lib/ladder/index.cjs +1 -1
  67. package/lib/ladder/index.js +2 -2
  68. package/lib/layout-box/index.cjs +1 -1
  69. package/lib/layout-box/index.js +2 -2
  70. package/lib/loading/index.cjs +1 -1
  71. package/lib/loading/index.js +1 -1
  72. package/lib/local-links/index.cjs +1 -1
  73. package/lib/local-links/index.js +1 -1
  74. package/lib/masonry-layout/index.cjs +1 -1
  75. package/lib/masonry-layout/index.js +2 -2
  76. package/lib/media/index.cjs +1 -1
  77. package/lib/media/index.js +2 -2
  78. package/lib/morph/index.cjs +1 -1
  79. package/lib/morph/index.js +294 -301
  80. package/lib/{morph-BQErz7qP.js → morph-D_ybmXWR.js} +8 -8
  81. package/lib/need_redo_tweaker/index.cjs +1 -1
  82. package/lib/need_redo_tweaker/index.js +3 -3
  83. package/lib/page-announcer/index.cjs +1 -1
  84. package/lib/page-announcer/index.js +1 -1
  85. package/lib/page-scroll/index.cjs +1 -1
  86. package/lib/page-scroll/index.js +1 -1
  87. package/lib/pixel-perfect/index.cjs +1 -1
  88. package/lib/pixel-perfect/index.js +3 -3
  89. package/lib/pointer/index.cjs +1 -1
  90. package/lib/pointer/index.js +4 -4
  91. package/lib/popover/index.cjs +1 -1
  92. package/lib/popover/index.js +3 -3
  93. package/lib/radio/index.cjs +1 -1
  94. package/lib/radio/index.js +1 -1
  95. package/lib/render-1u700s93.js +212 -0
  96. package/lib/render-BIOfUddT.cjs +1 -0
  97. package/lib/router/index.cjs +1 -1
  98. package/lib/router/index.js +6 -6
  99. package/lib/scroll/index.cjs +1 -1
  100. package/lib/scroll/index.js +8 -8
  101. package/lib/{scroll-DxcPU0vk.cjs → scroll-BA2WnUrb.cjs} +1 -1
  102. package/lib/{scroll-jcbHDexr.js → scroll-DY5senkF.js} +2 -2
  103. package/lib/scroll-entries/index.cjs +1 -1
  104. package/lib/scroll-entries/index.js +1 -1
  105. package/lib/scroll-kit/index.cjs +1 -1
  106. package/lib/scroll-kit/index.js +4 -4
  107. package/lib/sequence/index.cjs +1 -1
  108. package/lib/sequence/index.js +3 -3
  109. package/lib/size-element/index.cjs +1 -1
  110. package/lib/size-element/index.js +1 -1
  111. package/lib/slicer/index.cjs +1 -1
  112. package/lib/slicer/index.js +1 -1
  113. package/lib/source/index.cjs +1 -1
  114. package/lib/source/index.js +1 -1
  115. package/lib/spa/index.cjs +1 -1
  116. package/lib/spa/index.js +6 -6
  117. package/lib/store/index.cjs +1 -1
  118. package/lib/store/index.js +3 -3
  119. package/lib/{stylesheet-BcwbfhBp.cjs → stylesheet-5_o7PFzM.cjs} +1 -1
  120. package/lib/{stylesheet-DbHOxtjw.js → stylesheet-DdBzowZY.js} +1 -1
  121. package/lib/ticker/index.cjs +1 -1
  122. package/lib/ticker/index.js +2 -2
  123. package/lib/url-CHgcNwJ1.cjs +1 -0
  124. package/lib/url-CYgo5vrG.js +113 -0
  125. package/lib/utils/dom.d.ts +3 -0
  126. package/lib/utils/index.cjs +1 -1
  127. package/lib/utils/index.js +142 -137
  128. package/lib/utils/url.d.ts +6 -0
  129. package/lib/video/index.cjs +1 -1
  130. package/lib/video/index.js +3 -3
  131. package/lib/window-resizer/index.cjs +1 -1
  132. package/lib/window-resizer/index.js +1 -1
  133. package/lib/youtube/index.cjs +1 -1
  134. package/lib/youtube/index.js +3 -3
  135. package/package.json +13 -5
  136. package/lib/dom-BIeVMHfK.js +0 -57
  137. package/lib/dom-hTEdqeoj.cjs +0 -1
  138. package/lib/render-B3Hf-O7M.js +0 -205
  139. package/lib/render-BWjKu0M_.cjs +0 -1
  140. package/lib/url-CPgw9bd5.cjs +0 -1
  141. package/lib/url-DAl-mgbC.js +0 -97
@@ -1 +1 @@
1
- "use strict";var v=s=>{throw TypeError(s)};var E=(s,r,t)=>r.has(s)||v("Cannot "+t);var e=(s,r,t)=>(E(s,r,"read from private field"),t?t.call(s):r.get(s)),o=(s,r,t)=>r.has(s)?v("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(s):r.set(s,t),u=(s,r,t,a)=>(E(s,r,"write to private field"),a?a.call(s,t):r.set(s,t),t),w=(s,r,t)=>(E(s,r,"access private method"),t);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const A=require("../SourceElement-TzgPNQOd.cjs");require("../window-resizer/index.cjs");require("../Store-1JrMCgdX.cjs");const L=require("../index-CKTweR3M.cjs"),T=require("../events-KVanG9sR.cjs"),_=require("../string-DUXXtU8v.cjs");require("construct-style-sheets-polyfill");var i,c,n,y,l,f,b,R,p,I;const d=class d extends A.SourceElement{constructor(){super();o(this,p);o(this,i);o(this,c);o(this,n,!1);o(this,y,!1);o(this,l,()=>{u(this,n,e(this,n)||this.hasAttribute("autoplay")&&!this.hasAttribute("capture-autoplay")),u(this,i,new window.YT.Player(e(this,c),{playerVars:{mute:this.hasAttribute("muted")?1:0,controls:this.hasAttribute("controls")?1:0},events:{onReady:e(this,f),onError:e(this,b),onStateChange:e(this,R)}}))});o(this,f,()=>{u(this,y,!0),w(this,p,I).call(this)});o(this,b,t=>{var a,h;console.error("YouTube: Ошибка при загрузке видео:",this.currentURL,t),(h=(a=this.consumerElement).onerror)==null||h.call(a,new Event("error"))});o(this,R,()=>{});u(this,c,"yt-"+_.generateId(10)),d.__apiReady||(window.onYouTubeIframeAPIReady=()=>{d.__apiReady=!0,T.dispatchEvent(window,"youTubeIframeAPIReady")}),this.addEventListener("sourceCapture",()=>{this.hasAttribute("capture-autoplay")&&(e(this,y)?e(this,i).playVideo():u(this,n,!0))}),this.addEventListener("sourceRelease",()=>{e(this,i)&&this.hasAttribute("capture-autoplay")&&(e(this,i).pauseVideo(),this.hasAttribute("replay")&&e(this,i).seekTo(0))})}static __onYouTubeIframeAPIReady(){this.__apiReady=!0}createConsumer(){const t=document.createElement("div");return t.id=e(this,c),t}consumeSource(t){var a;if(t){if(!document.getElementById("youtube-script")){const h=document.createElement("script");h.id,h.src="https://www.youtube.com/iframe_api";const g=document.getElementsByTagName("script")[0];(a=g.parentNode)==null||a.insertBefore(h,g)}e(this,i)?w(this,p,I).call(this):d.__apiReady?e(this,l).call(this):addEventListener("youTubeIframeAPIReady",e(this,l))}else e(this,i)&&e(this,i).stopVideo()}disconnectedCallback(){super.disconnectedCallback(),e(this,i)&&e(this,i).destroy(),removeEventListener("youTubeIframeAPIReady",e(this,l))}};i=new WeakMap,c=new WeakMap,n=new WeakMap,y=new WeakMap,l=new WeakMap,f=new WeakMap,b=new WeakMap,R=new WeakMap,p=new WeakSet,I=function(){var t,a;this.currentURL&&(this.currentURL.startsWith("http")?e(this,i).loadVideoByUrl(this.currentURL):e(this,i).loadVideoById(this.currentURL)),e(this,n)?e(this,i).playVideo():e(this,i).stopVideo(),u(this,n,!1),(a=(t=this.consumerElement).onload)==null||a.call(t,new Event("load"))},d.__apiReady=!1;let m=d;L.isBrowser&&!customElements.get("e-youtube")&&customElements.define("e-youtube",m);exports.YouTubeElement=m;
1
+ "use strict";var v=s=>{throw TypeError(s)};var E=(s,r,t)=>r.has(s)||v("Cannot "+t);var e=(s,r,t)=>(E(s,r,"read from private field"),t?t.call(s):r.get(s)),o=(s,r,t)=>r.has(s)?v("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(s):r.set(s,t),u=(s,r,t,a)=>(E(s,r,"write to private field"),a?a.call(s,t):r.set(s,t),t),w=(s,r,t)=>(E(s,r,"access private method"),t);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const A=require("../SourceElement-BHqPFbna.cjs");require("../window-resizer/index.cjs");require("../Store-Blf4msDz.cjs");const L=require("../index-OE2INULi.cjs"),T=require("../events-KVanG9sR.cjs"),_=require("../string-DUXXtU8v.cjs");require("construct-style-sheets-polyfill");var i,c,n,y,l,f,b,R,p,I;const d=class d extends A.SourceElement{constructor(){super();o(this,p);o(this,i);o(this,c);o(this,n,!1);o(this,y,!1);o(this,l,()=>{u(this,n,e(this,n)||this.hasAttribute("autoplay")&&!this.hasAttribute("capture-autoplay")),u(this,i,new window.YT.Player(e(this,c),{playerVars:{mute:this.hasAttribute("muted")?1:0,controls:this.hasAttribute("controls")?1:0},events:{onReady:e(this,f),onError:e(this,b),onStateChange:e(this,R)}}))});o(this,f,()=>{u(this,y,!0),w(this,p,I).call(this)});o(this,b,t=>{var a,h;console.error("YouTube: Ошибка при загрузке видео:",this.currentURL,t),(h=(a=this.consumerElement).onerror)==null||h.call(a,new Event("error"))});o(this,R,()=>{});u(this,c,"yt-"+_.generateId(10)),d.__apiReady||(window.onYouTubeIframeAPIReady=()=>{d.__apiReady=!0,T.dispatchEvent(window,"youTubeIframeAPIReady")}),this.addEventListener("sourceCapture",()=>{this.hasAttribute("capture-autoplay")&&(e(this,y)?e(this,i).playVideo():u(this,n,!0))}),this.addEventListener("sourceRelease",()=>{e(this,i)&&this.hasAttribute("capture-autoplay")&&(e(this,i).pauseVideo(),this.hasAttribute("replay")&&e(this,i).seekTo(0))})}static __onYouTubeIframeAPIReady(){this.__apiReady=!0}createConsumer(){const t=document.createElement("div");return t.id=e(this,c),t}consumeSource(t){var a;if(t){if(!document.getElementById("youtube-script")){const h=document.createElement("script");h.id,h.src="https://www.youtube.com/iframe_api";const g=document.getElementsByTagName("script")[0];(a=g.parentNode)==null||a.insertBefore(h,g)}e(this,i)?w(this,p,I).call(this):d.__apiReady?e(this,l).call(this):addEventListener("youTubeIframeAPIReady",e(this,l))}else e(this,i)&&e(this,i).stopVideo()}disconnectedCallback(){super.disconnectedCallback(),e(this,i)&&e(this,i).destroy(),removeEventListener("youTubeIframeAPIReady",e(this,l))}};i=new WeakMap,c=new WeakMap,n=new WeakMap,y=new WeakMap,l=new WeakMap,f=new WeakMap,b=new WeakMap,R=new WeakMap,p=new WeakSet,I=function(){var t,a;this.currentURL&&(this.currentURL.startsWith("http")?e(this,i).loadVideoByUrl(this.currentURL):e(this,i).loadVideoById(this.currentURL)),e(this,n)?e(this,i).playVideo():e(this,i).stopVideo(),u(this,n,!1),(a=(t=this.consumerElement).onload)==null||a.call(t,new Event("load"))},d.__apiReady=!1;let m=d;L.isBrowser&&!customElements.get("e-youtube")&&customElements.define("e-youtube",m);exports.YouTubeElement=m;
@@ -3,10 +3,10 @@ var L = (s) => {
3
3
  };
4
4
  var b = (s, r, t) => r.has(s) || L("Cannot " + t);
5
5
  var e = (s, r, t) => (b(s, r, "read from private field"), t ? t.call(s) : r.get(s)), o = (s, r, t) => r.has(s) ? L("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(s) : r.set(s, t), u = (s, r, t, a) => (b(s, r, "write to private field"), a ? a.call(s, t) : r.set(s, t), t), E = (s, r, t) => (b(s, r, "access private method"), t);
6
- import { a as g } from "../SourceElement-BQ7g2KWK.js";
6
+ import { a as g } from "../SourceElement-DjbHjynf.js";
7
7
  import "../window-resizer/index.js";
8
- import "../Store-CgQ3ReoB.js";
9
- import { i as v } from "../index-LReFyN6i.js";
8
+ import "../Store-ZThXYBQd.js";
9
+ import { i as v } from "../index-e9eDuagL.js";
10
10
  import { d as T } from "../events-CsVF98U6.js";
11
11
  import { g as V } from "../string-BlMQbe8b.js";
12
12
  import "construct-style-sheets-polyfill";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aptechka",
3
- "version": "0.82.5",
3
+ "version": "0.83.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/denisavitski/aptechka.git"
@@ -28,6 +28,11 @@
28
28
  "require": "./lib/animation/index.cjs",
29
29
  "default": "./lib/animation/index.js"
30
30
  },
31
+ "./api-fetcher": {
32
+ "types": "./lib/api-fetcher/index.d.ts",
33
+ "require": "./lib/api-fetcher/index.cjs",
34
+ "default": "./lib/api-fetcher/index.js"
35
+ },
31
36
  "./attribute": {
32
37
  "types": "./lib/attribute/index.d.ts",
33
38
  "require": "./lib/attribute/index.cjs",
@@ -287,6 +292,9 @@
287
292
  "animation": [
288
293
  "lib/animation/index.d.ts"
289
294
  ],
295
+ "api-fetcher": [
296
+ "lib/api-fetcher/index.d.ts"
297
+ ],
290
298
  "attribute": [
291
299
  "lib/attribute/index.d.ts"
292
300
  ],
@@ -449,12 +457,12 @@
449
457
  "dev": "vite --host --mode site"
450
458
  },
451
459
  "devDependencies": {
452
- "@types/node": "^24.1.0",
460
+ "@types/node": "^24.3.0",
453
461
  "@types/three": "^0.179.0",
454
- "tsx": "^4.20.3",
455
- "vite": "^7.0.6",
462
+ "tsx": "^4.20.5",
463
+ "vite": "^7.1.3",
456
464
  "vite-plugin-dts": "^4.5.4",
457
- "vite-plugin-htmc": "0.1.16",
465
+ "vite-plugin-htmc": "0.1.17",
458
466
  "prettier-plugin-organize-imports": "^4.2.0",
459
467
  "csstype": "^3.1.3"
460
468
  },
@@ -1,57 +0,0 @@
1
- function u(e, t) {
2
- if (!e)
3
- return null;
4
- let n = e.parentElement;
5
- return e.parentElement instanceof t || (n = u(e.parentElement, t)), n;
6
- }
7
- function l(e, t = document) {
8
- return typeof e == "string" ? t.querySelector(e) : e;
9
- }
10
- function f(e, t = null) {
11
- if (t = t || e, !e || !(e instanceof HTMLElement))
12
- return document.body;
13
- if (t !== e) {
14
- const n = getComputedStyle(e);
15
- if (n.overflow.includes("auto") || n.overflow.includes("scroll"))
16
- return e;
17
- }
18
- return f(e.parentNode, t);
19
- }
20
- function i(e) {
21
- let t = [];
22
- return document.documentElement.addEventListener(
23
- "__illuminate-tree",
24
- (n) => {
25
- n.composedPath().forEach((r) => {
26
- r instanceof HTMLElement && t.push(r);
27
- });
28
- },
29
- { once: !0 }
30
- ), e.dispatchEvent(
31
- new CustomEvent("__illuminate-tree", {
32
- bubbles: !0,
33
- composed: !0
34
- })
35
- ), t;
36
- }
37
- function a(e, t) {
38
- t(e), e.childNodes.forEach((n) => {
39
- a(n, t);
40
- });
41
- }
42
- function c(e, t, n = !0) {
43
- e.shadowRoot && (t(e), n && o(e.shadowRoot, t, n)), o(e, t, n);
44
- }
45
- function o(e, t, n) {
46
- const s = e.children || (e instanceof ShadowRoot ? e.children : []);
47
- for (const r of Array.from(s))
48
- c(r, t, n);
49
- }
50
- export {
51
- i as a,
52
- u as b,
53
- c,
54
- f,
55
- l as g,
56
- a as t
57
- };
@@ -1 +0,0 @@
1
- "use strict";function u(e,t){if(!e)return null;let n=e.parentElement;return e.parentElement instanceof t||(n=u(e.parentElement,t)),n}function c(e,t=document){return typeof e=="string"?t.querySelector(e):e}function l(e,t=null){if(t=t||e,!e||!(e instanceof HTMLElement))return document.body;if(t!==e){const n=getComputedStyle(e);if(n.overflow.includes("auto")||n.overflow.includes("scroll"))return e}return l(e.parentNode,t)}function i(e){let t=[];return document.documentElement.addEventListener("__illuminate-tree",n=>{n.composedPath().forEach(r=>{r instanceof HTMLElement&&t.push(r)})},{once:!0}),e.dispatchEvent(new CustomEvent("__illuminate-tree",{bubbles:!0,composed:!0})),t}function f(e,t){t(e),e.childNodes.forEach(n=>{f(n,t)})}function a(e,t,n=!0){e.shadowRoot&&(t(e),n&&s(e.shadowRoot,t,n)),s(e,t,n)}function s(e,t,n){const o=e.children||(e instanceof ShadowRoot?e.children:[]);for(const r of Array.from(o))a(r,t,n)}exports.findParentElement=u;exports.findScrollParentElement=l;exports.getAllParentElements=i;exports.getElement=c;exports.traverseNodes=f;exports.traverseShadowRoots=a;
@@ -1,205 +0,0 @@
1
- var O = Object.defineProperty, R = Object.defineProperties;
2
- var q = Object.getOwnPropertyDescriptors;
3
- var _ = Object.getOwnPropertySymbols;
4
- var B = Object.prototype.hasOwnProperty, H = Object.prototype.propertyIsEnumerable;
5
- var L = (r) => {
6
- throw TypeError(r);
7
- };
8
- var w = (r, s, t) => s in r ? O(r, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[s] = t, y = (r, s) => {
9
- for (var t in s || (s = {}))
10
- B.call(s, t) && w(r, t, s[t]);
11
- if (_)
12
- for (var t of _(s))
13
- H.call(s, t) && w(r, t, s[t]);
14
- return r;
15
- }, N = (r, s) => R(r, q(s));
16
- var D = (r, s, t) => s.has(r) || L("Cannot " + t);
17
- var u = (r, s, t) => (D(r, s, "read from private field"), t ? t.call(r) : s.get(r)), m = (r, s, t) => s.has(r) ? L("Cannot add the same private member more than once") : s instanceof WeakSet ? s.add(r) : s.set(r, t), C = (r, s, t, o) => (D(r, s, "write to private field"), o ? o.call(r, t) : s.set(r, t), t);
18
- import { S as l } from "./Store-CgQ3ReoB.js";
19
- import { c as K } from "./string-BlMQbe8b.js";
20
- import "construct-style-sheets-polyfill";
21
- import "./index-LReFyN6i.js";
22
- import { connector as M } from "./connector/index.js";
23
- import { a as P } from "./DerivedArray-DG9iR0mf.js";
24
- const J = { current: null };
25
- var b, p;
26
- class X extends HTMLElement {
27
- constructor() {
28
- super();
29
- m(this, b, []);
30
- m(this, p, []);
31
- J.current = this;
32
- }
33
- addConnectCallback(t) {
34
- u(this, b).push(t);
35
- }
36
- addDisconnectCallback(t) {
37
- u(this, p).push(t);
38
- }
39
- connectedCallback() {
40
- u(this, b).forEach((t) => {
41
- const o = t(this);
42
- o && u(this, p).push(o);
43
- });
44
- }
45
- disconnectedCallback() {
46
- u(this, p).forEach((t) => {
47
- t(this);
48
- }), C(this, b, []), C(this, p, []);
49
- }
50
- }
51
- b = new WeakMap(), p = new WeakMap();
52
- function E(r, s, t) {
53
- const o = s.subscribe((c) => {
54
- t(c);
55
- });
56
- M.subscribe(r, {
57
- disconnectCallback: () => {
58
- o();
59
- },
60
- maxWaitSec: 20,
61
- unsubscribeAfterDisconnect: !0
62
- });
63
- }
64
- function W(r, s) {
65
- s && (s instanceof l ? E(r, s, (t) => {
66
- t.previous && r.classList.remove(t.previous.toString()), t.current && r.classList.add(t.current.toString());
67
- }) : typeof s == "object" && !Array.isArray(s) ? Object.entries(s).forEach(([t, o]) => {
68
- o instanceof l ? E(r, o, (c) => {
69
- r.classList.toggle(t, !!c.current);
70
- }) : o && r.classList.add(t);
71
- }) : Array.isArray(s) ? s.forEach((t) => {
72
- typeof t == "string" ? r.classList.add(t) : W(r, t);
73
- }) : s.toString().split(" ").map((t) => r.classList.add(t.trim())));
74
- }
75
- function $(r, s) {
76
- s && (typeof s == "object" ? Object.entries(s).forEach(([t, o]) => {
77
- o instanceof l ? E(r, o, (c) => {
78
- var n;
79
- r.style[t] = (n = c.current) == null ? void 0 : n.toString();
80
- }) : (typeof o == "number" || typeof o == "string" || typeof o == "boolean") && (r.style[t] = o.toString());
81
- }) : typeof s == "string" && (r.style = s));
82
- }
83
- function A(r, s, t) {
84
- s === "ref" && t ? Array.isArray(t) ? t.forEach((o) => {
85
- typeof o == "object" && "value" in o && (o.value = r);
86
- }) : typeof t == "object" && "value" in t && (t.value = r) : s === "className" || s === "class" ? W(r, t) : s === "style" ? $(r, t) : typeof t == "number" ? s === "tabIndex" ? r.setAttribute("tabindex", t.toString()) : A(r, s, t.toString()) : typeof t == "string" ? s === "htmlFor" ? r.setAttribute("for", t) : r.setAttribute(s, t) : typeof t == "boolean" ? t ? r.setAttribute(s, "") : r.removeAttribute(s) : t instanceof l && E(r, t, (o) => {
87
- s in r ? r[s] = o.current : A(r, s, o.current);
88
- });
89
- }
90
- function z(r, s) {
91
- for (const [t, o] of Object.entries(s != null ? s : {}))
92
- typeof o == "function" && t.startsWith("on") ? r.addEventListener(
93
- t.replace("on", "").toLowerCase(),
94
- o
95
- ) : A(r, t, o);
96
- }
97
- function I(r) {
98
- const s = [];
99
- return r.forEach((t) => {
100
- t != null && (typeof t == "number" ? s.push(t.toString()) : Array.isArray(t) ? t.forEach((o) => {
101
- s.push(...I(o));
102
- }) : s.push(t));
103
- }), s;
104
- }
105
- function Q(r, s) {
106
- const t = [...r.childNodes].filter((e) => e.__storeId === s.id), o = s.current, c = Array.isArray(o) ? o : [o], n = [];
107
- if (c.forEach((e) => {
108
- let i = null;
109
- typeof e == "boolean" || typeof e == "number" || typeof e == "string" ? i = document.createTextNode(e.toString()) : e instanceof Node && (i = e), i && (i.__storeId = s.id, n.push(i));
110
- }), s instanceof P) {
111
- const e = [];
112
- n.forEach((i, f) => {
113
- const a = t.find(
114
- (h) => h.__key === i.__key
115
- );
116
- a ? a.isEqualNode(i) ? e.push(a) : (a.replaceWith(i), e.push(i)) : (e.push(i), r.appendChild(i));
117
- }), t.forEach((i) => {
118
- e.includes(i) || i.remove();
119
- });
120
- } else
121
- n.forEach((e, i) => {
122
- var a;
123
- const f = t[i];
124
- if (f)
125
- f.isEqualNode(e) || (f.replaceWith(e), t[i] = e);
126
- else {
127
- const h = t[t.length - 1];
128
- h ? (a = h.parentNode) == null || a.insertBefore(
129
- e,
130
- h.nextSibling
131
- ) : r.appendChild(e);
132
- }
133
- }), t.slice(n.length).forEach((e) => {
134
- e.remove();
135
- });
136
- }
137
- class g {
138
- constructor(s, t, o) {
139
- this.tag = s, this.attributes = t, this.children = o;
140
- }
141
- }
142
- class S {
143
- constructor(s, t, o) {
144
- this.tag = s, this.attributes = t, this.children = o;
145
- }
146
- }
147
- function d(r, s, t, o = !1) {
148
- const c = I(t);
149
- z(r, s), c.forEach((n) => {
150
- if (n instanceof l)
151
- E(r, n, () => {
152
- Q(r, n);
153
- });
154
- else if (n instanceof g)
155
- n.tag === "shadow" && r.shadowRoot ? d(
156
- r.shadowRoot,
157
- n.attributes,
158
- n.children
159
- ) : d(r, n.attributes, n.children);
160
- else if (n instanceof S) {
161
- let e = null;
162
- n.tag === "svg" ? (e = document.createElementNS(
163
- "http://www.w3.org/2000/svg",
164
- "svg"
165
- ), d(e, n.attributes, n.children, !0)) : e = o ? document.createElementNS("http://www.w3.org/2000/svg", n.tag) : document.createElement(n.tag), d(e, n.attributes, n.children, o), r.append(e);
166
- } else
167
- r.append(n);
168
- });
169
- }
170
- function U(r, s, ...t) {
171
- var o;
172
- if (typeof r == "string")
173
- return r === "component" ? new g(r, s, t) : r === "shadow" ? new g(r, s, t) : new S(r, s, t);
174
- {
175
- if (r === F)
176
- return F(t);
177
- if (r.template)
178
- return r(y({}, s));
179
- const c = `e-${K(r.name)}`;
180
- let n = customElements.get(c);
181
- n || (n = (o = class extends X {
182
- constructor() {
183
- super();
184
- }
185
- }, o.formAssociated = r.formAssociated, o), customElements.define(c, n));
186
- const e = new n(), i = N(y({}, s), {
187
- children: t
188
- }), f = r(i);
189
- return __JSX_HMR_DEV__ && (e.__props__ = i), (f instanceof g || f instanceof S) && (f != null && f.children || f.attributes) && d(e, f.attributes, f.children), e;
190
- }
191
- }
192
- function F(r) {
193
- const s = document.createDocumentFragment();
194
- return d(s, void 0, r), s;
195
- }
196
- function T(r, s, t) {
197
- const o = /* @__PURE__ */ U(s, y({}, t));
198
- return r.append(o), o;
199
- }
200
- export {
201
- F,
202
- J as a,
203
- U as h,
204
- T as r
205
- };
@@ -1 +0,0 @@
1
- "use strict";var R=Object.defineProperty,B=Object.defineProperties;var H=Object.getOwnPropertyDescriptors;var w=Object.getOwnPropertySymbols;var K=Object.prototype.hasOwnProperty,M=Object.prototype.propertyIsEnumerable;var q=r=>{throw TypeError(r)};var L=(r,e,t)=>e in r?R(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,y=(r,e)=>{for(var t in e||(e={}))K.call(e,t)&&L(r,t,e[t]);if(w)for(var t of w(e))M.call(e,t)&&L(r,t,e[t]);return r},N=(r,e)=>B(r,H(e));var D=(r,e,t)=>e.has(r)||q("Cannot "+t);var p=(r,e,t)=>(D(r,e,"read from private field"),t?t.call(r):e.get(r)),S=(r,e,t)=>e.has(r)?q("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(r):e.set(r,t),C=(r,e,t,s)=>(D(r,e,"write to private field"),s?s.call(r,t):e.set(r,t),t);const l=require("./Store-1JrMCgdX.cjs"),P=require("./string-DUXXtU8v.cjs");require("construct-style-sheets-polyfill");require("./index-CKTweR3M.cjs");const J=require("./connector/index.cjs"),X=require("./DerivedArray-B8A0-8uT.cjs"),F={current:null};var b,u;class $ extends HTMLElement{constructor(){super();S(this,b,[]);S(this,u,[]);F.current=this}addConnectCallback(t){p(this,b).push(t)}addDisconnectCallback(t){p(this,u).push(t)}connectedCallback(){p(this,b).forEach(t=>{const s=t(this);s&&p(this,u).push(s)})}disconnectedCallback(){p(this,u).forEach(t=>{t(this)}),C(this,b,[]),C(this,u,[])}}b=new WeakMap,u=new WeakMap;function g(r,e,t){const s=e.subscribe(f=>{t(f)});J.connector.subscribe(r,{disconnectCallback:()=>{s()},maxWaitSec:20,unsubscribeAfterDisconnect:!0})}function W(r,e){e&&(e instanceof l.Store?g(r,e,t=>{t.previous&&r.classList.remove(t.previous.toString()),t.current&&r.classList.add(t.current.toString())}):typeof e=="object"&&!Array.isArray(e)?Object.entries(e).forEach(([t,s])=>{s instanceof l.Store?g(r,s,f=>{r.classList.toggle(t,!!f.current)}):s&&r.classList.add(t)}):Array.isArray(e)?e.forEach(t=>{typeof t=="string"?r.classList.add(t):W(r,t)}):e.toString().split(" ").map(t=>r.classList.add(t.trim())))}function z(r,e){e&&(typeof e=="object"?Object.entries(e).forEach(([t,s])=>{s instanceof l.Store?g(r,s,f=>{var o;r.style[t]=(o=f.current)==null?void 0:o.toString()}):(typeof s=="number"||typeof s=="string"||typeof s=="boolean")&&(r.style[t]=s.toString())}):typeof e=="string"&&(r.style=e))}function A(r,e,t){e==="ref"&&t?Array.isArray(t)?t.forEach(s=>{typeof s=="object"&&"value"in s&&(s.value=r)}):typeof t=="object"&&"value"in t&&(t.value=r):e==="className"||e==="class"?W(r,t):e==="style"?z(r,t):typeof t=="number"?e==="tabIndex"?r.setAttribute("tabindex",t.toString()):A(r,e,t.toString()):typeof t=="string"?e==="htmlFor"?r.setAttribute("for",t):r.setAttribute(e,t):typeof t=="boolean"?t?r.setAttribute(e,""):r.removeAttribute(e):t instanceof l.Store&&g(r,t,s=>{e in r?r[e]=s.current:A(r,e,s.current)})}function Q(r,e){for(const[t,s]of Object.entries(e!=null?e:{}))typeof s=="function"&&t.startsWith("on")?r.addEventListener(t.replace("on","").toLowerCase(),s):A(r,t,s)}function I(r){const e=[];return r.forEach(t=>{t!=null&&(typeof t=="number"?e.push(t.toString()):Array.isArray(t)?t.forEach(s=>{e.push(...I(s))}):e.push(t))}),e}function U(r,e){const t=[...r.childNodes].filter(n=>n.__storeId===e.id),s=e.current,f=Array.isArray(s)?s:[s],o=[];if(f.forEach(n=>{let i=null;typeof n=="boolean"||typeof n=="number"||typeof n=="string"?i=document.createTextNode(n.toString()):n instanceof Node&&(i=n),i&&(i.__storeId=e.id,o.push(i))}),e instanceof X.DerivedKeyedArray){const n=[];o.forEach((i,c)=>{const a=t.find(h=>h.__key===i.__key);a?a.isEqualNode(i)?n.push(a):(a.replaceWith(i),n.push(i)):(n.push(i),r.appendChild(i))}),t.forEach(i=>{n.includes(i)||i.remove()})}else o.forEach((n,i)=>{var a;const c=t[i];if(c)c.isEqualNode(n)||(c.replaceWith(n),t[i]=n);else{const h=t[t.length-1];h?(a=h.parentNode)==null||a.insertBefore(n,h.nextSibling):r.appendChild(n)}}),t.slice(o.length).forEach(n=>{n.remove()})}class E{constructor(e,t,s){this.tag=e,this.attributes=t,this.children=s}}class _{constructor(e,t,s){this.tag=e,this.attributes=t,this.children=s}}function d(r,e,t,s=!1){const f=I(t);Q(r,e),f.forEach(o=>{if(o instanceof l.Store)g(r,o,()=>{U(r,o)});else if(o instanceof E)o.tag==="shadow"&&r.shadowRoot?d(r.shadowRoot,o.attributes,o.children):d(r,o.attributes,o.children);else if(o instanceof _){let n=null;o.tag==="svg"?(n=document.createElementNS("http://www.w3.org/2000/svg","svg"),d(n,o.attributes,o.children,!0)):n=s?document.createElementNS("http://www.w3.org/2000/svg",o.tag):document.createElement(o.tag),d(n,o.attributes,o.children,s),r.append(n)}else r.append(o)})}function O(r,e,...t){var s;if(typeof r=="string")return r==="component"?new E(r,e,t):r==="shadow"?new E(r,e,t):new _(r,e,t);{if(r===m)return m(t);if(r.template)return r(y({},e));const f=`e-${P.camelToKebab(r.name)}`;let o=customElements.get(f);o||(o=(s=class extends ${constructor(){super()}},s.formAssociated=r.formAssociated,s),customElements.define(f,o));const n=new o,i=N(y({},e),{children:t}),c=r(i);return __JSX_HMR_DEV__&&(n.__props__=i),(c instanceof E||c instanceof _)&&(c!=null&&c.children||c.attributes)&&d(n,c.attributes,c.children),n}}function m(r){const e=document.createDocumentFragment();return d(e,void 0,r),e}function V(r,e,t){const s=O(e,y({},t));return r.append(s),s}exports.Fragment=m;exports.activeComponent=F;exports.h=O;exports.render=V;
@@ -1 +0,0 @@
1
- "use strict";var y=Object.defineProperty,$=Object.defineProperties;var w=Object.getOwnPropertyDescriptors;var p=Object.getOwnPropertySymbols;var P=Object.prototype.hasOwnProperty,W=Object.prototype.propertyIsEnumerable;var m=(t,e,r)=>e in t?y(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,S=(t,e)=>{for(var r in e||(e={}))P.call(e,r)&&m(t,r,e[r]);if(p)for(var r of p(e))W.call(e,r)&&m(t,r,e[r]);return t},g=(t,e)=>$(t,w(e));function z(t,{base:e="",trailingSlash:r=!1,mergeParams:s,removeParams:n}={}){e=e.endsWith("/")?e.slice(0,-1):e,t=t.replace(e,""),t.startsWith("/")&&(t=t.slice(1));const i=t.split("#"),l=i[0].split("?");let a=l[0].startsWith("/")?l[0]:"/"+l[0];r?a=!a.endsWith("/")&&a!=="/"?a+"/":a:a=a.endsWith("/")&&a!=="/"?a.slice(0,-1):a;let c=l[1]||"";if(s){const o=new URLSearchParams(c),U=new URLSearchParams(s);for(const[h,d]of U)o.has(h)||o.set(h,d);n==null||n.split(",").forEach(h=>{o.has(h)&&o.delete(h)}),c=o.toString()}const u=e+a,f=i[1],R=`${u}${c?"?"+c:""}${f?"#"+f:""}`;return{leaf:a,pathname:u,parameters:c,hash:f,path:R}}function A(t="/"){return t.endsWith("/")||(t+="/"),t.startsWith("/")||(t+="/"),t}function E(t){if(t.action==="none")return;const e=t==null?void 0:t.searchParameters,r=t.hash?t.hash.startsWith("#")?t.hash:"#"+t.hash:"",s=e?e.startsWith("?")?e:"?"+e:"",n=`${t.pathname}${s}${r}`,i=g(S({},t.state),{path:n});t.action==="push"?history.pushState(i,"",n):t.action==="replace"&&history.replaceState(i,"",n)}function k(t){const e=new URLSearchParams(t),r={};for(const[s,n]of e)r[s]=n;return r}function q(t,e){const r=new URL(location.href),s=(e==null?void 0:e.toString())||"";r.searchParams.set(t,s),history.replaceState(history.state,"",r.href)}function L(t,e,r){t.setAttribute(e,new URL(t.getAttribute(e),r).pathname)}function B(t,e){t.querySelectorAll('[href^="./"], [href^="../"]').forEach(r=>L(r,"href",e)),t.querySelectorAll('[src^="./"], [src^="../"]').forEach(r=>L(r,"src",e))}function H(t,{base:e="",trailingSlash:r=!1}={}){e=e.replace(/^\/|\/$/g,"");const s=typeof t=="string"?t.replace(/^\/|\/$/g,""):t.pathname.replace(/^\/|\/$/g,"");let n="";return s.includes(e)?n=`/${s}`:n=`${e}/${s}`,r&&!n.endsWith("/")&&(n+="/"),new URL(n,location.origin)}function j(t){try{const e=new URL(t);if(window.location.origin===e.origin)return e.pathname===window.location.pathname?!e.hash:!0}catch(e){}return!1}exports.changeHistory=E;exports.isLocalUrl=j;exports.normalizeBase=A;exports.normalizeRelativeURLs=B;exports.normalizeURL=H;exports.parseSearchParameters=k;exports.splitPath=z;exports.updateSearchParameter=q;
@@ -1,97 +0,0 @@
1
- var L = Object.defineProperty, R = Object.defineProperties;
2
- var U = Object.getOwnPropertyDescriptors;
3
- var p = Object.getOwnPropertySymbols;
4
- var W = Object.prototype.hasOwnProperty, P = Object.prototype.propertyIsEnumerable;
5
- var g = (t, e, s) => e in t ? L(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s, S = (t, e) => {
6
- for (var s in e || (e = {}))
7
- W.call(e, s) && g(t, s, e[s]);
8
- if (p)
9
- for (var s of p(e))
10
- P.call(e, s) && g(t, s, e[s]);
11
- return t;
12
- }, $ = (t, e) => R(t, U(e));
13
- function E(t, {
14
- base: e = "",
15
- trailingSlash: s = !1,
16
- mergeParams: r,
17
- removeParams: n
18
- } = {}) {
19
- e = e.endsWith("/") ? e.slice(0, -1) : e, t = t.replace(e, ""), t.startsWith("/") && (t = t.slice(1));
20
- const i = t.split("#"), f = i[0].split("?");
21
- let a = f[0].startsWith("/") ? f[0] : "/" + f[0];
22
- s ? a = !a.endsWith("/") && a !== "/" ? a + "/" : a : a = a.endsWith("/") && a !== "/" ? a.slice(0, -1) : a;
23
- let c = f[1] || "";
24
- if (r) {
25
- const o = new URLSearchParams(c), w = new URLSearchParams(r);
26
- for (const [h, y] of w)
27
- o.has(h) || o.set(h, y);
28
- n == null || n.split(",").forEach((h) => {
29
- o.has(h) && o.delete(h);
30
- }), c = o.toString();
31
- }
32
- const u = e + a, l = i[1], m = `${u}${c ? "?" + c : ""}${l ? "#" + l : ""}`;
33
- return {
34
- leaf: a,
35
- pathname: u,
36
- parameters: c,
37
- hash: l,
38
- path: m
39
- };
40
- }
41
- function k(t = "/") {
42
- return t.endsWith("/") || (t += "/"), t.startsWith("/") || (t += "/"), t;
43
- }
44
- function q(t) {
45
- if (t.action === "none")
46
- return;
47
- const e = t == null ? void 0 : t.searchParameters, s = t.hash ? t.hash.startsWith("#") ? t.hash : "#" + t.hash : "", r = e ? e.startsWith("?") ? e : "?" + e : "", n = `${t.pathname}${r}${s}`, i = $(S({}, t.state), { path: n });
48
- t.action === "push" ? history.pushState(i, "", n) : t.action === "replace" && history.replaceState(i, "", n);
49
- }
50
- function x(t) {
51
- const e = new URLSearchParams(t), s = {};
52
- for (const [r, n] of e)
53
- s[r] = n;
54
- return s;
55
- }
56
- function j(t, e) {
57
- const s = new URL(location.href), r = (e == null ? void 0 : e.toString()) || "";
58
- s.searchParams.set(t, r), history.replaceState(history.state, "", s.href);
59
- }
60
- function d(t, e, s) {
61
- t.setAttribute(e, new URL(t.getAttribute(e), s).pathname);
62
- }
63
- function B(t, e) {
64
- t.querySelectorAll('[href^="./"], [href^="../"]').forEach(
65
- (s) => d(s, "href", e)
66
- ), t.querySelectorAll('[src^="./"], [src^="../"]').forEach(
67
- (s) => d(s, "src", e)
68
- );
69
- }
70
- function H(t, {
71
- base: e = "",
72
- trailingSlash: s = !1
73
- } = {}) {
74
- e = e.replace(/^\/|\/$/g, "");
75
- const r = typeof t == "string" ? t.replace(/^\/|\/$/g, "") : t.pathname.replace(/^\/|\/$/g, "");
76
- let n = "";
77
- return r.includes(e) ? n = `/${r}` : n = `${e}/${r}`, s && !n.endsWith("/") && (n += "/"), new URL(n, location.origin);
78
- }
79
- function O(t) {
80
- try {
81
- const e = new URL(t);
82
- if (window.location.origin === e.origin)
83
- return e.pathname === window.location.pathname ? !e.hash : !0;
84
- } catch (e) {
85
- }
86
- return !1;
87
- }
88
- export {
89
- k as a,
90
- B as b,
91
- q as c,
92
- O as i,
93
- H as n,
94
- x as p,
95
- E as s,
96
- j as u
97
- };