@vanelsas/baredom 1.0.0 → 1.1.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 (70) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/README.md +11 -3
  3. package/dist/base.js +368 -349
  4. package/dist/x-alert.js +18 -18
  5. package/dist/x-avatar-group.js +11 -11
  6. package/dist/x-avatar.js +16 -17
  7. package/dist/x-badge.js +11 -11
  8. package/dist/x-breadcrumbs.js +14 -14
  9. package/dist/x-button.js +16 -16
  10. package/dist/x-cancel-dialogue.js +17 -17
  11. package/dist/x-card.js +7 -7
  12. package/dist/x-chart.js +47 -47
  13. package/dist/x-checkbox.js +11 -11
  14. package/dist/x-chip.js +8 -8
  15. package/dist/x-collapse.js +11 -11
  16. package/dist/x-command-palette.js +31 -31
  17. package/dist/x-container.js +6 -6
  18. package/dist/x-context-menu.js +19 -20
  19. package/dist/x-copy.js +23 -23
  20. package/dist/x-currency-field.js +23 -23
  21. package/dist/x-date-picker.js +39 -39
  22. package/dist/x-divider.js +12 -12
  23. package/dist/x-drawer.js +12 -12
  24. package/dist/x-dropdown.js +10 -10
  25. package/dist/x-fieldset.js +6 -6
  26. package/dist/x-file-download.js +7 -7
  27. package/dist/x-form-field.js +17 -17
  28. package/dist/x-form.js +9 -9
  29. package/dist/x-gaussian-blur.js +33 -0
  30. package/dist/x-grid.js +7 -7
  31. package/dist/x-kinetic-typography.js +62 -0
  32. package/dist/x-menu-item.js +10 -10
  33. package/dist/x-menu.js +10 -10
  34. package/dist/x-modal.js +13 -13
  35. package/dist/x-navbar.js +13 -13
  36. package/dist/x-notification-center.js +10 -10
  37. package/dist/x-organic-divider.js +20 -0
  38. package/dist/x-organic-shape.js +15 -0
  39. package/dist/x-pagination.js +16 -16
  40. package/dist/x-popover.js +15 -15
  41. package/dist/x-progress-circle.js +10 -10
  42. package/dist/x-progress.js +11 -11
  43. package/dist/x-radio.js +11 -11
  44. package/dist/x-ripple-effect.js +14 -0
  45. package/dist/x-scroll-parallax.js +20 -0
  46. package/dist/x-scroll-story.js +38 -0
  47. package/dist/x-scroll-timeline.js +51 -0
  48. package/dist/x-scroll.js +43 -0
  49. package/dist/x-search-field.js +14 -14
  50. package/dist/x-select.js +9 -9
  51. package/dist/x-sidebar.js +16 -16
  52. package/dist/x-skeleton.js +6 -7
  53. package/dist/x-slider.js +16 -16
  54. package/dist/x-spacer.js +5 -5
  55. package/dist/x-spinner.js +5 -5
  56. package/dist/x-stat.js +11 -11
  57. package/dist/x-stepper.js +16 -16
  58. package/dist/x-switch.js +10 -10
  59. package/dist/x-tab.js +7 -7
  60. package/dist/x-table-cell.js +21 -21
  61. package/dist/x-table-row.js +10 -10
  62. package/dist/x-table.js +14 -14
  63. package/dist/x-tabs.js +11 -12
  64. package/dist/x-text-area.js +19 -19
  65. package/dist/x-timeline-item.js +23 -23
  66. package/dist/x-timeline.js +9 -9
  67. package/dist/x-toast.js +23 -23
  68. package/dist/x-toaster.js +8 -8
  69. package/dist/x-typography.js +11 -0
  70. package/package.json +43 -2
package/dist/x-alert.js CHANGED
@@ -1,20 +1,20 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var cq=function(a){a=$APP.I($APP.$i,a);return $APP.n(a)?a:"info"},dq=function(a){return a==null?!0:$APP.O((""+$APP.T.g(a)).trim().toLowerCase(),"false")},eq=function(a){return typeof a==="string"?(a=parseInt(a.trim(),10),typeof a==="number"&&$APP.p(isNaN(a))&&a>0?a:null):null},fq=function(a){var b=$APP.N(a);a=$APP.I(b,$APP.oh);b=$APP.I(b,$APP.V);return $APP.n(a)?$APP.p(b):a},gq=function(a,b){var c=$APP.N(a);a=$APP.I(c,$APP.Z);c=$APP.I(c,$APP.Fh);return new $APP.Q(null,3,[$APP.Z,cq(a),$APP.qh,b,$APP.Fh,
3
- c],null)},iq=function(a){var b=$APP.l(a,"__xAlertRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("span"),g=document.createElement("slot"),h=document.createElement("span"),k=document.createElement("span"),m=document.createElement("button"),q=document.createElement("span");c.textContent=":host{display:block;color-scheme:light dark;--x-alert-radius:10px;--x-alert-padding-y:10px;--x-alert-padding-x:12px;--x-alert-gap:10px;--x-alert-font-size:0.875rem;--x-alert-motion-fast:120ms;--x-alert-motion-ease:cubic-bezier(0.2,0,0,1);--x-alert-enter-duration:140ms;--x-alert-exit-duration:160ms;--x-alert-press-scale:0.98;--x-alert-disabled-opacity:0.55;--x-alert-focus-ring:rgba(0,0,0,0.6);--x-alert-dismiss-color:rgba(0,0,0,0.62);--x-alert-dismiss-hover-bg:rgba(0,0,0,0.06);--x-alert-info-bg:rgba(0,102,204,0.08);--x-alert-info-border:rgba(0,102,204,0.35);--x-alert-info-color:rgba(0,60,120,0.95);--x-alert-success-bg:rgba(16,140,72,0.10);--x-alert-success-border:rgba(16,140,72,0.35);--x-alert-success-color:rgba(10,90,46,0.95);--x-alert-warning-bg:rgba(204,120,0,0.12);--x-alert-warning-border:rgba(204,120,0,0.45);--x-alert-warning-color:rgba(120,70,0,0.95);--x-alert-error-bg:rgba(190,20,40,0.10);--x-alert-error-border:rgba(190,20,40,0.45);--x-alert-error-color:rgba(120,10,20,0.95);--x-alert-bg:transparent;--x-alert-border-color:transparent;--x-alert-color:inherit;}@media (prefers-color-scheme:dark){:host{--x-alert-focus-ring:rgba(255,255,255,0.75);--x-alert-dismiss-color:rgba(255,255,255,0.75);--x-alert-dismiss-hover-bg:rgba(255,255,255,0.14);--x-alert-info-bg:rgba(80,160,255,0.18);--x-alert-info-border:rgba(80,160,255,0.42);--x-alert-info-color:rgba(230,245,255,0.92);--x-alert-success-bg:rgba(60,210,120,0.18);--x-alert-success-border:rgba(60,210,120,0.42);--x-alert-success-color:rgba(235,255,245,0.92);--x-alert-warning-bg:rgba(255,190,90,0.20);--x-alert-warning-border:rgba(255,190,90,0.46);--x-alert-warning-color:rgba(255,248,235,0.92);--x-alert-error-bg:rgba(255,90,110,0.18);--x-alert-error-border:rgba(255,90,110,0.46);--x-alert-error-color:rgba(255,235,238,0.92);}}:host([data-type\x3d'info']){--x-alert-bg:var(--x-alert-info-bg);--x-alert-border-color:var(--x-alert-info-border);--x-alert-color:var(--x-alert-info-color);}:host([data-type\x3d'success']){--x-alert-bg:var(--x-alert-success-bg);--x-alert-border-color:var(--x-alert-success-border);--x-alert-color:var(--x-alert-success-color);}:host([data-type\x3d'warning']){--x-alert-bg:var(--x-alert-warning-bg);--x-alert-border-color:var(--x-alert-warning-border);--x-alert-color:var(--x-alert-warning-color);}:host([data-type\x3d'error']){--x-alert-bg:var(--x-alert-error-bg);--x-alert-border-color:var(--x-alert-error-border);--x-alert-color:var(--x-alert-error-color);}[part\x3dcontainer]{display:flex;align-items:flex-start;gap:var(--x-alert-gap);padding:var(--x-alert-padding-y) var(--x-alert-padding-x);border:1px solid var(--x-alert-border-color);border-radius:var(--x-alert-radius);background:var(--x-alert-bg);color:var(--x-alert-color);font-size:var(--x-alert-font-size);transition:background var(--x-alert-motion-fast) var(--x-alert-motion-ease),border-color var(--x-alert-motion-fast) var(--x-alert-motion-ease),color var(--x-alert-motion-fast) var(--x-alert-motion-ease),opacity var(--x-alert-motion-fast) var(--x-alert-motion-ease),transform var(--x-alert-motion-fast) var(--x-alert-motion-ease);}[part\x3dicon]{flex:0 0 auto;line-height:1;margin-top:0.05em;}slot[name\x3dicon]::slotted(*){display:block;}[part\x3dtext]{flex:1 1 auto;line-height:1.25;min-width:0;overflow-wrap:anywhere;}[part\x3ddismiss]{flex:0 0 auto;appearance:none;border:0;background:transparent;color:var(--x-alert-dismiss-color);width:1.5em;height:1.5em;padding:0;margin:0;border-radius:999px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;transition:background var(--x-alert-motion-fast) var(--x-alert-motion-ease),transform var(--x-alert-motion-fast) var(--x-alert-motion-ease);}:host(:not([disabled])) [part\x3ddismiss]:hover{background:var(--x-alert-dismiss-hover-bg);}:host(:not([disabled])) [part\x3ddismiss]:active{transform:scale(var(--x-alert-press-scale));}[part\x3ddismiss]:focus{outline:none;}:host(:not([disabled])) [part\x3ddismiss]:focus-visible{outline:2px solid var(--x-alert-focus-ring);outline-offset:2px;}:host([disabled]){opacity:var(--x-alert-disabled-opacity);}:host([disabled]) [part\x3ddismiss]{cursor:default;pointer-events:none;}:host([data-entering]) [part\x3dcontainer]{animation:x-alert-enter var(--x-alert-enter-duration) var(--x-alert-motion-ease) both;}@keyframes x-alert-enter{from{opacity:0;transform:translateY(4px);}to{opacity:1;transform:translateY(0);}}:host([data-exiting]) [part\x3dcontainer]{animation:x-alert-exit var(--x-alert-exit-duration) var(--x-alert-motion-ease) forwards;}@keyframes x-alert-exit{from{opacity:1;transform:translateY(0);}to{opacity:0;transform:translateY(4px);}}@media (prefers-reduced-motion:reduce){[part\x3dcontainer],[part\x3ddismiss]{transition:none !important;}:host([data-entering]) [part\x3dcontainer],:host([data-exiting]) [part\x3dcontainer]{animation:none !important;}}";
4
- d.setAttribute("part","container");e.setAttribute("part","icon");e.setAttribute("aria-hidden","true");g.setAttribute("name","icon");h.setAttribute("part","default-icon");g.appendChild(h);e.appendChild(g);k.setAttribute("part","text");m.setAttribute("part","dismiss");m.setAttribute("type","button");q.setAttribute("aria-hidden","true");q.textContent="×";m.appendChild(q);d.appendChild(e);d.appendChild(k);d.appendChild(m);b.appendChild(c);b.appendChild(d);a.__xAlertRefs=new $APP.Q(null,7,[$APP.kh,b,$APP.ii,
5
- d,$APP.xg,e,$APP.Wh,g,$APP.Mi,h,hq,k,$APP.Xg,m],null);return $APP.l(a,"__xAlertRefs")},jq=function(a){a=new $APP.Q(null,7,[$APP.bh,a.getAttribute("type"),$APP.Fh,a.getAttribute("text"),$APP.Bg,a.hasAttribute("icon"),$APP.fi,a.getAttribute("icon"),$APP.Rh,a.getAttribute("dismissible"),$APP.Sh,a.hasAttribute("disabled"),$APP.$g,a.getAttribute("timeout-ms")],null);var b=$APP.N(a),c=$APP.I(b,$APP.bh);a=$APP.I(b,$APP.Fh);var d=$APP.I(b,$APP.Bg),e=$APP.I(b,$APP.fi),g=$APP.I(b,$APP.Rh),h=$APP.I(b,$APP.Sh);
6
- b=$APP.I(b,$APP.$g);c=$APP.I($APP.Zi,typeof c==="string"?c.toLowerCase():null);c=$APP.n(c)?c:$APP.rh;typeof e==="string"?(e=e.trim(),e=$APP.O(e,"")&&$APP.O(e.toLowerCase(),"none")?e:null):e=null;d=$APP.n($APP.n(d)?e==null:d)?$APP.Ri:e!=null?$APP.Hh:$APP.Sg;return new $APP.Q(null,7,[$APP.Z,c,$APP.Fh,$APP.n(a)?a:"",$APP.Xi,d,$APP.Rg,$APP.C.h(d,$APP.Hh)?e:null,$APP.oh,dq(g),$APP.V,$APP.K(h),$APP.xi,eq(b)],null)},kq=function(a){var b=jq(a);if($APP.O($APP.l(a,"__xAlertModel"),b)){b=$APP.N(b);var c=$APP.I(b,
7
- $APP.Z),d=$APP.I(b,$APP.Fh),e=$APP.I(b,$APP.Xi),g=$APP.I(b,$APP.Rg),h=$APP.I(b,$APP.oh),k=$APP.I(b,$APP.V),m=iq(a),q=$APP.N(m);m=$APP.I(q,$APP.ii);var r=$APP.I(q,$APP.xg),v=$APP.I(q,$APP.Wh),w=$APP.I(q,$APP.Mi),z=$APP.I(q,hq);q=$APP.I(q,$APP.Xg);v=$APP.n(v)?v.assignedNodes().length>0:null;$APP.C.h(e,$APP.Hh)||(g=$APP.I($APP.aj,c),g=$APP.n(g)?g:$APP.I($APP.aj,$APP.rh));e=$APP.p(v)&&$APP.C.h(e,$APP.Ri);a.setAttribute("data-type",cq(c));v=m.setAttribute;c=$APP.C.h(c,$APP.li)||$APP.C.h(c,$APP.ih)?"alert":
8
- "status";v.call(m,"role",c);z.textContent=d;e?(w.textContent="",r.style.display="none"):(w.textContent=g,r.style.display="inline");$APP.n(h)?(q.disabled=$APP.K(k),q.style.display="inline-flex"):(q.disabled=!0,q.style.display="none");q.setAttribute("aria-label","Dismiss alert");d=$APP.n(h)?$APP.p(k):h;a.tabIndex=$APP.n(d)?0:-1;$APP.n(k)?a.setAttribute("aria-disabled","true"):a.removeAttribute("aria-disabled");$APP.n(d)?a.setAttribute("aria-keyshortcuts","Escape"):a.removeAttribute("aria-keyshortcuts");
9
- a.__xAlertModel=b}},lq=function(a){a=typeof a==="string"?a.trim():"";return $APP.C.h(a,"")||$APP.C.h(a,"0")||$APP.C.h(a,"0ms")||$APP.C.h(a,"0s")?0:$APP.n(a.endsWith("ms"))?(a=parseFloat(a.slice(0,a.length-2)),$APP.n(isNaN(a))?0:Math.max(0,Math.round(a))):$APP.n(a.endsWith("s"))?(a=parseFloat(a.slice(0,a.length-1)),$APP.n(isNaN(a))?0:Math.max(0,Math.round(1E3*a))):0},mq=function(a){var b=window.getComputedStyle(a);a=lq(b.getPropertyValue("--x-alert-exit-duration"));b=lq(b.getPropertyValue("--x-motion-exit-duration"));
10
- return a>0?a:b>0?b:160},nq=function(a){var b=$APP.l(a,"__xAlertTimeout");$APP.n(b)&&(clearTimeout(b),a.__xAlertTimeout=null)},pq=function(a){nq(a);var b=function(){var c=$APP.l(a,"__xAlertModel");return $APP.n(c)?c:jq(a)}();$APP.n(function(){var c=fq(b);return $APP.n(c)?typeof $APP.xi.g(b)==="number"&&$APP.p($APP.l(a,"__xAlertExiting")):c}())&&$APP.la(a,"__xAlertTimeout",setTimeout(function(){a.__xAlertTimeout=null;if($APP.n(function(){var d=a.isConnected;return $APP.n(d)?$APP.p($APP.l(a,"__xAlertExiting")):
11
- d}())){var c=function(){var d=$APP.l(a,"__xAlertModel");return $APP.n(d)?d:jq(a)}();if($APP.n(fq(c)))return c=$APP.pg(gq(c,"timeout")),c=new CustomEvent("x-alert-dismiss",{detail:c,bubbles:!0,composed:!0,cancelable:!0}),c=a.dispatchEvent(c),$APP.n(c)?oq.g?oq.g(a):oq.call(null,a):null}return null},$APP.xi.g(b)))},qq=function(a){if(!$APP.n($APP.l(a,"__xAlertEntered"))){a.__xAlertEntered=!0;a.setAttribute("data-entering","");var b=iq(a);b=$APP.N(b);var c=$APP.I(b,$APP.ii);c.addEventListener("animationend",
12
- function g(e){return $APP.C.h(e.target,c)?(c.removeEventListener("animationend",g),a.removeAttribute("data-entering")):null})}},oq=function(a){if(!$APP.n($APP.l(a,"__xAlertExiting"))){a.__xAlertExiting=!0;nq(a);a.removeAttribute("data-entering");var b=mq(a);if(b===0||$APP.K(window.matchMedia("(prefers-reduced-motion:reduce)").matches))a.remove();else{var c=iq(a);c=$APP.N(c);var d=$APP.I(c,$APP.ii),e=function k(h){return $APP.C.h(h.target,d)?(d.removeEventListener("animationend",k),h=$APP.l(a,"__xAlertExitTimer"),
13
- $APP.n(h)&&(clearTimeout(h),a.__xAlertExitTimer=null),$APP.n(a.isConnected)?a.remove():null):null};a.setAttribute("data-exiting","");d.addEventListener("animationend",e);$APP.la(a,"__xAlertExitTimer",setTimeout(function(){var h=a.isConnected;return $APP.n($APP.n(h)?$APP.l(a,"__xAlertExiting"):h)?(d.removeEventListener("animationend",e),a.__xAlertExitTimer=null,a.remove()):null},b+60))}}return null},rq=function(a,b){var c=$APP.l(a,"__xAlertModel");c=$APP.n(c)?c:jq(a);b=$APP.pg(gq(c,b));b=new CustomEvent("x-alert-dismiss",
14
- {detail:b,bubbles:!0,composed:!0,cancelable:!0});b=a.dispatchEvent(b);$APP.n(b)&&oq(a)},sq=function(a,b){var c=function(){var d=$APP.l(a,"__xAlertModel");return $APP.n(d)?d:jq(a)}();$APP.n(function(){var d=fq(c);return $APP.n(d)?$APP.p($APP.l(a,"__xAlertExiting")):d}())&&(b.preventDefault(),rq(a,"button"));return null},tq=function(a,b){if($APP.C.h(b.key,"Escape")){var c=function(){var d=$APP.l(a,"__xAlertModel");return $APP.n(d)?d:jq(a)}();$APP.n(function(){var d=fq(c);return $APP.n(d)?$APP.p($APP.l(a,
15
- "__xAlertExiting")):d}())&&(b.preventDefault(),rq(a,"keyboard"))}return null},uq=function(a){function b(e){return tq(a,e)}function c(e){return sq(a,e)}var d=iq(a);d=$APP.N(d);$APP.I(d,$APP.Xg).addEventListener("click",c);a.addEventListener("keydown",b);$APP.la(a,"__xAlertHandlers",{click:c,keydown:b})},vq=function(a){nq(a);var b=$APP.l(a,"__xAlertExitTimer");$APP.n(b)&&(clearTimeout(b),a.__xAlertExitTimer=null);b=$APP.l(a,"__xAlertHandlers");var c=$APP.l(a,"__xAlertRefs");if($APP.n($APP.n(b)?c:b)){c=
16
- $APP.Xg.g(c);var d=$APP.l(b,"click");b=$APP.l(b,"keydown");$APP.n(d)&&c.removeEventListener("click",d);$APP.n(b)&&a.removeEventListener("keydown",b)}a.__xAlertHandlers=null},wq=function(a){Object.defineProperty(a,"type",{get:function(){var b=this.getAttribute("type");return $APP.n(b)?b:"info"},set:function(b){return $APP.n(b)?this.setAttribute("type",""+$APP.T.g(b)):this.removeAttribute("type")},enumerable:!0,configurable:!0});Object.defineProperty(a,"text",{get:function(){var b=this.getAttribute("text");
2
+ var $s=function(a){a=$APP.I($APP.Ck,a);return $APP.n(a)?a:"info"},at=function(a){return a==null?!0:$APP.P((""+$APP.T.g(a)).trim().toLowerCase(),"false")},bt=function(a){return typeof a==="string"?(a=parseInt(a.trim(),10),typeof a==="number"&&$APP.q(isNaN(a))&&a>0?a:null):null},ct=function(a){var b=$APP.O(a);a=$APP.I(b,$APP.ei);b=$APP.I(b,$APP.V);return $APP.n(a)?$APP.q(b):a},dt=function(a,b){var c=$APP.O(a);a=$APP.I(c,$APP.Z);c=$APP.I(c,$APP.Ki);return new $APP.Q(null,3,[$APP.Z,$s(a),$APP.gi,b,$APP.Ki,
3
+ c],null)},ft=function(a){var b=$APP.l(a,"__xAlertRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("span"),g=document.createElement("slot"),h=document.createElement("span"),k=document.createElement("span"),m=document.createElement("button"),p=document.createElement("span");c.textContent=":host{display:block;color-scheme:light dark;--x-alert-radius:10px;--x-alert-padding-y:10px;--x-alert-padding-x:12px;--x-alert-gap:10px;--x-alert-font-size:0.875rem;--x-alert-motion-fast:120ms;--x-alert-motion-ease:cubic-bezier(0.2,0,0,1);--x-alert-enter-duration:140ms;--x-alert-exit-duration:160ms;--x-alert-press-scale:0.98;--x-alert-disabled-opacity:0.55;--x-alert-focus-ring:rgba(0,0,0,0.6);--x-alert-dismiss-color:rgba(0,0,0,0.62);--x-alert-dismiss-hover-bg:rgba(0,0,0,0.06);--x-alert-info-bg:rgba(0,102,204,0.08);--x-alert-info-border:rgba(0,102,204,0.35);--x-alert-info-color:rgba(0,60,120,0.95);--x-alert-success-bg:rgba(16,140,72,0.10);--x-alert-success-border:rgba(16,140,72,0.35);--x-alert-success-color:rgba(10,90,46,0.95);--x-alert-warning-bg:rgba(204,120,0,0.12);--x-alert-warning-border:rgba(204,120,0,0.45);--x-alert-warning-color:rgba(120,70,0,0.95);--x-alert-error-bg:rgba(190,20,40,0.10);--x-alert-error-border:rgba(190,20,40,0.45);--x-alert-error-color:rgba(120,10,20,0.95);--x-alert-bg:transparent;--x-alert-border-color:transparent;--x-alert-color:inherit;}@media (prefers-color-scheme:dark){:host{--x-alert-focus-ring:rgba(255,255,255,0.75);--x-alert-dismiss-color:rgba(255,255,255,0.75);--x-alert-dismiss-hover-bg:rgba(255,255,255,0.14);--x-alert-info-bg:rgba(80,160,255,0.18);--x-alert-info-border:rgba(80,160,255,0.42);--x-alert-info-color:rgba(230,245,255,0.92);--x-alert-success-bg:rgba(60,210,120,0.18);--x-alert-success-border:rgba(60,210,120,0.42);--x-alert-success-color:rgba(235,255,245,0.92);--x-alert-warning-bg:rgba(255,190,90,0.20);--x-alert-warning-border:rgba(255,190,90,0.46);--x-alert-warning-color:rgba(255,248,235,0.92);--x-alert-error-bg:rgba(255,90,110,0.18);--x-alert-error-border:rgba(255,90,110,0.46);--x-alert-error-color:rgba(255,235,238,0.92);}}:host([data-type\x3d'info']){--x-alert-bg:var(--x-alert-info-bg);--x-alert-border-color:var(--x-alert-info-border);--x-alert-color:var(--x-alert-info-color);}:host([data-type\x3d'success']){--x-alert-bg:var(--x-alert-success-bg);--x-alert-border-color:var(--x-alert-success-border);--x-alert-color:var(--x-alert-success-color);}:host([data-type\x3d'warning']){--x-alert-bg:var(--x-alert-warning-bg);--x-alert-border-color:var(--x-alert-warning-border);--x-alert-color:var(--x-alert-warning-color);}:host([data-type\x3d'error']){--x-alert-bg:var(--x-alert-error-bg);--x-alert-border-color:var(--x-alert-error-border);--x-alert-color:var(--x-alert-error-color);}[part\x3dcontainer]{display:flex;align-items:flex-start;gap:var(--x-alert-gap);padding:var(--x-alert-padding-y) var(--x-alert-padding-x);border:1px solid var(--x-alert-border-color);border-radius:var(--x-alert-radius);background:var(--x-alert-bg);color:var(--x-alert-color);font-size:var(--x-alert-font-size);transition:background var(--x-alert-motion-fast) var(--x-alert-motion-ease),border-color var(--x-alert-motion-fast) var(--x-alert-motion-ease),color var(--x-alert-motion-fast) var(--x-alert-motion-ease),opacity var(--x-alert-motion-fast) var(--x-alert-motion-ease),transform var(--x-alert-motion-fast) var(--x-alert-motion-ease);}[part\x3dicon]{flex:0 0 auto;line-height:1;margin-top:0.05em;}slot[name\x3dicon]::slotted(*){display:block;}[part\x3dtext]{flex:1 1 auto;line-height:1.25;min-width:0;overflow-wrap:anywhere;}[part\x3ddismiss]{flex:0 0 auto;appearance:none;border:0;background:transparent;color:var(--x-alert-dismiss-color);width:1.5em;height:1.5em;padding:0;margin:0;border-radius:999px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;transition:background var(--x-alert-motion-fast) var(--x-alert-motion-ease),transform var(--x-alert-motion-fast) var(--x-alert-motion-ease);}:host(:not([disabled])) [part\x3ddismiss]:hover{background:var(--x-alert-dismiss-hover-bg);}:host(:not([disabled])) [part\x3ddismiss]:active{transform:scale(var(--x-alert-press-scale));}[part\x3ddismiss]:focus{outline:none;}:host(:not([disabled])) [part\x3ddismiss]:focus-visible{outline:2px solid var(--x-alert-focus-ring);outline-offset:2px;}:host([disabled]){opacity:var(--x-alert-disabled-opacity);}:host([disabled]) [part\x3ddismiss]{cursor:default;pointer-events:none;}:host([data-entering]) [part\x3dcontainer]{animation:x-alert-enter var(--x-alert-enter-duration) var(--x-alert-motion-ease) both;}@keyframes x-alert-enter{from{opacity:0;transform:translateY(4px);}to{opacity:1;transform:translateY(0);}}:host([data-exiting]) [part\x3dcontainer]{animation:x-alert-exit var(--x-alert-exit-duration) var(--x-alert-motion-ease) forwards;}@keyframes x-alert-exit{from{opacity:1;transform:translateY(0);}to{opacity:0;transform:translateY(4px);}}@media (prefers-reduced-motion:reduce){[part\x3dcontainer],[part\x3ddismiss]{transition:none !important;}:host([data-entering]) [part\x3dcontainer],:host([data-exiting]) [part\x3dcontainer]{animation:none !important;}}";
4
+ d.setAttribute("part","container");e.setAttribute("part","icon");e.setAttribute("aria-hidden","true");g.setAttribute("name","icon");h.setAttribute("part","default-icon");g.appendChild(h);e.appendChild(g);k.setAttribute("part","text");m.setAttribute("part","dismiss");m.setAttribute("type","button");p.setAttribute("aria-hidden","true");p.textContent="×";m.appendChild(p);d.appendChild(e);d.appendChild(k);d.appendChild(m);b.appendChild(c);b.appendChild(d);a.__xAlertRefs=new $APP.Q(null,7,[$APP.Xh,b,$APP.xj,
5
+ d,$APP.Vg,e,$APP.gj,g,$APP.kk,h,et,k,$APP.Dh,m],null);return $APP.l(a,"__xAlertRefs")},gt=function(a){a=new $APP.Q(null,7,[$APP.Mh,a.getAttribute("type"),$APP.Ki,a.getAttribute("text"),$APP.$g,a.hasAttribute("icon"),$APP.rj,a.getAttribute("icon"),$APP.$i,a.getAttribute("dismissible"),$APP.aj,a.hasAttribute("disabled"),$APP.Jh,a.getAttribute("timeout-ms")],null);var b=$APP.O(a),c=$APP.I(b,$APP.Mh);a=$APP.I(b,$APP.Ki);var d=$APP.I(b,$APP.$g),e=$APP.I(b,$APP.rj),g=$APP.I(b,$APP.$i),h=$APP.I(b,$APP.aj);
6
+ b=$APP.I(b,$APP.Jh);c=$APP.I($APP.Bk,typeof c==="string"?c.toLowerCase():null);c=$APP.n(c)?c:$APP.ii;typeof e==="string"?(e=e.trim(),e=$APP.P(e,"")&&$APP.P(e.toLowerCase(),"none")?e:null):e=null;d=$APP.n($APP.n(d)?e==null:d)?$APP.qk:e!=null?$APP.Ni:$APP.xh;return new $APP.Q(null,7,[$APP.Z,c,$APP.Ki,$APP.n(a)?a:"",$APP.yk,d,$APP.wh,$APP.C.h(d,$APP.Ni)?e:null,$APP.ei,at(g),$APP.V,$APP.K(h),$APP.Pj,bt(b)],null)},ht=function(a){var b=gt(a);if($APP.P($APP.l(a,"__xAlertModel"),b)){b=$APP.O(b);var c=$APP.I(b,
7
+ $APP.Z),d=$APP.I(b,$APP.Ki),e=$APP.I(b,$APP.yk),g=$APP.I(b,$APP.wh),h=$APP.I(b,$APP.ei),k=$APP.I(b,$APP.V),m=ft(a),p=$APP.O(m);m=$APP.I(p,$APP.xj);var r=$APP.I(p,$APP.Vg),v=$APP.I(p,$APP.gj),x=$APP.I(p,$APP.kk),y=$APP.I(p,et);p=$APP.I(p,$APP.Dh);v=$APP.n(v)?v.assignedNodes().length>0:null;$APP.C.h(e,$APP.Ni)||(g=$APP.I($APP.Dk,c),g=$APP.n(g)?g:$APP.I($APP.Dk,$APP.ii));e=$APP.q(v)&&$APP.C.h(e,$APP.qk);a.setAttribute("data-type",$s(c));v=m.setAttribute;c=$APP.C.h(c,$APP.Bj)||$APP.C.h(c,$APP.Uh)?"alert":
8
+ "status";v.call(m,"role",c);y.textContent=d;e?(x.textContent="",r.style.display="none"):(x.textContent=g,r.style.display="inline");$APP.n(h)?(p.disabled=$APP.K(k),p.style.display="inline-flex"):(p.disabled=!0,p.style.display="none");p.setAttribute("aria-label","Dismiss alert");d=$APP.n(h)?$APP.q(k):h;a.tabIndex=$APP.n(d)?0:-1;$APP.n(k)?a.setAttribute("aria-disabled","true"):a.removeAttribute("aria-disabled");$APP.n(d)?a.setAttribute("aria-keyshortcuts","Escape"):a.removeAttribute("aria-keyshortcuts");
9
+ a.__xAlertModel=b}},it=function(a){a=typeof a==="string"?a.trim():"";return $APP.C.h(a,"")||$APP.C.h(a,"0")||$APP.C.h(a,"0ms")||$APP.C.h(a,"0s")?0:$APP.n(a.endsWith("ms"))?(a=parseFloat(a.slice(0,a.length-2)),$APP.n(isNaN(a))?0:Math.max(0,Math.round(a))):$APP.n(a.endsWith("s"))?(a=parseFloat(a.slice(0,a.length-1)),$APP.n(isNaN(a))?0:Math.max(0,Math.round(1E3*a))):0},jt=function(a){var b=window.getComputedStyle(a);a=it(b.getPropertyValue("--x-alert-exit-duration"));b=it(b.getPropertyValue("--x-motion-exit-duration"));
10
+ return a>0?a:b>0?b:160},kt=function(a){var b=$APP.l(a,"__xAlertTimeout");$APP.n(b)&&(clearTimeout(b),a.__xAlertTimeout=null)},mt=function(a){kt(a);var b=function(){var c=$APP.l(a,"__xAlertModel");return $APP.n(c)?c:gt(a)}();$APP.n(function(){var c=ct(b);return $APP.n(c)?typeof $APP.Pj.g(b)==="number"&&$APP.q($APP.l(a,"__xAlertExiting")):c}())&&$APP.la(a,"__xAlertTimeout",setTimeout(function(){a.__xAlertTimeout=null;if($APP.n(function(){var d=a.isConnected;return $APP.n(d)?$APP.q($APP.l(a,"__xAlertExiting")):
11
+ d}())){var c=function(){var d=$APP.l(a,"__xAlertModel");return $APP.n(d)?d:gt(a)}();if($APP.n(ct(c)))return c=$APP.Lg(dt(c,"timeout")),c=new CustomEvent("x-alert-dismiss",{detail:c,bubbles:!0,composed:!0,cancelable:!0}),c=a.dispatchEvent(c),$APP.n(c)?lt.g?lt.g(a):lt.call(null,a):null}return null},$APP.Pj.g(b)))},nt=function(a){if(!$APP.n($APP.l(a,"__xAlertEntered"))){a.__xAlertEntered=!0;a.setAttribute("data-entering","");var b=ft(a);b=$APP.O(b);var c=$APP.I(b,$APP.xj);c.addEventListener("animationend",
12
+ function g(e){return $APP.C.h(e.target,c)?(c.removeEventListener("animationend",g),a.removeAttribute("data-entering")):null})}},lt=function(a){if(!$APP.n($APP.l(a,"__xAlertExiting"))){a.__xAlertExiting=!0;kt(a);a.removeAttribute("data-entering");var b=jt(a);if(b===0||$APP.K(window.matchMedia("(prefers-reduced-motion:reduce)").matches))a.remove();else{var c=ft(a);c=$APP.O(c);var d=$APP.I(c,$APP.xj),e=function k(h){return $APP.C.h(h.target,d)?(d.removeEventListener("animationend",k),h=$APP.l(a,"__xAlertExitTimer"),
13
+ $APP.n(h)&&(clearTimeout(h),a.__xAlertExitTimer=null),$APP.n(a.isConnected)?a.remove():null):null};a.setAttribute("data-exiting","");d.addEventListener("animationend",e);$APP.la(a,"__xAlertExitTimer",setTimeout(function(){var h=a.isConnected;return $APP.n($APP.n(h)?$APP.l(a,"__xAlertExiting"):h)?(d.removeEventListener("animationend",e),a.__xAlertExitTimer=null,a.remove()):null},b+60))}}return null},ot=function(a,b){var c=$APP.l(a,"__xAlertModel");c=$APP.n(c)?c:gt(a);b=$APP.Lg(dt(c,b));b=new CustomEvent("x-alert-dismiss",
14
+ {detail:b,bubbles:!0,composed:!0,cancelable:!0});b=a.dispatchEvent(b);$APP.n(b)&&lt(a)},pt=function(a,b){var c=function(){var d=$APP.l(a,"__xAlertModel");return $APP.n(d)?d:gt(a)}();$APP.n(function(){var d=ct(c);return $APP.n(d)?$APP.q($APP.l(a,"__xAlertExiting")):d}())&&(b.preventDefault(),ot(a,"button"));return null},qt=function(a,b){if($APP.C.h(b.key,"Escape")){var c=function(){var d=$APP.l(a,"__xAlertModel");return $APP.n(d)?d:gt(a)}();$APP.n(function(){var d=ct(c);return $APP.n(d)?$APP.q($APP.l(a,
15
+ "__xAlertExiting")):d}())&&(b.preventDefault(),ot(a,"keyboard"))}return null},rt=function(a){function b(e){return qt(a,e)}function c(e){return pt(a,e)}var d=ft(a);d=$APP.O(d);$APP.I(d,$APP.Dh).addEventListener("click",c);a.addEventListener("keydown",b);$APP.la(a,"__xAlertHandlers",{click:c,keydown:b})},st=function(a){kt(a);var b=$APP.l(a,"__xAlertExitTimer");$APP.n(b)&&(clearTimeout(b),a.__xAlertExitTimer=null);b=$APP.l(a,"__xAlertHandlers");var c=$APP.l(a,"__xAlertRefs");if($APP.n($APP.n(b)?c:b)){c=
16
+ $APP.Dh.g(c);var d=$APP.l(b,"click");b=$APP.l(b,"keydown");$APP.n(d)&&c.removeEventListener("click",d);$APP.n(b)&&a.removeEventListener("keydown",b)}a.__xAlertHandlers=null},tt=function(a){Object.defineProperty(a,"type",{get:function(){var b=this.getAttribute("type");return $APP.n(b)?b:"info"},set:function(b){return $APP.n(b)?this.setAttribute("type",""+$APP.T.g(b)):this.removeAttribute("type")},enumerable:!0,configurable:!0});Object.defineProperty(a,"text",{get:function(){var b=this.getAttribute("text");
17
17
  return $APP.n(b)?b:""},set:function(b){return $APP.n(b)?this.setAttribute("text",""+$APP.T.g(b)):this.removeAttribute("text")},enumerable:!0,configurable:!0});Object.defineProperty(a,"icon",{get:function(){return this.getAttribute("icon")},set:function(b){return $APP.n(b)?this.setAttribute("icon",""+$APP.T.g(b)):this.removeAttribute("icon")},enumerable:!0,configurable:!0});Object.defineProperty(a,"disabled",{get:function(){return this.hasAttribute("disabled")},set:function(b){return $APP.n(b)?this.setAttribute("disabled",
18
- ""):this.removeAttribute("disabled")},enumerable:!0,configurable:!0});Object.defineProperty(a,"dismissible",{get:function(){return dq(this.getAttribute("dismissible"))},set:function(b){return $APP.n(b)?this.setAttribute("dismissible",""):this.setAttribute("dismissible","false")},enumerable:!0,configurable:!0});Object.defineProperty(a,"timeoutMs",{get:function(){return eq(this.getAttribute("timeout-ms"))},set:function(b){return b==null?this.removeAttribute("timeout-ms"):this.setAttribute("timeout-ms",
19
- ""+$APP.T.g(b|0))},enumerable:!0,configurable:!0})},yq=function(){var a=class extends HTMLElement{};a.observedAttributes=xq;a.prototype.connectedCallback=function(){iq(this);vq(this);uq(this);kq(this);qq(this);pq(this);return null};a.prototype.disconnectedCallback=function(){vq(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.O(c,d)&&(kq(this),$APP.n(this.isConnected)&&pq(this));return null};wq(a.prototype);return a},zq=function(){$APP.n(customElements.get("x-alert"))||
20
- customElements.define("x-alert",yq());return null},xq="type text icon dismissible disabled timeout-ms".split(" "),hq=new $APP.M(null,"text-el","text-el",-1615414066);$APP.ja("baredom.exports.x_alert.init",zq);export const init=zq;
18
+ ""):this.removeAttribute("disabled")},enumerable:!0,configurable:!0});Object.defineProperty(a,"dismissible",{get:function(){return at(this.getAttribute("dismissible"))},set:function(b){return $APP.n(b)?this.setAttribute("dismissible",""):this.setAttribute("dismissible","false")},enumerable:!0,configurable:!0});Object.defineProperty(a,"timeoutMs",{get:function(){return bt(this.getAttribute("timeout-ms"))},set:function(b){return b==null?this.removeAttribute("timeout-ms"):this.setAttribute("timeout-ms",
19
+ ""+$APP.T.g(b|0))},enumerable:!0,configurable:!0})},vt=function(){var a=class extends HTMLElement{};a.observedAttributes=ut;a.prototype.connectedCallback=function(){ft(this);st(this);rt(this);ht(this);nt(this);mt(this);return null};a.prototype.disconnectedCallback=function(){st(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.P(c,d)&&(ht(this),$APP.n(this.isConnected)&&mt(this));return null};tt(a.prototype);return a},wt=function(){$APP.n(customElements.get("x-alert"))||
20
+ customElements.define("x-alert",vt());return null},ut="type text icon dismissible disabled timeout-ms".split(" "),et=new $APP.N(null,"text-el","text-el",-1615414066);$APP.ja("baredom.exports.x_alert.init",wt);export const init=wt;
@@ -1,12 +1,12 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var Aq=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.yc(a,c)?c:b},Bq=function(a){if(typeof a==="string"){a=parseInt(a,10);var b=isFinite(a);return $APP.n($APP.n(b)?a>0:b)?a:null}return null},Dq=function(a){var b=$APP.l(a,"__xAvatarGroupRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("slot"),e=document.createElement("span");c.textContent=":host{display:inline-flex;align-items:center;flex-direction:row;color-scheme:light dark;--x-avatar-group-overflow-bg:rgba(0,0,0,0.08);--x-avatar-group-overflow-color:rgba(0,0,0,0.70);--x-avatar-group-overflow-border:rgba(0,0,0,0.14);--x-avatar-group-overflow-ring:#ffffff;--x-avatar-group-size:32px;--x-avatar-group-font-size:0.75rem;}@media (prefers-color-scheme:dark){:host{--x-avatar-group-overflow-bg:rgba(255,255,255,0.10);--x-avatar-group-overflow-color:rgba(255,255,255,0.75);--x-avatar-group-overflow-border:rgba(255,255,255,0.18);--x-avatar-group-overflow-ring:#0b0c0f;}}:host([data-size\x3d'xs']){--x-avatar-group-size:20px;--x-avatar-group-font-size:0.625rem;}:host([data-size\x3d'sm']){--x-avatar-group-size:24px;--x-avatar-group-font-size:0.6875rem;}:host([data-size\x3d'md']){--x-avatar-group-size:32px;--x-avatar-group-font-size:0.75rem;}:host([data-size\x3d'lg']){--x-avatar-group-size:40px;--x-avatar-group-font-size:0.875rem;}:host([data-size\x3d'xl']){--x-avatar-group-size:48px;--x-avatar-group-font-size:1rem;}:host([data-direction\x3d'rtl']){flex-direction:row-reverse;}[part\x3doverflow]{display:none;flex-shrink:0;width:var(--x-avatar-group-size);height:var(--x-avatar-group-size);border-radius:999px;background:var(--x-avatar-group-overflow-bg);color:var(--x-avatar-group-overflow-color);border:1px solid var(--x-avatar-group-overflow-border);box-shadow:0 0 0 2px var(--x-avatar-group-overflow-ring);font-size:var(--x-avatar-group-font-size);font-weight:600;line-height:1;align-items:center;justify-content:center;user-select:none;box-sizing:border-box;white-space:nowrap;}::slotted(x-avatar){flex-shrink:0;}@media (prefers-reduced-motion:reduce){::slotted(x-avatar){transition:none !important;}}";
3
- e.setAttribute("part","overflow");e.setAttribute("aria-hidden","true");b.appendChild(c);b.appendChild(d);b.appendChild(e);a.__xAvatarGroupRefs=new $APP.Q(null,2,[$APP.Jh,d,Cq,e],null);return $APP.l(a,"__xAvatarGroupRefs")},Kq=function(a){a=new $APP.Q(null,6,[$APP.$h,a.getAttribute("size"),Eq,a.getAttribute("overlap"),$APP.ah,a.getAttribute("max"),Fq,a.getAttribute("direction"),$APP.Sh,a.hasAttribute("disabled"),$APP.Wg,a.getAttribute("label")],null);var b=$APP.N(a);a=$APP.I(b,$APP.$h);var c=$APP.I(b,
4
- Eq),d=$APP.I(b,$APP.ah),e=$APP.I(b,Fq),g=$APP.I(b,$APP.Sh);b=$APP.I(b,$APP.Wg);a=Aq(Gq,"md",a);c=Aq(Hq,"md",c);d=Bq(d);e=Aq(Iq,"ltr",e);g=$APP.K(g);typeof b==="string"?(b=b.trim(),b=$APP.C.h(b,"")?null:b):b=null;return new $APP.Q(null,6,[$APP.sg,a,Jq,c,$APP.Yg,d,$APP.Vh,e,$APP.pi,g,$APP.W,b],null)},Mq=function(a,b){b=$APP.N(b);var c=$APP.I(b,$APP.sg),d=$APP.I(b,Jq),e=$APP.I(b,$APP.Yg),g=$APP.I(b,$APP.Vh),h=$APP.I(b,$APP.pi),k=$APP.I(b,$APP.W),m=Dq(a);m=$APP.N(m);var q=$APP.I(m,$APP.Jh);m=$APP.I(m,
5
- Cq);var r=$APP.ec(q.assignedElements());q=$APP.B(r);q=$APP.n($APP.n(e)?q>e:e)?new $APP.P(null,2,5,$APP.Rd,[e,q-e],null):new $APP.P(null,2,5,$APP.Rd,[q,0],null);e=$APP.H(q,0,null);q=$APP.H(q,1,null);var v=$APP.ic(Lq,d,"0px");a.setAttribute("data-size",c);a.setAttribute("data-overlap",d);a.setAttribute("data-direction",g);a.setAttribute("role","group");$APP.n(k)?a.setAttribute("aria-label",k):a.removeAttribute("aria-label");$APP.n(h)?a.setAttribute("aria-disabled","true"):a.removeAttribute("aria-disabled");
6
- d=$APP.u($APP.Cd.m($APP.hg,r,$APP.wf(0,Number.MAX_VALUE)));g=null;for(r=k=0;;)if(r<k){var w=g.D(null,r),z=$APP.H(w,0,null);w=$APP.H(w,1,null);w<e?(z.style.display="",z.setAttribute("size",c),$APP.n(h)?z.setAttribute("disabled",""):z.removeAttribute("disabled"),z.style.marginInlineStart=w>0?v:"0px"):z.style.display="none";r+=1}else if(d=$APP.u(d))$APP.uc(d)?(k=$APP.mb(d),d=$APP.nb(d),g=k,k=$APP.B(k)):(k=$APP.x(d),g=$APP.H(k,0,null),k=$APP.H(k,1,null),k<e?(g.style.display="",g.setAttribute("size",c),
7
- $APP.n(h)?g.setAttribute("disabled",""):g.removeAttribute("disabled"),g.style.marginInlineStart=k>0?v:"0px"):g.style.display="none",d=$APP.y(d),g=null,k=0),r=0;else break;q>0?(m.textContent="+"+$APP.T.g(q),m.setAttribute("role","img"),m.setAttribute("aria-label",""+$APP.T.g(q)+" more"),m.style.display="inline-flex",m.style.marginInlineStart=v):(m.textContent="",m.style.display="none");a.__xAvatarGroupModel=b},Nq=function(a){Mq(a,Kq(a));return null},Oq=function(a){function b(){return Nq(a)}var c=Dq(a);
8
- c=$APP.N(c);c=$APP.I(c,$APP.Jh);$APP.n(c)&&c.addEventListener("slotchange",b);$APP.la(a,"__xAvatarGroupHandlers",{slot:b})},Pq=function(a){var b=$APP.l(a,"__xAvatarGroupHandlers");if($APP.n(b)){var c=$APP.l(a,"__xAvatarGroupRefs");$APP.n(c)&&(c=$APP.Jh.g(c),b=$APP.l(b,"slot"),$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",b))}a.__xAvatarGroupHandlers=null},Qq=function(a){Object.defineProperty(a,"label",{get:function(){return this.getAttribute("label")},set:function(b){return $APP.n(b)?
9
- this.setAttribute("label",""+$APP.T.g(b)):this.removeAttribute("label")},enumerable:!0,configurable:!0})},Rq=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},Sq=function(a){Object.defineProperty(a,"disabled",{get:function(){return this.hasAttribute("disabled")},set:function(b){return $APP.n(b)?this.setAttribute("disabled",
10
- ""):this.removeAttribute("disabled")},enumerable:!0,configurable:!0})},Tq=function(a){Object.defineProperty(a,"max",{get:function(){return Bq(this.getAttribute("max"))},set:function(b){return b!=null?this.setAttribute("max",""+$APP.T.g(b)):this.removeAttribute("max")},enumerable:!0,configurable:!0})},Uq=function(a){Rq(a,"size","md");Rq(a,"overlap","md");Rq(a,"direction","ltr");Qq(a);Sq(a);Tq(a)},Wq=function(){var a=class extends HTMLElement{};a.observedAttributes=Vq;a.prototype.connectedCallback=
11
- function(){Dq(this);Pq(this);Oq(this);Nq(this);return null};a.prototype.disconnectedCallback=function(){Pq(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.O(c,d)&&(b=Kq(this),$APP.O($APP.l(this,"__xAvatarGroupModel"),b)&&Mq(this,b));return null};Uq(a.prototype);return a},Xq=function(){$APP.n(customElements.get("x-avatar-group"))||customElements.define("x-avatar-group",Wq());return null},Eq=new $APP.M(null,"overlap-raw","overlap-raw",1202229114),Cq=new $APP.M(null,"overflow",
12
- "overflow",2058931880),Fq=new $APP.M(null,"direction-raw","direction-raw",560730236),Jq=new $APP.M(null,"overlap","overlap",-1673335644);var Vq="size overlap max direction disabled label".split(" "),Gq=new $APP.S(null,new $APP.Q(null,5,["xs",null,"md",null,"lg",null,"xl",null,"sm",null],null),null),Hq=new $APP.S(null,new $APP.Q(null,4,["none",null,"md",null,"lg",null,"sm",null],null),null),Iq=new $APP.S(null,new $APP.Q(null,2,["ltr",null,"rtl",null],null),null),Lq=new $APP.Q(null,4,"none 0px sm -4px md -8px lg -12px".split(" "),null);$APP.ja("baredom.exports.x_avatar_group.init",Xq);export const init=Xq;
2
+ var xt=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.M(a,c)?c:b},yt=function(a){if(typeof a==="string"){a=parseInt(a,10);var b=isFinite(a);return $APP.n($APP.n(b)?a>0:b)?a:null}return null},At=function(a){var b=$APP.l(a,"__xAvatarGroupRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("slot"),e=document.createElement("span");c.textContent=":host{display:inline-flex;align-items:center;flex-direction:row;color-scheme:light dark;--x-avatar-group-overflow-bg:rgba(0,0,0,0.08);--x-avatar-group-overflow-color:rgba(0,0,0,0.70);--x-avatar-group-overflow-border:rgba(0,0,0,0.14);--x-avatar-group-overflow-ring:#ffffff;--x-avatar-group-size:32px;--x-avatar-group-font-size:0.75rem;}@media (prefers-color-scheme:dark){:host{--x-avatar-group-overflow-bg:rgba(255,255,255,0.10);--x-avatar-group-overflow-color:rgba(255,255,255,0.75);--x-avatar-group-overflow-border:rgba(255,255,255,0.18);--x-avatar-group-overflow-ring:#0b0c0f;}}:host([data-size\x3d'xs']){--x-avatar-group-size:20px;--x-avatar-group-font-size:0.625rem;}:host([data-size\x3d'sm']){--x-avatar-group-size:24px;--x-avatar-group-font-size:0.6875rem;}:host([data-size\x3d'md']){--x-avatar-group-size:32px;--x-avatar-group-font-size:0.75rem;}:host([data-size\x3d'lg']){--x-avatar-group-size:40px;--x-avatar-group-font-size:0.875rem;}:host([data-size\x3d'xl']){--x-avatar-group-size:48px;--x-avatar-group-font-size:1rem;}:host([data-direction\x3d'rtl']){flex-direction:row-reverse;}[part\x3doverflow]{display:none;flex-shrink:0;width:var(--x-avatar-group-size);height:var(--x-avatar-group-size);border-radius:999px;background:var(--x-avatar-group-overflow-bg);color:var(--x-avatar-group-overflow-color);border:1px solid var(--x-avatar-group-overflow-border);box-shadow:0 0 0 2px var(--x-avatar-group-overflow-ring);font-size:var(--x-avatar-group-font-size);font-weight:600;line-height:1;align-items:center;justify-content:center;user-select:none;box-sizing:border-box;white-space:nowrap;}::slotted(x-avatar){flex-shrink:0;}@media (prefers-reduced-motion:reduce){::slotted(x-avatar){transition:none !important;}}";
3
+ e.setAttribute("part","overflow");e.setAttribute("aria-hidden","true");b.appendChild(c);b.appendChild(d);b.appendChild(e);a.__xAvatarGroupRefs=new $APP.Q(null,2,[$APP.Pi,d,zt,e],null);return $APP.l(a,"__xAvatarGroupRefs")},Gt=function(a){a=new $APP.Q(null,6,[$APP.lj,a.getAttribute("size"),Bt,a.getAttribute("overlap"),$APP.Lh,a.getAttribute("max"),$APP.si,a.getAttribute("direction"),$APP.aj,a.hasAttribute("disabled"),$APP.Ch,a.getAttribute("label")],null);var b=$APP.O(a);a=$APP.I(b,$APP.lj);var c=
4
+ $APP.I(b,Bt),d=$APP.I(b,$APP.Lh),e=$APP.I(b,$APP.si),g=$APP.I(b,$APP.aj);b=$APP.I(b,$APP.Ch);a=xt(Ct,"md",a);c=xt(Dt,"md",c);d=yt(d);e=xt(Et,"ltr",e);g=$APP.K(g);typeof b==="string"?(b=b.trim(),b=$APP.C.h(b,"")?null:b):b=null;return new $APP.Q(null,6,[$APP.Pg,a,Ft,c,$APP.Hh,d,$APP.dj,e,$APP.Fj,g,$APP.W,b],null)},It=function(a,b){b=$APP.O(b);var c=$APP.I(b,$APP.Pg),d=$APP.I(b,Ft),e=$APP.I(b,$APP.Hh),g=$APP.I(b,$APP.dj),h=$APP.I(b,$APP.Fj),k=$APP.I(b,$APP.W),m=At(a);m=$APP.O(m);var p=$APP.I(m,$APP.Pi);
5
+ m=$APP.I(m,zt);var r=$APP.gc(p.assignedElements());p=$APP.B(r);p=$APP.n($APP.n(e)?p>e:e)?new $APP.Zd(null,2,5,$APP.$d,[e,p-e],null):new $APP.Zd(null,2,5,$APP.$d,[p,0],null);e=$APP.H(p,0,null);p=$APP.H(p,1,null);var v=$APP.lc(Ht,d,"0px");a.setAttribute("data-size",c);a.setAttribute("data-overlap",d);a.setAttribute("data-direction",g);a.setAttribute("role","group");$APP.n(k)?a.setAttribute("aria-label",k):a.removeAttribute("aria-label");$APP.n(h)?a.setAttribute("aria-disabled","true"):a.removeAttribute("aria-disabled");
6
+ d=$APP.u($APP.Id.m($APP.Dg,r,$APP.Of(0,Number.MAX_VALUE)));g=null;for(r=k=0;;)if(r<k){var x=g.H(null,r),y=$APP.H(x,0,null);x=$APP.H(x,1,null);x<e?(y.style.display="",y.setAttribute("size",c),$APP.n(h)?y.setAttribute("disabled",""):y.removeAttribute("disabled"),y.style.marginInlineStart=x>0?v:"0px"):y.style.display="none";r+=1}else if(d=$APP.u(d))$APP.yc(d)?(k=$APP.nb(d),d=$APP.ob(d),g=k,k=$APP.B(k)):(k=$APP.w(d),g=$APP.H(k,0,null),k=$APP.H(k,1,null),k<e?(g.style.display="",g.setAttribute("size",c),
7
+ $APP.n(h)?g.setAttribute("disabled",""):g.removeAttribute("disabled"),g.style.marginInlineStart=k>0?v:"0px"):g.style.display="none",d=$APP.z(d),g=null,k=0),r=0;else break;p>0?(m.textContent="+"+$APP.T.g(p),m.setAttribute("role","img"),m.setAttribute("aria-label",""+$APP.T.g(p)+" more"),m.style.display="inline-flex",m.style.marginInlineStart=v):(m.textContent="",m.style.display="none");a.__xAvatarGroupModel=b},Jt=function(a){It(a,Gt(a));return null},Kt=function(a){function b(){return Jt(a)}var c=At(a);
8
+ c=$APP.O(c);c=$APP.I(c,$APP.Pi);$APP.n(c)&&c.addEventListener("slotchange",b);$APP.la(a,"__xAvatarGroupHandlers",{slot:b})},Lt=function(a){var b=$APP.l(a,"__xAvatarGroupHandlers");if($APP.n(b)){var c=$APP.l(a,"__xAvatarGroupRefs");$APP.n(c)&&(c=$APP.Pi.g(c),b=$APP.l(b,"slot"),$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",b))}a.__xAvatarGroupHandlers=null},Mt=function(a){Object.defineProperty(a,"label",{get:function(){return this.getAttribute("label")},set:function(b){return $APP.n(b)?
9
+ this.setAttribute("label",""+$APP.T.g(b)):this.removeAttribute("label")},enumerable:!0,configurable:!0})},Nt=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},Ot=function(a){Object.defineProperty(a,"disabled",{get:function(){return this.hasAttribute("disabled")},set:function(b){return $APP.n(b)?this.setAttribute("disabled",
10
+ ""):this.removeAttribute("disabled")},enumerable:!0,configurable:!0})},Pt=function(a){Object.defineProperty(a,"max",{get:function(){return yt(this.getAttribute("max"))},set:function(b){return b!=null?this.setAttribute("max",""+$APP.T.g(b)):this.removeAttribute("max")},enumerable:!0,configurable:!0})},Qt=function(a){Nt(a,"size","md");Nt(a,"overlap","md");Nt(a,"direction","ltr");Mt(a);Ot(a);Pt(a)},St=function(){var a=class extends HTMLElement{};a.observedAttributes=Rt;a.prototype.connectedCallback=
11
+ function(){At(this);Lt(this);Kt(this);Jt(this);return null};a.prototype.disconnectedCallback=function(){Lt(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.P(c,d)&&(b=Gt(this),$APP.P($APP.l(this,"__xAvatarGroupModel"),b)&&It(this,b));return null};Qt(a.prototype);return a},Tt=function(){$APP.n(customElements.get("x-avatar-group"))||customElements.define("x-avatar-group",St());return null},Bt=new $APP.N(null,"overlap-raw","overlap-raw",1202229114),zt=new $APP.N(null,"overflow",
12
+ "overflow",2058931880),Ft=new $APP.N(null,"overlap","overlap",-1673335644);var Rt="size overlap max direction disabled label".split(" "),Ct=new $APP.S(null,new $APP.Q(null,5,["xs",null,"md",null,"lg",null,"xl",null,"sm",null],null),null),Dt=new $APP.S(null,new $APP.Q(null,4,["none",null,"md",null,"lg",null,"sm",null],null),null),Et=new $APP.S(null,new $APP.Q(null,2,["ltr",null,"rtl",null],null),null),Ht=new $APP.Q(null,4,"none 0px sm -4px md -8px lg -12px".split(" "),null);$APP.ja("baredom.exports.x_avatar_group.init",Tt);export const init=Tt;
package/dist/x-avatar.js CHANGED
@@ -1,18 +1,17 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var ZE=function(a){return function(){function b(h,k){return $APP.p(a.h?a.h(h,k):a.call(null,h,k))}function c(h){return $APP.p(a.g?a.g(h):a.call(null,h))}function d(){return $APP.p(a.J?a.J():a.call(null))}var e=null,g=function(){function h(m,q,r){var v=null;if(arguments.length>2){v=0;for(var w=Array(arguments.length-2);v<w.length;)w[v]=arguments[v+2],++v;v=new $APP.Fb(w,0,null)}return k.call(this,m,q,v)}function k(m,q,r){return $APP.p($APP.pd(a,m,q,r))}h.Y=2;h.W=function(m){var q=$APP.x(m);m=$APP.y(m);
3
- var r=$APP.x(m);m=$APP.Jb(m);return k(q,r,m)};h.F=k;return h}();e=function(h,k,m){switch(arguments.length){case 0:return d.call(this);case 1:return c.call(this,h);case 2:return b.call(this,h,k);default:var q=null;if(arguments.length>2){q=0;for(var r=Array(arguments.length-2);q<r.length;)r[q]=arguments[q+2],++q;q=new $APP.Fb(r,0,null)}return g.F(h,k,q)}throw Error("Invalid arity: "+arguments.length);};e.Y=2;e.W=g.W;e.J=d;e.g=c;e.h=b;e.F=g.F;return e}()},$E=function(a,b){return $APP.Ed(ZE(a),b)},aF=
4
- function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.yc(a,c)?c:b},bF=function(a){return typeof a==="string"?(a=a.trim(),$APP.C.h(a,"")?null:a):null},cF=function(a){a=bF(a);if($APP.n(a)){var b=$APP.Wd($E(function(c){return $APP.C.h(c,"")},a.split(/\s+/)));if($APP.u(b))return a=$APP.x(b)[0],b=$APP.B(b)>=2?$APP.x($APP.y(b))[0]:null,a=""+$APP.T.g(a)+$APP.T.g($APP.n(b)?b:""),$APP.C.h(a,"")?null:a.toUpperCase()}return null},fF=function(a){var b=$APP.N(a);a=$APP.I(b,dF);b=$APP.I(b,
5
- eF);return $APP.n(a)?a:b},hF=function(a){var b=$APP.N(a);a=$APP.I(b,gF);b=$APP.I(b,$APP.ai);return $APP.n(a)?a:b},pF=function(a){var b=$APP.l(a,"__xAvatarRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("img"),g=document.createElement("span"),h=document.createElement("span"),k=document.createElement("span"),m=document.createElement("span"),q=document.createElement("slot");c.textContent=":host{display:inline-block;vertical-align:middle;position:relative;color-scheme:light dark;--x-avatar-size-xs:20px;--x-avatar-size-sm:24px;--x-avatar-size-md:32px;--x-avatar-size-lg:40px;--x-avatar-size-xl:48px;--x-avatar-radius:10px;--x-avatar-disabled-opacity:0.55;--x-avatar-bg:rgba(0,0,0,0.06);--x-avatar-border:rgba(0,0,0,0.14);--x-avatar-color:rgba(0,0,0,0.86);--x-avatar-ring:#ffffff;--x-avatar-status-online:rgba(16,140,72,0.95);--x-avatar-status-offline:rgba(0,0,0,0.45);--x-avatar-status-busy:rgba(190,20,40,0.95);--x-avatar-status-away:rgba(204,120,0,0.95);--x-avatar-status-color:transparent;--x-avatar-font-size:0.875rem;--x-avatar-size:var(--x-avatar-size-md);}@media (prefers-color-scheme:dark){:host{--x-avatar-bg:rgba(255,255,255,0.10);--x-avatar-border:rgba(255,255,255,0.18);--x-avatar-color:rgba(255,255,255,0.88);--x-avatar-ring:#0b0c0f;--x-avatar-status-online:rgba(60,210,120,0.95);--x-avatar-status-offline:rgba(255,255,255,0.45);--x-avatar-status-busy:rgba(255,90,110,0.95);--x-avatar-status-away:rgba(255,190,90,0.95);}}:host([data-size\x3d'xs']){--x-avatar-size:var(--x-avatar-size-xs);--x-avatar-font-size:0.625rem;}:host([data-size\x3d'sm']){--x-avatar-size:var(--x-avatar-size-sm);--x-avatar-font-size:0.75rem;}:host([data-size\x3d'md']){--x-avatar-size:var(--x-avatar-size-md);}:host([data-size\x3d'lg']){--x-avatar-size:var(--x-avatar-size-lg);--x-avatar-font-size:1rem;}:host([data-size\x3d'xl']){--x-avatar-size:var(--x-avatar-size-xl);--x-avatar-font-size:1.125rem;}:host([data-variant\x3d'brand']){--x-avatar-bg:rgba(0,102,204,0.10);--x-avatar-border:rgba(0,102,204,0.30);--x-avatar-color:rgba(0,60,120,0.90);}:host([data-variant\x3d'subtle']){--x-avatar-bg:rgba(0,0,0,0.03);--x-avatar-border:rgba(0,0,0,0.08);--x-avatar-color:rgba(0,0,0,0.55);}@media (prefers-color-scheme:dark){:host([data-variant\x3d'brand']){--x-avatar-bg:rgba(80,160,255,0.18);--x-avatar-border:rgba(80,160,255,0.40);--x-avatar-color:rgba(210,235,255,0.92);}:host([data-variant\x3d'subtle']){--x-avatar-bg:rgba(255,255,255,0.04);--x-avatar-border:rgba(255,255,255,0.08);--x-avatar-color:rgba(255,255,255,0.50);}}[part\x3droot]{width:var(--x-avatar-size);height:var(--x-avatar-size);display:inline-flex;align-items:center;justify-content:center;overflow:hidden;background:var(--x-avatar-bg);color:var(--x-avatar-color);border:1px solid var(--x-avatar-border);box-shadow:0 0 0 2px var(--x-avatar-ring);font-size:var(--x-avatar-font-size);font-weight:600;line-height:1;user-select:none;border-radius:999px;}:host([data-shape\x3d'square']) [part\x3droot]{border-radius:0;}:host([data-shape\x3d'rounded']) [part\x3droot]{border-radius:var(--x-avatar-radius);}:host([disabled]){opacity:var(--x-avatar-disabled-opacity);}[part\x3dimage]{width:100%;height:100%;object-fit:cover;display:none;}[part\x3dinitials],[part\x3dfallback]{display:none;padding:0 0.25em;}[part\x3dstatus]{position:absolute;right:-1px;bottom:-1px;width:0.34em;height:0.34em;min-width:10px;min-height:10px;border-radius:999px;border:2px solid var(--x-avatar-ring);background:var(--x-avatar-status-color);display:none;}[part\x3dbadge]{position:absolute;top:-4px;right:-4px;display:none;}slot[name\x3dbadge]::slotted(*){display:block;}@media (prefers-reduced-motion:reduce){[part\x3droot]{transition:none !important;}}";
6
- d.setAttribute("part","root");e.setAttribute("part","image");e.setAttribute("alt","");g.setAttribute("part","initials");h.setAttribute("part","fallback");h.textContent="?";k.setAttribute("part","status");k.setAttribute("aria-hidden","true");m.setAttribute("part","badge");q.setAttribute("name","badge");m.appendChild(q);d.appendChild(e);d.appendChild(g);d.appendChild(h);b.appendChild(c);b.appendChild(d);b.appendChild(k);b.appendChild(m);a.__xAvatarRefs=new $APP.Q(null,7,[iF,d,jF,e,kF,g,lF,h,mF,k,nF,
7
- m,oF,q],null);return $APP.l(a,"__xAvatarRefs")},sF=function(a,b){b=$APP.N(b);var c=$APP.I(b,qF),d=$APP.I(b,$APP.sg),e=$APP.I(b,rF),g=$APP.I(b,$APP.Ng),h=$APP.I(b,$APP.yg),k=$APP.I(b,$APP.pi),m=pF(a),q=$APP.N(m);m=$APP.I(q,jF);var r=$APP.I(q,kF),v=$APP.I(q,lF),w=$APP.I(q,mF),z=$APP.I(q,nF),A=$APP.I(q,oF),D=$APP.K($APP.l(a,"__xAvatarImgOk")),G=c!=null;q=fF(b);var J=hF(b);D=G&&D;G=!D&&q!=null;var E=!D&&!G;A=$APP.n(A)?A.assignedNodes().length>0:null;a.setAttribute("data-size",d);a.setAttribute("data-shape",
8
- e);a.setAttribute("data-variant",g);$APP.n(J)?(a.setAttribute("role","img"),a.setAttribute("aria-label",J),a.removeAttribute("aria-hidden")):(a.removeAttribute("role"),a.removeAttribute("aria-label"),a.setAttribute("aria-hidden","true"));$APP.n(k)?a.setAttribute("aria-disabled","true"):a.removeAttribute("aria-disabled");c=$APP.n(c)?c:"";$APP.O(function(){var R=$APP.l(a,"__xAvatarLastSrc");return $APP.n(R)?R:""}(),c)&&(a.__xAvatarLastSrc=c,m.src=c);m.style.display=D?"block":"none";G&&(r.textContent=
9
- q);r.style.display=G?"inline":"none";v.style.display=E?"inline":"none";$APP.n(h)?(a.style.setProperty("--x-avatar-status-color",function(){switch(h){case "online":return"var(--x-avatar-status-online)";case "busy":return"var(--x-avatar-status-busy)";case "away":return"var(--x-avatar-status-away)";default:return"var(--x-avatar-status-offline)"}}()),w.style.display="block"):w.style.display="none";z.style.display=$APP.n(A)?"block":"none";a.__xAvatarModel=b},CF=function(a){var b=$APP.Xe([tF,$APP.xh,$APP.Dh,
10
- vF,$APP.uh,$APP.Sh,wF,xF,$APP.$h],[a.getAttribute("initials"),a.getAttribute("variant"),a.getAttribute("name"),a.getAttribute("shape"),a.getAttribute("status"),a.hasAttribute("disabled"),a.getAttribute("alt"),a.getAttribute("src"),a.getAttribute("size")]);var c=$APP.N(b),d=$APP.I(c,tF),e=$APP.I(c,$APP.xh),g=$APP.I(c,$APP.Dh);b=$APP.I(c,vF);var h=$APP.I(c,$APP.uh),k=$APP.I(c,wF),m=$APP.I(c,$APP.Sh),q=$APP.I(c,xF);c=$APP.I(c,$APP.$h);q=bF(q);k=bF(k);g=bF(g);d=bF(d);d=$APP.n(d)?d.length>3?d.slice(0,
11
- 3):d:null;var r=d==null?cF(g):null,v=[dF,$APP.pi,$APP.Ng,gF,$APP.ai,qF,$APP.sg,$APP.yg,eF,rF];m=$APP.K(m);e=aF(yF,"neutral",e);c=aF(zF,"md",c);h=typeof h==="string"?h.trim().toLowerCase():null;h=$APP.yc(AF,h)?h:null;b=$APP.Xe(v,[d,m,e,k,g,q,c,h,r,aF(BF,"circle",b)]);$APP.O($APP.l(a,"__xAvatarModel"),b)&&sF(a,b);return null},DF=function(a){function b(){return CF(a)}function c(){a.__xAvatarImgOk=!1;return CF(a)}function d(){a.__xAvatarImgOk=!0;return CF(a)}var e=pF(a),g=$APP.N(e);e=$APP.I(g,jF);g=$APP.I(g,
12
- oF);e.addEventListener("load",d);e.addEventListener("error",c);$APP.n(g)&&g.addEventListener("slotchange",b);$APP.la(a,"__xAvatarHandlers",{load:d,error:c,slot:b})},EF=function(a){var b=$APP.l(a,"__xAvatarHandlers");if($APP.n(b)){var c=$APP.l(a,"__xAvatarRefs");if($APP.n(c)){var d=jF.g(c);c=oF.g(c);var e=$APP.l(b,"load"),g=$APP.l(b,"error");b=$APP.l(b,"slot");$APP.n(e)&&d.removeEventListener("load",e);$APP.n(g)&&d.removeEventListener("error",g);$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",
13
- b)}}a.__xAvatarHandlers=null},FF=function(a,b){Object.defineProperty(a,b,{get:function(){return this.getAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""+$APP.T.g(c)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},GF=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},HF=function(a){FF(a,
14
- "src");FF(a,"alt");FF(a,"name");FF(a,"initials");GF(a,"size","md");GF(a,"shape","circle");GF(a,"variant","neutral");FF(a,"status");Object.defineProperty(a,"disabled",{get:function(){return this.hasAttribute("disabled")},set:function(b){return $APP.n(b)?this.setAttribute("disabled",""):this.removeAttribute("disabled")},enumerable:!0,configurable:!0})},JF=function(){var a=class extends HTMLElement{};a.observedAttributes=IF;a.prototype.connectedCallback=function(){pF(this);EF(this);DF(this);CF(this);
15
- return null};a.prototype.disconnectedCallback=function(){EF(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.O(c,d)&&($APP.C.h(b,"src")&&(this.__xAvatarImgOk=!1),CF(this));return null};HF(a.prototype);return a},KF=function(){$APP.n(customElements.get("x-avatar"))||customElements.define("x-avatar",JF());return null},qF=new $APP.M(null,"src","src",-1651076051),gF=new $APP.M(null,"alt","alt",-3214426),nF=new $APP.M(null,"badge-el","badge-el",1341875403),oF=new $APP.M(null,
16
- "badge-slot","badge-slot",2030670001),vF=new $APP.M(null,"shape-raw","shape-raw",1588938757),kF=new $APP.M(null,"initials-el","initials-el",2044340724),tF=new $APP.M(null,"initials-raw","initials-raw",1031756224),jF=new $APP.M(null,"img","img",1442687358),eF=new $APP.M(null,"derived","derived",1986040597),xF=new $APP.M(null,"src-raw","src-raw",-510472785),wF=new $APP.M(null,"alt-raw","alt-raw",-1423153400),lF=new $APP.M(null,"fallback-el","fallback-el",-208030239),iF=new $APP.M(null,"root-el","root-el",
17
- 1068654895),rF=new $APP.M(null,"shape","shape",1190694006),mF=new $APP.M(null,"status-el","status-el",2132204108),dF=new $APP.M(null,"initials","initials",-2130377215);var IF="src alt name initials size shape variant status disabled".split(" "),zF=new $APP.S(null,new $APP.Q(null,5,["xs",null,"md",null,"lg",null,"xl",null,"sm",null],null),null),BF=new $APP.S(null,new $APP.Q(null,3,["rounded",null,"square",null,"circle",null],null),null),yF=new $APP.S(null,new $APP.Q(null,3,["neutral",null,"brand",null,"subtle",null],null),null),AF=new $APP.S(null,new $APP.Q(null,4,["online",null,"away",null,"offline",null,"busy",null],null),null);
18
- $APP.Xe([dF,$APP.pi,$APP.Ng,gF,$APP.ai,qF,$APP.sg,$APP.yg,rF],[new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.Di],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null)]);$APP.ja("baredom.exports.x_avatar.init",KF);export const init=KF;
2
+ var lM=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.M(a,c)?c:b},mM=function(a){return typeof a==="string"?(a=a.trim(),$APP.C.h(a,"")?null:a):null},nM=function(a){a=mM(a);if($APP.n(a)){var b=$APP.ee($APP.Ld(function(c){return $APP.C.h(c,"")},a.split(/\s+/)));if($APP.u(b))return a=$APP.w(b)[0],b=$APP.B(b)>=2?$APP.w($APP.z(b))[0]:null,a=""+$APP.T.g(a)+$APP.T.g($APP.n(b)?b:""),$APP.C.h(a,"")?null:a.toUpperCase()}return null},qM=function(a){var b=$APP.O(a);a=$APP.I(b,oM);
3
+ b=$APP.I(b,pM);return $APP.n(a)?a:b},sM=function(a){var b=$APP.O(a);a=$APP.I(b,rM);b=$APP.I(b,$APP.mj);return $APP.n(a)?a:b},AM=function(a){var b=$APP.l(a,"__xAvatarRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("img"),g=document.createElement("span"),h=document.createElement("span"),k=document.createElement("span"),m=document.createElement("span"),p=document.createElement("slot");c.textContent=
4
+ ":host{display:inline-block;vertical-align:middle;position:relative;color-scheme:light dark;--x-avatar-size-xs:20px;--x-avatar-size-sm:24px;--x-avatar-size-md:32px;--x-avatar-size-lg:40px;--x-avatar-size-xl:48px;--x-avatar-radius:10px;--x-avatar-disabled-opacity:0.55;--x-avatar-bg:rgba(0,0,0,0.06);--x-avatar-border:rgba(0,0,0,0.14);--x-avatar-color:rgba(0,0,0,0.86);--x-avatar-ring:#ffffff;--x-avatar-status-online:rgba(16,140,72,0.95);--x-avatar-status-offline:rgba(0,0,0,0.45);--x-avatar-status-busy:rgba(190,20,40,0.95);--x-avatar-status-away:rgba(204,120,0,0.95);--x-avatar-status-color:transparent;--x-avatar-font-size:0.875rem;--x-avatar-size:var(--x-avatar-size-md);}@media (prefers-color-scheme:dark){:host{--x-avatar-bg:rgba(255,255,255,0.10);--x-avatar-border:rgba(255,255,255,0.18);--x-avatar-color:rgba(255,255,255,0.88);--x-avatar-ring:#0b0c0f;--x-avatar-status-online:rgba(60,210,120,0.95);--x-avatar-status-offline:rgba(255,255,255,0.45);--x-avatar-status-busy:rgba(255,90,110,0.95);--x-avatar-status-away:rgba(255,190,90,0.95);}}:host([data-size\x3d'xs']){--x-avatar-size:var(--x-avatar-size-xs);--x-avatar-font-size:0.625rem;}:host([data-size\x3d'sm']){--x-avatar-size:var(--x-avatar-size-sm);--x-avatar-font-size:0.75rem;}:host([data-size\x3d'md']){--x-avatar-size:var(--x-avatar-size-md);}:host([data-size\x3d'lg']){--x-avatar-size:var(--x-avatar-size-lg);--x-avatar-font-size:1rem;}:host([data-size\x3d'xl']){--x-avatar-size:var(--x-avatar-size-xl);--x-avatar-font-size:1.125rem;}:host([data-variant\x3d'brand']){--x-avatar-bg:rgba(0,102,204,0.10);--x-avatar-border:rgba(0,102,204,0.30);--x-avatar-color:rgba(0,60,120,0.90);}:host([data-variant\x3d'subtle']){--x-avatar-bg:rgba(0,0,0,0.03);--x-avatar-border:rgba(0,0,0,0.08);--x-avatar-color:rgba(0,0,0,0.55);}@media (prefers-color-scheme:dark){:host([data-variant\x3d'brand']){--x-avatar-bg:rgba(80,160,255,0.18);--x-avatar-border:rgba(80,160,255,0.40);--x-avatar-color:rgba(210,235,255,0.92);}:host([data-variant\x3d'subtle']){--x-avatar-bg:rgba(255,255,255,0.04);--x-avatar-border:rgba(255,255,255,0.08);--x-avatar-color:rgba(255,255,255,0.50);}}[part\x3droot]{width:var(--x-avatar-size);height:var(--x-avatar-size);display:inline-flex;align-items:center;justify-content:center;overflow:hidden;background:var(--x-avatar-bg);color:var(--x-avatar-color);border:1px solid var(--x-avatar-border);box-shadow:0 0 0 2px var(--x-avatar-ring);font-size:var(--x-avatar-font-size);font-weight:600;line-height:1;user-select:none;border-radius:999px;}:host([data-shape\x3d'square']) [part\x3droot]{border-radius:0;}:host([data-shape\x3d'rounded']) [part\x3droot]{border-radius:var(--x-avatar-radius);}:host([disabled]){opacity:var(--x-avatar-disabled-opacity);}[part\x3dimage]{width:100%;height:100%;object-fit:cover;display:none;}[part\x3dinitials],[part\x3dfallback]{display:none;padding:0 0.25em;}[part\x3dstatus]{position:absolute;right:-1px;bottom:-1px;width:0.34em;height:0.34em;min-width:10px;min-height:10px;border-radius:999px;border:2px solid var(--x-avatar-ring);background:var(--x-avatar-status-color);display:none;}[part\x3dbadge]{position:absolute;top:-4px;right:-4px;display:none;}slot[name\x3dbadge]::slotted(*){display:block;}@media (prefers-reduced-motion:reduce){[part\x3droot]{transition:none !important;}}";
5
+ d.setAttribute("part","root");e.setAttribute("part","image");e.setAttribute("alt","");g.setAttribute("part","initials");h.setAttribute("part","fallback");h.textContent="?";k.setAttribute("part","status");k.setAttribute("aria-hidden","true");m.setAttribute("part","badge");p.setAttribute("name","badge");m.appendChild(p);d.appendChild(e);d.appendChild(g);d.appendChild(h);b.appendChild(c);b.appendChild(d);b.appendChild(k);b.appendChild(m);a.__xAvatarRefs=new $APP.Q(null,7,[tM,d,uM,e,vM,g,wM,h,xM,k,yM,
6
+ m,zM,p],null);return $APP.l(a,"__xAvatarRefs")},CM=function(a,b){b=$APP.O(b);var c=$APP.I(b,BM),d=$APP.I(b,$APP.Pg),e=$APP.I(b,$APP.mk),g=$APP.I(b,$APP.sh),h=$APP.I(b,$APP.Wg),k=$APP.I(b,$APP.Fj),m=AM(a),p=$APP.O(m);m=$APP.I(p,uM);var r=$APP.I(p,vM),v=$APP.I(p,wM),x=$APP.I(p,xM),y=$APP.I(p,yM),A=$APP.I(p,zM),D=$APP.K($APP.l(a,"__xAvatarImgOk")),F=c!=null;p=qM(b);var J=sM(b);D=F&&D;F=!D&&p!=null;var G=!D&&!F;A=$APP.n(A)?A.assignedNodes().length>0:null;a.setAttribute("data-size",d);a.setAttribute("data-shape",
7
+ e);a.setAttribute("data-variant",g);$APP.n(J)?(a.setAttribute("role","img"),a.setAttribute("aria-label",J),a.removeAttribute("aria-hidden")):(a.removeAttribute("role"),a.removeAttribute("aria-label"),a.setAttribute("aria-hidden","true"));$APP.n(k)?a.setAttribute("aria-disabled","true"):a.removeAttribute("aria-disabled");c=$APP.n(c)?c:"";$APP.P(function(){var R=$APP.l(a,"__xAvatarLastSrc");return $APP.n(R)?R:""}(),c)&&(a.__xAvatarLastSrc=c,m.src=c);m.style.display=D?"block":"none";F&&(r.textContent=
8
+ p);r.style.display=F?"inline":"none";v.style.display=G?"inline":"none";$APP.n(h)?(a.style.setProperty("--x-avatar-status-color",function(){switch(h){case "online":return"var(--x-avatar-status-online)";case "busy":return"var(--x-avatar-status-busy)";case "away":return"var(--x-avatar-status-away)";default:return"var(--x-avatar-status-offline)"}}()),x.style.display="block"):x.style.display="none";y.style.display=$APP.n(A)?"block":"none";a.__xAvatarModel=b},LM=function(a){var b=$APP.ff([DM,$APP.qi,$APP.Ai,
9
+ EM,$APP.li,$APP.aj,FM,GM,$APP.lj],[a.getAttribute("initials"),a.getAttribute("variant"),a.getAttribute("name"),a.getAttribute("shape"),a.getAttribute("status"),a.hasAttribute("disabled"),a.getAttribute("alt"),a.getAttribute("src"),a.getAttribute("size")]);var c=$APP.O(b),d=$APP.I(c,DM),e=$APP.I(c,$APP.qi),g=$APP.I(c,$APP.Ai);b=$APP.I(c,EM);var h=$APP.I(c,$APP.li),k=$APP.I(c,FM),m=$APP.I(c,$APP.aj),p=$APP.I(c,GM);c=$APP.I(c,$APP.lj);p=mM(p);k=mM(k);g=mM(g);d=mM(d);d=$APP.n(d)?d.length>3?d.slice(0,
10
+ 3):d:null;var r=d==null?nM(g):null,v=[oM,$APP.Fj,$APP.sh,rM,$APP.mj,BM,$APP.Pg,$APP.Wg,pM,$APP.mk];m=$APP.K(m);e=lM(HM,"neutral",e);c=lM(IM,"md",c);h=typeof h==="string"?h.trim().toLowerCase():null;h=$APP.M(JM,h)?h:null;b=$APP.ff(v,[d,m,e,k,g,p,c,h,r,lM(KM,"circle",b)]);$APP.P($APP.l(a,"__xAvatarModel"),b)&&CM(a,b);return null},MM=function(a){function b(){return LM(a)}function c(){a.__xAvatarImgOk=!1;return LM(a)}function d(){a.__xAvatarImgOk=!0;return LM(a)}var e=AM(a),g=$APP.O(e);e=$APP.I(g,uM);
11
+ g=$APP.I(g,zM);e.addEventListener("load",d);e.addEventListener("error",c);$APP.n(g)&&g.addEventListener("slotchange",b);$APP.la(a,"__xAvatarHandlers",{load:d,error:c,slot:b})},NM=function(a){var b=$APP.l(a,"__xAvatarHandlers");if($APP.n(b)){var c=$APP.l(a,"__xAvatarRefs");if($APP.n(c)){var d=uM.g(c);c=zM.g(c);var e=$APP.l(b,"load"),g=$APP.l(b,"error");b=$APP.l(b,"slot");$APP.n(e)&&d.removeEventListener("load",e);$APP.n(g)&&d.removeEventListener("error",g);$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",
12
+ b)}}a.__xAvatarHandlers=null},OM=function(a,b){Object.defineProperty(a,b,{get:function(){return this.getAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""+$APP.T.g(c)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},PM=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},QM=function(a){OM(a,
13
+ "src");OM(a,"alt");OM(a,"name");OM(a,"initials");PM(a,"size","md");PM(a,"shape","circle");PM(a,"variant","neutral");OM(a,"status");Object.defineProperty(a,"disabled",{get:function(){return this.hasAttribute("disabled")},set:function(b){return $APP.n(b)?this.setAttribute("disabled",""):this.removeAttribute("disabled")},enumerable:!0,configurable:!0})},SM=function(){var a=class extends HTMLElement{};a.observedAttributes=RM;a.prototype.connectedCallback=function(){AM(this);NM(this);MM(this);LM(this);
14
+ return null};a.prototype.disconnectedCallback=function(){NM(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.P(c,d)&&($APP.C.h(b,"src")&&(this.__xAvatarImgOk=!1),LM(this));return null};QM(a.prototype);return a},TM=function(){$APP.n(customElements.get("x-avatar"))||customElements.define("x-avatar",SM());return null},BM=new $APP.N(null,"src","src",-1651076051),rM=new $APP.N(null,"alt","alt",-3214426),yM=new $APP.N(null,"badge-el","badge-el",1341875403),zM=new $APP.N(null,
15
+ "badge-slot","badge-slot",2030670001),EM=new $APP.N(null,"shape-raw","shape-raw",1588938757),vM=new $APP.N(null,"initials-el","initials-el",2044340724),DM=new $APP.N(null,"initials-raw","initials-raw",1031756224),uM=new $APP.N(null,"img","img",1442687358),pM=new $APP.N(null,"derived","derived",1986040597),GM=new $APP.N(null,"src-raw","src-raw",-510472785),FM=new $APP.N(null,"alt-raw","alt-raw",-1423153400),wM=new $APP.N(null,"fallback-el","fallback-el",-208030239),tM=new $APP.N(null,"root-el","root-el",
16
+ 1068654895),xM=new $APP.N(null,"status-el","status-el",2132204108),oM=new $APP.N(null,"initials","initials",-2130377215);var RM="src alt name initials size shape variant status disabled".split(" "),IM=new $APP.S(null,new $APP.Q(null,5,["xs",null,"md",null,"lg",null,"xl",null,"sm",null],null),null),KM=new $APP.S(null,new $APP.Q(null,3,["rounded",null,"square",null,"circle",null],null),null),HM=new $APP.S(null,new $APP.Q(null,3,["neutral",null,"brand",null,"subtle",null],null),null),JM=new $APP.S(null,new $APP.Q(null,4,["online",null,"away",null,"offline",null,"busy",null],null),null);
17
+ $APP.ff([oM,$APP.Fj,$APP.sh,rM,$APP.mj,BM,$APP.Pg,$APP.Wg,$APP.mk],[new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.Yj],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null),new $APP.Q(null,1,[$APP.Z,$APP.X],null)]);$APP.ja("baredom.exports.x_avatar.init",TM);export const init=TM;
package/dist/x-badge.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var wE=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.yc(a,c)?c:b},xE=function(a,b){if(typeof a==="string"){a=parseInt(a,10);var c=isFinite(a);return $APP.n($APP.n(c)?a>=0:c)?a:b}return b},CE=function(a){var b=$APP.N(a);a=$APP.I(b,yE);var c=$APP.I(b,$APP.zg),d=$APP.I(b,$APP.Fh);b=$APP.I(b,zE);return $APP.n(a)?AE:c!=null?$APP.zg:d!=null?$APP.Fh:$APP.n(b)?zE:BE},DE=function(a){var b=$APP.N(a);a=$APP.I(b,$APP.zg);var c=$APP.I(b,$APP.Yg),d=$APP.I(b,$APP.Fh);b=CE(b);switch(b instanceof
3
- $APP.M?b.na:null){case "count":return a>c?""+$APP.T.g(c)+"+":""+$APP.T.g(a);case "text":return d;default:return null}},KE=function(a){var b=$APP.N(a);a=$APP.I(b,$APP.wi);var c=$APP.I(b,EE),d=$APP.I(b,$APP.ci),e=$APP.I(b,FE),g=$APP.I(b,$APP.xh),h=$APP.I(b,$APP.rg),k=$APP.I(b,yE),m=$APP.I(b,$APP.ah),q=$APP.I(b,GE);b=$APP.I(b,$APP.$h);m=xE(m,99);var r=$APP.n(q)?function(){var v=xE(q,null);return v!=null?v:null}():null;return $APP.Xe([yE,$APP.Ng,HE,$APP.sg,$APP.Yg,$APP.zg,$APP.Pi,zE,$APP.Uh,$APP.Fh],
4
- [$APP.K(k),wE(IE,"neutral",g),e!=null&&$APP.O(e,"false"),wE(JE,"md",b),m,r,d,c!=null&&$APP.O(c,"false"),a,typeof h==="string"?function(){var v=h.trim();return $APP.C.h(v,"")?null:v}():null])},ME=function(a){var b=$APP.l(a,"__xBadgeRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("slot"),g=document.createElement("span");c.textContent=":host{display:inline-flex;vertical-align:middle;align-items:center;justify-content:center;color-scheme:light dark;--x-badge-bg:rgba(0,0,0,0.08);--x-badge-color:rgba(0,0,0,0.80);--x-badge-border:rgba(0,0,0,0.12);--x-badge-font-size:0.75rem;--x-badge-height:1.25rem;--x-badge-padding:0 0.375rem;--x-badge-radius:0.25rem;}@media (prefers-color-scheme:dark){:host{--x-badge-bg:rgba(255,255,255,0.12);--x-badge-color:rgba(255,255,255,0.88);--x-badge-border:rgba(255,255,255,0.14);}}:host([data-variant\x3d'info']){--x-badge-bg:rgba(0,102,204,0.12);--x-badge-color:rgba(0,60,140,0.90);--x-badge-border:rgba(0,102,204,0.25);}:host([data-variant\x3d'success']){--x-badge-bg:rgba(16,140,72,0.12);--x-badge-color:rgba(0,90,45,0.90);--x-badge-border:rgba(16,140,72,0.25);}:host([data-variant\x3d'warning']){--x-badge-bg:rgba(204,120,0,0.12);--x-badge-color:rgba(140,70,0,0.90);--x-badge-border:rgba(204,120,0,0.25);}:host([data-variant\x3d'error']){--x-badge-bg:rgba(190,20,40,0.12);--x-badge-color:rgba(140,0,20,0.90);--x-badge-border:rgba(190,20,40,0.25);}@media (prefers-color-scheme:dark){:host([data-variant\x3d'info']){--x-badge-bg:rgba(80,160,255,0.18);--x-badge-color:rgba(210,235,255,0.95);--x-badge-border:rgba(80,160,255,0.35);}:host([data-variant\x3d'success']){--x-badge-bg:rgba(60,210,120,0.18);--x-badge-color:rgba(200,255,230,0.95);--x-badge-border:rgba(60,210,120,0.35);}:host([data-variant\x3d'warning']){--x-badge-bg:rgba(255,190,90,0.18);--x-badge-color:rgba(255,235,180,0.95);--x-badge-border:rgba(255,190,90,0.35);}:host([data-variant\x3d'error']){--x-badge-bg:rgba(255,90,110,0.18);--x-badge-color:rgba(255,210,215,0.95);--x-badge-border:rgba(255,90,110,0.35);}}:host([data-size\x3d'sm']){--x-badge-font-size:0.6875rem;--x-badge-height:1rem;--x-badge-padding:0 0.25rem;--x-badge-radius:0.1875rem;}[part\x3dbase]{display:inline-flex;align-items:center;justify-content:center;min-height:var(--x-badge-height);padding:var(--x-badge-padding);border-radius:var(--x-badge-radius);border:1px solid var(--x-badge-border);background:var(--x-badge-bg);color:var(--x-badge-color);font-size:var(--x-badge-font-size);font-weight:600;line-height:1;white-space:nowrap;user-select:none;box-sizing:border-box;}:host([data-pill]) [part\x3dbase]{border-radius:999px;}:host([data-dot]) [part\x3dbase]{min-width:var(--x-badge-height);padding:0;}:host([data-mode\x3d'dot']) [part\x3dlabel],:host([data-mode\x3d'empty']) [part\x3dbase]{display:none;}slot{display:none;}:host([data-mode\x3d'slot']) slot{display:contents;}:host([data-mode\x3d'slot']) [part\x3dlabel]{display:none;}@media (prefers-reduced-motion:reduce){[part\x3dbase]{transition:none !important;}}";
5
- d.setAttribute("part","base");d.setAttribute("role","status");g.setAttribute("part","label");d.appendChild(e);d.appendChild(g);b.appendChild(c);b.appendChild(d);a.__xBadgeRefs=new $APP.Q(null,3,[LE,d,$APP.Jh,e,$APP.Ji,g],null);return $APP.l(a,"__xBadgeRefs")},NE=function(a){var b=ME(a);b=$APP.N(b);b=$APP.I(b,$APP.Jh);return KE($APP.Xe([$APP.xh,$APP.rg,yE,$APP.ah,$APP.$h,GE,$APP.wi,EE,$APP.ci,FE],[a.getAttribute("variant"),a.getAttribute("text"),$APP.n(b)?b.assignedNodes().length>0:null,a.getAttribute("max"),
6
- a.getAttribute("size"),a.getAttribute("count"),a.getAttribute("aria-label"),a.getAttribute("dot"),a.getAttribute("aria-describedby"),a.getAttribute("pill")]))},OE=function(a){var b=NE(a);if($APP.O($APP.l(a,"__xBadgeModel"),b)){b=$APP.N(b);var c=$APP.I(b,$APP.Ng),d=$APP.I(b,$APP.sg),e=$APP.I(b,HE),g=$APP.I(b,zE),h=$APP.I(b,$APP.Uh),k=$APP.I(b,$APP.Pi),m=ME(a),q=$APP.N(m);m=$APP.I(q,LE);q=$APP.I(q,$APP.Ji);var r=CE(b),v=DE(b);a.setAttribute("data-variant",c);a.setAttribute("data-size",d);a.setAttribute("data-mode",
7
- $APP.qf(r));$APP.n(e)?a.setAttribute("data-pill",""):a.removeAttribute("data-pill");$APP.n(g)?a.setAttribute("data-dot",""):a.removeAttribute("data-dot");q.textContent=$APP.n(v)?v:"";$APP.n(h)?m.setAttribute("aria-label",h):m.removeAttribute("aria-label");$APP.n(k)?m.setAttribute("aria-describedby",k):m.removeAttribute("aria-describedby");a.__xBadgeModel=b}return null},PE=function(a){function b(){return OE(a)}var c=ME(a);c=$APP.N(c);c=$APP.I(c,$APP.Jh);$APP.n(c)&&c.addEventListener("slotchange",b);
8
- $APP.la(a,"__xBadgeHandlers",{slot:b})},QE=function(a){var b=$APP.l(a,"__xBadgeHandlers");if($APP.n(b)){var c=$APP.l(a,"__xBadgeRefs");$APP.n(c)&&(c=$APP.Jh.g(c),b=$APP.l(b,"slot"),$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",b))}a.__xBadgeHandlers=null},RE=function(a,b){Object.defineProperty(a,b,{get:function(){return this.getAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""+$APP.T.g(c)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},SE=function(a,b,c){Object.defineProperty(a,
9
- b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},TE=function(a,b){Object.defineProperty(a,b,{get:function(){return this.hasAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""):this.removeAttribute(b)},enumerable:!0,configurable:!0})},UE=function(a,b,c){Object.defineProperty(a,b,{get:function(){return xE(this.getAttribute(b),c)},set:function(d){return d!=
10
- null?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},VE=function(a){SE(a,"variant","neutral");SE(a,"size","md");TE(a,"pill");TE(a,"dot");RE(a,"text");RE(a,"aria-label");RE(a,"aria-describedby");UE(a,"count",null);UE(a,"max",99);Object.defineProperty(a,"displayText",{get:function(){return DE(NE(this))},enumerable:!0,configurable:!0})},XE=function(){var a=class extends HTMLElement{};a.observedAttributes=WE;a.prototype.connectedCallback=function(){ME(this);
11
- QE(this);PE(this);OE(this);return null};a.prototype.disconnectedCallback=function(){QE(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.O(c,d)&&OE(this);return null};VE(a.prototype);return a},YE=function(){$APP.n(customElements.get("x-badge"))||customElements.define("x-badge",XE());return null},yE=new $APP.M(null,"has-slot?","has-slot?",181244965),BE=new $APP.M(null,"empty","empty",767870958),zE=new $APP.M(null,"dot","dot",1442709401),HE=new $APP.M(null,"pill","pill",-37707E3),
12
- GE=new $APP.M(null,"count-raw","count-raw",-952861839),AE=new $APP.M(null,"slot","slot",240229571),EE=new $APP.M(null,"dot-raw","dot-raw",1754908187),FE=new $APP.M(null,"pill-raw","pill-raw",-557846051),LE=new $APP.M(null,"base","base",185279322);var WE="variant size pill dot count max text aria-label aria-describedby".split(" "),IE=new $APP.S(null,new $APP.Q(null,5,["success",null,"neutral",null,"warning",null,"info",null,"error",null],null),null),JE=new $APP.S(null,new $APP.Q(null,2,["md",null,"sm",null],null),null);$APP.ja("baredom.exports.x_badge.init",YE);export const init=YE;
2
+ var KL=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.M(a,c)?c:b},LL=function(a,b){if(typeof a==="string"){a=parseInt(a,10);var c=isFinite(a);return $APP.n($APP.n(c)?a>=0:c)?a:b}return b},PL=function(a){var b=$APP.O(a);a=$APP.I(b,ML);var c=$APP.I(b,$APP.Xg),d=$APP.I(b,$APP.Ki);b=$APP.I(b,NL);return $APP.n(a)?$APP.Si:c!=null?$APP.Xg:d!=null?$APP.Ki:$APP.n(b)?NL:OL},QL=function(a){var b=$APP.O(a);a=$APP.I(b,$APP.Xg);var c=$APP.I(b,$APP.Hh),d=$APP.I(b,$APP.Ki);b=PL(b);
3
+ switch(b instanceof $APP.N?b.ra:null){case "count":return a>c?""+$APP.T.g(c)+"+":""+$APP.T.g(a);case "text":return d;default:return null}},XL=function(a){var b=$APP.O(a);a=$APP.I(b,$APP.Nj);var c=$APP.I(b,RL),d=$APP.I(b,$APP.oj),e=$APP.I(b,SL),g=$APP.I(b,$APP.qi),h=$APP.I(b,$APP.Og),k=$APP.I(b,ML),m=$APP.I(b,$APP.Lh),p=$APP.I(b,TL);b=$APP.I(b,$APP.lj);m=LL(m,99);var r=$APP.n(p)?function(){var v=LL(p,null);return v!=null?v:null}():null;return $APP.ff([ML,$APP.sh,UL,$APP.Pg,$APP.Hh,$APP.Xg,$APP.ok,
4
+ NL,$APP.cj,$APP.Ki],[$APP.K(k),KL(VL,"neutral",g),e!=null&&$APP.P(e,"false"),KL(WL,"md",b),m,r,d,c!=null&&$APP.P(c,"false"),a,typeof h==="string"?function(){var v=h.trim();return $APP.C.h(v,"")?null:v}():null])},ZL=function(a){var b=$APP.l(a,"__xBadgeRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("div"),e=document.createElement("slot"),g=document.createElement("span");c.textContent=":host{display:inline-flex;vertical-align:middle;align-items:center;justify-content:center;color-scheme:light dark;--x-badge-bg:rgba(0,0,0,0.08);--x-badge-color:rgba(0,0,0,0.80);--x-badge-border:rgba(0,0,0,0.12);--x-badge-font-size:0.75rem;--x-badge-height:1.25rem;--x-badge-padding:0 0.375rem;--x-badge-radius:0.25rem;}@media (prefers-color-scheme:dark){:host{--x-badge-bg:rgba(255,255,255,0.12);--x-badge-color:rgba(255,255,255,0.88);--x-badge-border:rgba(255,255,255,0.14);}}:host([data-variant\x3d'info']){--x-badge-bg:rgba(0,102,204,0.12);--x-badge-color:rgba(0,60,140,0.90);--x-badge-border:rgba(0,102,204,0.25);}:host([data-variant\x3d'success']){--x-badge-bg:rgba(16,140,72,0.12);--x-badge-color:rgba(0,90,45,0.90);--x-badge-border:rgba(16,140,72,0.25);}:host([data-variant\x3d'warning']){--x-badge-bg:rgba(204,120,0,0.12);--x-badge-color:rgba(140,70,0,0.90);--x-badge-border:rgba(204,120,0,0.25);}:host([data-variant\x3d'error']){--x-badge-bg:rgba(190,20,40,0.12);--x-badge-color:rgba(140,0,20,0.90);--x-badge-border:rgba(190,20,40,0.25);}@media (prefers-color-scheme:dark){:host([data-variant\x3d'info']){--x-badge-bg:rgba(80,160,255,0.18);--x-badge-color:rgba(210,235,255,0.95);--x-badge-border:rgba(80,160,255,0.35);}:host([data-variant\x3d'success']){--x-badge-bg:rgba(60,210,120,0.18);--x-badge-color:rgba(200,255,230,0.95);--x-badge-border:rgba(60,210,120,0.35);}:host([data-variant\x3d'warning']){--x-badge-bg:rgba(255,190,90,0.18);--x-badge-color:rgba(255,235,180,0.95);--x-badge-border:rgba(255,190,90,0.35);}:host([data-variant\x3d'error']){--x-badge-bg:rgba(255,90,110,0.18);--x-badge-color:rgba(255,210,215,0.95);--x-badge-border:rgba(255,90,110,0.35);}}:host([data-size\x3d'sm']){--x-badge-font-size:0.6875rem;--x-badge-height:1rem;--x-badge-padding:0 0.25rem;--x-badge-radius:0.1875rem;}[part\x3dbase]{display:inline-flex;align-items:center;justify-content:center;min-height:var(--x-badge-height);padding:var(--x-badge-padding);border-radius:var(--x-badge-radius);border:1px solid var(--x-badge-border);background:var(--x-badge-bg);color:var(--x-badge-color);font-size:var(--x-badge-font-size);font-weight:600;line-height:1;white-space:nowrap;user-select:none;box-sizing:border-box;}:host([data-pill]) [part\x3dbase]{border-radius:999px;}:host([data-dot]) [part\x3dbase]{min-width:var(--x-badge-height);padding:0;}:host([data-mode\x3d'dot']) [part\x3dlabel],:host([data-mode\x3d'empty']) [part\x3dbase]{display:none;}slot{display:none;}:host([data-mode\x3d'slot']) slot{display:contents;}:host([data-mode\x3d'slot']) [part\x3dlabel]{display:none;}@media (prefers-reduced-motion:reduce){[part\x3dbase]{transition:none !important;}}";
5
+ d.setAttribute("part","base");d.setAttribute("role","status");g.setAttribute("part","label");d.appendChild(e);d.appendChild(g);b.appendChild(c);b.appendChild(d);a.__xBadgeRefs=new $APP.Q(null,3,[YL,d,$APP.Pi,e,$APP.hk,g],null);return $APP.l(a,"__xBadgeRefs")},$L=function(a){var b=ZL(a);b=$APP.O(b);b=$APP.I(b,$APP.Pi);return XL($APP.ff([$APP.qi,$APP.Og,ML,$APP.Lh,$APP.lj,TL,$APP.Nj,RL,$APP.oj,SL],[a.getAttribute("variant"),a.getAttribute("text"),$APP.n(b)?b.assignedNodes().length>0:null,a.getAttribute("max"),
6
+ a.getAttribute("size"),a.getAttribute("count"),a.getAttribute("aria-label"),a.getAttribute("dot"),a.getAttribute("aria-describedby"),a.getAttribute("pill")]))},aM=function(a){var b=$L(a);if($APP.P($APP.l(a,"__xBadgeModel"),b)){b=$APP.O(b);var c=$APP.I(b,$APP.sh),d=$APP.I(b,$APP.Pg),e=$APP.I(b,UL),g=$APP.I(b,NL),h=$APP.I(b,$APP.cj),k=$APP.I(b,$APP.ok),m=ZL(a),p=$APP.O(m);m=$APP.I(p,YL);p=$APP.I(p,$APP.hk);var r=PL(b),v=QL(b);a.setAttribute("data-variant",c);a.setAttribute("data-size",d);a.setAttribute("data-mode",
7
+ $APP.If(r));$APP.n(e)?a.setAttribute("data-pill",""):a.removeAttribute("data-pill");$APP.n(g)?a.setAttribute("data-dot",""):a.removeAttribute("data-dot");p.textContent=$APP.n(v)?v:"";$APP.n(h)?m.setAttribute("aria-label",h):m.removeAttribute("aria-label");$APP.n(k)?m.setAttribute("aria-describedby",k):m.removeAttribute("aria-describedby");a.__xBadgeModel=b}return null},bM=function(a){function b(){return aM(a)}var c=ZL(a);c=$APP.O(c);c=$APP.I(c,$APP.Pi);$APP.n(c)&&c.addEventListener("slotchange",b);
8
+ $APP.la(a,"__xBadgeHandlers",{slot:b})},cM=function(a){var b=$APP.l(a,"__xBadgeHandlers");if($APP.n(b)){var c=$APP.l(a,"__xBadgeRefs");$APP.n(c)&&(c=$APP.Pi.g(c),b=$APP.l(b,"slot"),$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",b))}a.__xBadgeHandlers=null},dM=function(a,b){Object.defineProperty(a,b,{get:function(){return this.getAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""+$APP.T.g(c)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},eM=function(a,b,c){Object.defineProperty(a,
9
+ b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},fM=function(a,b){Object.defineProperty(a,b,{get:function(){return this.hasAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""):this.removeAttribute(b)},enumerable:!0,configurable:!0})},gM=function(a,b,c){Object.defineProperty(a,b,{get:function(){return LL(this.getAttribute(b),c)},set:function(d){return d!=
10
+ null?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},hM=function(a){eM(a,"variant","neutral");eM(a,"size","md");fM(a,"pill");fM(a,"dot");dM(a,"text");dM(a,"aria-label");dM(a,"aria-describedby");gM(a,"count",null);gM(a,"max",99);Object.defineProperty(a,"displayText",{get:function(){return QL($L(this))},enumerable:!0,configurable:!0})},jM=function(){var a=class extends HTMLElement{};a.observedAttributes=iM;a.prototype.connectedCallback=function(){ZL(this);
11
+ cM(this);bM(this);aM(this);return null};a.prototype.disconnectedCallback=function(){cM(this);return null};a.prototype.attributeChangedCallback=function(b,c,d){$APP.P(c,d)&&aM(this);return null};hM(a.prototype);return a},kM=function(){$APP.n(customElements.get("x-badge"))||customElements.define("x-badge",jM());return null},ML=new $APP.N(null,"has-slot?","has-slot?",181244965),OL=new $APP.N(null,"empty","empty",767870958),NL=new $APP.N(null,"dot","dot",1442709401),UL=new $APP.N(null,"pill","pill",-37707E3),
12
+ TL=new $APP.N(null,"count-raw","count-raw",-952861839),RL=new $APP.N(null,"dot-raw","dot-raw",1754908187),SL=new $APP.N(null,"pill-raw","pill-raw",-557846051),YL=new $APP.N(null,"base","base",185279322);var iM="variant size pill dot count max text aria-label aria-describedby".split(" "),VL=new $APP.S(null,new $APP.Q(null,5,["success",null,"neutral",null,"warning",null,"info",null,"error",null],null),null),WL=new $APP.S(null,new $APP.Q(null,2,["md",null,"sm",null],null),null);$APP.ja("baredom.exports.x_badge.init",kM);export const init=kM;
@@ -1,15 +1,15 @@
1
1
  import { $APP, shadow$provide } from "./base.js";
2
- var Ln=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.yc(a,c)?c:b},Mn=function(a,b){if(typeof a==="string"){a=parseInt(a,10);var c=isFinite(a);return $APP.n($APP.n(c)?a>0:c)?a:b}return b},Nn=function(a){var b=$APP.l(a,"__xBreadcrumbsRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("nav"),e=document.createElement("ol"),g=document.createElement("slot");c.textContent=":host{display:block;color-scheme:light dark;--x-breadcrumbs-color:rgba(0,0,0,0.55);--x-breadcrumbs-color-current:rgba(0,0,0,0.88);--x-breadcrumbs-color-hover:rgba(0,0,0,0.80);--x-breadcrumbs-separator-color:rgba(0,0,0,0.35);--x-breadcrumbs-font-size:0.875rem;--x-breadcrumbs-gap:0.25rem;--x-breadcrumbs-disabled-opacity:0.55;}@media (prefers-color-scheme:dark){:host{--x-breadcrumbs-color:rgba(255,255,255,0.50);--x-breadcrumbs-color-current:rgba(255,255,255,0.90);--x-breadcrumbs-color-hover:rgba(255,255,255,0.75);--x-breadcrumbs-separator-color:rgba(255,255,255,0.30);}}:host([data-size\x3d'sm']){--x-breadcrumbs-font-size:0.75rem;}:host([data-size\x3d'lg']){--x-breadcrumbs-font-size:1rem;}:host([disabled]){opacity:var(--x-breadcrumbs-disabled-opacity);pointer-events:none;}[part\x3droot]{display:block;font-size:var(--x-breadcrumbs-font-size);}[part\x3dlist]{display:flex;flex-wrap:wrap;align-items:center;list-style:none;margin:0;padding:0;gap:var(--x-breadcrumbs-gap);}:host([data-wrap\x3d'false']) [part\x3dlist]{flex-wrap:nowrap;}.crumb{display:inline-flex;align-items:center;gap:var(--x-breadcrumbs-gap);}.crumb-content{color:var(--x-breadcrumbs-color);text-decoration:none;cursor:pointer;}.crumb-content:hover{color:var(--x-breadcrumbs-color-hover);}.crumb[data-current] .crumb-content{color:var(--x-breadcrumbs-color-current);font-weight:500;}:host([data-variant\x3d'subtle']) .crumb-content{opacity:0.75;}:host([data-variant\x3d'text']) .crumb-content{text-decoration:none;border-bottom:none;}.separator{color:var(--x-breadcrumbs-separator-color);user-select:none;aria-hidden:true;flex-shrink:0;}.ellipsis{display:inline-flex;align-items:center;gap:var(--x-breadcrumbs-gap);}.ellipsis-btn{color:var(--x-breadcrumbs-color);background:none;border:none;padding:0;cursor:pointer;font:inherit;line-height:1;}.ellipsis-btn:hover{color:var(--x-breadcrumbs-color-hover);}slot{display:none;}@media (prefers-reduced-motion:reduce){[part\x3dlist]{transition:none !important;}}";
3
- d.setAttribute("part","root");e.setAttribute("part","list");d.appendChild(e);b.appendChild(c);b.appendChild(d);b.appendChild(g);a.__xBreadcrumbsRefs=new $APP.Q(null,3,[$APP.fh,d,$APP.eh,e,$APP.Jh,g],null);return $APP.l(a,"__xBreadcrumbsRefs")},On=function(a){var b=document.createElement("span");b.setAttribute("class","separator");b.setAttribute("aria-hidden","true");b.textContent=a;return b},Pn=function(a){var b=document.createElement("li"),c=document.createElement("span"),d=document.createElement("button");
4
- b.setAttribute("class","ellipsis");c.setAttribute("class","separator");c.setAttribute("aria-hidden","true");c.textContent=a;d.setAttribute("class","ellipsis-btn");d.setAttribute("aria-label","Show hidden breadcrumbs");d.textContent="…";b.appendChild(c);b.appendChild(d);return b},Qn=function(a,b){var c=document.createElement("li"),d=document.createElement("span");a=a.cloneNode(!0);c.setAttribute("class","crumb");d.setAttribute("class","crumb-content");d.appendChild(a);c.appendChild(d);$APP.n(b)&&(c.setAttribute("data-current",
5
- ""),d.setAttribute("aria-current","page"));return c},go=function(a){var b=$APP.Xe([$APP.xh,Rn,$APP.Sh,Sn,Tn,$APP.$h,Un,Vn,$APP.wi,Wn,$APP.ci],[a.getAttribute("variant"),a.getAttribute("max-items"),a.hasAttribute("disabled"),a.getAttribute("wrap"),a.getAttribute("items-after"),a.getAttribute("size"),a.hasAttribute("preserve-aria-current"),a.getAttribute("items-before"),a.getAttribute("aria-label"),a.getAttribute("separator"),a.getAttribute("aria-describedby")]);var c=$APP.N(b);b=$APP.I(c,$APP.wi);
6
- var d=$APP.I(c,Wn),e=$APP.I(c,$APP.ci),g=$APP.I(c,Rn),h=$APP.I(c,$APP.xh),k=$APP.I(c,$APP.Sh),m=$APP.I(c,Tn),q=$APP.I(c,Sn),r=$APP.I(c,$APP.$h),v=$APP.I(c,Un);c=$APP.I(c,Vn);v=$APP.K(v);m=Mn(m,2);q=q!=null&&$APP.O(q,"false");k=$APP.K(k);h=Ln(Xn,"default",h);if(typeof g==="string"){g=parseInt(g,10);var w=isFinite(g);g=$APP.n($APP.n(w)?g>0:w)?g:null}else g=null;b=$APP.Xe([Yn,Zn,$n,$APP.pi,$APP.Ng,ao,$APP.sg,$APP.Pi,bo,$APP.Uh,$APP.hh],[v,m,q,k,h,g,Ln(co,"md",r),e,Mn(c,1),b,typeof d==="string"?d:"/"]);
7
- b=$APP.N(b);d=$APP.I(b,$APP.sg);e=$APP.I(b,$APP.Ng);r=$APP.I(b,$n);$APP.I(b,$APP.pi);c=$APP.I(b,$APP.Uh);v=$APP.I(b,$APP.Pi);g=Nn(a);g=$APP.N(g);g=$APP.I(g,$APP.fh);a.setAttribute("data-size",d);a.setAttribute("data-variant",e);a.setAttribute("data-wrap",""+$APP.T.g($APP.K(r)));$APP.n(c)?g.setAttribute("aria-label",c):g.setAttribute("aria-label","Breadcrumb");$APP.n(v)?g.setAttribute("aria-describedby",v):g.removeAttribute("aria-describedby");e=$APP.N(b);d=$APP.I(e,$APP.hh);m=$APP.I(e,ao);h=$APP.I(e,
8
- bo);g=$APP.I(e,Zn);e=$APP.I(e,Yn);r=Nn(a);r=$APP.N(r);c=$APP.I(r,$APP.Jh);r=$APP.I(r,$APP.eh);c=$APP.ec(c.assignedElements());v=$APP.B(c);m==null||v<=m?g=new $APP.Q(null,3,[$APP.Oh,$APP.Wd($APP.wf(0,v)),eo,-1,fo,v],null):(m=$APP.eg.h(h,$APP.dg.h(0,v-g)),g=$APP.eg.h(g,$APP.dg.h(0,v-m)),m=$APP.eg.h(m,v-g),m=$APP.dg.h(0,m),m=$APP.Wd($APP.wf(0,m)),g=$APP.Wd($APP.wf(v-g,v)),g=new $APP.Q(null,3,[$APP.Oh,$APP.ve.h(m,g),eo,$APP.B(m),fo,v],null));v=$APP.Oh.g(g);g=eo.g(g);r.innerHTML="";m=$APP.u($APP.yd($APP.hg,
9
- v));h=null;for(k=q=0;;)if(k<q){var z=h.D(null,k);w=$APP.H(z,0,null);z=$APP.H(z,1,null);z=$APP.H(c,z,null);var A=$APP.C.h(w,$APP.B(v)-1)&&$APP.p(e);$APP.C.h(w,g)&&r.appendChild(Pn(d));w>0&&!$APP.C.h(w,g)&&r.appendChild(On(d));$APP.C.h(w,g)&&r.appendChild(On(d));$APP.n(z)&&r.appendChild(Qn(z,A));k+=1}else if(m=$APP.u(m))$APP.uc(m)?(q=$APP.mb(m),m=$APP.nb(m),h=q,q=$APP.B(q)):(q=$APP.x(m),h=$APP.H(q,0,null),q=$APP.H(q,1,null),q=$APP.H(c,q,null),k=$APP.C.h(h,$APP.B(v)-1)&&$APP.p(e),$APP.C.h(h,g)&&r.appendChild(Pn(d)),
10
- h>0&&!$APP.C.h(h,g)&&r.appendChild(On(d)),$APP.C.h(h,g)&&r.appendChild(On(d)),$APP.n(q)&&r.appendChild(Qn(q,k)),m=$APP.y(m),h=null,q=0),k=0;else break;$APP.C.h(g,$APP.B(v))&&r.appendChild(Pn(d));a.__xBreadcrumbsModel=b;return null},ho=function(a){function b(){return go(a)}var c=Nn(a);c=$APP.N(c);c=$APP.I(c,$APP.Jh);$APP.n(c)&&c.addEventListener("slotchange",b);$APP.la(a,"__xBreadcrumbsHandlers",{slot:b})},io=function(a){var b=$APP.l(a,"__xBreadcrumbsHandlers");if($APP.n(b)){var c=$APP.l(a,"__xBreadcrumbsRefs");
11
- $APP.n(c)&&(c=$APP.Jh.g(c),b=$APP.l(b,"slot"),$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",b))}a.__xBreadcrumbsHandlers=null},jo=function(a,b){Object.defineProperty(a,b,{get:function(){return this.getAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""+$APP.T.g(c)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},ko=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,
12
- ""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},lo=function(a,b){Object.defineProperty(a,b,{get:function(){return this.hasAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""):this.removeAttribute(b)},enumerable:!0,configurable:!0})},mo=function(a,b,c){Object.defineProperty(a,b,{get:function(){return Mn(this.getAttribute(b),c)},set:function(d){return d!=null?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},no=
13
- function(a){ko(a,"separator","/");ko(a,"size","md");ko(a,"variant","default");lo(a,"wrap");lo(a,"disabled");lo(a,"preserve-aria-current");mo(a,"max-items",null);mo(a,"items-before",1);mo(a,"items-after",2);jo(a,"aria-label");jo(a,"aria-describedby")},po=function(){var a=class extends HTMLElement{};a.observedAttributes=oo;a.prototype.connectedCallback=function(){Nn(this);io(this);ho(this);go(this);return null};a.prototype.disconnectedCallback=function(){io(this);return null};a.prototype.attributeChangedCallback=
14
- function(b,c,d){$APP.O(c,d)&&go(this);return null};no(a.prototype);return a},qo=function(){$APP.n(customElements.get("x-breadcrumbs"))||customElements.define("x-breadcrumbs",po());return null},Rn=new $APP.M(null,"max-items-raw","max-items-raw",-340487390),Zn=new $APP.M(null,"items-after","items-after",358736705),$n=new $APP.M(null,"wrap","wrap",851669987),Sn=new $APP.M(null,"wrap-raw","wrap-raw",-1468030804),ao=new $APP.M(null,"max-items","max-items",-1969244147),Wn=new $APP.M(null,"separator-raw",
15
- "separator-raw",1358337914),eo=new $APP.M(null,"ellipsis-at","ellipsis-at",-628372349),Un=new $APP.M(null,"preserve-aria-current-present?","preserve-aria-current-present?",729931506),Vn=new $APP.M(null,"items-before-raw","items-before-raw",1580997624),Tn=new $APP.M(null,"items-after-raw","items-after-raw",-1677187220),bo=new $APP.M(null,"items-before","items-before",-1151895719),Yn=new $APP.M(null,"preserve-aria-current","preserve-aria-current",682773185),fo=new $APP.M(null,"total","total",1916810418);var oo="separator size variant wrap max-items items-before items-after disabled preserve-aria-current aria-label aria-describedby".split(" "),co=new $APP.S(null,new $APP.Q(null,3,["md",null,"lg",null,"sm",null],null),null),Xn=new $APP.S(null,new $APP.Q(null,3,["subtle",null,"text",null,"default",null],null),null);$APP.ja("baredom.exports.x_breadcrumbs.init",qo);export const init=qo;
2
+ var Gp=function(a,b,c){c=typeof c==="string"?c.trim().toLowerCase():null;return $APP.M(a,c)?c:b},Hp=function(a,b){if(typeof a==="string"){a=parseInt(a,10);var c=isFinite(a);return $APP.n($APP.n(c)?a>0:c)?a:b}return b},Ip=function(a){var b=$APP.l(a,"__xBreadcrumbsRefs");if($APP.n(b))return b;b=a.attachShadow({mode:"open"});var c=document.createElement("style"),d=document.createElement("nav"),e=document.createElement("ol"),g=document.createElement("slot");c.textContent=":host{display:block;color-scheme:light dark;--x-breadcrumbs-color:rgba(0,0,0,0.55);--x-breadcrumbs-color-current:rgba(0,0,0,0.88);--x-breadcrumbs-color-hover:rgba(0,0,0,0.80);--x-breadcrumbs-separator-color:rgba(0,0,0,0.35);--x-breadcrumbs-font-size:0.875rem;--x-breadcrumbs-gap:0.25rem;--x-breadcrumbs-disabled-opacity:0.55;}@media (prefers-color-scheme:dark){:host{--x-breadcrumbs-color:rgba(255,255,255,0.50);--x-breadcrumbs-color-current:rgba(255,255,255,0.90);--x-breadcrumbs-color-hover:rgba(255,255,255,0.75);--x-breadcrumbs-separator-color:rgba(255,255,255,0.30);}}:host([data-size\x3d'sm']){--x-breadcrumbs-font-size:0.75rem;}:host([data-size\x3d'lg']){--x-breadcrumbs-font-size:1rem;}:host([disabled]){opacity:var(--x-breadcrumbs-disabled-opacity);pointer-events:none;}[part\x3droot]{display:block;font-size:var(--x-breadcrumbs-font-size);}[part\x3dlist]{display:flex;flex-wrap:wrap;align-items:center;list-style:none;margin:0;padding:0;gap:var(--x-breadcrumbs-gap);}:host([data-wrap\x3d'false']) [part\x3dlist]{flex-wrap:nowrap;}.crumb{display:inline-flex;align-items:center;gap:var(--x-breadcrumbs-gap);}.crumb-content{color:var(--x-breadcrumbs-color);text-decoration:none;cursor:pointer;}.crumb-content:hover{color:var(--x-breadcrumbs-color-hover);}.crumb[data-current] .crumb-content{color:var(--x-breadcrumbs-color-current);font-weight:500;}:host([data-variant\x3d'subtle']) .crumb-content{opacity:0.75;}:host([data-variant\x3d'text']) .crumb-content{text-decoration:none;border-bottom:none;}.separator{color:var(--x-breadcrumbs-separator-color);user-select:none;aria-hidden:true;flex-shrink:0;}.ellipsis{display:inline-flex;align-items:center;gap:var(--x-breadcrumbs-gap);}.ellipsis-btn{color:var(--x-breadcrumbs-color);background:none;border:none;padding:0;cursor:pointer;font:inherit;line-height:1;}.ellipsis-btn:hover{color:var(--x-breadcrumbs-color-hover);}slot{display:none;}@media (prefers-reduced-motion:reduce){[part\x3dlist]{transition:none !important;}}";
3
+ d.setAttribute("part","root");e.setAttribute("part","list");d.appendChild(e);b.appendChild(c);b.appendChild(d);b.appendChild(g);a.__xBreadcrumbsRefs=new $APP.Q(null,3,[$APP.Rh,d,$APP.Ph,e,$APP.Pi,g],null);return $APP.l(a,"__xBreadcrumbsRefs")},Jp=function(a){var b=document.createElement("span");b.setAttribute("class","separator");b.setAttribute("aria-hidden","true");b.textContent=a;return b},Kp=function(a){var b=document.createElement("li"),c=document.createElement("span"),d=document.createElement("button");
4
+ b.setAttribute("class","ellipsis");c.setAttribute("class","separator");c.setAttribute("aria-hidden","true");c.textContent=a;d.setAttribute("class","ellipsis-btn");d.setAttribute("aria-label","Show hidden breadcrumbs");d.textContent="…";b.appendChild(c);b.appendChild(d);return b},Lp=function(a,b){var c=document.createElement("li"),d=document.createElement("span");a=a.cloneNode(!0);c.setAttribute("class","crumb");d.setAttribute("class","crumb-content");d.appendChild(a);c.appendChild(d);$APP.n(b)&&(c.setAttribute("data-current",
5
+ ""),d.setAttribute("aria-current","page"));return c},aq=function(a){var b=$APP.ff([$APP.qi,Mp,$APP.aj,Np,Op,$APP.lj,Pp,Qp,$APP.Nj,Rp,$APP.oj],[a.getAttribute("variant"),a.getAttribute("max-items"),a.hasAttribute("disabled"),a.getAttribute("wrap"),a.getAttribute("items-after"),a.getAttribute("size"),a.hasAttribute("preserve-aria-current"),a.getAttribute("items-before"),a.getAttribute("aria-label"),a.getAttribute("separator"),a.getAttribute("aria-describedby")]);var c=$APP.O(b);b=$APP.I(c,$APP.Nj);
6
+ var d=$APP.I(c,Rp),e=$APP.I(c,$APP.oj),g=$APP.I(c,Mp),h=$APP.I(c,$APP.qi),k=$APP.I(c,$APP.aj),m=$APP.I(c,Op),p=$APP.I(c,Np),r=$APP.I(c,$APP.lj),v=$APP.I(c,Pp);c=$APP.I(c,Qp);v=$APP.K(v);m=Hp(m,2);p=p!=null&&$APP.P(p,"false");k=$APP.K(k);h=Gp(Sp,"default",h);if(typeof g==="string"){g=parseInt(g,10);var x=isFinite(g);g=$APP.n($APP.n(x)?g>0:x)?g:null}else g=null;b=$APP.ff([Tp,Up,Vp,$APP.Fj,$APP.sh,Wp,$APP.Pg,$APP.ok,Xp,$APP.cj,$APP.Th],[v,m,p,k,h,g,Gp(Yp,"md",r),e,Hp(c,1),b,typeof d==="string"?d:"/"]);
7
+ b=$APP.O(b);d=$APP.I(b,$APP.Pg);e=$APP.I(b,$APP.sh);r=$APP.I(b,Vp);$APP.I(b,$APP.Fj);c=$APP.I(b,$APP.cj);v=$APP.I(b,$APP.ok);g=Ip(a);g=$APP.O(g);g=$APP.I(g,$APP.Rh);a.setAttribute("data-size",d);a.setAttribute("data-variant",e);a.setAttribute("data-wrap",""+$APP.T.g($APP.K(r)));$APP.n(c)?g.setAttribute("aria-label",c):g.setAttribute("aria-label","Breadcrumb");$APP.n(v)?g.setAttribute("aria-describedby",v):g.removeAttribute("aria-describedby");e=$APP.O(b);d=$APP.I(e,$APP.Th);m=$APP.I(e,Wp);h=$APP.I(e,
8
+ Xp);g=$APP.I(e,Up);e=$APP.I(e,Tp);r=Ip(a);r=$APP.O(r);c=$APP.I(r,$APP.Pi);r=$APP.I(r,$APP.Ph);c=$APP.gc(c.assignedElements());v=$APP.B(c);m==null||v<=m?g=new $APP.Q(null,3,[$APP.Xi,$APP.ee($APP.Of(0,v)),Zp,-1,$p,v],null):(m=$APP.Ag.h(h,$APP.zg.h(0,v-g)),g=$APP.Ag.h(g,$APP.zg.h(0,v-m)),m=$APP.Ag.h(m,v-g),m=$APP.zg.h(0,m),m=$APP.ee($APP.Of(0,m)),g=$APP.ee($APP.Of(v-g,v)),g=new $APP.Q(null,3,[$APP.Xi,$APP.De.h(m,g),Zp,$APP.B(m),$p,v],null));v=$APP.Xi.g(g);g=Zp.g(g);r.innerHTML="";m=$APP.u($APP.Ed($APP.Dg,
9
+ v));h=null;for(k=p=0;;)if(k<p){var y=h.H(null,k);x=$APP.H(y,0,null);y=$APP.H(y,1,null);y=$APP.H(c,y,null);var A=$APP.C.h(x,$APP.B(v)-1)&&$APP.q(e);$APP.C.h(x,g)&&r.appendChild(Kp(d));x>0&&!$APP.C.h(x,g)&&r.appendChild(Jp(d));$APP.C.h(x,g)&&r.appendChild(Jp(d));$APP.n(y)&&r.appendChild(Lp(y,A));k+=1}else if(m=$APP.u(m))$APP.yc(m)?(p=$APP.nb(m),m=$APP.ob(m),h=p,p=$APP.B(p)):(p=$APP.w(m),h=$APP.H(p,0,null),p=$APP.H(p,1,null),p=$APP.H(c,p,null),k=$APP.C.h(h,$APP.B(v)-1)&&$APP.q(e),$APP.C.h(h,g)&&r.appendChild(Kp(d)),
10
+ h>0&&!$APP.C.h(h,g)&&r.appendChild(Jp(d)),$APP.C.h(h,g)&&r.appendChild(Jp(d)),$APP.n(p)&&r.appendChild(Lp(p,k)),m=$APP.z(m),h=null,p=0),k=0;else break;$APP.C.h(g,$APP.B(v))&&r.appendChild(Kp(d));a.__xBreadcrumbsModel=b;return null},bq=function(a){function b(){return aq(a)}var c=Ip(a);c=$APP.O(c);c=$APP.I(c,$APP.Pi);$APP.n(c)&&c.addEventListener("slotchange",b);$APP.la(a,"__xBreadcrumbsHandlers",{slot:b})},cq=function(a){var b=$APP.l(a,"__xBreadcrumbsHandlers");if($APP.n(b)){var c=$APP.l(a,"__xBreadcrumbsRefs");
11
+ $APP.n(c)&&(c=$APP.Pi.g(c),b=$APP.l(b,"slot"),$APP.n($APP.n(c)?b:c)&&c.removeEventListener("slotchange",b))}a.__xBreadcrumbsHandlers=null},dq=function(a,b){Object.defineProperty(a,b,{get:function(){return this.getAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""+$APP.T.g(c)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},eq=function(a,b,c){Object.defineProperty(a,b,{get:function(){var d=this.getAttribute(b);return $APP.n(d)?d:c},set:function(d){return $APP.n(d)?this.setAttribute(b,
12
+ ""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},fq=function(a,b){Object.defineProperty(a,b,{get:function(){return this.hasAttribute(b)},set:function(c){return $APP.n(c)?this.setAttribute(b,""):this.removeAttribute(b)},enumerable:!0,configurable:!0})},gq=function(a,b,c){Object.defineProperty(a,b,{get:function(){return Hp(this.getAttribute(b),c)},set:function(d){return d!=null?this.setAttribute(b,""+$APP.T.g(d)):this.removeAttribute(b)},enumerable:!0,configurable:!0})},hq=
13
+ function(a){eq(a,"separator","/");eq(a,"size","md");eq(a,"variant","default");fq(a,"wrap");fq(a,"disabled");fq(a,"preserve-aria-current");gq(a,"max-items",null);gq(a,"items-before",1);gq(a,"items-after",2);dq(a,"aria-label");dq(a,"aria-describedby")},jq=function(){var a=class extends HTMLElement{};a.observedAttributes=iq;a.prototype.connectedCallback=function(){Ip(this);cq(this);bq(this);aq(this);return null};a.prototype.disconnectedCallback=function(){cq(this);return null};a.prototype.attributeChangedCallback=
14
+ function(b,c,d){$APP.P(c,d)&&aq(this);return null};hq(a.prototype);return a},kq=function(){$APP.n(customElements.get("x-breadcrumbs"))||customElements.define("x-breadcrumbs",jq());return null},Mp=new $APP.N(null,"max-items-raw","max-items-raw",-340487390),Up=new $APP.N(null,"items-after","items-after",358736705),Vp=new $APP.N(null,"wrap","wrap",851669987),Np=new $APP.N(null,"wrap-raw","wrap-raw",-1468030804),Wp=new $APP.N(null,"max-items","max-items",-1969244147),Rp=new $APP.N(null,"separator-raw",
15
+ "separator-raw",1358337914),Zp=new $APP.N(null,"ellipsis-at","ellipsis-at",-628372349),Pp=new $APP.N(null,"preserve-aria-current-present?","preserve-aria-current-present?",729931506),Qp=new $APP.N(null,"items-before-raw","items-before-raw",1580997624),Op=new $APP.N(null,"items-after-raw","items-after-raw",-1677187220),Xp=new $APP.N(null,"items-before","items-before",-1151895719),Tp=new $APP.N(null,"preserve-aria-current","preserve-aria-current",682773185),$p=new $APP.N(null,"total","total",1916810418);var iq="separator size variant wrap max-items items-before items-after disabled preserve-aria-current aria-label aria-describedby".split(" "),Yp=new $APP.S(null,new $APP.Q(null,3,["md",null,"lg",null,"sm",null],null),null),Sp=new $APP.S(null,new $APP.Q(null,3,["subtle",null,"text",null,"default",null],null),null);$APP.ja("baredom.exports.x_breadcrumbs.init",kq);export const init=kq;