@local-logic/design-system 0.7.36 → 0.7.37
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/components/HorizontalScrollFilters/Root/Filter/index.d.ts.map +1 -1
- package/dist/components/HorizontalScrollFilters/Root/Filter/styles.d.ts +1 -1
- package/dist/components/HorizontalScrollFilters/Root/Filter/styles.d.ts.map +1 -1
- package/dist/index.es.js +27 -16
- package/dist/index.umd.js +4 -4
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/HorizontalScrollFilters/Root/Filter/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAIlD,wBAAgB,MAAM,CAAC,CAAC,EAAE,EACxB,MAAM,EACN,KAAK,EACL,IAAI,EAAE,IAAI,EACV,mBAAmB,EACnB,aAAa,EACb,QAAQ,EACR,cAAc,GACf,EAAE;IACD,MAAM,EAAE,CAAC,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,IAAI,CAAC;IACX,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,KAAK,IAAI,CAAC;CACtC,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/HorizontalScrollFilters/Root/Filter/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAIlD,wBAAgB,MAAM,CAAC,CAAC,EAAE,EACxB,MAAM,EACN,KAAK,EACL,IAAI,EAAE,IAAI,EACV,mBAAmB,EACnB,aAAa,EACb,QAAQ,EACR,cAAc,GACf,EAAE;IACD,MAAM,EAAE,CAAC,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,IAAI,CAAC;IACX,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,KAAK,IAAI,CAAC;CACtC,qBAyCA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const container = "group list-none";
|
|
2
|
-
export declare const button = "\n text-gray-400 flex items-center gap-x-2 border border-gray-150\n h-10 px-5 rounded-full cursor-pointer transition-colors -outline-offset-2\n
|
|
2
|
+
export declare const button = "\n text-gray-400 flex items-center gap-x-2 border border-gray-150\n h-10 px-5 rounded-full cursor-pointer transition-colors -outline-offset-2\n\n hover:bg-[color:var(--background,_theme(colors.primary.100))]\n hover:text-base-white\n hover:border-transparent\n\n group-data-[active=true]:bg-[color:var(--background,_theme(colors.primary.100))]\n group-data-[active=true]:text-base-white\n group-data-[active=true]:border-transparent\n";
|
|
3
3
|
export declare const icon = "w-5 h-5";
|
|
4
4
|
export declare const text = "text-sm font-medium leading-5 text-nowrap";
|
|
5
5
|
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../../../src/components/HorizontalScrollFilters/Root/Filter/styles.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,oBAAoB,CAAC;AAE3C,eAAO,MAAM,MAAM,+
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../../../src/components/HorizontalScrollFilters/Root/Filter/styles.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,oBAAoB,CAAC;AAE3C,eAAO,MAAM,MAAM,+bAWlB,CAAC;AAEF,eAAO,MAAM,IAAI,YAAY,CAAC;AAE9B,eAAO,MAAM,IAAI,8CAA8C,CAAC"}
|
package/dist/index.es.js
CHANGED
|
@@ -10638,12 +10638,12 @@ const ZT = ({
|
|
|
10638
10638
|
}, HT = "group list-none", KT = `
|
|
10639
10639
|
text-gray-400 flex items-center gap-x-2 border border-gray-150
|
|
10640
10640
|
h-10 px-5 rounded-full cursor-pointer transition-colors -outline-offset-2
|
|
10641
|
-
|
|
10642
|
-
hover:bg-primary
|
|
10641
|
+
|
|
10642
|
+
hover:bg-[color:var(--background,_theme(colors.primary.100))]
|
|
10643
10643
|
hover:text-base-white
|
|
10644
10644
|
hover:border-transparent
|
|
10645
10645
|
|
|
10646
|
-
group-data-[active=true]:bg-primary
|
|
10646
|
+
group-data-[active=true]:bg-[color:var(--background,_theme(colors.primary.100))]
|
|
10647
10647
|
group-data-[active=true]:text-base-white
|
|
10648
10648
|
group-data-[active=true]:border-transparent
|
|
10649
10649
|
`, GT = "w-5 h-5", YT = "text-sm font-medium leading-5 text-nowrap";
|
|
@@ -10663,19 +10663,30 @@ function XT({
|
|
|
10663
10663
|
"data-active": i,
|
|
10664
10664
|
"data-testid": "filter-item",
|
|
10665
10665
|
"data-filter": e,
|
|
10666
|
-
children: /* @__PURE__ */ H(
|
|
10667
|
-
|
|
10668
|
-
|
|
10669
|
-
|
|
10670
|
-
|
|
10671
|
-
|
|
10672
|
-
|
|
10673
|
-
|
|
10674
|
-
|
|
10675
|
-
|
|
10676
|
-
|
|
10677
|
-
|
|
10678
|
-
|
|
10666
|
+
children: /* @__PURE__ */ H(
|
|
10667
|
+
"button",
|
|
10668
|
+
{
|
|
10669
|
+
onClick: () => {
|
|
10670
|
+
s && s(e);
|
|
10671
|
+
},
|
|
10672
|
+
className: KT,
|
|
10673
|
+
"data-testid": "filter-item-button",
|
|
10674
|
+
style: o ? {
|
|
10675
|
+
"--background": o
|
|
10676
|
+
} : void 0,
|
|
10677
|
+
children: [
|
|
10678
|
+
r && o ? /* @__PURE__ */ E(
|
|
10679
|
+
Lh,
|
|
10680
|
+
{
|
|
10681
|
+
element: /* @__PURE__ */ E(n, {}),
|
|
10682
|
+
backgroundColor: r,
|
|
10683
|
+
fillColor: o
|
|
10684
|
+
}
|
|
10685
|
+
) : /* @__PURE__ */ E(n, { className: GT, "data-testid": "filter-item-icon" }),
|
|
10686
|
+
/* @__PURE__ */ E("p", { className: YT, "data-testid": "filter-item-label", children: t })
|
|
10687
|
+
]
|
|
10688
|
+
}
|
|
10689
|
+
)
|
|
10679
10690
|
}
|
|
10680
10691
|
);
|
|
10681
10692
|
}
|
package/dist/index.umd.js
CHANGED
|
@@ -243,15 +243,15 @@
|
|
|
243
243
|
`,dT=({label:e})=>{const{setIsFiltersDialogOpen:t}=ji();return v.jsx("button",{"data-testid":"dialog-trigger",className:lT,"aria-label":e||"All filters",onClick:()=>t(!0),children:v.jsx(qu,{className:uT})})},fT="relative overflow-hidden",hT="h-full flex gap-x-2 items-center overflow-auto no-scrollbar outline-px focus:outline-primary-100 -outline-offset-2",rd="h-full hidden md:flex items-center w-16 absolute from-base-white via-base-white to-transparent",pT=`${rd} justify-start left-0 bg-gradient-to-r pl-1`,mT=`${rd} justify-end right-0 bg-gradient-to-l pr-1`,od="flex justify-center items-center border-2 border-gray-400 text-gray-400 rounded-full w-8 h-8 bg-base-white cursor-pointer hover:scale-110 hover:shadow-md transition-all",id=50,Bi=128;function gT(e,t,n,r,o){if(e||t===n||!o?.current||!t||!r)return;const i=o.current.querySelector("li[data-active='true']");i&&o.current?.scroll({left:i.offsetLeft-Bi,behavior:"smooth"})}const yT=({activeFilter:e,leftArrowAriaLabel:t,rightArrowAriaLabel:n,children:r})=>{const{isFiltersDialogOpen:o}=ji(),[i,s]=E.useState(e),[a,c]=E.useState(o),[l,u]=E.useState(!1),[f,h]=E.useState(!0),p=E.useRef(null);E.useEffect(()=>{c(o)},[o]),E.useEffect(()=>{s(e)},[e]),E.useEffect(()=>{gT(o,e,i,a,p)},[e,i,o,a]);const y=()=>{p.current?.scroll({left:p.current.scrollLeft-p.current.clientWidth+Bi,behavior:"smooth"})},m=()=>{p.current?.scroll({left:p.current.scrollLeft+p.current.clientWidth-Bi,behavior:"smooth"})},g=b=>{const x=id,T=b.currentTarget.scrollWidth-b.currentTarget.offsetWidth-id;b.currentTarget.scrollLeft>x&&!l?u(!0):b.currentTarget.scrollLeft<x&&l&&u(!1),b.currentTarget.scrollLeft<T&&!f?h(!0):b.currentTarget.scrollLeft>T&&f&&h(!1)};return v.jsx("div",{className:fT,"data-testid":"scroll-list-container",children:v.jsxs("ul",{"data-testid":"scroll-list",className:hT,ref:p,onScroll:g,tabIndex:0,children:[l&&v.jsx("li",{className:pT,children:v.jsx("button",{"data-testid":"left-arrow-button",className:od,"aria-label":t||"Scroll left",onClick:y,children:v.jsx(Gu,{weight:"bold"})})}),r,f&&v.jsx("li",{className:mT,children:v.jsx("button",{"data-testid":"right-arrow-button",className:od,"aria-label":n||"Scroll right",onClick:m,children:v.jsx(Yu,{weight:"bold"})})})]})})},vT="group list-none",bT=`
|
|
244
244
|
text-gray-400 flex items-center gap-x-2 border border-gray-150
|
|
245
245
|
h-10 px-5 rounded-full cursor-pointer transition-colors -outline-offset-2
|
|
246
|
-
|
|
247
|
-
hover:bg-primary
|
|
246
|
+
|
|
247
|
+
hover:bg-[color:var(--background,_theme(colors.primary.100))]
|
|
248
248
|
hover:text-base-white
|
|
249
249
|
hover:border-transparent
|
|
250
250
|
|
|
251
|
-
group-data-[active=true]:bg-primary
|
|
251
|
+
group-data-[active=true]:bg-[color:var(--background,_theme(colors.primary.100))]
|
|
252
252
|
group-data-[active=true]:text-base-white
|
|
253
253
|
group-data-[active=true]:border-transparent
|
|
254
|
-
`,wT="w-5 h-5",TT="text-sm font-medium leading-5 text-nowrap";function ET({filter:e,label:t,icon:n,iconBackgroundColor:r,iconFillColor:o,isActive:i,onSelectFilter:s}){const a=()=>{s&&s(e)};return v.jsx("li",{className:vT,"data-active":i,"data-testid":"filter-item","data-filter":e,children:v.jsxs("button",{onClick:a,className:bT,"data-testid":"filter-item-button",children:[r&&o?v.jsx(Is,{element:v.jsx(n,{}),backgroundColor:r,fillColor:o}):v.jsx(n,{className:wT,"data-testid":"filter-item-icon"}),v.jsx("p",{className:TT,"data-testid":"filter-item-label",children:t})]})})}function vt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e?.(o),n===!1||!o.defaultPrevented)return t?.(o)}}function sd(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ad(...e){return t=>{let n=!1;const r=e.map(o=>{const i=sd(o,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let o=0;o<r.length;o++){const i=r[o];typeof i=="function"?i():sd(e[o],null)}}}}function Ce(...e){return d.useCallback(ad(...e),e)}function xT(e,t){const n=d.createContext(t),r=i=>{const{children:s,...a}=i,c=d.useMemo(()=>a,Object.values(a));return v.jsx(n.Provider,{value:c,children:s})};r.displayName=e+"Provider";function o(i){const s=d.useContext(n);if(s)return s;if(t!==void 0)return t;throw new Error(`\`${i}\` must be used within \`${e}\``)}return[r,o]}function $i(e,t=[]){let n=[];function r(i,s){const a=d.createContext(s),c=n.length;n=[...n,s];const l=f=>{const{scope:h,children:p,...y}=f,m=h?.[e]?.[c]||a,g=d.useMemo(()=>y,Object.values(y));return v.jsx(m.Provider,{value:g,children:p})};l.displayName=i+"Provider";function u(f,h){const p=h?.[e]?.[c]||a,y=d.useContext(p);if(y)return y;if(s!==void 0)return s;throw new Error(`\`${f}\` must be used within \`${i}\``)}return[l,u]}const o=()=>{const i=n.map(s=>d.createContext(s));return function(a){const c=a?.[e]||i;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[r,ST(o,...t)]}function ST(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const s=r.reduce((a,{useScope:c,scopeName:l})=>{const f=c(i)[`__scope${l}`];return{...a,...f}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}var bt=globalThis?.document?d.useLayoutEffect:()=>{},AT=d[" useId ".trim().toString()]||(()=>{}),CT=0;function Ui(e){const[t,n]=d.useState(AT());return bt(()=>{n(r=>r??String(CT++))},[e]),e||(t?`radix-${t}`:"")}var PT=d[" useInsertionEffect ".trim().toString()]||bt;function cd({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,i,s]=MT({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:o;{const u=d.useRef(e!==void 0);d.useEffect(()=>{const f=u.current;f!==a&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),u.current=a},[a,r])}const l=d.useCallback(u=>{if(a){const f=DT(u)?u(e):u;f!==e&&s.current?.(f)}else i(u)},[a,e,i,s]);return[c,l]}function MT({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),i=d.useRef(t);return PT(()=>{i.current=t},[t]),d.useEffect(()=>{o.current!==n&&(i.current?.(n),o.current=n)},[n,o]),[n,r,i]}function DT(e){return typeof e=="function"}function Er(e){const t=OT(e),n=d.forwardRef((r,o)=>{const{children:i,...s}=r,a=d.Children.toArray(i),c=a.find(FT);if(c){const l=c.props.children,u=a.map(f=>f===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:f);return v.jsx(t,{...s,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,u):null})}return v.jsx(t,{...s,ref:o,children:i})});return n.displayName=`${e}.Slot`,n}function OT(e){const t=d.forwardRef((n,r)=>{const{children:o,...i}=n;if(d.isValidElement(o)){const s=IT(o),a=kT(i,o.props);return o.type!==d.Fragment&&(a.ref=r?ad(r,s):s),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var VT=Symbol("radix.slottable");function FT(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===VT}function kT(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...a)=>{const c=i(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}function IT(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var NT=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ge=NT.reduce((e,t)=>{const n=Er(`Primitive.${t}`),r=d.forwardRef((o,i)=>{const{asChild:s,...a}=o,c=s?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(c,{...a,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Wi(e,t){e&&ys.flushSync(()=>e.dispatchEvent(t))}function Le(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>t.current?.(...n),[])}function ld(e,t=globalThis?.document){const n=Le(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var LT="DismissableLayer",zi="dismissableLayer.update",RT="dismissableLayer.pointerDownOutside",_T="dismissableLayer.focusOutside",ud,dd=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),fd=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:s,onDismiss:a,...c}=e,l=d.useContext(dd),[u,f]=d.useState(null),h=u?.ownerDocument??globalThis?.document,[,p]=d.useState({}),y=Ce(t,A=>f(A)),m=Array.from(l.layers),[g]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),b=m.indexOf(g),x=u?m.indexOf(u):-1,T=l.layersWithOutsidePointerEventsDisabled.size>0,P=x>=b,w=$T(A=>{const M=A.target,N=[...l.branches].some(j=>j.contains(M));!P||N||(o?.(A),s?.(A),A.defaultPrevented||a?.())},h),C=UT(A=>{const M=A.target;[...l.branches].some(j=>j.contains(M))||(i?.(A),s?.(A),A.defaultPrevented||a?.())},h);return ld(A=>{x===l.layers.size-1&&(r?.(A),!A.defaultPrevented&&a&&(A.preventDefault(),a()))},h),d.useEffect(()=>{if(u)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(ud=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),hd(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=ud)}},[u,h,n,l]),d.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),hd())},[u,l]),d.useEffect(()=>{const A=()=>p({});return document.addEventListener(zi,A),()=>document.removeEventListener(zi,A)},[]),v.jsx(ge.div,{...c,ref:y,style:{pointerEvents:T?P?"auto":"none":void 0,...e.style},onFocusCapture:vt(e.onFocusCapture,C.onFocusCapture),onBlurCapture:vt(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:vt(e.onPointerDownCapture,w.onPointerDownCapture)})});fd.displayName=LT;var jT="DismissableLayerBranch",BT=d.forwardRef((e,t)=>{const n=d.useContext(dd),r=d.useRef(null),o=Ce(t,r);return d.useEffect(()=>{const i=r.current;if(i)return n.branches.add(i),()=>{n.branches.delete(i)}},[n.branches]),v.jsx(ge.div,{...e,ref:o})});BT.displayName=jT;function $T(e,t=globalThis?.document){const n=Le(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let c=function(){pd(RT,n,l,{discrete:!0})};const l={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function UT(e,t=globalThis?.document){const n=Le(e),r=d.useRef(!1);return d.useEffect(()=>{const o=i=>{i.target&&!r.current&&pd(_T,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function hd(){const e=new CustomEvent(zi);document.dispatchEvent(e)}function pd(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Wi(o,i):o.dispatchEvent(i)}var Zi="focusScope.autoFocusOnMount",Hi="focusScope.autoFocusOnUnmount",md={bubbles:!1,cancelable:!0},WT="FocusScope",gd=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...s}=e,[a,c]=d.useState(null),l=Le(o),u=Le(i),f=d.useRef(null),h=Ce(t,m=>c(m)),p=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let m=function(T){if(p.paused||!a)return;const P=T.target;a.contains(P)?f.current=P:wt(f.current,{select:!0})},g=function(T){if(p.paused||!a)return;const P=T.relatedTarget;P!==null&&(a.contains(P)||wt(f.current,{select:!0}))},b=function(T){if(document.activeElement===document.body)for(const w of T)w.removedNodes.length>0&&wt(a)};document.addEventListener("focusin",m),document.addEventListener("focusout",g);const x=new MutationObserver(b);return a&&x.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",g),x.disconnect()}}},[r,a,p.paused]),d.useEffect(()=>{if(a){bd.add(p);const m=document.activeElement;if(!a.contains(m)){const b=new CustomEvent(Zi,md);a.addEventListener(Zi,l),a.dispatchEvent(b),b.defaultPrevented||(zT(YT(yd(a)),{select:!0}),document.activeElement===m&&wt(a))}return()=>{a.removeEventListener(Zi,l),setTimeout(()=>{const b=new CustomEvent(Hi,md);a.addEventListener(Hi,u),a.dispatchEvent(b),b.defaultPrevented||wt(m??document.body,{select:!0}),a.removeEventListener(Hi,u),bd.remove(p)},0)}}},[a,l,u,p]);const y=d.useCallback(m=>{if(!n&&!r||p.paused)return;const g=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,b=document.activeElement;if(g&&b){const x=m.currentTarget,[T,P]=ZT(x);T&&P?!m.shiftKey&&b===P?(m.preventDefault(),n&&wt(T,{select:!0})):m.shiftKey&&b===T&&(m.preventDefault(),n&&wt(P,{select:!0})):b===x&&m.preventDefault()}},[n,r,p.paused]);return v.jsx(ge.div,{tabIndex:-1,...s,ref:h,onKeyDown:y})});gd.displayName=WT;function zT(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(wt(r,{select:t}),document.activeElement!==n)return}function ZT(e){const t=yd(e),n=vd(t,e),r=vd(t.reverse(),e);return[n,r]}function yd(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function vd(e,t){for(const n of e)if(!HT(n,{upTo:t}))return n}function HT(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function KT(e){return e instanceof HTMLInputElement&&"select"in e}function wt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&KT(e)&&t&&e.select()}}var bd=GT();function GT(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=wd(e,t),e.unshift(t)},remove(t){e=wd(e,t),e[0]?.resume()}}}function wd(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function YT(e){return e.filter(t=>t.tagName!=="A")}var XT="Portal",Ki=d.forwardRef((e,t)=>{const{container:n,...r}=e,[o,i]=d.useState(!1);bt(()=>i(!0),[]);const s=n||o&&globalThis?.document?.body;return s?ms.createPortal(v.jsx(ge.div,{...r,ref:t}),s):null});Ki.displayName=XT;function qT(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var xr=e=>{const{present:t,children:n}=e,r=QT(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),i=Ce(r.ref,JT(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:i}):null};xr.displayName="Presence";function QT(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),i=d.useRef("none"),s=e?"mounted":"unmounted",[a,c]=qT(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=Sr(r.current);i.current=a==="mounted"?l:"none"},[a]),bt(()=>{const l=r.current,u=o.current;if(u!==e){const h=i.current,p=Sr(l);e?c("MOUNT"):p==="none"||l?.display==="none"?c("UNMOUNT"):c(u&&h!==p?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),bt(()=>{if(t){let l;const u=t.ownerDocument.defaultView??window,f=p=>{const m=Sr(r.current).includes(p.animationName);if(p.target===t&&m&&(c("ANIMATION_END"),!o.current)){const g=t.style.animationFillMode;t.style.animationFillMode="forwards",l=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=g)})}},h=p=>{p.target===t&&(i.current=Sr(r.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{u.clearTimeout(l),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(l=>{r.current=l?getComputedStyle(l):null,n(l)},[])}}function Sr(e){return e?.animationName||"none"}function JT(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Gi=0;function eE(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Td()),document.body.insertAdjacentElement("beforeend",e[1]??Td()),Gi++,()=>{Gi===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Gi--}},[])}function Td(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var He=function(){return He=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},He.apply(this,arguments)};function Ed(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function tE(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Ar="right-scroll-bar-position",Cr="width-before-scroll-bar",nE="with-scroll-bars-hidden",rE="--removed-body-scroll-bar-size";function Yi(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function oE(e,t){var n=E.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var iE=typeof window<"u"?d.useLayoutEffect:d.useEffect,xd=new WeakMap;function sE(e,t){var n=oE(null,function(r){return e.forEach(function(o){return Yi(o,r)})});return iE(function(){var r=xd.get(n);if(r){var o=new Set(r),i=new Set(e),s=n.current;o.forEach(function(a){i.has(a)||Yi(a,null)}),i.forEach(function(a){o.has(a)||Yi(a,s)})}xd.set(n,e)},[e]),n}function aE(e){return e}function cE(e,t){t===void 0&&(t=aE);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(i){var s=t(i,r);return n.push(s),function(){n=n.filter(function(a){return a!==s})}},assignSyncMedium:function(i){for(r=!0;n.length;){var s=n;n=[],s.forEach(i)}n={push:function(a){return i(a)},filter:function(){return n}}},assignMedium:function(i){r=!0;var s=[];if(n.length){var a=n;n=[],a.forEach(i),s=n}var c=function(){var u=s;s=[],u.forEach(i)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(u){s.push(u),l()},filter:function(u){return s=s.filter(u),n}}}};return o}function lE(e){e===void 0&&(e={});var t=cE(null);return t.options=He({async:!0,ssr:!1},e),t}var Sd=function(e){var t=e.sideCar,n=Ed(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,He({},n))};Sd.isSideCarExport=!0;function uE(e,t){return e.useMedium(t),Sd}var Ad=lE(),Xi=function(){},Pr=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Xi,onWheelCapture:Xi,onTouchMoveCapture:Xi}),o=r[0],i=r[1],s=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,f=e.shards,h=e.sideCar,p=e.noIsolation,y=e.inert,m=e.allowPinchZoom,g=e.as,b=g===void 0?"div":g,x=e.gapMode,T=Ed(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=h,w=sE([n,t]),C=He(He({},T),o);return d.createElement(d.Fragment,null,u&&d.createElement(P,{sideCar:Ad,removeScrollBar:l,shards:f,noIsolation:p,inert:y,setCallbacks:i,allowPinchZoom:!!m,lockRef:n,gapMode:x}),s?d.cloneElement(d.Children.only(a),He(He({},C),{ref:w})):d.createElement(b,He({},C,{className:c,ref:w}),a))});Pr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Pr.classNames={fullWidth:Cr,zeroRight:Ar};var dE=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function fE(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=dE();return t&&e.setAttribute("nonce",t),e}function hE(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function pE(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var mE=function(){var e=0,t=null;return{add:function(n){e==0&&(t=fE())&&(hE(t,n),pE(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},gE=function(){var e=mE();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Cd=function(){var e=gE(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},yE={left:0,top:0,right:0,gap:0},qi=function(e){return parseInt(e||"",10)||0},vE=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[qi(n),qi(r),qi(o)]},bE=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return yE;var t=vE(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},wE=Cd(),un="data-scroll-locked",TE=function(e,t,n,r){var o=e.left,i=e.top,s=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
254
|
+
`,wT="w-5 h-5",TT="text-sm font-medium leading-5 text-nowrap";function ET({filter:e,label:t,icon:n,iconBackgroundColor:r,iconFillColor:o,isActive:i,onSelectFilter:s}){const a=()=>{s&&s(e)};return v.jsx("li",{className:vT,"data-active":i,"data-testid":"filter-item","data-filter":e,children:v.jsxs("button",{onClick:a,className:bT,"data-testid":"filter-item-button",style:o?{"--background":o}:void 0,children:[r&&o?v.jsx(Is,{element:v.jsx(n,{}),backgroundColor:r,fillColor:o}):v.jsx(n,{className:wT,"data-testid":"filter-item-icon"}),v.jsx("p",{className:TT,"data-testid":"filter-item-label",children:t})]})})}function vt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e?.(o),n===!1||!o.defaultPrevented)return t?.(o)}}function sd(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ad(...e){return t=>{let n=!1;const r=e.map(o=>{const i=sd(o,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let o=0;o<r.length;o++){const i=r[o];typeof i=="function"?i():sd(e[o],null)}}}}function Ce(...e){return d.useCallback(ad(...e),e)}function xT(e,t){const n=d.createContext(t),r=i=>{const{children:s,...a}=i,c=d.useMemo(()=>a,Object.values(a));return v.jsx(n.Provider,{value:c,children:s})};r.displayName=e+"Provider";function o(i){const s=d.useContext(n);if(s)return s;if(t!==void 0)return t;throw new Error(`\`${i}\` must be used within \`${e}\``)}return[r,o]}function $i(e,t=[]){let n=[];function r(i,s){const a=d.createContext(s),c=n.length;n=[...n,s];const l=f=>{const{scope:h,children:p,...y}=f,m=h?.[e]?.[c]||a,g=d.useMemo(()=>y,Object.values(y));return v.jsx(m.Provider,{value:g,children:p})};l.displayName=i+"Provider";function u(f,h){const p=h?.[e]?.[c]||a,y=d.useContext(p);if(y)return y;if(s!==void 0)return s;throw new Error(`\`${f}\` must be used within \`${i}\``)}return[l,u]}const o=()=>{const i=n.map(s=>d.createContext(s));return function(a){const c=a?.[e]||i;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[r,ST(o,...t)]}function ST(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const s=r.reduce((a,{useScope:c,scopeName:l})=>{const f=c(i)[`__scope${l}`];return{...a,...f}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}var bt=globalThis?.document?d.useLayoutEffect:()=>{},AT=d[" useId ".trim().toString()]||(()=>{}),CT=0;function Ui(e){const[t,n]=d.useState(AT());return bt(()=>{n(r=>r??String(CT++))},[e]),e||(t?`radix-${t}`:"")}var PT=d[" useInsertionEffect ".trim().toString()]||bt;function cd({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,i,s]=MT({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:o;{const u=d.useRef(e!==void 0);d.useEffect(()=>{const f=u.current;f!==a&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),u.current=a},[a,r])}const l=d.useCallback(u=>{if(a){const f=DT(u)?u(e):u;f!==e&&s.current?.(f)}else i(u)},[a,e,i,s]);return[c,l]}function MT({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),i=d.useRef(t);return PT(()=>{i.current=t},[t]),d.useEffect(()=>{o.current!==n&&(i.current?.(n),o.current=n)},[n,o]),[n,r,i]}function DT(e){return typeof e=="function"}function Er(e){const t=OT(e),n=d.forwardRef((r,o)=>{const{children:i,...s}=r,a=d.Children.toArray(i),c=a.find(FT);if(c){const l=c.props.children,u=a.map(f=>f===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:f);return v.jsx(t,{...s,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,u):null})}return v.jsx(t,{...s,ref:o,children:i})});return n.displayName=`${e}.Slot`,n}function OT(e){const t=d.forwardRef((n,r)=>{const{children:o,...i}=n;if(d.isValidElement(o)){const s=IT(o),a=kT(i,o.props);return o.type!==d.Fragment&&(a.ref=r?ad(r,s):s),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var VT=Symbol("radix.slottable");function FT(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===VT}function kT(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...a)=>{const c=i(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}function IT(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var NT=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ge=NT.reduce((e,t)=>{const n=Er(`Primitive.${t}`),r=d.forwardRef((o,i)=>{const{asChild:s,...a}=o,c=s?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(c,{...a,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Wi(e,t){e&&ys.flushSync(()=>e.dispatchEvent(t))}function Le(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>t.current?.(...n),[])}function ld(e,t=globalThis?.document){const n=Le(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var LT="DismissableLayer",zi="dismissableLayer.update",RT="dismissableLayer.pointerDownOutside",_T="dismissableLayer.focusOutside",ud,dd=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),fd=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:s,onDismiss:a,...c}=e,l=d.useContext(dd),[u,f]=d.useState(null),h=u?.ownerDocument??globalThis?.document,[,p]=d.useState({}),y=Ce(t,A=>f(A)),m=Array.from(l.layers),[g]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),b=m.indexOf(g),x=u?m.indexOf(u):-1,T=l.layersWithOutsidePointerEventsDisabled.size>0,P=x>=b,w=$T(A=>{const M=A.target,N=[...l.branches].some(j=>j.contains(M));!P||N||(o?.(A),s?.(A),A.defaultPrevented||a?.())},h),C=UT(A=>{const M=A.target;[...l.branches].some(j=>j.contains(M))||(i?.(A),s?.(A),A.defaultPrevented||a?.())},h);return ld(A=>{x===l.layers.size-1&&(r?.(A),!A.defaultPrevented&&a&&(A.preventDefault(),a()))},h),d.useEffect(()=>{if(u)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(ud=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),hd(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=ud)}},[u,h,n,l]),d.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),hd())},[u,l]),d.useEffect(()=>{const A=()=>p({});return document.addEventListener(zi,A),()=>document.removeEventListener(zi,A)},[]),v.jsx(ge.div,{...c,ref:y,style:{pointerEvents:T?P?"auto":"none":void 0,...e.style},onFocusCapture:vt(e.onFocusCapture,C.onFocusCapture),onBlurCapture:vt(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:vt(e.onPointerDownCapture,w.onPointerDownCapture)})});fd.displayName=LT;var jT="DismissableLayerBranch",BT=d.forwardRef((e,t)=>{const n=d.useContext(dd),r=d.useRef(null),o=Ce(t,r);return d.useEffect(()=>{const i=r.current;if(i)return n.branches.add(i),()=>{n.branches.delete(i)}},[n.branches]),v.jsx(ge.div,{...e,ref:o})});BT.displayName=jT;function $T(e,t=globalThis?.document){const n=Le(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let c=function(){pd(RT,n,l,{discrete:!0})};const l={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function UT(e,t=globalThis?.document){const n=Le(e),r=d.useRef(!1);return d.useEffect(()=>{const o=i=>{i.target&&!r.current&&pd(_T,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function hd(){const e=new CustomEvent(zi);document.dispatchEvent(e)}function pd(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Wi(o,i):o.dispatchEvent(i)}var Zi="focusScope.autoFocusOnMount",Hi="focusScope.autoFocusOnUnmount",md={bubbles:!1,cancelable:!0},WT="FocusScope",gd=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...s}=e,[a,c]=d.useState(null),l=Le(o),u=Le(i),f=d.useRef(null),h=Ce(t,m=>c(m)),p=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let m=function(T){if(p.paused||!a)return;const P=T.target;a.contains(P)?f.current=P:wt(f.current,{select:!0})},g=function(T){if(p.paused||!a)return;const P=T.relatedTarget;P!==null&&(a.contains(P)||wt(f.current,{select:!0}))},b=function(T){if(document.activeElement===document.body)for(const w of T)w.removedNodes.length>0&&wt(a)};document.addEventListener("focusin",m),document.addEventListener("focusout",g);const x=new MutationObserver(b);return a&&x.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",g),x.disconnect()}}},[r,a,p.paused]),d.useEffect(()=>{if(a){bd.add(p);const m=document.activeElement;if(!a.contains(m)){const b=new CustomEvent(Zi,md);a.addEventListener(Zi,l),a.dispatchEvent(b),b.defaultPrevented||(zT(YT(yd(a)),{select:!0}),document.activeElement===m&&wt(a))}return()=>{a.removeEventListener(Zi,l),setTimeout(()=>{const b=new CustomEvent(Hi,md);a.addEventListener(Hi,u),a.dispatchEvent(b),b.defaultPrevented||wt(m??document.body,{select:!0}),a.removeEventListener(Hi,u),bd.remove(p)},0)}}},[a,l,u,p]);const y=d.useCallback(m=>{if(!n&&!r||p.paused)return;const g=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,b=document.activeElement;if(g&&b){const x=m.currentTarget,[T,P]=ZT(x);T&&P?!m.shiftKey&&b===P?(m.preventDefault(),n&&wt(T,{select:!0})):m.shiftKey&&b===T&&(m.preventDefault(),n&&wt(P,{select:!0})):b===x&&m.preventDefault()}},[n,r,p.paused]);return v.jsx(ge.div,{tabIndex:-1,...s,ref:h,onKeyDown:y})});gd.displayName=WT;function zT(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(wt(r,{select:t}),document.activeElement!==n)return}function ZT(e){const t=yd(e),n=vd(t,e),r=vd(t.reverse(),e);return[n,r]}function yd(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function vd(e,t){for(const n of e)if(!HT(n,{upTo:t}))return n}function HT(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function KT(e){return e instanceof HTMLInputElement&&"select"in e}function wt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&KT(e)&&t&&e.select()}}var bd=GT();function GT(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=wd(e,t),e.unshift(t)},remove(t){e=wd(e,t),e[0]?.resume()}}}function wd(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function YT(e){return e.filter(t=>t.tagName!=="A")}var XT="Portal",Ki=d.forwardRef((e,t)=>{const{container:n,...r}=e,[o,i]=d.useState(!1);bt(()=>i(!0),[]);const s=n||o&&globalThis?.document?.body;return s?ms.createPortal(v.jsx(ge.div,{...r,ref:t}),s):null});Ki.displayName=XT;function qT(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var xr=e=>{const{present:t,children:n}=e,r=QT(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),i=Ce(r.ref,JT(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:i}):null};xr.displayName="Presence";function QT(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),i=d.useRef("none"),s=e?"mounted":"unmounted",[a,c]=qT(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=Sr(r.current);i.current=a==="mounted"?l:"none"},[a]),bt(()=>{const l=r.current,u=o.current;if(u!==e){const h=i.current,p=Sr(l);e?c("MOUNT"):p==="none"||l?.display==="none"?c("UNMOUNT"):c(u&&h!==p?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),bt(()=>{if(t){let l;const u=t.ownerDocument.defaultView??window,f=p=>{const m=Sr(r.current).includes(p.animationName);if(p.target===t&&m&&(c("ANIMATION_END"),!o.current)){const g=t.style.animationFillMode;t.style.animationFillMode="forwards",l=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=g)})}},h=p=>{p.target===t&&(i.current=Sr(r.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{u.clearTimeout(l),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(l=>{r.current=l?getComputedStyle(l):null,n(l)},[])}}function Sr(e){return e?.animationName||"none"}function JT(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Gi=0;function eE(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Td()),document.body.insertAdjacentElement("beforeend",e[1]??Td()),Gi++,()=>{Gi===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Gi--}},[])}function Td(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var He=function(){return He=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},He.apply(this,arguments)};function Ed(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function tE(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Ar="right-scroll-bar-position",Cr="width-before-scroll-bar",nE="with-scroll-bars-hidden",rE="--removed-body-scroll-bar-size";function Yi(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function oE(e,t){var n=E.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var iE=typeof window<"u"?d.useLayoutEffect:d.useEffect,xd=new WeakMap;function sE(e,t){var n=oE(null,function(r){return e.forEach(function(o){return Yi(o,r)})});return iE(function(){var r=xd.get(n);if(r){var o=new Set(r),i=new Set(e),s=n.current;o.forEach(function(a){i.has(a)||Yi(a,null)}),i.forEach(function(a){o.has(a)||Yi(a,s)})}xd.set(n,e)},[e]),n}function aE(e){return e}function cE(e,t){t===void 0&&(t=aE);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(i){var s=t(i,r);return n.push(s),function(){n=n.filter(function(a){return a!==s})}},assignSyncMedium:function(i){for(r=!0;n.length;){var s=n;n=[],s.forEach(i)}n={push:function(a){return i(a)},filter:function(){return n}}},assignMedium:function(i){r=!0;var s=[];if(n.length){var a=n;n=[],a.forEach(i),s=n}var c=function(){var u=s;s=[],u.forEach(i)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(u){s.push(u),l()},filter:function(u){return s=s.filter(u),n}}}};return o}function lE(e){e===void 0&&(e={});var t=cE(null);return t.options=He({async:!0,ssr:!1},e),t}var Sd=function(e){var t=e.sideCar,n=Ed(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,He({},n))};Sd.isSideCarExport=!0;function uE(e,t){return e.useMedium(t),Sd}var Ad=lE(),Xi=function(){},Pr=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Xi,onWheelCapture:Xi,onTouchMoveCapture:Xi}),o=r[0],i=r[1],s=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,f=e.shards,h=e.sideCar,p=e.noIsolation,y=e.inert,m=e.allowPinchZoom,g=e.as,b=g===void 0?"div":g,x=e.gapMode,T=Ed(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=h,w=sE([n,t]),C=He(He({},T),o);return d.createElement(d.Fragment,null,u&&d.createElement(P,{sideCar:Ad,removeScrollBar:l,shards:f,noIsolation:p,inert:y,setCallbacks:i,allowPinchZoom:!!m,lockRef:n,gapMode:x}),s?d.cloneElement(d.Children.only(a),He(He({},C),{ref:w})):d.createElement(b,He({},C,{className:c,ref:w}),a))});Pr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Pr.classNames={fullWidth:Cr,zeroRight:Ar};var dE=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function fE(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=dE();return t&&e.setAttribute("nonce",t),e}function hE(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function pE(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var mE=function(){var e=0,t=null;return{add:function(n){e==0&&(t=fE())&&(hE(t,n),pE(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},gE=function(){var e=mE();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Cd=function(){var e=gE(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},yE={left:0,top:0,right:0,gap:0},qi=function(e){return parseInt(e||"",10)||0},vE=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[qi(n),qi(r),qi(o)]},bE=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return yE;var t=vE(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},wE=Cd(),un="data-scroll-locked",TE=function(e,t,n,r){var o=e.left,i=e.top,s=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
255
255
|
.`.concat(nE,` {
|
|
256
256
|
overflow: hidden `).concat(r,`;
|
|
257
257
|
padding-right: `).concat(a,"px ").concat(r,`;
|