1import"./BoSgytzD.js";import{m as tt,o as dt,v as P,g as a,u as A,j as vt,bV as gt,O as E,p as C,e as S,h as _,a as m,b as F,f as k,c as K,P as T,r as U,t as mt,s as at}from"./cTk3EI1u.js";import{c as z}from"./an-jh6Vv.js";import{p as d,i as O,r as D,s as j}from"./C1UlOoSx.js";import{c as L}from"./DJ19z78D.js";import{a as I}from"./BQtIuW8-.js";import{d as W,c as pt,a as bt}from"./BD_yA8oF.js";import{i as yt,B as xt,f as At,b as f,g as _t,t as St,h as wt,j as Pt,A as Y,k as et,l as rt,n as Z,E as It,o as Nt,H as Ct,C as lt,e as Ft,a as q,p as J,P as Dt,q as Q,S as Rt,r as kt,s as ct,w as $,u as Tt,v as Mt,c as G,x as Bt,m as H}from"./BQQvsFJy.js";import{C as Vt}from"./Dd-Fokri.js";import{C as Kt}from"./j8cHeQll.js";function M(i){let t=tt(dt(i));return{[xt]:!0,[yt]:!0,get current(){return a(t)},set current(e){P(t,e,!0)}}}M.from=At;M.with=f;M.flatten=_t;M.readonly=St;M.isBox=wt;M.isWritableBox=Pt;function Ut(i){return window.getComputedStyle(i).getPropertyValue("direction")}function zt(i="ltr",t="horizontal"){return{horizontal:i==="rtl"?rt:et,vertical:Z}[t]}function Et(i="ltr",t="horizontal"){return{horizontal:i==="rtl"?et:rt,vertical:Y}[t]}function Ot(i="ltr",t="horizontal"){return["ltr","rtl"].includes(i)||(i="ltr"),["horizontal","vertical"].includes(t)||(t="horizontal"),{nextKey:zt(i,t),prevKey:Et(i,t)}}class Wt{#t;#e=M(null);constructor(t){this.#t=t}getCandidateNodes(){return this.#t.rootNode.current?this.#t.candidateSelector?Array.from(this.#t.rootNode.current.querySelectorAll(this.#t.candidateSelector)):this.#t.candidateAttr?Array.from(this.#t.rootNode.current.querySelectorAll(`[${this.#t.candidateAttr}]:not([data-disabled])`)):[]:[]}focusFirstCandidate(){const t=this.getCandidateNodes();t.length&&t[0]?.focus()}handleKeydown(t,e,r=!1){const n=this.#t.rootNode.current;if(!n||!t)return;const c=this.getCandidateNodes();if(!c.length)return;const v=c.indexOf(t),b=Ut(n),{nextKey:h,prevKey:g}=Ot(b,this.#t.orientation.current),l=this.#t.loop.current,y={[h]:v+1,[g]:v-1,[Ct]:0,[It]:c.length-1};if(r){const s=h===Z?et:Z,o=g===Y?rt:Y;y[s]=v+1,y[o]=v-1}let x=y[e.key];if(x===void 0)return;e.preventDefault(),x<0&&l?x=c.length-1:x===c.length&&l&&(x=0);const u=c[x];if(u)return u.focus(),this.#e.current=u.id,this.#t.onCandidateFocus?.(u),u}getTabIndex(t){const e=this.getCandidateNodes(),r=this.#e.current!==null;return t&&!r&&e[0]===t?(this.#e.current=t.id,0):t?.id===this.#e.current?0:-1}setCurrentTabStopId(t){this.#e.current=t}focusCurrentTabStop(){const t=this.#e.current;if(!t)return;const e=this.#t.rootNode.current?.querySelector(`#${t}`);!e||!Nt(e)||e.focus()}}const V=Ft({component:"accordion",parts:["root","trigger","content","item","header"]}),ut=new lt("Accordion.Root"),X=new lt("Accordion.Item");class ht{opts;rovingFocusGroup;attachment;constructor(t){this.opts=t,this.rovingFocusGroup=new Wt({rootNode:this.opts.ref,candidateAttr:V.trigger,loop:this.opts.loop,orientation:this.opts.orientation}),this.attachment=q(this.opts.ref)}#t=A(()=>({id:this.opts.id.current,"data-orientation":this.opts.orientation.current,"data-disabled":J(this.opts.disabled.current),[V.root]:"",...this.attachment}));get props(){return a(this.#t)}set props(t){P(this.#t,t)}}class qt extends ht{opts;isMulti=!1;constructor(t){super(t),this.opts=t,this.includesItem=this.includesItem.bind(this),this.toggleItem=this.toggleItem.bind(this)}includesItem(t){return this.opts.value.current===t}toggleItem(t){this.opts.value.current=this.includesItem(t)?"":t}}class Gt extends ht{#t;isMulti=!0;constructor(t){super(t),this.#t=t.value,this.includesItem=this.includesItem.bind(this),this.toggleItem=this.toggleItem.bind(this)}includesItem(t){return this.#t.current.includes(t)}toggleItem(t){this.#t.current=this.includesItem(t)?this.#t.current.filter(e=>e!==t):[...this.#t.current,t]}}class Ht{static create(t){const{type:e,...r}=t,n=e==="single"?new qt(r):new Gt(r);return ut.set(n)}}class it{static create(t){return X.set(new it({...t,rootState:ut.get()}))}opts;root;#t=A(()=>this.root.includesItem(this.opts.value.current));get isActive(){return a(this.#t)}set isActive(t){P(this.#t,t)}#e=A(()=>this.opts.disabled.current||this.root.opts.disabled.current);get isDisabled(){return a(this.#e)}set isDisabled(t){P(this.#e,t)}attachment;#r=tt(null);get contentNode(){return a(this.#r)}set contentNode(t){P(this.#r,t,!0)}contentPresence;
1constructor(t){this.opts=t,this.root=t.rootState,this.updateValue=this.updateValue.bind(this),this.attachment=q(this.opts.ref),this.contentPresence=new Dt({ref:f(()=>this.contentNode),open:f(()=>this.isActive)})}updateValue(){this.root.toggleItem(this.opts.value.current)}#i=A(()=>({id:this.opts.id.current,"data-state":Q(this.isActive),"data-disabled":J(this.isDisabled),"data-orientation":this.root.opts.orientation.current,[V.item]:"",...this.attachment}));get props(){return a(this.#i)}set props(t){P(this.#i,t)}}class nt{opts;itemState;#t;#e=A(()=>this.opts.disabled.current||this.itemState.opts.disabled.current||this.#t.opts.disabled.current);attachment;constructor(t,e){this.opts=t,this.itemState=e,this.#t=e.root,this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this),this.attachment=q(this.opts.ref)}static create(t){return new nt(t,X.get())}onclick(t){if(a(this.#e)||t.button!==0){t.preventDefault();return}this.itemState.updateValue()}onkeydown(t){if(!a(this.#e)){if(t.key===Rt||t.key===kt){t.preventDefault(),this.itemState.updateValue();return}this.#t.rovingFocusGroup.handleKeydown(this.opts.ref.current,t)}}#r=A(()=>({id:this.opts.id.current,disabled:a(this.#e),"aria-expanded":ct(this.itemState.isActive),"aria-disabled":ct(a(this.#e)),"data-disabled":J(a(this.#e)),"data-state":Q(this.itemState.isActive),"data-orientation":this.#t.opts.orientation.current,[V.trigger]:"",tabindex:this.opts.tabindex.current,onclick:this.onclick,onkeydown:this.onkeydown,...this.attachment}));get props(){return a(this.#r)}set props(t){P(this.#r,t)}}class st{opts;item;attachment;#t=void 0;#e=!1;#r=tt(dt({width:0,height:0}));#i=A(()=>this.opts.hiddenUntilFound.current?this.item.isActive:this.opts.forceMount.current||this.item.isActive);get open(){return a(this.#i)}set open(t){P(this.#i,t)}constructor(t,e){this.opts=t,this.item=e,this.#e=this.item.isActive,this.attachment=q(this.opts.ref,r=>this.item.contentNode=r),vt(()=>{const r=requestAnimationFrame(()=>{this.#e=!1});return()=>cancelAnimationFrame(r)}),$.pre([()=>this.opts.ref.current,()=>this.opts.hiddenUntilFound.current],([r,n])=>!r||!n?void 0:gt(r,"beforematch",()=>{this.item.isActive||requestAnimationFrame(()=>{this.item.updateValue()})})),$([()=>this.open,()=>this.opts.ref.current],this.#o)}static create(t){return new st(t,X.get())}#o=([t,e])=>{e&&Tt(()=>{const r=this.opts.ref.current;if(!r)return;this.#t??={transitionDuration:r.style.transitionDuration,animationName:r.style.animationName},r.style.transitionDuration="0s",r.style.animationName="none";const n=r.getBoundingClientRect();P(this.#r,{width:n.width,height:n.height},!0),!this.#e&&this.#t&&(r.style.transitionDuration=this.#t.transitionDuration,r.style.animationName=this.#t.animationName)})};get shouldRender(){return this.item.contentPresence.shouldRender}#n=A(()=>({open:this.item.isActive}));get snippetProps(){return a(this.#n)}set snippetProps(t){P(this.#n,t)}#s=A(()=>({id:this.opts.id.current,"data-state":Q(this.item.isActive),...Mt(this.item.contentPresence.transitionStatus),"data-disabled":J(this.item.isDisabled),"data-orientation":this.item.root.opts.orientation.current,[V.content]:"",style:{"--bits-accordion-content-height":`${a(this.#r).height}px`,"--bits-accordion-content-width":`${a(this.#r).width}px`},hidden:this.opts.hiddenUntilFound.current&&!this.item.isActive?"until-found":void 0,...this.opts.hiddenUntilFound.current&&!this.shouldRender?{}:{hidden:this.opts.hiddenUntilFound.current?!this.shouldRender:this.opts.forceMount.current?void 0:!this.shouldRender},...this.attachment}));get props(){return a(this.#s)}set props(t){P(this.#s,t)}}class ot{opts;item;attachment;constructor(t,e){this.opts=t,this.item=e,this.attachment=q(this.opts.ref)}static create(t){return new ot(t,X.get())}#t=A(()=>({id:this.opts.id.current,role:"heading","aria-level":this.opts.level.current,"data-heading-level":this.opts.level.current,"data-state":Q(this.item.isActive),"data-orientation":this.item.root.opts.orientation.current,[V.header]:"",...this.attachment}));get props(){return a(this.#t)}set props(t){P(this.#t,t)}}var jt=new Set(["$$slots","$$events","$$legacy","disabled","children","child","type","value","ref","id","onValueChange","loop","orientation"]),Lt=k("<div><!></div>");function Jt(i,t){const e=E();C(t,!0);let r=d(t,"disabled",3,!1),n=d(t,"value",15),c=d(t,"ref",15,null),v=d(t,"id",19,()=>G(e)),b=d(t,"onValueChange",3,Bt),h=d(t,"loop",3,!0),g=d(t,"orientation",3,"vertical"),l=D(t,jt);function y(){n()===void 0&&n(t.type==="single"?"":[])}y(),$.pre(()=>n(),()=>{y()});const x=Ht.create({type:t.type,value:f(()=>n(),w=>{n(w),b()(w)}),id:f(()=>v()),disabled:f(()=>r()),loop:f(()=>h()),orientation:f(()=>g()),ref:f(()=>c(),w=>c(w))}),u=A(()=>H(l,x.props));var s=S(),o=_(s);{var p=w=>
1{var N=S(),B=_(N);I(B,()=>t.child,()=>({props:a(u)})),m(w,N)},R=w=>{var N=Lt();W(N,()=>({...a(u)}));var B=K(N);I(B,()=>t.children??T),U(N),m(w,N)};O(o,w=>{t.child?w(p):w(R,-1)})}m(i,s),F()}var Qt=new Set(["$$slots","$$events","$$legacy","id","disabled","value","children","child","ref"]),Xt=k("<div><!></div>");function Yt(i,t){const e=E();C(t,!0);const r=G(e);let n=d(t,"id",3,r),c=d(t,"disabled",3,!1),v=d(t,"value",3,r),b=d(t,"ref",15,null),h=D(t,Qt);const g=it.create({value:f(()=>v()),disabled:f(()=>c()),id:f(()=>n()),ref:f(()=>b(),o=>b(o))}),l=A(()=>H(h,g.props));var y=S(),x=_(y);{var u=o=>{var p=S(),R=_(p);I(R,()=>t.child,()=>({props:a(l)})),m(o,p)},s=o=>{var p=Xt();W(p,()=>({...a(l)}));var R=K(p);I(R,()=>t.children??T),U(p),m(o,p)};O(x,o=>{t.child?o(u):o(s,-1)})}m(i,y),F()}var Zt=new Set(["$$slots","$$events","$$legacy","id","level","children","child","ref"]),$t=k("<div><!></div>");function te(i,t){const e=E();C(t,!0);let r=d(t,"id",19,()=>G(e)),n=d(t,"level",3,2),c=d(t,"ref",15,null),v=D(t,Zt);const b=ot.create({id:f(()=>r()),level:f(()=>n()),ref:f(()=>c(),u=>c(u))}),h=A(()=>H(v,b.props));var g=S(),l=_(g);{var y=u=>{var s=S(),o=_(s);I(o,()=>t.child,()=>({props:a(h)})),m(u,s)},x=u=>{var s=$t();W(s,()=>({...a(h)}));var o=K(s);I(o,()=>t.children??T),U(s),m(u,s)};O(l,u=>{t.child?u(y):u(x,-1)})}m(i,g),F()}var ee=new Set(["$$slots","$$events","$$legacy","disabled","ref","id","tabindex","children","child"]),re=k("<button><!></button>");function ie(i,t){const e=E();C(t,!0);let r=d(t,"disabled",3,!1),n=d(t,"ref",15,null),c=d(t,"id",19,()=>G(e)),v=d(t,"tabindex",3,0),b=D(t,ee);const h=nt.create({disabled:f(()=>r()),id:f(()=>c()),tabindex:f(()=>v()??0),ref:f(()=>n(),s=>n(s))}),g=A(()=>H(b,h.props));var l=S(),y=_(l);{var x=s=>{var o=S(),p=_(o);I(p,()=>t.child,()=>({props:a(g)})),m(s,o)},u=s=>{var o=re();W(o,()=>({type:"button",...a(g)}));var p=K(o);I(p,()=>t.children??T),U(o),m(s,o)};O(y,s=>{t.child?s(x):s(u,-1)})}m(i,l),F()}var ne=new Set(["$$slots","$$events","$$legacy","child","ref","id","forceMount","children","hiddenUntilFound"]),se=k("<div><!></div>");function oe(i,t){const e=E();C(t,!0);let r=d(t,"ref",15,null),n=d(t,"id",19,()=>G(e)),c=d(t,"forceMount",3,!1),v=d(t,"hiddenUntilFound",3,!1),b=D(t,ne);const h=st.create({forceMount:f(()=>c()),id:f(()=>n()),ref:f(()=>r(),s=>r(s)),hiddenUntilFound:f(()=>v())}),g=A(()=>H(b,h.props));var l=S(),y=_(l);{var x=s=>{var o=S(),p=_(o);{let R=A(()=>({props:a(g),...h.snippetProps}));I(p,()=>t.child,()=>a(R))}m(s,o)},u=s=>{var o=se();W(o,()=>({...a(g)}));var p=K(o);I(p,()=>t.children??T),U(o),m(s,o)};O(y,s=>{t.child?s(x):s(u,-1)})}m(i,l),F()}var ae=new Set(["$$slots","$$events","$$legacy","ref","value","class"]);function Se(i,t){C(t,!0);let e=d(t,"ref",15,null),r=d(t,"value",15),n=D(t,ae);var c=S(),v=_(c);{let b=A(()=>L("cn-accordion flex w-full flex-col",t.class));z(v,()=>Jt,(h,g)=>{g(h,j({"data-slot":"accordion",get class(){return a(b)}},()=>n,{get ref(){return e()},set ref(l){e(l)},get value(){return r()},set value(l){r(l)}}))})}m(i,c),F()}var ce=new Set(["$$slots","$$events","$$legacy","ref","class","children"]),de=k("<div><!></div>");function we(i,t){C(t,!0);let e=d(t,"ref",15,null),r=D(t,ce);var n=S(),c=_(n);z(c,()=>oe,(v,b)=>{b(v,j({"data-slot":"accordion-content",class:"overflow-hidden data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down"},()=>r,{get ref(){return e()},set ref(h){e(h)},children:(h,g)=>{var l=de(),y=K(l);I(y,()=>t.children??T),U(l),mt(x=>bt(l,1,x),[()=>pt(L("pt-0 pb-2.5 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground",t.class))]),m(h,l)},$$slots:{default:!0}}))}),m(i,n),F()}var le=new Set(["$$slots","$$events","$$legacy","ref","class"]);function Pe(i,t){C(t,!0);let e=d(t,"ref",15,null),r=D(t,le);var n=S(),c=_(n);{let v=A(()=>L("border-b",t.class));z(c,()=>Yt,(b,h)=>{h(b,j({"data-slot":"accordion-item",get class(){return a(v)}},()=>r,{get ref(){return e()},set ref(g){e(g)}}))})}m(i,n),F()}var ue=new Set(["$$slots","$$events","$$legacy","ref","class","level","children"]),he=k("<!> <!> <!>",1);function Ie(i,t){C(t,!0);let e=d(t,"ref",15,null),r=d(t,"level",3,3),n=D(t,ue);var c=S(),v=_(c);z(v,()=>te,(b,h)=>{h(b,{get level(){return r()},class:"flex",children:(g,l)=>{var y=S(),x=_(y);{let u=A(()=>L("group/accordion-trigger relative flex flex-1 items-start justify-between rounded-lg border border-transparent py-2.5 text-left text-heading-quaternary transition-all outline-none hover:underline focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:after:border-ring disabled:pointer-events-none disabled:opacity-50 **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground lg:text-heading-tertiary",t.class));z(x,()=>ie,(s,o)=>{o(s,j({"data-slot":"accordion-trigger",get class(){return a(u)}},()=>n,{get ref(){return e()},set ref(p){e(p)},children:(p,R)=>{var w=he(),N=_(w);I(N,()=>t.children??T);var B=at(N,2);Vt(B,{"data-slot":"accordion-trigger-icon",class:"cn-accordion-trigger-icon stroke-text-coral pointer-events-none size-5 shrink-0 group-aria-expanded/accordion-trigger:hidden"});var ft=at(B,2);Kt(ft,{"data-slot":"accordion-trigger-icon",class:"cn-accordion-trigger-icon stroke-text-coral pointer-events-none hidden size-5 shrink-0 group-aria-expanded/accordion-trigger:inline"}),m(p,w)},$$slots:{default:!0}}
1))})}m(g,y)},$$slots:{default:!0}})}),m(i,c),F()}export{Se as A,Pe as a,Ie as b,we as c};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.