@momentum-design/components 0.121.3 → 0.121.4
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.
- package/dist/browser/index.js +14 -14
- package/dist/browser/index.js.map +2 -2
- package/dist/components/slider/slider.component.d.ts +4 -0
- package/dist/components/slider/slider.component.js +9 -1
- package/dist/components/slider/slider.types.d.ts +1 -1
- package/dist/custom-elements.json +880 -862
- package/dist/index.d.ts +2 -1
- package/dist/react/index.d.ts +3 -3
- package/dist/react/index.js +3 -3
- package/package.json +1 -1
package/dist/browser/index.js
CHANGED
|
@@ -2534,7 +2534,7 @@
|
|
|
2534
2534
|
}
|
|
2535
2535
|
}
|
|
2536
2536
|
`],Qu=OE;var bo=class extends Bt(q){constructor(){super(...arguments);this.checked=!1;this.readonly=!1;this.softDisabled=!1}render(){return _` <slot></slot>
|
|
2537
|
-
<span part="radio-icon" class="radio-icon"></span>`}};bo.styles=[...q.styles,...Qu],p([u({type:Boolean,reflect:!0})],bo.prototype,"checked",2),p([u({type:Boolean,reflect:!0})],bo.prototype,"readonly",2),p([u({type:Boolean,attribute:"soft-disabled",reflect:!0})],bo.prototype,"softDisabled",2);var Rc=bo;var Ju=z.constructTagName("staticradio");Rc.register(Ju);var PE=Rc;Lc.register(Il);var DE=Lc;var Fr=Math.min,_e=Math.max,La=Math.round,Ra=Math.floor,Tr=n=>({x:n,y:n}),$E={left:"right",right:"left",bottom:"top",top:"bottom"},FE={start:"end",end:"start"};function kl(n,o,t){return _e(n,Fr(o,t))}function yo(n,o){return typeof n=="function"?n(o):n}function li(n){return n.split("-")[0]}function Eo(n){return n.split("-")[1]}function Mc(n){return n==="x"?"y":"x"}function wl(n){return n==="y"?"height":"width"}var VE=new Set(["top","bottom"]);function Vr(n){return VE.has(li(n))?"y":"x"}function Nl(n){return Mc(Vr(n))}function rf(n,o,t){t===void 0&&(t=!1);let i=Eo(n),a=Nl(n),d=wl(a),m=a==="x"?i===(t?"end":"start")?"right":"left":i==="start"?"bottom":"top";return o.reference[d]>o.floating[d]&&(m=Na(m)),[m,Na(m)]}function of(n){let o=Na(n);return[Cl(n),o,Cl(o)]}function Cl(n){return n.replace(/start|end/g,o=>FE[o])}var tf=["left","right"],ef=["right","left"],zE=["top","bottom"],BE=["bottom","top"];function UE(n,o,t){switch(n){case"top":case"bottom":return t?o?ef:tf:o?tf:ef;case"left":case"right":return o?zE:BE;default:return[]}}function sf(n,o,t,i){let a=Eo(n),d=UE(li(n),t==="start",i);return a&&(d=d.map(m=>m+"-"+a),o&&(d=d.concat(d.map(Cl)))),d}function Na(n){return n.replace(/left|right|bottom|top/g,o=>$E[o])}function HE(n){return{top:0,right:0,bottom:0,left:0,...n}}function Oc(n){return typeof n!="number"?HE(n):{top:n,right:n,bottom:n,left:n}}function To(n){let{x:o,y:t,width:i,height:a}=n;return{width:i,height:a,top:t,left:o,right:o+i,bottom:t+a,x:o,y:t}}function af(n,o,t){let{reference:i,floating:a}=n,d=Vr(o),m=Nl(o),b=wl(m),C=li(o),L=d==="y",W=i.x+i.width/2-a.width/2,K=i.y+i.height/2-a.height/2,rt=i[b]/2-a[b]/2,X;switch(C){case"top":X={x:W,y:i.y-a.height};break;case"bottom":X={x:W,y:i.y+i.height};break;case"right":X={x:i.x+i.width,y:K};break;case"left":X={x:i.x-a.width,y:K};break;default:X={x:i.x,y:i.y}}switch(Eo(o)){case"start":X[m]-=rt*(t&&L?-1:1);break;case"end":X[m]+=rt*(t&&L?-1:1);break}return X}var nf=async(n,o,t)=>{let{placement:i="bottom",strategy:a="absolute",middleware:d=[],platform:m}=t,b=d.filter(Boolean),C=await(m.isRTL==null?void 0:m.isRTL(o)),L=await m.getElementRects({reference:n,floating:o,strategy:a}),{x:W,y:K}=af(L,i,C),rt=i,X={},et=0;for(let lt=0;lt<b.length;lt++){let{name:dt,fn:gt}=b[lt],{x:At,y:Nt,data:jt,reset:Vt}=await gt({x:W,y:K,initialPlacement:i,placement:rt,strategy:a,middlewareData:X,rects:L,platform:m,elements:{reference:n,floating:o}});W=At!=null?At:W,K=Nt!=null?Nt:K,X={...X,[dt]:{...X[dt],...jt}},Vt&&et<=50&&(et++,typeof Vt=="object"&&(Vt.placement&&(rt=Vt.placement),Vt.rects&&(L=Vt.rects===!0?await m.getElementRects({reference:n,floating:o,strategy:a}):Vt.rects),{x:W,y:K}=af(L,rt,C)),lt=-1)}return{x:W,y:K,placement:rt,strategy:a,middlewareData:X}};async function Ll(n,o){var t;o===void 0&&(o={});let{x:i,y:a,platform:d,rects:m,elements:b,strategy:C}=n,{boundary:L="clippingAncestors",rootBoundary:W="viewport",elementContext:K="floating",altBoundary:rt=!1,padding:X=0}=yo(o,n),et=Oc(X),dt=b[rt?K==="floating"?"reference":"floating":K],gt=To(await d.getClippingRect({element:(t=await(d.isElement==null?void 0:d.isElement(dt)))==null||t?dt:dt.contextElement||await(d.getDocumentElement==null?void 0:d.getDocumentElement(b.floating)),boundary:L,rootBoundary:W,strategy:C})),At=K==="floating"?{x:i,y:a,width:m.floating.width,height:m.floating.height}:m.reference,Nt=await(d.getOffsetParent==null?void 0:d.getOffsetParent(b.floating)),jt=await(d.isElement==null?void 0:d.isElement(Nt))?await(d.getScale==null?void 0:d.getScale(Nt))||{x:1,y:1}:{x:1,y:1},Vt=To(d.convertOffsetParentRelativeRectToViewportRelativeRect?await d.convertOffsetParentRelativeRectToViewportRelativeRect({elements:b,rect:At,offsetParent:Nt,strategy:C}):At);return{top:(gt.top-Vt.top+et.top)/jt.y,bottom:(Vt.bottom-gt.bottom+et.bottom)/jt.y,left:(gt.left-Vt.left+et.left)/jt.x,right:(Vt.right-gt.right+et.right)/jt.x}}var lf=n=>({name:"arrow",options:n,async fn(o){let{x:t,y:i,placement:a,rects:d,platform:m,elements:b,middlewareData:C}=o,{element:L,padding:W=0}=yo(n,o)||{};if(L==null)return{};let K=Oc(W),rt={x:t,y:i},X=Nl(a),et=wl(X),lt=await m.getDimensions(L),dt=X==="y",gt=dt?"top":"left",At=dt?"bottom":"right",Nt=dt?"clientHeight":"clientWidth",jt=d.reference[et]+d.reference[X]-rt[X]-d.floating[et],Vt=rt[X]-d.reference[X],Ut=await(m.getOffsetParent==null?void 0:m.getOffsetParent(L)),Zt=Ut?Ut[Nt]:0;(!Zt||!await(m.isElement==null?void 0:m.isElement(Ut)))&&(Zt=b.floating[Nt]||d.floating[et]);let ne=jt/2-Vt/2,ur=Zt/2-lt[et]/2-1,ke=Fr(K[gt],ur),Xe=Fr(K[At],ur),fr=ke,vr=Zt-lt[et]-Xe,Ct=Zt/2-lt[et]/2+ne,me=kl(fr,Ct,vr),Ze=!C.arrow&&Eo(a)!=null&&Ct!==me&&d.reference[et]/2-(Ct<fr?ke:Xe)-lt[et]/2<0,Qe=Ze?Ct<fr?Ct-fr:Ct-vr:0;return{[X]:rt[X]+Qe,data:{[X]:me,centerOffset:Ct-me-Qe,...Ze&&{alignmentOffset:Qe}},reset:Ze}}});var df=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(o){var t,i;let{placement:a,middlewareData:d,rects:m,initialPlacement:b,platform:C,elements:L}=o,{mainAxis:W=!0,crossAxis:K=!0,fallbackPlacements:rt,fallbackStrategy:X="bestFit",fallbackAxisSideDirection:et="none",flipAlignment:lt=!0,...dt}=yo(n,o);if((t=d.arrow)!=null&&t.alignmentOffset)return{};let gt=li(a),At=Vr(b),Nt=li(b)===b,jt=await(C.isRTL==null?void 0:C.isRTL(L.floating)),Vt=rt||(Nt||!lt?[Na(b)]:of(b)),Ut=et!=="none";!rt&&Ut&&Vt.push(...sf(b,lt,et,jt));let Zt=[b,...Vt],ne=await Ll(o,dt),ur=[],ke=((i=d.flip)==null?void 0:i.overflows)||[];if(W&&ur.push(ne[gt]),K){let Ct=rf(a,m,jt);ur.push(ne[Ct[0]],ne[Ct[1]])}if(ke=[...ke,{placement:a,overflows:ur}],!ur.every(Ct=>Ct<=0)){var Xe,fr;let Ct=(((Xe=d.flip)==null?void 0:Xe.index)||0)+1,me=Zt[Ct];if(me&&(!(K==="alignment"?At!==Vr(me):!1)||ke.every(Je=>Je.overflows[0]>0&&Vr(Je.placement)===At)))return{data:{index:Ct,overflows:ke},reset:{placement:me}};let Ze=(fr=ke.filter(Qe=>Qe.overflows[0]<=0).sort((Qe,Je)=>Qe.overflows[1]-Je.overflows[1])[0])==null?void 0:fr.placement;if(!Ze)switch(X){case"bestFit":{var vr;let Qe=(vr=ke.filter(Je=>{if(Ut){let tr=Vr(Je.placement);return tr===At||tr==="y"}return!0}).map(Je=>[Je.placement,Je.overflows.filter(tr=>tr>0).reduce((tr,pn)=>tr+pn,0)]).sort((Je,tr)=>Je[1]-tr[1])[0])==null?void 0:vr[0];Qe&&(Ze=Qe);break}case"initialPlacement":Ze=b;break}if(a!==Ze)return{reset:{placement:Ze}}}return{}}}};var GE=new Set(["left","top"]);async function YE(n,o){let{placement:t,platform:i,elements:a}=n,d=await(i.isRTL==null?void 0:i.isRTL(a.floating)),m=li(t),b=Eo(t),C=Vr(t)==="y",L=GE.has(m)?-1:1,W=d&&C?-1:1,K=yo(o,n),{mainAxis:rt,crossAxis:X,alignmentAxis:et}=typeof K=="number"?{mainAxis:K,crossAxis:0,alignmentAxis:null}:{mainAxis:K.mainAxis||0,crossAxis:K.crossAxis||0,alignmentAxis:K.alignmentAxis};return b&&typeof et=="number"&&(X=b==="end"?et*-1:et),C?{x:X*W,y:rt*L}:{x:rt*L,y:X*W}}var cf=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(o){var t,i;let{x:a,y:d,placement:m,middlewareData:b}=o,C=await YE(o,n);return m===((t=b.offset)==null?void 0:t.placement)&&(i=b.arrow)!=null&&i.alignmentOffset?{}:{x:a+C.x,y:d+C.y,data:{...C,placement:m}}}}},hf=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(o){let{x:t,y:i,placement:a}=o,{mainAxis:d=!0,crossAxis:m=!1,limiter:b={fn:dt=>{let{x:gt,y:At}=dt;return{x:gt,y:At}}},...C}=yo(n,o),L={x:t,y:i},W=await Ll(o,C),K=Vr(li(a)),rt=Mc(K),X=L[rt],et=L[K];if(d){let dt=rt==="y"?"top":"left",gt=rt==="y"?"bottom":"right",At=X+W[dt],Nt=X-W[gt];X=kl(At,X,Nt)}if(m){let dt=K==="y"?"top":"left",gt=K==="y"?"bottom":"right",At=et+W[dt],Nt=et-W[gt];et=kl(At,et,Nt)}let lt=b.fn({...o,[rt]:X,[K]:et});return{...lt,data:{x:lt.x-t,y:lt.y-i,enabled:{[rt]:d,[K]:m}}}}}};var pf=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(o){var t,i;let{placement:a,rects:d,platform:m,elements:b}=o,{apply:C=()=>{},...L}=yo(n,o),W=await Ll(o,L),K=li(a),rt=Eo(a),X=Vr(a)==="y",{width:et,height:lt}=d.floating,dt,gt;K==="top"||K==="bottom"?(dt=K,gt=rt===(await(m.isRTL==null?void 0:m.isRTL(b.floating))?"start":"end")?"left":"right"):(gt=K,dt=rt==="end"?"top":"bottom");let At=lt-W.top-W.bottom,Nt=et-W.left-W.right,jt=Fr(lt-W[dt],At),Vt=Fr(et-W[gt],Nt),Ut=!o.middlewareData.shift,Zt=jt,ne=Vt;if((t=o.middlewareData.shift)!=null&&t.enabled.x&&(ne=Nt),(i=o.middlewareData.shift)!=null&&i.enabled.y&&(Zt=At),Ut&&!rt){let ke=_e(W.left,0),Xe=_e(W.right,0),fr=_e(W.top,0),vr=_e(W.bottom,0);X?ne=et-2*(ke!==0||Xe!==0?ke+Xe:_e(W.left,W.right)):Zt=lt-2*(fr!==0||vr!==0?fr+vr:_e(W.top,W.bottom))}await C({...o,availableWidth:ne,availableHeight:Zt});let ur=await m.getDimensions(b.floating);return et!==ur.width||lt!==ur.height?{reset:{rects:!0}}:{}}}};function Rl(){return typeof window<"u"}function xo(n){return uf(n)?(n.nodeName||"").toLowerCase():"#document"}function Fe(n){var o;return(n==null||(o=n.ownerDocument)==null?void 0:o.defaultView)||window}function xr(n){var o;return(o=(uf(n)?n.ownerDocument:n.document)||window.document)==null?void 0:o.documentElement}function uf(n){return Rl()?n instanceof Node||n instanceof Fe(n).Node:!1}function nr(n){return Rl()?n instanceof Element||n instanceof Fe(n).Element:!1}function Ar(n){return Rl()?n instanceof HTMLElement||n instanceof Fe(n).HTMLElement:!1}function mf(n){return!Rl()||typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof Fe(n).ShadowRoot}var WE=new Set(["inline","contents"]);function ys(n){let{overflow:o,overflowX:t,overflowY:i,display:a}=lr(n);return/auto|scroll|overlay|hidden|clip/.test(o+i+t)&&!WE.has(a)}var jE=new Set(["table","td","th"]);function ff(n){return jE.has(xo(n))}var qE=[":popover-open",":modal"];function Ma(n){return qE.some(o=>{try{return n.matches(o)}catch{return!1}})}var KE=["transform","translate","scale","rotate","perspective"],XE=["transform","translate","scale","rotate","perspective","filter"],ZE=["paint","layout","strict","content"];function Ml(n){let o=Ol(),t=nr(n)?lr(n):n;return KE.some(i=>t[i]?t[i]!=="none":!1)||(t.containerType?t.containerType!=="normal":!1)||!o&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!o&&(t.filter?t.filter!=="none":!1)||XE.some(i=>(t.willChange||"").includes(i))||ZE.some(i=>(t.contain||"").includes(i))}function vf(n){let o=di(n);for(;Ar(o)&&!Ao(o);){if(Ml(o))return o;if(Ma(o))return null;o=di(o)}return null}function Ol(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}var QE=new Set(["html","body","#document"]);function Ao(n){return QE.has(xo(n))}function lr(n){return Fe(n).getComputedStyle(n)}function Oa(n){return nr(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function di(n){if(xo(n)==="html")return n;let o=n.assignedSlot||n.parentNode||mf(n)&&n.host||xr(n);return mf(o)?o.host:o}function gf(n){let o=di(n);return Ao(o)?n.ownerDocument?n.ownerDocument.body:n.body:Ar(o)&&ys(o)?o:gf(o)}function bs(n,o,t){var i;o===void 0&&(o=[]),t===void 0&&(t=!0);let a=gf(n),d=a===((i=n.ownerDocument)==null?void 0:i.body),m=Fe(a);if(d){let b=Pl(m);return o.concat(m,m.visualViewport||[],ys(a)?a:[],b&&t?bs(b):[])}return o.concat(a,bs(a,[],t))}function Pl(n){return n.parent&&Object.getPrototypeOf(n.parent)?n.frameElement:null}function Ef(n){let o=lr(n),t=parseFloat(o.width)||0,i=parseFloat(o.height)||0,a=Ar(n),d=a?n.offsetWidth:t,m=a?n.offsetHeight:i,b=La(t)!==d||La(i)!==m;return b&&(t=d,i=m),{width:t,height:i,$:b}}function Dc(n){return nr(n)?n:n.contextElement}function Es(n){let o=Dc(n);if(!Ar(o))return Tr(1);let t=o.getBoundingClientRect(),{width:i,height:a,$:d}=Ef(o),m=(d?La(t.width):t.width)/i,b=(d?La(t.height):t.height)/a;return(!m||!Number.isFinite(m))&&(m=1),(!b||!Number.isFinite(b))&&(b=1),{x:m,y:b}}var JE=Tr(0);function Tf(n){let o=Fe(n);return!Ol()||!o.visualViewport?JE:{x:o.visualViewport.offsetLeft,y:o.visualViewport.offsetTop}}function tT(n,o,t){return o===void 0&&(o=!1),!t||o&&t!==Fe(n)?!1:o}function So(n,o,t,i){o===void 0&&(o=!1),t===void 0&&(t=!1);let a=n.getBoundingClientRect(),d=Dc(n),m=Tr(1);o&&(i?nr(i)&&(m=Es(i)):m=Es(n));let b=tT(d,t,i)?Tf(d):Tr(0),C=(a.left+b.x)/m.x,L=(a.top+b.y)/m.y,W=a.width/m.x,K=a.height/m.y;if(d){let rt=Fe(d),X=i&&nr(i)?Fe(i):i,et=rt,lt=Pl(et);for(;lt&&i&&X!==et;){let dt=Es(lt),gt=lt.getBoundingClientRect(),At=lr(lt),Nt=gt.left+(lt.clientLeft+parseFloat(At.paddingLeft))*dt.x,jt=gt.top+(lt.clientTop+parseFloat(At.paddingTop))*dt.y;C*=dt.x,L*=dt.y,W*=dt.x,K*=dt.y,C+=Nt,L+=jt,et=Fe(lt),lt=Pl(et)}}return To({width:W,height:K,x:C,y:L})}function $c(n,o){let t=Oa(n).scrollLeft;return o?o.left+t:So(xr(n)).left+t}function xf(n,o,t){t===void 0&&(t=!1);let i=n.getBoundingClientRect(),a=i.left+o.scrollLeft-(t?0:$c(n,i)),d=i.top+o.scrollTop;return{x:a,y:d}}function eT(n){let{elements:o,rect:t,offsetParent:i,strategy:a}=n,d=a==="fixed",m=xr(i),b=o?Ma(o.floating):!1;if(i===m||b&&d)return t;let C={scrollLeft:0,scrollTop:0},L=Tr(1),W=Tr(0),K=Ar(i);if((K||!K&&!d)&&((xo(i)!=="body"||ys(m))&&(C=Oa(i)),Ar(i))){let X=So(i);L=Es(i),W.x=X.x+i.clientLeft,W.y=X.y+i.clientTop}let rt=m&&!K&&!d?xf(m,C,!0):Tr(0);return{width:t.width*L.x,height:t.height*L.y,x:t.x*L.x-C.scrollLeft*L.x+W.x+rt.x,y:t.y*L.y-C.scrollTop*L.y+W.y+rt.y}}function rT(n){return Array.from(n.getClientRects())}function iT(n){let o=xr(n),t=Oa(n),i=n.ownerDocument.body,a=_e(o.scrollWidth,o.clientWidth,i.scrollWidth,i.clientWidth),d=_e(o.scrollHeight,o.clientHeight,i.scrollHeight,i.clientHeight),m=-t.scrollLeft+$c(n),b=-t.scrollTop;return lr(i).direction==="rtl"&&(m+=_e(o.clientWidth,i.clientWidth)-a),{width:a,height:d,x:m,y:b}}function oT(n,o){let t=Fe(n),i=xr(n),a=t.visualViewport,d=i.clientWidth,m=i.clientHeight,b=0,C=0;if(a){d=a.width,m=a.height;let L=Ol();(!L||L&&o==="fixed")&&(b=a.offsetLeft,C=a.offsetTop)}return{width:d,height:m,x:b,y:C}}var sT=new Set(["absolute","fixed"]);function aT(n,o){let t=So(n,!0,o==="fixed"),i=t.top+n.clientTop,a=t.left+n.clientLeft,d=Ar(n)?Es(n):Tr(1),m=n.clientWidth*d.x,b=n.clientHeight*d.y,C=a*d.x,L=i*d.y;return{width:m,height:b,x:C,y:L}}function bf(n,o,t){let i;if(o==="viewport")i=oT(n,t);else if(o==="document")i=iT(xr(n));else if(nr(o))i=aT(o,t);else{let a=Tf(n);i={x:o.x-a.x,y:o.y-a.y,width:o.width,height:o.height}}return To(i)}function Af(n,o){let t=di(n);return t===o||!nr(t)||Ao(t)?!1:lr(t).position==="fixed"||Af(t,o)}function nT(n,o){let t=o.get(n);if(t)return t;let i=bs(n,[],!1).filter(b=>nr(b)&&xo(b)!=="body"),a=null,d=lr(n).position==="fixed",m=d?di(n):n;for(;nr(m)&&!Ao(m);){let b=lr(m),C=Ml(m);!C&&b.position==="fixed"&&(a=null),(d?!C&&!a:!C&&b.position==="static"&&!!a&&sT.has(a.position)||ys(m)&&!C&&Af(n,m))?i=i.filter(W=>W!==m):a=b,m=di(m)}return o.set(n,i),i}function lT(n){let{element:o,boundary:t,rootBoundary:i,strategy:a}=n,m=[...t==="clippingAncestors"?Ma(o)?[]:nT(o,this._c):[].concat(t),i],b=m[0],C=m.reduce((L,W)=>{let K=bf(o,W,a);return L.top=_e(K.top,L.top),L.right=Fr(K.right,L.right),L.bottom=Fr(K.bottom,L.bottom),L.left=_e(K.left,L.left),L},bf(o,b,a));return{width:C.right-C.left,height:C.bottom-C.top,x:C.left,y:C.top}}function dT(n){let{width:o,height:t}=Ef(n);return{width:o,height:t}}function cT(n,o,t){let i=Ar(o),a=xr(o),d=t==="fixed",m=So(n,!0,d,o),b={scrollLeft:0,scrollTop:0},C=Tr(0);function L(){C.x=$c(a)}if(i||!i&&!d)if((xo(o)!=="body"||ys(a))&&(b=Oa(o)),i){let X=So(o,!0,d,o);C.x=X.x+o.clientLeft,C.y=X.y+o.clientTop}else a&&L();d&&!i&&a&&L();let W=a&&!i&&!d?xf(a,b):Tr(0),K=m.left+b.scrollLeft-C.x-W.x,rt=m.top+b.scrollTop-C.y-W.y;return{x:K,y:rt,width:m.width,height:m.height}}function Pc(n){return lr(n).position==="static"}function yf(n,o){if(!Ar(n)||lr(n).position==="fixed")return null;if(o)return o(n);let t=n.offsetParent;return xr(n)===t&&(t=t.ownerDocument.body),t}function Sf(n,o){let t=Fe(n);if(Ma(n))return t;if(!Ar(n)){let a=di(n);for(;a&&!Ao(a);){if(nr(a)&&!Pc(a))return a;a=di(a)}return t}let i=yf(n,o);for(;i&&ff(i)&&Pc(i);)i=yf(i,o);return i&&Ao(i)&&Pc(i)&&!Ml(i)?t:i||vf(n)||t}var hT=async function(n){let o=this.getOffsetParent||Sf,t=this.getDimensions,i=await t(n.floating);return{reference:cT(n.reference,await o(n.floating),n.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function pT(n){return lr(n).direction==="rtl"}var mT={convertOffsetParentRelativeRectToViewportRelativeRect:eT,getDocumentElement:xr,getClippingRect:lT,getOffsetParent:Sf,getElementRects:hT,getClientRects:rT,getDimensions:dT,getScale:Es,isElement:nr,isRTL:pT};function _f(n,o){return n.x===o.x&&n.y===o.y&&n.width===o.width&&n.height===o.height}function uT(n,o){let t=null,i,a=xr(n);function d(){var b;clearTimeout(i),(b=t)==null||b.disconnect(),t=null}function m(b,C){b===void 0&&(b=!1),C===void 0&&(C=1),d();let L=n.getBoundingClientRect(),{left:W,top:K,width:rt,height:X}=L;if(b||o(),!rt||!X)return;let et=Ra(K),lt=Ra(a.clientWidth-(W+rt)),dt=Ra(a.clientHeight-(K+X)),gt=Ra(W),Nt={rootMargin:-et+"px "+-lt+"px "+-dt+"px "+-gt+"px",threshold:_e(0,Fr(1,C))||1},jt=!0;function Vt(Ut){let Zt=Ut[0].intersectionRatio;if(Zt!==C){if(!jt)return m();Zt?m(!1,Zt):i=setTimeout(()=>{m(!1,1e-7)},1e3)}Zt===1&&!_f(L,n.getBoundingClientRect())&&m(),jt=!1}try{t=new IntersectionObserver(Vt,{...Nt,root:a.ownerDocument})}catch{t=new IntersectionObserver(Vt,Nt)}t.observe(n)}return m(!0),d}function If(n,o,t,i){i===void 0&&(i={});let{ancestorScroll:a=!0,ancestorResize:d=!0,elementResize:m=typeof ResizeObserver=="function",layoutShift:b=typeof IntersectionObserver=="function",animationFrame:C=!1}=i,L=Dc(n),W=a||d?[...L?bs(L):[],...bs(o)]:[];W.forEach(gt=>{a&>.addEventListener("scroll",t,{passive:!0}),d&>.addEventListener("resize",t)});let K=L&&b?uT(L,t):null,rt=-1,X=null;m&&(X=new ResizeObserver(gt=>{let[At]=gt;At&&At.target===L&&X&&(X.unobserve(o),cancelAnimationFrame(rt),rt=requestAnimationFrame(()=>{var Nt;(Nt=X)==null||Nt.observe(o)})),t()}),L&&!C&&X.observe(L),X.observe(o));let et,lt=C?So(n):null;C&&dt();function dt(){let gt=So(n);lt&&!_f(lt,gt)&&t(),lt=gt,et=requestAnimationFrame(dt)}return t(),()=>{var gt;W.forEach(At=>{a&&At.removeEventListener("scroll",t),d&&At.removeEventListener("resize",t)}),K==null||K(),(gt=X)==null||gt.disconnect(),X=null,C&&cancelAnimationFrame(et)}}var Cf=cf;var kf=hf,wf=df,Nf=pf;var Lf=lf;var Rf=(n,o,t)=>{let i=new Map,a={platform:mT,...t},d={...a.platform,_c:i};return nf(n,o,{...a,platform:d})};var Mf=z.constructTagName("popover"),kt={LEFT_START:"left-start",LEFT:"left",LEFT_END:"left-end",RIGHT_START:"right-start",RIGHT:"right",RIGHT_END:"right-end",TOP_START:"top-start",TOP:"top",TOP_END:"top-end",BOTTOM_START:"bottom-start",BOTTOM:"bottom",BOTTOM_END:"bottom-end"},ci={CLICK:"click",MOUSEENTER:"mouseenter",FOCUSIN:"focusin",MANUAL:"manual"},_o={TONAL:"tonal",CONTRAST:"contrast"},fT={ABSOLUTE:"absolute",FIXED:"fixed"},_t={PLACEMENT:kt.BOTTOM,TRIGGER:ci.CLICK,COLOR:_o.TONAL,STRATEGY:fT.ABSOLUTE,OFFSET:4,BOUNDARY:"clippingAncestors",BOUNDARY_ROOT:"viewport",BOUNDARY_PADDING:0,VISIBLE:!1,ARROW:!1,CLOSE_BUTTON:!1,FOCUS_TRAP:!1,INTERACTIVE:!1,PREVENT_SCROLL:!1,HIDE_ON_ESCAPE:!1,HIDE_ON_BLUR:!1,HIDE_ON_CLICK_OUTSIDE:!1,FOCUS_BACK:!1,BACKDROP:!1,FLIP:!0,SIZE:!1,DELAY:"0,0",ROLE:tt.DIALOG,Z_INDEX:1e3,DISABLE_ARIA_EXPANDED:!1,PROPAGATE_EVENT_ON_ESCAPE:!1,KEEP_CONNECTED_TOOLTIP_CLOSED:!0,IS_BACKDROP_INVISIBLE:!0};var hi=class{static dispatchPopoverEvent(o,t){t.dispatchEvent(new CustomEvent(o,{detail:{show:t.visible},composed:!0,bubbles:!0}))}static onShowPopover(o){this.dispatchPopoverEvent("shown",o)}static onHidePopover(o){this.dispatchPopoverEvent("hidden",o)}static onCreatedPopover(o){this.dispatchPopoverEvent("created",o)}static onDestroyedPopover(o){this.dispatchPopoverEvent("destroyed",o)}static onEscapeKeyPressed(o){this.dispatchPopoverEvent("closebyescape",o)}static onClickOutside(o){this.dispatchPopoverEvent("closebyoutsideclick",o)}};var Fc=class{constructor(){this.stack=[]}push(o){this.stack.push(o)}pop(){return this.stack.pop()}peek(){return this.stack[this.stack.length-1]}remove(o){this.stack=this.stack.filter(t=>t!==o)}has(o){return this.stack.includes(o)}clear(){this.stack=[]}},Ie=new Fc;var vT=B`
|
|
2537
|
+
<span part="radio-icon" class="radio-icon"></span>`}};bo.styles=[...q.styles,...Qu],p([u({type:Boolean,reflect:!0})],bo.prototype,"checked",2),p([u({type:Boolean,reflect:!0})],bo.prototype,"readonly",2),p([u({type:Boolean,attribute:"soft-disabled",reflect:!0})],bo.prototype,"softDisabled",2);var Rc=bo;var Ju=z.constructTagName("staticradio");Rc.register(Ju);var PE=Rc;Lc.register(Il);var DE=Lc;var Fr=Math.min,_e=Math.max,La=Math.round,Ra=Math.floor,Tr=n=>({x:n,y:n}),$E={left:"right",right:"left",bottom:"top",top:"bottom"},FE={start:"end",end:"start"};function kl(n,o,t){return _e(n,Fr(o,t))}function yo(n,o){return typeof n=="function"?n(o):n}function li(n){return n.split("-")[0]}function Eo(n){return n.split("-")[1]}function Mc(n){return n==="x"?"y":"x"}function wl(n){return n==="y"?"height":"width"}var VE=new Set(["top","bottom"]);function Vr(n){return VE.has(li(n))?"y":"x"}function Nl(n){return Mc(Vr(n))}function rf(n,o,t){t===void 0&&(t=!1);let i=Eo(n),a=Nl(n),d=wl(a),m=a==="x"?i===(t?"end":"start")?"right":"left":i==="start"?"bottom":"top";return o.reference[d]>o.floating[d]&&(m=Na(m)),[m,Na(m)]}function of(n){let o=Na(n);return[Cl(n),o,Cl(o)]}function Cl(n){return n.replace(/start|end/g,o=>FE[o])}var tf=["left","right"],ef=["right","left"],zE=["top","bottom"],BE=["bottom","top"];function UE(n,o,t){switch(n){case"top":case"bottom":return t?o?ef:tf:o?tf:ef;case"left":case"right":return o?zE:BE;default:return[]}}function sf(n,o,t,i){let a=Eo(n),d=UE(li(n),t==="start",i);return a&&(d=d.map(m=>m+"-"+a),o&&(d=d.concat(d.map(Cl)))),d}function Na(n){return n.replace(/left|right|bottom|top/g,o=>$E[o])}function HE(n){return{top:0,right:0,bottom:0,left:0,...n}}function Oc(n){return typeof n!="number"?HE(n):{top:n,right:n,bottom:n,left:n}}function To(n){let{x:o,y:t,width:i,height:a}=n;return{width:i,height:a,top:t,left:o,right:o+i,bottom:t+a,x:o,y:t}}function af(n,o,t){let{reference:i,floating:a}=n,d=Vr(o),m=Nl(o),b=wl(m),C=li(o),L=d==="y",W=i.x+i.width/2-a.width/2,K=i.y+i.height/2-a.height/2,rt=i[b]/2-a[b]/2,X;switch(C){case"top":X={x:W,y:i.y-a.height};break;case"bottom":X={x:W,y:i.y+i.height};break;case"right":X={x:i.x+i.width,y:K};break;case"left":X={x:i.x-a.width,y:K};break;default:X={x:i.x,y:i.y}}switch(Eo(o)){case"start":X[m]-=rt*(t&&L?-1:1);break;case"end":X[m]+=rt*(t&&L?-1:1);break}return X}var nf=async(n,o,t)=>{let{placement:i="bottom",strategy:a="absolute",middleware:d=[],platform:m}=t,b=d.filter(Boolean),C=await(m.isRTL==null?void 0:m.isRTL(o)),L=await m.getElementRects({reference:n,floating:o,strategy:a}),{x:W,y:K}=af(L,i,C),rt=i,X={},et=0;for(let lt=0;lt<b.length;lt++){let{name:dt,fn:gt}=b[lt],{x:At,y:Nt,data:jt,reset:Vt}=await gt({x:W,y:K,initialPlacement:i,placement:rt,strategy:a,middlewareData:X,rects:L,platform:m,elements:{reference:n,floating:o}});W=At!=null?At:W,K=Nt!=null?Nt:K,X={...X,[dt]:{...X[dt],...jt}},Vt&&et<=50&&(et++,typeof Vt=="object"&&(Vt.placement&&(rt=Vt.placement),Vt.rects&&(L=Vt.rects===!0?await m.getElementRects({reference:n,floating:o,strategy:a}):Vt.rects),{x:W,y:K}=af(L,rt,C)),lt=-1)}return{x:W,y:K,placement:rt,strategy:a,middlewareData:X}};async function Ll(n,o){var t;o===void 0&&(o={});let{x:i,y:a,platform:d,rects:m,elements:b,strategy:C}=n,{boundary:L="clippingAncestors",rootBoundary:W="viewport",elementContext:K="floating",altBoundary:rt=!1,padding:X=0}=yo(o,n),et=Oc(X),dt=b[rt?K==="floating"?"reference":"floating":K],gt=To(await d.getClippingRect({element:(t=await(d.isElement==null?void 0:d.isElement(dt)))==null||t?dt:dt.contextElement||await(d.getDocumentElement==null?void 0:d.getDocumentElement(b.floating)),boundary:L,rootBoundary:W,strategy:C})),At=K==="floating"?{x:i,y:a,width:m.floating.width,height:m.floating.height}:m.reference,Nt=await(d.getOffsetParent==null?void 0:d.getOffsetParent(b.floating)),jt=await(d.isElement==null?void 0:d.isElement(Nt))?await(d.getScale==null?void 0:d.getScale(Nt))||{x:1,y:1}:{x:1,y:1},Vt=To(d.convertOffsetParentRelativeRectToViewportRelativeRect?await d.convertOffsetParentRelativeRectToViewportRelativeRect({elements:b,rect:At,offsetParent:Nt,strategy:C}):At);return{top:(gt.top-Vt.top+et.top)/jt.y,bottom:(Vt.bottom-gt.bottom+et.bottom)/jt.y,left:(gt.left-Vt.left+et.left)/jt.x,right:(Vt.right-gt.right+et.right)/jt.x}}var lf=n=>({name:"arrow",options:n,async fn(o){let{x:t,y:i,placement:a,rects:d,platform:m,elements:b,middlewareData:C}=o,{element:L,padding:W=0}=yo(n,o)||{};if(L==null)return{};let K=Oc(W),rt={x:t,y:i},X=Nl(a),et=wl(X),lt=await m.getDimensions(L),dt=X==="y",gt=dt?"top":"left",At=dt?"bottom":"right",Nt=dt?"clientHeight":"clientWidth",jt=d.reference[et]+d.reference[X]-rt[X]-d.floating[et],Vt=rt[X]-d.reference[X],Ut=await(m.getOffsetParent==null?void 0:m.getOffsetParent(L)),Zt=Ut?Ut[Nt]:0;(!Zt||!await(m.isElement==null?void 0:m.isElement(Ut)))&&(Zt=b.floating[Nt]||d.floating[et]);let ne=jt/2-Vt/2,ur=Zt/2-lt[et]/2-1,ke=Fr(K[gt],ur),Xe=Fr(K[At],ur),fr=ke,vr=Zt-lt[et]-Xe,Ct=Zt/2-lt[et]/2+ne,me=kl(fr,Ct,vr),Ze=!C.arrow&&Eo(a)!=null&&Ct!==me&&d.reference[et]/2-(Ct<fr?ke:Xe)-lt[et]/2<0,Qe=Ze?Ct<fr?Ct-fr:Ct-vr:0;return{[X]:rt[X]+Qe,data:{[X]:me,centerOffset:Ct-me-Qe,...Ze&&{alignmentOffset:Qe}},reset:Ze}}});var df=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(o){var t,i;let{placement:a,middlewareData:d,rects:m,initialPlacement:b,platform:C,elements:L}=o,{mainAxis:W=!0,crossAxis:K=!0,fallbackPlacements:rt,fallbackStrategy:X="bestFit",fallbackAxisSideDirection:et="none",flipAlignment:lt=!0,...dt}=yo(n,o);if((t=d.arrow)!=null&&t.alignmentOffset)return{};let gt=li(a),At=Vr(b),Nt=li(b)===b,jt=await(C.isRTL==null?void 0:C.isRTL(L.floating)),Vt=rt||(Nt||!lt?[Na(b)]:of(b)),Ut=et!=="none";!rt&&Ut&&Vt.push(...sf(b,lt,et,jt));let Zt=[b,...Vt],ne=await Ll(o,dt),ur=[],ke=((i=d.flip)==null?void 0:i.overflows)||[];if(W&&ur.push(ne[gt]),K){let Ct=rf(a,m,jt);ur.push(ne[Ct[0]],ne[Ct[1]])}if(ke=[...ke,{placement:a,overflows:ur}],!ur.every(Ct=>Ct<=0)){var Xe,fr;let Ct=(((Xe=d.flip)==null?void 0:Xe.index)||0)+1,me=Zt[Ct];if(me&&(!(K==="alignment"?At!==Vr(me):!1)||ke.every(Je=>Je.overflows[0]>0&&Vr(Je.placement)===At)))return{data:{index:Ct,overflows:ke},reset:{placement:me}};let Ze=(fr=ke.filter(Qe=>Qe.overflows[0]<=0).sort((Qe,Je)=>Qe.overflows[1]-Je.overflows[1])[0])==null?void 0:fr.placement;if(!Ze)switch(X){case"bestFit":{var vr;let Qe=(vr=ke.filter(Je=>{if(Ut){let tr=Vr(Je.placement);return tr===At||tr==="y"}return!0}).map(Je=>[Je.placement,Je.overflows.filter(tr=>tr>0).reduce((tr,pn)=>tr+pn,0)]).sort((Je,tr)=>Je[1]-tr[1])[0])==null?void 0:vr[0];Qe&&(Ze=Qe);break}case"initialPlacement":Ze=b;break}if(a!==Ze)return{reset:{placement:Ze}}}return{}}}};var GE=new Set(["left","top"]);async function YE(n,o){let{placement:t,platform:i,elements:a}=n,d=await(i.isRTL==null?void 0:i.isRTL(a.floating)),m=li(t),b=Eo(t),C=Vr(t)==="y",L=GE.has(m)?-1:1,W=d&&C?-1:1,K=yo(o,n),{mainAxis:rt,crossAxis:X,alignmentAxis:et}=typeof K=="number"?{mainAxis:K,crossAxis:0,alignmentAxis:null}:{mainAxis:K.mainAxis||0,crossAxis:K.crossAxis||0,alignmentAxis:K.alignmentAxis};return b&&typeof et=="number"&&(X=b==="end"?et*-1:et),C?{x:X*W,y:rt*L}:{x:rt*L,y:X*W}}var cf=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(o){var t,i;let{x:a,y:d,placement:m,middlewareData:b}=o,C=await YE(o,n);return m===((t=b.offset)==null?void 0:t.placement)&&(i=b.arrow)!=null&&i.alignmentOffset?{}:{x:a+C.x,y:d+C.y,data:{...C,placement:m}}}}},hf=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(o){let{x:t,y:i,placement:a}=o,{mainAxis:d=!0,crossAxis:m=!1,limiter:b={fn:dt=>{let{x:gt,y:At}=dt;return{x:gt,y:At}}},...C}=yo(n,o),L={x:t,y:i},W=await Ll(o,C),K=Vr(li(a)),rt=Mc(K),X=L[rt],et=L[K];if(d){let dt=rt==="y"?"top":"left",gt=rt==="y"?"bottom":"right",At=X+W[dt],Nt=X-W[gt];X=kl(At,X,Nt)}if(m){let dt=K==="y"?"top":"left",gt=K==="y"?"bottom":"right",At=et+W[dt],Nt=et-W[gt];et=kl(At,et,Nt)}let lt=b.fn({...o,[rt]:X,[K]:et});return{...lt,data:{x:lt.x-t,y:lt.y-i,enabled:{[rt]:d,[K]:m}}}}}};var pf=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(o){var t,i;let{placement:a,rects:d,platform:m,elements:b}=o,{apply:C=()=>{},...L}=yo(n,o),W=await Ll(o,L),K=li(a),rt=Eo(a),X=Vr(a)==="y",{width:et,height:lt}=d.floating,dt,gt;K==="top"||K==="bottom"?(dt=K,gt=rt===(await(m.isRTL==null?void 0:m.isRTL(b.floating))?"start":"end")?"left":"right"):(gt=K,dt=rt==="end"?"top":"bottom");let At=lt-W.top-W.bottom,Nt=et-W.left-W.right,jt=Fr(lt-W[dt],At),Vt=Fr(et-W[gt],Nt),Ut=!o.middlewareData.shift,Zt=jt,ne=Vt;if((t=o.middlewareData.shift)!=null&&t.enabled.x&&(ne=Nt),(i=o.middlewareData.shift)!=null&&i.enabled.y&&(Zt=At),Ut&&!rt){let ke=_e(W.left,0),Xe=_e(W.right,0),fr=_e(W.top,0),vr=_e(W.bottom,0);X?ne=et-2*(ke!==0||Xe!==0?ke+Xe:_e(W.left,W.right)):Zt=lt-2*(fr!==0||vr!==0?fr+vr:_e(W.top,W.bottom))}await C({...o,availableWidth:ne,availableHeight:Zt});let ur=await m.getDimensions(b.floating);return et!==ur.width||lt!==ur.height?{reset:{rects:!0}}:{}}}};function Rl(){return typeof window<"u"}function xo(n){return uf(n)?(n.nodeName||"").toLowerCase():"#document"}function Fe(n){var o;return(n==null||(o=n.ownerDocument)==null?void 0:o.defaultView)||window}function xr(n){var o;return(o=(uf(n)?n.ownerDocument:n.document)||window.document)==null?void 0:o.documentElement}function uf(n){return Rl()?n instanceof Node||n instanceof Fe(n).Node:!1}function nr(n){return Rl()?n instanceof Element||n instanceof Fe(n).Element:!1}function Ar(n){return Rl()?n instanceof HTMLElement||n instanceof Fe(n).HTMLElement:!1}function mf(n){return!Rl()||typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof Fe(n).ShadowRoot}var WE=new Set(["inline","contents"]);function ys(n){let{overflow:o,overflowX:t,overflowY:i,display:a}=lr(n);return/auto|scroll|overlay|hidden|clip/.test(o+i+t)&&!WE.has(a)}var jE=new Set(["table","td","th"]);function ff(n){return jE.has(xo(n))}var qE=[":popover-open",":modal"];function Ma(n){return qE.some(o=>{try{return n.matches(o)}catch{return!1}})}var KE=["transform","translate","scale","rotate","perspective"],XE=["transform","translate","scale","rotate","perspective","filter"],ZE=["paint","layout","strict","content"];function Ml(n){let o=Ol(),t=nr(n)?lr(n):n;return KE.some(i=>t[i]?t[i]!=="none":!1)||(t.containerType?t.containerType!=="normal":!1)||!o&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!o&&(t.filter?t.filter!=="none":!1)||XE.some(i=>(t.willChange||"").includes(i))||ZE.some(i=>(t.contain||"").includes(i))}function vf(n){let o=di(n);for(;Ar(o)&&!Ao(o);){if(Ml(o))return o;if(Ma(o))return null;o=di(o)}return null}function Ol(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}var QE=new Set(["html","body","#document"]);function Ao(n){return QE.has(xo(n))}function lr(n){return Fe(n).getComputedStyle(n)}function Oa(n){return nr(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function di(n){if(xo(n)==="html")return n;let o=n.assignedSlot||n.parentNode||mf(n)&&n.host||xr(n);return mf(o)?o.host:o}function gf(n){let o=di(n);return Ao(o)?n.ownerDocument?n.ownerDocument.body:n.body:Ar(o)&&ys(o)?o:gf(o)}function bs(n,o,t){var i;o===void 0&&(o=[]),t===void 0&&(t=!0);let a=gf(n),d=a===((i=n.ownerDocument)==null?void 0:i.body),m=Fe(a);if(d){let b=Pl(m);return o.concat(m,m.visualViewport||[],ys(a)?a:[],b&&t?bs(b):[])}return o.concat(a,bs(a,[],t))}function Pl(n){return n.parent&&Object.getPrototypeOf(n.parent)?n.frameElement:null}function Ef(n){let o=lr(n),t=parseFloat(o.width)||0,i=parseFloat(o.height)||0,a=Ar(n),d=a?n.offsetWidth:t,m=a?n.offsetHeight:i,b=La(t)!==d||La(i)!==m;return b&&(t=d,i=m),{width:t,height:i,$:b}}function Dc(n){return nr(n)?n:n.contextElement}function Es(n){let o=Dc(n);if(!Ar(o))return Tr(1);let t=o.getBoundingClientRect(),{width:i,height:a,$:d}=Ef(o),m=(d?La(t.width):t.width)/i,b=(d?La(t.height):t.height)/a;return(!m||!Number.isFinite(m))&&(m=1),(!b||!Number.isFinite(b))&&(b=1),{x:m,y:b}}var JE=Tr(0);function Tf(n){let o=Fe(n);return!Ol()||!o.visualViewport?JE:{x:o.visualViewport.offsetLeft,y:o.visualViewport.offsetTop}}function tT(n,o,t){return o===void 0&&(o=!1),!t||o&&t!==Fe(n)?!1:o}function So(n,o,t,i){o===void 0&&(o=!1),t===void 0&&(t=!1);let a=n.getBoundingClientRect(),d=Dc(n),m=Tr(1);o&&(i?nr(i)&&(m=Es(i)):m=Es(n));let b=tT(d,t,i)?Tf(d):Tr(0),C=(a.left+b.x)/m.x,L=(a.top+b.y)/m.y,W=a.width/m.x,K=a.height/m.y;if(d){let rt=Fe(d),X=i&&nr(i)?Fe(i):i,et=rt,lt=Pl(et);for(;lt&&i&&X!==et;){let dt=Es(lt),gt=lt.getBoundingClientRect(),At=lr(lt),Nt=gt.left+(lt.clientLeft+parseFloat(At.paddingLeft))*dt.x,jt=gt.top+(lt.clientTop+parseFloat(At.paddingTop))*dt.y;C*=dt.x,L*=dt.y,W*=dt.x,K*=dt.y,C+=Nt,L+=jt,et=Fe(lt),lt=Pl(et)}}return To({width:W,height:K,x:C,y:L})}function $c(n,o){let t=Oa(n).scrollLeft;return o?o.left+t:So(xr(n)).left+t}function xf(n,o,t){t===void 0&&(t=!1);let i=n.getBoundingClientRect(),a=i.left+o.scrollLeft-(t?0:$c(n,i)),d=i.top+o.scrollTop;return{x:a,y:d}}function eT(n){let{elements:o,rect:t,offsetParent:i,strategy:a}=n,d=a==="fixed",m=xr(i),b=o?Ma(o.floating):!1;if(i===m||b&&d)return t;let C={scrollLeft:0,scrollTop:0},L=Tr(1),W=Tr(0),K=Ar(i);if((K||!K&&!d)&&((xo(i)!=="body"||ys(m))&&(C=Oa(i)),Ar(i))){let X=So(i);L=Es(i),W.x=X.x+i.clientLeft,W.y=X.y+i.clientTop}let rt=m&&!K&&!d?xf(m,C,!0):Tr(0);return{width:t.width*L.x,height:t.height*L.y,x:t.x*L.x-C.scrollLeft*L.x+W.x+rt.x,y:t.y*L.y-C.scrollTop*L.y+W.y+rt.y}}function rT(n){return Array.from(n.getClientRects())}function iT(n){let o=xr(n),t=Oa(n),i=n.ownerDocument.body,a=_e(o.scrollWidth,o.clientWidth,i.scrollWidth,i.clientWidth),d=_e(o.scrollHeight,o.clientHeight,i.scrollHeight,i.clientHeight),m=-t.scrollLeft+$c(n),b=-t.scrollTop;return lr(i).direction==="rtl"&&(m+=_e(o.clientWidth,i.clientWidth)-a),{width:a,height:d,x:m,y:b}}function oT(n,o){let t=Fe(n),i=xr(n),a=t.visualViewport,d=i.clientWidth,m=i.clientHeight,b=0,C=0;if(a){d=a.width,m=a.height;let L=Ol();(!L||L&&o==="fixed")&&(b=a.offsetLeft,C=a.offsetTop)}return{width:d,height:m,x:b,y:C}}var sT=new Set(["absolute","fixed"]);function aT(n,o){let t=So(n,!0,o==="fixed"),i=t.top+n.clientTop,a=t.left+n.clientLeft,d=Ar(n)?Es(n):Tr(1),m=n.clientWidth*d.x,b=n.clientHeight*d.y,C=a*d.x,L=i*d.y;return{width:m,height:b,x:C,y:L}}function bf(n,o,t){let i;if(o==="viewport")i=oT(n,t);else if(o==="document")i=iT(xr(n));else if(nr(o))i=aT(o,t);else{let a=Tf(n);i={x:o.x-a.x,y:o.y-a.y,width:o.width,height:o.height}}return To(i)}function Af(n,o){let t=di(n);return t===o||!nr(t)||Ao(t)?!1:lr(t).position==="fixed"||Af(t,o)}function nT(n,o){let t=o.get(n);if(t)return t;let i=bs(n,[],!1).filter(b=>nr(b)&&xo(b)!=="body"),a=null,d=lr(n).position==="fixed",m=d?di(n):n;for(;nr(m)&&!Ao(m);){let b=lr(m),C=Ml(m);!C&&b.position==="fixed"&&(a=null),(d?!C&&!a:!C&&b.position==="static"&&!!a&&sT.has(a.position)||ys(m)&&!C&&Af(n,m))?i=i.filter(W=>W!==m):a=b,m=di(m)}return o.set(n,i),i}function lT(n){let{element:o,boundary:t,rootBoundary:i,strategy:a}=n,m=[...t==="clippingAncestors"?Ma(o)?[]:nT(o,this._c):[].concat(t),i],b=m[0],C=m.reduce((L,W)=>{let K=bf(o,W,a);return L.top=_e(K.top,L.top),L.right=Fr(K.right,L.right),L.bottom=Fr(K.bottom,L.bottom),L.left=_e(K.left,L.left),L},bf(o,b,a));return{width:C.right-C.left,height:C.bottom-C.top,x:C.left,y:C.top}}function dT(n){let{width:o,height:t}=Ef(n);return{width:o,height:t}}function cT(n,o,t){let i=Ar(o),a=xr(o),d=t==="fixed",m=So(n,!0,d,o),b={scrollLeft:0,scrollTop:0},C=Tr(0);function L(){C.x=$c(a)}if(i||!i&&!d)if((xo(o)!=="body"||ys(a))&&(b=Oa(o)),i){let X=So(o,!0,d,o);C.x=X.x+o.clientLeft,C.y=X.y+o.clientTop}else a&&L();d&&!i&&a&&L();let W=a&&!i&&!d?xf(a,b):Tr(0),K=m.left+b.scrollLeft-C.x-W.x,rt=m.top+b.scrollTop-C.y-W.y;return{x:K,y:rt,width:m.width,height:m.height}}function Pc(n){return lr(n).position==="static"}function yf(n,o){if(!Ar(n)||lr(n).position==="fixed")return null;if(o)return o(n);let t=n.offsetParent;return xr(n)===t&&(t=t.ownerDocument.body),t}function Sf(n,o){let t=Fe(n);if(Ma(n))return t;if(!Ar(n)){let a=di(n);for(;a&&!Ao(a);){if(nr(a)&&!Pc(a))return a;a=di(a)}return t}let i=yf(n,o);for(;i&&ff(i)&&Pc(i);)i=yf(i,o);return i&&Ao(i)&&Pc(i)&&!Ml(i)?t:i||vf(n)||t}var hT=async function(n){let o=this.getOffsetParent||Sf,t=this.getDimensions,i=await t(n.floating);return{reference:cT(n.reference,await o(n.floating),n.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function pT(n){return lr(n).direction==="rtl"}var mT={convertOffsetParentRelativeRectToViewportRelativeRect:eT,getDocumentElement:xr,getClippingRect:lT,getOffsetParent:Sf,getElementRects:hT,getClientRects:rT,getDimensions:dT,getScale:Es,isElement:nr,isRTL:pT};function _f(n,o){return n.x===o.x&&n.y===o.y&&n.width===o.width&&n.height===o.height}function uT(n,o){let t=null,i,a=xr(n);function d(){var b;clearTimeout(i),(b=t)==null||b.disconnect(),t=null}function m(b,C){b===void 0&&(b=!1),C===void 0&&(C=1),d();let L=n.getBoundingClientRect(),{left:W,top:K,width:rt,height:X}=L;if(b||o(),!rt||!X)return;let et=Ra(K),lt=Ra(a.clientWidth-(W+rt)),dt=Ra(a.clientHeight-(K+X)),gt=Ra(W),Nt={rootMargin:-et+"px "+-lt+"px "+-dt+"px "+-gt+"px",threshold:_e(0,Fr(1,C))||1},jt=!0;function Vt(Ut){let Zt=Ut[0].intersectionRatio;if(Zt!==C){if(!jt)return m();Zt?m(!1,Zt):i=setTimeout(()=>{m(!1,1e-7)},1e3)}Zt===1&&!_f(L,n.getBoundingClientRect())&&m(),jt=!1}try{t=new IntersectionObserver(Vt,{...Nt,root:a.ownerDocument})}catch{t=new IntersectionObserver(Vt,Nt)}t.observe(n)}return m(!0),d}function If(n,o,t,i){i===void 0&&(i={});let{ancestorScroll:a=!0,ancestorResize:d=!0,elementResize:m=typeof ResizeObserver=="function",layoutShift:b=typeof IntersectionObserver=="function",animationFrame:C=!1}=i,L=Dc(n),W=a||d?[...L?bs(L):[],...bs(o)]:[];W.forEach(gt=>{a&>.addEventListener("scroll",t,{passive:!0}),d&>.addEventListener("resize",t)});let K=L&&b?uT(L,t):null,rt=-1,X=null;m&&(X=new ResizeObserver(gt=>{let[At]=gt;At&&At.target===L&&X&&(X.unobserve(o),cancelAnimationFrame(rt),rt=requestAnimationFrame(()=>{var Nt;(Nt=X)==null||Nt.observe(o)})),t()}),L&&!C&&X.observe(L),X.observe(o));let et,lt=C?So(n):null;C&&dt();function dt(){let gt=So(n);lt&&!_f(lt,gt)&&t(),lt=gt,et=requestAnimationFrame(dt)}return t(),()=>{var gt;W.forEach(At=>{a&&At.removeEventListener("scroll",t),d&&At.removeEventListener("resize",t)}),K==null||K(),(gt=X)==null||gt.disconnect(),X=null,C&&cancelAnimationFrame(et)}}var Cf=cf;var kf=hf,wf=df,Nf=pf;var Lf=lf;var Rf=(n,o,t)=>{let i=new Map,a={platform:mT,...t},d={...a.platform,_c:i};return nf(n,o,{...a,platform:d})};var Mf=z.constructTagName("popover"),wt={LEFT_START:"left-start",LEFT:"left",LEFT_END:"left-end",RIGHT_START:"right-start",RIGHT:"right",RIGHT_END:"right-end",TOP_START:"top-start",TOP:"top",TOP_END:"top-end",BOTTOM_START:"bottom-start",BOTTOM:"bottom",BOTTOM_END:"bottom-end"},ci={CLICK:"click",MOUSEENTER:"mouseenter",FOCUSIN:"focusin",MANUAL:"manual"},_o={TONAL:"tonal",CONTRAST:"contrast"},fT={ABSOLUTE:"absolute",FIXED:"fixed"},_t={PLACEMENT:wt.BOTTOM,TRIGGER:ci.CLICK,COLOR:_o.TONAL,STRATEGY:fT.ABSOLUTE,OFFSET:4,BOUNDARY:"clippingAncestors",BOUNDARY_ROOT:"viewport",BOUNDARY_PADDING:0,VISIBLE:!1,ARROW:!1,CLOSE_BUTTON:!1,FOCUS_TRAP:!1,INTERACTIVE:!1,PREVENT_SCROLL:!1,HIDE_ON_ESCAPE:!1,HIDE_ON_BLUR:!1,HIDE_ON_CLICK_OUTSIDE:!1,FOCUS_BACK:!1,BACKDROP:!1,FLIP:!0,SIZE:!1,DELAY:"0,0",ROLE:tt.DIALOG,Z_INDEX:1e3,DISABLE_ARIA_EXPANDED:!1,PROPAGATE_EVENT_ON_ESCAPE:!1,KEEP_CONNECTED_TOOLTIP_CLOSED:!0,IS_BACKDROP_INVISIBLE:!0};var hi=class{static dispatchPopoverEvent(o,t){t.dispatchEvent(new CustomEvent(o,{detail:{show:t.visible},composed:!0,bubbles:!0}))}static onShowPopover(o){this.dispatchPopoverEvent("shown",o)}static onHidePopover(o){this.dispatchPopoverEvent("hidden",o)}static onCreatedPopover(o){this.dispatchPopoverEvent("created",o)}static onDestroyedPopover(o){this.dispatchPopoverEvent("destroyed",o)}static onEscapeKeyPressed(o){this.dispatchPopoverEvent("closebyescape",o)}static onClickOutside(o){this.dispatchPopoverEvent("closebyoutsideclick",o)}};var Fc=class{constructor(){this.stack=[]}push(o){this.stack.push(o)}pop(){return this.stack.pop()}peek(){return this.stack[this.stack.length-1]}remove(o){this.stack=this.stack.filter(t=>t!==o)}has(o){return this.stack.includes(o)}clear(){this.stack=[]}},Ie=new Fc;var vT=B`
|
|
2538
2538
|
:host {
|
|
2539
2539
|
--mdc-popover-arrow-border-radius: 0.1875rem;
|
|
2540
2540
|
--mdc-popover-arrow-border: 0.0625rem solid var(--mds-color-theme-outline-secondary-normal);
|
|
@@ -2656,7 +2656,7 @@
|
|
|
2656
2656
|
border-top-right-radius: var(--mdc-popover-arrow-border-radius);
|
|
2657
2657
|
border-bottom-left-radius: 100%;
|
|
2658
2658
|
}
|
|
2659
|
-
`,Of=[vT];var $l=z.constructTagName("popoverportal"),Dl=class extends q{connectedCallback(){super.connectedCallback(),this.ariaHidden="true",this.style.display="none"}disconnectedCallback(){var o;super.disconnectedCallback(),(o=this.onDisconnect)==null||o.call(this)}};var Fl=class{constructor(o){this.portalElement=null;this.disconnectAfterAppendTo=!1;this.arrowPixelChange=!1;this.popover=o}setupDelay(){try{let[o,t]=this.popover.delay.split(",").map(i=>{let a=parseInt(i,10);if(Number.isNaN(a)||a<0)throw new Error(`Invalid delay value: ${i}`);return a});return[o,t]}catch{return this.popover.delay="0,0",[0,0]}}setupHoverBridge(o){let t=this.popover.renderRoot.querySelector('div[part="popover-hover-bridge"]');Object.assign(t.style,{top:"",left:"",right:"",bottom:""});let i=`calc(${this.popover.showArrow?"0.75rem + ":""}${this.popover.offset}px)`,a=this.popover.offsetHeight||0,d=this.popover.offsetWidth||0;if(t)switch(o.split("-")[0]){case"top":t.style.height=i,t.style.bottom=`calc(-1 * (${i}))`,t.style.left="50%",t.style.width=`${d}px`;break;case"left":t.style.height=`${a}px`,t.style.width=i,t.style.right=`calc(-1.5 * (${i}))`;break;case"right":t.style.height=`${a}px`,t.style.width=i,t.style.left=`calc(-0.5 * (${i}))`;break;case"bottom":default:t.style.height=i,t.style.top=`calc(-1 * (${i}))`,t.style.left="50%",t.style.width=`${d}px`;break}}setupAppendTo(){var o,t;if(this.popover.appendTo){let i=document.getElementById(this.popover.appendTo);i&&!Array.from(i.children).includes(this.popover)&&(this.disconnectAfterAppendTo=!0,this.portalElement=document.createElement($l),this.portalElement.onDisconnect=()=>{this.popover.remove(),this.portalElement=null},(t=(o=this.popover.parentElement)==null?void 0:o.appendChild)==null||t.call(o,this.portalElement),i.appendChild(this.popover))}}cleanupAppendTo(){!this.disconnectAfterAppendTo&&this.portalElement&&this.portalElement.remove(),this.disconnectAfterAppendTo=!1}updateAriaLabels(){var o,t,i;this.popover.interactive&&this.popover.role&&(this.popover.ariaLabel||(this.popover.ariaLabel=((o=this.popover.triggerElement)==null?void 0:o.ariaLabel)||((t=this.popover.triggerElement)==null?void 0:t.textContent)||""),this.popover.ariaLabelledby||(this.popover.ariaLabelledby=((i=this.popover.triggerElement)==null?void 0:i.id)||""))}updateAriaModal(){this.popover.role===tt.DIALOG||this.popover.role===tt.ALERTDIALOG?this.popover.setAttribute("aria-modal","true"):this.popover.removeAttribute("aria-modal")}updateAriaExpandedAttribute(){var o,t,i;this.popover.disableAriaExpanded||((o=this.popover.triggerElement)==null||o.setAttribute("aria-expanded",`${this.popover.visible}`),(i=this.popover.triggerElement)==null||i.setAttribute("aria-haspopup",((t=this.popover.triggerElement)==null?void 0:t.getAttribute("aria-haspopup"))||this.popover.role||"dialog"))}updateArrowStyle(o,t){var W;if(!this.popover.arrowElement)return;let i=t.split("-")[0],a={top:"bottom",right:"left",bottom:"top",left:"right"}[i],{x:d,y:m}=o,b=this.popover.arrowElement.getBoundingClientRect(),C=(W=this.popover.arrowElement.offsetParent)==null?void 0:W.getBoundingClientRect();if(!this.arrowPixelChange){let K=C!=null&&C[a]?12-Math.abs(b[a]-C[a]):0;Math.round(K)===1?this.arrowPixelChange=!0:this.arrowPixelChange=!1}let L=this.arrowPixelChange?.5:0;this.popover.arrowElement.setAttribute("data-side",i),Object.assign(this.popover.arrowElement.style,{left:d!=null?`${d}px`:"",top:m!=null?`${m}px`:"",[a]:`${-this.popover.arrowElement.offsetHeight/2-L}px`})}updatePopoverStyle(o,t){Object.assign(this.popover.style,{left:`${o}px`,top:`${t}px`})}};var It=class extends ml(dl(ll(q))){constructor(){super();this.id="";this.triggerID="";this.trigger=_t.TRIGGER;this.placement=_t.PLACEMENT;this.color=_t.COLOR;this.visible=_t.VISIBLE;this.offset=_t.OFFSET;this.boundary=_t.BOUNDARY;this.boundaryRoot=_t.BOUNDARY_ROOT;this.focusTrap=_t.FOCUS_TRAP;this.preventScroll=_t.PREVENT_SCROLL;this.showArrow=_t.ARROW;this.closeButton=_t.CLOSE_BUTTON;this.interactive=_t.INTERACTIVE;this.delay=_t.DELAY;this.hideOnEscape=_t.HIDE_ON_ESCAPE;this.propagateEventOnEscape=_t.PROPAGATE_EVENT_ON_ESCAPE;this.hideOnBlur=_t.HIDE_ON_BLUR;this.hideOnOutsideClick=_t.HIDE_ON_CLICK_OUTSIDE;this.focusBackToTrigger=_t.FOCUS_BACK;this.backdrop=_t.BACKDROP;this.isBackdropInvisible=_t.IS_BACKDROP_INVISIBLE;this.flip=_t.FLIP;this.size=_t.SIZE;this.zIndex=_t.Z_INDEX;this.closeButtonAriaLabel=null;this.strategy=_t.STRATEGY;this.role=_t.ROLE;this.ariaLabelledby=null;this.ariaDescribedby=null;this.disableAriaExpanded=_t.DISABLE_ARIA_EXPANDED;this.keepConnectedTooltipClosed=_t.KEEP_CONNECTED_TOOLTIP_CLOSED;this.arrowElement=null;this.hoverTimer=null;this.isHovered=!1;this.openDelay=0;this.closeDelay=0;this.floatingUICleanupFunction=null;this.shouldSuppressOpening=!1;this.parseTrigger=()=>{var d;let a=(((d=this.trigger)==null?void 0:d.split(" "))||[]).filter(m=>Object.values(ci).includes(m)).length>0?this.trigger:_t.TRIGGER;a==="mouseenter"&&(this.interactive?a="mouseenter click":a="mouseenter focusin"),this.trigger=a};this.setupTriggerListeners=()=>{if(this.trigger.includes("click")&&document.addEventListener("click",this.togglePopoverVisible,{capture:!0}),this.trigger.includes("mouseenter")){let t=this.renderRoot.querySelector('div[part="popover-hover-bridge"]');t==null||t.addEventListener("mouseenter",this.show),document.addEventListener("mouseenter",this.handleMouseEnter,{capture:!0}),document.addEventListener("mouseleave",this.handleMouseLeave,{capture:!0}),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay)}this.trigger.includes("focusin")&&(document.addEventListener("focusin",this.handleFocusIn,{capture:!0}),this.interactive||document.addEventListener("focusout",this.handleFocusOut,{capture:!0}))};this.removeTriggerListeners=()=>{document.removeEventListener("click",this.togglePopoverVisible,{capture:!0});let t=this.renderRoot.querySelector('div[part="popover-hover-bridge"]');t==null||t.removeEventListener("mouseenter",this.show),document.removeEventListener("mouseenter",this.handleMouseEnter,{capture:!0}),document.removeEventListener("mouseleave",this.handleMouseLeave,{capture:!0}),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("mouseleave",this.startCloseDelay),document.removeEventListener("focusin",this.handleFocusIn,{capture:!0}),document.removeEventListener("focusout",this.handleFocusOut,{capture:!0})};this.removeAllListeners=()=>{this.removeTriggerListeners(),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick,{capture:!0}),this.hideOnEscape&&(this.removeEventListener("keydown",this.onEscapeKeydown),document.removeEventListener("keydown",this.onEscapeKeydown,{capture:!0})),this.hideOnBlur&&this.removeEventListener("focusout",this.onPopoverFocusOut)};this.onOutsidePopoverClick=t=>{if(Ie.peek()!==this)return;let i=t.composedPath(),a=this.contains(t.target)||i.includes(this.triggerElement)||i.includes(this),d=this.backdropElement?i.includes(this.backdropElement):!1;(!a||d)&&(this.hide(),hi.onClickOutside(this))};this.onEscapeKeydown=t=>{!this.visible||t.code!=="Escape"||(this.propagateEventOnEscape||t.stopPropagation(),t.preventDefault(),this.hide(),hi.onEscapeKeyPressed(this))};this.onPopoverFocusOut=t=>{this.contains(t.relatedTarget)||this.hide()};this.handleMouseEnter=t=>{this.isEventFromTrigger(t)&&(this.isHovered=!0,this.show())};this.handleMouseLeave=t=>{this.isEventFromTrigger(t)&&(this.isHovered=!1,this.startCloseDelay())};this.handleFocusOut=t=>{this.isEventFromTrigger(t)&&(this.isHovered||this.hide())};this.handleFocusIn=t=>{var i;this.isEventFromTrigger(t)&&((i=this.triggerElement)!=null&&i.matches(":focus-visible")||this.isHovered)&&this.show()};this.startCloseDelay=()=>{this.interactive?this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay):this.hide()};this.cancelCloseDelay=()=>{this.hoverTimer&&(window.clearTimeout(this.hoverTimer),this.hoverTimer=null)};this.show=()=>{this.visible||this.shouldSuppressOpening||(this.cancelCloseDelay(),this.openDelay>0?setTimeout(()=>{this.visible=!0},this.openDelay):this.visible=!0)};this.hide=()=>{this.closeDelay?setTimeout(()=>{this.visible=!1},this.closeDelay):this.visible=!1};this.togglePopoverVisible=t=>{this.isEventFromTrigger(t)&&(this.visible?this.hide():this.show())};this.positionPopover=()=>{let{triggerElement:t}=this;if(!t)return;let i=!this.boundary||this.boundary==="clippingAncestors"?"clippingAncestors":Array.from(document.querySelectorAll(this.boundary)),a=this.boundaryRoot,d=[kf({boundary:i,rootBoundary:a,padding:this.boundaryPadding})],m=this.offset;if(this.flip&&d.push(wf({boundary:i,rootBoundary:a})),this.size){let b=L=>{this.style.setProperty("--mdc-popover-internal-available-height",`${L}px`)},C=this.renderRoot.querySelector('[part="popover-content"]');d.push(Nf({boundary:i,rootBoundary:a,apply({availableHeight:L}){C&&(Object.assign(C.style,{maxHeight:`${L}px`,overflowY:"auto"}),b(L))},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector('div[part="popover-arrow"]'),this.arrowElement)){let b=this.arrowElement.offsetHeight,C=Math.sqrt(2*b**2)/2;m+=C,d.push(Lf({element:this.arrowElement,padding:12}))}d.push(Cf(m)),this.floatingUICleanupFunction=If(t,this,async()=>{let{triggerElement:b}=this;if(!b)return;let C=this.adjustPlacementForRtl(this.placement),{x:L,y:W,middlewareData:K,placement:rt}=await Rf(b,this,{placement:C,middleware:d,strategy:this.strategy});this.utils.updatePopoverStyle(L,W),K.arrow&&this.arrowElement&&this.utils.updateArrowStyle(K.arrow,rt),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(rt)})};this.utils=new Fl(this),this.parseTrigger(),[this.openDelay,this.closeDelay]=this.utils.setupDelay()}get connectedTooltip(){let t=this.getRootNode().querySelectorAll(`mdc-tooltip[triggerID="${this.triggerID}"]`);return Array.from(t).find(i=>i!==this)}get triggerElement(){return this.getRootNode().querySelector(`[id="${this.triggerID}"]`)}async firstUpdated(t){super.firstUpdated(t),hi.onCreatedPopover(this)}connectedCallback(){super.connectedCallback(),this.style.zIndex=`${this.zIndex}`,this.utils.setupAppendTo(),this.setupTriggerListeners()}async disconnectedCallback(){var t,i;super.disconnectedCallback(),this.removeAllListeners(),(t=this.deactivateFocusTrap)==null||t.call(this),this.deactivatePreventScroll(),this.moveElementBackAfterBackdropRemoval(this.triggerElement),this.removeBackdrop(),(i=this.floatingUICleanupFunction)==null||i.call(this),this.cancelCloseDelay(),this.keepConnectedTooltipClosed&&this.connectedTooltip&&(this.connectedTooltip.shouldSuppressOpening=!1),this.utils.cleanupAppendTo(),hi.onDestroyedPopover(this),Ie.remove(this)}async updated(t){if(super.updated(t),t.has("visible")){let i=t.get("visible")||!1;await this.isOpenUpdated(i,this.visible),this.utils.updateAriaExpandedAttribute()}t.has("trigger")&&(this.parseTrigger(),this.removeTriggerListeners(),this.setupTriggerListeners()),t.has("placement")&&this.setAttribute("placement",Object.values(kt).includes(this.placement)?this.placement:_t.PLACEMENT),t.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),t.has("color")&&this.setAttribute("color",Object.values(_o).includes(this.color)?this.color:_t.COLOR),t.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),t.has("appendTo")&&(this.appendTo?this.utils.setupAppendTo():this.utils.cleanupAppendTo()),(t.has("interactive")||t.has("aria-label")||t.has("aria-labelledby"))&&this.utils.updateAriaLabels(),t.has("role")&&(this.role===""&&(this.role=null),this.utils.updateAriaModal()),t.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),t.has("focusTrap")&&!this.focusTrap&&this.visible&&this.deactivateFocusTrap(),t.has("preventScroll")&&(!this.preventScroll&&this.visible?this.deactivatePreventScroll():this.preventScroll&&this.visible&&this.activatePreventScroll())}async isOpenUpdated(t,i){var d,m;let{triggerElement:a}=this;t===i||!a||(i&&!this.shouldSuppressOpening?(Ie.peek()!==this&&Ie.push(this),this.keepConnectedTooltipClosed&&this.connectedTooltip&&(this.connectedTooltip.visible=!1,this.connectedTooltip.shouldSuppressOpening=!0),this.backdrop&&!this.backdropElement&&(this.createBackdrop("popover"),this.keepElementAboveBackdrop(a)),this.positionPopover(),this.hideOnBlur&&(this.addEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(a.style.pointerEvents="none")),this.hideOnEscape&&(this.addEventListener("keydown",this.onEscapeKeydown),document.addEventListener("keydown",this.onEscapeKeydown)),this.activatePreventScroll(),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick,{capture:!0}),setTimeout(()=>{var b,C;this.interactive&&this.focusTrap&&((b=this.activateFocusTrap)==null||b.call(this),(C=this.setInitialFocus)==null||C.call(this))},0),hi.onShowPopover(this)):(Ie.peek()===this&&Ie.pop(),(d=this.floatingUICleanupFunction)==null||d.call(this),this.backdrop&&(this.moveElementBackAfterBackdropRemoval(a),this.removeBackdrop()),this.hideOnBlur&&(this.removeEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(a.style.pointerEvents="")),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick,{capture:!0}),this.hideOnEscape&&(this.removeEventListener("keydown",this.onEscapeKeydown),document.removeEventListener("keydown",this.onEscapeKeydown)),this.deactivatePreventScroll(),(m=this.deactivateFocusTrap)==null||m.call(this),this.focusBackToTrigger&&(a==null||a.focus()),this.keepConnectedTooltipClosed&&this.connectedTooltip&&(this.connectedTooltip.shouldSuppressOpening=!1),hi.onHidePopover(this)))}isEventFromTrigger(t){var i;return this.triggerID?t.composed?t.composedPath().some(a=>(a==null?void 0:a.id)===this.triggerID):((i=t.target)==null?void 0:i.id)===this.triggerID:!1}isRtl(){return window.getComputedStyle(this).direction==="rtl"}adjustPlacementForRtl(t){if(!this.isRtl())return t;switch(t){case kt.LEFT:return kt.RIGHT;case kt.LEFT_START:return kt.RIGHT_START;case kt.LEFT_END:return kt.RIGHT_END;case kt.RIGHT:return kt.LEFT;case kt.RIGHT_START:return kt.LEFT_START;case kt.RIGHT_END:return kt.LEFT_END;default:return t}}render(){return _`
|
|
2659
|
+
`,Of=[vT];var $l=z.constructTagName("popoverportal"),Dl=class extends q{connectedCallback(){super.connectedCallback(),this.ariaHidden="true",this.style.display="none"}disconnectedCallback(){var o;super.disconnectedCallback(),(o=this.onDisconnect)==null||o.call(this)}};var Fl=class{constructor(o){this.portalElement=null;this.disconnectAfterAppendTo=!1;this.arrowPixelChange=!1;this.popover=o}setupDelay(){try{let[o,t]=this.popover.delay.split(",").map(i=>{let a=parseInt(i,10);if(Number.isNaN(a)||a<0)throw new Error(`Invalid delay value: ${i}`);return a});return[o,t]}catch{return this.popover.delay="0,0",[0,0]}}setupHoverBridge(o){let t=this.popover.renderRoot.querySelector('div[part="popover-hover-bridge"]');Object.assign(t.style,{top:"",left:"",right:"",bottom:""});let i=`calc(${this.popover.showArrow?"0.75rem + ":""}${this.popover.offset}px)`,a=this.popover.offsetHeight||0,d=this.popover.offsetWidth||0;if(t)switch(o.split("-")[0]){case"top":t.style.height=i,t.style.bottom=`calc(-1 * (${i}))`,t.style.left="50%",t.style.width=`${d}px`;break;case"left":t.style.height=`${a}px`,t.style.width=i,t.style.right=`calc(-1.5 * (${i}))`;break;case"right":t.style.height=`${a}px`,t.style.width=i,t.style.left=`calc(-0.5 * (${i}))`;break;case"bottom":default:t.style.height=i,t.style.top=`calc(-1 * (${i}))`,t.style.left="50%",t.style.width=`${d}px`;break}}setupAppendTo(){var o,t;if(this.popover.appendTo){let i=document.getElementById(this.popover.appendTo);i&&!Array.from(i.children).includes(this.popover)&&(this.disconnectAfterAppendTo=!0,this.portalElement=document.createElement($l),this.portalElement.onDisconnect=()=>{this.popover.remove(),this.portalElement=null},(t=(o=this.popover.parentElement)==null?void 0:o.appendChild)==null||t.call(o,this.portalElement),i.appendChild(this.popover))}}cleanupAppendTo(){!this.disconnectAfterAppendTo&&this.portalElement&&this.portalElement.remove(),this.disconnectAfterAppendTo=!1}updateAriaLabels(){var o,t,i;this.popover.interactive&&this.popover.role&&(this.popover.ariaLabel||(this.popover.ariaLabel=((o=this.popover.triggerElement)==null?void 0:o.ariaLabel)||((t=this.popover.triggerElement)==null?void 0:t.textContent)||""),this.popover.ariaLabelledby||(this.popover.ariaLabelledby=((i=this.popover.triggerElement)==null?void 0:i.id)||""))}updateAriaModal(){this.popover.role===tt.DIALOG||this.popover.role===tt.ALERTDIALOG?this.popover.setAttribute("aria-modal","true"):this.popover.removeAttribute("aria-modal")}updateAriaExpandedAttribute(){var o,t,i;this.popover.disableAriaExpanded||((o=this.popover.triggerElement)==null||o.setAttribute("aria-expanded",`${this.popover.visible}`),(i=this.popover.triggerElement)==null||i.setAttribute("aria-haspopup",((t=this.popover.triggerElement)==null?void 0:t.getAttribute("aria-haspopup"))||this.popover.role||"dialog"))}updateArrowStyle(o,t){var W;if(!this.popover.arrowElement)return;let i=t.split("-")[0],a={top:"bottom",right:"left",bottom:"top",left:"right"}[i],{x:d,y:m}=o,b=this.popover.arrowElement.getBoundingClientRect(),C=(W=this.popover.arrowElement.offsetParent)==null?void 0:W.getBoundingClientRect();if(!this.arrowPixelChange){let K=C!=null&&C[a]?12-Math.abs(b[a]-C[a]):0;Math.round(K)===1?this.arrowPixelChange=!0:this.arrowPixelChange=!1}let L=this.arrowPixelChange?.5:0;this.popover.arrowElement.setAttribute("data-side",i),Object.assign(this.popover.arrowElement.style,{left:d!=null?`${d}px`:"",top:m!=null?`${m}px`:"",[a]:`${-this.popover.arrowElement.offsetHeight/2-L}px`})}updatePopoverStyle(o,t){Object.assign(this.popover.style,{left:`${o}px`,top:`${t}px`})}};var It=class extends ml(dl(ll(q))){constructor(){super();this.id="";this.triggerID="";this.trigger=_t.TRIGGER;this.placement=_t.PLACEMENT;this.color=_t.COLOR;this.visible=_t.VISIBLE;this.offset=_t.OFFSET;this.boundary=_t.BOUNDARY;this.boundaryRoot=_t.BOUNDARY_ROOT;this.focusTrap=_t.FOCUS_TRAP;this.preventScroll=_t.PREVENT_SCROLL;this.showArrow=_t.ARROW;this.closeButton=_t.CLOSE_BUTTON;this.interactive=_t.INTERACTIVE;this.delay=_t.DELAY;this.hideOnEscape=_t.HIDE_ON_ESCAPE;this.propagateEventOnEscape=_t.PROPAGATE_EVENT_ON_ESCAPE;this.hideOnBlur=_t.HIDE_ON_BLUR;this.hideOnOutsideClick=_t.HIDE_ON_CLICK_OUTSIDE;this.focusBackToTrigger=_t.FOCUS_BACK;this.backdrop=_t.BACKDROP;this.isBackdropInvisible=_t.IS_BACKDROP_INVISIBLE;this.flip=_t.FLIP;this.size=_t.SIZE;this.zIndex=_t.Z_INDEX;this.closeButtonAriaLabel=null;this.strategy=_t.STRATEGY;this.role=_t.ROLE;this.ariaLabelledby=null;this.ariaDescribedby=null;this.disableAriaExpanded=_t.DISABLE_ARIA_EXPANDED;this.keepConnectedTooltipClosed=_t.KEEP_CONNECTED_TOOLTIP_CLOSED;this.arrowElement=null;this.hoverTimer=null;this.isHovered=!1;this.openDelay=0;this.closeDelay=0;this.floatingUICleanupFunction=null;this.shouldSuppressOpening=!1;this.parseTrigger=()=>{var d;let a=(((d=this.trigger)==null?void 0:d.split(" "))||[]).filter(m=>Object.values(ci).includes(m)).length>0?this.trigger:_t.TRIGGER;a==="mouseenter"&&(this.interactive?a="mouseenter click":a="mouseenter focusin"),this.trigger=a};this.setupTriggerListeners=()=>{if(this.trigger.includes("click")&&document.addEventListener("click",this.togglePopoverVisible,{capture:!0}),this.trigger.includes("mouseenter")){let t=this.renderRoot.querySelector('div[part="popover-hover-bridge"]');t==null||t.addEventListener("mouseenter",this.show),document.addEventListener("mouseenter",this.handleMouseEnter,{capture:!0}),document.addEventListener("mouseleave",this.handleMouseLeave,{capture:!0}),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay)}this.trigger.includes("focusin")&&(document.addEventListener("focusin",this.handleFocusIn,{capture:!0}),this.interactive||document.addEventListener("focusout",this.handleFocusOut,{capture:!0}))};this.removeTriggerListeners=()=>{document.removeEventListener("click",this.togglePopoverVisible,{capture:!0});let t=this.renderRoot.querySelector('div[part="popover-hover-bridge"]');t==null||t.removeEventListener("mouseenter",this.show),document.removeEventListener("mouseenter",this.handleMouseEnter,{capture:!0}),document.removeEventListener("mouseleave",this.handleMouseLeave,{capture:!0}),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("mouseleave",this.startCloseDelay),document.removeEventListener("focusin",this.handleFocusIn,{capture:!0}),document.removeEventListener("focusout",this.handleFocusOut,{capture:!0})};this.removeAllListeners=()=>{this.removeTriggerListeners(),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick,{capture:!0}),this.hideOnEscape&&(this.removeEventListener("keydown",this.onEscapeKeydown),document.removeEventListener("keydown",this.onEscapeKeydown,{capture:!0})),this.hideOnBlur&&this.removeEventListener("focusout",this.onPopoverFocusOut)};this.onOutsidePopoverClick=t=>{if(Ie.peek()!==this)return;let i=t.composedPath(),a=this.contains(t.target)||i.includes(this.triggerElement)||i.includes(this),d=this.backdropElement?i.includes(this.backdropElement):!1;(!a||d)&&(this.hide(),hi.onClickOutside(this))};this.onEscapeKeydown=t=>{!this.visible||t.code!=="Escape"||(this.propagateEventOnEscape||t.stopPropagation(),t.preventDefault(),this.hide(),hi.onEscapeKeyPressed(this))};this.onPopoverFocusOut=t=>{this.contains(t.relatedTarget)||this.hide()};this.handleMouseEnter=t=>{this.isEventFromTrigger(t)&&(this.isHovered=!0,this.show())};this.handleMouseLeave=t=>{this.isEventFromTrigger(t)&&(this.isHovered=!1,this.startCloseDelay())};this.handleFocusOut=t=>{this.isEventFromTrigger(t)&&(this.isHovered||this.hide())};this.handleFocusIn=t=>{var i;this.isEventFromTrigger(t)&&((i=this.triggerElement)!=null&&i.matches(":focus-visible")||this.isHovered)&&this.show()};this.startCloseDelay=()=>{this.interactive?this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay):this.hide()};this.cancelCloseDelay=()=>{this.hoverTimer&&(window.clearTimeout(this.hoverTimer),this.hoverTimer=null)};this.show=()=>{this.visible||this.shouldSuppressOpening||(this.cancelCloseDelay(),this.openDelay>0?setTimeout(()=>{this.visible=!0},this.openDelay):this.visible=!0)};this.hide=()=>{this.closeDelay?setTimeout(()=>{this.visible=!1},this.closeDelay):this.visible=!1};this.togglePopoverVisible=t=>{this.isEventFromTrigger(t)&&(this.visible?this.hide():this.show())};this.positionPopover=()=>{let{triggerElement:t}=this;if(!t)return;let i=!this.boundary||this.boundary==="clippingAncestors"?"clippingAncestors":Array.from(document.querySelectorAll(this.boundary)),a=this.boundaryRoot,d=[kf({boundary:i,rootBoundary:a,padding:this.boundaryPadding})],m=this.offset;if(this.flip&&d.push(wf({boundary:i,rootBoundary:a})),this.size){let b=L=>{this.style.setProperty("--mdc-popover-internal-available-height",`${L}px`)},C=this.renderRoot.querySelector('[part="popover-content"]');d.push(Nf({boundary:i,rootBoundary:a,apply({availableHeight:L}){C&&(Object.assign(C.style,{maxHeight:`${L}px`,overflowY:"auto"}),b(L))},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector('div[part="popover-arrow"]'),this.arrowElement)){let b=this.arrowElement.offsetHeight,C=Math.sqrt(2*b**2)/2;m+=C,d.push(Lf({element:this.arrowElement,padding:12}))}d.push(Cf(m)),this.floatingUICleanupFunction=If(t,this,async()=>{let{triggerElement:b}=this;if(!b)return;let C=this.adjustPlacementForRtl(this.placement),{x:L,y:W,middlewareData:K,placement:rt}=await Rf(b,this,{placement:C,middleware:d,strategy:this.strategy});this.utils.updatePopoverStyle(L,W),K.arrow&&this.arrowElement&&this.utils.updateArrowStyle(K.arrow,rt),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(rt)})};this.utils=new Fl(this),this.parseTrigger(),[this.openDelay,this.closeDelay]=this.utils.setupDelay()}get connectedTooltip(){let t=this.getRootNode().querySelectorAll(`mdc-tooltip[triggerID="${this.triggerID}"]`);return Array.from(t).find(i=>i!==this)}get triggerElement(){return this.getRootNode().querySelector(`[id="${this.triggerID}"]`)}async firstUpdated(t){super.firstUpdated(t),hi.onCreatedPopover(this)}connectedCallback(){super.connectedCallback(),this.style.zIndex=`${this.zIndex}`,this.utils.setupAppendTo(),this.setupTriggerListeners()}async disconnectedCallback(){var t,i;super.disconnectedCallback(),this.removeAllListeners(),(t=this.deactivateFocusTrap)==null||t.call(this),this.deactivatePreventScroll(),this.moveElementBackAfterBackdropRemoval(this.triggerElement),this.removeBackdrop(),(i=this.floatingUICleanupFunction)==null||i.call(this),this.cancelCloseDelay(),this.keepConnectedTooltipClosed&&this.connectedTooltip&&(this.connectedTooltip.shouldSuppressOpening=!1),this.utils.cleanupAppendTo(),hi.onDestroyedPopover(this),Ie.remove(this)}async updated(t){if(super.updated(t),t.has("visible")){let i=t.get("visible")||!1;await this.isOpenUpdated(i,this.visible),this.utils.updateAriaExpandedAttribute()}t.has("trigger")&&(this.parseTrigger(),this.removeTriggerListeners(),this.setupTriggerListeners()),t.has("placement")&&this.setAttribute("placement",Object.values(wt).includes(this.placement)?this.placement:_t.PLACEMENT),t.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),t.has("color")&&this.setAttribute("color",Object.values(_o).includes(this.color)?this.color:_t.COLOR),t.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),t.has("appendTo")&&(this.appendTo?this.utils.setupAppendTo():this.utils.cleanupAppendTo()),(t.has("interactive")||t.has("aria-label")||t.has("aria-labelledby"))&&this.utils.updateAriaLabels(),t.has("role")&&(this.role===""&&(this.role=null),this.utils.updateAriaModal()),t.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),t.has("focusTrap")&&!this.focusTrap&&this.visible&&this.deactivateFocusTrap(),t.has("preventScroll")&&(!this.preventScroll&&this.visible?this.deactivatePreventScroll():this.preventScroll&&this.visible&&this.activatePreventScroll())}async isOpenUpdated(t,i){var d,m;let{triggerElement:a}=this;t===i||!a||(i&&!this.shouldSuppressOpening?(Ie.peek()!==this&&Ie.push(this),this.keepConnectedTooltipClosed&&this.connectedTooltip&&(this.connectedTooltip.visible=!1,this.connectedTooltip.shouldSuppressOpening=!0),this.backdrop&&!this.backdropElement&&(this.createBackdrop("popover"),this.keepElementAboveBackdrop(a)),this.positionPopover(),this.hideOnBlur&&(this.addEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(a.style.pointerEvents="none")),this.hideOnEscape&&(this.addEventListener("keydown",this.onEscapeKeydown),document.addEventListener("keydown",this.onEscapeKeydown)),this.activatePreventScroll(),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick,{capture:!0}),setTimeout(()=>{var b,C;this.interactive&&this.focusTrap&&((b=this.activateFocusTrap)==null||b.call(this),(C=this.setInitialFocus)==null||C.call(this))},0),hi.onShowPopover(this)):(Ie.peek()===this&&Ie.pop(),(d=this.floatingUICleanupFunction)==null||d.call(this),this.backdrop&&(this.moveElementBackAfterBackdropRemoval(a),this.removeBackdrop()),this.hideOnBlur&&(this.removeEventListener("focusout",this.onPopoverFocusOut),this.trigger==="click"&&(a.style.pointerEvents="")),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick,{capture:!0}),this.hideOnEscape&&(this.removeEventListener("keydown",this.onEscapeKeydown),document.removeEventListener("keydown",this.onEscapeKeydown)),this.deactivatePreventScroll(),(m=this.deactivateFocusTrap)==null||m.call(this),this.focusBackToTrigger&&(a==null||a.focus()),this.keepConnectedTooltipClosed&&this.connectedTooltip&&(this.connectedTooltip.shouldSuppressOpening=!1),hi.onHidePopover(this)))}isEventFromTrigger(t){var i;return this.triggerID?t.composed?t.composedPath().some(a=>(a==null?void 0:a.id)===this.triggerID):((i=t.target)==null?void 0:i.id)===this.triggerID:!1}isRtl(){return window.getComputedStyle(this).direction==="rtl"}adjustPlacementForRtl(t){if(!this.isRtl())return t;switch(t){case wt.LEFT:return wt.RIGHT;case wt.LEFT_START:return wt.RIGHT_START;case wt.LEFT_END:return wt.RIGHT_END;case wt.RIGHT:return wt.LEFT;case wt.RIGHT_START:return wt.LEFT_START;case wt.RIGHT_END:return wt.LEFT_END;default:return t}}render(){return _`
|
|
2660
2660
|
<div part="popover-hover-bridge"></div>
|
|
2661
2661
|
${this.closeButton?_` <mdc-button
|
|
2662
2662
|
part="popover-close"
|
|
@@ -2670,7 +2670,7 @@
|
|
|
2670
2670
|
<div part="popover-content">
|
|
2671
2671
|
<slot></slot>
|
|
2672
2672
|
</div>
|
|
2673
|
-
`}};It.styles=[...q.styles,...Of],p([u({type:String,reflect:!0})],It.prototype,"id",2),p([u({type:String,reflect:!0})],It.prototype,"triggerID",2),p([u({type:String,reflect:!0})],It.prototype,"trigger",2),p([u({type:String,reflect:!0})],It.prototype,"placement",2),p([u({type:String,reflect:!0})],It.prototype,"color",2),p([u({type:Boolean,reflect:!0})],It.prototype,"visible",2),p([u({type:Number,reflect:!0})],It.prototype,"offset",2),p([u({type:String,reflect:!0,attribute:"boundary"})],It.prototype,"boundary",2),p([u({type:String,reflect:!0,attribute:"boundary-root"})],It.prototype,"boundaryRoot",2),p([u({type:Number,reflect:!0,attribute:"boundary-padding"})],It.prototype,"boundaryPadding",2),p([u({type:Boolean,reflect:!0,attribute:"focus-trap"})],It.prototype,"focusTrap",2),p([u({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],It.prototype,"preventScroll",2),p([u({type:Boolean,reflect:!0,attribute:"show-arrow"})],It.prototype,"showArrow",2),p([u({type:Boolean,reflect:!0,attribute:"close-button"})],It.prototype,"closeButton",2),p([u({type:Boolean,reflect:!0})],It.prototype,"interactive",2),p([u({type:String,reflect:!0})],It.prototype,"delay",2),p([u({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],It.prototype,"hideOnEscape",2),p([u({type:Boolean,reflect:!0,attribute:"propagate-event-on-escape"})],It.prototype,"propagateEventOnEscape",2),p([u({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],It.prototype,"hideOnBlur",2),p([u({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],It.prototype,"hideOnOutsideClick",2),p([u({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],It.prototype,"focusBackToTrigger",2),p([u({type:Boolean,reflect:!0})],It.prototype,"backdrop",2),p([u({type:String,reflect:!0,attribute:"backdrop-append-to"})],It.prototype,"backdropAppendTo",2),p([u({type:Boolean,reflect:!0,attribute:"is-backdrop-invisible"})],It.prototype,"isBackdropInvisible",2),p([u({type:Boolean,reflect:!0})],It.prototype,"flip",2),p([u({type:Boolean,reflect:!0})],It.prototype,"size",2),p([u({type:Number,reflect:!0,attribute:"z-index"})],It.prototype,"zIndex",2),p([u({type:String,reflect:!0,attribute:"append-to"})],It.prototype,"appendTo",2),p([u({type:String,attribute:"close-button-aria-label",reflect:!0})],It.prototype,"closeButtonAriaLabel",2),p([u({type:String,reflect:!0})],It.prototype,"strategy",2),p([u({type:String,reflect:!0})],It.prototype,"role",2),p([u({type:String,reflect:!0,attribute:"aria-labelledby"})],It.prototype,"ariaLabelledby",2),p([u({type:String,reflect:!0,attribute:"aria-describedby"})],It.prototype,"ariaDescribedby",2),p([u({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],It.prototype,"disableAriaExpanded",2),p([u({type:Boolean,reflect:!0,attribute:"keep-connected-tooltip-closed"})],It.prototype,"keepConnectedTooltipClosed",2);var Ve=It;var Pf=z.constructTagName("toggletip"),Io={CLOSE_BUTTON:!0,CLOSE_BUTTON_ARIA_LABEL:"Close",OFFSET:4,PLACEMENT:
|
|
2673
|
+
`}};It.styles=[...q.styles,...Of],p([u({type:String,reflect:!0})],It.prototype,"id",2),p([u({type:String,reflect:!0})],It.prototype,"triggerID",2),p([u({type:String,reflect:!0})],It.prototype,"trigger",2),p([u({type:String,reflect:!0})],It.prototype,"placement",2),p([u({type:String,reflect:!0})],It.prototype,"color",2),p([u({type:Boolean,reflect:!0})],It.prototype,"visible",2),p([u({type:Number,reflect:!0})],It.prototype,"offset",2),p([u({type:String,reflect:!0,attribute:"boundary"})],It.prototype,"boundary",2),p([u({type:String,reflect:!0,attribute:"boundary-root"})],It.prototype,"boundaryRoot",2),p([u({type:Number,reflect:!0,attribute:"boundary-padding"})],It.prototype,"boundaryPadding",2),p([u({type:Boolean,reflect:!0,attribute:"focus-trap"})],It.prototype,"focusTrap",2),p([u({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],It.prototype,"preventScroll",2),p([u({type:Boolean,reflect:!0,attribute:"show-arrow"})],It.prototype,"showArrow",2),p([u({type:Boolean,reflect:!0,attribute:"close-button"})],It.prototype,"closeButton",2),p([u({type:Boolean,reflect:!0})],It.prototype,"interactive",2),p([u({type:String,reflect:!0})],It.prototype,"delay",2),p([u({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],It.prototype,"hideOnEscape",2),p([u({type:Boolean,reflect:!0,attribute:"propagate-event-on-escape"})],It.prototype,"propagateEventOnEscape",2),p([u({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],It.prototype,"hideOnBlur",2),p([u({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],It.prototype,"hideOnOutsideClick",2),p([u({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],It.prototype,"focusBackToTrigger",2),p([u({type:Boolean,reflect:!0})],It.prototype,"backdrop",2),p([u({type:String,reflect:!0,attribute:"backdrop-append-to"})],It.prototype,"backdropAppendTo",2),p([u({type:Boolean,reflect:!0,attribute:"is-backdrop-invisible"})],It.prototype,"isBackdropInvisible",2),p([u({type:Boolean,reflect:!0})],It.prototype,"flip",2),p([u({type:Boolean,reflect:!0})],It.prototype,"size",2),p([u({type:Number,reflect:!0,attribute:"z-index"})],It.prototype,"zIndex",2),p([u({type:String,reflect:!0,attribute:"append-to"})],It.prototype,"appendTo",2),p([u({type:String,attribute:"close-button-aria-label",reflect:!0})],It.prototype,"closeButtonAriaLabel",2),p([u({type:String,reflect:!0})],It.prototype,"strategy",2),p([u({type:String,reflect:!0})],It.prototype,"role",2),p([u({type:String,reflect:!0,attribute:"aria-labelledby"})],It.prototype,"ariaLabelledby",2),p([u({type:String,reflect:!0,attribute:"aria-describedby"})],It.prototype,"ariaDescribedby",2),p([u({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],It.prototype,"disableAriaExpanded",2),p([u({type:Boolean,reflect:!0,attribute:"keep-connected-tooltip-closed"})],It.prototype,"keepConnectedTooltipClosed",2);var Ve=It;var Pf=z.constructTagName("toggletip"),Io={CLOSE_BUTTON:!0,CLOSE_BUTTON_ARIA_LABEL:"Close",OFFSET:4,PLACEMENT:wt.TOP,CLICK:ci.CLICK,SHOW_ARROW:!0};var gT=B`
|
|
2674
2674
|
:host {
|
|
2675
2675
|
--mdc-toggletip-max-width: 400px;
|
|
2676
2676
|
--mdc-toggletip-text-color: var(--mds-color-theme-text-primary-normal);
|
|
@@ -2700,7 +2700,7 @@
|
|
|
2700
2700
|
:host([close-button]:dir(rtl))::part(popover-content) {
|
|
2701
2701
|
margin-left: 2rem;
|
|
2702
2702
|
}
|
|
2703
|
-
`,Df=[gT];var Vi=class extends Ve{constructor(){super(...arguments);this.currentAnnouncement="";this.placement=Io.PLACEMENT}connectedCallback(){var t;super.connectedCallback(),this.closeButton=(t=this.closeButton)!=null?t:Io.CLOSE_BUTTON,this.closeButtonAriaLabel=Io.CLOSE_BUTTON_ARIA_LABEL,this.trigger=Io.CLICK,this.showArrow=Io.SHOW_ARROW,this.interactive=!0,this.backdrop=!0,this.hideOnBlur=!0,this.hideOnEscape=!0,this.hideOnOutsideClick=!0,this.disableAriaExpanded=!1,this.focusBackToTrigger=!0,this.focusTrap=!0}getToggleTipText(){var t,i;return((i=(t=this.defaultSlotNodes)==null?void 0:t.map(a=>a.textContent).join(" "))==null?void 0:i.trim())||""}onPlacementUpdated(){Object.values(
|
|
2703
|
+
`,Df=[gT];var Vi=class extends Ve{constructor(){super(...arguments);this.currentAnnouncement="";this.placement=Io.PLACEMENT}connectedCallback(){var t;super.connectedCallback(),this.closeButton=(t=this.closeButton)!=null?t:Io.CLOSE_BUTTON,this.closeButtonAriaLabel=Io.CLOSE_BUTTON_ARIA_LABEL,this.trigger=Io.CLICK,this.showArrow=Io.SHOW_ARROW,this.interactive=!0,this.backdrop=!0,this.hideOnBlur=!0,this.hideOnEscape=!0,this.hideOnOutsideClick=!0,this.disableAriaExpanded=!1,this.focusBackToTrigger=!0,this.focusTrap=!0}getToggleTipText(){var t,i;return((i=(t=this.defaultSlotNodes)==null?void 0:t.map(a=>a.textContent).join(" "))==null?void 0:i.trim())||""}onPlacementUpdated(){Object.values(wt).includes(this.placement)||(this.placement=Io.PLACEMENT)}update(t){super.update(t),t.has("placement")&&this.onPlacementUpdated(),t.has("visible")&&(this.currentAnnouncement=this.visible?this.getToggleTipText():"")}render(){return _`
|
|
2704
2704
|
${super.render()}
|
|
2705
2705
|
<mdc-screenreaderannouncer
|
|
2706
2706
|
identity="${it(this.screenreaderAnnouncerIdentity)}"
|
|
@@ -3976,7 +3976,7 @@
|
|
|
3976
3976
|
var(--mdc-marker-striped-background-color) 0.375rem
|
|
3977
3977
|
);
|
|
3978
3978
|
}
|
|
3979
|
-
`,fv=[JT];var vv=z.constructTagName("marker"),gv={SOLID:"solid",STRIPED:"striped"};var Ga=class extends q{constructor(){super(...arguments);this.variant=gv.SOLID}};Ga.styles=[...q.styles,...fv],p([u({type:String,reflect:!0})],Ga.prototype,"variant",2);var oh=Ga;oh.register(vv);var tx=oh;var te=z.constructTagName("menupopover"),sh={PLACEMENT:
|
|
3979
|
+
`,fv=[JT];var vv=z.constructTagName("marker"),gv={SOLID:"solid",STRIPED:"striped"};var Ga=class extends q{constructor(){super(...arguments);this.variant=gv.SOLID}};Ga.styles=[...q.styles,...fv],p([u({type:String,reflect:!0})],Ga.prototype,"variant",2);var oh=Ga;oh.register(vv);var tx=oh;var te=z.constructTagName("menupopover"),sh={PLACEMENT:wt.BOTTOM_START,ORIENTATION:"vertical"};var ui=z.constructTagName("menusection"),bv={DIVIDER_VARIANT:"solid"};var Gi=z.constructTagName("sidenavigation"),Ur={FIXED_EXPANDED:"fixed-expanded",FIXED_COLLAPSED:"fixed-collapsed",FLEXIBLE:"flexible",HIDDEN:"hidden"},Xl={VARIANT:Ur.FLEXIBLE};var Ya=z.constructTagName("menubar"),yv={ORIENTATION:"vertical"};var ex=B`
|
|
3980
3980
|
:host {
|
|
3981
3981
|
display: flex;
|
|
3982
3982
|
}
|
|
@@ -3988,7 +3988,7 @@
|
|
|
3988
3988
|
:host([aria-orientation='vertical']) {
|
|
3989
3989
|
flex-direction: column;
|
|
3990
3990
|
}
|
|
3991
|
-
`,Ev=[ex];var Wa=class extends q{constructor(){super(),this.addEventListener("click",this.handleClick.bind(this)),this.addEventListener("keydown",this.handleKeyDown.bind(this))}async connectedCallback(){var o;super.connectedCallback(),this.role=tt.MENUBAR,this.ariaOrientation=yv.ORIENTATION,await this.updateComplete,(o=this.menusections)==null||o.forEach(t=>{t.setAttribute("divider-variant","gradient")})}get menuItems(){var d,m;let o=(d=this.shadowRoot)==null?void 0:d.querySelector("slot"),t=(m=o==null?void 0:o.assignedElements({flatten:!0}))!=null?m:[],i=[],a=b=>{b.role===tt.MENUITEM&&!b.hasAttribute("disabled")?i.push(b):b.tagName.toLowerCase()===ui&&Array.from(b.children).forEach(a)};return t.forEach(a),i}getVisibleSubMenusOfItems(o){let t=[];return!o||o.length===0||o.forEach(i=>{var m;let a=i.getAttribute("id");if(!a)return;let d=(m=document.querySelector)==null?void 0:m.call(document,`${te}[triggerid="${a}"]`);d&&d.visible&&t.push(d)}),t}getAllPopovers(){var a,d;if(!this.menuItems.length)return[];let o=(d=(a=this.menuItems[0])==null?void 0:a.closest(Gi))!=null?d:this;if(!o)return[];let t=[],i=m=>{m.querySelectorAll(`${te}`).forEach(b=>{t.push(b)}),m.querySelectorAll("slot").forEach(b=>{b.assignedElements({flatten:!0}).forEach(i)})};return i(o),t}update(o){super.update(o)}firstUpdated(o){super.firstUpdated(o),this.resetTabIndexAndSetActiveTabIndex(this.menuItems),this.updatePopoverPlacement()}handleClick(o){let t=o.target;if(!t||!this.isTopLevelMenuItem(t))return;let i=this.menuItems.filter(d=>d!==t);this.getVisibleSubMenusOfItems(i).forEach(d=>{d.hide()})}resetTabIndexAndSetActiveTabIndex(o){o.forEach((t,i)=>{let a=i===0?"0":"-1";t==null||t.setAttribute("tabindex",a)})}getCurrentIndex(o){return this.menuItems.findIndex(t=>t===o||t===o.parentElement)}getSubmenu(o){if(o)return this.getAllPopovers().find(t=>t.getAttribute("triggerid")===o)}showSubmenu(o){if(!o||!this.menuItems.find(a=>a.getAttribute("id")===o))return;let i=this.getSubmenu(o);i&&i.show()}updatePopoverPlacement(){let o=
|
|
3991
|
+
`,Ev=[ex];var Wa=class extends q{constructor(){super(),this.addEventListener("click",this.handleClick.bind(this)),this.addEventListener("keydown",this.handleKeyDown.bind(this))}async connectedCallback(){var o;super.connectedCallback(),this.role=tt.MENUBAR,this.ariaOrientation=yv.ORIENTATION,await this.updateComplete,(o=this.menusections)==null||o.forEach(t=>{t.setAttribute("divider-variant","gradient")})}get menuItems(){var d,m;let o=(d=this.shadowRoot)==null?void 0:d.querySelector("slot"),t=(m=o==null?void 0:o.assignedElements({flatten:!0}))!=null?m:[],i=[],a=b=>{b.role===tt.MENUITEM&&!b.hasAttribute("disabled")?i.push(b):b.tagName.toLowerCase()===ui&&Array.from(b.children).forEach(a)};return t.forEach(a),i}getVisibleSubMenusOfItems(o){let t=[];return!o||o.length===0||o.forEach(i=>{var m;let a=i.getAttribute("id");if(!a)return;let d=(m=document.querySelector)==null?void 0:m.call(document,`${te}[triggerid="${a}"]`);d&&d.visible&&t.push(d)}),t}getAllPopovers(){var a,d;if(!this.menuItems.length)return[];let o=(d=(a=this.menuItems[0])==null?void 0:a.closest(Gi))!=null?d:this;if(!o)return[];let t=[],i=m=>{m.querySelectorAll(`${te}`).forEach(b=>{t.push(b)}),m.querySelectorAll("slot").forEach(b=>{b.assignedElements({flatten:!0}).forEach(i)})};return i(o),t}update(o){super.update(o)}firstUpdated(o){super.firstUpdated(o),this.resetTabIndexAndSetActiveTabIndex(this.menuItems),this.updatePopoverPlacement()}handleClick(o){let t=o.target;if(!t||!this.isTopLevelMenuItem(t))return;let i=this.menuItems.filter(d=>d!==t);this.getVisibleSubMenusOfItems(i).forEach(d=>{d.hide()})}resetTabIndexAndSetActiveTabIndex(o){o.forEach((t,i)=>{let a=i===0?"0":"-1";t==null||t.setAttribute("tabindex",a)})}getCurrentIndex(o){return this.menuItems.findIndex(t=>t===o||t===o.parentElement)}getSubmenu(o){if(o)return this.getAllPopovers().find(t=>t.getAttribute("triggerid")===o)}showSubmenu(o){if(!o||!this.menuItems.find(a=>a.getAttribute("id")===o))return;let i=this.getSubmenu(o);i&&i.show()}updatePopoverPlacement(){let o=wt.RIGHT_START;this.getAllPopovers().forEach(t=>{t.setAttribute("placement",o)})}updateTabIndexAndFocus(o,t,i){var a,d,m;i<0||t<0||(t!==i&&((a=o[t])==null||a.setAttribute("tabindex","-1"),(d=o[i])==null||d.setAttribute("tabindex","0")),(m=o[i])==null||m.focus())}navigateToMenuItem(o,t,i=!1){var m;let{length:a}=this.menuItems;if(a===0)return;let d=o;if(d=t==="prev"?(o-1+a)%a:(o+1)%a,this.updateTabIndexAndFocus(this.menuItems,o,d),i){let b=(m=this.menuItems[d])==null?void 0:m.getAttribute("id");this.getSubmenu(b)&&!this.menuItems[d].hasAttribute("soft-disabled")&&this.showSubmenu(b)}}getKeyWithDirectionFix(o){return window.getComputedStyle(this).direction==="rtl"?o===Z.ARROW_LEFT?Z.ARROW_RIGHT:o===Z.ARROW_RIGHT?Z.ARROW_LEFT:o:o}isTopLevelMenuItem(o){var d;let t=o.parentElement;if(!t||o.role!==tt.MENUITEM)return!1;let i=t.tagName.toLowerCase(),a=(d=t.parentElement)==null?void 0:d.tagName.toLowerCase();return i===Ya||i===Gi||i===ui&&(a===Ya||a===Gi)}isNestedMenuItem(o){return!!o.closest(te)&&o.role===tt.MENUITEM}async closeAllMenuPopovers(){let o=[];for(;Ie.peek();){let t=Ie.pop();t&&(t.hide(),o.push(t))}await Promise.all(o.map(t=>t.updateComplete))}async crossMenubarNavigationOnLeft(o){if(o.role===tt.MENUITEM){let i=o.closest(te),a=i==null?void 0:i.getAttribute("triggerid"),d=this.menuItems.find(m=>m.getAttribute("id")===a);if(d){this.isTopLevelMenuItem(d)&&(i==null||i.hide()),await(i==null?void 0:i.updateComplete);let m=this.getCurrentIndex(d);this.navigateToMenuItem(m,"prev",!0)}}}async crossMenubarNavigationOnRight(o){if(this.isTopLevelMenuItem(o)&&this.getSubmenu(o.id)&&!o.hasAttribute("soft-disabled"))this.showSubmenu(o.id);else if(this.isNestedMenuItem(o)&&!this.getSubmenu(o.id)){await this.closeAllMenuPopovers();let t=this.getParentMenuItemIndex(o);t>=0&&this.navigateToMenuItem(t,"next",!0)}}getParentMenuItemIndex(o){let t=o.parentElement;for(;t;){if(t.tagName.toLowerCase()===te){let i=t.getAttribute("triggerid"),a=this.menuItems.find(d=>d.getAttribute("id")===i);if(a)return this.isTopLevelMenuItem(a)?this.menuItems.findIndex(d=>d===a):this.getParentMenuItemIndex(a)}t=t.parentElement}return-1}async handleKeyDown(o){let t=this.getCurrentIndex(o.target);switch(this.getKeyWithDirectionFix(o.key)){case Z.HOME:this.updateTabIndexAndFocus(this.menuItems,t,0);break;case Z.END:this.updateTabIndexAndFocus(this.menuItems,t,this.menuItems.length-1);break;case Z.ARROW_LEFT:{let a=t>=0?this.menuItems[t]:o.target;await this.crossMenubarNavigationOnLeft(a);break}case Z.ARROW_RIGHT:{let a=t>=0?this.menuItems[t]:o.target;await this.crossMenubarNavigationOnRight(a);break}case Z.ARROW_UP:{this.navigateToMenuItem(t,"prev"),o.preventDefault();break}case Z.ARROW_DOWN:{this.navigateToMenuItem(t,"next"),o.preventDefault();break}default:break}}render(){return _`<slot role="${tt.GROUP}"></slot>`}};Wa.styles=[...q.styles,...Ev],p([Pt({selector:"mdc-menusection",flatten:!0})],Wa.prototype,"menusections",2);var ah=Wa;ah.register(Ya);var rx=ah;var ja=z.constructTagName("menuitem"),qa={LEFT:"arrow-left-bold",RIGHT:"arrow-right-bold"},nh={POSITIVE:"positive",NEGATIVE:"negative"},lh={LEADING:"leading",TRAILING:"trailing"};var ix=B`
|
|
3992
3992
|
:host(:dir(rtl))::part(trailing-arrow),
|
|
3993
3993
|
:host(:dir(rtl))::part(leading-arrow) {
|
|
3994
3994
|
transform: rotate(180deg);
|
|
@@ -4117,7 +4117,7 @@
|
|
|
4117
4117
|
size="${Av[this.size]}"
|
|
4118
4118
|
></mdc-icon>
|
|
4119
4119
|
</div>
|
|
4120
|
-
`}};Wi.styles=[...q.styles,..._v],p([u({type:Boolean,reflect:!0})],Wi.prototype,"checked",2),p([u({type:String,reflect:!0})],Wi.prototype,"size",2),p([u({type:Boolean,reflect:!0})],Wi.prototype,"readonly",2),p([u({type:Boolean,attribute:"soft-disabled",reflect:!0})],Wi.prototype,"softDisabled",2);var ch=Wi;ch.register(xv);var nx=ch;var Ka=z.constructTagName("tooltip"),je={DESCRIPTION:"description",LABEL:"label",NONE:"none"},ji={BACKDROP:!1,DELAY:"0,0",OFFSET:4,PLACEMENT:
|
|
4120
|
+
`}};Wi.styles=[...q.styles,..._v],p([u({type:Boolean,reflect:!0})],Wi.prototype,"checked",2),p([u({type:String,reflect:!0})],Wi.prototype,"size",2),p([u({type:Boolean,reflect:!0})],Wi.prototype,"readonly",2),p([u({type:Boolean,attribute:"soft-disabled",reflect:!0})],Wi.prototype,"softDisabled",2);var ch=Wi;ch.register(xv);var nx=ch;var Ka=z.constructTagName("tooltip"),je={DESCRIPTION:"description",LABEL:"label",NONE:"none"},ji={BACKDROP:!1,DELAY:"0,0",OFFSET:4,PLACEMENT:wt.TOP,SHOW_ARROW:!0,TOOLTIP_TYPE:je.DESCRIPTION};var lx=B`
|
|
4121
4121
|
:host {
|
|
4122
4122
|
--mdc-tooltip-max-width: 400px;
|
|
4123
4123
|
--mdc-tooltip-padding: 0.75rem;
|
|
@@ -4141,7 +4141,7 @@
|
|
|
4141
4141
|
:host([color='contrast'])::part(popover-content) {
|
|
4142
4142
|
color: var(--mdc-tooltip-text-color-contrast);
|
|
4143
4143
|
}
|
|
4144
|
-
`,Iv=[lx];var Ls=class extends Ve{constructor(){super(...arguments);this.tooltipType=ji.TOOLTIP_TYPE}connectedCallback(){super.connectedCallback(),this.backdrop=!1,this.delay=this.delay||ji.DELAY,this.focusTrap=!1,this.hideOnBlur=!0,this.hideOnEscape=!0,this.interactive=!1,this.offset=this.offset||ji.OFFSET,this.placement=this.placement||ji.PLACEMENT,this.role=tt.TOOLTIP,this.trigger="mouseenter focusin",this.preventScroll=!1,this.flip=!0,this.preventScroll=!1,this.closeButton=!1,this.hideOnOutsideClick=!1,this.focusBackToTrigger=!1,this.size=!1,this.disableAriaExpanded=!0}getTooltipText(){var t,i;return((i=(t=this.defaultSlotNodes)==null?void 0:t.map(a=>a.textContent).join(" "))==null?void 0:i.trim())||""}setTooltipType(t){this.setAttribute("tooltip-type",Object.values(je).includes(t)?t:ji.TOOLTIP_TYPE)}async onIdUpdated(){if(this.id.length===0&&(this.id=`mdc-tooltip-${Ee()}`),await this.updateComplete,this.triggerElement)switch(this.tooltipType){case je.DESCRIPTION:this.triggerElement.setAttribute("aria-describedby",this.id);break;case je.LABEL:this.triggerElement.setAttribute("aria-labelledby",this.id);break;default:break}}onPlacementUpdated(){Object.values(
|
|
4144
|
+
`,Iv=[lx];var Ls=class extends Ve{constructor(){super(...arguments);this.tooltipType=ji.TOOLTIP_TYPE}connectedCallback(){super.connectedCallback(),this.backdrop=!1,this.delay=this.delay||ji.DELAY,this.focusTrap=!1,this.hideOnBlur=!0,this.hideOnEscape=!0,this.interactive=!1,this.offset=this.offset||ji.OFFSET,this.placement=this.placement||ji.PLACEMENT,this.role=tt.TOOLTIP,this.trigger="mouseenter focusin",this.preventScroll=!1,this.flip=!0,this.preventScroll=!1,this.closeButton=!1,this.hideOnOutsideClick=!1,this.focusBackToTrigger=!1,this.size=!1,this.disableAriaExpanded=!0}getTooltipText(){var t,i;return((i=(t=this.defaultSlotNodes)==null?void 0:t.map(a=>a.textContent).join(" "))==null?void 0:i.trim())||""}setTooltipType(t){this.setAttribute("tooltip-type",Object.values(je).includes(t)?t:ji.TOOLTIP_TYPE)}async onIdUpdated(){if(this.id.length===0&&(this.id=`mdc-tooltip-${Ee()}`),await this.updateComplete,this.triggerElement)switch(this.tooltipType){case je.DESCRIPTION:this.triggerElement.setAttribute("aria-describedby",this.id);break;case je.LABEL:this.triggerElement.setAttribute("aria-labelledby",this.id);break;default:break}}onPlacementUpdated(){Object.values(wt).includes(this.placement)||(this.placement=ji.PLACEMENT)}onTooltipTypeUpdated(t){let i=t.get("tooltipType");if(Object.values(je).includes(this.tooltipType)||this.setTooltipType(ji.TOOLTIP_TYPE),this.triggerElement){let a=this.getTooltipText();switch(this.tooltipType){case je.DESCRIPTION:i===je.LABEL&&this.triggerElement.removeAttribute("aria-labelledby"),this.triggerElement.setAttribute("aria-describedby",this.id);break;case je.LABEL:i===je.DESCRIPTION&&this.triggerElement.removeAttribute("aria-describedby"),this.triggerElement.setAttribute("aria-labelledby",this.id);break;default:i===je.DESCRIPTION?this.triggerElement.removeAttribute("aria-describedby"):i===je.LABEL&&this.triggerElement.removeAttribute("aria-labelledby");break}a.length>0&&this.tooltipType!==je.NONE&&!this.ariaLabel&&(this.ariaLabel=a)}}async update(t){super.update(t),t.has("id")&&await this.onIdUpdated(),t.has("placement")&&this.onPlacementUpdated(),t.has("tooltipType")&&this.onTooltipTypeUpdated(t)}};Ls.styles=[...Ve.styles,...Iv],p([u({type:String,attribute:"tooltip-type",reflect:!0})],Ls.prototype,"tooltipType",2),p([Un()],Ls.prototype,"defaultSlotNodes",2);var hh=Ls;hh.register(Ka);var dx=hh;var Rs=oi(class extends Pr{constructor(n){var o;if(super(n),n.type!==Ye.ATTRIBUTE||n.name!=="class"||((o=n.strings)==null?void 0:o.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(n){return" "+Object.keys(n).filter(o=>n[o]).join(" ")+" "}update(n,[o]){var i,a;if(this.st===void 0){this.st=new Set,n.strings!==void 0&&(this.nt=new Set(n.strings.join(" ").split(/\s/).filter(d=>d!=="")));for(let d in o)o[d]&&!((i=this.nt)!=null&&i.has(d))&&this.st.add(d);return this.render(o)}let t=n.element.classList;for(let d of this.st)d in o||(t.remove(d),this.st.delete(d));for(let d in o){let m=!!o[d];m===this.st.has(d)||(a=this.nt)!=null&&a.has(d)||(m?(t.add(d),this.st.add(d)):(t.remove(d),this.st.delete(d)))}return ge}});var Cv=z.constructTagName("toggle"),Xa={DEFAULT:"default",COMPACT:"compact"};var ph={SIZE:Xa.DEFAULT,VALIDATION_MESSAGE:"Please toggle this switch if you want to proceed."};var Zl=n=>{class o extends n{constructor(){super(...arguments);this.controlTypeProviderContext=De.consume({host:this,context:Wc.Context})}willUpdate(){this.controlType&&Ul.includes(this.controlType)||(this.controlTypeProviderContext.value?this.controlType=this.controlTypeProviderContext.value:this.controlType=Bl.CONTROL_TYPE)}}return p([u({type:String,attribute:"control-type",reflect:!0})],o.prototype,"controlType",2),o};var Ql=z.constructTagName("menuitemcheckbox"),Za={NONE:"none",CHECKBOX:"checkbox",CHECKMARK:"checkmark",TOGGLE:"toggle"},kv={INDICATOR:Za.CHECKBOX};var cx=B`
|
|
4145
4145
|
:host::part(checkmark-icon) {
|
|
4146
4146
|
--mdc-icon-fill-color: currentColor;
|
|
4147
4147
|
}
|
|
@@ -4239,7 +4239,7 @@
|
|
|
4239
4239
|
::slotted(mdc-divider) {
|
|
4240
4240
|
margin-block: 0.25rem;
|
|
4241
4241
|
}
|
|
4242
|
-
`,Pv=[ux];var Qa=n=>{var t;if(!n)return!1;let o=(t=n.getAttribute("role"))==null?void 0:t.toLowerCase();return o===tt.MENUITEM||o===tt.MENUITEMCHECKBOX||o===tt.MENUITEMRADIO},fh=n=>{var o;return((o=n==null?void 0:n.tagName)==null?void 0:o.toLowerCase())===te};var Ja=class extends Ve{constructor(){super();this.placement=sh.PLACEMENT;this.menuItems=[];this.menuItemsWithSubMenus=[];this.onOutsidePopoverClick=t=>{if(Ie.peek()!==this)return;let i=t.composedPath(),a=this.contains(t.target)||i.includes(this.triggerElement)||i.includes(this),d=this.backdropElement?i.includes(this.backdropElement):!1;(!a||d)&&this.closeAllMenuPopovers()};this.togglePopoverVisible=t=>{var i;(i=this.triggerElement)!=null&&i.hasAttribute("soft-disabled")||!this.isEventFromTrigger(t)||(this.visible?this.hide():this.show())};this.handleItemCreation=t=>{let i=t.target;Qa(i)&&(t.stopImmediatePropagation(),i.addEventListener("destroyed",this.handleItemChangeEvent),i.addEventListener("disabled",this.handleItemChangeEvent))};this.handleItemChangeEvent=t=>{t.stopImmediatePropagation(),t.target&&t.type==="destroyed"&&(t.target.removeEventListener("destroyed",this.handleItemChangeEvent),t.target.removeEventListener("disabled",this.handleItemChangeEvent)),this.resetMenuNavigation()};this.resetMenuNavigation=()=>{this.collectMenuItems(),this.menuItems.find(i=>i.getAttribute("tabindex")==="0")||this.resetTabIndexes(0)};this.handleKeyDown=t=>{let i=!1;this.collectMenuItems();let a=t.target,d=this.getCurrentIndex(a);if(d===-1)return;this.resetTabIndexes(d);let m=window.getComputedStyle(this).direction==="rtl";switch(this.resolveDirectionKey(t.key,m)){case Z.HOME:{this.resetTabIndexAndSetFocus(0,d),i=!0;break}case Z.END:{this.resetTabIndexAndSetFocus(this.menuItems.length-1,d),i=!0;break}case Z.ARROW_DOWN:{let C=d+1===this.menuItems.length?0:d+1;this.resetTabIndexAndSetFocus(C,d),i=!0;break}case Z.ARROW_UP:{let C=d-1===-1?this.menuItems.length-1:d-1;this.resetTabIndexAndSetFocus(C,d),i=!0;break}case Z.ARROW_RIGHT:{let C=this.getSubMenuPopoverOfTarget(a);C&&(C.show(),i=!0);break}case Z.ARROW_LEFT:{fh(this.parentElement)&&(this.hide(),this.resetTabIndexAndSetFocus(0,d),i=!0);break}case Z.ESCAPE:{this.resetTabIndexAndSetFocus(0,d),i=!0;break}case Z.ENTER:{this.getSubMenuPopoverOfTarget(a)||(this.closeAllMenuPopovers(),this.fireMenuItemAction(a),i=!0);break}case Z.SPACE:{i=!0;break}default:break}i&&(t.stopPropagation(),t.preventDefault())};this.handleKeyUp=t=>{let i=!1,a=t.target;switch(t.key){case Z.SPACE:{a.matches(`${Jl}, ${Ql}`)||this.getSubMenuPopoverOfTarget(a)||(this.closeAllMenuPopovers(),this.fireMenuItemAction(a),i=!0);break}default:break}i&&(t.stopPropagation(),t.preventDefault())};this.addEventListener("keydown",this.handleKeyDown),this.addEventListener("keyup",this.handleKeyUp),this.addEventListener("click",this.handleMouseClick),this.addEventListener("created",this.handleItemCreation)}getSubMenuPopoverOfTarget(t){var a,d;let i=t.getAttribute("id");return i?(d=(a=this.parentElement)==null?void 0:a.querySelector)==null?void 0:d.call(a,`${te}[triggerid="${i}"]`):null}collectMenuItems(){var a;let t=(a=this.shadowRoot)==null?void 0:a.querySelector("slot"),i=(t==null?void 0:t.assignedElements({flatten:!0}))||[];this.menuItems=i.map(d=>d.tagName.toLowerCase()===ui?Array.from(d.children).filter(m=>Qa(m)):Qa(d)?d:[]).flat().filter(d=>!!d&&!d.hasAttribute("disabled")),this.menuItemsWithSubMenus=this.menuItems.filter(d=>this.getSubMenuPopoverOfTarget(d))}getOpenSubMenusOfItems(t){let i=[];return!t||t.length===0||t.forEach(a=>{let d=this.getSubMenuPopoverOfTarget(a);d&&d.visible&&i.push(d)}),i}connectedCallback(){super.connectedCallback(),this.role=tt.MENU,this.ariaOrientation=sh.ORIENTATION,this.backdrop=!1,this.color=_o.TONAL,this.disableAriaExpanded=!1,this.focusBackToTrigger=!0,this.focusTrap=!0,this.hideOnEscape=!0,this.hideOnOutsideClick=!0,this.interactive=!0,this.showArrow=!1,this.closeButton=!1,this.closeButtonAriaLabel=null}async isOpenUpdated(t,i){return t===i||!this.triggerElement?Promise.resolve():(i&&(this.backdrop=![ja,qi].includes(this.triggerElement.tagName.toLowerCase())),i===!1&&this.menuItemsWithSubMenus.forEach(a=>{let d=this.getSubMenuPopoverOfTarget(a);d&&d.hide()}),this.resetMenuNavigation(),super.isOpenUpdated(t,i))}async firstUpdated(t){await super.firstUpdated(t),this.collectMenuItems(),this.resetTabIndexes(0)}resetTabIndexes(t){this.menuItems.length>0&&(this.menuItems.forEach(i=>i.setAttribute("tabindex","-1")),this.menuItems[t].setAttribute("tabindex","0"),this.menuItems[t].focus())}getCurrentIndex(t){return this.menuItems.findIndex(i=>i===t)}resetTabIndexAndSetFocus(t,i){t!==i&&(this.menuItems[i].setAttribute("tabindex","-1"),this.menuItems[t].setAttribute("tabindex","0"),this.menuItems[t].focus())}closeAllMenuPopovers(t){for(;Ie.peek()!==t&&fh(Ie.peek());){let i=Ie.pop();if(i)i.hide();else break}}closeOtherSubMenusOnSameLevel(t){let i=this.menuItemsWithSubMenus.filter(d=>d!==t);this.getOpenSubMenusOfItems(i).forEach(d=>{d.hide()})}fireMenuItemAction(t){t.matches(ja)&&t.dispatchEvent(new Event("action",{bubbles:!0,composed:!0}))}handleMouseClick(t){let i=t.target;if(t.stopPropagation(),!(!Qa(i)||!t.isTrusted)){if(this.getSubMenuPopoverOfTarget(i)){this.closeOtherSubMenusOnSameLevel(i);return}this.closeAllMenuPopovers(),this.fireMenuItemAction(i)}}resolveDirectionKey(t,i){if(!i)return t;switch(t){case Z.ARROW_LEFT:return Z.ARROW_RIGHT;case Z.ARROW_RIGHT:return Z.ARROW_LEFT;default:return t}}};Ja.styles=[...Ve.styles,...Pv],p([u({type:String,reflect:!0})],Ja.prototype,"placement",2);var vh=Ja;vh.register(te);var fx=vh;var ed=class{constructor(o,t,i){this.variant=o,this.expanded=t,this.parentNavTooltipText=i}hasSiblingWithTriggerId(o){var a,d;let t=o==null?void 0:o.getAttribute("id");return t?Array.from((d=(a=o==null?void 0:o.parentElement)==null?void 0:a.children)!=null?d:[]).some(m=>m!==o&&m.tagName.toLowerCase()===te&&m.getAttribute("triggerid")===t):!1}getParentNavMenuItems(o){if(!o)return[];let t=[],i=o;for(;i;){let a=i==null?void 0:i.closest(te);if(!a)break;let d=a.getAttribute("triggerid");if(!d)break;let m=document.getElementById(d);if(m&&m.tagName.toLowerCase()===qi)t.push(m),i=m;else break}return t}setCurrentActiveNavMenuItem(o){var d;let t=((d=this.currentActiveNavMenuItem)==null?void 0:d.navId)===(o==null?void 0:o.navId),i=(o==null?void 0:o.disableAriaCurrent)||this.hasSiblingWithTriggerId(o)||(o==null?void 0:o.softDisabled);if(t||i||(this.currentActiveNavMenuItem&&(this.currentActiveNavMenuItem.removeAttribute("aria-current"),this.currentActiveNavMenuItem.removeAttribute("active"),this.getParentNavMenuItems(this.currentActiveNavMenuItem).forEach(b=>{b.removeAttribute("tooltip-text"),b.removeAttribute("tooltip-placement"),b.removeAttribute("active")})),!o))return;this.currentActiveNavMenuItem=o,o.setAttribute("aria-current","page"),o.setAttribute("active",""),this.getParentNavMenuItems(o).forEach(m=>{m.setAttribute("tooltip-text",this.parentNavTooltipText||""),m.setAttribute("tooltip-placement",
|
|
4242
|
+
`,Pv=[ux];var Qa=n=>{var t;if(!n)return!1;let o=(t=n.getAttribute("role"))==null?void 0:t.toLowerCase();return o===tt.MENUITEM||o===tt.MENUITEMCHECKBOX||o===tt.MENUITEMRADIO},fh=n=>{var o;return((o=n==null?void 0:n.tagName)==null?void 0:o.toLowerCase())===te};var Ja=class extends Ve{constructor(){super();this.placement=sh.PLACEMENT;this.menuItems=[];this.menuItemsWithSubMenus=[];this.onOutsidePopoverClick=t=>{if(Ie.peek()!==this)return;let i=t.composedPath(),a=this.contains(t.target)||i.includes(this.triggerElement)||i.includes(this),d=this.backdropElement?i.includes(this.backdropElement):!1;(!a||d)&&this.closeAllMenuPopovers()};this.togglePopoverVisible=t=>{var i;(i=this.triggerElement)!=null&&i.hasAttribute("soft-disabled")||!this.isEventFromTrigger(t)||(this.visible?this.hide():this.show())};this.handleItemCreation=t=>{let i=t.target;Qa(i)&&(t.stopImmediatePropagation(),i.addEventListener("destroyed",this.handleItemChangeEvent),i.addEventListener("disabled",this.handleItemChangeEvent))};this.handleItemChangeEvent=t=>{t.stopImmediatePropagation(),t.target&&t.type==="destroyed"&&(t.target.removeEventListener("destroyed",this.handleItemChangeEvent),t.target.removeEventListener("disabled",this.handleItemChangeEvent)),this.resetMenuNavigation()};this.resetMenuNavigation=()=>{this.collectMenuItems(),this.menuItems.find(i=>i.getAttribute("tabindex")==="0")||this.resetTabIndexes(0)};this.handleKeyDown=t=>{let i=!1;this.collectMenuItems();let a=t.target,d=this.getCurrentIndex(a);if(d===-1)return;this.resetTabIndexes(d);let m=window.getComputedStyle(this).direction==="rtl";switch(this.resolveDirectionKey(t.key,m)){case Z.HOME:{this.resetTabIndexAndSetFocus(0,d),i=!0;break}case Z.END:{this.resetTabIndexAndSetFocus(this.menuItems.length-1,d),i=!0;break}case Z.ARROW_DOWN:{let C=d+1===this.menuItems.length?0:d+1;this.resetTabIndexAndSetFocus(C,d),i=!0;break}case Z.ARROW_UP:{let C=d-1===-1?this.menuItems.length-1:d-1;this.resetTabIndexAndSetFocus(C,d),i=!0;break}case Z.ARROW_RIGHT:{let C=this.getSubMenuPopoverOfTarget(a);C&&(C.show(),i=!0);break}case Z.ARROW_LEFT:{fh(this.parentElement)&&(this.hide(),this.resetTabIndexAndSetFocus(0,d),i=!0);break}case Z.ESCAPE:{this.resetTabIndexAndSetFocus(0,d),i=!0;break}case Z.ENTER:{this.getSubMenuPopoverOfTarget(a)||(this.closeAllMenuPopovers(),this.fireMenuItemAction(a),i=!0);break}case Z.SPACE:{i=!0;break}default:break}i&&(t.stopPropagation(),t.preventDefault())};this.handleKeyUp=t=>{let i=!1,a=t.target;switch(t.key){case Z.SPACE:{a.matches(`${Jl}, ${Ql}`)||this.getSubMenuPopoverOfTarget(a)||(this.closeAllMenuPopovers(),this.fireMenuItemAction(a),i=!0);break}default:break}i&&(t.stopPropagation(),t.preventDefault())};this.addEventListener("keydown",this.handleKeyDown),this.addEventListener("keyup",this.handleKeyUp),this.addEventListener("click",this.handleMouseClick),this.addEventListener("created",this.handleItemCreation)}getSubMenuPopoverOfTarget(t){var a,d;let i=t.getAttribute("id");return i?(d=(a=this.parentElement)==null?void 0:a.querySelector)==null?void 0:d.call(a,`${te}[triggerid="${i}"]`):null}collectMenuItems(){var a;let t=(a=this.shadowRoot)==null?void 0:a.querySelector("slot"),i=(t==null?void 0:t.assignedElements({flatten:!0}))||[];this.menuItems=i.map(d=>d.tagName.toLowerCase()===ui?Array.from(d.children).filter(m=>Qa(m)):Qa(d)?d:[]).flat().filter(d=>!!d&&!d.hasAttribute("disabled")),this.menuItemsWithSubMenus=this.menuItems.filter(d=>this.getSubMenuPopoverOfTarget(d))}getOpenSubMenusOfItems(t){let i=[];return!t||t.length===0||t.forEach(a=>{let d=this.getSubMenuPopoverOfTarget(a);d&&d.visible&&i.push(d)}),i}connectedCallback(){super.connectedCallback(),this.role=tt.MENU,this.ariaOrientation=sh.ORIENTATION,this.backdrop=!1,this.color=_o.TONAL,this.disableAriaExpanded=!1,this.focusBackToTrigger=!0,this.focusTrap=!0,this.hideOnEscape=!0,this.hideOnOutsideClick=!0,this.interactive=!0,this.showArrow=!1,this.closeButton=!1,this.closeButtonAriaLabel=null}async isOpenUpdated(t,i){return t===i||!this.triggerElement?Promise.resolve():(i&&(this.backdrop=![ja,qi].includes(this.triggerElement.tagName.toLowerCase())),i===!1&&this.menuItemsWithSubMenus.forEach(a=>{let d=this.getSubMenuPopoverOfTarget(a);d&&d.hide()}),this.resetMenuNavigation(),super.isOpenUpdated(t,i))}async firstUpdated(t){await super.firstUpdated(t),this.collectMenuItems(),this.resetTabIndexes(0)}resetTabIndexes(t){this.menuItems.length>0&&(this.menuItems.forEach(i=>i.setAttribute("tabindex","-1")),this.menuItems[t].setAttribute("tabindex","0"),this.menuItems[t].focus())}getCurrentIndex(t){return this.menuItems.findIndex(i=>i===t)}resetTabIndexAndSetFocus(t,i){t!==i&&(this.menuItems[i].setAttribute("tabindex","-1"),this.menuItems[t].setAttribute("tabindex","0"),this.menuItems[t].focus())}closeAllMenuPopovers(t){for(;Ie.peek()!==t&&fh(Ie.peek());){let i=Ie.pop();if(i)i.hide();else break}}closeOtherSubMenusOnSameLevel(t){let i=this.menuItemsWithSubMenus.filter(d=>d!==t);this.getOpenSubMenusOfItems(i).forEach(d=>{d.hide()})}fireMenuItemAction(t){t.matches(ja)&&t.dispatchEvent(new Event("action",{bubbles:!0,composed:!0}))}handleMouseClick(t){let i=t.target;if(t.stopPropagation(),!(!Qa(i)||!t.isTrusted)){if(this.getSubMenuPopoverOfTarget(i)){this.closeOtherSubMenusOnSameLevel(i);return}this.closeAllMenuPopovers(),this.fireMenuItemAction(i)}}resolveDirectionKey(t,i){if(!i)return t;switch(t){case Z.ARROW_LEFT:return Z.ARROW_RIGHT;case Z.ARROW_RIGHT:return Z.ARROW_LEFT;default:return t}}};Ja.styles=[...Ve.styles,...Pv],p([u({type:String,reflect:!0})],Ja.prototype,"placement",2);var vh=Ja;vh.register(te);var fx=vh;var ed=class{constructor(o,t,i){this.variant=o,this.expanded=t,this.parentNavTooltipText=i}hasSiblingWithTriggerId(o){var a,d;let t=o==null?void 0:o.getAttribute("id");return t?Array.from((d=(a=o==null?void 0:o.parentElement)==null?void 0:a.children)!=null?d:[]).some(m=>m!==o&&m.tagName.toLowerCase()===te&&m.getAttribute("triggerid")===t):!1}getParentNavMenuItems(o){if(!o)return[];let t=[],i=o;for(;i;){let a=i==null?void 0:i.closest(te);if(!a)break;let d=a.getAttribute("triggerid");if(!d)break;let m=document.getElementById(d);if(m&&m.tagName.toLowerCase()===qi)t.push(m),i=m;else break}return t}setCurrentActiveNavMenuItem(o){var d;let t=((d=this.currentActiveNavMenuItem)==null?void 0:d.navId)===(o==null?void 0:o.navId),i=(o==null?void 0:o.disableAriaCurrent)||this.hasSiblingWithTriggerId(o)||(o==null?void 0:o.softDisabled);if(t||i||(this.currentActiveNavMenuItem&&(this.currentActiveNavMenuItem.removeAttribute("aria-current"),this.currentActiveNavMenuItem.removeAttribute("active"),this.getParentNavMenuItems(this.currentActiveNavMenuItem).forEach(b=>{b.removeAttribute("tooltip-text"),b.removeAttribute("tooltip-placement"),b.removeAttribute("active")})),!o))return;this.currentActiveNavMenuItem=o,o.setAttribute("aria-current","page"),o.setAttribute("active",""),this.getParentNavMenuItems(o).forEach(m=>{m.setAttribute("tooltip-text",this.parentNavTooltipText||""),m.setAttribute("tooltip-placement",wt.BOTTOM),m.setAttribute("active","")})}};ed.context=Gi;var rd=ed;var vx=B`
|
|
4243
4243
|
:host {
|
|
4244
4244
|
--mdc-sidenavigation-expanded-width: 15rem;
|
|
4245
4245
|
--mdc-sidenavigation-collapsed-width: 4.5rem;
|
|
@@ -5066,7 +5066,7 @@
|
|
|
5066
5066
|
:host([soft-disabled])::part(base-text) {
|
|
5067
5067
|
--mdc-select-text-color: var(--mds-color-theme-text-primary-disabled);
|
|
5068
5068
|
}
|
|
5069
|
-
`,rg=[Dx,...St(!0)];var Ke=class extends ws(Ui(be(xe(Gt(se))))){constructor(){super();this.placement=
|
|
5069
|
+
`,rg=[Dx,...St(!0)];var Ke=class extends ws(Ui(be(xe(Gt(se))))){constructor(){super();this.placement=wt.BOTTOM_START;this.boundary=_t.BOUNDARY;this.strategy=_t.STRATEGY;this.popoverZIndex=_t.Z_INDEX;this.displayPopover=!1;this.initialSelectedOption=null;this.itemsStore=new Br(this,{isValidItem:this.isValidItem,onStoreUpdate:this.onStoreUpdate});this.addEventListener(Yt.MODIFIED,this.handleModifiedEvent)}connectedCallback(){super.connectedCallback(),this.loop="false",this.initialFocus=0}get navItems(){return this.itemsStore.items}attributeChangedCallback(t,i,a){var d;if(super.attributeChangedCallback(t,i,a),t==="value"&&a!==""&&a!==i&&a!==((d=this.selectedOption)==null?void 0:d.value)&&this.navItems.length){let m=this.getFirstSelectedOption(),b=this.getFirstOption(),C=this.navItems.find(W=>W.value===a),L=null;if(C)L=C;else if(this.placeholder)L=null;else if(b)L=b;else if(m)L=m;else return;this.updateComplete.then(()=>{this.setSelectedOption(L)}).catch(W=>{this.onerror&&this.onerror(W)})}}onStoreUpdate(t,i,a){switch(i){case"added":t.setAttribute("tabindex","-1");break;case"removed":{if(a===-1||t.tabIndex!==0)return;let d=a+1;if(d>=this.navItems.length&&(d=a-1),d===-1){this.displayPopover=!1,this.handleNativeInputFocus();return}this.resetTabIndexes(d);break}default:break}}isValidItem(t){return t.matches(`${pr}:not([disabled])`)}getFirstSelectedOption(){return this.navItems.find(t=>t.hasAttribute("selected"))}getFirstOption(){return this.navItems[0]}handleModifiedEvent(t){let i=t.target,a=this.getFirstSelectedOption();switch(t.detail.change){case"selected":{a?this.setSelectedOption(a):this.setSelectedOption(i);break}case"unselected":{a?this.setSelectedOption(a):this.setSelectedOption(this.placeholder?null:this.getFirstOption());break}case"enabled":{this.itemsStore.add(i);break}case"disabled":{this.itemsStore.delete(i);break}default:break}}async firstUpdated(t){await this.updateComplete;let i=this.getFirstSelectedOption();if(i)this.initialSelectedOption=i,this.setSelectedOption(i);else if(this.placeholder)this.placeholder&&this.setInputValidity();else{let a=this.getFirstOption();this.setSelectedOption(a),this.fireEvents()}this.inputElement&&this.autoFocusOnMount&&(this.elementToAutoFocus=this.inputElement),super.firstUpdated(t)}updated(t){super.updated(t),(t.has("disabled")||t.has("softDisabled")||t.has("readonly"))&&(this.disabled||this.softDisabled||this.readonly)&&(this.displayPopover=!1)}handleOptionsClick(t){let i=t.target;i&&i.tagName===pr.toUpperCase()&&!i.hasAttribute("disabled")&&!i.hasAttribute("soft-disabled")&&(this.setSelectedOption(i),this.displayPopover=!1,this.fireEvents())}setSelectedOption(t){var i,a,d;t!==this.selectedOption&&(this.updateSelectedInChildOptions(t),this.resetTabIndexes(this.navItems.indexOf(t)),this.selectedOption=t,this.value=(a=(i=this.selectedOption)==null?void 0:i.value)!=null?a:"",this.internals.setFormValue(this.value),(d=this.inputElement)==null||d.setAttribute("value",this.value),this.setInputValidity())}updateSelectedInChildOptions(t){t==null||t.setAttribute("selected","true"),this.navItems.forEach(i=>{i!==t&&i.removeAttribute("selected")})}fireEvents(){this.dispatchInput(this.selectedOption),this.dispatchChange(this.selectedOption)}setInputValidity(){var t,i;!this.selectedOption&&this.required&&this.validationMessage?(t=this.inputElement)==null||t.setCustomValidity(this.validationMessage):(i=this.inputElement)==null||i.setCustomValidity(""),this.setValidity()}formResetCallback(){var i;let t=this.initialSelectedOption||null;((i=this.selectedOption)==null?void 0:i.value)!==(t==null?void 0:t.value)&&(this.setSelectedOption(t),this.fireEvents())}formStateRestoreCallback(t){var a;let i=this.navItems.find(d=>d.value===t||d.label===t);((a=this.selectedOption)==null?void 0:a.value)!==(i==null?void 0:i.value)&&(this.setSelectedOption(i||null),this.fireEvents())}dispatchChange(t){this.dispatchEvent(new CustomEvent("change",{detail:{value:t==null?void 0:t.value,label:t==null?void 0:t.label},composed:!0,bubbles:!0}))}dispatchInput(t){this.dispatchEvent(new CustomEvent("input",{detail:{value:t==null?void 0:t.value,label:t==null?void 0:t.label},composed:!0,bubbles:!0}))}handleClickCombobox(t){this.disabled||this.softDisabled||this.readonly||(this.displayPopover=!this.displayPopover,t.stopPropagation())}handleKeydownCombobox(t){if(!(this.disabled||this.softDisabled||this.readonly))switch(t.key){case Z.ARROW_DOWN:case Z.ARROW_UP:this.displayPopover=!0,t.preventDefault(),t.stopPropagation();break;case Z.ENTER:case Z.SPACE:this.displayPopover=!0,t.preventDefault(),t.stopPropagation();break;case Z.HOME:{this.displayPopover=!0,this.resetTabIndexAndSetFocus(0),t.preventDefault();break}case Z.END:{this.displayPopover=!0,this.resetTabIndexAndSetFocus(this.navItems.length-1),t.preventDefault();break}default:break}}handleNativeInputFocus(){this.visualCombobox.focus()}render(){var t,i,a,d,m,b;return _`
|
|
5070
5070
|
${this.renderLabel()}
|
|
5071
5071
|
<div part="container">
|
|
5072
5072
|
<div
|
|
@@ -6342,7 +6342,7 @@
|
|
|
6342
6342
|
--mdc-icon-fill-color: ButtonText;
|
|
6343
6343
|
}
|
|
6344
6344
|
}
|
|
6345
|
-
`,Hg=[TA];var pe=class extends Ui(be(xe(Gt(se)))){constructor(){super();this.placement=
|
|
6345
|
+
`,Hg=[TA];var pe=class extends Ui(be(xe(Gt(se)))){constructor(){super();this.placement=wt.BOTTOM_START;this.boundary=_t.BOUNDARY;this.strategy=_t.STRATEGY;this.popoverZIndex=_t.Z_INDEX;this.isOpen=!1;this.filteredValue="";this.initialSelectedOption=null;this.handleUpdateError=t=>{this.onerror&&this.onerror(t)};this.handleDestroyEvent=t=>{let i=t.detail.originalTarget;if(i&&(!this.isValidItem(i)||i.tabIndex!==0))return;let a=this.navItems.findIndex(m=>m===i);if(a===-1)return;let d=a+1;d>=this.navItems.length&&(d=a-1)};this.addEventListener(Yt.DESTROYED,this.handleDestroyEvent),this.itemsStore=new Br(this,{isValidItem:this.isValidItem})}get navItems(){return this.itemsStore.items}connectedCallback(){super.connectedCallback(),this.updateComplete.then(()=>{this.inputElement&&(this.setInputValidity(),this.internals.setFormValue(this.inputElement.value))}).catch(this.handleUpdateError)}isValidItem(t){return t.matches(`${pr}:not([disabled])`)}openPopover(){this.isOpen=!0}closePopover(){this.isOpen=!1}toggleDropdown(){this.isOpen=!this.isOpen}compareOptionWithValue(t,i){return(t.getAttribute("label")||"").toLowerCase().startsWith(i==null?void 0:i.toLowerCase())}getFirstSelectedOption(){return this.navItems.find(t=>t.hasAttribute("selected"))}getVisibleOptions(t){return this.navItems.filter(i=>this.compareOptionWithValue(i,t))}setSelectedValue(t){this.value=(t==null?void 0:t.getAttribute("value"))||"",this.filteredValue=(t==null?void 0:t.getAttribute("label"))||"",this.internals.setFormValue(this.value),this.updateHiddenOptions(),this.updateSelectedOption(t),this.setInputValidity(),this.resetHelpText(),cn.onInputCombobox(this,t),cn.onChangeCombobox(this,t)}resetSelectedValue(){this.value="",this.internals.setFormValue(this.value),this.resetHelpText()}resetHelpText(){this.invalidCustomValueText&&this.helpText===this.invalidCustomValueText&&(this.helpText="",this.helpTextType=Ft.DEFAULT)}attributeChangedCallback(t,i,a){super.attributeChangedCallback(t,i,a),t==="validation-message"&&this.updateComplete.then(()=>{this.setInputValidity()}).catch(this.handleUpdateError)}async firstUpdated(t){await this.updateComplete,this.inputElement&&this.autoFocusOnMount&&(this.elementToAutoFocus=this.inputElement),super.firstUpdated(t);let i=this.getFirstSelectedOption();if(i)this.initialSelectedOption=i,this.setSelectedValue(i);else if(this.value){let a=this.navItems.find(d=>d.value===this.value);this.setSelectedValue(a)}else this.placeholder&&this.setInputValidity();this.navItems.forEach(a=>{a.setAttribute("tabindex","-1")})}updated(t){super.updated(t),(t.has("slottedListboxes")||t.has("isOpen"))&&(this.visualCombobox&&"ariaControlsElements"in this.visualCombobox&&(this.visualCombobox.ariaControlsElements=this.slottedListboxes),this.dropDownButton&&"ariaControlsElements"in this.dropDownButton&&(this.dropDownButton.ariaControlsElements=this.slottedListboxes)),(t.has("disabled")||t.has("readonly"))&&(this.disabled||this.readonly)&&this.closePopover()}setInputValidity(){var t,i;!this.value&&this.required?(this.validationMessage?(t=this.inputElement)==null||t.setCustomValidity(this.validationMessage):(i=this.inputElement)==null||i.setCustomValidity(""),this.setValidity()):this.internals.setValidity({})}formResetCallback(){var i;let t=this.initialSelectedOption||null;this.setSelectedValue(t),this.filteredValue=(i=t==null?void 0:t.label)!=null?i:"",this.setInputValidity()}formStateRestoreCallback(t){let i=this.navItems.find(a=>a.value===t||a.label===t);this.setSelectedValue(i||null)}handleNativeInputFocus(){this.visualCombobox.focus()}resetFocusedOption(){this.navItems.filter(t=>t.hasAttribute("data-focused")).forEach(t=>this.updateOptionAttributes(t,!1))}updateSelectedOption(t){this.navItems.forEach(i=>{i.removeAttribute("selected")}),t==null||t.setAttribute("selected","")}updateOptionAttributes(t,i){t!==void 0&&(i?t.setAttribute("data-focused",""):t.removeAttribute("data-focused"),t.setAttribute("aria-selected",i.toString()))}handleBlurChange(){let t=this.getVisibleOptions(this.filteredValue),i=t.findIndex(a=>a.hasAttribute("data-focused"));if(i!==-1){this.setSelectedValue(t[i]),this.closePopover();return}i===-1&&this.filteredValue!==""&&this.invalidCustomValueText&&!this.getFirstSelectedOption()&&(this.helpText=this.invalidCustomValueText,this.helpTextType=Ft.ERROR),this.setInputValidity()}updateFocusAndScrollIntoView(t,i,a){var d;this.updateOptionAttributes(t[i],!1),this.updateOptionAttributes(t[a],!0),(d=t[a])==null||d.scrollIntoView({block:"nearest"})}handleInputKeydown(t){let i=this.getVisibleOptions(this.filteredValue),a=i.findIndex(d=>d.hasAttribute("data-focused"));switch(t.key){case Z.ARROW_DOWN:{this.openPopover();let d=i.length-1===a?0:a+1;this.updateFocusAndScrollIntoView(i,a,d),t.preventDefault();break}case Z.ARROW_UP:{this.openPopover();let d=a===-1||a===0?i.length-1:a-1;this.updateFocusAndScrollIntoView(i,a,d),t.preventDefault();break}case Z.ENTER:{if(a===-1)return;this.setSelectedValue(i[a]),this.isOpen===!0&&this.closePopover();break}case Z.ESCAPE:{a!==-1&&this.updateOptionAttributes(i[a],!1),i.length&&this.shouldDisplayPopover(i.length)?this.closePopover():(this.resetSelectedValue(),this.filteredValue="");break}case Z.TAB:{this.closePopover();break}case Z.HOME:case Z.END:{this.resetFocusedOption();break}default:break}}updateHiddenOptions(){this.navItems.forEach(t=>{this.compareOptionWithValue(t,this.filteredValue)?(t.removeAttribute("data-hidden"),this.showOptionGroupAndDivider(t)):(t.setAttribute("data-hidden",""),this.hideOptionGroupAndDivider(t))})}hideOptionGroupAndDivider(t){var i,a,d;(i=t.parentElement)!=null&&i.matches(tn)&&((a=Array.from(t.parentElement.children))==null?void 0:a.filter(b=>!b.hasAttribute("data-hidden"))).length===0&&(t.parentElement.setAttribute("data-hidden",""),(d=t.parentElement.nextElementSibling)!=null&&d.matches(Da)&&t.parentElement.nextElementSibling.setAttribute("data-hidden",""))}showOptionGroupAndDivider(t){var i,a,d;(i=t.parentElement)!=null&&i.matches(tn)&&((a=Array.from(t.parentElement.children))==null?void 0:a.filter(b=>!b.hasAttribute("data-hidden"))).length>0&&(t.parentElement.removeAttribute("data-hidden"),(d=t.parentElement.nextElementSibling)!=null&&d.matches(Da)&&t.parentElement.nextElementSibling.removeAttribute("data-hidden"))}handleInputChange(t){var i;this.filteredValue=t.target.value,this.resetSelectedValue(),this.resetFocusedOption(),this.updateHiddenOptions(),(i=this.getFirstSelectedOption())==null||i.removeAttribute("selected"),this.isOpen===!1&&this.openPopover()}handleOptionsClick(t){var a;let i=(a=t.target.closest(pr))!=null?a:null;i&&!i.hasAttribute("disabled")&&(this.setSelectedValue(i),this.closePopover(),this.updateComplete.then(()=>this.handleNativeInputFocus()).catch(this.handleUpdateError))}shouldDisplayPopover(t){return this.disabled||this.readonly?!1:t?this.isOpen:!!this.noResultText}renderNativeInput(){return _`
|
|
6346
6346
|
<input
|
|
6347
6347
|
id="${this.inputId}"
|
|
6348
6348
|
name="${this.name}"
|
|
@@ -6658,12 +6658,12 @@
|
|
|
6658
6658
|
border: 1px solid;
|
|
6659
6659
|
}
|
|
6660
6660
|
}
|
|
6661
|
-
`,jg=[Li,SA];var
|
|
6661
|
+
`,jg=[Li,SA];var kt=class extends q{constructor(){super();this.thumbFocused=Qi.STATE;this.thumbHovered=Qi.STATE;this.range=!1;this.min=Qi.MIN;this.max=Qi.MAX;this.step=Qi.STEP;this.addEventListener("keydown",this.preventChange.bind(this)),this.addEventListener("mousedown",this.preventChange.bind(this))}updated(t){super.updated(t),(t.has("value")||t.has("step")||t.has("min")||t.has("max")||t.has("disabled")||t.has("softDisabled")||t.has("range")||t.has("valueStart")||t.has("valueEnd"))&&this.updateTrackStyling(),t.has("softDisabled")&&this.setSoftDisabled(),(t.has("range")||t.has("valueStart")||t.has("valueEnd"))&&this.initializeRangeSlider()}preventChange(t){this.softDisabled&&(t instanceof KeyboardEvent&&t.key!==Z.TAB||!(t instanceof KeyboardEvent))&&(t.preventDefault(),t.stopPropagation())}setSoftDisabled(){this.inputElements.forEach(t=>{let i=t;this.softDisabled?i.setAttribute("aria-disabled","true"):i.removeAttribute("aria-disabled")})}initializeRangeSlider(){this.valueStart===void 0&&(this.valueStart=this.min),this.valueEnd===void 0&&(this.valueEnd=this.max),this.handleInput(0),this.handleInput(1)}handleInput(t){let i=this.inputElements[t];if(i)if(t===0){if(!this.valueEnd)return;let a=Number(i.value);a>this.valueEnd?(i.value=String(this.valueEnd),this.valueStart=this.valueEnd):a>=this.min&&a<this.valueEnd?this.valueStart=a:a<this.min&&(i.value=String(this.min),this.valueStart=this.min)}else{if(!this.valueStart)return;let a=Number(i.value);a<this.valueStart?(i.value=String(this.valueStart),this.valueEnd=this.valueStart):a<=this.max&&a>this.valueStart?this.valueEnd=a:a>this.max&&(i.value=String(this.max),this.valueEnd=this.max)}}iconTemplate(t,i){return typeof t=="string"&&t.length>0?_`<mdc-icon
|
|
6662
6662
|
name="${t}"
|
|
6663
6663
|
part="${i}"
|
|
6664
6664
|
length-unit="${Qi.ICON_LENGTH_UNIT}"
|
|
6665
6665
|
size="${Qi.ICON_SIZE}"
|
|
6666
|
-
></mdc-icon>`:null}tooltipTemplate(t,i){let[a,d]=this.inputElements,m=i==="end"?d:a,b=Number(m==null?void 0:m.value);if(typeof b!="number"||Number.isNaN(b)||this.max===this.min||this.disabled)return j;let C=(b-this.min)/(this.max-this.min);return _`<div part="slider-tooltip" aria-hidden="true" style="--mdc-slider-tooltip-left: ${C}">
|
|
6666
|
+
></mdc-icon>`:null}tooltipTemplate(t,i){let[a,d]=this.inputElements,m=i==="end"?d:a,b=Number(m==null?void 0:m.value);if(typeof b!="number"||Number.isNaN(b)||this.max===this.min||this.disabled||this.hideTooltip)return j;let C=(b-this.min)/(this.max-this.min);return _`<div part="slider-tooltip" aria-hidden="true" style="--mdc-slider-tooltip-left: ${C}">
|
|
6667
6667
|
${t||b}
|
|
6668
6668
|
</div> `}updateTrackStyling(){let t="var(--mdc-slider-progress-color)",i="var(--mdc-slider-track-color)";if((this.disabled||this.softDisabled)&&(t="var(--mds-color-theme-control-active-disabled)",i="var(--mds-color-theme-control-inactive-disabled)"),this.range){if(!this.inputElements[1])return;let a=Number(this.inputElements[0].value),d=Number(this.inputElements[1].value),m=Number(this.inputElements[0].max)||1,b=Math.max(0,Math.min(100,(a-this.min)/(m-this.min)*100)),C=Math.max(0,Math.min(100,(d-this.min)/(m-this.min)*100));this.inputElements[1].style.background=`linear-gradient(
|
|
6669
6669
|
to right,
|
|
@@ -6763,7 +6763,7 @@
|
|
|
6763
6763
|
${this.labelStart?_`<span part="slider-label-start">${this.labelStart}</span>`:null}
|
|
6764
6764
|
${this.labelEnd?_`<span part="slider-label-end">${this.labelEnd}</span>`:null}
|
|
6765
6765
|
</div>
|
|
6766
|
-
`}};
|
|
6766
|
+
`}};kt.styles=[...q.styles,...jg],p([vt()],kt.prototype,"thumbFocused",2),p([vt()],kt.prototype,"thumbHovered",2),p([u({reflect:!0,type:Boolean})],kt.prototype,"range",2),p([u({reflect:!0,type:Number})],kt.prototype,"min",2),p([u({reflect:!0,type:Number})],kt.prototype,"max",2),p([u({reflect:!0,type:Boolean})],kt.prototype,"disabled",2),p([u({reflect:!0,type:Boolean,attribute:"soft-disabled"})],kt.prototype,"softDisabled",2),p([u({reflect:!0,type:String,attribute:"leading-icon"})],kt.prototype,"leadingIcon",2),p([u({reflect:!0,type:String,attribute:"trailing-icon"})],kt.prototype,"trailingIcon",2),p([u({reflect:!0,type:Number})],kt.prototype,"value",2),p([u({reflect:!0,type:Number,attribute:"value-start"})],kt.prototype,"valueStart",2),p([u({reflect:!0,type:Number,attribute:"value-end"})],kt.prototype,"valueEnd",2),p([u({reflect:!0,type:Number})],kt.prototype,"step",2),p([u({reflect:!0,type:String})],kt.prototype,"label",2),p([u({reflect:!0,type:String,attribute:"label-start"})],kt.prototype,"labelStart",2),p([u({reflect:!0,type:String,attribute:"label-end"})],kt.prototype,"labelEnd",2),p([u({reflect:!0,type:String,attribute:"value-label"})],kt.prototype,"valueLabel",2),p([u({reflect:!0,type:String,attribute:"value-label-start"})],kt.prototype,"valueLabelStart",2),p([u({reflect:!0,type:String,attribute:"value-label-end"})],kt.prototype,"valueLabelEnd",2),p([u({reflect:!0,type:String})],kt.prototype,"name",2),p([u({reflect:!0,type:String,attribute:"name-start"})],kt.prototype,"nameStart",2),p([u({reflect:!0,type:String,attribute:"name-end"})],kt.prototype,"nameEnd",2),p([u({reflect:!0,type:String,attribute:"data-aria-label"})],kt.prototype,"dataAriaLabel",2),p([u({reflect:!0,type:String,attribute:"start-aria-label"})],kt.prototype,"startAriaLabel",2),p([u({reflect:!0,type:String,attribute:"end-aria-label"})],kt.prototype,"endAriaLabel",2),p([u({reflect:!0,type:String,attribute:"data-aria-valuetext"})],kt.prototype,"dataAriaValuetext",2),p([u({reflect:!0,type:String,attribute:"start-aria-valuetext"})],kt.prototype,"startAriaValuetext",2),p([u({reflect:!0,type:String,attribute:"end-aria-valuetext"})],kt.prototype,"endAriaValueText",2),p([u({reflect:!0,type:Boolean,attribute:"hide-tooltip"})],kt.prototype,"hideTooltip",2),p([Am('input[type="range"]')],kt.prototype,"inputElements",2);var op=kt;op.register(Wg);var _A=op;var IA=B`
|
|
6767
6767
|
:host {
|
|
6768
6768
|
--mdc-listbox-max-height: auto;
|
|
6769
6769
|
|