@tscircuit/runframe 0.0.146 → 0.0.148

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.
@@ -908,7 +908,8 @@ var CircuitJsonPreview = ({
908
908
  hasCodeChangedSinceLastRun,
909
909
  onEditEvent,
910
910
  editEvents,
911
- defaultActiveTab
911
+ defaultActiveTab,
912
+ autoRotate3dViewerDisabled
912
913
  }) => {
913
914
  useStyles();
914
915
  const [activeTab, setActiveTabState] = useState4(defaultActiveTab ?? "pcb");
@@ -1100,7 +1101,13 @@ var CircuitJsonPreview = ({
1100
1101
  "rf-overflow-auto",
1101
1102
  isFullScreen ? "rf-h-[calc(100vh-96px)]" : "rf-h-[620px]"
1102
1103
  ),
1103
- children: /* @__PURE__ */ jsx15(ErrorBoundary, { FallbackComponent: ErrorFallback, children: circuitJson ? /* @__PURE__ */ jsx15(CadViewer, { soup: circuitJson }) : /* @__PURE__ */ jsx15(PreviewEmptyState_default, { onRunClicked }) })
1104
+ children: /* @__PURE__ */ jsx15(ErrorBoundary, { FallbackComponent: ErrorFallback, children: circuitJson ? /* @__PURE__ */ jsx15(
1105
+ CadViewer,
1106
+ {
1107
+ soup: circuitJson,
1108
+ autoRotateDisabled: autoRotate3dViewerDisabled
1109
+ }
1110
+ ) : /* @__PURE__ */ jsx15(PreviewEmptyState_default, { onRunClicked }) })
1104
1111
  }
1105
1112
  ) }),
1106
1113
  /* @__PURE__ */ jsx15(TabsContent, { value: "bom", children: /* @__PURE__ */ jsx15(
package/dist/preview.d.ts CHANGED
@@ -49,7 +49,8 @@ interface PreviewContentProps {
49
49
  onEditEvent?: (editEvent: ManualEditEvent) => void;
50
50
  editEvents?: ManualEditEvent[];
51
51
  onActiveTabChange?: (tab: TabId) => any;
52
+ autoRotate3dViewerDisabled?: boolean;
52
53
  }
53
- declare const CircuitJsonPreview: ({ code, onRunClicked, errorMessage, circuitJsonKey, circuitJson, showCodeTab, codeTabContent, showJsonTab, showRenderLogTab, onActiveTabChange, renderLog, showImportAndFormatButtons, className, headerClassName, leftHeaderContent, readOnly, isStreaming, onToggleFullScreen, isFullScreen, isRunningCode, hasCodeChangedSinceLastRun, onEditEvent, editEvents, defaultActiveTab, }: PreviewContentProps) => react_jsx_runtime.JSX.Element;
54
+ declare const CircuitJsonPreview: ({ code, onRunClicked, errorMessage, circuitJsonKey, circuitJson, showCodeTab, codeTabContent, showJsonTab, showRenderLogTab, onActiveTabChange, renderLog, showImportAndFormatButtons, className, headerClassName, leftHeaderContent, readOnly, isStreaming, onToggleFullScreen, isFullScreen, isRunningCode, hasCodeChangedSinceLastRun, onEditEvent, editEvents, defaultActiveTab, autoRotate3dViewerDisabled, }: PreviewContentProps) => react_jsx_runtime.JSX.Element;
54
55
 
55
56
  export { CircuitJsonPreview, type PreviewContentProps, type TabId };
package/dist/preview.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  CircuitJsonPreview
3
- } from "./chunk-RZZLPP7I.js";
3
+ } from "./chunk-2CEQQKA2.js";
4
4
  export {
5
5
  CircuitJsonPreview
6
6
  };
package/dist/runner.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  Button,
3
3
  CircuitJsonPreview
4
- } from "./chunk-RZZLPP7I.js";
4
+ } from "./chunk-2CEQQKA2.js";
5
5
 
6
6
  // lib/components/RunFrame.tsx
7
7
  import { createCircuitWebWorker } from "@tscircuit/eval-webworker";
@@ -13122,7 +13122,7 @@ searched component ${l.getString()}, which has ports: ${l.children.filter(c=>c.c
13122
13122
  `)},sit=function(){var r=parseInt(document.body.getAttribute(Hw)||"0",10);return isFinite(r)?r:0},upn=function(){Ct.useEffect(function(){return document.body.setAttribute(Hw,(sit()+1).toString()),function(){var r=sit()-1;r<=0?document.body.removeAttribute(Hw):document.body.setAttribute(Hw,r.toString())}},[])},fpn=function(r){var e=r.noRelative,t=r.noImportant,n=r.gapMode,i=n===void 0?"margin":n;upn();var a=Ct.useMemo(function(){return spn(i)},[i]);return Ct.createElement(lpn,{styles:cpn(a,!e,i,t?"":"!important")})};function dpn(){if(!document)return null;var r=document.createElement("style");r.type="text/css";var e=oit();return e&&r.setAttribute("nonce",e),r}function ppn(r,e){r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}function hpn(r){var e=document.head||document.getElementsByTagName("head")[0];e.appendChild(r)}var mpn=function(){var r=0,e=null;return{add:function(t){r==0&&(e=dpn())&&(ppn(e,t),hpn(e)),r++},remove:function(){r--,!r&&e&&(e.parentNode&&e.parentNode.removeChild(e),e=null)}}},vpn=function(){var r=mpn();return function(e,t){Ct.useEffect(function(){return r.add(e),function(){r.remove()}},[e&&t])}},ypn=function(){var r=vpn(),e=function(t){var n=t.styles,i=t.dynamic;return r(n,i),null};return e},Ape=!1;if(typeof window<"u")try{var LF=Object.defineProperty({},"passive",{get:function(){return Ape=!0,!0}});window.addEventListener("test",LF,LF),window.removeEventListener("test",LF,LF)}catch{Ape=!1}var qw=Ape?{passive:!1}:!1,gpn=function(r){return r.tagName==="TEXTAREA"},lit=function(r,e){if(!(r instanceof Element))return!1;var t=window.getComputedStyle(r);return t[e]!=="hidden"&&!(t.overflowY===t.overflowX&&!gpn(r)&&t[e]==="visible")},_pn=function(r){return lit(r,"overflowY")},xpn=function(r){return lit(r,"overflowX")},cit=function(r,e){var t=e.ownerDocument,n=e;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var i=uit(r,n);if(i){var a=fit(r,n),o=a[1],s=a[2];if(o>s)return!0}n=n.parentNode}while(n&&n!==t.body);return!1},bpn=function(r){var e=r.scrollTop,t=r.scrollHeight,n=r.clientHeight;return[e,t,n]},Spn=function(r){var e=r.scrollLeft,t=r.scrollWidth,n=r.clientWidth;return[e,t,n]},uit=function(r,e){return r==="v"?_pn(e):xpn(e)},fit=function(r,e){return r==="v"?bpn(e):Spn(e)},Epn=function(r,e){return r==="h"&&e==="rtl"?-1:1},wpn=function(r,e,t,n,i){var a=Epn(r,window.getComputedStyle(e).direction),o=a*n,s=t.target,l=e.contains(s),c=!1,u=o>0,f=0,h=0;do{var v=fit(r,s),x=v[0],E=v[1],S=v[2],b=E-S-a*x;(x||b)&&uit(r,s)&&(f+=b,h+=x),s instanceof ShadowRoot?s=s.host:s=s.parentNode}while(!l&&s!==document.body||l&&(e.contains(s)||e===s));return(u&&(Math.abs(f)<1||!i)||!u&&(Math.abs(h)<1||!i))&&(c=!0),c},zF=function(r){return"changedTouches"in r?[r.changedTouches[0].clientX,r.changedTouches[0].clientY]:[0,0]},dit=function(r){return[r.deltaX,r.deltaY]},pit=function(r){return r&&"current"in r?r.current:r},Tpn=function(r,e){return r[0]===e[0]&&r[1]===e[1]},Mpn=function(r){return`
13123
13123
  .block-interactivity-`.concat(r,` {pointer-events: none;}
13124
13124
  .allow-interactivity-`).concat(r,` {pointer-events: all;}
13125
- `)},Cpn=0,$w=[];function Rpn(r){var e=Ct.useRef([]),t=Ct.useRef([0,0]),n=Ct.useRef(),i=Ct.useState(Cpn++)[0],a=Ct.useState(ypn)[0],o=Ct.useRef(r);Ct.useEffect(function(){o.current=r},[r]),Ct.useEffect(function(){if(r.inert){document.body.classList.add("block-interactivity-".concat(i));var E=Hdn([r.lockRef.current],(r.shards||[]).map(pit),!0).filter(Boolean);return E.forEach(function(S){return S.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),E.forEach(function(S){return S.classList.remove("allow-interactivity-".concat(i))})}}},[r.inert,r.lockRef.current,r.shards]);var s=Ct.useCallback(function(E,S){if("touches"in E&&E.touches.length===2||E.type==="wheel"&&E.ctrlKey)return!o.current.allowPinchZoom;var b=zF(E),C=t.current,N="deltaX"in E?E.deltaX:C[0]-b[0],U="deltaY"in E?E.deltaY:C[1]-b[1],G,Z=E.target,$=Math.abs(N)>Math.abs(U)?"h":"v";if("touches"in E&&$==="h"&&Z.type==="range")return!1;var te=cit($,Z);if(!te)return!0;if(te?G=$:(G=$==="v"?"h":"v",te=cit($,Z)),!te)return!1;if(!n.current&&"changedTouches"in E&&(N||U)&&(n.current=G),!G)return!0;var re=n.current||G;return wpn(re,S,E,re==="h"?N:U,!0)},[]),l=Ct.useCallback(function(E){var S=E;if(!(!$w.length||$w[$w.length-1]!==a)){var b="deltaY"in S?dit(S):zF(S),C=e.current.filter(function(G){return G.name===S.type&&(G.target===S.target||S.target===G.shadowParent)&&Tpn(G.delta,b)})[0];if(C&&C.should){S.cancelable&&S.preventDefault();return}if(!C){var N=(o.current.shards||[]).map(pit).filter(Boolean).filter(function(G){return G.contains(S.target)}),U=N.length>0?s(S,N[0]):!o.current.noIsolation;U&&S.cancelable&&S.preventDefault()}}},[]),c=Ct.useCallback(function(E,S,b,C){var N={name:E,delta:S,target:b,should:C,shadowParent:Apn(b)};e.current.push(N),setTimeout(function(){e.current=e.current.filter(function(U){return U!==N})},1)},[]),u=Ct.useCallback(function(E){t.current=zF(E),n.current=void 0},[]),f=Ct.useCallback(function(E){c(E.type,dit(E),E.target,s(E,r.lockRef.current))},[]),h=Ct.useCallback(function(E){c(E.type,zF(E),E.target,s(E,r.lockRef.current))},[]);Ct.useEffect(function(){return $w.push(a),r.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:h}),document.addEventListener("wheel",l,qw),document.addEventListener("touchmove",l,qw),document.addEventListener("touchstart",u,qw),function(){$w=$w.filter(function(E){return E!==a}),document.removeEventListener("wheel",l,qw),document.removeEventListener("touchmove",l,qw),document.removeEventListener("touchstart",u,qw)}},[]);var v=r.removeScrollBar,x=r.inert;return Ct.createElement(Ct.Fragment,null,x?Ct.createElement(a,{styles:Mpn(i)}):null,v?Ct.createElement(fpn,{gapMode:r.gapMode}):null)}function Apn(r){for(var e=null;r!==null;)r instanceof ShadowRoot&&(e=r.host,r=r.host),r=r.parentNode;return e}const Ppn=Kdn(ait,Rpn);var hit=Ct.forwardRef(function(r,e){return Ct.createElement(NF,Hb({},r,{ref:e,sideCar:Ppn}))});hit.classNames=NF.classNames;var Ppe=["Enter"," "],Dpn=["ArrowDown","PageUp","Home"],mit=["ArrowUp","PageDown","End"],Npn=[...Dpn,...mit],Lpn={ltr:[...Ppe,"ArrowRight"],rtl:[...Ppe,"ArrowLeft"]},zpn={ltr:["ArrowLeft"],rtl:["ArrowRight"]},HR="Menu",[qR,Opn,Upn]=fme(HR),[v7,vit]=M7(HR,[Upn,$rt,SA]),OF=$rt(),yit=SA(),[kpn,y7]=v7(HR),[Fpn,$R]=v7(HR),git=r=>{const{__scopeMenu:e,open:t=!1,children:n,dir:i,onOpenChange:a,modal:o=!0}=r,s=OF(e),[l,c]=Ct.useState(null),u=Ct.useRef(!1),f=D4(a),h=CI(i);return Ct.useEffect(()=>{const v=()=>{u.current=!0,document.addEventListener("pointerdown",x,{capture:!0,once:!0}),document.addEventListener("pointermove",x,{capture:!0,once:!0})},x=()=>u.current=!1;return document.addEventListener("keydown",v,{capture:!0}),()=>{document.removeEventListener("keydown",v,{capture:!0}),document.removeEventListener("pointerdown",x,{capture:!0}),document.removeEventListener("pointermove",x,{capture:!0})}},[]),_t.jsx(zdn,{...s,children:_t.jsx(kpn,{scope:e,open:t,onOpenChange:f,content:l,onContentChange:c,children:_t.jsx(Fpn,{scope:e,onClose:Ct.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:u,dir:h,modal:o,children:n})})})};git.displayName=HR;var Ipn="MenuAnchor",Dpe=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r,i=OF(t);return _t.jsx(Odn,{...i,...n,ref:e})});Dpe.displayName=Ipn;var Npe="MenuPortal",[Bpn,_it]=v7(Npe,{forceMount:void 0}),xit=r=>{const{__scopeMenu:e,forceMount:t,children:n,container:i}=r,a=y7(Npe,e);return _t.jsx(Bpn,{scope:e,forceMount:t,children:_t.jsx(A7,{present:t||a.open,children:_t.jsx(eit,{asChild:!0,container:i,children:n})})})};xit.displayName=Npe;var b4="MenuContent",[jpn,Lpe]=v7(b4),bit=Ct.forwardRef((r,e)=>{const t=_it(b4,r.__scopeMenu),{forceMount:n=t.forceMount,...i}=r,a=y7(b4,r.__scopeMenu),o=$R(b4,r.__scopeMenu);return _t.jsx(qR.Provider,{scope:r.__scopeMenu,children:_t.jsx(A7,{present:n||a.open,children:_t.jsx(qR.Slot,{scope:r.__scopeMenu,children:o.modal?_t.jsx(Vpn,{...i,ref:e}):_t.jsx(Hpn,{...i,ref:e})})})})}),Vpn=Ct.forwardRef((r,e)=>{const t=y7(b4,r.__scopeMenu),n=Ct.useRef(null),i=x3(e,n);return Ct.useEffect(()=>{const a=n.current;if(a)return Vdn(a)},[]),_t.jsx(zpe,{...r,ref:i,trapFocus:t.open,disableOutsidePointerEvents:t.open,disableOutsideScroll:!0,onFocusOutside:Fm(r.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>t.onOpenChange(!1)})}),Hpn=Ct.forwardRef((r,e)=>{const t=y7(b4,r.__scopeMenu);return _t.jsx(zpe,{...r,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>t.onOpenChange(!1)})}),zpe=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,loop:n=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:l,onEscapeKeyDown:c,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:h,onDismiss:v,disableOutsideScroll:x,...E}=r,S=y7(b4,t),b=$R(b4,t),C=OF(t),N=yit(t),U=Opn(t),[G,Z]=Ct.useState(null),$=Ct.useRef(null),te=x3(e,$,S.onContentChange),re=Ct.useRef(0),se=Ct.useRef(""),fe=Ct.useRef(0),de=Ct.useRef(null),ye=Ct.useRef("right"),Se=Ct.useRef(0),Re=x?hit:Ct.Fragment,Te=x?{as:C7,allowPinchZoom:!0}:void 0,Ce=Fe=>{var dt,kt;const Ie=se.current+Fe,ke=U().filter(qt=>!qt.disabled),Ee=document.activeElement,$e=(dt=ke.find(qt=>qt.ref.current===Ee))==null?void 0:dt.textValue,tt=ke.map(qt=>qt.textValue),ut=thn(tt,Ie,$e),gt=(kt=ke.find(qt=>qt.textValue===ut))==null?void 0:kt.ref.current;(function qt(Dn){se.current=Dn,window.clearTimeout(re.current),Dn!==""&&(re.current=window.setTimeout(()=>qt(""),1e3))})(Ie),gt&&setTimeout(()=>gt.focus())};Ct.useEffect(()=>()=>window.clearTimeout(re.current),[]),xfn();const Me=Ct.useCallback(Fe=>{var ke,Ee;return ye.current===((ke=de.current)==null?void 0:ke.side)&&rhn(Fe,(Ee=de.current)==null?void 0:Ee.area)},[]);return _t.jsx(jpn,{scope:t,searchRef:se,onItemEnter:Ct.useCallback(Fe=>{Me(Fe)&&Fe.preventDefault()},[Me]),onItemLeave:Ct.useCallback(Fe=>{var Ie;Me(Fe)||((Ie=$.current)==null||Ie.focus(),Z(null))},[Me]),onTriggerLeave:Ct.useCallback(Fe=>{Me(Fe)&&Fe.preventDefault()},[Me]),pointerGraceTimerRef:fe,onPointerGraceIntentChange:Ct.useCallback(Fe=>{de.current=Fe},[]),children:_t.jsx(Re,{...Te,children:_t.jsx(brt,{asChild:!0,trapped:i,onMountAutoFocus:Fm(a,Fe=>{var Ie;Fe.preventDefault(),(Ie=$.current)==null||Ie.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:_t.jsx(vrt,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:c,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:h,onDismiss:v,children:_t.jsx(Tme,{asChild:!0,...N,dir:b.dir,orientation:"vertical",loop:n,currentTabStopId:G,onCurrentTabStopIdChange:Z,onEntryFocus:Fm(l,Fe=>{b.isUsingKeyboardRef.current||Fe.preventDefault()}),preventScrollOnEntryFocus:!0,children:_t.jsx(Udn,{role:"menu","aria-orientation":"vertical","data-state":Fit(S.open),"data-radix-menu-content":"",dir:b.dir,...C,...E,ref:te,style:{outline:"none",...E.style},onKeyDown:Fm(E.onKeyDown,Fe=>{const ke=Fe.target.closest("[data-radix-menu-content]")===Fe.currentTarget,Ee=Fe.ctrlKey||Fe.altKey||Fe.metaKey,$e=Fe.key.length===1;ke&&(Fe.key==="Tab"&&Fe.preventDefault(),!Ee&&$e&&Ce(Fe.key));const tt=$.current;if(Fe.target!==tt||!Npn.includes(Fe.key))return;Fe.preventDefault();const gt=U().filter(dt=>!dt.disabled).map(dt=>dt.ref.current);mit.includes(Fe.key)&&gt.reverse(),Jpn(gt)}),onBlur:Fm(r.onBlur,Fe=>{Fe.currentTarget.contains(Fe.target)||(window.clearTimeout(re.current),se.current="")}),onPointerMove:Fm(r.onPointerMove,YR(Fe=>{const Ie=Fe.target,ke=Se.current!==Fe.clientX;if(Fe.currentTarget.contains(Ie)&&ke){const Ee=Fe.clientX>Se.current?"right":"left";ye.current=Ee,Se.current=Fe.clientX}}))})})})})})})});bit.displayName=b4;var qpn="MenuGroup",Ope=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r;return _t.jsx(e2.div,{role:"group",...n,ref:e})});Ope.displayName=qpn;var $pn="MenuLabel",Sit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r;return _t.jsx(e2.div,{...n,ref:e})});Sit.displayName=$pn;var UF="MenuItem",Eit="menu.itemSelect",kF=Ct.forwardRef((r,e)=>{const{disabled:t=!1,onSelect:n,...i}=r,a=Ct.useRef(null),o=$R(UF,r.__scopeMenu),s=Lpe(UF,r.__scopeMenu),l=x3(e,a),c=Ct.useRef(!1),u=()=>{const f=a.current;if(!t&&f){const h=new CustomEvent(Eit,{bubbles:!0,cancelable:!0});f.addEventListener(Eit,v=>n==null?void 0:n(v),{once:!0}),_me(f,h),h.defaultPrevented?c.current=!1:o.onClose()}};return _t.jsx(wit,{...i,ref:l,disabled:t,onClick:Fm(r.onClick,u),onPointerDown:f=>{var h;(h=r.onPointerDown)==null||h.call(r,f),c.current=!0},onPointerUp:Fm(r.onPointerUp,f=>{var h;c.current||(h=f.currentTarget)==null||h.click()}),onKeyDown:Fm(r.onKeyDown,f=>{const h=s.searchRef.current!=="";t||h&&f.key===" "||Ppe.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})})});kF.displayName=UF;var wit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,disabled:n=!1,textValue:i,...a}=r,o=Lpe(UF,t),s=yit(t),l=Ct.useRef(null),c=x3(e,l),[u,f]=Ct.useState(!1),[h,v]=Ct.useState("");return Ct.useEffect(()=>{const x=l.current;x&&v((x.textContent??"").trim())},[a.children]),_t.jsx(qR.ItemSlot,{scope:t,disabled:n,textValue:i??h,children:_t.jsx(Mme,{asChild:!0,...s,focusable:!n,children:_t.jsx(e2.div,{role:"menuitem","data-highlighted":u?"":void 0,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,...a,ref:c,onPointerMove:Fm(r.onPointerMove,YR(x=>{n?o.onItemLeave(x):(o.onItemEnter(x),x.defaultPrevented||x.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:Fm(r.onPointerLeave,YR(x=>o.onItemLeave(x))),onFocus:Fm(r.onFocus,()=>f(!0)),onBlur:Fm(r.onBlur,()=>f(!1))})})})}),Gpn="MenuCheckboxItem",Tit=Ct.forwardRef((r,e)=>{const{checked:t=!1,onCheckedChange:n,...i}=r;return _t.jsx(Pit,{scope:r.__scopeMenu,checked:t,children:_t.jsx(kF,{role:"menuitemcheckbox","aria-checked":FF(t)?"mixed":t,...i,ref:e,"data-state":kpe(t),onSelect:Fm(i.onSelect,()=>n==null?void 0:n(FF(t)?!0:!t),{checkForDefaultPrevented:!1})})})});Tit.displayName=Gpn;var Mit="MenuRadioGroup",[Ypn,Xpn]=v7(Mit,{value:void 0,onValueChange:()=>{}}),Cit=Ct.forwardRef((r,e)=>{const{value:t,onValueChange:n,...i}=r,a=D4(n);return _t.jsx(Ypn,{scope:r.__scopeMenu,value:t,onValueChange:a,children:_t.jsx(Ope,{...i,ref:e})})});Cit.displayName=Mit;var Rit="MenuRadioItem",Ait=Ct.forwardRef((r,e)=>{const{value:t,...n}=r,i=Xpn(Rit,r.__scopeMenu),a=t===i.value;return _t.jsx(Pit,{scope:r.__scopeMenu,checked:a,children:_t.jsx(kF,{role:"menuitemradio","aria-checked":a,...n,ref:e,"data-state":kpe(a),onSelect:Fm(n.onSelect,()=>{var o;return(o=i.onValueChange)==null?void 0:o.call(i,t)},{checkForDefaultPrevented:!1})})})});Ait.displayName=Rit;var Upe="MenuItemIndicator",[Pit,Wpn]=v7(Upe,{checked:!1}),Dit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,forceMount:n,...i}=r,a=Wpn(Upe,t);return _t.jsx(A7,{present:n||FF(a.checked)||a.checked===!0,children:_t.jsx(e2.span,{...i,ref:e,"data-state":kpe(a.checked)})})});Dit.displayName=Upe;var Zpn="MenuSeparator",Nit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r;return _t.jsx(e2.div,{role:"separator","aria-orientation":"horizontal",...n,ref:e})});Nit.displayName=Zpn;var Qpn="MenuArrow",Lit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r,i=OF(t);return _t.jsx(kdn,{...i,...n,ref:e})});Lit.displayName=Qpn;var Kpn="MenuSub",[Qyn,zit]=v7(Kpn),GR="MenuSubTrigger",Oit=Ct.forwardRef((r,e)=>{const t=y7(GR,r.__scopeMenu),n=$R(GR,r.__scopeMenu),i=zit(GR,r.__scopeMenu),a=Lpe(GR,r.__scopeMenu),o=Ct.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:l}=a,c={__scopeMenu:r.__scopeMenu},u=Ct.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);return Ct.useEffect(()=>u,[u]),Ct.useEffect(()=>{const f=s.current;return()=>{window.clearTimeout(f),l(null)}},[s,l]),_t.jsx(Dpe,{asChild:!0,...c,children:_t.jsx(wit,{id:i.triggerId,"aria-haspopup":"menu","aria-expanded":t.open,"aria-controls":i.contentId,"data-state":Fit(t.open),...r,ref:yA(e,i.onTriggerChange),onClick:f=>{var h;(h=r.onClick)==null||h.call(r,f),!(r.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),t.open||t.onOpenChange(!0))},onPointerMove:Fm(r.onPointerMove,YR(f=>{a.onItemEnter(f),!f.defaultPrevented&&!r.disabled&&!t.open&&!o.current&&(a.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{t.onOpenChange(!0),u()},100))})),onPointerLeave:Fm(r.onPointerLeave,YR(f=>{var v,x;u();const h=(v=t.content)==null?void 0:v.getBoundingClientRect();if(h){const E=(x=t.content)==null?void 0:x.dataset.side,S=E==="right",b=S?-5:5,C=h[S?"left":"right"],N=h[S?"right":"left"];a.onPointerGraceIntentChange({area:[{x:f.clientX+b,y:f.clientY},{x:C,y:h.top},{x:N,y:h.top},{x:N,y:h.bottom},{x:C,y:h.bottom}],side:E}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(f),f.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:Fm(r.onKeyDown,f=>{var v;const h=a.searchRef.current!=="";r.disabled||h&&f.key===" "||Lpn[n.dir].includes(f.key)&&(t.onOpenChange(!0),(v=t.content)==null||v.focus(),f.preventDefault())})})})});Oit.displayName=GR;var Uit="MenuSubContent",kit=Ct.forwardRef((r,e)=>{const t=_it(b4,r.__scopeMenu),{forceMount:n=t.forceMount,...i}=r,a=y7(b4,r.__scopeMenu),o=$R(b4,r.__scopeMenu),s=zit(Uit,r.__scopeMenu),l=Ct.useRef(null),c=x3(e,l);return _t.jsx(qR.Provider,{scope:r.__scopeMenu,children:_t.jsx(A7,{present:n||a.open,children:_t.jsx(qR.Slot,{scope:r.__scopeMenu,children:_t.jsx(zpe,{id:s.contentId,"aria-labelledby":s.triggerId,...i,ref:c,align:"start",side:o.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:u=>{var f;o.isUsingKeyboardRef.current&&((f=l.current)==null||f.focus()),u.preventDefault()},onCloseAutoFocus:u=>u.preventDefault(),onFocusOutside:Fm(r.onFocusOutside,u=>{u.target!==s.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:Fm(r.onEscapeKeyDown,u=>{o.onClose(),u.preventDefault()}),onKeyDown:Fm(r.onKeyDown,u=>{var v;const f=u.currentTarget.contains(u.target),h=zpn[o.dir].includes(u.key);f&&h&&(a.onOpenChange(!1),(v=s.trigger)==null||v.focus(),u.preventDefault())})})})})})});kit.displayName=Uit;function Fit(r){return r?"open":"closed"}function FF(r){return r==="indeterminate"}function kpe(r){return FF(r)?"indeterminate":r?"checked":"unchecked"}function Jpn(r){const e=document.activeElement;for(const t of r)if(t===e||(t.focus(),document.activeElement!==e))return}function ehn(r,e){return r.map((t,n)=>r[(e+n)%r.length])}function thn(r,e,t){const i=e.length>1&&Array.from(e).every(c=>c===e[0])?e[0]:e,a=t?r.indexOf(t):-1;let o=ehn(r,Math.max(a,0));i.length===1&&(o=o.filter(c=>c!==t));const l=o.find(c=>c.toLowerCase().startsWith(i.toLowerCase()));return l!==t?l:void 0}function nhn(r,e){const{x:t,y:n}=r;let i=!1;for(let a=0,o=e.length-1;a<e.length;o=a++){const s=e[a].x,l=e[a].y,c=e[o].x,u=e[o].y;l>n!=u>n&&t<(c-s)*(n-l)/(u-l)+s&&(i=!i)}return i}function rhn(r,e){if(!e)return!1;const t={x:r.clientX,y:r.clientY};return nhn(t,e)}function YR(r){return e=>e.pointerType==="mouse"?r(e):void 0}var ihn=git,ahn=Dpe,ohn=xit,shn=bit,lhn=Ope,chn=Sit,uhn=kF,fhn=Tit,dhn=Cit,phn=Ait,hhn=Dit,mhn=Nit,vhn=Lit,yhn=Oit,ghn=kit,Fpe="DropdownMenu",[_hn,Kyn]=M7(Fpe,[vit]),s3=vit(),[xhn,Iit]=_hn(Fpe),Bit=r=>{const{__scopeDropdownMenu:e,children:t,dir:n,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=r,l=s3(e),c=Ct.useRef(null),[u=!1,f]=MI({prop:i,defaultProp:a,onChange:o});return _t.jsx(xhn,{scope:e,triggerId:gA(),triggerRef:c,contentId:gA(),open:u,onOpenChange:f,onOpenToggle:Ct.useCallback(()=>f(h=>!h),[f]),modal:s,children:_t.jsx(ihn,{...l,open:u,onOpenChange:f,dir:n,modal:s,children:t})})};Bit.displayName=Fpe;var jit="DropdownMenuTrigger",Vit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,disabled:n=!1,...i}=r,a=Iit(jit,t),o=s3(t);return _t.jsx(ahn,{asChild:!0,...o,children:_t.jsx(e2.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":n?"":void 0,disabled:n,...i,ref:yA(e,a.triggerRef),onPointerDown:Fm(r.onPointerDown,s=>{!n&&s.button===0&&s.ctrlKey===!1&&(a.onOpenToggle(),a.open||s.preventDefault())}),onKeyDown:Fm(r.onKeyDown,s=>{n||(["Enter"," "].includes(s.key)&&a.onOpenToggle(),s.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});Vit.displayName=jit;var bhn="DropdownMenuPortal",Hit=r=>{const{__scopeDropdownMenu:e,...t}=r,n=s3(e);return _t.jsx(ohn,{...n,...t})};Hit.displayName=bhn;var qit="DropdownMenuContent",$it=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=Iit(qit,t),a=s3(t),o=Ct.useRef(!1);return _t.jsx(shn,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...n,ref:e,onCloseAutoFocus:Fm(r.onCloseAutoFocus,s=>{var l;o.current||(l=i.triggerRef.current)==null||l.focus(),o.current=!1,s.preventDefault()}),onInteractOutside:Fm(r.onInteractOutside,s=>{const l=s.detail.originalEvent,c=l.button===0&&l.ctrlKey===!0,u=l.button===2||c;(!i.modal||u)&&(o.current=!0)}),style:{...r.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});$it.displayName=qit;var Shn="DropdownMenuGroup",Ehn=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(lhn,{...i,...n,ref:e})});Ehn.displayName=Shn;var whn="DropdownMenuLabel",Git=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(chn,{...i,...n,ref:e})});Git.displayName=whn;var Thn="DropdownMenuItem",Yit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(uhn,{...i,...n,ref:e})});Yit.displayName=Thn;var Mhn="DropdownMenuCheckboxItem",Xit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(fhn,{...i,...n,ref:e})});Xit.displayName=Mhn;var Chn="DropdownMenuRadioGroup",Rhn=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(dhn,{...i,...n,ref:e})});Rhn.displayName=Chn;var Ahn="DropdownMenuRadioItem",Wit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(phn,{...i,...n,ref:e})});Wit.displayName=Ahn;var Phn="DropdownMenuItemIndicator",Zit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(hhn,{...i,...n,ref:e})});Zit.displayName=Phn;var Dhn="DropdownMenuSeparator",Qit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(mhn,{...i,...n,ref:e})});Qit.displayName=Dhn;var Nhn="DropdownMenuArrow",Lhn=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(vhn,{...i,...n,ref:e})});Lhn.displayName=Nhn;var zhn="DropdownMenuSubTrigger",Kit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(yhn,{...i,...n,ref:e})});Kit.displayName=zhn;var Ohn="DropdownMenuSubContent",Jit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(ghn,{...i,...n,ref:e,style:{...r.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Jit.displayName=Ohn;var Uhn=Bit,khn=Vit,Fhn=Hit,eat=$it,tat=Git,nat=Yit,rat=Xit,iat=Wit,aat=Zit,oat=Qit,sat=Kit,lat=Jit;const Ihn=Uhn,Bhn=khn,jhn=Ct.forwardRef(({className:r,inset:e,children:t,...n},i)=>_t.jsxs(sat,{ref:i,className:mg("rf-flex rf-cursor-default rf-gap-2 rf-select-none rf-items-center rf-rounded-sm rf-px-2 rf-py-1.5 rf-text-sm rf-outline-none focus:rf-bg-zinc-100 data-[state=open]:rf-bg-zinc-100 [&_svg]:rf-pointer-events-none [&_svg]:rf-size-4 [&_svg]:rf-shrink-0 dark:focus:rf-bg-zinc-800 dark:data-[state=open]:rf-bg-zinc-800",e&&"rf-pl-8",r),...n,children:[t,_t.jsx(Man,{className:"rf-ml-auto"})]}));jhn.displayName=sat.displayName;const Vhn=Ct.forwardRef(({className:r,...e},t)=>_t.jsx(lat,{ref:t,className:mg("rf-z-50 rf-min-w-[8rem] rf-overflow-hidden rf-rounded-md rf-border rf-border-zinc-200 rf-bg-white rf-p-1 rf-text-zinc-950 rf-shadow-lg data-[state=open]:rf-animate-in data-[state=closed]:rf-animate-out data-[state=closed]:rf-fade-out-0 data-[state=open]:rf-fade-in-0 data-[state=closed]:rf-zoom-out-95 data-[state=open]:rf-zoom-in-95 data-[side=bottom]:rf-slide-in-from-top-2 data-[side=left]:rf-slide-in-from-right-2 data-[side=right]:rf-slide-in-from-left-2 data-[side=top]:rf-slide-in-from-bottom-2 dark:rf-border-zinc-800 dark:rf-bg-zinc-950 dark:rf-text-zinc-50",r),...e}));Vhn.displayName=lat.displayName;const cat=Ct.forwardRef(({className:r,sideOffset:e=4,...t},n)=>_t.jsx(Fhn,{children:_t.jsx(eat,{ref:n,sideOffset:e,className:mg("rf-z-50 rf-min-w-[8rem] rf-overflow-hidden rf-rounded-md rf-border rf-border-zinc-200 rf-bg-white rf-p-1 rf-text-zinc-950 rf-shadow-md dark:rf-border-zinc-800 dark:rf-bg-zinc-950 dark:rf-text-zinc-50","data-[state=open]:rf-animate-in data-[state=closed]:rf-animate-out data-[state=closed]:rf-fade-out-0 data-[state=open]:rf-fade-in-0 data-[state=closed]:rf-zoom-out-95 data-[state=open]:rf-zoom-in-95 data-[side=bottom]:rf-slide-in-from-top-2 data-[side=left]:rf-slide-in-from-right-2 data-[side=right]:rf-slide-in-from-left-2 data-[side=top]:rf-slide-in-from-bottom-2",r),...t})}));cat.displayName=eat.displayName;const uat=Ct.forwardRef(({className:r,inset:e,...t},n)=>_t.jsx(nat,{ref:n,className:mg("rf-relative rf-flex rf-cursor-default rf-select-none rf-items-center rf-gap-2 rf-rounded-sm rf-px-2 rf-py-1.5 rf-text-sm rf-outline-none rf-transition-colors focus:rf-bg-zinc-100 focus:rf-text-zinc-900 data-[disabled]:rf-pointer-events-none data-[disabled]:rf-opacity-50 [&>svg]:rf-size-4 [&>svg]:rf-shrink-0 dark:focus:rf-bg-zinc-800 dark:focus:rf-text-zinc-50",e&&"rf-pl-8",r),...t}));uat.displayName=nat.displayName;const Hhn=Ct.forwardRef(({className:r,children:e,checked:t,...n},i)=>_t.jsxs(rat,{ref:i,className:mg("rf-relative rf-flex rf-cursor-default rf-select-none rf-items-center rf-rounded-sm rf-py-1.5 rf-pl-8 rf-pr-2 rf-text-sm rf-outline-none rf-transition-colors focus:rf-bg-zinc-100 focus:rf-text-zinc-900 data-[disabled]:rf-pointer-events-none data-[disabled]:rf-opacity-50 dark:focus:rf-bg-zinc-800 dark:focus:rf-text-zinc-50",r),checked:t,...n,children:[_t.jsx("span",{className:"rf-absolute rf-left-2 rf-flex rf-h-3.5 rf-w-3.5 rf-items-center rf-justify-center",children:_t.jsx(aat,{children:_t.jsx(FJe,{className:"rf-h-4 rf-w-4"})})}),e]}));Hhn.displayName=rat.displayName;const qhn=Ct.forwardRef(({className:r,children:e,...t},n)=>_t.jsxs(iat,{ref:n,className:mg("rf-relative rf-flex rf-cursor-default rf-select-none rf-items-center rf-rounded-sm rf-py-1.5 rf-pl-8 rf-pr-2 rf-text-sm rf-outline-none rf-transition-colors focus:rf-bg-zinc-100 focus:rf-text-zinc-900 data-[disabled]:rf-pointer-events-none data-[disabled]:rf-opacity-50 dark:focus:rf-bg-zinc-800 dark:focus:rf-text-zinc-50",r),...t,children:[_t.jsx("span",{className:"rf-absolute rf-left-2 rf-flex rf-h-3.5 rf-w-3.5 rf-items-center rf-justify-center",children:_t.jsx(aat,{children:_t.jsx(Can,{className:"rf-h-2 rf-w-2 rf-fill-current"})})}),e]}));qhn.displayName=iat.displayName;const $hn=Ct.forwardRef(({className:r,inset:e,...t},n)=>_t.jsx(tat,{ref:n,className:mg("rf-px-2 rf-py-1.5 rf-text-sm rf-font-semibold",e&&"rf-pl-8",r),...t}));$hn.displayName=tat.displayName;const Ghn=Ct.forwardRef(({className:r,...e},t)=>_t.jsx(oat,{ref:t,className:mg("rf--mx-1 rf-my-1 rf-h-px rf-bg-zinc-100 dark:rf-bg-zinc-800",r),...e}));Ghn.displayName=oat.displayName;const Yhn=({containerClassName:r,...e})=>{const t=Ct.useRef(null),[n,i]=Ct.useState(620);return Ct.useLayoutEffect(()=>{const a=()=>{if(t.current){const s=t.current.clientHeight,l=window.innerHeight;i(Math.min(Math.max(s,620),l))}};a();const o=new ResizeObserver(a);return t.current&&o.observe(t.current),window.addEventListener("resize",a),()=>{o.disconnect(),window.removeEventListener("resize",a)}},[]),_t.jsx("div",{ref:t,className:r||"rf-w-full rf-h-full",children:_t.jsx(van,{...e,height:n})})},Xhn='*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-feature-settings:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]:where(:not([hidden=until-found])){display:none}:root{--radius:0.5rem}.rf-pointer-events-none{pointer-events:none}.rf-invisible{visibility:hidden}.rf-fixed{position:fixed}.rf-absolute{position:absolute}.rf-relative{position:relative}.rf-inset-0{inset:0}.-rf-left-2{left:-.5rem}.-rf-right-10{right:-2.5rem}.-rf-right-2{right:-.5rem}.-rf-right-4{right:-1rem}.-rf-right-6{right:-1.5rem}.-rf-right-7{right:-1.75rem}.-rf-right-8{right:-2rem}.-rf-right-9{right:-2.25rem}.rf-bottom-full{bottom:100%}.rf-left-1{left:.25rem}.rf-left-1\\/2{left:50%}.rf-left-2{left:.5rem}.rf-right-0{right:0}.rf-right-4{right:1rem}.rf-right-\\[4px\\]{right:4px}.rf-top-1{top:.25rem}.rf-top-2{top:.5rem}.rf-top-\\[6px\\]{top:6px}.rf-z-50{z-index:50}.rf-z-\\[100\\]{z-index:100}.rf--mx-1{margin-left:-.25rem;margin-right:-.25rem}.rf-mx-2{margin-left:.5rem;margin-right:.5rem}.rf-my-1{margin-bottom:.25rem;margin-top:.25rem}.rf-mb-2{margin-bottom:.5rem}.rf-mb-3{margin-bottom:.75rem}.rf-mb-4{margin-bottom:1rem}.rf-ml-1{margin-left:.25rem}.rf-ml-1\\.5{margin-left:.375rem}.rf-ml-2{margin-left:.5rem}.rf-ml-auto{margin-left:auto}.rf-mr-1{margin-right:.25rem}.rf-mr-2{margin-right:.5rem}.rf-mt-0{margin-top:0}.rf-mt-2{margin-top:.5rem}.rf-mt-4{margin-top:1rem}.rf-flex{display:flex}.rf-inline-flex{display:inline-flex}.rf-size-4{height:1rem;width:1rem}.\\!rf-h-2{height:.5rem!important}.\\!rf-h-2\\.5{height:.625rem!important}.\\!rf-h-3{height:.75rem!important}.rf-h-1{height:.25rem}.rf-h-10{height:2.5rem}.rf-h-2{height:.5rem}.rf-h-3{height:.75rem}.rf-h-3\\.5{height:.875rem}.rf-h-4{height:1rem}.rf-h-60{height:15rem}.rf-h-8{height:2rem}.rf-h-9{height:2.25rem}.rf-h-\\[620px\\]{height:620px}.rf-h-\\[calc\\(100vh-96px\\)\\]{height:calc(100vh - 96px)}.rf-h-full{height:100%}.rf-h-px{height:1px}.rf-max-h-\\[500px\\]{max-height:500px}.rf-min-h-\\[620px\\]{min-height:620px}.rf-min-h-\\[calc\\(100vh-240px\\)\\]{min-height:calc(100vh - 240px)}.\\!rf-w-2{width:.5rem!important}.\\!rf-w-2\\.5{width:.625rem!important}.rf-w-1{width:.25rem}.rf-w-11{width:2.75rem}.rf-w-11\\/12{width:91.666667%}.rf-w-16{width:4rem}.rf-w-2{width:.5rem}.rf-w-3{width:.75rem}.rf-w-3\\.5{width:.875rem}.rf-w-32{width:8rem}.rf-w-4{width:1rem}.rf-w-64{width:16rem}.rf-w-8{width:2rem}.rf-w-9{width:2.25rem}.rf-w-96{width:24rem}.rf-w-full{width:100%}.rf-min-w-10{min-width:2.5rem}.rf-min-w-16{min-width:4rem}.rf-min-w-\\[8rem\\]{min-width:8rem}.rf-max-w-2xl{max-width:42rem}.rf-shrink-0{flex-shrink:0}.rf-flex-grow{flex-grow:1}.rf-table-auto{table-layout:auto}.-rf-translate-x-1{--tw-translate-x:-0.25rem}.-rf-translate-x-1,.-rf-translate-x-1\\/2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rf-translate-x-1\\/2{--tw-translate-x:-50%}.-rf-translate-y-1{--tw-translate-y:-0.25rem}.-rf-translate-y-1,.rf--translate-x-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf--translate-x-1{--tw-translate-x:-0.25rem}.rf-transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes rf-spin{to{transform:rotate(1turn)}}.rf-animate-spin{animation:rf-spin 1s linear infinite}.rf-cursor-default{cursor:default}.rf-cursor-pointer{cursor:pointer}.rf-select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.rf-flex-col{flex-direction:column}.rf-items-center{align-items:center}.rf-justify-end{justify-content:flex-end}.rf-justify-center{justify-content:center}.rf-justify-between{justify-content:space-between}.rf-gap-0{gap:0}.rf-gap-1{gap:.25rem}.rf-gap-2{gap:.5rem}.rf-gap-3{gap:.75rem}.rf-gap-5{gap:1.25rem}.rf-gap-6{gap:1.5rem}.rf-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.rf-space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}.rf-overflow-auto{overflow:auto}.rf-overflow-hidden{overflow:hidden}.rf-overflow-visible{overflow:visible}.rf-overflow-x-auto{overflow-x:auto}.rf-overflow-y-auto{overflow-y:auto}.rf-whitespace-nowrap{white-space:nowrap}.rf-whitespace-pre-wrap{white-space:pre-wrap}.rf-rounded{border-radius:.25rem}.rf-rounded-full{border-radius:9999px}.rf-rounded-lg{border-radius:var(--radius)}.rf-rounded-md{border-radius:calc(var(--radius) - 2px)}.rf-rounded-sm{border-radius:calc(var(--radius) - 4px)}.rf-border{border-width:1px}.rf-border-b{border-bottom-width:1px}.rf-border-green-200{--tw-border-opacity:1;border-color:rgb(187 247 208/var(--tw-border-opacity,1))}.rf-border-neutral-200{--tw-border-opacity:1;border-color:rgb(229 229 229/var(--tw-border-opacity,1))}.rf-border-red-200{--tw-border-opacity:1;border-color:rgb(254 202 202/var(--tw-border-opacity,1))}.rf-border-zinc-200{--tw-border-opacity:1;border-color:rgb(228 228 231/var(--tw-border-opacity,1))}.rf-bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity,1))}.rf-bg-blue-500{--tw-bg-opacity:1;background-color:rgb(59 130 246/var(--tw-bg-opacity,1))}.rf-bg-blue-600{--tw-bg-opacity:1;background-color:rgb(37 99 235/var(--tw-bg-opacity,1))}.rf-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.rf-bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}.rf-bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.rf-bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}.rf-bg-green-50{--tw-bg-opacity:1;background-color:rgb(240 253 244/var(--tw-bg-opacity,1))}.rf-bg-neutral-100{--tw-bg-opacity:1;background-color:rgb(245 245 245/var(--tw-bg-opacity,1))}.rf-bg-neutral-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-neutral-800{--tw-bg-opacity:1;background-color:rgb(38 38 38/var(--tw-bg-opacity,1))}.rf-bg-neutral-900{--tw-bg-opacity:1;background-color:rgb(23 23 23/var(--tw-bg-opacity,1))}.rf-bg-orange-400{--tw-bg-opacity:1;background-color:rgb(251 146 60/var(--tw-bg-opacity,1))}.rf-bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity,1))}.rf-bg-red-50{--tw-bg-opacity:1;background-color:rgb(254 242 242/var(--tw-bg-opacity,1))}.rf-bg-red-500{--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}.rf-bg-red-900{--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.rf-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.rf-bg-zinc-100{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.rf-bg-zinc-200{--tw-bg-opacity:1;background-color:rgb(228 228 231/var(--tw-bg-opacity,1))}.rf-bg-zinc-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-zinc-800{--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.rf-bg-zinc-900{--tw-bg-opacity:1;background-color:rgb(24 24 27/var(--tw-bg-opacity,1))}.rf-bg-opacity-50{--tw-bg-opacity:0.5}.rf-fill-current{fill:currentColor}.rf-p-0{padding:0}.rf-p-0\\.5{padding:.125rem}.rf-p-1{padding:.25rem}.rf-p-2{padding:.5rem}.rf-p-3{padding:.75rem}.rf-p-4{padding:1rem}.rf-p-5{padding:1.25rem}.rf-p-6{padding:1.5rem}.rf-px-1{padding-left:.25rem;padding-right:.25rem}.rf-px-1\\.5{padding-left:.375rem;padding-right:.375rem}.rf-px-2{padding-left:.5rem;padding-right:.5rem}.rf-px-3{padding-left:.75rem;padding-right:.75rem}.rf-px-4{padding-left:1rem;padding-right:1rem}.rf-px-8{padding-left:2rem;padding-right:2rem}.rf-py-0{padding-bottom:0;padding-top:0}.rf-py-1{padding-bottom:.25rem;padding-top:.25rem}.rf-py-1\\.5{padding-bottom:.375rem;padding-top:.375rem}.rf-py-10{padding-bottom:2.5rem;padding-top:2.5rem}.rf-py-2{padding-bottom:.5rem;padding-top:.5rem}.rf-pb-4{padding-bottom:1rem}.rf-pl-2{padding-left:.5rem}.rf-pl-8{padding-left:2rem}.rf-pr-2{padding-right:.5rem}.rf-text-left{text-align:left}.rf-text-center{text-align:center}.rf-font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.rf-text-2xl{font-size:1.5rem;line-height:2rem}.rf-text-\\[8px\\]{font-size:8px}.rf-text-lg{font-size:1.125rem;line-height:1.75rem}.rf-text-sm{font-size:.875rem;line-height:1.25rem}.rf-text-xs{font-size:.75rem;line-height:1rem}.rf-font-bold{font-weight:700}.rf-font-medium{font-weight:500}.rf-font-semibold{font-weight:600}.rf-capitalize{text-transform:capitalize}.rf-tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.rf-leading-5{line-height:1.25rem}.rf-tracking-widest{letter-spacing:.1em}.rf-text-blue-500{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity,1))}.rf-text-blue-600{--tw-text-opacity:1;color:rgb(37 99 235/var(--tw-text-opacity,1))}.rf-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.rf-text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}.rf-text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}.rf-text-green-500{--tw-text-opacity:1;color:rgb(34 197 94/var(--tw-text-opacity,1))}.rf-text-green-700{--tw-text-opacity:1;color:rgb(21 128 61/var(--tw-text-opacity,1))}.rf-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity,1))}.rf-text-neutral-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-neutral-500{--tw-text-opacity:1;color:rgb(115 115 115/var(--tw-text-opacity,1))}.rf-text-neutral-900{--tw-text-opacity:1;color:rgb(23 23 23/var(--tw-text-opacity,1))}.rf-text-neutral-950{--tw-text-opacity:1;color:rgb(10 10 10/var(--tw-text-opacity,1))}.rf-text-red-200{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity,1))}.rf-text-red-300{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.rf-text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.rf-text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity,1))}.rf-text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity,1))}.rf-text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity,1))}.rf-text-red-800{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity,1))}.rf-text-red-900{--tw-text-opacity:1;color:rgb(127 29 29/var(--tw-text-opacity,1))}.rf-text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.rf-text-zinc-200{--tw-text-opacity:1;color:rgb(228 228 231/var(--tw-text-opacity,1))}.rf-text-zinc-300{--tw-text-opacity:1;color:rgb(212 212 216/var(--tw-text-opacity,1))}.rf-text-zinc-400{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.rf-text-zinc-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-zinc-500{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.rf-text-zinc-900{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.rf-text-zinc-950{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.rf-underline{text-decoration-line:underline}.rf-underline-offset-4{text-underline-offset:4px}.rf-opacity-0{opacity:0}.rf-opacity-50{opacity:.5}.rf-opacity-60{opacity:.6}.rf-shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)}.rf-shadow,.rf-shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.rf-shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.rf-shadow-md,.rf-shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.rf-outline-none{outline:2px solid transparent;outline-offset:2px}.rf-ring-offset-white{--tw-ring-offset-color:#fff}.rf-transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity,1);transform:translate3d(var(--tw-enter-translate-x,0),var(--tw-enter-translate-y,0),0) scale3d(var(--tw-enter-scale,1),var(--tw-enter-scale,1),var(--tw-enter-scale,1)) rotate(var(--tw-enter-rotate,0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity,1);transform:translate3d(var(--tw-exit-translate-x,0),var(--tw-exit-translate-y,0),0) scale3d(var(--tw-exit-scale,1),var(--tw-exit-scale,1),var(--tw-exit-scale,1)) rotate(var(--tw-exit-rotate,0))}}.hover\\:\\!rf-bg-transparent:hover{background-color:transparent!important}.hover\\:rf-bg-blue-700:hover{--tw-bg-opacity:1;background-color:rgb(29 78 216/var(--tw-bg-opacity,1))}.hover\\:rf-bg-red-500\\/90:hover{background-color:rgba(239,68,68,.9)}.hover\\:rf-bg-zinc-100:hover{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.hover\\:rf-bg-zinc-100\\/80:hover{background-color:hsla(240,5%,96%,.8)}.hover\\:rf-bg-zinc-900\\/90:hover{background-color:rgba(24,24,27,.9)}.hover\\:rf-text-red-400:hover{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.hover\\:rf-text-zinc-900:hover{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.hover\\:rf-underline:hover{text-decoration-line:underline}.focus\\:rf-bg-zinc-100:focus{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.focus\\:rf-text-zinc-900:focus{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.focus-visible\\:rf-outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:rf-ring-1:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-zinc-950:focus-visible{--tw-ring-opacity:1;--tw-ring-color:rgb(9 9 11/var(--tw-ring-opacity,1))}.focus-visible\\:rf-ring-offset-2:focus-visible{--tw-ring-offset-width:2px}.disabled\\:rf-pointer-events-none:disabled{pointer-events:none}.disabled\\:rf-opacity-50:disabled{opacity:.5}.rf-group\\/bar:hover .group-hover\\/bar\\:rf-opacity-100{opacity:1}.data-\\[disabled\\]\\:rf-pointer-events-none[data-disabled]{pointer-events:none}.data-\\[state\\=active\\]\\:rf-bg-white[data-state=active]{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.data-\\[state\\=open\\]\\:rf-bg-zinc-100[data-state=open]{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.data-\\[state\\=active\\]\\:rf-text-zinc-950[data-state=active]{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.data-\\[disabled\\]\\:rf-opacity-50[data-disabled]{opacity:.5}.data-\\[state\\=active\\]\\:rf-shadow[data-state=active]{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.data-\\[state\\=open\\]\\:rf-animate-in[data-state=open]{animation-duration:.15s;animation-name:enter;--tw-enter-opacity:initial;--tw-enter-scale:initial;--tw-enter-rotate:initial;--tw-enter-translate-x:initial;--tw-enter-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-animate-out[data-state=closed]{animation-duration:.15s;animation-name:exit;--tw-exit-opacity:initial;--tw-exit-scale:initial;--tw-exit-rotate:initial;--tw-exit-translate-x:initial;--tw-exit-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-fade-out-0[data-state=closed]{--tw-exit-opacity:0}.data-\\[state\\=open\\]\\:rf-fade-in-0[data-state=open]{--tw-enter-opacity:0}.data-\\[state\\=closed\\]\\:rf-zoom-out-95[data-state=closed]{--tw-exit-scale:.95}.data-\\[state\\=open\\]\\:rf-zoom-in-95[data-state=open]{--tw-enter-scale:.95}.data-\\[side\\=bottom\\]\\:rf-slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y:-0.5rem}.data-\\[side\\=left\\]\\:rf-slide-in-from-right-2[data-side=left]{--tw-enter-translate-x:0.5rem}.data-\\[side\\=right\\]\\:rf-slide-in-from-left-2[data-side=right]{--tw-enter-translate-x:-0.5rem}.data-\\[side\\=top\\]\\:rf-slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y:0.5rem}.dark\\:rf-border-zinc-800:is(.rf-dark *){--tw-border-opacity:1;border-color:rgb(39 39 42/var(--tw-border-opacity,1))}.dark\\:rf-bg-red-900:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-50:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-800:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-950:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:rf-text-zinc-400:is(.rf-dark *){--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-50:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-900:is(.rf-dark *){--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.dark\\:rf-ring-offset-zinc-950:is(.rf-dark *){--tw-ring-offset-color:#09090b}.dark\\:hover\\:rf-bg-red-900\\/90:hover:is(.rf-dark *){background-color:rgba(127,29,29,.9)}.dark\\:hover\\:rf-bg-zinc-50\\/90:hover:is(.rf-dark *){background-color:hsla(0,0%,98%,.9)}.dark\\:hover\\:rf-bg-zinc-800:hover:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:hover\\:rf-bg-zinc-800\\/80:hover:is(.rf-dark *){background-color:rgba(39,39,42,.8)}.dark\\:hover\\:rf-text-zinc-50:hover:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus\\:rf-bg-zinc-800:focus:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:focus\\:rf-text-zinc-50:focus:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus-visible\\:rf-ring-zinc-300:focus-visible:is(.rf-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(212 212 216/var(--tw-ring-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-bg-zinc-950[data-state=active]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=open\\]\\:rf-bg-zinc-800[data-state=open]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-text-zinc-50[data-state=active]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.\\[\\&\\>svg\\]\\:rf-size-4>svg{height:1rem;width:1rem}.\\[\\&\\>svg\\]\\:rf-shrink-0>svg{flex-shrink:0}.\\[\\&\\>svg\\]\\:rf-text-red-300>svg{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.\\[\\&\\>svg\\]\\:hover\\:rf-text-red-400:hover>svg{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.\\[\\&_svg\\]\\:rf-pointer-events-none svg{pointer-events:none}.\\[\\&_svg\\]\\:rf-size-4 svg{height:1rem;width:1rem}.\\[\\&_svg\\]\\:rf-shrink-0 svg{flex-shrink:0}',Whn=()=>{Ct.useEffect(()=>{if(document.querySelector('style[data-styles="tscircuit-runframe"]'))return;const e=document.createElement("style");e.setAttribute("data-styles","tscircuit-runframe"),e.textContent=Xhn,document.head.appendChild(e)},[])},fat=r=>`hsl(${K3.indexOf(r)*137.5%360}, 70%, 50%)`,Zhn=({phaseTimings:r})=>{if(!r)return null;const e=Object.values(r).reduce((t,n)=>t+n,0);return _t.jsxs("div",{className:"rf-space-y-2 rf-w-full rf-px-4",children:[_t.jsx("div",{className:"rf-relative rf-h-8 rf-flex rf-rounded-sm",children:K3.map(t=>{const n=r[t]||0,i=n/e*100;return _t.jsx("div",{className:"rf-group/bar rf-relative rf-overflow-visible",style:{width:`${i}%`,backgroundColor:fat(t)},children:_t.jsxs("div",{className:"rf-opacity-0 group-hover/bar:rf-opacity-100 rf-transition-opacity rf-absolute rf-bottom-full rf-left-1/2 rf-transform -rf-translate-x-1/2 rf-mb-2 rf-px-2 rf-py-1 rf-text-xs rf-whitespace-nowrap rf-rounded rf-bg-gray-900 rf-text-white rf-pointer-events-none",children:[t,": ",n.toFixed(1),"ms"]})},t)})}),_t.jsxs("div",{className:"rf-text-xs rf-text-gray-500",children:["Total: ",e.toFixed(2),"ms"]})]})},Qhn=({renderLog:r})=>{const[e,t]=Ct.useState("chronological");if(!r)return _t.jsx("div",{className:"rf-p-4 rf-bg-gray-100 rf-rounded-md",children:"No render log, make sure this tab is open when you render (TODO add a rerender button here)"});const n=Object.entries((r==null?void 0:r.phaseTimings)??{});e==="chronological"?n.sort((a,o)=>K3.indexOf(a[0])-K3.indexOf(o[0])):n.sort((a,o)=>o[1]-a[1]);const i=n.reduce((a,[o,s])=>a+s,0);return _t.jsxs("div",{className:"rf-bg-white",children:[_t.jsxs("div",{className:"rf-flex rf-justify-between rf-items-center",children:[_t.jsx("div",{children:"Render Logs"}),_t.jsxs("div",{className:"rf-mb-4 rf-pr-2 rf-flex rf-text-xs rf-items-center",children:[_t.jsx("div",{className:"rf-mr-2",children:"Sort by:"}),_t.jsxs("select",{value:e,onChange:a=>t(a.target.value),className:"rf-px-2 rf-py-1 rf-border rf-rounded rf-text-xs",children:[_t.jsx("option",{value:"chronological",children:"Phase Order"}),_t.jsx("option",{value:"longest",children:"Duration"})]})]})]}),_t.jsx(Zhn,{phaseTimings:r.phaseTimings}),_t.jsxs("table",{className:"rf-w-full rf-text-xs",children:[_t.jsx("thead",{children:_t.jsxs("tr",{children:[_t.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase Order"}),_t.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase"}),_t.jsx("th",{className:"rf-text-left rf-p-2",children:"Duration (ms)"})]})}),_t.jsx("tbody",{children:n.map(([a,o])=>_t.jsxs("tr",{children:[_t.jsx("td",{className:"rf-p-2",children:K3.indexOf(a)}),_t.jsx("td",{className:"rf-p-2",children:a}),_t.jsx("td",{className:"rf-p-2",children:_t.jsx("div",{className:"rf-w-8",children:_t.jsx("div",{className:"rf-h-2 rf-rounded-sm",style:{backgroundColor:fat(a),width:`${o/i*100}%`}})})}),_t.jsx("td",{className:"rf-p-2",children:_t.jsxs("div",{className:"rf-flex w-full",children:[_t.jsxs("span",{className:"rf-flex-grow",children:[o,"ms"]}),_t.jsxs("span",{className:"rf-text-gray-500 rf-pr-2",children:[(o/i*100).toFixed(1),"%"]})]})})]},a))})]})]})},Khn=["assembly","bom","circuit_json","errors","render_log"],Jhn=({code:r,onRunClicked:e=void 0,errorMessage:t,circuitJsonKey:n="",circuitJson:i,showCodeTab:a=!1,codeTabContent:o,showJsonTab:s=!0,showRenderLogTab:l=!0,onActiveTabChange:c,renderLog:u,showImportAndFormatButtons:f=!0,className:h,headerClassName:v,leftHeaderContent:x,readOnly:E,isStreaming:S,onToggleFullScreen:b,isFullScreen:C,isRunningCode:N,hasCodeChangedSinceLastRun:U,onEditEvent:G,editEvents:Z,defaultActiveTab:$})=>{var fe;Whn();const[te,re]=Ct.useState($??"pcb"),se=Ct.useCallback(de=>{re(de),c==null||c(de)},[c]);return Ct.useEffect(()=>{t&&se("errors")},[t]),Ct.useEffect(()=>{te==="code"&&i&&!t&&se("pcb")},[i]),_t.jsx("div",{className:mg("flex flex-col relative",h),children:_t.jsx("div",{className:"rf-md:sticky rf-md:top-2",children:_t.jsxs(Act,{value:te,onValueChange:se,className:"rf-flex-grow rf-flex rf-flex-col rf-p-2",children:[_t.jsxs("div",{className:mg("rf-flex rf-items-center rf-gap-2",v),children:[x,x&&_t.jsx("div",{className:"rf-flex-grow"}),!x&&N&&_t.jsx(zfe,{className:"rf-w-4 rf-h-4 rf-animate-spin"}),!x&&_t.jsx("div",{className:"rf-flex-grow"}),u&&u.progress!==1&&_t.jsxs("div",{className:"rf-flex rf-items-center rf-gap-2",children:[u.lastRenderEvent&&_t.jsx("div",{className:"rf-text-xs rf-text-gray-500",children:(fe=u.lastRenderEvent)==null?void 0:fe.type.split("renderable:renderLifecycle:")[1].split(":")[0]}),_t.jsx("div",{className:"rf-w-4 rf-h-4 rf-bg-blue-500 rf-opacity-50 rf-rounded-full rf-text-white",children:_t.jsx(zfe,{className:"rf-w-4 rf-h-4 rf-animate-spin"})}),_t.jsxs("div",{className:"rf-text-xs rf-font-bold rf-text-gray-700 rf-tabular-nums",children:[((u.progress??0)*100).toFixed(1),"%"]})]}),_t.jsxs(Wme,{children:[a&&_t.jsx(N7,{value:"code",children:"Code"}),_t.jsxs(N7,{value:"pcb",className:"rf-whitespace-nowrap",children:[i&&_t.jsx("span",{className:mg("rf-inline-flex rf-items-center rf-justify-center rf-w-2 rf-h-2 rf-mr-1 rf-text-xs rf-font-bold rf-text-white rf-rounded-full",U?"rf-bg-gray-500":"rf-bg-blue-500")}),"PCB"]}),_t.jsxs(N7,{value:"schematic",className:"rf-whitespace-nowrap",children:[i&&_t.jsx("span",{className:mg("rf-inline-flex rf-items-center rf-justify-center rf-w-2 rf-h-2 rf-mr-1 rf-text-xs rf-font-bold rf-text-white rf-rounded-full",U?"rf-bg-gray-500":"rf-bg-blue-500")}),"Schematic"]}),_t.jsxs(N7,{value:"cad",children:[i&&_t.jsx("span",{className:mg("inline-flex items-center justify-center w-2 h-2 mr-1 text-xs font-bold text-white rounded-full",U?"rf-bg-gray-500":"rf-bg-blue-500")}),"3D"]}),!["pcb","cad","schematic"].includes(te)&&_t.jsx(N7,{value:te,children:Xme(te)}),_t.jsxs(Ihn,{children:[_t.jsx(Bhn,{asChild:!0,children:_t.jsxs("div",{className:"rf-whitespace-nowrap rf-p-2 rf-mr-1 rf-cursor-pointer rf-relative",children:[_t.jsx(Aan,{className:"rf-w-4 rf-h-4"}),t&&_t.jsx("span",{className:"rf-inline-flex rf-absolute rf-top-[6px] rf-right-[4px] rf-items-center rf-justify-center rf-w-1 rf-h-1 rf-ml-2 rf-text-[8px] rf-font-bold rf-text-white rf-bg-red-500 rf-rounded-full"})]})}),_t.jsx(cat,{className:"rf-*:text-xs",children:Khn.map(de=>_t.jsxs(uat,{onSelect:()=>se(de),children:[_t.jsx(FJe,{className:mg("rf-w-3 rf-h-3 rf-mr-2",te!==de&&"rf-invisible")}),_t.jsx("div",{className:"rf-pr-2",children:Xme(de)}),de==="errors"&&t&&_t.jsx("span",{className:"rf-inline-flex rf-items-center rf-justify-center rf-w-3 rf-h-3 rf-ml-2 rf-text-[8px] rf-font-bold rf-text-white rf-bg-red-500 rf-rounded-full",children:"1"})]},de))})]})]}),b&&_t.jsx(Ow,{onClick:b,variant:"ghost",children:C?_t.jsx(Dan,{size:16}):_t.jsx(Pan,{size:16})})]}),a&&_t.jsx(fb,{value:"code",className:"rf-flex-grow rf-overflow-hidden",children:_t.jsx("div",{className:"rf-h-full",children:o})}),_t.jsx(fb,{value:"pcb",children:_t.jsx("div",{className:mg("rf-overflow-hidden",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading PCB viewer"}),children:i?_t.jsx(Yhn,{soup:i,containerClassName:mg("rf-h-full rf-w-full",C?"rf-min-h-[calc(100vh-240px)]":"rf-min-h-[620px]")},n):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"assembly",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading Assembly"}),children:i?_t.jsx(sfn,{circuitJson:i,containerStyle:{height:"100%"},editingEnabled:!0,debugGrid:!0}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"schematic",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading Schematic"}),children:i?_t.jsx(ifn,{circuitJson:i,containerStyle:{height:"100%"},editingEnabled:!0,onEditEvent:de=>G==null?void 0:G(de),editEvents:Z,debugGrid:!0}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"cad",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{FallbackComponent:yan,children:i?_t.jsx(yYt,{soup:i}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"bom",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading BOM"}),children:i?_t.jsx(ffn,{circuitJson:i}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"circuit_json",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading JSON viewer"}),children:i?_t.jsx(cfn,{elements:i}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"errors",children:i||t?_t.jsx(zan,{code:r,errorMessage:t}):_t.jsx(h7,{onRunClicked:e})}),l&&_t.jsx(fb,{value:"render_log",children:_t.jsx(Qhn,{renderLog:u})})]})})})};/**
13125
+ `)},Cpn=0,$w=[];function Rpn(r){var e=Ct.useRef([]),t=Ct.useRef([0,0]),n=Ct.useRef(),i=Ct.useState(Cpn++)[0],a=Ct.useState(ypn)[0],o=Ct.useRef(r);Ct.useEffect(function(){o.current=r},[r]),Ct.useEffect(function(){if(r.inert){document.body.classList.add("block-interactivity-".concat(i));var E=Hdn([r.lockRef.current],(r.shards||[]).map(pit),!0).filter(Boolean);return E.forEach(function(S){return S.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),E.forEach(function(S){return S.classList.remove("allow-interactivity-".concat(i))})}}},[r.inert,r.lockRef.current,r.shards]);var s=Ct.useCallback(function(E,S){if("touches"in E&&E.touches.length===2||E.type==="wheel"&&E.ctrlKey)return!o.current.allowPinchZoom;var b=zF(E),C=t.current,N="deltaX"in E?E.deltaX:C[0]-b[0],U="deltaY"in E?E.deltaY:C[1]-b[1],G,Z=E.target,$=Math.abs(N)>Math.abs(U)?"h":"v";if("touches"in E&&$==="h"&&Z.type==="range")return!1;var te=cit($,Z);if(!te)return!0;if(te?G=$:(G=$==="v"?"h":"v",te=cit($,Z)),!te)return!1;if(!n.current&&"changedTouches"in E&&(N||U)&&(n.current=G),!G)return!0;var re=n.current||G;return wpn(re,S,E,re==="h"?N:U,!0)},[]),l=Ct.useCallback(function(E){var S=E;if(!(!$w.length||$w[$w.length-1]!==a)){var b="deltaY"in S?dit(S):zF(S),C=e.current.filter(function(G){return G.name===S.type&&(G.target===S.target||S.target===G.shadowParent)&&Tpn(G.delta,b)})[0];if(C&&C.should){S.cancelable&&S.preventDefault();return}if(!C){var N=(o.current.shards||[]).map(pit).filter(Boolean).filter(function(G){return G.contains(S.target)}),U=N.length>0?s(S,N[0]):!o.current.noIsolation;U&&S.cancelable&&S.preventDefault()}}},[]),c=Ct.useCallback(function(E,S,b,C){var N={name:E,delta:S,target:b,should:C,shadowParent:Apn(b)};e.current.push(N),setTimeout(function(){e.current=e.current.filter(function(U){return U!==N})},1)},[]),u=Ct.useCallback(function(E){t.current=zF(E),n.current=void 0},[]),f=Ct.useCallback(function(E){c(E.type,dit(E),E.target,s(E,r.lockRef.current))},[]),h=Ct.useCallback(function(E){c(E.type,zF(E),E.target,s(E,r.lockRef.current))},[]);Ct.useEffect(function(){return $w.push(a),r.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:h}),document.addEventListener("wheel",l,qw),document.addEventListener("touchmove",l,qw),document.addEventListener("touchstart",u,qw),function(){$w=$w.filter(function(E){return E!==a}),document.removeEventListener("wheel",l,qw),document.removeEventListener("touchmove",l,qw),document.removeEventListener("touchstart",u,qw)}},[]);var v=r.removeScrollBar,x=r.inert;return Ct.createElement(Ct.Fragment,null,x?Ct.createElement(a,{styles:Mpn(i)}):null,v?Ct.createElement(fpn,{gapMode:r.gapMode}):null)}function Apn(r){for(var e=null;r!==null;)r instanceof ShadowRoot&&(e=r.host,r=r.host),r=r.parentNode;return e}const Ppn=Kdn(ait,Rpn);var hit=Ct.forwardRef(function(r,e){return Ct.createElement(NF,Hb({},r,{ref:e,sideCar:Ppn}))});hit.classNames=NF.classNames;var Ppe=["Enter"," "],Dpn=["ArrowDown","PageUp","Home"],mit=["ArrowUp","PageDown","End"],Npn=[...Dpn,...mit],Lpn={ltr:[...Ppe,"ArrowRight"],rtl:[...Ppe,"ArrowLeft"]},zpn={ltr:["ArrowLeft"],rtl:["ArrowRight"]},HR="Menu",[qR,Opn,Upn]=fme(HR),[v7,vit]=M7(HR,[Upn,$rt,SA]),OF=$rt(),yit=SA(),[kpn,y7]=v7(HR),[Fpn,$R]=v7(HR),git=r=>{const{__scopeMenu:e,open:t=!1,children:n,dir:i,onOpenChange:a,modal:o=!0}=r,s=OF(e),[l,c]=Ct.useState(null),u=Ct.useRef(!1),f=D4(a),h=CI(i);return Ct.useEffect(()=>{const v=()=>{u.current=!0,document.addEventListener("pointerdown",x,{capture:!0,once:!0}),document.addEventListener("pointermove",x,{capture:!0,once:!0})},x=()=>u.current=!1;return document.addEventListener("keydown",v,{capture:!0}),()=>{document.removeEventListener("keydown",v,{capture:!0}),document.removeEventListener("pointerdown",x,{capture:!0}),document.removeEventListener("pointermove",x,{capture:!0})}},[]),_t.jsx(zdn,{...s,children:_t.jsx(kpn,{scope:e,open:t,onOpenChange:f,content:l,onContentChange:c,children:_t.jsx(Fpn,{scope:e,onClose:Ct.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:u,dir:h,modal:o,children:n})})})};git.displayName=HR;var Ipn="MenuAnchor",Dpe=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r,i=OF(t);return _t.jsx(Odn,{...i,...n,ref:e})});Dpe.displayName=Ipn;var Npe="MenuPortal",[Bpn,_it]=v7(Npe,{forceMount:void 0}),xit=r=>{const{__scopeMenu:e,forceMount:t,children:n,container:i}=r,a=y7(Npe,e);return _t.jsx(Bpn,{scope:e,forceMount:t,children:_t.jsx(A7,{present:t||a.open,children:_t.jsx(eit,{asChild:!0,container:i,children:n})})})};xit.displayName=Npe;var b4="MenuContent",[jpn,Lpe]=v7(b4),bit=Ct.forwardRef((r,e)=>{const t=_it(b4,r.__scopeMenu),{forceMount:n=t.forceMount,...i}=r,a=y7(b4,r.__scopeMenu),o=$R(b4,r.__scopeMenu);return _t.jsx(qR.Provider,{scope:r.__scopeMenu,children:_t.jsx(A7,{present:n||a.open,children:_t.jsx(qR.Slot,{scope:r.__scopeMenu,children:o.modal?_t.jsx(Vpn,{...i,ref:e}):_t.jsx(Hpn,{...i,ref:e})})})})}),Vpn=Ct.forwardRef((r,e)=>{const t=y7(b4,r.__scopeMenu),n=Ct.useRef(null),i=x3(e,n);return Ct.useEffect(()=>{const a=n.current;if(a)return Vdn(a)},[]),_t.jsx(zpe,{...r,ref:i,trapFocus:t.open,disableOutsidePointerEvents:t.open,disableOutsideScroll:!0,onFocusOutside:Fm(r.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>t.onOpenChange(!1)})}),Hpn=Ct.forwardRef((r,e)=>{const t=y7(b4,r.__scopeMenu);return _t.jsx(zpe,{...r,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>t.onOpenChange(!1)})}),zpe=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,loop:n=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:l,onEscapeKeyDown:c,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:h,onDismiss:v,disableOutsideScroll:x,...E}=r,S=y7(b4,t),b=$R(b4,t),C=OF(t),N=yit(t),U=Opn(t),[G,Z]=Ct.useState(null),$=Ct.useRef(null),te=x3(e,$,S.onContentChange),re=Ct.useRef(0),se=Ct.useRef(""),fe=Ct.useRef(0),de=Ct.useRef(null),ye=Ct.useRef("right"),Se=Ct.useRef(0),Re=x?hit:Ct.Fragment,Te=x?{as:C7,allowPinchZoom:!0}:void 0,Ce=Fe=>{var dt,kt;const Ie=se.current+Fe,ke=U().filter(qt=>!qt.disabled),Ee=document.activeElement,$e=(dt=ke.find(qt=>qt.ref.current===Ee))==null?void 0:dt.textValue,tt=ke.map(qt=>qt.textValue),ut=thn(tt,Ie,$e),gt=(kt=ke.find(qt=>qt.textValue===ut))==null?void 0:kt.ref.current;(function qt(Dn){se.current=Dn,window.clearTimeout(re.current),Dn!==""&&(re.current=window.setTimeout(()=>qt(""),1e3))})(Ie),gt&&setTimeout(()=>gt.focus())};Ct.useEffect(()=>()=>window.clearTimeout(re.current),[]),xfn();const Me=Ct.useCallback(Fe=>{var ke,Ee;return ye.current===((ke=de.current)==null?void 0:ke.side)&&rhn(Fe,(Ee=de.current)==null?void 0:Ee.area)},[]);return _t.jsx(jpn,{scope:t,searchRef:se,onItemEnter:Ct.useCallback(Fe=>{Me(Fe)&&Fe.preventDefault()},[Me]),onItemLeave:Ct.useCallback(Fe=>{var Ie;Me(Fe)||((Ie=$.current)==null||Ie.focus(),Z(null))},[Me]),onTriggerLeave:Ct.useCallback(Fe=>{Me(Fe)&&Fe.preventDefault()},[Me]),pointerGraceTimerRef:fe,onPointerGraceIntentChange:Ct.useCallback(Fe=>{de.current=Fe},[]),children:_t.jsx(Re,{...Te,children:_t.jsx(brt,{asChild:!0,trapped:i,onMountAutoFocus:Fm(a,Fe=>{var Ie;Fe.preventDefault(),(Ie=$.current)==null||Ie.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:_t.jsx(vrt,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:c,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:h,onDismiss:v,children:_t.jsx(Tme,{asChild:!0,...N,dir:b.dir,orientation:"vertical",loop:n,currentTabStopId:G,onCurrentTabStopIdChange:Z,onEntryFocus:Fm(l,Fe=>{b.isUsingKeyboardRef.current||Fe.preventDefault()}),preventScrollOnEntryFocus:!0,children:_t.jsx(Udn,{role:"menu","aria-orientation":"vertical","data-state":Fit(S.open),"data-radix-menu-content":"",dir:b.dir,...C,...E,ref:te,style:{outline:"none",...E.style},onKeyDown:Fm(E.onKeyDown,Fe=>{const ke=Fe.target.closest("[data-radix-menu-content]")===Fe.currentTarget,Ee=Fe.ctrlKey||Fe.altKey||Fe.metaKey,$e=Fe.key.length===1;ke&&(Fe.key==="Tab"&&Fe.preventDefault(),!Ee&&$e&&Ce(Fe.key));const tt=$.current;if(Fe.target!==tt||!Npn.includes(Fe.key))return;Fe.preventDefault();const gt=U().filter(dt=>!dt.disabled).map(dt=>dt.ref.current);mit.includes(Fe.key)&&gt.reverse(),Jpn(gt)}),onBlur:Fm(r.onBlur,Fe=>{Fe.currentTarget.contains(Fe.target)||(window.clearTimeout(re.current),se.current="")}),onPointerMove:Fm(r.onPointerMove,YR(Fe=>{const Ie=Fe.target,ke=Se.current!==Fe.clientX;if(Fe.currentTarget.contains(Ie)&&ke){const Ee=Fe.clientX>Se.current?"right":"left";ye.current=Ee,Se.current=Fe.clientX}}))})})})})})})});bit.displayName=b4;var qpn="MenuGroup",Ope=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r;return _t.jsx(e2.div,{role:"group",...n,ref:e})});Ope.displayName=qpn;var $pn="MenuLabel",Sit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r;return _t.jsx(e2.div,{...n,ref:e})});Sit.displayName=$pn;var UF="MenuItem",Eit="menu.itemSelect",kF=Ct.forwardRef((r,e)=>{const{disabled:t=!1,onSelect:n,...i}=r,a=Ct.useRef(null),o=$R(UF,r.__scopeMenu),s=Lpe(UF,r.__scopeMenu),l=x3(e,a),c=Ct.useRef(!1),u=()=>{const f=a.current;if(!t&&f){const h=new CustomEvent(Eit,{bubbles:!0,cancelable:!0});f.addEventListener(Eit,v=>n==null?void 0:n(v),{once:!0}),_me(f,h),h.defaultPrevented?c.current=!1:o.onClose()}};return _t.jsx(wit,{...i,ref:l,disabled:t,onClick:Fm(r.onClick,u),onPointerDown:f=>{var h;(h=r.onPointerDown)==null||h.call(r,f),c.current=!0},onPointerUp:Fm(r.onPointerUp,f=>{var h;c.current||(h=f.currentTarget)==null||h.click()}),onKeyDown:Fm(r.onKeyDown,f=>{const h=s.searchRef.current!=="";t||h&&f.key===" "||Ppe.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})})});kF.displayName=UF;var wit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,disabled:n=!1,textValue:i,...a}=r,o=Lpe(UF,t),s=yit(t),l=Ct.useRef(null),c=x3(e,l),[u,f]=Ct.useState(!1),[h,v]=Ct.useState("");return Ct.useEffect(()=>{const x=l.current;x&&v((x.textContent??"").trim())},[a.children]),_t.jsx(qR.ItemSlot,{scope:t,disabled:n,textValue:i??h,children:_t.jsx(Mme,{asChild:!0,...s,focusable:!n,children:_t.jsx(e2.div,{role:"menuitem","data-highlighted":u?"":void 0,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,...a,ref:c,onPointerMove:Fm(r.onPointerMove,YR(x=>{n?o.onItemLeave(x):(o.onItemEnter(x),x.defaultPrevented||x.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:Fm(r.onPointerLeave,YR(x=>o.onItemLeave(x))),onFocus:Fm(r.onFocus,()=>f(!0)),onBlur:Fm(r.onBlur,()=>f(!1))})})})}),Gpn="MenuCheckboxItem",Tit=Ct.forwardRef((r,e)=>{const{checked:t=!1,onCheckedChange:n,...i}=r;return _t.jsx(Pit,{scope:r.__scopeMenu,checked:t,children:_t.jsx(kF,{role:"menuitemcheckbox","aria-checked":FF(t)?"mixed":t,...i,ref:e,"data-state":kpe(t),onSelect:Fm(i.onSelect,()=>n==null?void 0:n(FF(t)?!0:!t),{checkForDefaultPrevented:!1})})})});Tit.displayName=Gpn;var Mit="MenuRadioGroup",[Ypn,Xpn]=v7(Mit,{value:void 0,onValueChange:()=>{}}),Cit=Ct.forwardRef((r,e)=>{const{value:t,onValueChange:n,...i}=r,a=D4(n);return _t.jsx(Ypn,{scope:r.__scopeMenu,value:t,onValueChange:a,children:_t.jsx(Ope,{...i,ref:e})})});Cit.displayName=Mit;var Rit="MenuRadioItem",Ait=Ct.forwardRef((r,e)=>{const{value:t,...n}=r,i=Xpn(Rit,r.__scopeMenu),a=t===i.value;return _t.jsx(Pit,{scope:r.__scopeMenu,checked:a,children:_t.jsx(kF,{role:"menuitemradio","aria-checked":a,...n,ref:e,"data-state":kpe(a),onSelect:Fm(n.onSelect,()=>{var o;return(o=i.onValueChange)==null?void 0:o.call(i,t)},{checkForDefaultPrevented:!1})})})});Ait.displayName=Rit;var Upe="MenuItemIndicator",[Pit,Wpn]=v7(Upe,{checked:!1}),Dit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,forceMount:n,...i}=r,a=Wpn(Upe,t);return _t.jsx(A7,{present:n||FF(a.checked)||a.checked===!0,children:_t.jsx(e2.span,{...i,ref:e,"data-state":kpe(a.checked)})})});Dit.displayName=Upe;var Zpn="MenuSeparator",Nit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r;return _t.jsx(e2.div,{role:"separator","aria-orientation":"horizontal",...n,ref:e})});Nit.displayName=Zpn;var Qpn="MenuArrow",Lit=Ct.forwardRef((r,e)=>{const{__scopeMenu:t,...n}=r,i=OF(t);return _t.jsx(kdn,{...i,...n,ref:e})});Lit.displayName=Qpn;var Kpn="MenuSub",[Qyn,zit]=v7(Kpn),GR="MenuSubTrigger",Oit=Ct.forwardRef((r,e)=>{const t=y7(GR,r.__scopeMenu),n=$R(GR,r.__scopeMenu),i=zit(GR,r.__scopeMenu),a=Lpe(GR,r.__scopeMenu),o=Ct.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:l}=a,c={__scopeMenu:r.__scopeMenu},u=Ct.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);return Ct.useEffect(()=>u,[u]),Ct.useEffect(()=>{const f=s.current;return()=>{window.clearTimeout(f),l(null)}},[s,l]),_t.jsx(Dpe,{asChild:!0,...c,children:_t.jsx(wit,{id:i.triggerId,"aria-haspopup":"menu","aria-expanded":t.open,"aria-controls":i.contentId,"data-state":Fit(t.open),...r,ref:yA(e,i.onTriggerChange),onClick:f=>{var h;(h=r.onClick)==null||h.call(r,f),!(r.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),t.open||t.onOpenChange(!0))},onPointerMove:Fm(r.onPointerMove,YR(f=>{a.onItemEnter(f),!f.defaultPrevented&&!r.disabled&&!t.open&&!o.current&&(a.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{t.onOpenChange(!0),u()},100))})),onPointerLeave:Fm(r.onPointerLeave,YR(f=>{var v,x;u();const h=(v=t.content)==null?void 0:v.getBoundingClientRect();if(h){const E=(x=t.content)==null?void 0:x.dataset.side,S=E==="right",b=S?-5:5,C=h[S?"left":"right"],N=h[S?"right":"left"];a.onPointerGraceIntentChange({area:[{x:f.clientX+b,y:f.clientY},{x:C,y:h.top},{x:N,y:h.top},{x:N,y:h.bottom},{x:C,y:h.bottom}],side:E}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(f),f.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:Fm(r.onKeyDown,f=>{var v;const h=a.searchRef.current!=="";r.disabled||h&&f.key===" "||Lpn[n.dir].includes(f.key)&&(t.onOpenChange(!0),(v=t.content)==null||v.focus(),f.preventDefault())})})})});Oit.displayName=GR;var Uit="MenuSubContent",kit=Ct.forwardRef((r,e)=>{const t=_it(b4,r.__scopeMenu),{forceMount:n=t.forceMount,...i}=r,a=y7(b4,r.__scopeMenu),o=$R(b4,r.__scopeMenu),s=zit(Uit,r.__scopeMenu),l=Ct.useRef(null),c=x3(e,l);return _t.jsx(qR.Provider,{scope:r.__scopeMenu,children:_t.jsx(A7,{present:n||a.open,children:_t.jsx(qR.Slot,{scope:r.__scopeMenu,children:_t.jsx(zpe,{id:s.contentId,"aria-labelledby":s.triggerId,...i,ref:c,align:"start",side:o.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:u=>{var f;o.isUsingKeyboardRef.current&&((f=l.current)==null||f.focus()),u.preventDefault()},onCloseAutoFocus:u=>u.preventDefault(),onFocusOutside:Fm(r.onFocusOutside,u=>{u.target!==s.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:Fm(r.onEscapeKeyDown,u=>{o.onClose(),u.preventDefault()}),onKeyDown:Fm(r.onKeyDown,u=>{var v;const f=u.currentTarget.contains(u.target),h=zpn[o.dir].includes(u.key);f&&h&&(a.onOpenChange(!1),(v=s.trigger)==null||v.focus(),u.preventDefault())})})})})})});kit.displayName=Uit;function Fit(r){return r?"open":"closed"}function FF(r){return r==="indeterminate"}function kpe(r){return FF(r)?"indeterminate":r?"checked":"unchecked"}function Jpn(r){const e=document.activeElement;for(const t of r)if(t===e||(t.focus(),document.activeElement!==e))return}function ehn(r,e){return r.map((t,n)=>r[(e+n)%r.length])}function thn(r,e,t){const i=e.length>1&&Array.from(e).every(c=>c===e[0])?e[0]:e,a=t?r.indexOf(t):-1;let o=ehn(r,Math.max(a,0));i.length===1&&(o=o.filter(c=>c!==t));const l=o.find(c=>c.toLowerCase().startsWith(i.toLowerCase()));return l!==t?l:void 0}function nhn(r,e){const{x:t,y:n}=r;let i=!1;for(let a=0,o=e.length-1;a<e.length;o=a++){const s=e[a].x,l=e[a].y,c=e[o].x,u=e[o].y;l>n!=u>n&&t<(c-s)*(n-l)/(u-l)+s&&(i=!i)}return i}function rhn(r,e){if(!e)return!1;const t={x:r.clientX,y:r.clientY};return nhn(t,e)}function YR(r){return e=>e.pointerType==="mouse"?r(e):void 0}var ihn=git,ahn=Dpe,ohn=xit,shn=bit,lhn=Ope,chn=Sit,uhn=kF,fhn=Tit,dhn=Cit,phn=Ait,hhn=Dit,mhn=Nit,vhn=Lit,yhn=Oit,ghn=kit,Fpe="DropdownMenu",[_hn,Kyn]=M7(Fpe,[vit]),s3=vit(),[xhn,Iit]=_hn(Fpe),Bit=r=>{const{__scopeDropdownMenu:e,children:t,dir:n,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=r,l=s3(e),c=Ct.useRef(null),[u=!1,f]=MI({prop:i,defaultProp:a,onChange:o});return _t.jsx(xhn,{scope:e,triggerId:gA(),triggerRef:c,contentId:gA(),open:u,onOpenChange:f,onOpenToggle:Ct.useCallback(()=>f(h=>!h),[f]),modal:s,children:_t.jsx(ihn,{...l,open:u,onOpenChange:f,dir:n,modal:s,children:t})})};Bit.displayName=Fpe;var jit="DropdownMenuTrigger",Vit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,disabled:n=!1,...i}=r,a=Iit(jit,t),o=s3(t);return _t.jsx(ahn,{asChild:!0,...o,children:_t.jsx(e2.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":n?"":void 0,disabled:n,...i,ref:yA(e,a.triggerRef),onPointerDown:Fm(r.onPointerDown,s=>{!n&&s.button===0&&s.ctrlKey===!1&&(a.onOpenToggle(),a.open||s.preventDefault())}),onKeyDown:Fm(r.onKeyDown,s=>{n||(["Enter"," "].includes(s.key)&&a.onOpenToggle(),s.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});Vit.displayName=jit;var bhn="DropdownMenuPortal",Hit=r=>{const{__scopeDropdownMenu:e,...t}=r,n=s3(e);return _t.jsx(ohn,{...n,...t})};Hit.displayName=bhn;var qit="DropdownMenuContent",$it=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=Iit(qit,t),a=s3(t),o=Ct.useRef(!1);return _t.jsx(shn,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...n,ref:e,onCloseAutoFocus:Fm(r.onCloseAutoFocus,s=>{var l;o.current||(l=i.triggerRef.current)==null||l.focus(),o.current=!1,s.preventDefault()}),onInteractOutside:Fm(r.onInteractOutside,s=>{const l=s.detail.originalEvent,c=l.button===0&&l.ctrlKey===!0,u=l.button===2||c;(!i.modal||u)&&(o.current=!0)}),style:{...r.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});$it.displayName=qit;var Shn="DropdownMenuGroup",Ehn=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(lhn,{...i,...n,ref:e})});Ehn.displayName=Shn;var whn="DropdownMenuLabel",Git=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(chn,{...i,...n,ref:e})});Git.displayName=whn;var Thn="DropdownMenuItem",Yit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(uhn,{...i,...n,ref:e})});Yit.displayName=Thn;var Mhn="DropdownMenuCheckboxItem",Xit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(fhn,{...i,...n,ref:e})});Xit.displayName=Mhn;var Chn="DropdownMenuRadioGroup",Rhn=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(dhn,{...i,...n,ref:e})});Rhn.displayName=Chn;var Ahn="DropdownMenuRadioItem",Wit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(phn,{...i,...n,ref:e})});Wit.displayName=Ahn;var Phn="DropdownMenuItemIndicator",Zit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(hhn,{...i,...n,ref:e})});Zit.displayName=Phn;var Dhn="DropdownMenuSeparator",Qit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(mhn,{...i,...n,ref:e})});Qit.displayName=Dhn;var Nhn="DropdownMenuArrow",Lhn=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(vhn,{...i,...n,ref:e})});Lhn.displayName=Nhn;var zhn="DropdownMenuSubTrigger",Kit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(yhn,{...i,...n,ref:e})});Kit.displayName=zhn;var Ohn="DropdownMenuSubContent",Jit=Ct.forwardRef((r,e)=>{const{__scopeDropdownMenu:t,...n}=r,i=s3(t);return _t.jsx(ghn,{...i,...n,ref:e,style:{...r.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Jit.displayName=Ohn;var Uhn=Bit,khn=Vit,Fhn=Hit,eat=$it,tat=Git,nat=Yit,rat=Xit,iat=Wit,aat=Zit,oat=Qit,sat=Kit,lat=Jit;const Ihn=Uhn,Bhn=khn,jhn=Ct.forwardRef(({className:r,inset:e,children:t,...n},i)=>_t.jsxs(sat,{ref:i,className:mg("rf-flex rf-cursor-default rf-gap-2 rf-select-none rf-items-center rf-rounded-sm rf-px-2 rf-py-1.5 rf-text-sm rf-outline-none focus:rf-bg-zinc-100 data-[state=open]:rf-bg-zinc-100 [&_svg]:rf-pointer-events-none [&_svg]:rf-size-4 [&_svg]:rf-shrink-0 dark:focus:rf-bg-zinc-800 dark:data-[state=open]:rf-bg-zinc-800",e&&"rf-pl-8",r),...n,children:[t,_t.jsx(Man,{className:"rf-ml-auto"})]}));jhn.displayName=sat.displayName;const Vhn=Ct.forwardRef(({className:r,...e},t)=>_t.jsx(lat,{ref:t,className:mg("rf-z-50 rf-min-w-[8rem] rf-overflow-hidden rf-rounded-md rf-border rf-border-zinc-200 rf-bg-white rf-p-1 rf-text-zinc-950 rf-shadow-lg data-[state=open]:rf-animate-in data-[state=closed]:rf-animate-out data-[state=closed]:rf-fade-out-0 data-[state=open]:rf-fade-in-0 data-[state=closed]:rf-zoom-out-95 data-[state=open]:rf-zoom-in-95 data-[side=bottom]:rf-slide-in-from-top-2 data-[side=left]:rf-slide-in-from-right-2 data-[side=right]:rf-slide-in-from-left-2 data-[side=top]:rf-slide-in-from-bottom-2 dark:rf-border-zinc-800 dark:rf-bg-zinc-950 dark:rf-text-zinc-50",r),...e}));Vhn.displayName=lat.displayName;const cat=Ct.forwardRef(({className:r,sideOffset:e=4,...t},n)=>_t.jsx(Fhn,{children:_t.jsx(eat,{ref:n,sideOffset:e,className:mg("rf-z-50 rf-min-w-[8rem] rf-overflow-hidden rf-rounded-md rf-border rf-border-zinc-200 rf-bg-white rf-p-1 rf-text-zinc-950 rf-shadow-md dark:rf-border-zinc-800 dark:rf-bg-zinc-950 dark:rf-text-zinc-50","data-[state=open]:rf-animate-in data-[state=closed]:rf-animate-out data-[state=closed]:rf-fade-out-0 data-[state=open]:rf-fade-in-0 data-[state=closed]:rf-zoom-out-95 data-[state=open]:rf-zoom-in-95 data-[side=bottom]:rf-slide-in-from-top-2 data-[side=left]:rf-slide-in-from-right-2 data-[side=right]:rf-slide-in-from-left-2 data-[side=top]:rf-slide-in-from-bottom-2",r),...t})}));cat.displayName=eat.displayName;const uat=Ct.forwardRef(({className:r,inset:e,...t},n)=>_t.jsx(nat,{ref:n,className:mg("rf-relative rf-flex rf-cursor-default rf-select-none rf-items-center rf-gap-2 rf-rounded-sm rf-px-2 rf-py-1.5 rf-text-sm rf-outline-none rf-transition-colors focus:rf-bg-zinc-100 focus:rf-text-zinc-900 data-[disabled]:rf-pointer-events-none data-[disabled]:rf-opacity-50 [&>svg]:rf-size-4 [&>svg]:rf-shrink-0 dark:focus:rf-bg-zinc-800 dark:focus:rf-text-zinc-50",e&&"rf-pl-8",r),...t}));uat.displayName=nat.displayName;const Hhn=Ct.forwardRef(({className:r,children:e,checked:t,...n},i)=>_t.jsxs(rat,{ref:i,className:mg("rf-relative rf-flex rf-cursor-default rf-select-none rf-items-center rf-rounded-sm rf-py-1.5 rf-pl-8 rf-pr-2 rf-text-sm rf-outline-none rf-transition-colors focus:rf-bg-zinc-100 focus:rf-text-zinc-900 data-[disabled]:rf-pointer-events-none data-[disabled]:rf-opacity-50 dark:focus:rf-bg-zinc-800 dark:focus:rf-text-zinc-50",r),checked:t,...n,children:[_t.jsx("span",{className:"rf-absolute rf-left-2 rf-flex rf-h-3.5 rf-w-3.5 rf-items-center rf-justify-center",children:_t.jsx(aat,{children:_t.jsx(FJe,{className:"rf-h-4 rf-w-4"})})}),e]}));Hhn.displayName=rat.displayName;const qhn=Ct.forwardRef(({className:r,children:e,...t},n)=>_t.jsxs(iat,{ref:n,className:mg("rf-relative rf-flex rf-cursor-default rf-select-none rf-items-center rf-rounded-sm rf-py-1.5 rf-pl-8 rf-pr-2 rf-text-sm rf-outline-none rf-transition-colors focus:rf-bg-zinc-100 focus:rf-text-zinc-900 data-[disabled]:rf-pointer-events-none data-[disabled]:rf-opacity-50 dark:focus:rf-bg-zinc-800 dark:focus:rf-text-zinc-50",r),...t,children:[_t.jsx("span",{className:"rf-absolute rf-left-2 rf-flex rf-h-3.5 rf-w-3.5 rf-items-center rf-justify-center",children:_t.jsx(aat,{children:_t.jsx(Can,{className:"rf-h-2 rf-w-2 rf-fill-current"})})}),e]}));qhn.displayName=iat.displayName;const $hn=Ct.forwardRef(({className:r,inset:e,...t},n)=>_t.jsx(tat,{ref:n,className:mg("rf-px-2 rf-py-1.5 rf-text-sm rf-font-semibold",e&&"rf-pl-8",r),...t}));$hn.displayName=tat.displayName;const Ghn=Ct.forwardRef(({className:r,...e},t)=>_t.jsx(oat,{ref:t,className:mg("rf--mx-1 rf-my-1 rf-h-px rf-bg-zinc-100 dark:rf-bg-zinc-800",r),...e}));Ghn.displayName=oat.displayName;const Yhn=({containerClassName:r,...e})=>{const t=Ct.useRef(null),[n,i]=Ct.useState(620);return Ct.useLayoutEffect(()=>{const a=()=>{if(t.current){const s=t.current.clientHeight,l=window.innerHeight;i(Math.min(Math.max(s,620),l))}};a();const o=new ResizeObserver(a);return t.current&&o.observe(t.current),window.addEventListener("resize",a),()=>{o.disconnect(),window.removeEventListener("resize",a)}},[]),_t.jsx("div",{ref:t,className:r||"rf-w-full rf-h-full",children:_t.jsx(van,{...e,height:n})})},Xhn='*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-feature-settings:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]:where(:not([hidden=until-found])){display:none}:root{--radius:0.5rem}.rf-pointer-events-none{pointer-events:none}.rf-invisible{visibility:hidden}.rf-fixed{position:fixed}.rf-absolute{position:absolute}.rf-relative{position:relative}.rf-inset-0{inset:0}.-rf-left-2{left:-.5rem}.-rf-right-10{right:-2.5rem}.-rf-right-2{right:-.5rem}.-rf-right-4{right:-1rem}.-rf-right-6{right:-1.5rem}.-rf-right-7{right:-1.75rem}.-rf-right-8{right:-2rem}.-rf-right-9{right:-2.25rem}.rf-bottom-full{bottom:100%}.rf-left-1{left:.25rem}.rf-left-1\\/2{left:50%}.rf-left-2{left:.5rem}.rf-right-0{right:0}.rf-right-4{right:1rem}.rf-right-\\[4px\\]{right:4px}.rf-top-1{top:.25rem}.rf-top-2{top:.5rem}.rf-top-\\[6px\\]{top:6px}.rf-z-50{z-index:50}.rf-z-\\[100\\]{z-index:100}.rf--mx-1{margin-left:-.25rem;margin-right:-.25rem}.rf-mx-2{margin-left:.5rem;margin-right:.5rem}.rf-my-1{margin-bottom:.25rem;margin-top:.25rem}.rf-mb-2{margin-bottom:.5rem}.rf-mb-3{margin-bottom:.75rem}.rf-mb-4{margin-bottom:1rem}.rf-ml-1{margin-left:.25rem}.rf-ml-1\\.5{margin-left:.375rem}.rf-ml-2{margin-left:.5rem}.rf-ml-auto{margin-left:auto}.rf-mr-1{margin-right:.25rem}.rf-mr-2{margin-right:.5rem}.rf-mt-0{margin-top:0}.rf-mt-2{margin-top:.5rem}.rf-mt-4{margin-top:1rem}.rf-flex{display:flex}.rf-inline-flex{display:inline-flex}.rf-size-4{height:1rem;width:1rem}.\\!rf-h-2{height:.5rem!important}.\\!rf-h-2\\.5{height:.625rem!important}.\\!rf-h-3{height:.75rem!important}.rf-h-1{height:.25rem}.rf-h-10{height:2.5rem}.rf-h-2{height:.5rem}.rf-h-3{height:.75rem}.rf-h-3\\.5{height:.875rem}.rf-h-4{height:1rem}.rf-h-60{height:15rem}.rf-h-8{height:2rem}.rf-h-9{height:2.25rem}.rf-h-\\[620px\\]{height:620px}.rf-h-\\[calc\\(100vh-96px\\)\\]{height:calc(100vh - 96px)}.rf-h-full{height:100%}.rf-h-px{height:1px}.rf-max-h-\\[500px\\]{max-height:500px}.rf-min-h-\\[620px\\]{min-height:620px}.rf-min-h-\\[calc\\(100vh-240px\\)\\]{min-height:calc(100vh - 240px)}.\\!rf-w-2{width:.5rem!important}.\\!rf-w-2\\.5{width:.625rem!important}.rf-w-1{width:.25rem}.rf-w-11{width:2.75rem}.rf-w-11\\/12{width:91.666667%}.rf-w-16{width:4rem}.rf-w-2{width:.5rem}.rf-w-3{width:.75rem}.rf-w-3\\.5{width:.875rem}.rf-w-32{width:8rem}.rf-w-4{width:1rem}.rf-w-64{width:16rem}.rf-w-8{width:2rem}.rf-w-9{width:2.25rem}.rf-w-96{width:24rem}.rf-w-full{width:100%}.rf-min-w-10{min-width:2.5rem}.rf-min-w-16{min-width:4rem}.rf-min-w-\\[8rem\\]{min-width:8rem}.rf-max-w-2xl{max-width:42rem}.rf-shrink-0{flex-shrink:0}.rf-flex-grow{flex-grow:1}.rf-table-auto{table-layout:auto}.-rf-translate-x-1{--tw-translate-x:-0.25rem}.-rf-translate-x-1,.-rf-translate-x-1\\/2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rf-translate-x-1\\/2{--tw-translate-x:-50%}.-rf-translate-y-1{--tw-translate-y:-0.25rem}.-rf-translate-y-1,.rf--translate-x-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf--translate-x-1{--tw-translate-x:-0.25rem}.rf-transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes rf-spin{to{transform:rotate(1turn)}}.rf-animate-spin{animation:rf-spin 1s linear infinite}.rf-cursor-default{cursor:default}.rf-cursor-pointer{cursor:pointer}.rf-select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.rf-flex-col{flex-direction:column}.rf-items-center{align-items:center}.rf-justify-end{justify-content:flex-end}.rf-justify-center{justify-content:center}.rf-justify-between{justify-content:space-between}.rf-gap-0{gap:0}.rf-gap-1{gap:.25rem}.rf-gap-2{gap:.5rem}.rf-gap-3{gap:.75rem}.rf-gap-5{gap:1.25rem}.rf-gap-6{gap:1.5rem}.rf-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.rf-space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}.rf-overflow-auto{overflow:auto}.rf-overflow-hidden{overflow:hidden}.rf-overflow-visible{overflow:visible}.rf-overflow-x-auto{overflow-x:auto}.rf-overflow-y-auto{overflow-y:auto}.rf-whitespace-nowrap{white-space:nowrap}.rf-whitespace-pre-wrap{white-space:pre-wrap}.rf-rounded{border-radius:.25rem}.rf-rounded-full{border-radius:9999px}.rf-rounded-lg{border-radius:var(--radius)}.rf-rounded-md{border-radius:calc(var(--radius) - 2px)}.rf-rounded-sm{border-radius:calc(var(--radius) - 4px)}.rf-border{border-width:1px}.rf-border-b{border-bottom-width:1px}.rf-border-green-200{--tw-border-opacity:1;border-color:rgb(187 247 208/var(--tw-border-opacity,1))}.rf-border-neutral-200{--tw-border-opacity:1;border-color:rgb(229 229 229/var(--tw-border-opacity,1))}.rf-border-red-200{--tw-border-opacity:1;border-color:rgb(254 202 202/var(--tw-border-opacity,1))}.rf-border-zinc-200{--tw-border-opacity:1;border-color:rgb(228 228 231/var(--tw-border-opacity,1))}.rf-bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity,1))}.rf-bg-blue-500{--tw-bg-opacity:1;background-color:rgb(59 130 246/var(--tw-bg-opacity,1))}.rf-bg-blue-600{--tw-bg-opacity:1;background-color:rgb(37 99 235/var(--tw-bg-opacity,1))}.rf-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.rf-bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}.rf-bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.rf-bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}.rf-bg-green-50{--tw-bg-opacity:1;background-color:rgb(240 253 244/var(--tw-bg-opacity,1))}.rf-bg-neutral-100{--tw-bg-opacity:1;background-color:rgb(245 245 245/var(--tw-bg-opacity,1))}.rf-bg-neutral-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-neutral-800{--tw-bg-opacity:1;background-color:rgb(38 38 38/var(--tw-bg-opacity,1))}.rf-bg-neutral-900{--tw-bg-opacity:1;background-color:rgb(23 23 23/var(--tw-bg-opacity,1))}.rf-bg-orange-400{--tw-bg-opacity:1;background-color:rgb(251 146 60/var(--tw-bg-opacity,1))}.rf-bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity,1))}.rf-bg-red-50{--tw-bg-opacity:1;background-color:rgb(254 242 242/var(--tw-bg-opacity,1))}.rf-bg-red-500{--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}.rf-bg-red-900{--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.rf-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.rf-bg-zinc-100{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.rf-bg-zinc-200{--tw-bg-opacity:1;background-color:rgb(228 228 231/var(--tw-bg-opacity,1))}.rf-bg-zinc-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-zinc-800{--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.rf-bg-zinc-900{--tw-bg-opacity:1;background-color:rgb(24 24 27/var(--tw-bg-opacity,1))}.rf-bg-opacity-50{--tw-bg-opacity:0.5}.rf-fill-current{fill:currentColor}.rf-p-0{padding:0}.rf-p-0\\.5{padding:.125rem}.rf-p-1{padding:.25rem}.rf-p-2{padding:.5rem}.rf-p-3{padding:.75rem}.rf-p-4{padding:1rem}.rf-p-5{padding:1.25rem}.rf-p-6{padding:1.5rem}.rf-px-1{padding-left:.25rem;padding-right:.25rem}.rf-px-1\\.5{padding-left:.375rem;padding-right:.375rem}.rf-px-2{padding-left:.5rem;padding-right:.5rem}.rf-px-3{padding-left:.75rem;padding-right:.75rem}.rf-px-4{padding-left:1rem;padding-right:1rem}.rf-px-8{padding-left:2rem;padding-right:2rem}.rf-py-0{padding-bottom:0;padding-top:0}.rf-py-1{padding-bottom:.25rem;padding-top:.25rem}.rf-py-1\\.5{padding-bottom:.375rem;padding-top:.375rem}.rf-py-10{padding-bottom:2.5rem;padding-top:2.5rem}.rf-py-2{padding-bottom:.5rem;padding-top:.5rem}.rf-pb-4{padding-bottom:1rem}.rf-pl-2{padding-left:.5rem}.rf-pl-8{padding-left:2rem}.rf-pr-2{padding-right:.5rem}.rf-text-left{text-align:left}.rf-text-center{text-align:center}.rf-font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.rf-text-2xl{font-size:1.5rem;line-height:2rem}.rf-text-\\[8px\\]{font-size:8px}.rf-text-lg{font-size:1.125rem;line-height:1.75rem}.rf-text-sm{font-size:.875rem;line-height:1.25rem}.rf-text-xs{font-size:.75rem;line-height:1rem}.rf-font-bold{font-weight:700}.rf-font-medium{font-weight:500}.rf-font-semibold{font-weight:600}.rf-capitalize{text-transform:capitalize}.rf-tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.rf-leading-5{line-height:1.25rem}.rf-tracking-widest{letter-spacing:.1em}.rf-text-blue-500{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity,1))}.rf-text-blue-600{--tw-text-opacity:1;color:rgb(37 99 235/var(--tw-text-opacity,1))}.rf-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.rf-text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}.rf-text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}.rf-text-green-500{--tw-text-opacity:1;color:rgb(34 197 94/var(--tw-text-opacity,1))}.rf-text-green-700{--tw-text-opacity:1;color:rgb(21 128 61/var(--tw-text-opacity,1))}.rf-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity,1))}.rf-text-neutral-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-neutral-500{--tw-text-opacity:1;color:rgb(115 115 115/var(--tw-text-opacity,1))}.rf-text-neutral-900{--tw-text-opacity:1;color:rgb(23 23 23/var(--tw-text-opacity,1))}.rf-text-neutral-950{--tw-text-opacity:1;color:rgb(10 10 10/var(--tw-text-opacity,1))}.rf-text-red-200{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity,1))}.rf-text-red-300{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.rf-text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.rf-text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity,1))}.rf-text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity,1))}.rf-text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity,1))}.rf-text-red-800{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity,1))}.rf-text-red-900{--tw-text-opacity:1;color:rgb(127 29 29/var(--tw-text-opacity,1))}.rf-text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.rf-text-zinc-200{--tw-text-opacity:1;color:rgb(228 228 231/var(--tw-text-opacity,1))}.rf-text-zinc-300{--tw-text-opacity:1;color:rgb(212 212 216/var(--tw-text-opacity,1))}.rf-text-zinc-400{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.rf-text-zinc-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-zinc-500{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.rf-text-zinc-900{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.rf-text-zinc-950{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.rf-underline{text-decoration-line:underline}.rf-underline-offset-4{text-underline-offset:4px}.rf-opacity-0{opacity:0}.rf-opacity-50{opacity:.5}.rf-opacity-60{opacity:.6}.rf-shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)}.rf-shadow,.rf-shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.rf-shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.rf-shadow-md,.rf-shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.rf-outline-none{outline:2px solid transparent;outline-offset:2px}.rf-ring-offset-white{--tw-ring-offset-color:#fff}.rf-transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity,1);transform:translate3d(var(--tw-enter-translate-x,0),var(--tw-enter-translate-y,0),0) scale3d(var(--tw-enter-scale,1),var(--tw-enter-scale,1),var(--tw-enter-scale,1)) rotate(var(--tw-enter-rotate,0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity,1);transform:translate3d(var(--tw-exit-translate-x,0),var(--tw-exit-translate-y,0),0) scale3d(var(--tw-exit-scale,1),var(--tw-exit-scale,1),var(--tw-exit-scale,1)) rotate(var(--tw-exit-rotate,0))}}.hover\\:\\!rf-bg-transparent:hover{background-color:transparent!important}.hover\\:rf-bg-blue-700:hover{--tw-bg-opacity:1;background-color:rgb(29 78 216/var(--tw-bg-opacity,1))}.hover\\:rf-bg-red-500\\/90:hover{background-color:rgba(239,68,68,.9)}.hover\\:rf-bg-zinc-100:hover{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.hover\\:rf-bg-zinc-100\\/80:hover{background-color:hsla(240,5%,96%,.8)}.hover\\:rf-bg-zinc-900\\/90:hover{background-color:rgba(24,24,27,.9)}.hover\\:rf-text-red-400:hover{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.hover\\:rf-text-zinc-900:hover{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.hover\\:rf-underline:hover{text-decoration-line:underline}.focus\\:rf-bg-zinc-100:focus{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.focus\\:rf-text-zinc-900:focus{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.focus-visible\\:rf-outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:rf-ring-1:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-zinc-950:focus-visible{--tw-ring-opacity:1;--tw-ring-color:rgb(9 9 11/var(--tw-ring-opacity,1))}.focus-visible\\:rf-ring-offset-2:focus-visible{--tw-ring-offset-width:2px}.disabled\\:rf-pointer-events-none:disabled{pointer-events:none}.disabled\\:rf-opacity-50:disabled{opacity:.5}.rf-group\\/bar:hover .group-hover\\/bar\\:rf-opacity-100{opacity:1}.data-\\[disabled\\]\\:rf-pointer-events-none[data-disabled]{pointer-events:none}.data-\\[state\\=active\\]\\:rf-bg-white[data-state=active]{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.data-\\[state\\=open\\]\\:rf-bg-zinc-100[data-state=open]{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.data-\\[state\\=active\\]\\:rf-text-zinc-950[data-state=active]{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.data-\\[disabled\\]\\:rf-opacity-50[data-disabled]{opacity:.5}.data-\\[state\\=active\\]\\:rf-shadow[data-state=active]{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.data-\\[state\\=open\\]\\:rf-animate-in[data-state=open]{animation-duration:.15s;animation-name:enter;--tw-enter-opacity:initial;--tw-enter-scale:initial;--tw-enter-rotate:initial;--tw-enter-translate-x:initial;--tw-enter-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-animate-out[data-state=closed]{animation-duration:.15s;animation-name:exit;--tw-exit-opacity:initial;--tw-exit-scale:initial;--tw-exit-rotate:initial;--tw-exit-translate-x:initial;--tw-exit-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-fade-out-0[data-state=closed]{--tw-exit-opacity:0}.data-\\[state\\=open\\]\\:rf-fade-in-0[data-state=open]{--tw-enter-opacity:0}.data-\\[state\\=closed\\]\\:rf-zoom-out-95[data-state=closed]{--tw-exit-scale:.95}.data-\\[state\\=open\\]\\:rf-zoom-in-95[data-state=open]{--tw-enter-scale:.95}.data-\\[side\\=bottom\\]\\:rf-slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y:-0.5rem}.data-\\[side\\=left\\]\\:rf-slide-in-from-right-2[data-side=left]{--tw-enter-translate-x:0.5rem}.data-\\[side\\=right\\]\\:rf-slide-in-from-left-2[data-side=right]{--tw-enter-translate-x:-0.5rem}.data-\\[side\\=top\\]\\:rf-slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y:0.5rem}.dark\\:rf-border-zinc-800:is(.rf-dark *){--tw-border-opacity:1;border-color:rgb(39 39 42/var(--tw-border-opacity,1))}.dark\\:rf-bg-red-900:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-50:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-800:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-950:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:rf-text-zinc-400:is(.rf-dark *){--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-50:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-900:is(.rf-dark *){--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.dark\\:rf-ring-offset-zinc-950:is(.rf-dark *){--tw-ring-offset-color:#09090b}.dark\\:hover\\:rf-bg-red-900\\/90:hover:is(.rf-dark *){background-color:rgba(127,29,29,.9)}.dark\\:hover\\:rf-bg-zinc-50\\/90:hover:is(.rf-dark *){background-color:hsla(0,0%,98%,.9)}.dark\\:hover\\:rf-bg-zinc-800:hover:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:hover\\:rf-bg-zinc-800\\/80:hover:is(.rf-dark *){background-color:rgba(39,39,42,.8)}.dark\\:hover\\:rf-text-zinc-50:hover:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus\\:rf-bg-zinc-800:focus:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:focus\\:rf-text-zinc-50:focus:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus-visible\\:rf-ring-zinc-300:focus-visible:is(.rf-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(212 212 216/var(--tw-ring-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-bg-zinc-950[data-state=active]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=open\\]\\:rf-bg-zinc-800[data-state=open]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-text-zinc-50[data-state=active]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.\\[\\&\\>svg\\]\\:rf-size-4>svg{height:1rem;width:1rem}.\\[\\&\\>svg\\]\\:rf-shrink-0>svg{flex-shrink:0}.\\[\\&\\>svg\\]\\:rf-text-red-300>svg{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.\\[\\&\\>svg\\]\\:hover\\:rf-text-red-400:hover>svg{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.\\[\\&_svg\\]\\:rf-pointer-events-none svg{pointer-events:none}.\\[\\&_svg\\]\\:rf-size-4 svg{height:1rem;width:1rem}.\\[\\&_svg\\]\\:rf-shrink-0 svg{flex-shrink:0}',Whn=()=>{Ct.useEffect(()=>{if(document.querySelector('style[data-styles="tscircuit-runframe"]'))return;const e=document.createElement("style");e.setAttribute("data-styles","tscircuit-runframe"),e.textContent=Xhn,document.head.appendChild(e)},[])},fat=r=>`hsl(${K3.indexOf(r)*137.5%360}, 70%, 50%)`,Zhn=({phaseTimings:r})=>{if(!r)return null;const e=Object.values(r).reduce((t,n)=>t+n,0);return _t.jsxs("div",{className:"rf-space-y-2 rf-w-full rf-px-4",children:[_t.jsx("div",{className:"rf-relative rf-h-8 rf-flex rf-rounded-sm",children:K3.map(t=>{const n=r[t]||0,i=n/e*100;return _t.jsx("div",{className:"rf-group/bar rf-relative rf-overflow-visible",style:{width:`${i}%`,backgroundColor:fat(t)},children:_t.jsxs("div",{className:"rf-opacity-0 group-hover/bar:rf-opacity-100 rf-transition-opacity rf-absolute rf-bottom-full rf-left-1/2 rf-transform -rf-translate-x-1/2 rf-mb-2 rf-px-2 rf-py-1 rf-text-xs rf-whitespace-nowrap rf-rounded rf-bg-gray-900 rf-text-white rf-pointer-events-none",children:[t,": ",n.toFixed(1),"ms"]})},t)})}),_t.jsxs("div",{className:"rf-text-xs rf-text-gray-500",children:["Total: ",e.toFixed(2),"ms"]})]})},Qhn=({renderLog:r})=>{const[e,t]=Ct.useState("chronological");if(!r)return _t.jsx("div",{className:"rf-p-4 rf-bg-gray-100 rf-rounded-md",children:"No render log, make sure this tab is open when you render (TODO add a rerender button here)"});const n=Object.entries((r==null?void 0:r.phaseTimings)??{});e==="chronological"?n.sort((a,o)=>K3.indexOf(a[0])-K3.indexOf(o[0])):n.sort((a,o)=>o[1]-a[1]);const i=n.reduce((a,[o,s])=>a+s,0);return _t.jsxs("div",{className:"rf-bg-white",children:[_t.jsxs("div",{className:"rf-flex rf-justify-between rf-items-center",children:[_t.jsx("div",{children:"Render Logs"}),_t.jsxs("div",{className:"rf-mb-4 rf-pr-2 rf-flex rf-text-xs rf-items-center",children:[_t.jsx("div",{className:"rf-mr-2",children:"Sort by:"}),_t.jsxs("select",{value:e,onChange:a=>t(a.target.value),className:"rf-px-2 rf-py-1 rf-border rf-rounded rf-text-xs",children:[_t.jsx("option",{value:"chronological",children:"Phase Order"}),_t.jsx("option",{value:"longest",children:"Duration"})]})]})]}),_t.jsx(Zhn,{phaseTimings:r.phaseTimings}),_t.jsxs("table",{className:"rf-w-full rf-text-xs",children:[_t.jsx("thead",{children:_t.jsxs("tr",{children:[_t.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase Order"}),_t.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase"}),_t.jsx("th",{className:"rf-text-left rf-p-2",children:"Duration (ms)"})]})}),_t.jsx("tbody",{children:n.map(([a,o])=>_t.jsxs("tr",{children:[_t.jsx("td",{className:"rf-p-2",children:K3.indexOf(a)}),_t.jsx("td",{className:"rf-p-2",children:a}),_t.jsx("td",{className:"rf-p-2",children:_t.jsx("div",{className:"rf-w-8",children:_t.jsx("div",{className:"rf-h-2 rf-rounded-sm",style:{backgroundColor:fat(a),width:`${o/i*100}%`}})})}),_t.jsx("td",{className:"rf-p-2",children:_t.jsxs("div",{className:"rf-flex w-full",children:[_t.jsxs("span",{className:"rf-flex-grow",children:[o,"ms"]}),_t.jsxs("span",{className:"rf-text-gray-500 rf-pr-2",children:[(o/i*100).toFixed(1),"%"]})]})})]},a))})]})]})},Khn=["assembly","bom","circuit_json","errors","render_log"],Jhn=({code:r,onRunClicked:e=void 0,errorMessage:t,circuitJsonKey:n="",circuitJson:i,showCodeTab:a=!1,codeTabContent:o,showJsonTab:s=!0,showRenderLogTab:l=!0,onActiveTabChange:c,renderLog:u,showImportAndFormatButtons:f=!0,className:h,headerClassName:v,leftHeaderContent:x,readOnly:E,isStreaming:S,onToggleFullScreen:b,isFullScreen:C,isRunningCode:N,hasCodeChangedSinceLastRun:U,onEditEvent:G,editEvents:Z,defaultActiveTab:$,autoRotate3dViewerDisabled:te})=>{var de;Whn();const[re,se]=Ct.useState($??"pcb"),fe=Ct.useCallback(ye=>{se(ye),c==null||c(ye)},[c]);return Ct.useEffect(()=>{t&&fe("errors")},[t]),Ct.useEffect(()=>{re==="code"&&i&&!t&&fe("pcb")},[i]),_t.jsx("div",{className:mg("flex flex-col relative",h),children:_t.jsx("div",{className:"rf-md:sticky rf-md:top-2",children:_t.jsxs(Act,{value:re,onValueChange:fe,className:"rf-flex-grow rf-flex rf-flex-col rf-p-2",children:[_t.jsxs("div",{className:mg("rf-flex rf-items-center rf-gap-2",v),children:[x,x&&_t.jsx("div",{className:"rf-flex-grow"}),!x&&N&&_t.jsx(zfe,{className:"rf-w-4 rf-h-4 rf-animate-spin"}),!x&&_t.jsx("div",{className:"rf-flex-grow"}),u&&u.progress!==1&&_t.jsxs("div",{className:"rf-flex rf-items-center rf-gap-2",children:[u.lastRenderEvent&&_t.jsx("div",{className:"rf-text-xs rf-text-gray-500",children:(de=u.lastRenderEvent)==null?void 0:de.type.split("renderable:renderLifecycle:")[1].split(":")[0]}),_t.jsx("div",{className:"rf-w-4 rf-h-4 rf-bg-blue-500 rf-opacity-50 rf-rounded-full rf-text-white",children:_t.jsx(zfe,{className:"rf-w-4 rf-h-4 rf-animate-spin"})}),_t.jsxs("div",{className:"rf-text-xs rf-font-bold rf-text-gray-700 rf-tabular-nums",children:[((u.progress??0)*100).toFixed(1),"%"]})]}),_t.jsxs(Wme,{children:[a&&_t.jsx(N7,{value:"code",children:"Code"}),_t.jsxs(N7,{value:"pcb",className:"rf-whitespace-nowrap",children:[i&&_t.jsx("span",{className:mg("rf-inline-flex rf-items-center rf-justify-center rf-w-2 rf-h-2 rf-mr-1 rf-text-xs rf-font-bold rf-text-white rf-rounded-full",U?"rf-bg-gray-500":"rf-bg-blue-500")}),"PCB"]}),_t.jsxs(N7,{value:"schematic",className:"rf-whitespace-nowrap",children:[i&&_t.jsx("span",{className:mg("rf-inline-flex rf-items-center rf-justify-center rf-w-2 rf-h-2 rf-mr-1 rf-text-xs rf-font-bold rf-text-white rf-rounded-full",U?"rf-bg-gray-500":"rf-bg-blue-500")}),"Schematic"]}),_t.jsxs(N7,{value:"cad",children:[i&&_t.jsx("span",{className:mg("inline-flex items-center justify-center w-2 h-2 mr-1 text-xs font-bold text-white rounded-full",U?"rf-bg-gray-500":"rf-bg-blue-500")}),"3D"]}),!["pcb","cad","schematic"].includes(re)&&_t.jsx(N7,{value:re,children:Xme(re)}),_t.jsxs(Ihn,{children:[_t.jsx(Bhn,{asChild:!0,children:_t.jsxs("div",{className:"rf-whitespace-nowrap rf-p-2 rf-mr-1 rf-cursor-pointer rf-relative",children:[_t.jsx(Aan,{className:"rf-w-4 rf-h-4"}),t&&_t.jsx("span",{className:"rf-inline-flex rf-absolute rf-top-[6px] rf-right-[4px] rf-items-center rf-justify-center rf-w-1 rf-h-1 rf-ml-2 rf-text-[8px] rf-font-bold rf-text-white rf-bg-red-500 rf-rounded-full"})]})}),_t.jsx(cat,{className:"rf-*:text-xs",children:Khn.map(ye=>_t.jsxs(uat,{onSelect:()=>fe(ye),children:[_t.jsx(FJe,{className:mg("rf-w-3 rf-h-3 rf-mr-2",re!==ye&&"rf-invisible")}),_t.jsx("div",{className:"rf-pr-2",children:Xme(ye)}),ye==="errors"&&t&&_t.jsx("span",{className:"rf-inline-flex rf-items-center rf-justify-center rf-w-3 rf-h-3 rf-ml-2 rf-text-[8px] rf-font-bold rf-text-white rf-bg-red-500 rf-rounded-full",children:"1"})]},ye))})]})]}),b&&_t.jsx(Ow,{onClick:b,variant:"ghost",children:C?_t.jsx(Dan,{size:16}):_t.jsx(Pan,{size:16})})]}),a&&_t.jsx(fb,{value:"code",className:"rf-flex-grow rf-overflow-hidden",children:_t.jsx("div",{className:"rf-h-full",children:o})}),_t.jsx(fb,{value:"pcb",children:_t.jsx("div",{className:mg("rf-overflow-hidden",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading PCB viewer"}),children:i?_t.jsx(Yhn,{soup:i,containerClassName:mg("rf-h-full rf-w-full",C?"rf-min-h-[calc(100vh-240px)]":"rf-min-h-[620px]")},n):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"assembly",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading Assembly"}),children:i?_t.jsx(sfn,{circuitJson:i,containerStyle:{height:"100%"},editingEnabled:!0,debugGrid:!0}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"schematic",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading Schematic"}),children:i?_t.jsx(ifn,{circuitJson:i,containerStyle:{height:"100%"},editingEnabled:!0,onEditEvent:ye=>G==null?void 0:G(ye),editEvents:Z,debugGrid:!0}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"cad",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{FallbackComponent:yan,children:i?_t.jsx(yYt,{soup:i,autoRotateDisabled:te}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"bom",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading BOM"}),children:i?_t.jsx(ffn,{circuitJson:i}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"circuit_json",children:_t.jsx("div",{className:mg("rf-overflow-auto",C?"rf-h-[calc(100vh-96px)]":"rf-h-[620px]"),children:_t.jsx(zw,{fallback:_t.jsx("div",{children:"Error loading JSON viewer"}),children:i?_t.jsx(cfn,{elements:i}):_t.jsx(h7,{onRunClicked:e})})})}),_t.jsx(fb,{value:"errors",children:i||t?_t.jsx(zan,{code:r,errorMessage:t}):_t.jsx(h7,{onRunClicked:e})}),l&&_t.jsx(fb,{value:"render_log",children:_t.jsx(Qhn,{renderLog:u})})]})})})};/**
13126
13126
  * @license
13127
13127
  * Copyright 2019 Google LLC
13128
13128
  * SPDX-License-Identifier: Apache-2.0
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@tscircuit/runframe",
3
3
  "main": "dist/preview.js",
4
4
  "type": "module",
5
- "version": "0.0.146",
5
+ "version": "0.0.148",
6
6
  "exports": {
7
7
  ".": "./dist/preview.js",
8
8
  "./preview": "./dist/preview.js",
@@ -62,7 +62,7 @@
62
62
  "@tscircuit/core": "^0.0.301",
63
63
  "@tscircuit/file-server": "^0.0.13",
64
64
  "@tscircuit/pcb-viewer": "^1.11.29",
65
- "@tscircuit/props": "^0.0.138",
65
+ "@tscircuit/props": "^0.0.139",
66
66
  "@tscircuit/schematic-viewer": "2.0.9",
67
67
  "circuit-to-svg": "^0.0.101",
68
68
  "clsx": "^2.1.1",