@vanelsas/baredom 2.8.0 → 3.0.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 (113) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/README.md +1 -1
  3. package/custom-elements.json +467 -0
  4. package/dist/baredom.d.ts +25 -0
  5. package/dist/base.js +541 -452
  6. package/dist/integrity.json +103 -97
  7. package/dist/x-alert.js +16 -17
  8. package/dist/x-avatar-group.js +9 -9
  9. package/dist/x-avatar.js +14 -15
  10. package/dist/x-badge.js +9 -9
  11. package/dist/x-bento-grid.js +5 -5
  12. package/dist/x-bento-item.js +4 -4
  13. package/dist/x-breadcrumbs.js +13 -13
  14. package/dist/x-button.js +1 -16
  15. package/dist/x-cancel-dialogue.js +13 -13
  16. package/dist/x-card.js +7 -7
  17. package/dist/x-carousel.js +31 -31
  18. package/dist/x-chart.js +47 -47
  19. package/dist/x-checkbox.js +1 -11
  20. package/dist/x-chip.js +1 -1
  21. package/dist/x-collapse.js +10 -10
  22. package/dist/x-color-picker.js +45 -44
  23. package/dist/x-combobox.js +26 -26
  24. package/dist/x-command-palette.js +24 -24
  25. package/dist/x-confetti.d.ts +50 -0
  26. package/dist/x-confetti.js +25 -0
  27. package/dist/x-container.js +5 -4
  28. package/dist/x-context-menu.js +20 -20
  29. package/dist/x-copy.js +20 -20
  30. package/dist/x-currency-field.js +23 -23
  31. package/dist/x-date-picker.js +40 -40
  32. package/dist/x-divider.js +9 -9
  33. package/dist/x-drawer.js +9 -9
  34. package/dist/x-dropdown.js +11 -11
  35. package/dist/x-fieldset.js +5 -5
  36. package/dist/x-file-download.js +7 -7
  37. package/dist/x-file-upload.js +22 -22
  38. package/dist/x-form-field.js +15 -15
  39. package/dist/x-form.js +9 -9
  40. package/dist/x-gaussian-blur.js +12 -12
  41. package/dist/x-grid.js +7 -6
  42. package/dist/x-i18n-provider.js +7 -7
  43. package/dist/x-i18n.js +4 -4
  44. package/dist/x-icon.js +6 -6
  45. package/dist/x-image.js +16 -17
  46. package/dist/x-kbd.d.ts +17 -0
  47. package/dist/x-kbd.js +17 -0
  48. package/dist/x-kinetic-canvas.js +25 -25
  49. package/dist/x-kinetic-font.js +27 -27
  50. package/dist/x-kinetic-typography.js +33 -33
  51. package/dist/x-liquid-dock.js +38 -39
  52. package/dist/x-liquid-fill.js +44 -44
  53. package/dist/x-liquid-glass.js +47 -47
  54. package/dist/x-menu-item.js +8 -8
  55. package/dist/x-menu.js +10 -9
  56. package/dist/x-metaball-cursor.js +26 -27
  57. package/dist/x-modal.js +10 -10
  58. package/dist/x-morph-stack.js +36 -37
  59. package/dist/x-multi-combobox.js +36 -36
  60. package/dist/x-navbar.js +12 -12
  61. package/dist/x-neural-glow.js +32 -32
  62. package/dist/x-notification-center.js +9 -9
  63. package/dist/x-organic-divider.js +17 -17
  64. package/dist/x-organic-progress.js +37 -37
  65. package/dist/x-organic-shape.js +13 -13
  66. package/dist/x-otp-input.d.ts +55 -0
  67. package/dist/x-otp-input.js +23 -0
  68. package/dist/x-pagination.js +15 -15
  69. package/dist/x-particle-button.js +51 -51
  70. package/dist/x-popover.js +25 -26
  71. package/dist/x-progress-circle.js +8 -8
  72. package/dist/x-progress.js +10 -10
  73. package/dist/x-proximity-list.d.ts +43 -0
  74. package/dist/x-proximity-list.js +21 -0
  75. package/dist/x-radio.js +11 -11
  76. package/dist/x-ripple-effect.js +10 -10
  77. package/dist/x-scroll-parallax.js +18 -18
  78. package/dist/x-scroll-stack.js +17 -17
  79. package/dist/x-scroll-story.js +34 -34
  80. package/dist/x-scroll-timeline.js +45 -45
  81. package/dist/x-scroll.js +38 -38
  82. package/dist/x-search-field.js +1 -15
  83. package/dist/x-select.js +1 -11
  84. package/dist/x-sidebar.js +15 -15
  85. package/dist/x-skeleton-group.js +12 -12
  86. package/dist/x-skeleton.js +1 -1
  87. package/dist/x-slider.js +15 -15
  88. package/dist/x-soft-body.js +22 -22
  89. package/dist/x-spacer.js +4 -4
  90. package/dist/x-spinner.js +4 -4
  91. package/dist/x-splash.js +12 -12
  92. package/dist/x-spotlight-card.d.ts +19 -0
  93. package/dist/x-spotlight-card.js +13 -0
  94. package/dist/x-stat.js +10 -10
  95. package/dist/x-stepper.js +14 -14
  96. package/dist/x-switch.js +10 -10
  97. package/dist/x-tab.js +7 -7
  98. package/dist/x-table-cell.js +18 -18
  99. package/dist/x-table-row.js +8 -8
  100. package/dist/x-table.js +12 -12
  101. package/dist/x-tabs.js +11 -11
  102. package/dist/x-text-area.js +19 -19
  103. package/dist/x-theme.js +25 -25
  104. package/dist/x-timeline-item.js +20 -21
  105. package/dist/x-timeline.js +8 -8
  106. package/dist/x-toast.js +21 -22
  107. package/dist/x-toaster.js +8 -8
  108. package/dist/x-tooltip.js +12 -12
  109. package/dist/x-trace-history.d.ts +242 -0
  110. package/dist/x-trace-history.js +118 -0
  111. package/dist/x-typography.js +9 -9
  112. package/dist/x-welcome-tour.js +60 -59
  113. package/package.json +32 -2
package/dist/x-menu.js CHANGED
@@ -1,11 +1,12 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var JR=function(a){a=a.querySelectorAll("x-menu-item");for(var b=[],c=a.length,d=0;;)if(d<c){var e=a[d];$APP.p(e.hasAttribute("disabled"))&&$APP.M(e.getAttribute("type"),"divider")&&b.push(e);d+=1}else break;return b},MR=function(a){$APP.n(a.hasAttribute("open"))||(a.setAttribute("open",""),$APP.P(a,"x-menu-open",{}));if($APP.n(null)){a=JR(a);var b=a.length;return b>0?$APP.B.i(null,KR)?a[0].focus():$APP.B.i(null,LR)?a[b-1].focus():null:null}return null},NR=function(a,b){$APP.n(a.hasAttribute("open"))&&
3
- (a.removeAttribute("open"),$APP.P(a,"x-menu-close",{}));return $APP.n(b)?(a=$APP.k(a,"__xMenuRefs"),a=$APP.n(a)?$APP.k(a,"trigger-slot"):null,a=$APP.n(a)?a.assignedElements():null,a=$APP.n($APP.n(a)?a.length>0:a)?a[0]:null,$APP.n(a)?a.focus():null):null},OR=function(a,b){var c=b.composedPath();a=$APP.Cc(a.assignedElements());return $APP.E($APP.be(function(d){return c.indexOf(d)>-1},a))},PR=function(a,b){var c=b.key,d=a.hasAttribute("open");if($APP.B.i(c,"Escape"))return $APP.n(d)?(b.preventDefault(),
4
- NR(a,!0)):null;if($APP.B.i(c,"Tab"))return $APP.n(d)?NR(a,!1):null;if($APP.B.i(c,"ArrowDown")||$APP.B.i(c,"ArrowUp")){var e=JR(a),f=e.length;if(f>0){b.preventDefault();if($APP.n(d))return a=e.indexOf(document.activeElement),c=$APP.B.i(c,"ArrowDown")?a>=f-1?0:a<0?0:a+1:a<=0?f-1:a-1,e[c].focus();MR(a);return e[$APP.B.i(c,"ArrowDown")?0:f-1].focus()}}else if($APP.B.i(c,"Home")){if($APP.n(d)&&(e=JR(a),e.length>0))return b.preventDefault(),e[0].focus()}else if($APP.B.i(c,"End")&&$APP.n(d)&&(e=JR(a),e.length>
5
- 0))return b.preventDefault(),e[e.length-1].focus();return null},RR=function(a){var b=$APP.k(a,"__xMenuRefs");b=$APP.n(b)?$APP.k(b,"popup"):null;a=new $APP.N(null,3,[$APP.Bn,a.hasAttribute("open"),$APP.bl,a.getAttribute("placement"),$APP.X,a.getAttribute("label")],null);a=$APP.J(a);var c=$APP.C(a,$APP.Bn),d=$APP.C(a,$APP.bl);a=$APP.C(a,$APP.X);c=$APP.E(c);d=$APP.n(d)?d:"";d=$APP.Zc(QR,d)?d:"bottom-start";a=new $APP.N(null,3,[$APP.Bn,c,$APP.bl,d,$APP.X,$APP.n(a)?a:""],null);return $APP.n(b)?(b.setAttribute("data-placement",
6
- $APP.bl.g(a)),a=$APP.X.g(a),$APP.n($APP.n(a)?$APP.M(a,""):a)?b.setAttribute("aria-label",a):b.removeAttribute("aria-label")):null},SR=function(a){function b(h){h.stopPropagation();h=h.detail.value;NR(a,!1);return $APP.P(a,"x-menu-select",{value:$APP.n(h)?h:""})}function c(h){return PR(a,h)}function d(h){$APP.n(a.hasAttribute("open"))?(h=h.composedPath(),h=$APP.B.i(-1,h.indexOf(a))?NR(a,!1):null):h=null;return h}function e(h){var l=$APP.k(a,"__xMenuRefs");l=$APP.n(l)?$APP.k(l,"trigger-slot"):null;
7
- return $APP.n($APP.n(l)?OR(l,h):l)?$APP.n(a.hasAttribute("open"))?NR(a,!0):MR(a):null}var f={};a.addEventListener("click",e);document.addEventListener("click",d,!0);a.addEventListener("keydown",c);a.addEventListener("x-menu-item-select",b);f.click=e;f["doc-click"]=d;f.keydown=c;f["item-select"]=b;a.__xMenuHandlers=f},TR=function(a){if($APP.$g(a,"__xMenuInit"))return SR(a),RR(a);if(!$APP.$g(a,"__xMenuInit")){var b=a.attachShadow({mode:"open"}),c=document.createElement("style"),d=document.createElement("div"),
2
+ var RY=function(a){a=a.querySelectorAll("x-menu-item");for(var b=[],c=a.length,d=0;;)if(d<c){var e=a[d];$APP.p(e.hasAttribute("disabled"))&&$APP.I(e.getAttribute("type"),"divider")&&b.push(e);d+=1}else break;return b},SY=function(a){$APP.n(a.hasAttribute("open"))||($APP.S(a,"open",""),$APP.Nh(a,"x-menu-open",{}));if($APP.n(null)){a=RY(a);var b=a.length;return b>0?$APP.A.j(null,Ica)?a[0].focus():$APP.A.j(null,Jca)?a[b-1].focus():null:null}return null},TY=function(a,b){$APP.n(a.hasAttribute("open"))&&
3
+ ($APP.T(a,"open"),$APP.Nh(a,"x-menu-close",{}));return $APP.n(b)?(a=$APP.k(a,"__xMenuRefs"),a=$APP.n(a)?$APP.k(a,"trigger-slot"):null,a=$APP.n(a)?a.assignedElements():null,a=$APP.n($APP.n(a)?a.length>0:a)?a[0]:null,$APP.n(a)?a.focus():null):null},Kca=function(a,b){var c=b.composedPath();a=$APP.Ac(a.assignedElements());return $APP.D($APP.ge(function(d){return c.indexOf(d)>-1},a))},Lca=function(a,b){var c=b.key,d=a.hasAttribute("open");if($APP.A.j(c,"Escape"))return $APP.n(d)?(b.preventDefault(),TY(a,
4
+ !0)):null;if($APP.A.j(c,"Tab"))return $APP.n(d)?TY(a,!1):null;if($APP.A.j(c,"ArrowDown")||$APP.A.j(c,"ArrowUp")){var e=RY(a),f=e.length;if(f>0){b.preventDefault();if($APP.n(d))return a=e.indexOf(document.activeElement),c=$APP.A.j(c,"ArrowDown")?a>=f-1?0:a<0?0:a+1:a<=0?f-1:a-1,e[c].focus();SY(a);return e[$APP.A.j(c,"ArrowDown")?0:f-1].focus()}}else if($APP.A.j(c,"Home")){if($APP.n(d)&&(e=RY(a),e.length>0))return b.preventDefault(),e[0].focus()}else if($APP.A.j(c,"End")&&$APP.n(d)&&(e=RY(a),e.length>
5
+ 0))return b.preventDefault(),e[e.length-1].focus();return null},UY=function(a){var b=$APP.k(a,"__xMenuRefs");b=$APP.n(b)?$APP.k(b,"popup"):null;a=new $APP.O(null,3,[$APP.wq,a.hasAttribute("open"),$APP.Vn,a.getAttribute("placement"),$APP.Z,a.getAttribute("label")],null);a=$APP.G(a);var c=$APP.C(a,$APP.wq),d=$APP.C(a,$APP.Vn);a=$APP.C(a,$APP.Z);c=$APP.D(c);d=$APP.n(d)?d:"";d=$APP.$c(Mca,d)?d:"bottom-start";a=new $APP.O(null,3,[$APP.wq,c,$APP.Vn,d,$APP.Z,$APP.n(a)?a:""],null);return $APP.n(b)?(b.setAttribute("data-placement",
6
+ $APP.Vn.i(a)),a=$APP.Z.i(a),$APP.n($APP.n(a)?$APP.I(a,""):a)?b.setAttribute("aria-label",a):b.removeAttribute("aria-label")):null},VY=function(a){function b(h){h.stopPropagation();h=h.detail.value;TY(a,!1);return $APP.Nh(a,"x-menu-select",{value:$APP.n(h)?h:""})}function c(h){return Lca(a,h)}function d(h){$APP.n(a.hasAttribute("open"))?(h=h.composedPath(),h=$APP.A.j(-1,h.indexOf(a))?TY(a,!1):null):h=null;return h}function e(h){var l=$APP.k(a,"__xMenuRefs");l=$APP.n(l)?$APP.k(l,"trigger-slot"):null;
7
+ return $APP.n($APP.n(l)?Kca(l,h):l)?$APP.n(a.hasAttribute("open"))?TY(a,!0):SY(a):null}var f={};a.addEventListener("click",e);document.addEventListener("click",d,!0);a.addEventListener("keydown",c);a.addEventListener("x-menu-item-select",b);f.click=e;f["doc-click"]=d;f.keydown=c;f["item-select"]=b;$APP.R(a,"__xMenuHandlers",f)},Nca=function(a){if($APP.Fh(a,"__xMenuInit"))return VY(a),UY(a);if(!$APP.Fh(a,"__xMenuInit")){var b=a.attachShadow({mode:"open"}),c=document.createElement("style"),d=document.createElement("div"),
8
8
  e=document.createElement("slot"),f=document.createElement("div"),h=document.createElement("slot");c.textContent=":host{display:inline-block;position:relative;color-scheme:light dark;--x-menu-bg:var(--x-color-bg,#ffffff);--x-menu-border:1px solid var(--x-color-border,#e5e7eb);--x-menu-border-radius:var(--x-radius-md,8px);--x-menu-shadow:var(--x-shadow-md,0 4px 16px rgba(0,0,0,0.12));--x-menu-min-width:160px;--x-menu-padding:4px;--x-menu-z-index:1000;}@media (prefers-color-scheme:dark){:host{--x-menu-bg:var(--x-color-bg,#1f2937);--x-menu-border:1px solid var(--x-color-border,#374151);--x-menu-shadow:var(--x-shadow-md,0 4px 16px rgba(0,0,0,0.4));}}.base{position:relative;display:inline-block;}.popup{display:none;position:absolute;background:var(--x-menu-bg);border:var(--x-menu-border);border-radius:var(--x-menu-border-radius);box-shadow:var(--x-menu-shadow);min-width:var(--x-menu-min-width);max-width:calc(100vw - 1rem);padding:var(--x-menu-padding);z-index:var(--x-menu-z-index);box-sizing:border-box;}:host([open]) .popup{display:block;}.popup[data-placement\x3d'bottom-start']{top:100%;left:0;margin-top:4px;}.popup[data-placement\x3d'bottom-end']{top:100%;right:0;margin-top:4px;}.popup[data-placement\x3d'top-start']{bottom:100%;left:0;margin-bottom:4px;}.popup[data-placement\x3d'top-end']{bottom:100%;right:0;margin-bottom:4px;}";
9
- d.setAttribute("part","base");d.className="base";e.setAttribute("name","trigger");f.setAttribute("part","popup");f.className="popup";f.setAttribute("role","menu");f.appendChild(h);d.appendChild(e);d.appendChild(f);b.appendChild(c);b.appendChild(d);b={};b.base=d;b.popup=f;b["trigger-slot"]=e;b["item-slot"]=h;a.__xMenuRefs=b;SR(a);a.__xMenuInit=!0}RR(a);return a},UR=function(a){var b=$APP.k(a,"__xMenuHandlers");if($APP.n(b)){var c=$APP.k(b,"doc-click"),d=$APP.k(b,"keydown"),e=$APP.k(b,"item-select");
10
- a.removeEventListener("click",$APP.k(b,"click"));document.removeEventListener("click",c,!0);a.removeEventListener("keydown",d);a=a.removeEventListener("x-menu-item-select",e)}else a=null;return a},VR=function(a){return $APP.$g(a,"__xMenuInit")?RR(a):null},YR=function(a){return $APP.jh(a,WR)},$R=function(){return $APP.Yg("x-menu",new $APP.N(null,5,[$APP.Pg,ZR,$APP.Qg,TR,$APP.Rg,UR,$APP.Sg,VR,$APP.Wg,YR],null))},LR=new $APP.F(null,"last","last",1105735132),KR=new $APP.F(null,"first","first",-644103046);var ZR=["open","placement","label"],QR=new $APP.O(null,new $APP.N(null,4,["bottom-start",null,"bottom-end",null,"top-end",null,"top-start",null],null),null),WR=new $APP.N(null,3,[$APP.Bn,new $APP.N(null,2,[$APP.R,$APP.T,$APP.S,"open"],null),$APP.bl,new $APP.N(null,2,[$APP.R,$APP.U,$APP.S,"placement"],null),$APP.X,new $APP.N(null,2,[$APP.R,$APP.U,$APP.S,"label"],null)],null);
11
- $APP.Yd(["x-menu-open",new $APP.N(null,1,[$APP.Z,$APP.Zd],null),"x-menu-close",new $APP.N(null,1,[$APP.Z,$APP.Zd],null),"x-menu-select",new $APP.N(null,1,[$APP.Z,new $APP.N(null,1,[$APP.Gh,$APP.U],null)],null)]);$APP.ca("baredom.exports.x_menu.init",$R);export const init=$R;
9
+ d.setAttribute("part","base");d.className="base";e.setAttribute("name","trigger");f.setAttribute("part","popup");f.className="popup";f.setAttribute("role","menu");f.appendChild(h);d.appendChild(e);d.appendChild(f);b.appendChild(c);b.appendChild(d);b={};b.base=d;b.popup=f;b["trigger-slot"]=e;b["item-slot"]=h;$APP.R(a,"__xMenuRefs",b);VY(a);$APP.R(a,"__xMenuInit",!0)}UY(a);return a},Oca=function(a){var b=$APP.k(a,"__xMenuHandlers");if($APP.n(b)){var c=$APP.k(b,"doc-click"),d=$APP.k(b,"keydown"),e=$APP.k(b,
10
+ "item-select");a.removeEventListener("click",$APP.k(b,"click"));document.removeEventListener("click",c,!0);a.removeEventListener("keydown",d);a=a.removeEventListener("x-menu-item-select",e)}else a=null;return a},Pca=function(a){return $APP.Fh(a,"__xMenuInit")?UY(a):null},Rca=function(a){return $APP.Zh(a,Qca)},WY=function(){return $APP.Ah("x-menu",new $APP.O(null,5,[$APP.qh,Sca,$APP.oh,Nca,$APP.lh,Oca,$APP.kh,Pca,$APP.ph,Rca],null))},Jca=new $APP.F(null,"last","last",1105735132),Ica=new $APP.F(null,
11
+ "first","first",-644103046);var Sca=["open","placement","label"],Mca=new $APP.pg(null,new $APP.O(null,4,["bottom-start",null,"bottom-end",null,"top-end",null,"top-start",null],null),null),Qca=new $APP.O(null,3,[$APP.wq,new $APP.O(null,2,[$APP.Q,$APP.Xh,$APP.W,"open"],null),$APP.Vn,new $APP.O(null,2,[$APP.Q,$APP.X,$APP.W,"placement"],null),$APP.Z,new $APP.O(null,2,[$APP.Q,$APP.X,$APP.W,"label"],null)],null);
12
+ $APP.ce(["x-menu-open",new $APP.O(null,1,[$APP.U,$APP.de],null),"x-menu-close",new $APP.O(null,1,[$APP.U,$APP.de],null),"x-menu-select",new $APP.O(null,1,[$APP.U,new $APP.O(null,1,[$APP.Eh,$APP.X],null)],null)]);$APP.ha("baredom.exports.x_menu.init",WY);export const init=WY;
@@ -1,28 +1,27 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var XN=function(a){if(typeof a==="string"){a=parseInt(a.trim(),10);var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?5:Math.min(10,Math.max(2,a))}return 5},YN=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?40:Math.min(200,Math.max(10,a))}return 40},ZN=function(a){return typeof a==="string"&&a.trim().length>0?a.trim():"#6366f1"},$N=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?
3
- 3:Math.min(20,Math.max(.5,a))}return 3},aO=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?.02:Math.min(.1,Math.max(.001,a))}return.02},bO=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?6:Math.min(30,Math.max(1,a))}return 6},cO=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?12:Math.min(40,Math.max(4,a))}return 12},dO=
4
- function(a){return typeof a==="string"&&a.trim().length>0?a.trim():"1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 20 -10"},fO=function(a){if(typeof a==="string"&&a.trim().length>0){var b=$APP.C(eO,a.trim().toLowerCase());if($APP.n(b))return b;if(a.indexOf(",")>=0)return a=a.split(","),$APP.hf.l($APP.pe,$APP.Ji.i($APP.he.g(function(c){return c.trim()}),$APP.me(function(c){return c.length>0})),a)}return null},gO=function(a){for(var b=[],c=0;;)if(c<a)b.push(Math.max(.01,.35*Math.pow(.45,c))),c+=1;else break;
5
- return b},hO=function(a,b){for(var c=[],d=0;;)if(d<b)c.push(Math.max(a*.5,a*(1-d*.08))),d+=1;else break;return c},iO=function(a,b,c){return a+(b-a)*c},xO=function(a){a=$APP.Lf([$APP.Kn,jO,kO,lO,mO,nO,$APP.lj,$APP.to,oO,pO],[a.getAttribute("blur"),a.getAttribute("noise-intensity"),a.getAttribute("blob-size"),a.getAttribute("palette"),a.getAttribute("noise-scale"),a.getAttribute("noise"),a.getAttribute("threshold"),a.getAttribute("color"),a.getAttribute("blob-count"),a.getAttribute("noise-speed")]);
6
- var b=$APP.J(a),c=$APP.C(b,pO);a=$APP.C(b,$APP.Kn);var d=$APP.C(b,jO),e=$APP.C(b,kO),f=$APP.C(b,lO),h=$APP.C(b,mO),l=$APP.C(b,nO),m=$APP.C(b,$APP.lj),q=$APP.C(b,$APP.to);b=$APP.C(b,oO);b=XN(b);q=ZN(q);f=fO(f);c=aO(c);var r=[];if($APP.n($APP.n(f)?$APP.z(f)>0:f))for(var v=$APP.z(f),x=0;;)if(x<b)r.push($APP.wc(f,$APP.od(x,v))),x+=1;else break;else for(v=0;;)if(v<b)r.push(q),v+=1;else break;return $APP.Lf([$APP.$k,qO,rO,$APP.Ln,$APP.ln,sO,tO,$APP.wj,uO,vO,wO],[q,f,c,r,dO(m),$N(h),b,cO(a),YN(e),l!=null,
7
- bO(d)])},yO=function(a,b){b=$APP.J(b);b=$APP.C(b,$APP.$k);return a.style.setProperty("--x-metaball-cursor-color",b)},AO=function(a){$APP.E(window.matchMedia("(prefers-reduced-motion:reduce)").matches)||(a.__xMetaballSeed=0,$APP.fa(a,"__xMetaballRaf",requestAnimationFrame(function(){return zO(a)})))},BO=function(a){function b(c){var d=$APP.vk.g($APP.k(a,"__xMetaballRefs"));if($APP.n(d)){d=d.getBoundingClientRect();var e=$APP.k(a,"__xMetaballMouse");e.x=c.clientX-d.left;e.y=c.clientY-d.top}return null}
8
- window.addEventListener("pointermove",b);a.__xMetaballHandler=b},CO=function(a){var b=$APP.k(a,"__xMetaballHandler");$APP.n(b)&&(window.removeEventListener("pointermove",b),a.__xMetaballHandler=null)},DO=function(a){Object.defineProperty(a,"blobCount",{get:function(){return XN(this.getAttribute("blob-count"))},set:function(b){return b==null?this.removeAttribute("blob-count"):this.setAttribute("blob-count",""+$APP.Q.g(b|0))},enumerable:!0,configurable:!0});Object.defineProperty(a,"blobSize",{get:function(){return YN(this.getAttribute("blob-size"))},
9
- set:function(b){return b==null?this.removeAttribute("blob-size"):this.setAttribute("blob-size",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"color",{get:function(){return ZN(this.getAttribute("color"))},set:function(b){return b==null?this.removeAttribute("color"):this.setAttribute("color",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});$APP.dh(a,"noise","noise");Object.defineProperty(a,"noiseScale",{get:function(){return $N(this.getAttribute("noise-scale"))},set:function(b){return b==
10
- null?this.removeAttribute("noise-scale"):this.setAttribute("noise-scale",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"noiseSpeed",{get:function(){return aO(this.getAttribute("noise-speed"))},set:function(b){return b==null?this.removeAttribute("noise-speed"):this.setAttribute("noise-speed",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"noiseIntensity",{get:function(){return bO(this.getAttribute("noise-intensity"))},set:function(b){return b==null?
11
- this.removeAttribute("noise-intensity"):this.setAttribute("noise-intensity",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"blur",{get:function(){return cO(this.getAttribute("blur"))},set:function(b){return b==null?this.removeAttribute("blur"):this.setAttribute("blur",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"threshold",{get:function(){return dO(this.getAttribute("threshold"))},set:function(b){return b==null?this.removeAttribute("threshold"):
12
- this.setAttribute("threshold",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});return Object.defineProperty(a,"palette",{get:function(){return fO(this.getAttribute("palette"))},set:function(b){return b==null||$APP.B.i("",b)?this.removeAttribute("palette"):this.setAttribute("palette",""+$APP.Q.g(b))},enumerable:!0,configurable:!0})},GO=function(a){var b=xO(a);a.__xMetaballModel=b;a.__xMetaballMouse={x:0,y:0};if(!$APP.n($APP.k(a,"__xMetaballRefs"))){var c=$APP.k(a,"__xMetaballModel"),d=EO[0];EO[0]=
13
- d+1;var e="mb-"+$APP.Q.g(d),f=a.attachShadow({mode:"open"}),h=document.createElement("style"),l=document.createElement("div"),m=document.createElementNS("http://www.w3.org/2000/svg","svg");a.__xMetaballUid=d;h.textContent=FO;l.setAttribute("part","viewport");l.style.filter="url(#"+$APP.Q.g(e)+")";m.style.position="absolute";m.style.width="0";m.style.height="0";m.style.overflow="hidden";var q=$APP.J(c);c=$APP.C(q,$APP.wj);d=$APP.C(q,$APP.ln);var r=$APP.C(q,vO),v=$APP.C(q,sO);q=$APP.C(q,wO);var x=document.createElementNS("http://www.w3.org/2000/svg",
14
- "defs"),y=document.createElementNS("http://www.w3.org/2000/svg","filter"),A=document.createElementNS("http://www.w3.org/2000/svg","feGaussianBlur"),D=document.createElementNS("http://www.w3.org/2000/svg","feColorMatrix"),G=document.createElementNS("http://www.w3.org/2000/svg","feTurbulence"),I=document.createElementNS("http://www.w3.org/2000/svg","feDisplacementMap");y.setAttribute("id",e);y.setAttribute("x","-20%");y.setAttribute("y","-20%");y.setAttribute("width","140%");y.setAttribute("height",
15
- "140%");A.setAttribute("in","SourceGraphic");A.setAttribute("stdDeviation",""+$APP.Q.g(c));A.setAttribute("result","blur");D.setAttribute("in","blur");D.setAttribute("type","matrix");D.setAttribute("values",d);D.setAttribute("result","threshold");G.setAttribute("type","fractalNoise");G.setAttribute("baseFrequency",""+$APP.Q.g(.01*v));G.setAttribute("numOctaves","3");G.setAttribute("seed","0");G.setAttribute("result","noise");I.setAttribute("in","threshold");I.setAttribute("in2","noise");I.setAttribute("scale",
16
- $APP.n(r)?""+$APP.Q.g(q):"0");I.setAttribute("xChannelSelector","R");I.setAttribute("yChannelSelector","G");y.appendChild(A);y.appendChild(D);y.appendChild(G);y.appendChild(I);x.appendChild(y);m.appendChild(x);e=new $APP.N(null,5,[$APP.wm,y,$APP.wk,A,$APP.ho,D,$APP.fn,G,$APP.Yk,I],null);l.appendChild(m);f.appendChild(h);f.appendChild(l);f=$APP.cg($APP.Bc([e,new $APP.N(null,3,[$APP.Uh,f,$APP.vk,l,$APP.tl,m],null)]));a.__xMetaballRefs=f}f=$APP.k(a,"__xMetaballBlobs");if($APP.n(f)){h=f.length;for(l=
17
- 0;;)if(l<h)m=f[l],$APP.n(m.parentNode)&&m.parentNode.removeChild(m),l+=1;else break;a.__xMetaballBlobs=[];a.__xMetaballPos=[]}h=$APP.J(b);f=$APP.C(h,tO);m=$APP.C(h,uO);h=$APP.C(h,$APP.Ln);l=$APP.J($APP.k(a,"__xMetaballRefs"));l=$APP.C(l,$APP.vk);m=hO(m,f);e=[];c=[];for(d=0;;)if(d<f)r=document.createElement("div"),v=m[d],r.className="blob",r.style.width=""+$APP.Q.g(v)+"px",r.style.height=""+$APP.Q.g(v)+"px",r.style.background=h[d],l.appendChild(r),e.push(r),c.push({x:0,y:0}),d+=1;else break;a.__xMetaballBlobs=
18
- e;a.__xMetaballPos=c;f=gO(f);a.__xMetaballSpeeds=f;yO(a,b);a.setAttribute("aria-hidden","true");a.setAttribute("role","presentation");CO(a);BO(a);AO(a);return null},HO=function(a){var b=$APP.k(a,"__xMetaballRaf");$APP.n(b)&&(cancelAnimationFrame(b),a.__xMetaballRaf=null);CO(a);return null},IO=function(a,b,c,d){if($APP.M(c,d)&&(b=xO(a),a.__xMetaballModel=b,$APP.n($APP.k(a,"__xMetaballRefs")))){d=$APP.J(b);c=$APP.C(d,tO);var e=$APP.C(d,uO);d=$APP.C(d,$APP.Ln);var f=$APP.J($APP.k(a,"__xMetaballRefs")),
19
- h=$APP.C(f,$APP.vk);f=$APP.k(a,"__xMetaballBlobs");var l=$APP.k(a,"__xMetaballPos"),m=f.length;e=hO(e,c);for(var q=m;;)if(q<c){var r=document.createElement("div");r.className="blob";h.appendChild(r);f.push(r);l.push({x:0,y:0});q+=1}else break;for(h=m;;)if(h>c)m=f.pop(),l.pop(),$APP.n(m.parentNode)&&m.parentNode.removeChild(m),--h;else break;for(l=0;;)if(l<c)h=f[l],m=e[l],h.style.width=""+$APP.Q.g(m)+"px",h.style.height=""+$APP.Q.g(m)+"px",h.style.background=d[l],l+=1;else break;c=gO(c);a.__xMetaballSpeeds=
20
- c;f=$APP.J(b);h=$APP.C(f,$APP.wj);e=$APP.C(f,$APP.ln);c=$APP.C(f,vO);d=$APP.C(f,sO);f=$APP.C(f,wO);l=$APP.k(a,"__xMetaballRefs");m=$APP.wk.g(l);$APP.n(m)&&m.setAttribute("stdDeviation",""+$APP.Q.g(h));h=$APP.ho.g(l);$APP.n(h)&&h.setAttribute("values",e);e=$APP.fn.g(l);$APP.n(e)&&e.setAttribute("baseFrequency",""+$APP.Q.g(.01*d));d=$APP.Yk.g(l);$APP.n(d)&&d.setAttribute("scale",$APP.n(c)?""+$APP.Q.g(f):"0");return yO(a,b)}return null},KO=function(){return $APP.Yg("x-metaball-cursor",new $APP.N(null,
21
- 5,[$APP.Pg,JO,$APP.Qg,GO,$APP.Rg,HO,$APP.Sg,IO,$APP.Wg,DO],null))},mO=new $APP.F(null,"noise-scale-raw","noise-scale-raw",123215597),jO=new $APP.F(null,"noise-intensity-raw","noise-intensity-raw",-116633534),vO=new $APP.F(null,"noise?","noise?",-38350370),uO=new $APP.F(null,"blob-size","blob-size",-1862159046),sO=new $APP.F(null,"noise-scale","noise-scale",-2033475279),nO=new $APP.F(null,"noise-attr","noise-attr",-1534959409),lO=new $APP.F(null,"palette-raw","palette-raw",-1398782582),qO=new $APP.F(null,
22
- "palette","palette",-456203511),oO=new $APP.F(null,"blob-count-raw","blob-count-raw",-1850938603),pO=new $APP.F(null,"noise-speed-raw","noise-speed-raw",1761342974),rO=new $APP.F(null,"noise-speed","noise-speed",866692139),tO=new $APP.F(null,"blob-count","blob-count",-248711053),wO=new $APP.F(null,"noise-intensity","noise-intensity",747731519),kO=new $APP.F(null,"blob-size-raw","blob-size-raw",530207878);var JO="blob-count blob-size color noise noise-scale noise-speed noise-intensity blur threshold palette".split(" ");
23
- $APP.Lf([$APP.$k,new $APP.F(null,"blobSize","blobSize",-64083896),new $APP.F(null,"noiseIntensity","noiseIntensity",-792053623),qO,new $APP.F(null,"noiseScale","noiseScale",2003002730),new $APP.F(null,"noise","noise",-994696820),$APP.ln,$APP.wj,new $APP.F(null,"noiseSpeed","noiseSpeed",-959403627),new $APP.F(null,"blobCount","blobCount",-1279691625)],[new $APP.N(null,1,[$APP.R,$APP.U],null),new $APP.N(null,1,[$APP.R,$APP.V],null),new $APP.N(null,1,[$APP.R,$APP.V],null),new $APP.N(null,1,[$APP.R,$APP.U],
24
- null),new $APP.N(null,1,[$APP.R,$APP.V],null),new $APP.N(null,1,[$APP.R,$APP.T],null),new $APP.N(null,1,[$APP.R,$APP.U],null),new $APP.N(null,1,[$APP.R,$APP.V],null),new $APP.N(null,1,[$APP.R,$APP.V],null),new $APP.N(null,1,[$APP.R,$APP.V],null)]);
25
- var eO=new $APP.N(null,5,["rainbow",new $APP.De(null,5,5,$APP.Ee,["#ef4444","#f59e0b","#22c55e","#3b82f6","#a855f7"],null),"ocean",new $APP.De(null,5,5,$APP.Ee,["#06b6d4","#0ea5e9","#6366f1","#8b5cf6","#0d9488"],null),"sunset",new $APP.De(null,5,5,$APP.Ee,["#ef4444","#f97316","#eab308","#ec4899","#f43f5e"],null),"neon",new $APP.De(null,5,5,$APP.Ee,["#22d3ee","#a78bfa","#f472b6","#34d399","#facc15"],null),"ember",new $APP.De(null,5,5,$APP.Ee,["#dc2626","#ea580c","#d97706","#b91c1c","#f59e0b"],null)],
26
- null);var EO=[0],FO=":host{display:block;position:relative;width:100%;height:100%;overflow:hidden;pointer-events:none;z-index:var("+$APP.Q.g("--x-metaball-cursor-z-index")+",9999);}[part\x3dviewport]{position:absolute;inset:var("+$APP.Q.g("--x-metaball-cursor-inset")+",0);pointer-events:none;opacity:var("+$APP.Q.g("--x-metaball-cursor-opacity")+",1);mix-blend-mode:var("+$APP.Q.g("--x-metaball-cursor-blend-mode")+",normal);}.blob{position:absolute;border-radius:50%;will-change:transform;pointer-events:none;top:0;left:0;background:var("+
27
- $APP.Q.g("--x-metaball-cursor-color")+",#6366f1);}@media(prefers-reduced-motion:reduce){.blob{transition:none!important;}}",zO=function zO(a){if($APP.n(a.isConnected)){var c=$APP.k(a,"__xMetaballMouse"),d=$APP.k(a,"__xMetaballBlobs"),e=$APP.k(a,"__xMetaballPos"),f=$APP.k(a,"__xMetaballSpeeds"),h=$APP.k(c,"x");c=$APP.k(c,"y");for(var l=$APP.k(a,"__xMetaballModel"),m=d.length,q=0;;)if(q<m){var r=e[q],v=f[q],x=iO($APP.k(r,"x"),h,v);v=iO($APP.k(r,"y"),c,v);var y=d[q];r.x=x;r.y=v;y.style.transform="translate("+
28
- $APP.Q.g(x)+"px,"+$APP.Q.g(v)+"px) translate(-50%,-50%)";q+=1}else break;$APP.n(vO.g(l))&&(d=$APP.k(a,"__xMetaballSeed")+rO.g(l),e=$APP.k(a,"__xMetaballRefs"),a.__xMetaballSeed=d,e=$APP.fn.g(e),$APP.n(e)&&e.setAttribute("seed",""+$APP.Q.g(Math.floor(d))));$APP.fa(a,"__xMetaballRaf",requestAnimationFrame(function(){return zO.g?zO.g(a):zO.call(null,a)}))}return null};$APP.ca("baredom.exports.x_metaball_cursor.init",KO);export const init=KO;
2
+ var eW=function(a){if(typeof a==="string"){a=parseInt(a.trim(),10);var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?5:Math.min(10,Math.max(2,a))}return 5},fW=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?40:Math.min(200,Math.max(10,a))}return 40},gW=function(a){return typeof a==="string"&&a.trim().length>0?a.trim():"#6366f1"},hW=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?
3
+ 3:Math.min(20,Math.max(.5,a))}return 3},iW=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?.02:Math.min(.1,Math.max(.001,a))}return.02},jW=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?6:Math.min(30,Math.max(1,a))}return 6},kW=function(a){if(typeof a==="string"){a=parseFloat(a.trim());var b=isNaN(a);return $APP.n($APP.n(b)?b:!(a>0))?12:Math.min(40,Math.max(4,a))}return 12},lW=
4
+ function(a){return typeof a==="string"&&a.trim().length>0?a.trim():"1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 20 -10"},mW=function(a){if(typeof a==="string"&&a.trim().length>0){var b=$APP.C(raa,a.trim().toLowerCase());if($APP.n(b))return b;if(a.indexOf(",")>=0)return a=a.split(","),$APP.sf.m($APP.ye,$APP.Il.j($APP.pe.i(function(c){return c.trim()}),$APP.ve(function(c){return c.length>0})),a)}return null},nW=function(a){for(var b=[],c=0;;)if(c<a)b.push(Math.max(.01,.35*Math.pow(.45,c))),c+=1;else break;
5
+ return b},oW=function(a,b){for(var c=[],d=0;;)if(d<b)c.push(Math.max(a*.5,a*(1-d*.08))),d+=1;else break;return c},pW=function(a,b,c){return a+(b-a)*c},EW=function(a){a=$APP.Wf([$APP.Gq,qW,rW,sW,tW,uW,$APP.om,$APP.qr,vW,wW],[a.getAttribute("blur"),a.getAttribute("noise-intensity"),a.getAttribute("blob-size"),a.getAttribute("palette"),a.getAttribute("noise-scale"),a.getAttribute("noise"),a.getAttribute("threshold"),a.getAttribute("color"),a.getAttribute("blob-count"),a.getAttribute("noise-speed")]);
6
+ var b=$APP.G(a),c=$APP.C(b,wW);a=$APP.C(b,$APP.Gq);var d=$APP.C(b,qW),e=$APP.C(b,rW),f=$APP.C(b,sW),h=$APP.C(b,tW),l=$APP.C(b,uW),m=$APP.C(b,$APP.om),q=$APP.C(b,$APP.qr);b=$APP.C(b,vW);b=eW(b);q=gW(q);f=mW(f);c=iW(c);var r=[];if($APP.n($APP.n(f)?$APP.y(f)>0:f))for(var v=$APP.y(f),x=0;;)if(x<b)r.push($APP.tc(f,$APP.qd(x,v))),x+=1;else break;else for(v=0;;)if(v<b)r.push(q),v+=1;else break;return $APP.Wf([$APP.Un,xW,yW,$APP.Iq,$APP.iq,zW,AW,$APP.xm,BW,CW,DW],[q,f,c,r,lW(m),hW(h),b,kW(a),fW(e),l!=null,
7
+ jW(d)])},FW=function(a,b){b=$APP.G(b);b=$APP.C(b,$APP.Un);return a.style.setProperty("--x-metaball-cursor-color",b)},saa=function(a){$APP.D(window.matchMedia("(prefers-reduced-motion:reduce)").matches)||(a.__xMetaballSeed=0,$APP.ja(a,"__xMetaballRaf",requestAnimationFrame(function(){return GW(a)})))},taa=function(a){function b(c){var d=$APP.wn.i($APP.k(a,"__xMetaballRefs"));if($APP.n(d)){d=d.getBoundingClientRect();var e=$APP.k(a,"__xMetaballMouse");e.x=c.clientX-d.left;e.y=c.clientY-d.top}return null}
8
+ window.addEventListener("pointermove",b);a.__xMetaballHandler=b},HW=function(a){var b=$APP.k(a,"__xMetaballHandler");$APP.n(b)&&(window.removeEventListener("pointermove",b),a.__xMetaballHandler=null)},uaa=function(a){Object.defineProperty(a,"blobCount",{get:function(){return eW(this.getAttribute("blob-count"))},set:function(b){return b==null?this.removeAttribute("blob-count"):this.setAttribute("blob-count",""+$APP.V.i(b|0))},enumerable:!0,configurable:!0});Object.defineProperty(a,"blobSize",{get:function(){return fW(this.getAttribute("blob-size"))},
9
+ set:function(b){return b==null?this.removeAttribute("blob-size"):this.setAttribute("blob-size",""+$APP.V.i(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"color",{get:function(){return gW(this.getAttribute("color"))},set:function(b){return b==null?this.removeAttribute("color"):this.setAttribute("color",""+$APP.V.i(b))},enumerable:!0,configurable:!0});$APP.Sh(a,"noise","noise");Object.defineProperty(a,"noiseScale",{get:function(){return hW(this.getAttribute("noise-scale"))},set:function(b){return b==
10
+ null?this.removeAttribute("noise-scale"):this.setAttribute("noise-scale",""+$APP.V.i(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"noiseSpeed",{get:function(){return iW(this.getAttribute("noise-speed"))},set:function(b){return b==null?this.removeAttribute("noise-speed"):this.setAttribute("noise-speed",""+$APP.V.i(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"noiseIntensity",{get:function(){return jW(this.getAttribute("noise-intensity"))},set:function(b){return b==null?
11
+ this.removeAttribute("noise-intensity"):this.setAttribute("noise-intensity",""+$APP.V.i(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"blur",{get:function(){return kW(this.getAttribute("blur"))},set:function(b){return b==null?this.removeAttribute("blur"):this.setAttribute("blur",""+$APP.V.i(b))},enumerable:!0,configurable:!0});Object.defineProperty(a,"threshold",{get:function(){return lW(this.getAttribute("threshold"))},set:function(b){return b==null?this.removeAttribute("threshold"):
12
+ this.setAttribute("threshold",""+$APP.V.i(b))},enumerable:!0,configurable:!0});return Object.defineProperty(a,"palette",{get:function(){return mW(this.getAttribute("palette"))},set:function(b){return b==null||$APP.A.j("",b)?this.removeAttribute("palette"):this.setAttribute("palette",""+$APP.V.i(b))},enumerable:!0,configurable:!0})},waa=function(a){var b=EW(a);a.__xMetaballModel=b;a.__xMetaballMouse={x:0,y:0};if(!$APP.n($APP.k(a,"__xMetaballRefs"))){var c=$APP.k(a,"__xMetaballModel"),d=IW[0];IW[0]=
13
+ d+1;var e="mb-"+$APP.V.i(d),f=a.attachShadow({mode:"open"}),h=document.createElement("style"),l=document.createElement("div"),m=document.createElementNS("http://www.w3.org/2000/svg","svg");a.__xMetaballUid=d;h.textContent=vaa;l.setAttribute("part","viewport");l.style.filter="url(#"+$APP.V.i(e)+")";m.style.position="absolute";m.style.width="0";m.style.height="0";m.style.overflow="hidden";var q=$APP.G(c);c=$APP.C(q,$APP.xm);d=$APP.C(q,$APP.iq);var r=$APP.C(q,CW),v=$APP.C(q,zW);q=$APP.C(q,DW);var x=
14
+ document.createElementNS("http://www.w3.org/2000/svg","defs"),z=document.createElementNS("http://www.w3.org/2000/svg","filter"),B=document.createElementNS("http://www.w3.org/2000/svg","feGaussianBlur"),E=document.createElementNS("http://www.w3.org/2000/svg","feColorMatrix"),H=document.createElementNS("http://www.w3.org/2000/svg","feTurbulence"),K=document.createElementNS("http://www.w3.org/2000/svg","feDisplacementMap");z.setAttribute("id",e);z.setAttribute("x","-20%");z.setAttribute("y","-20%");
15
+ z.setAttribute("width","140%");z.setAttribute("height","140%");B.setAttribute("in","SourceGraphic");B.setAttribute("stdDeviation",""+$APP.V.i(c));B.setAttribute("result","blur");E.setAttribute("in","blur");E.setAttribute("type","matrix");E.setAttribute("values",d);E.setAttribute("result","threshold");H.setAttribute("type","fractalNoise");H.setAttribute("baseFrequency",""+$APP.V.i(.01*v));H.setAttribute("numOctaves","3");H.setAttribute("seed","0");H.setAttribute("result","noise");K.setAttribute("in",
16
+ "threshold");K.setAttribute("in2","noise");K.setAttribute("scale",$APP.n(r)?""+$APP.V.i(q):"0");K.setAttribute("xChannelSelector","R");K.setAttribute("yChannelSelector","G");z.appendChild(B);z.appendChild(E);z.appendChild(H);z.appendChild(K);x.appendChild(z);m.appendChild(x);e=new $APP.O(null,5,[$APP.Bp,z,$APP.xn,B,$APP.fr,E,$APP.dq,H,$APP.Rn,K],null);l.appendChild(m);f.appendChild(h);f.appendChild(l);f=$APP.ng($APP.zc([e,new $APP.O(null,3,[$APP.jj,f,$APP.wn,l,$APP.po,m],null)]));a.__xMetaballRefs=
17
+ f}f=$APP.k(a,"__xMetaballBlobs");if($APP.n(f)){h=f.length;for(l=0;;)if(l<h)m=f[l],$APP.n(m.parentNode)&&m.parentNode.removeChild(m),l+=1;else break;a.__xMetaballBlobs=[];a.__xMetaballPos=[]}h=$APP.G(b);f=$APP.C(h,AW);m=$APP.C(h,BW);h=$APP.C(h,$APP.Iq);l=$APP.G($APP.k(a,"__xMetaballRefs"));l=$APP.C(l,$APP.wn);m=oW(m,f);e=[];c=[];for(d=0;;)if(d<f)r=document.createElement("div"),v=m[d],r.className="blob",r.style.width=""+$APP.V.i(v)+"px",r.style.height=""+$APP.V.i(v)+"px",r.style.background=h[d],l.appendChild(r),
18
+ e.push(r),c.push({x:0,y:0}),d+=1;else break;a.__xMetaballBlobs=e;a.__xMetaballPos=c;f=nW(f);a.__xMetaballSpeeds=f;FW(a,b);$APP.S(a,"aria-hidden","true");$APP.S(a,"role","presentation");HW(a);taa(a);saa(a);return null},xaa=function(a){var b=$APP.k(a,"__xMetaballRaf");$APP.n(b)&&(cancelAnimationFrame(b),a.__xMetaballRaf=null);HW(a);return null},yaa=function(a,b,c,d){if($APP.I(c,d)&&(b=EW(a),a.__xMetaballModel=b,$APP.n($APP.k(a,"__xMetaballRefs")))){d=$APP.G(b);c=$APP.C(d,AW);var e=$APP.C(d,BW);d=$APP.C(d,
19
+ $APP.Iq);var f=$APP.G($APP.k(a,"__xMetaballRefs")),h=$APP.C(f,$APP.wn);f=$APP.k(a,"__xMetaballBlobs");var l=$APP.k(a,"__xMetaballPos"),m=f.length;e=oW(e,c);for(var q=m;;)if(q<c){var r=document.createElement("div");r.className="blob";h.appendChild(r);f.push(r);l.push({x:0,y:0});q+=1}else break;for(h=m;;)if(h>c)m=f.pop(),l.pop(),$APP.n(m.parentNode)&&m.parentNode.removeChild(m),--h;else break;for(l=0;;)if(l<c)h=f[l],m=e[l],h.style.width=""+$APP.V.i(m)+"px",h.style.height=""+$APP.V.i(m)+"px",h.style.background=
20
+ d[l],l+=1;else break;c=nW(c);a.__xMetaballSpeeds=c;f=$APP.G(b);h=$APP.C(f,$APP.xm);e=$APP.C(f,$APP.iq);c=$APP.C(f,CW);d=$APP.C(f,zW);f=$APP.C(f,DW);l=$APP.k(a,"__xMetaballRefs");m=$APP.xn.i(l);$APP.n(m)&&m.setAttribute("stdDeviation",""+$APP.V.i(h));h=$APP.fr.i(l);$APP.n(h)&&h.setAttribute("values",e);e=$APP.dq.i(l);$APP.n(e)&&e.setAttribute("baseFrequency",""+$APP.V.i(.01*d));d=$APP.Rn.i(l);$APP.n(d)&&d.setAttribute("scale",$APP.n(c)?""+$APP.V.i(f):"0");return FW(a,b)}return null},JW=function(){return $APP.Ah("x-metaball-cursor",
21
+ new $APP.O(null,5,[$APP.qh,zaa,$APP.oh,waa,$APP.lh,xaa,$APP.kh,yaa,$APP.ph,uaa],null))},tW=new $APP.F(null,"noise-scale-raw","noise-scale-raw",123215597),qW=new $APP.F(null,"noise-intensity-raw","noise-intensity-raw",-116633534),CW=new $APP.F(null,"noise?","noise?",-38350370),BW=new $APP.F(null,"blob-size","blob-size",-1862159046),zW=new $APP.F(null,"noise-scale","noise-scale",-2033475279),uW=new $APP.F(null,"noise-attr","noise-attr",-1534959409),sW=new $APP.F(null,"palette-raw","palette-raw",-1398782582),
22
+ xW=new $APP.F(null,"palette","palette",-456203511),vW=new $APP.F(null,"blob-count-raw","blob-count-raw",-1850938603),wW=new $APP.F(null,"noise-speed-raw","noise-speed-raw",1761342974),yW=new $APP.F(null,"noise-speed","noise-speed",866692139),AW=new $APP.F(null,"blob-count","blob-count",-248711053),DW=new $APP.F(null,"noise-intensity","noise-intensity",747731519),rW=new $APP.F(null,"blob-size-raw","blob-size-raw",530207878);var zaa="blob-count blob-size color noise noise-scale noise-speed noise-intensity blur threshold palette".split(" ");
23
+ $APP.Wf([$APP.Un,new $APP.F(null,"blobSize","blobSize",-64083896),new $APP.F(null,"noiseIntensity","noiseIntensity",-792053623),xW,new $APP.F(null,"noiseScale","noiseScale",2003002730),new $APP.F(null,"noise","noise",-994696820),$APP.iq,$APP.xm,new $APP.F(null,"noiseSpeed","noiseSpeed",-959403627),new $APP.F(null,"blobCount","blobCount",-1279691625)],[new $APP.O(null,1,[$APP.Q,$APP.X],null),new $APP.O(null,1,[$APP.Q,$APP.Y],null),new $APP.O(null,1,[$APP.Q,$APP.Y],null),new $APP.O(null,1,[$APP.Q,$APP.X],
24
+ null),new $APP.O(null,1,[$APP.Q,$APP.Y],null),new $APP.O(null,1,[$APP.Q,$APP.Xh],null),new $APP.O(null,1,[$APP.Q,$APP.X],null),new $APP.O(null,1,[$APP.Q,$APP.Y],null),new $APP.O(null,1,[$APP.Q,$APP.Y],null),new $APP.O(null,1,[$APP.Q,$APP.Y],null)]);
25
+ var raa=new $APP.O(null,5,["rainbow",new $APP.M(null,5,5,$APP.N,["#ef4444","#f59e0b","#22c55e","#3b82f6","#a855f7"],null),"ocean",new $APP.M(null,5,5,$APP.N,["#06b6d4","#0ea5e9","#6366f1","#8b5cf6","#0d9488"],null),"sunset",new $APP.M(null,5,5,$APP.N,["#ef4444","#f97316","#eab308","#ec4899","#f43f5e"],null),"neon",new $APP.M(null,5,5,$APP.N,["#22d3ee","#a78bfa","#f472b6","#34d399","#facc15"],null),"ember",new $APP.M(null,5,5,$APP.N,["#dc2626","#ea580c","#d97706","#b91c1c","#f59e0b"],null)],null);var IW=[0],vaa=":host{display:block;position:relative;width:100%;height:100%;overflow:hidden;pointer-events:none;z-index:var("+$APP.V.i("--x-metaball-cursor-z-index")+",9999);}[part\x3dviewport]{position:absolute;inset:var("+$APP.V.i("--x-metaball-cursor-inset")+",0);pointer-events:none;opacity:var("+$APP.V.i("--x-metaball-cursor-opacity")+",1);mix-blend-mode:var("+$APP.V.i("--x-metaball-cursor-blend-mode")+",normal);}.blob{position:absolute;border-radius:50%;will-change:transform;pointer-events:none;top:0;left:0;background:var("+
26
+ $APP.V.i("--x-metaball-cursor-color")+",#6366f1);}@media(prefers-reduced-motion:reduce){.blob{transition:none!important;}}",GW=function GW(a){if($APP.n(a.isConnected)){var c=$APP.k(a,"__xMetaballMouse"),d=$APP.k(a,"__xMetaballBlobs"),e=$APP.k(a,"__xMetaballPos"),f=$APP.k(a,"__xMetaballSpeeds"),h=$APP.k(c,"x");c=$APP.k(c,"y");for(var l=$APP.k(a,"__xMetaballModel"),m=d.length,q=0;;)if(q<m){var r=e[q],v=f[q],x=pW($APP.k(r,"x"),h,v);v=pW($APP.k(r,"y"),c,v);var z=d[q];r.x=x;r.y=v;z.style.transform="translate("+
27
+ $APP.V.i(x)+"px,"+$APP.V.i(v)+"px) translate(-50%,-50%)";q+=1}else break;$APP.n(CW.i(l))&&(d=$APP.k(a,"__xMetaballSeed")+yW.i(l),e=$APP.k(a,"__xMetaballRefs"),a.__xMetaballSeed=d,e=$APP.dq.i(e),$APP.n(e)&&e.setAttribute("seed",""+$APP.V.i(Math.floor(d))));$APP.ja(a,"__xMetaballRaf",requestAnimationFrame(function(){return GW.i?GW.i(a):GW.call(null,a)}))}return null};$APP.ha("baredom.exports.x_metaball_cursor.init",JW);export const init=JW;
package/dist/x-modal.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var w2=function(a){var b=$APP.k(a,"__xModalRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("div"),f=document.createElement("div"),h=document.createElement("slot"),l=document.createElement("div"),m=document.createElement("slot"),q=document.createElement("div"),r=document.createElement("slot");c.textContent=":host{display:contents;color-scheme:light dark;--x-modal-bg:var(--x-color-bg,Canvas);--x-modal-fg:var(--x-color-text,CanvasText);--x-modal-backdrop:rgb(0 0 0/0.45);--x-modal-shadow:var(--x-shadow-lg,0 20px 60px rgb(0 0 0/0.25));--x-modal-radius:var(--x-radius-md,0.75rem);--x-modal-width-sm:22rem;--x-modal-width-md:32rem;--x-modal-width-lg:44rem;--x-modal-width-xl:60rem;--x-modal-max-height:90dvh;--x-modal-header-padding:1rem 1.25rem;--x-modal-body-padding:1rem 1.25rem;--x-modal-footer-padding:0.75rem 1.25rem;--x-modal-border:var(--x-color-border,color-mix(in srgb,currentColor 12%,transparent));--x-modal-duration:var(--x-transition-duration,180ms);--x-modal-easing:ease;--x-modal-z:1000;}[part\x3dbackdrop]{position:fixed;inset:0;background:var(--x-modal-backdrop);z-index:var(--x-modal-z);opacity:0;visibility:hidden;pointer-events:none;transition:opacity var(--x-modal-duration) var(--x-modal-easing),visibility 0s var(--x-modal-easing) var(--x-modal-duration);}:host([data-open\x3dtrue]) [part\x3dbackdrop]{opacity:1;visibility:visible;pointer-events:auto;transition:opacity var(--x-modal-duration) var(--x-modal-easing),visibility 0s;}[part\x3ddialog]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%) scale(0.96);opacity:0;visibility:hidden;pointer-events:none;background:var(--x-modal-bg);color:var(--x-modal-fg);box-shadow:var(--x-modal-shadow);border-radius:var(--x-modal-radius);display:flex;flex-direction:column;overflow:hidden;z-index:calc(var(--x-modal-z) + 1);max-height:var(--x-modal-max-height);transition:opacity var(--x-modal-duration) var(--x-modal-easing),transform var(--x-modal-duration) var(--x-modal-easing),visibility 0s var(--x-modal-easing) var(--x-modal-duration);}:host([data-size\x3dsm]) [part\x3ddialog]{width:var(--x-modal-width-sm);}:host([data-size\x3dmd]) [part\x3ddialog]{width:var(--x-modal-width-md);}:host([data-size\x3dlg]) [part\x3ddialog]{width:var(--x-modal-width-lg);}:host([data-size\x3dxl]) [part\x3ddialog]{width:var(--x-modal-width-xl);}:host([data-size\x3dfull]) [part\x3ddialog]{inset:0;top:0;left:0;width:100%;height:100dvh;border-radius:0;max-width:100%;max-height:100dvh;transform:scale(0.98);}:host([data-open\x3dtrue]) [part\x3ddialog]{opacity:1;transform:translate(-50%,-50%) scale(1);visibility:visible;pointer-events:auto;transition:opacity var(--x-modal-duration) var(--x-modal-easing),transform var(--x-modal-duration) var(--x-modal-easing),visibility 0s;}:host([data-open\x3dtrue][data-size\x3dfull]) [part\x3ddialog]{transform:scale(1);}[part\x3ddialog]:focus{outline:none;}[part\x3dheader]{padding:var(--x-modal-header-padding);border-bottom:1px solid var(--x-modal-border);flex-shrink:0;}[part\x3dbody]{padding:var(--x-modal-body-padding);overflow-y:auto;flex:1;}[part\x3dfooter]{padding:var(--x-modal-footer-padding);border-top:1px solid var(--x-modal-border);flex-shrink:0;}[part\x3ddialog]{max-width:calc(100vw - 2rem);}:host([data-size\x3dfull]) [part\x3ddialog]{max-width:100%;}@media (prefers-reduced-motion:reduce){[part\x3ddialog],[part\x3dbackdrop]{transition:none;}}";
2
+ var u4=function(a){var b=$APP.k(a,"__xModalRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("div"),f=document.createElement("div"),h=document.createElement("slot"),l=document.createElement("div"),m=document.createElement("slot"),q=document.createElement("div"),r=document.createElement("slot");c.textContent=":host{display:contents;color-scheme:light dark;--x-modal-bg:var(--x-color-bg,Canvas);--x-modal-fg:var(--x-color-text,CanvasText);--x-modal-backdrop:rgb(0 0 0/0.45);--x-modal-shadow:var(--x-shadow-lg,0 20px 60px rgb(0 0 0/0.25));--x-modal-radius:var(--x-radius-md,0.75rem);--x-modal-width-sm:22rem;--x-modal-width-md:32rem;--x-modal-width-lg:44rem;--x-modal-width-xl:60rem;--x-modal-max-height:90dvh;--x-modal-header-padding:1rem 1.25rem;--x-modal-body-padding:1rem 1.25rem;--x-modal-footer-padding:0.75rem 1.25rem;--x-modal-border:var(--x-color-border,color-mix(in srgb,currentColor 12%,transparent));--x-modal-duration:var(--x-transition-duration,180ms);--x-modal-easing:ease;--x-modal-z:1000;}[part\x3dbackdrop]{position:fixed;inset:0;background:var(--x-modal-backdrop);z-index:var(--x-modal-z);opacity:0;visibility:hidden;pointer-events:none;transition:opacity var(--x-modal-duration) var(--x-modal-easing),visibility 0s var(--x-modal-easing) var(--x-modal-duration);}:host([data-open\x3dtrue]) [part\x3dbackdrop]{opacity:1;visibility:visible;pointer-events:auto;transition:opacity var(--x-modal-duration) var(--x-modal-easing),visibility 0s;}[part\x3ddialog]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%) scale(0.96);opacity:0;visibility:hidden;pointer-events:none;background:var(--x-modal-bg);color:var(--x-modal-fg);box-shadow:var(--x-modal-shadow);border-radius:var(--x-modal-radius);display:flex;flex-direction:column;overflow:hidden;z-index:calc(var(--x-modal-z) + 1);max-height:var(--x-modal-max-height);transition:opacity var(--x-modal-duration) var(--x-modal-easing),transform var(--x-modal-duration) var(--x-modal-easing),visibility 0s var(--x-modal-easing) var(--x-modal-duration);}:host([data-size\x3dsm]) [part\x3ddialog]{width:var(--x-modal-width-sm);}:host([data-size\x3dmd]) [part\x3ddialog]{width:var(--x-modal-width-md);}:host([data-size\x3dlg]) [part\x3ddialog]{width:var(--x-modal-width-lg);}:host([data-size\x3dxl]) [part\x3ddialog]{width:var(--x-modal-width-xl);}:host([data-size\x3dfull]) [part\x3ddialog]{inset:0;top:0;left:0;width:100%;height:100dvh;border-radius:0;max-width:100%;max-height:100dvh;transform:scale(0.98);}:host([data-open\x3dtrue]) [part\x3ddialog]{opacity:1;transform:translate(-50%,-50%) scale(1);visibility:visible;pointer-events:auto;transition:opacity var(--x-modal-duration) var(--x-modal-easing),transform var(--x-modal-duration) var(--x-modal-easing),visibility 0s;}:host([data-open\x3dtrue][data-size\x3dfull]) [part\x3ddialog]{transform:scale(1);}[part\x3ddialog]:focus{outline:none;}[part\x3dheader]{padding:var(--x-modal-header-padding);border-bottom:1px solid var(--x-modal-border);flex-shrink:0;}[part\x3dbody]{padding:var(--x-modal-body-padding);overflow-y:auto;flex:1;}[part\x3dfooter]{padding:var(--x-modal-footer-padding);border-top:1px solid var(--x-modal-border);flex-shrink:0;}[part\x3ddialog]{max-width:calc(100vw - 2rem);}:host([data-size\x3dfull]) [part\x3ddialog]{max-width:100%;}@media (prefers-reduced-motion:reduce){[part\x3ddialog],[part\x3dbackdrop]{transition:none;}}";
3
3
  d.setAttribute("part","backdrop");e.setAttribute("part","dialog");e.setAttribute("role","dialog");e.setAttribute("aria-modal","true");f.setAttribute("part","header");h.setAttribute("name","header");l.setAttribute("part","body");q.setAttribute("part","footer");r.setAttribute("name","footer");f.appendChild(h);l.appendChild(m);q.appendChild(r);e.appendChild(f);e.appendChild(l);e.appendChild(q);b.appendChild(c);b.appendChild(d);b.appendChild(e);a.__xModalRefs={root:b,backdrop:d,dialog:e,header:f,body:l,
4
- footer:q};return $APP.k(a,"__xModalRefs")},x2=function(a){function b(d){var e=window.getComputedStyle(d);return $APP.M("none",e.display)&&$APP.M("hidden",e.visibility)&&d.offsetWidth>0&&d.offsetHeight>0}var c=$APP.ne(b,$APP.Bc($APP.k(a,"dialog").querySelectorAll("a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex\x3d'-1'])")));a=$APP.le(function(d){return $APP.ne(b,$APP.le(function(e){var f=$APP.Bc(e.querySelectorAll("a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex\x3d'-1'])"));
5
- return $APP.n(e.matches("a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex\x3d'-1'])"))?$APP.xd(e,f):f},$APP.Bc([$APP.Cc(d.assignedElements({flatten:!0}))])))},$APP.Bc([$APP.Bc($APP.k(a,"root").querySelectorAll("slot"))]));return $APP.Je($APP.ke.i(c,a))},y2=function(a){var b=$APP.k(a,"__xModalRefs");b=$APP.n(b)?$APP.k(b,"dialog"):null;var c=$APP.k(a,"__xModalRestore"),d=$APP.k(a,"__xModalDialogTab")===!0;a.__xModalTabbables=
6
- null;a.__xModalRestore=null;$APP.n($APP.n(b)?d:b)&&(b.removeAttribute("tabindex"),a.__xModalDialogTab=!1);$APP.n($APP.n(c)?c.isConnected:c)&&c.focus()},z2=function(a,b){$APP.P(a,"x-modal-dismiss",{reason:b});a.removeAttribute("open");return null},A2=function(a){$APP.n(a.hasAttribute("open"))||a.setAttribute("open","");return null},B2=function(a){a.removeAttribute("open");return null},C2=function(a,b){$APP.M($APP.k(a,"__xModalPrevOpen"),b)&&(a.__xModalPrevOpen=b,$APP.P(a,"x-modal-toggle",{open:b}),
7
- $APP.n(b)?setTimeout(function(){var c=$APP.k(a,"__xModalRefs"),d=$APP.n(c)?$APP.k(c,"dialog"):null;c=$APP.n(c)?x2(c):null;a.__xModalRestore=document.activeElement;var e=$APP.n(c)?$APP.Xi(c):null;a.__xModalTabbables=e;$APP.t(c)?$APP.u(c).focus():$APP.n(d)&&($APP.n(d.hasAttribute("tabindex"))||(d.setAttribute("tabindex","-1"),a.__xModalDialogTab=!0),d.focus());return null},0):y2(a))},E2=function(a){var b=w2(a);b=$APP.k(b,"dialog");var c=new $APP.N(null,3,[$APP.Pj,a.hasAttribute("open"),$APP.on,a.getAttribute("size"),
8
- $APP.Ch,a.getAttribute("label")],null);var d=$APP.J(c),e=$APP.C(d,$APP.Pj);c=$APP.C(d,$APP.on);d=$APP.C(d,$APP.Ch);e=$APP.E(e);c=typeof c==="string"&&$APP.Zc(D2,c)?c:"md";d=typeof d==="string"&&$APP.M(d,"")?d:"Modal";c=new $APP.N(null,3,[$APP.ao,e,$APP.bj,c,$APP.X,d],null);d=$APP.ao.g(c);a.setAttribute("data-open",$APP.n(d)?"true":"false");a.setAttribute("data-size",$APP.bj.g(c));b.setAttribute("aria-label",$APP.X.g(c));C2(a,d)},F2=function(a){function b(f){var h=f.key;if($APP.B.i(h,"Escape"))f.preventDefault(),
9
- z2(a,"escape");else if($APP.B.i(h,"Tab")){h=$APP.k(a,"__xModalTabbables");h=$APP.n(h)?$APP.Je($APP.Bc(h)):$APP.pe;var l=$APP.k(a,"__xModalRefs");l=$APP.n(l)?$APP.k(l,"dialog"):null;if($APP.Oc(h))f.preventDefault(),$APP.n(l)&&l.focus();else{l=document.activeElement;var m=$APP.u(h);h=$APP.Ec(h);var q=f.shiftKey;$APP.n($APP.n(q)?$APP.B.i(l,m):q)?(f.preventDefault(),h.focus()):$APP.p(q)&&$APP.B.i(l,h)&&(f.preventDefault(),m.focus())}}return null}function c(){return z2(a,"backdrop")}var d=w2(a),e=$APP.k(d,
10
- "dialog");$APP.k(d,"backdrop").addEventListener("click",c);e.addEventListener("keydown",b);$APP.fa(a,"__xModalHandlers",{backdrop:c,keydown:b})},G2=function(a){var b=$APP.k(a,"__xModalHandlers"),c=$APP.k(a,"__xModalRefs");if($APP.n($APP.n(b)?c:b)){var d=$APP.k(c,"backdrop");c=$APP.k(c,"dialog");var e=$APP.k(b,"backdrop");b=$APP.k(b,"keydown");$APP.n(e)&&d.removeEventListener("click",e);$APP.n(b)&&c.removeEventListener("keydown",b)}a.__xModalHandlers=null},H2=function(a){w2(a);G2(a);F2(a);E2(a);return null},
11
- I2=function(a){G2(a);y2(a);return null},J2=function(a,b,c,d){$APP.M(c,d)&&E2(a);return null},K2=function(a){Object.defineProperty(a,"open",{get:function(){return this.hasAttribute("open")},set:function(b){return $APP.n(b)?A2(this):B2(this)},enumerable:!0,configurable:!0});$APP.eh(a,"size","size","md");$APP.eh(a,"label","label","Modal");Object.defineProperty(a,"show",{value:function(){return A2(this)},enumerable:!0,configurable:!0,writable:!0});Object.defineProperty(a,"hide",{value:function(){return B2(this)},
12
- enumerable:!0,configurable:!0,writable:!0});return Object.defineProperty(a,"toggle",{value:function(){$APP.n(this.hasAttribute("open"))?B2(this):A2(this);return null},enumerable:!0,configurable:!0,writable:!0})},M2=function(){return $APP.Yg("x-modal",new $APP.N(null,5,[$APP.Pg,L2,$APP.Qg,H2,$APP.Rg,I2,$APP.Sg,J2,$APP.Wg,K2],null))};var D2=new $APP.O(null,new $APP.N(null,5,["md",null,"lg",null,"full",null,"xl",null,"sm",null],null),null),L2=["open","size","label"];$APP.Yd(["x-modal-toggle",new $APP.N(null,2,[$APP.Fn,!1,$APP.Z,new $APP.N(null,1,[$APP.Bn,$APP.T],null)],null),"x-modal-dismiss",new $APP.N(null,2,[$APP.Fn,!1,$APP.Z,new $APP.N(null,1,[$APP.Yj,$APP.U],null)],null)]);$APP.ca("baredom.exports.x_modal.init",M2);export const init=M2;
4
+ footer:q};return $APP.k(a,"__xModalRefs")},Wha=function(a){function b(d){var e=window.getComputedStyle(d);return $APP.I("none",e.display)&&$APP.I("hidden",e.visibility)&&d.offsetWidth>0&&d.offsetHeight>0}var c=$APP.we(b,$APP.zc($APP.k(a,"dialog").querySelectorAll("a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex\x3d'-1'])")));a=$APP.ue(function(d){return $APP.we(b,$APP.ue(function(e){var f=$APP.zc(e.querySelectorAll("a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex\x3d'-1'])"));
5
+ return $APP.n(e.matches("a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex\x3d'-1'])"))?$APP.zd(e,f):f},$APP.zc([$APP.Ac(d.assignedElements({flatten:!0}))])))},$APP.zc([$APP.zc($APP.k(a,"root").querySelectorAll("slot"))]));return $APP.Qe($APP.te.j(c,a))},v4=function(a){var b=$APP.k(a,"__xModalRefs");b=$APP.n(b)?$APP.k(b,"dialog"):null;var c=$APP.k(a,"__xModalRestore"),d=$APP.k(a,"__xModalDialogTab")===!0;a.__xModalTabbables=
6
+ null;a.__xModalRestore=null;$APP.n($APP.n(b)?d:b)&&(b.removeAttribute("tabindex"),a.__xModalDialogTab=!1);$APP.n($APP.n(c)?c.isConnected:c)&&c.focus()},w4=function(a,b){$APP.Nh(a,"x-modal-dismiss",{reason:b});$APP.T(a,"open");return null},x4=function(a){$APP.n(a.hasAttribute("open"))||$APP.S(a,"open","");return null},y4=function(a){$APP.T(a,"open");return null},Xha=function(a,b){$APP.I($APP.k(a,"__xModalPrevOpen"),b)&&(a.__xModalPrevOpen=b,$APP.Nh(a,"x-modal-toggle",{open:b}),$APP.n(b)?setTimeout(function(){var c=
7
+ $APP.k(a,"__xModalRefs"),d=$APP.n(c)?$APP.k(c,"dialog"):null;c=$APP.n(c)?Wha(c):null;a.__xModalRestore=document.activeElement;var e=$APP.n(c)?$APP.$l(c):null;a.__xModalTabbables=e;$APP.t(c)?$APP.u(c).focus():$APP.n(d)&&($APP.n(d.hasAttribute("tabindex"))||(d.setAttribute("tabindex","-1"),a.__xModalDialogTab=!0),d.focus());return null},0):v4(a))},z4=function(a){var b=u4(a);b=$APP.k(b,"dialog");var c=new $APP.O(null,3,[$APP.Qm,a.hasAttribute("open"),$APP.Vk,a.getAttribute("size"),$APP.ui,a.getAttribute("label")],
8
+ null);var d=$APP.G(c),e=$APP.C(d,$APP.Qm);c=$APP.C(d,$APP.Vk);d=$APP.C(d,$APP.ui);e=$APP.D(e);c=typeof c==="string"&&$APP.$c(Yha,c)?c:"md";d=typeof d==="string"&&$APP.I(d,"")?d:"Modal";c=new $APP.O(null,3,[$APP.Zq,e,$APP.ok,c,$APP.Z,d],null);d=$APP.Zq.i(c);$APP.S(a,"data-open",$APP.n(d)?"true":"false");$APP.S(a,"data-size",$APP.ok.i(c));b.setAttribute("aria-label",$APP.Z.i(c));Xha(a,d)},Zha=function(a){function b(f){var h=f.key;if($APP.A.j(h,"Escape"))f.preventDefault(),w4(a,"escape");else if($APP.A.j(h,
9
+ "Tab")){h=$APP.k(a,"__xModalTabbables");h=$APP.n(h)?$APP.Qe($APP.zc(h)):$APP.ye;var l=$APP.k(a,"__xModalRefs");l=$APP.n(l)?$APP.k(l,"dialog"):null;if($APP.Pc(h))f.preventDefault(),$APP.n(l)&&l.focus();else{l=document.activeElement;var m=$APP.u(h);h=$APP.Dc(h);var q=f.shiftKey;$APP.n($APP.n(q)?$APP.A.j(l,m):q)?(f.preventDefault(),h.focus()):$APP.p(q)&&$APP.A.j(l,h)&&(f.preventDefault(),m.focus())}}return null}function c(){return w4(a,"backdrop")}var d=u4(a),e=$APP.k(d,"dialog");$APP.k(d,"backdrop").addEventListener("click",
10
+ c);e.addEventListener("keydown",b);$APP.ja(a,"__xModalHandlers",{backdrop:c,keydown:b})},A4=function(a){var b=$APP.k(a,"__xModalHandlers"),c=$APP.k(a,"__xModalRefs");if($APP.n($APP.n(b)?c:b)){var d=$APP.k(c,"backdrop");c=$APP.k(c,"dialog");var e=$APP.k(b,"backdrop");b=$APP.k(b,"keydown");$APP.n(e)&&d.removeEventListener("click",e);$APP.n(b)&&c.removeEventListener("keydown",b)}a.__xModalHandlers=null},$ha=function(a){u4(a);A4(a);Zha(a);z4(a);return null},aia=function(a){A4(a);v4(a);return null},bia=
11
+ function(a,b,c,d){$APP.I(c,d)&&z4(a);return null},cia=function(a){Object.defineProperty(a,"open",{get:function(){return this.hasAttribute("open")},set:function(b){return $APP.n(b)?x4(this):y4(this)},enumerable:!0,configurable:!0});$APP.Th(a,"size","size","md");$APP.Th(a,"label","label","Modal");Object.defineProperty(a,"show",{value:function(){return x4(this)},enumerable:!0,configurable:!0,writable:!0});Object.defineProperty(a,"hide",{value:function(){return y4(this)},enumerable:!0,configurable:!0,
12
+ writable:!0});return Object.defineProperty(a,"toggle",{value:function(){$APP.n(this.hasAttribute("open"))?y4(this):x4(this);return null},enumerable:!0,configurable:!0,writable:!0})},B4=function(){return $APP.Ah("x-modal",new $APP.O(null,5,[$APP.qh,dia,$APP.oh,$ha,$APP.lh,aia,$APP.kh,bia,$APP.ph,cia],null))};var Yha=new $APP.pg(null,new $APP.O(null,5,["md",null,"lg",null,"full",null,"xl",null,"sm",null],null),null),dia=["open","size","label"];$APP.ce(["x-modal-toggle",new $APP.O(null,2,[$APP.Aq,!1,$APP.U,new $APP.O(null,1,[$APP.wq,$APP.Xh],null)],null),"x-modal-dismiss",new $APP.O(null,2,[$APP.Aq,!1,$APP.U,new $APP.O(null,1,[$APP.Ym,$APP.X],null)],null)]);$APP.ha("baredom.exports.x_modal.init",B4);export const init=B4;
@@ -1,39 +1,38 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var Xz=function(a){return typeof a==="string"?(a=a.trim().toLowerCase(),$APP.Zc(Wz,a)?a:"clean"):"clean"},Yz=function(a){return $APP.B.i(a,"organic")||$APP.B.i(a,"liquid")},Zz=function(a){var b=(a-1)/17*-7;return"1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 "+$APP.Q.g(a)+" "+$APP.Q.g(b)},$z=function(a,b,c,d){if(typeof a==="string"){a=a.trim();if($APP.B.i(a,""))return b;a=parseFloat(a);return $APP.n(isNaN(a))?b:Math.min(d,Math.max(c,a))}return b},aA=function(a,b,c,d){if($APP.n($APP.n(a)?a>0:a)){b=$APP.Hi.i(1E-4,
3
- $APP.n(b)?b:0);c=$APP.Hi.i(1E-4,$APP.n(c)?c:0);d=$APP.Hi.i(1E-4,$APP.n(d)?d:0);var e=Math.sqrt(b/d);a=1E3*(4/($APP.Hi.i(.2,$APP.Ii.i(5,c/(2*Math.sqrt(b*d))))*e)+Math.PI/e)/a}else a=1;return a},bA=function(a,b,c,d,e,f){b+=(e*(1-a)-f*b)/d*c;return[a+b*c,b]},dA=function(a,b){b=$APP.J(b);var c=$APP.C(b,cA);b=$APP.C(b,$APP.nl);var d=$APP.Je(a);a=$APP.z(d);if(a>0){var e=$APP.n(function(){return $APP.n(c)?$APP.be(function(f){return $APP.B.i(f,c)},d):c}())?c:null;if($APP.n(e))return e;a=$APP.Hi.i(0,$APP.Ii.i(a-
4
- 1,$APP.n(b)?b:0));return $APP.wc(d,a)}return null},eA=function(a,b,c){return a+(b-a)*c},fA=function(a){if(typeof a==="string"){a=a.match(/rgba?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)(?:\s*,\s*(\d*(?:\.\d+)?))?\s*\)/);if($APP.n(a)){var b=parseFloat(a[1]),c=parseFloat(a[2]),d=parseFloat(a[3]);var e=a[4];e=$APP.n(e)?$APP.M("",a[4]):e;a=[b,c,d,$APP.n(e)?parseFloat(a[4]):1]}else a=null;return a}return null},gA=function(a,b,c){var d=fA(a),e=fA(b);return $APP.n($APP.n(d)?e:d)?"rgba("+
5
- $APP.Q.g(Math.round(eA(d[0],e[0],c)))+","+$APP.Q.g(Math.round(eA(d[1],e[1],c)))+","+$APP.Q.g(Math.round(eA(d[2],e[2],c)))+","+$APP.Q.g(eA(d[3],e[3],c))+")":c<.5?a:b},hA=function(a){if(typeof a==="string")if(a=a.trim(),$APP.M(a,"")){a=a.split(/\s+/);for(var b=a.length,c=[],d=0;;){if(d>=b)return c.length>0?c:null;var e=a[d];if($APP.n(e.endsWith("px"))){e=parseFloat(e.slice(0,e.length-2));if($APP.n(isNaN(e)))return null;c.push(e);d+=1}else return null}}else return null;else return null},iA=function(a,
6
- b){return new $APP.N(null,2,[$APP.kj,$APP.n(a)?a:"",$APP.wn,$APP.n(b)?b:""],null)},kA=function(a){var b=$APP.k(a,"__xMorphStackRefs"),c=$APP.n(b)?jA.g(b):null;if($APP.n($APP.n(c)?c.isConnected:c))return b;c=document.createElement("div");var d=document.createElementNS("http://www.w3.org/2000/svg","svg");c.style.position="fixed";c.style.top="0";c.style.left="0";c.style.width="100%";c.style.height="100dvh";c.style.pointerEvents="none";c.style.overflow="visible";c.style.zIndex="2147483646";c.setAttribute("aria-hidden",
7
- "true");c.setAttribute("data-x-morph-stack-ghost-layer","");d.style.position="absolute";d.style.width="0";d.style.height="0";d.style.overflow="hidden";d.setAttribute("aria-hidden","true");c.appendChild(d);document.body.appendChild(c);b=$APP.Fi.B(b,jA,c,$APP.Bc([$APP.tl,d]));return a.__xMorphStackRefs=b},lA=function(a){var b=$APP.k(a,"__xMorphStackRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("slot");
2
+ var YC=function(a){return typeof a==="string"?(a=a.trim().toLowerCase(),$APP.$c(XC,a)?a:"clean"):"clean"},ZC=function(a){return $APP.A.j(a,"organic")||$APP.A.j(a,"liquid")},$C=function(a){var b=(a-1)/17*-7;return"1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 "+$APP.V.i(a)+" "+$APP.V.i(b)},aD=function(a,b,c,d){if(typeof a==="string"){a=a.trim();if($APP.A.j(a,""))return b;a=parseFloat(a);return $APP.n(isNaN(a))?b:Math.min(d,Math.max(c,a))}return b},bD=function(a,b,c,d){if($APP.n($APP.n(a)?a>0:a)){b=$APP.Gl.j(1E-4,
3
+ $APP.n(b)?b:0);c=$APP.Gl.j(1E-4,$APP.n(c)?c:0);d=$APP.Gl.j(1E-4,$APP.n(d)?d:0);var e=Math.sqrt(b/d);a=1E3*(4/($APP.Gl.j(.2,$APP.Hl.j(5,c/(2*Math.sqrt(b*d))))*e)+Math.PI/e)/a}else a=1;return a},cD=function(a,b,c,d,e,f){b+=(e*(1-a)-f*b)/d*c;return[a+b*c,b]},eD=function(a,b){b=$APP.G(b);var c=$APP.C(b,dD);b=$APP.C(b,$APP.ho);var d=$APP.Qe(a);a=$APP.y(d);if(a>0){var e=$APP.n(function(){return $APP.n(c)?$APP.ge(function(f){return $APP.A.j(f,c)},d):c}())?c:null;if($APP.n(e))return e;a=$APP.Gl.j(0,$APP.Hl.j(a-
4
+ 1,$APP.n(b)?b:0));return $APP.tc(d,a)}return null},fD=function(a,b,c){return a+(b-a)*c},gD=function(a){if(typeof a==="string"){a=a.match(/rgba?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)(?:\s*,\s*(\d*(?:\.\d+)?))?\s*\)/);if($APP.n(a)){var b=parseFloat(a[1]),c=parseFloat(a[2]),d=parseFloat(a[3]);var e=a[4];e=$APP.n(e)?$APP.I("",a[4]):e;a=[b,c,d,$APP.n(e)?parseFloat(a[4]):1]}else a=null;return a}return null},hD=function(a,b,c){var d=gD(a),e=gD(b);return $APP.n($APP.n(d)?e:d)?"rgba("+
5
+ $APP.V.i(Math.round(fD(d[0],e[0],c)))+","+$APP.V.i(Math.round(fD(d[1],e[1],c)))+","+$APP.V.i(Math.round(fD(d[2],e[2],c)))+","+$APP.V.i(fD(d[3],e[3],c))+")":c<.5?a:b},iD=function(a){if(typeof a==="string")if(a=a.trim(),$APP.I(a,"")){a=a.split(/\s+/);for(var b=a.length,c=[],d=0;;){if(d>=b)return c.length>0?c:null;var e=a[d];if($APP.n(e.endsWith("px"))){e=parseFloat(e.slice(0,e.length-2));if($APP.n(isNaN(e)))return null;c.push(e);d+=1}else return null}}else return null;else return null},jD=function(a,
6
+ b){return new $APP.O(null,2,[$APP.nm,$APP.n(a)?a:"",$APP.rq,$APP.n(b)?b:""],null)},lD=function(a){var b=$APP.k(a,"__xMorphStackRefs"),c=$APP.n(b)?kD.i(b):null;if($APP.n($APP.n(c)?c.isConnected:c))return b;c=document.createElement("div");var d=document.createElementNS("http://www.w3.org/2000/svg","svg");c.style.position="fixed";c.style.top="0";c.style.left="0";c.style.width="100%";c.style.height="100dvh";c.style.pointerEvents="none";c.style.overflow="visible";c.style.zIndex="2147483646";c.setAttribute("aria-hidden",
7
+ "true");c.setAttribute("data-x-morph-stack-ghost-layer","");d.style.position="absolute";d.style.width="0";d.style.height="0";d.style.overflow="hidden";d.setAttribute("aria-hidden","true");c.appendChild(d);document.body.appendChild(c);b=$APP.Dk.B(b,kD,c,$APP.zc([$APP.po,d]));return a.__xMorphStackRefs=b},mD=function(a){var b=$APP.k(a,"__xMorphStackRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("slot");
8
8
  c.textContent=":host{display:block;position:relative;color-scheme:light dark;--x-morph-stack-spring-stiffness:170;--x-morph-stack-spring-damping:26;--x-morph-stack-spring-mass:1;--x-morph-stack-fade-ms:160ms;--x-morph-stack-goo-blur:10;--x-morph-stack-goo-threshold:18;--x-morph-stack-bg:transparent;}:host([data-variant\x3d'clean']){--x-morph-stack-spring-stiffness:280;--x-morph-stack-spring-damping:30;--x-morph-stack-spring-mass:0.7;}:host([data-variant\x3d'organic']){--x-morph-stack-spring-stiffness:180;--x-morph-stack-spring-damping:5;--x-morph-stack-spring-mass:1.0;--x-morph-stack-goo-blur:6;--x-morph-stack-goo-threshold:14;}:host([data-variant\x3d'liquid']){--x-morph-stack-spring-stiffness:50;--x-morph-stack-spring-damping:14;--x-morph-stack-spring-mass:2.0;--x-morph-stack-goo-blur:26;--x-morph-stack-goo-threshold:26;}[part\x3dviewport]{position:relative;display:block;background:var(--x-morph-stack-bg);}:host([disabled]){opacity:0.7;}";
9
- d.setAttribute("part","viewport");e.setAttribute("name","state");d.appendChild(e);b.appendChild(c);b.appendChild(d);a.__xMorphStackRefs=new $APP.N(null,3,[$APP.Uh,b,$APP.vk,d,$APP.tk,e],null);return $APP.k(a,"__xMorphStackRefs")},nA=function(a){a=new $APP.N(null,8,[mA,a.getAttribute("active-state"),$APP.zm,a.getAttribute("active-index"),$APP.En,a.getAttribute("stiffness"),$APP.ko,a.getAttribute("damping"),$APP.Rk,a.getAttribute("mass"),$APP.Gm,a.getAttribute("variant"),$APP.dk,a.getAttribute("duration"),
10
- $APP.Fh,a.hasAttribute("disabled")],null);a=$APP.J(a);var b=$APP.C(a,mA),c=$APP.C(a,$APP.zm),d=$APP.C(a,$APP.En),e=$APP.C(a,$APP.ko),f=$APP.C(a,$APP.Rk),h=$APP.C(a,$APP.Gm),l=$APP.C(a,$APP.dk);a=$APP.C(a,$APP.Fh);b=typeof b==="string"&&$APP.M("",b.trim())?b.trim():null;a:{if(typeof c==="string"&&(c=c.trim(),$APP.M(c,""))){c=parseInt(c,10);c=typeof c==="number"&&$APP.p(isNaN(c))&&c>=0?c:null;break a}c=null}d=$z(d,170,10,500);e=$z(e,26,1,100);f=$z(f,1,.1,10);h=Xz(h);a:{if(typeof l==="string"&&(l=l.trim(),
11
- $APP.M(l,""))){l=parseFloat(l);l=typeof l==="number"&&$APP.p(isNaN(l))&&l>0?l:null;break a}l=null}return new $APP.N(null,8,[cA,b,$APP.nl,c,$APP.kn,d,$APP.Wl,e,$APP.Nn,f,$APP.ii,h,$APP.rm,l,$APP.Y,$APP.E(a)],null)},oA=function(a,b,c){a=window.getComputedStyle(a).getPropertyValue(b);return typeof a==="string"&&$APP.M("",a.trim())?(a=parseFloat(a.trim()),$APP.n(isNaN(a))?c:a):c},pA=function(a){a=lA(a);a=$APP.J(a);a=$APP.C(a,$APP.tk).assignedElements();for(var b=[],c=a.length,d=0;;)if(d<c){var e=a[d],
12
- f=$APP.B.i(1,e.nodeType);$APP.n(f?e.hasAttribute("data-state"):f)&&b.push(e);d+=1}else break;return b},qA=function(a){a=pA(a);for(var b=[],c=a.length,d=0;;)if(d<c)b.push(a[d].getAttribute("data-state")),d+=1;else break;return b},rA=function(a,b){a=pA(a);for(var c=a.length,d=0;;)if(d<c){var e=a[d];if($APP.B.i(b,e.getAttribute("data-state")))return e;d+=1}else return null},sA=function(a,b){for(var c=pA(a),d=c.length,e=0;;)if(e<d){var f=c[e],h=f.getAttribute("data-state");$APP.B.i(h,b)?f.style.display=
13
- "":f.style.display="none";e+=1}else break;$APP.n(b)?a.setAttribute("data-active-state",b):a.removeAttribute("data-active-state");a.__xMorphStackCurrent=b},tA=function(a){var b={};if($APP.n(a)){a=a.querySelectorAll("["+$APP.Q.g("data-morph-id")+"]");for(var c=a.length,d=0;;)if(d<c){var e=a[d],f=e.getAttribute("data-morph-id"),h=e.getBoundingClientRect(),l=window.getComputedStyle(e);b[f]={rect:{x:h.left,y:h.top,w:h.width,h:h.height},br:l.borderRadius,bg:l.backgroundColor,color:l.color,clip:l.clipPath,
14
- text:e.textContent,node:e};d+=1}else break}return b},uA=function(a,b,c){var d=$APP.k(a,"__xMorphStackFilterBlur");a=$APP.k(a,"__xMorphStackFilterMatrix");$APP.n(d)&&d.setAttribute("stdDeviation",""+$APP.Q.g(b));$APP.n(a)&&a.setAttribute("values",Zz(c))},vA=function(a,b){var c=$APP.k(a,"__xMorphStackGooBaseBlur"),d=$APP.k(a,"__xMorphStackGooBaseThreshold");c!=null&&d!=null&&(b=b<=0?1:b<.18?1-b/.18:b<.7?0:b<1?(b-.7)/(1-.7):1,uA(a,c*(1-b),eA(d,1,b)))},xA=function(a){var b=kA(a);b=$APP.J(b);b=$APP.C(b,
15
- $APP.tl);var c=$APP.k(a,"__xMorphStackFilterId");if($APP.n(c))b=c;else{c=wA[0];wA[0]=c+1;c="x-morph-stack-goo-"+$APP.Q.g(c);var d=document.createElementNS("http://www.w3.org/2000/svg","defs"),e=document.createElementNS("http://www.w3.org/2000/svg","filter"),f=document.createElementNS("http://www.w3.org/2000/svg","feGaussianBlur"),h=document.createElementNS("http://www.w3.org/2000/svg","feColorMatrix");e.setAttribute("id",c);e.setAttribute("x","-20%");e.setAttribute("y","-20%");e.setAttribute("width",
16
- "140%");e.setAttribute("height","140%");f.setAttribute("in","SourceGraphic");f.setAttribute("stdDeviation",""+$APP.Q.g(10));f.setAttribute("result","blur");h.setAttribute("in","blur");h.setAttribute("type","matrix");h.setAttribute("values",Zz(18));e.appendChild(f);e.appendChild(h);d.appendChild(e);b.appendChild(d);a.__xMorphStackFilterId=c;a.__xMorphStackFilterBlur=f;a.__xMorphStackFilterMatrix=h;b=c}c=kA(a);c=$APP.J(c);c=$APP.C(c,jA);d=oA(a,"--x-morph-stack-goo-blur",10);e=oA(a,"--x-morph-stack-goo-threshold",
17
- 18);a.__xMorphStackGooBaseBlur=d;a.__xMorphStackGooBaseThreshold=e;uA(a,d,e);c.style.filter="url(#"+$APP.Q.g(b)+")";c.style.webkitFilter="url(#"+$APP.Q.g(b)+")"},yA=function(a){a=$APP.k(a,"__xMorphStackRefs");a=$APP.n(a)?jA.g(a):null;$APP.n(a)&&(a.style.filter="",a.style.webkitFilter="")},zA=function(a){a.style.position="absolute";a.style.margin="0";a.style.boxSizing="border-box";a.style.transformOrigin="top left";a.style.pointerEvents="none"},AA=function(a,b,c){var d=b.y-c.top;a.style.left=""+$APP.Q.g(b.x-
18
- c.left)+"px";a.style.top=""+$APP.Q.g(d)+"px";a.style.width=""+$APP.Q.g(b.w)+"px";a.style.height=""+$APP.Q.g(b.h)+"px"},BA=function(a,b,c,d){function e(va){va=$APP.Hi.i(0,$APP.Ii.i(1,va));var Pa=eA(ea,0,va),eb=eA(H,1,va),sb=eA(K,1,va);D.style.transform="translate("+$APP.Q.g(eA(W,0,va))+"px,"+$APP.Q.g(Pa)+"px) scale("+$APP.Q.g(eb)+","+$APP.Q.g(sb)+")";Pa=D.style;eb=hA(m);sb=hA(q);if($APP.n($APP.n(eb)?$APP.n(sb)?$APP.B.i(eb.length,sb.length):sb:eb)){for(var tb=[],Ib=eb.length,fc=0;;)if(fc<Ib)tb.push(""+
19
- $APP.Q.g(eA(eb[fc],sb[fc],va))+"px"),fc+=1;else break;eb=tb.join(" ")}else eb=va<.5?m:q;Pa.borderRadius=eb;$APP.n($APP.n(r)?v:r)&&(D.style.backgroundColor=gA(r,v,va));$APP.n($APP.n(x)?y:x)&&(D.style.color=gA(x,y,va));A&&(D.style.opacity=""+$APP.Q.g($APP.Hi.i(0,$APP.Ii.i(1,va))));return null}var f=$APP.k(d,"node"),h=$APP.k(d,"rect"),l=$APP.k(c,"rect"),m=$APP.k(c,"br"),q=$APP.k(d,"br"),r=$APP.k(c,"bg"),v=$APP.k(d,"bg"),x=$APP.k(c,"color"),y=$APP.k(d,"color"),A=$APP.M($APP.k(c,"text"),$APP.k(d,"text")),
20
- D=f.cloneNode(!0);c=h.w;d=h.h;var G=l.w,I=l.h,H=c>0?G/c:1,K=d>0?I/d:1,W=l.x-h.x,ea=l.y-h.y;zA(D);AA(D,h,b);a.appendChild(D);f.style.visibility="hidden";e(0);return{t:0,v:0,update:e,finalize:function(){f.style.visibility="";return $APP.n(D.parentNode)?D.parentNode.removeChild(D):null}}},CA=function(a,b,c,d){function e(D){D=$APP.Hi.i(0,$APP.Ii.i(1,D));var G=eA(0,v,D),I=eA(1,x,D),H=eA(1,y,D);A.style.transform="translate("+$APP.Q.g(eA(0,r,D))+"px,"+$APP.Q.g(G)+"px) scale("+$APP.Q.g(I)+","+$APP.Q.g(H)+
21
- ")";A.style.opacity=""+$APP.Q.g($APP.Hi.i(0,1-D));return null}var f=$APP.k(c,"rect");d=$APP.k(d,"rect");var h=f.w,l=f.h,m=d.w,q=d.h,r=d.x-f.x,v=d.y-f.y,x=h>0?m/h:1,y=l>0?q/l:1,A=$APP.k(c,"node").cloneNode(!0);zA(A);AA(A,f,b);a.appendChild(A);e(0);return{t:0,v:0,update:e,finalize:function(){return $APP.n(A.parentNode)?A.parentNode.removeChild(A):null}}},DA=function(a,b,c){var d=$APP.k(c,"rect"),e=$APP.k(c,"node").cloneNode(!0);zA(e);AA(e,d,b);a.appendChild(e);return{t:0,v:0,update:function(f){e.style.opacity=
22
- ""+$APP.Q.g($APP.Hi.i(0,1-f));return null},finalize:function(){return $APP.n(e.parentNode)?e.parentNode.removeChild(e):null}}},EA=function(a){var b=$APP.k(a,"node");b.style.opacity="0";return{t:0,v:0,update:function(c){b.style.opacity=""+$APP.Q.g($APP.Hi.i(0,$APP.Ii.i(1,c)));return null},finalize:function(){return b.style.opacity=""}}},JA=function(a,b,c){a=kA(a);a=$APP.J(a);var d=$APP.C(a,jA),e=d.getBoundingClientRect(),f=Object.keys(b);a=Object.keys(c);f=$APP.Je(f);a=$APP.Je(a);f=$APP.ig(f);a=$APP.ig(a);
23
- a=new $APP.N(null,3,[FA,$APP.zo.i(f,a),GA,HA.i(f,a),IA,HA.i(a,f)],null);var h=FA.g(a),l=GA.g(a);f=IA.g(a);a=[];h=$APP.t(h);for(var m=null,q=0,r=0;;)if(r<q){var v=m.F(null,r),x=$APP.k(b,v);v=$APP.k(c,v);var y=$APP.k(x,"text"),A=$APP.k(v,"text");a.push(BA(d,e,x,v));$APP.M(y,A)&&a.push(CA(d,e,x,v));r+=1}else if(h=$APP.t(h))$APP.Vc(h)?(q=$APP.Db(h),h=$APP.Eb(h),m=q,q=$APP.z(q)):(q=$APP.u(h),m=$APP.k(b,q),q=$APP.k(c,q),r=$APP.k(m,"text"),x=$APP.k(q,"text"),a.push(BA(d,e,m,q)),$APP.M(r,x)&&a.push(CA(d,
24
- e,m,q)),h=$APP.w(h),m=null,q=0),r=0;else break;l=$APP.t(l);h=null;for(q=m=0;;)if(q<m)r=h.F(null,q),a.push(DA(d,e,$APP.k(b,r))),q+=1;else if(l=$APP.t(l))h=l,$APP.Vc(h)?(l=$APP.Db(h),q=$APP.Eb(h),h=l,m=$APP.z(l),l=q):(l=$APP.u(h),a.push(DA(d,e,$APP.k(b,l))),l=$APP.w(h),h=null,m=0),q=0;else break;b=$APP.t(f);d=null;for(f=e=0;;)if(f<e)l=d.F(null,f),a.push(EA($APP.k(c,l))),f+=1;else if(b=$APP.t(b))d=b,$APP.Vc(d)?(b=$APP.Db(d),f=$APP.Eb(d),d=b,e=$APP.z(b),b=f):(b=$APP.u(d),a.push(EA($APP.k(c,b))),b=$APP.w(d),
25
- d=null,e=0),f=0;else break;return a},KA=function(a){if($APP.n(a))for(var b=a.length,c=0;;)if(c<b){var d=a[c].finalize;$APP.n(d)&&(d.H?d.H():d.call(null));c+=1}else break},LA=function(a,b,c){if($APP.B.i(b,$APP.k(a,"__xMorphStackToken"))){b=$APP.k(a,"__xMorphStackEntries");var d=$APP.k(a,"__xMorphStackRaf");$APP.n(d)&&(window.cancelAnimationFrame(d),a.__xMorphStackRaf=null);KA(b);a.__xMorphStackEntries=null;a.__xMorphStackLast=null;yA(a);$APP.n(c)&&(c=$APP.Xi(iA($APP.k(a,"__xMorphStackFrom"),$APP.k(a,
26
- "__xMorphStackTo"))),$APP.P(a,"x-morph-stack-changed",c),a.__xMorphStackFrom=null,a.__xMorphStackTo=null)}return null},MA=function(a){var b=$APP.k(a,"__xMorphStackRaf");$APP.n(b)&&(window.cancelAnimationFrame(b),a.__xMorphStackRaf=null);KA($APP.k(a,"__xMorphStackEntries"));a.__xMorphStackEntries=null;a.__xMorphStackLast=null;yA(a)},OA=function(a,b,c){var d=$APP.k(a,"__xMorphStackCurrent"),e=function(){var m=$APP.k(a,"__xMorphStackModel");return $APP.n(m)?m:nA(a)}(),f=qA(a);if(f.length===0||b==null||
27
- $APP.p($APP.be(function(m){return $APP.B.i(m,b)},f)))return!1;if($APP.B.i(d,b))return!0;var h=$APP.n(d)?rA(a,d):null;f=rA(a,b);c=$APP.Xi(new $APP.N(null,3,[$APP.kj,$APP.n(d)?d:"",$APP.wn,$APP.n(b)?b:"",$APP.Yj,$APP.n(c)?c:"method"],null));if($APP.ch(a,"x-morph-stack-change",c)){MA(a);c=function(){var m=$APP.E(window.matchMedia("(prefers-reduced-motion:reduce)").matches);return m?m:$APP.Y.g(e)}();if($APP.n(c))sA(a,b),queueMicrotask(function(){return $APP.P(a,"x-morph-stack-changed",$APP.Xi(iA(d,b)))});
28
- else{h=tA(h);sA(a,b);$APP.vk.g(lA(a));f=tA(f);f=JA(a,h,f);var l=function(){var m=$APP.k(a,"__xMorphStackToken");return $APP.n(m)?m:0}()+1;a.__xMorphStackToken=l;a.__xMorphStackEntries=f;a.__xMorphStackLast=null;a.__xMorphStackFrom=d;a.__xMorphStackTo=b;$APP.fa(a,"__xMorphStackTimeScale",aA($APP.rm.g(e),$APP.kn.g(e),$APP.Wl.g(e),$APP.Nn.g(e)));Yz($APP.ii.g(e))&&(xA(a),vA(a,0));f.length===0?LA(a,l,!0):(f=window.requestAnimationFrame(function(m){return $APP.B.i(l,$APP.k(a,"__xMorphStackToken"))?NA(a,
29
- m):null}),a.__xMorphStackRaf=f)}return!0}return!1},PA=function(a){lA(a);var b=nA(a);a.__xMorphStackModel=b;a.setAttribute("data-variant",$APP.ii.g(b));var c=qA(a);c=dA($APP.Je($APP.Bc(c)),b);b=$APP.k(a,"__xMorphStackCurrent");b==null?$APP.n(c)&&sA(a,c):$APP.n($APP.n(c)?$APP.M(c,b):c)?OA(a,c,"attribute"):(c=c==null,$APP.n(c?b:c)&&(MA(a),sA(a,null)))},QA=function(a){var b=qA(a);var c=$APP.k(a,"__xMorphStackModel");c=$APP.n(c)?c:nA(a);b=dA($APP.Je($APP.Bc(b)),c);c=$APP.k(a,"__xMorphStackCurrent");b==
30
- null?(MA(a),sA(a,null)):$APP.n($APP.n(c)?rA(a,c)==null:c)?(MA(a),sA(a,b)):c==null?sA(a,b):sA(a,c);return null},RA=function(a){function b(){return QA(a)}var c=lA(a);c=$APP.J(c);$APP.C(c,$APP.tk).addEventListener("slotchange",b);$APP.fa(a,"__xMorphStackHandlers",{slot:b})},SA=function(a){var b=$APP.k(a,"__xMorphStackHandlers"),c=$APP.k(a,"__xMorphStackRefs");$APP.n($APP.n(b)?c:b)&&(c=$APP.tk.g(c),b=$APP.k(b,"slot"),$APP.n(b)&&c.removeEventListener("slotchange",b));a.__xMorphStackHandlers=null},TA=function(a,
31
- b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(c);return d==null?null:parseFloat(d)},set:function(d){return d==null?this.removeAttribute(c):this.setAttribute(c,""+$APP.Q.g(d))},enumerable:!0,configurable:!0})},UA=function(a){$APP.fh(a,"activeState","active-state");Object.defineProperty(a,"activeIndex",{get:function(){var b=this.getAttribute("active-index");return b==null?null:parseInt(b,10)},set:function(b){return b==null?this.removeAttribute("active-index"):this.setAttribute("active-index",
32
- ""+$APP.Q.g(b|0))},enumerable:!0,configurable:!0});TA(a,"stiffness","stiffness");TA(a,"damping","damping");TA(a,"mass","mass");TA(a,"duration","duration");Object.defineProperty(a,"variant",{get:function(){return Xz(this.getAttribute("variant"))},set:function(b){return b==null?this.removeAttribute("variant"):this.setAttribute("variant",""+$APP.Q.g(b))},enumerable:!0,configurable:!0});$APP.dh(a,"disabled","disabled");a.goTo=function(b){b=b!=null?""+$APP.Q.g(b):null;return OA(this,b,"method")};a.next=
33
- function(){var b=qA(this);var c=b.length,d=$APP.k(this,"__xMorphStackCurrent");if(c>0){b:{for(var e=0;;){if(e>=c){d=-1;break b}if($APP.B.i(b[e],d)){d=e;break b}e+=1}d=void 0}b=OA(this,b[$APP.od(d+1,c)],"method")}else b=null;return b};a.prev=function(){var b=qA(this);var c=b.length,d=$APP.k(this,"__xMorphStackCurrent");if(c>0){b:{for(var e=0;;){if(e>=c){d=0;break b}if($APP.B.i(b[e],d)){d=e;break b}e+=1}d=void 0}b=OA(this,b[$APP.od(d-1+c,c)],"method")}else b=null;return b};return a.states=function(){return qA(this)}},
34
- VA=function(a){lA(a);SA(a);RA(a);PA(a);$APP.k(a,"__xMorphStackCurrent")==null&&QA(a);return null},XA=function(a){MA(a);var b=$APP.k(a,"__xMorphStackRefs"),c=$APP.n(b)?jA.g(b):null;$APP.n($APP.n(c)?c.parentNode:c)&&c.parentNode.removeChild(c);$APP.n(b)&&(b=WA.i(WA.i(b,jA),$APP.tl),a.__xMorphStackRefs=b);a.__xMorphStackFilterId=null;a.__xMorphStackFilterBlur=null;a.__xMorphStackFilterMatrix=null;a.__xMorphStackGooBaseBlur=null;a.__xMorphStackGooBaseThreshold=null;SA(a);return null},YA=function(a,b,
35
- c,d){$APP.M(c,d)&&PA(a);return null},$A=function(){return $APP.Yg("x-morph-stack",new $APP.N(null,5,[$APP.Pg,ZA,$APP.Qg,VA,$APP.Rg,XA,$APP.Sg,YA,$APP.Wg,UA],null))},WA=function WA(a){switch(arguments.length){case 1:return WA.g(arguments[0]);case 2:return WA.i(arguments[0],arguments[1]);default:for(var c=[],d=arguments.length,e=0;;)if(e<d)c.push(arguments[e]),e+=1;else break;return WA.B(arguments[0],arguments[1],2<c.length?new $APP.$b(c.slice(2),0,null):null)}};WA.g=function(a){return a};
36
- WA.i=function(a,b){return a==null?null:$APP.Ra(a,b)};WA.B=function(a,b,c){for(;;){if(a==null)return null;a=WA.i(a,b);if($APP.n(c))b=$APP.u(c),c=$APP.w(c);else return a}};WA.I=function(a){var b=$APP.u(a),c=$APP.w(a);a=$APP.u(c);c=$APP.w(c);return this.B(b,a,c)};WA.J=2;
37
- var HA=function HA(a){switch(arguments.length){case 1:return HA.g(arguments[0]);case 2:return HA.i(arguments[0],arguments[1]);default:for(var c=[],d=arguments.length,e=0;;)if(e<d)c.push(arguments[e]),e+=1;else break;return HA.B(arguments[0],arguments[1],2<c.length?new $APP.$b(c.slice(2),0,null):null)}};HA.g=function(a){return a};HA.i=function(a,b){return $APP.z(a)<$APP.z(b)?$APP.wa(function(c,d){return $APP.Zc(b,d)?$APP.Gi.i(c,d):c},a,a):$APP.wa($APP.Gi,a,b)};
38
- HA.B=function(a,b,c){return $APP.wa(HA,a,$APP.ud.i(c,b))};HA.I=function(a){var b=$APP.u(a),c=$APP.w(a);a=$APP.u(c);c=$APP.w(c);return this.B(b,a,c)};HA.J=2;var IA=new $APP.F(null,"entering","entering",-413471949),GA=new $APP.F(null,"leaving","leaving",608616060),FA=new $APP.F(null,"matched","matched",-975207164),mA=new $APP.F(null,"active-state-raw","active-state-raw",-60607051),cA=new $APP.F(null,"active-state","active-state",-1185168001),jA=new $APP.F(null,"ghost-layer","ghost-layer",1707493707);var ZA="active-state active-index stiffness damping mass variant duration disabled".split(" "),Wz=$APP.fg(["liquid","clean","organic"]);$APP.Yd(["x-morph-stack-change",new $APP.N(null,2,[$APP.Z,new $APP.N(null,3,[$APP.kj,$APP.U,$APP.wn,$APP.U,$APP.Yj,$APP.U],null),$APP.Fn,!0],null),"x-morph-stack-changed",new $APP.N(null,2,[$APP.Z,new $APP.N(null,2,[$APP.kj,$APP.U,$APP.wn,$APP.U],null),$APP.Fn,!1],null)]);var wA=[0],NA=function NA(a,b){var d=$APP.k(a,"__xMorphStackToken"),e=$APP.k(a,"__xMorphStackEntries"),f=$APP.k(a,"__xMorphStackLast"),h=function(){var D=$APP.k(a,"__xMorphStackModel");return $APP.n(D)?D:nA(a)}(),l=$APP.Nn.g(h),m=$APP.kn.g(h);h=$APP.Wl.g(h);f=$APP.Hi.i(0,$APP.Ii.i(1/30,function(){var D=$APP.k(a,"__xMorphStackTimeScale");return $APP.n(D)?D:1}()*($APP.n(f)?(b-f)/1E3:1/60)));a.__xMorphStackLast=b;if($APP.n($APP.n(e)?e.length:e)){b=[!0];for(var q=[1],r=e.length,v=0;;)if(v<r){var x=e[v],
39
- y=bA(x.t,x.v,f,l,m,h),A=y[0];y=y[1];x.t=A;x.v=y;x=x.update;x.g?x.g(A):x.call(null,A);A<q[0]&&(q[0]=A);Math.abs(A-1)<.001&&Math.abs(y)<.01||(b[0]=!1);v+=1}else break;vA(a,q[0]);$APP.n(b[0])?LA.l?LA.l(a,d,!0):LA.call(null,a,d,!0):(e=window.requestAnimationFrame(function(D){return $APP.B.i(d,$APP.k(a,"__xMorphStackToken"))?NA.i?NA.i(a,D):NA.call(null,a,D):null}),a.__xMorphStackRaf=e)}return null};$APP.ca("baredom.exports.x_morph_stack.init",$A);export const init=$A;
9
+ d.setAttribute("part","viewport");e.setAttribute("name","state");d.appendChild(e);b.appendChild(c);b.appendChild(d);a.__xMorphStackRefs=new $APP.O(null,3,[$APP.jj,b,$APP.wn,d,$APP.un,e],null);return $APP.k(a,"__xMorphStackRefs")},oD=function(a){a=new $APP.O(null,8,[nD,a.getAttribute("active-state"),$APP.Ep,a.getAttribute("active-index"),$APP.zq,a.getAttribute("stiffness"),$APP.ir,a.getAttribute("damping"),$APP.Ln,a.getAttribute("mass"),$APP.Lp,a.getAttribute("variant"),$APP.dn,a.getAttribute("duration"),
10
+ $APP.vi,a.hasAttribute("disabled")],null);a=$APP.G(a);var b=$APP.C(a,nD),c=$APP.C(a,$APP.Ep),d=$APP.C(a,$APP.zq),e=$APP.C(a,$APP.ir),f=$APP.C(a,$APP.Ln),h=$APP.C(a,$APP.Lp),l=$APP.C(a,$APP.dn);a=$APP.C(a,$APP.vi);b=typeof b==="string"&&$APP.I("",b.trim())?b.trim():null;a:{if(typeof c==="string"&&(c=c.trim(),$APP.I(c,""))){c=parseInt(c,10);c=typeof c==="number"&&$APP.p(isNaN(c))&&c>=0?c:null;break a}c=null}d=aD(d,170,10,500);e=aD(e,26,1,100);f=aD(f,1,.1,10);h=YC(h);a:{if(typeof l==="string"&&(l=l.trim(),
11
+ $APP.I(l,""))){l=parseFloat(l);l=typeof l==="number"&&$APP.p(isNaN(l))&&l>0?l:null;break a}l=null}return new $APP.O(null,8,[dD,b,$APP.ho,c,$APP.hq,d,$APP.Zo,e,$APP.Jq,f,$APP.nk,h,$APP.wp,l,$APP.Bi,$APP.D(a)],null)},pD=function(a,b,c){a=window.getComputedStyle(a).getPropertyValue(b);return typeof a==="string"&&$APP.I("",a.trim())?(a=parseFloat(a.trim()),$APP.n(isNaN(a))?c:a):c},qD=function(a){a=mD(a);a=$APP.G(a);a=$APP.C(a,$APP.un).assignedElements();for(var b=[],c=a.length,d=0;;)if(d<c){var e=a[d],
12
+ f=$APP.A.j(1,e.nodeType);$APP.n(f?e.hasAttribute("data-state"):f)&&b.push(e);d+=1}else break;return b},rD=function(a){a=qD(a);for(var b=[],c=a.length,d=0;;)if(d<c)b.push(a[d].getAttribute("data-state")),d+=1;else break;return b},sD=function(a,b){a=qD(a);for(var c=a.length,d=0;;)if(d<c){var e=a[d];if($APP.A.j(b,e.getAttribute("data-state")))return e;d+=1}else return null},tD=function(a,b){for(var c=qD(a),d=c.length,e=0;;)if(e<d){var f=c[e],h=f.getAttribute("data-state");$APP.A.j(h,b)?f.style.display=
13
+ "":f.style.display="none";e+=1}else break;$APP.n(b)?$APP.S(a,"data-active-state",b):$APP.T(a,"data-active-state");a.__xMorphStackCurrent=b},uD=function(a){var b={};if($APP.n(a)){a=a.querySelectorAll("["+$APP.V.i("data-morph-id")+"]");for(var c=a.length,d=0;;)if(d<c){var e=a[d],f=e.getAttribute("data-morph-id"),h=e.getBoundingClientRect(),l=window.getComputedStyle(e);b[f]={rect:{x:h.left,y:h.top,w:h.width,h:h.height},br:l.borderRadius,bg:l.backgroundColor,color:l.color,clip:l.clipPath,text:e.textContent,
14
+ node:e};d+=1}else break}return b},vD=function(a,b,c){var d=$APP.k(a,"__xMorphStackFilterBlur");a=$APP.k(a,"__xMorphStackFilterMatrix");$APP.n(d)&&d.setAttribute("stdDeviation",""+$APP.V.i(b));$APP.n(a)&&a.setAttribute("values",$C(c))},wD=function(a,b){var c=$APP.k(a,"__xMorphStackGooBaseBlur"),d=$APP.k(a,"__xMorphStackGooBaseThreshold");c!=null&&d!=null&&(b=b<=0?1:b<.18?1-b/.18:b<.7?0:b<1?(b-.7)/(1-.7):1,vD(a,c*(1-b),fD(d,1,b)))},yD=function(a){var b=lD(a);b=$APP.G(b);b=$APP.C(b,$APP.po);var c=$APP.k(a,
15
+ "__xMorphStackFilterId");if($APP.n(c))b=c;else{c=xD[0];xD[0]=c+1;c="x-morph-stack-goo-"+$APP.V.i(c);var d=document.createElementNS("http://www.w3.org/2000/svg","defs"),e=document.createElementNS("http://www.w3.org/2000/svg","filter"),f=document.createElementNS("http://www.w3.org/2000/svg","feGaussianBlur"),h=document.createElementNS("http://www.w3.org/2000/svg","feColorMatrix");e.setAttribute("id",c);e.setAttribute("x","-20%");e.setAttribute("y","-20%");e.setAttribute("width","140%");e.setAttribute("height",
16
+ "140%");f.setAttribute("in","SourceGraphic");f.setAttribute("stdDeviation",""+$APP.V.i(10));f.setAttribute("result","blur");h.setAttribute("in","blur");h.setAttribute("type","matrix");h.setAttribute("values",$C(18));e.appendChild(f);e.appendChild(h);d.appendChild(e);b.appendChild(d);a.__xMorphStackFilterId=c;a.__xMorphStackFilterBlur=f;a.__xMorphStackFilterMatrix=h;b=c}c=lD(a);c=$APP.G(c);c=$APP.C(c,kD);d=pD(a,"--x-morph-stack-goo-blur",10);e=pD(a,"--x-morph-stack-goo-threshold",18);a.__xMorphStackGooBaseBlur=
17
+ d;a.__xMorphStackGooBaseThreshold=e;vD(a,d,e);c.style.filter="url(#"+$APP.V.i(b)+")";c.style.webkitFilter="url(#"+$APP.V.i(b)+")"},zD=function(a){a=$APP.k(a,"__xMorphStackRefs");a=$APP.n(a)?kD.i(a):null;$APP.n(a)&&(a.style.filter="",a.style.webkitFilter="")},AD=function(a){a.style.position="absolute";a.style.margin="0";a.style.boxSizing="border-box";a.style.transformOrigin="top left";a.style.pointerEvents="none"},BD=function(a,b,c){var d=b.y-c.top;a.style.left=""+$APP.V.i(b.x-c.left)+"px";a.style.top=
18
+ ""+$APP.V.i(d)+"px";a.style.width=""+$APP.V.i(b.w)+"px";a.style.height=""+$APP.V.i(b.h)+"px"},CD=function(a,b,c,d){function e(Ea){Ea=$APP.Gl.j(0,$APP.Hl.j(1,Ea));var Na=fD(la,0,Ea),Za=fD(J,1,Ea),Eb=fD(P,1,Ea);E.style.transform="translate("+$APP.V.i(fD(ea,0,Ea))+"px,"+$APP.V.i(Na)+"px) scale("+$APP.V.i(Za)+","+$APP.V.i(Eb)+")";Na=E.style;Za=iD(m);Eb=iD(q);if($APP.n($APP.n(Za)?$APP.n(Eb)?$APP.A.j(Za.length,Eb.length):Eb:Za)){for(var Cb=[],Kb=Za.length,Dd=0;;)if(Dd<Kb)Cb.push(""+$APP.V.i(fD(Za[Dd],Eb[Dd],
19
+ Ea))+"px"),Dd+=1;else break;Za=Cb.join(" ")}else Za=Ea<.5?m:q;Na.borderRadius=Za;$APP.n($APP.n(r)?v:r)&&(E.style.backgroundColor=hD(r,v,Ea));$APP.n($APP.n(x)?z:x)&&(E.style.color=hD(x,z,Ea));B&&(E.style.opacity=""+$APP.V.i($APP.Gl.j(0,$APP.Hl.j(1,Ea))));return null}var f=$APP.k(d,"node"),h=$APP.k(d,"rect"),l=$APP.k(c,"rect"),m=$APP.k(c,"br"),q=$APP.k(d,"br"),r=$APP.k(c,"bg"),v=$APP.k(d,"bg"),x=$APP.k(c,"color"),z=$APP.k(d,"color"),B=$APP.I($APP.k(c,"text"),$APP.k(d,"text")),E=f.cloneNode(!0);c=h.w;
20
+ d=h.h;var H=l.w,K=l.h,J=c>0?H/c:1,P=d>0?K/d:1,ea=l.x-h.x,la=l.y-h.y;AD(E);BD(E,h,b);a.appendChild(E);f.style.visibility="hidden";e(0);return{t:0,v:0,update:e,finalize:function(){f.style.visibility="";return $APP.n(E.parentNode)?E.parentNode.removeChild(E):null}}},DD=function(a,b,c,d){function e(E){E=$APP.Gl.j(0,$APP.Hl.j(1,E));var H=fD(0,v,E),K=fD(1,x,E),J=fD(1,z,E);B.style.transform="translate("+$APP.V.i(fD(0,r,E))+"px,"+$APP.V.i(H)+"px) scale("+$APP.V.i(K)+","+$APP.V.i(J)+")";B.style.opacity=""+
21
+ $APP.V.i($APP.Gl.j(0,1-E));return null}var f=$APP.k(c,"rect");d=$APP.k(d,"rect");var h=f.w,l=f.h,m=d.w,q=d.h,r=d.x-f.x,v=d.y-f.y,x=h>0?m/h:1,z=l>0?q/l:1,B=$APP.k(c,"node").cloneNode(!0);AD(B);BD(B,f,b);a.appendChild(B);e(0);return{t:0,v:0,update:e,finalize:function(){return $APP.n(B.parentNode)?B.parentNode.removeChild(B):null}}},ED=function(a,b,c){var d=$APP.k(c,"rect"),e=$APP.k(c,"node").cloneNode(!0);AD(e);BD(e,d,b);a.appendChild(e);return{t:0,v:0,update:function(f){e.style.opacity=""+$APP.V.i($APP.Gl.j(0,
22
+ 1-f));return null},finalize:function(){return $APP.n(e.parentNode)?e.parentNode.removeChild(e):null}}},FD=function(a){var b=$APP.k(a,"node");b.style.opacity="0";return{t:0,v:0,update:function(c){b.style.opacity=""+$APP.V.i($APP.Gl.j(0,$APP.Hl.j(1,c)));return null},finalize:function(){return b.style.opacity=""}}},KD=function(a,b,c){a=lD(a);a=$APP.G(a);var d=$APP.C(a,kD),e=d.getBoundingClientRect(),f=Object.keys(b);a=Object.keys(c);f=$APP.Qe(f);a=$APP.Qe(a);f=$APP.vg(f);a=$APP.vg(a);a=new $APP.O(null,
23
+ 3,[GD,$APP.wr.j(f,a),HD,ID.j(f,a),JD,ID.j(a,f)],null);var h=GD.i(a),l=HD.i(a);f=JD.i(a);a=[];h=$APP.t(h);for(var m=null,q=0,r=0;;)if(r<q){var v=m.F(null,r),x=$APP.k(b,v);v=$APP.k(c,v);var z=$APP.k(x,"text"),B=$APP.k(v,"text");a.push(CD(d,e,x,v));$APP.I(z,B)&&a.push(DD(d,e,x,v));r+=1}else if(h=$APP.t(h))$APP.Wc(h)?(q=$APP.Ab(h),h=$APP.Bb(h),m=q,q=$APP.y(q)):(q=$APP.u(h),m=$APP.k(b,q),q=$APP.k(c,q),r=$APP.k(m,"text"),x=$APP.k(q,"text"),a.push(CD(d,e,m,q)),$APP.I(r,x)&&a.push(DD(d,e,m,q)),h=$APP.w(h),
24
+ m=null,q=0),r=0;else break;l=$APP.t(l);h=null;for(q=m=0;;)if(q<m)r=h.F(null,q),a.push(ED(d,e,$APP.k(b,r))),q+=1;else if(l=$APP.t(l))h=l,$APP.Wc(h)?(l=$APP.Ab(h),q=$APP.Bb(h),h=l,m=$APP.y(l),l=q):(l=$APP.u(h),a.push(ED(d,e,$APP.k(b,l))),l=$APP.w(h),h=null,m=0),q=0;else break;b=$APP.t(f);d=null;for(f=e=0;;)if(f<e)l=d.F(null,f),a.push(FD($APP.k(c,l))),f+=1;else if(b=$APP.t(b))d=b,$APP.Wc(d)?(b=$APP.Ab(d),f=$APP.Bb(d),d=b,e=$APP.y(b),b=f):(b=$APP.u(d),a.push(FD($APP.k(c,b))),b=$APP.w(d),d=null,e=0),f=
25
+ 0;else break;return a},LD=function(a){if($APP.n(a))for(var b=a.length,c=0;;)if(c<b){var d=a[c].finalize;$APP.n(d)&&(d.H?d.H():d.call(null));c+=1}else break},MD=function(a,b,c){if($APP.A.j(b,$APP.k(a,"__xMorphStackToken"))){b=$APP.k(a,"__xMorphStackEntries");var d=$APP.k(a,"__xMorphStackRaf");$APP.n(d)&&(window.cancelAnimationFrame(d),a.__xMorphStackRaf=null);LD(b);a.__xMorphStackEntries=null;a.__xMorphStackLast=null;zD(a);$APP.n(c)&&(c=$APP.$l(jD($APP.k(a,"__xMorphStackFrom"),$APP.k(a,"__xMorphStackTo"))),
26
+ $APP.Nh(a,"x-morph-stack-changed",c),a.__xMorphStackFrom=null,a.__xMorphStackTo=null)}return null},ND=function(a){var b=$APP.k(a,"__xMorphStackRaf");$APP.n(b)&&(window.cancelAnimationFrame(b),a.__xMorphStackRaf=null);LD($APP.k(a,"__xMorphStackEntries"));a.__xMorphStackEntries=null;a.__xMorphStackLast=null;zD(a)},PD=function(a,b,c){var d=$APP.k(a,"__xMorphStackCurrent"),e=function(){var m=$APP.k(a,"__xMorphStackModel");return $APP.n(m)?m:oD(a)}(),f=rD(a);if(f.length===0||b==null||$APP.p($APP.ge(function(m){return $APP.A.j(m,
27
+ b)},f)))return!1;if($APP.A.j(d,b))return!0;var h=$APP.n(d)?sD(a,d):null;f=sD(a,b);c=$APP.$l(new $APP.O(null,3,[$APP.nm,$APP.n(d)?d:"",$APP.rq,$APP.n(b)?b:"",$APP.Ym,$APP.n(c)?c:"method"],null));if($APP.Ph(a,"x-morph-stack-change",c)){ND(a);c=function(){var m=$APP.D(window.matchMedia("(prefers-reduced-motion:reduce)").matches);return m?m:$APP.Bi.i(e)}();if($APP.n(c))tD(a,b),queueMicrotask(function(){return $APP.Nh(a,"x-morph-stack-changed",$APP.$l(jD(d,b)))});else{h=uD(h);tD(a,b);$APP.wn.i(mD(a));
28
+ f=uD(f);f=KD(a,h,f);var l=function(){var m=$APP.k(a,"__xMorphStackToken");return $APP.n(m)?m:0}()+1;a.__xMorphStackToken=l;a.__xMorphStackEntries=f;a.__xMorphStackLast=null;a.__xMorphStackFrom=d;a.__xMorphStackTo=b;$APP.ja(a,"__xMorphStackTimeScale",bD($APP.wp.i(e),$APP.hq.i(e),$APP.Zo.i(e),$APP.Jq.i(e)));ZC($APP.nk.i(e))&&(yD(a),wD(a,0));f.length===0?MD(a,l,!0):(f=window.requestAnimationFrame(function(m){return $APP.A.j(l,$APP.k(a,"__xMorphStackToken"))?OD(a,m):null}),a.__xMorphStackRaf=f)}return!0}return!1},
29
+ QD=function(a){mD(a);var b=oD(a);a.__xMorphStackModel=b;$APP.S(a,"data-variant",$APP.nk.i(b));var c=rD(a);c=eD($APP.Qe($APP.zc(c)),b);b=$APP.k(a,"__xMorphStackCurrent");b==null?$APP.n(c)&&tD(a,c):$APP.n($APP.n(c)?$APP.I(c,b):c)?PD(a,c,"attribute"):(c=c==null,$APP.n(c?b:c)&&(ND(a),tD(a,null)))},RD=function(a){var b=rD(a);var c=$APP.k(a,"__xMorphStackModel");c=$APP.n(c)?c:oD(a);b=eD($APP.Qe($APP.zc(b)),c);c=$APP.k(a,"__xMorphStackCurrent");b==null?(ND(a),tD(a,null)):$APP.n($APP.n(c)?sD(a,c)==null:c)?
30
+ (ND(a),tD(a,b)):c==null?tD(a,b):tD(a,c);return null},SD=function(a){function b(){return RD(a)}var c=mD(a);c=$APP.G(c);$APP.C(c,$APP.un).addEventListener("slotchange",b);$APP.ja(a,"__xMorphStackHandlers",{slot:b})},TD=function(a){var b=$APP.k(a,"__xMorphStackHandlers"),c=$APP.k(a,"__xMorphStackRefs");$APP.n($APP.n(b)?c:b)&&(c=$APP.un.i(c),b=$APP.k(b,"slot"),$APP.n(b)&&c.removeEventListener("slotchange",b));a.__xMorphStackHandlers=null},UD=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=
31
+ this.getAttribute(c);return d==null?null:parseFloat(d)},set:function(d){return d==null?this.removeAttribute(c):this.setAttribute(c,""+$APP.V.i(d))},enumerable:!0,configurable:!0})},VD=function(a){$APP.Uh(a,"activeState","active-state");Object.defineProperty(a,"activeIndex",{get:function(){var b=this.getAttribute("active-index");return b==null?null:parseInt(b,10)},set:function(b){return b==null?this.removeAttribute("active-index"):this.setAttribute("active-index",""+$APP.V.i(b|0))},enumerable:!0,configurable:!0});
32
+ UD(a,"stiffness","stiffness");UD(a,"damping","damping");UD(a,"mass","mass");UD(a,"duration","duration");Object.defineProperty(a,"variant",{get:function(){return YC(this.getAttribute("variant"))},set:function(b){return b==null?this.removeAttribute("variant"):this.setAttribute("variant",""+$APP.V.i(b))},enumerable:!0,configurable:!0});$APP.Sh(a,"disabled","disabled");a.goTo=function(b){b=b!=null?""+$APP.V.i(b):null;return PD(this,b,"method")};a.next=function(){var b=rD(this);var c=b.length,d=$APP.k(this,
33
+ "__xMorphStackCurrent");if(c>0){b:{for(var e=0;;){if(e>=c){d=-1;break b}if($APP.A.j(b[e],d)){d=e;break b}e+=1}d=void 0}b=PD(this,b[$APP.qd(d+1,c)],"method")}else b=null;return b};a.prev=function(){var b=rD(this);var c=b.length,d=$APP.k(this,"__xMorphStackCurrent");if(c>0){b:{for(var e=0;;){if(e>=c){d=0;break b}if($APP.A.j(b[e],d)){d=e;break b}e+=1}d=void 0}b=PD(this,b[$APP.qd(d-1+c,c)],"method")}else b=null;return b};return a.states=function(){return rD(this)}},WD=function(a){mD(a);TD(a);SD(a);QD(a);
34
+ $APP.k(a,"__xMorphStackCurrent")==null&&RD(a);return null},XD=function(a){ND(a);var b=$APP.k(a,"__xMorphStackRefs"),c=$APP.n(b)?kD.i(b):null;$APP.n($APP.n(c)?c.parentNode:c)&&c.parentNode.removeChild(c);$APP.n(b)&&(b=$APP.El.j($APP.El.j(b,kD),$APP.po),a.__xMorphStackRefs=b);a.__xMorphStackFilterId=null;a.__xMorphStackFilterBlur=null;a.__xMorphStackFilterMatrix=null;a.__xMorphStackGooBaseBlur=null;a.__xMorphStackGooBaseThreshold=null;TD(a);return null},YD=function(a,b,c,d){$APP.I(c,d)&&QD(a);return null},
35
+ $D=function(){return $APP.Ah("x-morph-stack",new $APP.O(null,5,[$APP.qh,ZD,$APP.oh,WD,$APP.lh,XD,$APP.kh,YD,$APP.ph,VD],null))},ID=function ID(a){switch(arguments.length){case 1:return ID.i(arguments[0]);case 2:return ID.j(arguments[0],arguments[1]);default:for(var c=[],d=arguments.length,e=0;;)if(e<d)c.push(arguments[e]),e+=1;else break;return ID.B(arguments[0],arguments[1],2<c.length?new $APP.Yb(c.slice(2),0,null):null)}};ID.i=function(a){return a};
36
+ ID.j=function(a,b){return $APP.y(a)<$APP.y(b)?$APP.xa(function(c,d){return $APP.$c(b,d)?$APP.Fl.j(c,d):c},a,a):$APP.xa($APP.Fl,a,b)};ID.B=function(a,b,c){return $APP.xa(ID,a,$APP.wd.j(c,b))};ID.K=function(a){var b=$APP.u(a),c=$APP.w(a);a=$APP.u(c);c=$APP.w(c);return this.B(b,a,c)};ID.M=2;
37
+ var JD=new $APP.F(null,"entering","entering",-413471949),HD=new $APP.F(null,"leaving","leaving",608616060),GD=new $APP.F(null,"matched","matched",-975207164),nD=new $APP.F(null,"active-state-raw","active-state-raw",-60607051),dD=new $APP.F(null,"active-state","active-state",-1185168001),kD=new $APP.F(null,"ghost-layer","ghost-layer",1707493707);var ZD="active-state active-index stiffness damping mass variant duration disabled".split(" "),XC=$APP.rg(["liquid","clean","organic"]);$APP.ce(["x-morph-stack-change",new $APP.O(null,2,[$APP.U,new $APP.O(null,3,[$APP.nm,$APP.X,$APP.rq,$APP.X,$APP.Ym,$APP.X],null),$APP.Aq,!0],null),"x-morph-stack-changed",new $APP.O(null,2,[$APP.U,new $APP.O(null,2,[$APP.nm,$APP.X,$APP.rq,$APP.X],null),$APP.Aq,!1],null)]);var xD=[0],OD=function OD(a,b){var d=$APP.k(a,"__xMorphStackToken"),e=$APP.k(a,"__xMorphStackEntries"),f=$APP.k(a,"__xMorphStackLast"),h=function(){var E=$APP.k(a,"__xMorphStackModel");return $APP.n(E)?E:oD(a)}(),l=$APP.Jq.i(h),m=$APP.hq.i(h);h=$APP.Zo.i(h);f=$APP.Gl.j(0,$APP.Hl.j(1/30,function(){var E=$APP.k(a,"__xMorphStackTimeScale");return $APP.n(E)?E:1}()*($APP.n(f)?(b-f)/1E3:1/60)));a.__xMorphStackLast=b;if($APP.n($APP.n(e)?e.length:e)){b=[!0];for(var q=[1],r=e.length,v=0;;)if(v<r){var x=e[v],
38
+ z=cD(x.t,x.v,f,l,m,h),B=z[0];z=z[1];x.t=B;x.v=z;x=x.update;x.i?x.i(B):x.call(null,B);B<q[0]&&(q[0]=B);Math.abs(B-1)<.001&&Math.abs(z)<.01||(b[0]=!1);v+=1}else break;wD(a,q[0]);$APP.n(b[0])?MD.m?MD.m(a,d,!0):MD.call(null,a,d,!0):(e=window.requestAnimationFrame(function(E){return $APP.A.j(d,$APP.k(a,"__xMorphStackToken"))?OD.j?OD.j(a,E):OD.call(null,a,E):null}),a.__xMorphStackRaf=e)}return null};$APP.ha("baredom.exports.x_morph_stack.init",$D);export const init=$D;