@tom2012/cc-web 2026.4.19-t → 2026.4.19-u
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/backend/dist/adapters/claude-adapter.d.ts.map +1 -1
- package/backend/dist/adapters/claude-adapter.js +107 -1
- package/backend/dist/adapters/claude-adapter.js.map +1 -1
- package/backend/dist/adapters/gemini-adapter.js +1 -1
- package/backend/dist/adapters/gemini-adapter.js.map +1 -1
- package/backend/dist/adapters/types.d.ts +3 -0
- package/backend/dist/adapters/types.d.ts.map +1 -1
- package/backend/dist/routes/skillhub.d.ts +27 -0
- package/backend/dist/routes/skillhub.d.ts.map +1 -1
- package/backend/dist/routes/skillhub.js +149 -180
- package/backend/dist/routes/skillhub.js.map +1 -1
- package/backend/dist/sync-service.d.ts +9 -6
- package/backend/dist/sync-service.d.ts.map +1 -1
- package/backend/dist/sync-service.js +84 -14
- package/backend/dist/sync-service.js.map +1 -1
- package/backend/package-lock.json +26 -0
- package/backend/package.json +2 -0
- package/frontend/dist/assets/{AssistantMessageContent-D1-3VpWE.js → AssistantMessageContent-DuOuKxgH.js} +2 -2
- package/frontend/dist/assets/{GraphPreview-CeI4sbtV.js → GraphPreview-UVA4ODDv.js} +1 -1
- package/frontend/dist/assets/MobilePage-8bMFdgD9.js +14 -0
- package/frontend/dist/assets/{OfficePreview-Dgs4aiYi.js → OfficePreview-DFa568OD.js} +2 -2
- package/frontend/dist/assets/{ProjectPage-DPv57nD9.js → ProjectPage-D23Cx4LX.js} +5 -5
- package/frontend/dist/assets/SettingsPage-CTTCafJA.js +13 -0
- package/frontend/dist/assets/SkillHubPage-BBWaNxzY.js +13 -0
- package/frontend/dist/assets/{chevron-down-CyDTNuVw.js → chevron-down-XjVVezAn.js} +1 -1
- package/frontend/dist/assets/{chevron-up-BURz786o.js → chevron-up-BD4j4icv.js} +1 -1
- package/frontend/dist/assets/index-BL3iZx_u.css +1 -0
- package/frontend/dist/assets/{index-z4qRGojt.js → index-Cz7UGH1l.js} +1 -1
- package/frontend/dist/assets/index-Qowsi3Ey.js +13 -0
- package/frontend/dist/assets/{index-BFWZX3Hz.js → index-hLxTQaCY.js} +10 -10
- package/frontend/dist/assets/{jszip.min-CPG_u-b-.js → jszip.min-BvfmA-CV.js} +1 -1
- package/frontend/dist/assets/{search-CZ83atP-.js → search-CdJtkP3F.js} +1 -1
- package/frontend/dist/index.html +2 -2
- package/package.json +1 -1
- package/frontend/dist/assets/MobilePage-BP7c3W3D.js +0 -14
- package/frontend/dist/assets/SettingsPage-CFSmKovg.js +0 -13
- package/frontend/dist/assets/SkillHubPage-4g29B-Hr.js +0 -13
- package/frontend/dist/assets/index-D0NB3R9q.css +0 -1
- package/frontend/dist/assets/index-Uy-V98k3.js +0 -13
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/OfficePreview-Dgs4aiYi.js","assets/index-BFWZX3Hz.js","assets/index-D0NB3R9q.css","assets/purify.es-CgRAQgUo.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{c as e,ad as t,aF as s,r as a,bh as n,bi as r,j as l,bj as o,l as c,d as i,bk as d,bl as x,aw as u,ax as m,L as h,K as p,bm as f,ae as g,a as j,b,g as v,D as y,ai as N,f as w,R as k,_ as C,k as S,X as I,o as M,bn as z,bo as P,C as U,A as T,p as $}from"./index-BFWZX3Hz.js";import{A,d as D,G as E,S as L,M as R,r as H,a as O,b as F,h as _,o as q,c as B,I as W,F as K}from"./AssistantMessageContent-D1-3VpWE.js";import{C as V}from"./chevron-up-BURz786o.js";import{C as G}from"./chevron-down-CyDTNuVw.js";
|
|
3
|
-
/**
|
|
4
|
-
* @license lucide-react v0.309.0 - ISC
|
|
5
|
-
*
|
|
6
|
-
* This source code is licensed under the ISC license.
|
|
7
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
8
|
-
*/const J=e("Bookmark",[["path",{d:"m19 21-7-4-7 4V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v16z",key:"1fy3hk"}]]),Q=e("FileCode",[["path",{d:"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z",key:"1nnpy2"}],["polyline",{points:"14 2 14 8 20 8",key:"1ew0cm"}],["path",{d:"m10 13-2 2 2 2",key:"17smn8"}],["path",{d:"m14 17 2-2-2-2",key:"14mezr"}]]),X=e("FileJson",[["path",{d:"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z",key:"1nnpy2"}],["polyline",{points:"14 2 14 8 20 8",key:"1ew0cm"}],["path",{d:"M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1",key:"1oajmo"}],["path",{d:"M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1",key:"mpwhp6"}]]),Y=e("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]),Z=window.matchMedia("(pointer: coarse)").matches&&window.innerWidth<768;
|
|
9
|
-
/**
|
|
10
|
-
* @license lucide-react v0.309.0 - ISC
|
|
11
|
-
*
|
|
12
|
-
* This source code is licensed under the ISC license.
|
|
13
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
14
|
-
*/function ee({onSelectProject:e}){const x=t(),{projects:u,fetchProjects:m,hasFetched:h,loading:p}=s(),[f,g]=a.useState(new Map),[j,b]=a.useState(new Set),[v,y]=a.useState(!1);a.useEffect(()=>{m()},[m]);const N=a.useCallback(e=>{e.status&&g(t=>{const s=new Map(t);return s.set(e.projectId,e.status),s}),void 0!==e.active&&b(t=>{const s=new Set(t);return e.active?s.add(e.projectId):s.delete(e.projectId),s})},[]);n({onActivityUpdate:N});const{applyOrder:w}=r(),k=w(u.filter(e=>!e.archived));return l.jsxs("div",{className:"flex flex-col h-full",children:[l.jsxs("div",{className:"flex items-center gap-3 px-4 h-12 border-b border-border shrink-0",children:[l.jsx("span",{className:"font-semibold text-base flex-1",children:"CC Web"}),l.jsx(o,{}),l.jsx("button",{onClick:()=>{(async()=>{y(!0);try{await m()}finally{y(!1)}})()},className:"text-muted-foreground active:text-foreground",disabled:v,children:l.jsx(c,{className:i("h-4 w-4",v&&"animate-spin")})}),!Z&&l.jsx("button",{onClick:()=>x("/"),className:"text-muted-foreground active:text-foreground",title:"桌面模式",children:l.jsx(d,{className:"h-4 w-4"})})]}),l.jsxs("div",{className:"flex-1 overflow-y-auto px-3 py-3",children:[p&&!h&&l.jsx("div",{className:"text-center text-muted-foreground text-sm py-12",children:"加载中..."}),h&&0===k.length&&l.jsx("div",{className:"text-center text-muted-foreground text-sm py-12",children:"暂无项目"}),l.jsx("div",{className:"grid grid-cols-2 gap-2",children:k.map(t=>{var s;const a="running"===(s=t,f.get(s.id)??s.status??"stopped"),n=j.has(t.id),r=l.jsxs("button",{onClick:()=>e(t.id),className:i("w-full text-left rounded-lg border bg-card p-2.5 active:bg-accent transition-colors",n?"border-transparent":"border-border"),children:[l.jsxs("div",{className:"flex items-center gap-1.5 mb-1",children:[l.jsx("span",{className:i("w-2 h-2 rounded-full shrink-0",a?"bg-green-500":"bg-zinc-400")}),l.jsx("span",{className:"font-medium text-sm truncate flex-1",children:t.name})]}),l.jsx("div",{className:"text-[10px] text-muted-foreground font-mono truncate",children:t.cliTool??"claude"})]});return l.jsx("div",{className:n?"card-active-glow rounded-lg":void 0,children:r},t.id)})})]})]})}function te({project:e,onBack:t,onOpenPanel:s,onContextUpdate:n}){const[r,o]=a.useState(""),c=a.useRef(null),d=a.useRef(null),[j,b]=a.useState([]),v=a.useCallback(e=>{b(t=>{const s=[...t,e];return s.length>200?s.slice(-200):s})},[]),y=a.useRef(null),N=a.useCallback(e=>{var t;"stopped"===e&&(null==(t=y.current)||t.call(y,"stopped"))},[]),[w,k]=a.useState([]),C=a.useRef(new Set),S=a.useCallback(e=>{C.current.has(e.toolUseId)||k(t=>t.some(t=>t.toolUseId===e.toolUseId)?t:[...t,{projectId:e.projectId,toolUseId:e.toolUseId,toolName:e.toolName,toolInput:e.toolInput,sessionId:e.sessionId,createdAt:e.createdAt}])},[]),I=a.useCallback(e=>{C.current.add(e.toolUseId),k(t=>t.filter(t=>t.toolUseId!==e.toolUseId))},[]),M=a.useCallback(e=>{C.current.add(e),k(t=>t.filter(t=>t.toolUseId!==e))},[]),{sendInput:z,connected:P}=x({projectId:e.id,enabled:!0,onChatMessage:v,onStatusChange:N,onContextUpdate:n,onApprovalRequest:S,onApprovalResolved:I});a.useEffect(()=>{if(!P)return;if("claude"!==e.cliTool)return;let t=!1;return u(e.id).then(e=>{if(t)return;const s=e.pending.filter(e=>!C.current.has(e.toolUseId));k(e=>{const t=new Map;for(const a of s)t.set(a.toolUseId,a);for(const s of e)t.has(s.toolUseId)||C.current.has(s.toolUseId)||t.set(s.toolUseId,s);return[...t.values()]})}).catch(()=>{}),()=>{t=!0}},[e.id,e.cliTool,P]);const{state:U,setState:T,messages:$,hasMoreHistory:R,loadMoreHistory:H,sendMessage:O,isWaking:F}=m({project:e,liveMessages:j,ws:{send:z,connected:P},historyLimit:20});y.current=T;const _=a.useRef(P);a.useEffect(()=>{!_.current&&P&&b([]),_.current=P},[P]);const q=(()=>{for(let e=$.length-1;e>=0;e--)if("assistant"===$[e].role)return e;return-1})(),[B,W]=a.useState([]),[K,Q]=a.useState([]),[X,Z]=a.useState(null);a.useEffect(()=>{h().then(W).catch(()=>{}),p(e.id).then(Q).catch(()=>{})},[e.id]);const ee=a.useCallback(async()=>{const e=c.current,t=(null==e?void 0:e.scrollHeight)??0;await H(),requestAnimationFrame(()=>{e&&(e.scrollTop+=e.scrollHeight-t)})},[H]),te=a.useRef(0);a.useEffect(()=>{const e=c.current;if(!e)return;const t=$.length>te.current,s=0===te.current&&$.length>0;te.current=$.length,s?e.scrollTo({top:e.scrollHeight}):t&&e.scrollTo({top:e.scrollHeight,behavior:"smooth"})},[$,w.length]);const se=a.useCallback(()=>{const e=r.trim();e&&(o(""),d.current&&(d.current.style.height="auto"),O(e))},[r,O]),ae=f(se,"shift"),ne=a.useCallback(e=>{Z(null),O(e)},[O]),re="live"===U;return l.jsxs("div",{className:"flex flex-col h-full bg-background",children:[l.jsxs("div",{className:"flex items-center gap-2 px-3 h-12 border-b border-border shrink-0",children:[l.jsx("button",{onClick:t,className:"text-muted-foreground active:text-foreground p-1",children:l.jsx(g,{className:"h-5 w-5"})}),l.jsxs("div",{className:"flex items-center gap-1.5 flex-1 min-w-0",children:[l.jsx("span",{className:"font-medium text-sm truncate",children:e.name}),l.jsx("span",{className:i("w-2 h-2 rounded-full shrink-0",re?"bg-green-500":F?"bg-yellow-400 animate-pulse":"bg-zinc-400")})]}),l.jsx("button",{onClick:s,className:"text-muted-foreground active:text-foreground p-1",children:l.jsx(Y,{className:"h-5 w-5"})})]}),l.jsxs("div",{ref:c,className:"flex-1 overflow-y-auto px-3 py-3 space-y-3 min-h-0",children:[R&&l.jsx("div",{className:"flex justify-center pb-1",children:l.jsxs("button",{onClick:()=>{ee()},className:"flex items-center gap-1 px-3 py-1.5 rounded-full text-xs text-muted-foreground border border-border active:bg-accent transition-colors",children:[l.jsx(V,{className:"h-3 w-3"}),"加载更早消息"]})}),$.map((e,t)=>{const s="user"===e.role;return l.jsx("div",{className:i("flex",s?"justify-end":"justify-start"),children:l.jsx("div",{className:i("max-w-[85%] rounded-xl px-3 py-2 break-words text-sm leading-relaxed",s?"bg-blue-500/15 text-foreground border border-blue-500/20 rounded-br-sm whitespace-pre-wrap":"bg-secondary text-secondary-foreground border border-border rounded-bl-sm"),children:s?e.content:l.jsx(A,{content:e.content,blocks:e.blocks,isLatest:t===q})})},e.id)}),w.map(e=>l.jsx(D,{approval:e,onResolved:M},e.toolUseId)),0===$.length&&0===w.length&&"stopped"===U&&l.jsx("div",{className:"flex items-center justify-center h-full text-muted-foreground/40 text-sm",children:"暂无对话记录"}),F&&l.jsx("div",{className:"flex items-center justify-center py-4 text-yellow-400 text-sm animate-pulse",children:"启动中..."})]}),X&&l.jsx("div",{className:"border-t border-border max-h-48 overflow-y-auto shrink-0",children:l.jsxs("div",{className:"px-3 py-2 space-y-1",children:[("global"===X?B:K).map(e=>l.jsxs("button",{onClick:()=>ne(e.command),disabled:F,className:i("w-full text-left rounded-md px-2.5 py-2 text-sm active:bg-accent transition-colors border border-border/50",F&&"opacity-50 cursor-not-allowed"),children:[l.jsx("div",{className:"font-medium text-xs",children:e.label}),l.jsx("div",{className:"text-[11px] text-muted-foreground font-mono truncate",children:e.command})]},e.id)),0===("global"===X?B:K).length&&l.jsx("div",{className:"text-center text-muted-foreground text-xs py-3",children:"暂无快捷命令"})]})}),(B.length>0||K.length>0)&&l.jsxs("div",{className:"flex items-center gap-1.5 px-3 py-1.5 border-t border-border shrink-0",children:[l.jsxs("button",{onClick:()=>Z(e=>"global"===e?null:"global"),className:i("flex items-center gap-1 px-2 py-1 rounded-md text-xs transition-colors","global"===X?"bg-blue-500/15 text-blue-500":"text-muted-foreground active:bg-accent"),children:[l.jsx(E,{className:"h-3 w-3"}),"全局","global"===X&&l.jsx(G,{className:"h-3 w-3"})]}),l.jsxs("button",{onClick:()=>Z(e=>"project"===e?null:"project"),className:i("flex items-center gap-1 px-2 py-1 rounded-md text-xs transition-colors","project"===X?"bg-blue-500/15 text-blue-500":"text-muted-foreground active:bg-accent"),children:[l.jsx(J,{className:"h-3 w-3"}),"项目","project"===X&&l.jsx(G,{className:"h-3 w-3"})]})]}),l.jsx("div",{className:"border-t border-border px-3 py-2 shrink-0",style:{paddingBottom:"max(0.5rem, env(safe-area-inset-bottom))"},children:l.jsxs("div",{className:"flex items-end gap-2",children:[l.jsx("textarea",{ref:d,value:r,onChange:e=>o(e.target.value),onKeyDown:ae,disabled:F,placeholder:F?"启动中...":"stopped"===U?"输入消息(自动启动)...":"输入消息...",rows:1,className:i("flex-1 resize-none rounded-lg border border-input bg-transparent px-3 py-2 text-sm outline-none","focus:ring-1 focus:ring-ring placeholder:text-muted-foreground/50","max-h-32 overflow-y-auto",F&&"opacity-50 cursor-not-allowed"),style:{minHeight:"2.5rem"},onInput:e=>{const t=e.currentTarget;t.style.height="auto",t.style.height=Math.min(t.scrollHeight,128)+"px"}}),l.jsx("button",{onClick:se,disabled:F||!r.trim(),className:i("shrink-0 p-2 rounded-lg transition-colors",r.trim()?"text-blue-500 active:bg-blue-500/10":"text-muted-foreground/30"),children:l.jsx(L,{className:"h-5 w-5"})})]})})]})}const se=k.lazy(()=>C(()=>import("./OfficePreview-Dgs4aiYi.js"),__vite__mapDeps([0,1,2,3])).then(e=>({default:e.OfficePreview}))),ae=new Set(["png","jpg","jpeg","gif","webp","svg","bmp","ico","avif"]),ne=new Set(["docx","xlsx","xls","pptx"]),re={js:"javascript",jsx:"jsx",ts:"typescript",tsx:"tsx",py:"python",rb:"ruby",go:"go",rs:"rust",java:"java",kt:"kotlin",swift:"swift",c:"c",cpp:"cpp",h:"c",cs:"csharp",php:"php",sh:"bash",bash:"bash",zsh:"bash",yaml:"yaml",yml:"yaml",json:"json",toml:"toml",html:"html",htm:"html",xml:"xml",svg:"xml",css:"css",scss:"scss",less:"less",sql:"sql",graphql:"graphql",gql:"graphql",dockerfile:"docker",makefile:"makefile",r:"r",lua:"lua",dart:"dart",zig:"zig"};function le(e){return e.split("/").pop()??e}function oe({filePath:e,onBack:t}){const[s,n]=a.useState(null),[r,o]=a.useState(!0),[c,i]=a.useState(null),{resolved:d}=j(),x=function(e){const t=e.split("/").pop()??"",s=t.toLowerCase();if("dockerfile"===s)return"dockerfile";if("makefile"===s)return"makefile";const a=t.lastIndexOf(".");return a>=0?t.slice(a+1).toLowerCase():""}(e),u=ae.has(x),m=ne.has(x),h=re[x],p="dark"===d;a.useEffect(()=>{u||m?o(!1):(o(!0),i(null),b(e).then(n).catch(e=>i(e instanceof Error?e.message:"Failed to load")).finally(()=>o(!1)))},[e,u,m]);const f=w(e),k=a.useMemo(()=>{const e=v();return e?`${f}&token=${encodeURIComponent(e)}`:f},[f]),C=a.useMemo(()=>u?`${k}&t=${Date.now()}`:"",[k,u]);return l.jsxs("div",{className:"flex flex-col h-full",children:[l.jsxs("div",{className:"flex items-center gap-2 px-3 h-12 border-b border-border shrink-0",children:[l.jsx("button",{onClick:t,className:"text-muted-foreground active:text-foreground p-1",children:l.jsx(g,{className:"h-5 w-5"})}),l.jsx("span",{className:"flex-1 text-sm font-medium truncate",children:le(e)}),l.jsx("a",{href:k,download:!0,className:"text-muted-foreground active:text-foreground p-1",onClick:e=>e.stopPropagation(),children:l.jsx(y,{className:"h-4 w-4"})})]}),l.jsxs("div",{className:"flex-1 overflow-auto min-h-0",children:[r&&l.jsx("div",{className:"flex items-center justify-center py-12",children:l.jsx(N,{className:"h-5 w-5 animate-spin text-muted-foreground"})}),c&&l.jsx("div",{className:"text-center text-destructive text-sm py-12 px-4",children:c}),u&&l.jsx("div",{className:"flex items-center justify-center p-4 h-full",children:l.jsx("img",{src:C,alt:le(e),className:"max-w-full max-h-full object-contain rounded",style:{touchAction:"pinch-zoom"}})}),m&&l.jsx(a.Suspense,{fallback:l.jsx("div",{className:"flex items-center justify-center py-12",children:l.jsx(N,{className:"h-5 w-5 animate-spin text-muted-foreground"})}),children:l.jsx(se,{filePath:e,ext:x,zoom:100})}),s&&(s.binary||s.tooLarge)&&l.jsxs("div",{className:"text-center py-12 px-4 space-y-3",children:[l.jsxs("p",{className:"text-muted-foreground text-sm",children:[s.binary?"二进制文件":"文件过大",s.size>0&&` (${S=s.size,S<1024?`${S} B`:S<1048576?`${(S/1024).toFixed(1)} KB`:`${(S/1048576).toFixed(1)} MB`})`]}),l.jsxs("a",{href:k,download:!0,className:"inline-flex items-center gap-1.5 text-sm text-blue-500 active:text-blue-400",children:[l.jsx(y,{className:"h-4 w-4"}),"下载文件"]})]}),s&&!s.binary&&!s.tooLarge&&null!=s.content&&l.jsxs(l.Fragment,{children:["md"===x&&l.jsx("div",{className:"prose prose-sm dark:prose-invert max-w-none px-4 py-3",children:l.jsx(R,{remarkPlugins:[O,F],rehypePlugins:[H],children:s.content})}),"md"!==x&&h&&l.jsx(_,{language:h,style:p?q:B,customStyle:{margin:0,fontSize:"12px",borderRadius:0},showLineNumbers:!0,children:s.content}),"md"!==x&&!h&&l.jsx("pre",{className:"p-4 text-xs font-mono whitespace-pre-wrap break-words",children:s.content})]})]})]});var S}const ce=new Set(["png","jpg","jpeg","gif","webp","svg","bmp","ico","avif"]),ie=new Set(["js","jsx","ts","tsx","py","rb","go","rs","java","c","cpp","h","swift","kt","cs","php","sh","bash","zsh","r","lua","dart","zig","css","scss","less","html","htm","xml","sql"]),de=new Set(["json","yaml","yml","toml","csv","tsv"]);function xe({entry:e}){if("dir"===e.type)return l.jsx(M,{className:"h-8 w-8 text-blue-400"});const t=function(e){const t=e.lastIndexOf(".");return t>=0?e.slice(t+1).toLowerCase():""}(e.name);return ce.has(t)?l.jsx(W,{className:"h-8 w-8 text-emerald-400"}):ie.has(t)?l.jsx(Q,{className:"h-8 w-8 text-orange-400"}):de.has(t)?l.jsx(X,{className:"h-8 w-8 text-yellow-400"}):"md"===t?l.jsx(K,{className:"h-8 w-8 text-sky-400"}):l.jsx(z,{className:"h-8 w-8 text-muted-foreground"})}function ue({rootPath:e,onClose:t}){const[s,n]=a.useState(e),[r,o]=a.useState([]),[c,i]=a.useState(!0),[d,x]=a.useState(null),u=a.useCallback(async e=>{i(!0);try{const t=[...(await S(e)).entries].sort((e,t)=>e.type!==t.type?"dir"===e.type?-1:1:e.name.localeCompare(t.name));o(t),n(e)}catch{o([])}finally{i(!1)}},[]);a.useEffect(()=>{u(e)},[e,u]);const m=s!==e,h=s.startsWith(e)?s.slice(e.length)||"/":s;return d?l.jsx(oe,{filePath:d,onBack:()=>x(null)}):l.jsxs("div",{className:"flex flex-col h-full",children:[l.jsxs("div",{className:"flex items-center gap-2 px-3 h-12 border-b border-border shrink-0",children:[l.jsx("button",{onClick:t,className:"text-muted-foreground active:text-foreground p-1",children:l.jsx(I,{className:"h-5 w-5"})}),l.jsxs("div",{className:"flex items-center gap-1 flex-1 min-w-0 text-sm",children:[m&&l.jsx("button",{onClick:()=>{if(s===e)return;const t=s.replace(/\/[^/]+$/,"")||"/";t.startsWith(e)&&u(t)},className:"text-muted-foreground active:text-foreground p-0.5 shrink-0",children:l.jsx(g,{className:"h-4 w-4"})}),l.jsx("span",{className:"truncate text-muted-foreground font-mono text-xs",children:h})]})]}),l.jsxs("div",{className:"flex-1 overflow-y-auto px-3 py-3",children:[c&&l.jsx("div",{className:"flex items-center justify-center py-12",children:l.jsx(N,{className:"h-5 w-5 animate-spin text-muted-foreground"})}),!c&&0===r.length&&l.jsx("div",{className:"text-center text-muted-foreground text-sm py-12",children:"空目录"}),!c&&l.jsx("div",{className:"grid grid-cols-3 gap-1",children:r.map(e=>l.jsxs("button",{onClick:()=>(e=>{"dir"===e.type?u(e.path):x(e.path)})(e),className:"flex flex-col items-center gap-1 p-2 rounded-lg active:bg-accent transition-colors",children:[l.jsx(xe,{entry:e}),l.jsx("span",{className:"text-[11px] text-center leading-tight w-full line-clamp-2 break-all",children:e.name})]},e.path))})]})]})}function me(e){return e<50?"text-green-400":e<80?"text-yellow-400":"text-red-400"}function he(e){return e<50?"bg-green-500":e<80?"bg-yellow-500":"bg-red-500"}function pe({projectName:e,cliTool:t,folderPath:s,contextData:n,onClose:r}){const[o,d]=a.useState(new Set(["context","usage","files"])),[x,u]=a.useState(null),[m,h]=a.useState(!1),p=e=>{d(t=>{const s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s})};a.useEffect(()=>{h(!0),P(t).then(u).catch(()=>u(null)).finally(()=>h(!1))},[t]);const f=n?Math.round(n.usedPercentage):null;return l.jsxs("div",{className:"flex flex-col h-full",children:[l.jsxs("div",{className:"flex items-center gap-2 px-3 h-12 border-b border-border shrink-0",children:[l.jsx("button",{onClick:r,className:"text-muted-foreground active:text-foreground p-1",children:l.jsx(I,{className:"h-5 w-5"})}),l.jsx("span",{className:"flex-1 font-medium text-sm truncate",children:e})]}),l.jsxs("div",{className:"flex-1 overflow-y-auto",children:[l.jsxs("button",{onClick:()=>p("context"),className:"w-full flex items-center gap-2 px-4 py-2.5 border-b border-border/50 active:bg-accent",children:[o.has("context")?l.jsx(G,{className:"h-3.5 w-3.5 text-muted-foreground"}):l.jsx(U,{className:"h-3.5 w-3.5 text-muted-foreground"}),l.jsx("span",{className:"text-sm font-medium",children:"上下文"}),null!==f&&l.jsxs("span",{className:i("text-xs font-mono ml-auto",me(f)),children:[f,"%"]})]}),o.has("context")&&l.jsx("div",{className:"px-4 py-3 border-b border-border/50",children:null!==f&&n?l.jsxs("div",{className:"space-y-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"flex-1 h-2 bg-secondary rounded-full overflow-hidden",children:l.jsx("div",{className:i("h-full rounded-full transition-all",he(f)),style:{width:`${Math.min(f,100)}%`}})}),l.jsxs("span",{className:i("text-xs font-mono w-10 text-right",me(f)),children:[f,"%"]})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-x-4 gap-y-1 text-[11px] text-muted-foreground",children:[l.jsx("span",{children:"窗口大小"}),l.jsx("span",{className:"text-right font-mono",children:n.contextWindowSize>=1e6?`${(n.contextWindowSize/1e6).toFixed(1)}M`:`${Math.round(n.contextWindowSize/1e3)}K`}),l.jsx("span",{children:"输入 tokens"}),l.jsx("span",{className:"text-right font-mono",children:n.inputTokens.toLocaleString()}),l.jsx("span",{children:"输出 tokens"}),l.jsx("span",{className:"text-right font-mono",children:n.outputTokens.toLocaleString()})]})]}):l.jsx("div",{className:"text-xs text-muted-foreground/50 text-center py-2",children:"暂无数据"})}),l.jsxs("div",{className:"w-full flex items-center gap-2 px-4 py-2.5 border-b border-border/50 cursor-pointer",role:"button",tabIndex:0,onClick:()=>p("usage"),onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||p("usage")},children:[o.has("usage")?l.jsx(G,{className:"h-3.5 w-3.5 text-muted-foreground"}):l.jsx(U,{className:"h-3.5 w-3.5 text-muted-foreground"}),l.jsx("span",{className:"text-sm font-medium",children:"用量"}),l.jsx("button",{onClick:e=>{e.stopPropagation(),(async()=>{h(!0);try{const{refreshUsage:e}=await C(async()=>{const{refreshUsage:e}=await import("./index-BFWZX3Hz.js").then(e=>e.bw);return{refreshUsage:e}},__vite__mapDeps([1,2]));u(await e(t))}catch{}finally{h(!1)}})()},className:"ml-auto text-muted-foreground active:text-foreground",children:l.jsx(c,{className:i("h-3 w-3",m&&"animate-spin")})})]}),o.has("usage")&&l.jsx("div",{className:"px-4 py-3 border-b border-border/50",children:x?l.jsxs("div",{className:"space-y-2",children:[x.planName&&l.jsxs("div",{className:"text-[11px] text-muted-foreground",children:["Plan: ",l.jsx("span",{className:"font-medium text-foreground",children:x.planName})]}),l.jsx(fe,{label:"5h",bucket:x.fiveHour}),l.jsx(fe,{label:"7d",bucket:x.sevenDay}),x.sevenDaySonnet&&l.jsx(fe,{label:"7d Sonnet",bucket:x.sevenDaySonnet}),x.sevenDayOpus&&l.jsx(fe,{label:"7d Opus",bucket:x.sevenDayOpus}),!x.fiveHour&&!x.sevenDay&&l.jsx("div",{className:"text-xs text-muted-foreground/50 text-center",children:"暂无数据"})]}):l.jsx("div",{className:"text-xs text-muted-foreground/50 text-center py-2",children:m?"加载中...":"暂无数据"})}),l.jsxs("button",{onClick:()=>p("files"),className:"w-full flex items-center gap-2 px-4 py-2.5 border-b border-border/50 active:bg-accent",children:[o.has("files")?l.jsx(G,{className:"h-3.5 w-3.5 text-muted-foreground"}):l.jsx(U,{className:"h-3.5 w-3.5 text-muted-foreground"}),l.jsx("span",{className:"text-sm font-medium",children:"文件"})]}),o.has("files")&&l.jsx("div",{className:"h-[60vh]",children:l.jsx(ue,{rootPath:s,onClose:()=>p("files")})})]})]})}function fe({label:e,bucket:t}){if(!t||void 0===t.utilization)return null;const s=t.utilization,a=function(e){if(!e)return"";const t=new Date(e).getTime()-Date.now();if(t<=0)return"即将重置";const s=Math.floor(t/36e5),a=Math.floor(t%36e5/6e4);return s>0?`${s}h${a}m`:`${a}m`}(t.resetAt);return l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("span",{className:"text-xs text-muted-foreground w-16",children:e}),l.jsx("div",{className:"flex-1 h-1.5 bg-secondary rounded-full overflow-hidden",children:l.jsx("div",{className:i("h-full rounded-full",he(s)),style:{width:`${Math.min(s,100)}%`}})}),l.jsxs("span",{className:i("text-xs font-mono w-8 text-right",me(s)),children:[s,"%"]}),a&&l.jsx("span",{className:"text-[10px] text-muted-foreground/60",children:a})]})}function ge(){a.useEffect(()=>{const e=document.querySelector('meta[name="viewport"]');if(!e)return;const t=e.getAttribute("content")??"";return e.setAttribute("content","width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover"),()=>{e.setAttribute("content",t)}},[]);const[e,t]=a.useState({screen:"list"}),[n,r]=a.useState(null),o=s(e=>e.projects),c=a.useCallback(e=>{t({screen:"chat",projectId:e}),r(null)},[]),i=a.useCallback(e=>{t({screen:"panel",projectId:e})},[]),d=a.useCallback(()=>{t(e=>"panel"===e.screen?{screen:"chat",projectId:e.projectId}:{screen:"list"})},[]),x="list"!==e.screen?o.find(t=>t.id===e.projectId):void 0;return l.jsxs("div",{className:"fixed inset-0 bg-background overflow-hidden",children:[l.jsxs(T,{mode:"wait",children:["list"===e.screen&&l.jsx($.div,{className:"absolute inset-0",initial:{opacity:0},animate:{opacity:1},exit:{x:"-30%",opacity:0},transition:{duration:.2},style:{paddingTop:"env(safe-area-inset-top)"},children:l.jsx(ee,{onSelectProject:c})},"list"),"chat"===e.screen&&x&&l.jsx($.div,{className:"absolute inset-0",initial:{x:"100%"},animate:{x:0},exit:{x:"100%"},transition:{type:"tween",duration:.25},style:{paddingTop:"env(safe-area-inset-top)"},children:l.jsx(te,{project:x,onBack:d,onOpenPanel:()=>i(e.projectId),onContextUpdate:r})},`chat-${e.projectId}`)]}),l.jsx(T,{children:"panel"===e.screen&&x&&l.jsx($.div,{className:"absolute inset-0 z-50 bg-background",initial:{x:"100%"},animate:{x:0},exit:{x:"100%"},transition:{type:"tween",duration:.25},style:{paddingTop:"env(safe-area-inset-top)"},children:l.jsx(pe,{projectName:x.name,cliTool:x.cliTool??"claude",folderPath:x.folderPath,contextData:n,onClose:d})},"panel")})]})}export{ge as MobilePage};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import{c as e,r as t,av as n,ap as r,aH as s,j as o,aq as a,at as l,as as i,d as c,aI as d,au as u,aJ as h,aK as f,aL as p,aM as m,aN as x,aO as g,aP as y,aQ as v,x as w,aR as b,Q as j,U as N,V as S,W as C,Y as k,B as R,$ as P,I as A,a0 as D,aS as T,aT as E,aU as O,aV as _,aW as M,af as I,aX as L,l as H,T as z,aY as V,t as W,ai as F,D as B,aZ as $,a_ as U,a$ as K,ad as q,b0 as X,h as Y,S as G,b1 as Z,ae as Q,b2 as J,y as ee,A as te,p as ne,X as re,s as se,b3 as oe,b4 as ae,b5 as le,b6 as ie,b7 as ce,b8 as de,b9 as ue,ba as he}from"./index-BFWZX3Hz.js";import{u as fe,f as pe,e as me,S as xe,U as ge,T as ye,a as ve,b as we,d as be,c as je}from"./index-Uy-V98k3.js";import{C as Ne}from"./chevron-down-CyDTNuVw.js";import{C as Se}from"./chevron-up-BURz786o.js";
|
|
2
|
-
/**
|
|
3
|
-
* @license lucide-react v0.309.0 - ISC
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the ISC license.
|
|
6
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/const Ce=e("Activity",[["path",{d:"M22 12h-4l-3 9L9 3l-3 9H2",key:"d5dnw9"}]]),ke=e("AlertTriangle",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z",key:"c3ski4"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),Re=e("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]),Pe=e("CheckCircle2",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]),Ae=e("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]),De=e("Cloud",[["path",{d:"M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z",key:"p7xjir"}]]),Te=e("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]]),Ee=e("Plug",[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M9 8V2",key:"14iosj"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M18 8v5a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V8Z",key:"osxo6l"}]]),Oe=e("Settings2",[["path",{d:"M20 7h-9",key:"3s1dr2"}],["path",{d:"M14 17H5",key:"gfn3mx"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}],["circle",{cx:"7",cy:"7",r:"3",key:"dfmy0x"}]]),_e=e("XCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);
|
|
8
|
-
/**
|
|
9
|
-
* @license lucide-react v0.309.0 - ISC
|
|
10
|
-
*
|
|
11
|
-
* This source code is licensed under the ISC license.
|
|
12
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
13
|
-
*/function Me(e){const n=t.useRef({value:e,previous:e});return t.useMemo(()=>(n.current.value!==e&&(n.current.previous=n.current.value,n.current.value=e),n.current.previous),[e])}function Ie(e){const[r,s]=t.useState(void 0);return n(()=>{if(e){s({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver(t=>{if(!Array.isArray(t))return;if(!t.length)return;const n=t[0];let r,o;if("borderBoxSize"in n){const e=n.borderBoxSize,t=Array.isArray(e)?e[0]:e;r=t.inlineSize,o=t.blockSize}else r=e.offsetWidth,o=e.offsetHeight;s({width:r,height:o})});return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}s(void 0)},[e]),r}var Le="Switch",[He]=i(Le),[ze,Ve]=He(Le),We=t.forwardRef((e,n)=>{const{__scopeSwitch:i,name:c,checked:d,defaultChecked:u,required:h,disabled:f,value:p="on",onCheckedChange:m,form:x,...g}=e,[y,v]=t.useState(null),w=r(n,e=>v(e)),b=t.useRef(!1),j=!y||(x||!!y.closest("form")),[N,S]=s({prop:d,defaultProp:u??!1,onChange:m,caller:Le});return o.jsxs(ze,{scope:i,checked:N,disabled:f,children:[o.jsx(a.button,{type:"button",role:"switch","aria-checked":N,"aria-required":h,"data-state":Ue(N),"data-disabled":f?"":void 0,disabled:f,value:p,...g,ref:w,onClick:l(e.onClick,e=>{S(e=>!e),j&&(b.current=e.isPropagationStopped(),b.current||e.stopPropagation())})}),j&&o.jsx($e,{control:y,bubbles:!b.current,name:c,value:p,checked:N,required:h,disabled:f,form:x,style:{transform:"translateX(-100%)"}})]})});We.displayName=Le;var Fe="SwitchThumb",Be=t.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,s=Ve(Fe,n);return o.jsx(a.span,{"data-state":Ue(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:t})});Be.displayName=Fe;var $e=t.forwardRef(({__scopeSwitch:e,control:n,checked:s,bubbles:a=!0,...l},i)=>{const c=t.useRef(null),d=r(c,i),u=Me(s),h=Ie(n);return t.useEffect(()=>{const e=c.current;if(!e)return;const t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,"checked").set;if(u!==s&&n){const t=new Event("click",{bubbles:a});n.call(e,s),e.dispatchEvent(t)}},[u,s,a]),o.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:s,...l,tabIndex:-1,ref:d,style:{...l.style,...h,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});function Ue(e){return e?"checked":"unchecked"}$e.displayName="SwitchBubbleInput";var Ke=We,qe=Be;const Xe=t.forwardRef(({className:e,...t},n)=>o.jsx(Ke,{className:c("peer inline-flex h-[24px] w-[44px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:n,children:o.jsx(qe,{className:c("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})}));Xe.displayName=Ke.displayName;const Ye=["top","right","bottom","left"],Ge=Math.min,Ze=Math.max,Qe=Math.round,Je=Math.floor,et=e=>({x:e,y:e}),tt={left:"right",right:"left",bottom:"top",top:"bottom"};function nt(e,t,n){return Ze(e,Ge(t,n))}function rt(e,t){return"function"==typeof e?e(t):e}function st(e){return e.split("-")[0]}function ot(e){return e.split("-")[1]}function at(e){return"x"===e?"y":"x"}function lt(e){return"y"===e?"height":"width"}function it(e){const t=e[0];return"t"===t||"b"===t?"y":"x"}function ct(e){return at(it(e))}function dt(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const ut=["left","right"],ht=["right","left"],ft=["top","bottom"],pt=["bottom","top"];function mt(e,t,n,r){const s=ot(e);let o=function(e,t,n){switch(e){case"top":case"bottom":return n?t?ht:ut:t?ut:ht;case"left":case"right":return t?ft:pt;default:return[]}}(st(e),"start"===n,r);return s&&(o=o.map(e=>e+"-"+s),t&&(o=o.concat(o.map(dt)))),o}function xt(e){const t=st(e);return tt[t]+e.slice(t.length)}function gt(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function yt(e){const{x:t,y:n,width:r,height:s}=e;return{width:r,height:s,top:n,left:t,right:t+r,bottom:n+s,x:t,y:n}}function vt(e,t,n){let{reference:r,floating:s}=e;const o=it(t),a=ct(t),l=lt(a),i=st(t),c="y"===o,d=r.x+r.width/2-s.width/2,u=r.y+r.height/2-s.height/2,h=r[l]/2-s[l]/2;let f;switch(i){case"top":f={x:d,y:r.y-s.height};break;case"bottom":f={x:d,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:u};break;case"left":f={x:r.x-s.width,y:u};break;default:f={x:r.x,y:r.y}}switch(ot(t)){case"start":f[a]-=h*(n&&c?-1:1);break;case"end":f[a]+=h*(n&&c?-1:1)}return f}async function wt(e,t){var n;void 0===t&&(t={});const{x:r,y:s,platform:o,rects:a,elements:l,strategy:i}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:h=!1,padding:f=0}=rt(t,e),p=gt(f),m=l[h?"floating"===u?"reference":"floating":u],x=yt(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(m)))||n?m:m.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(l.floating)),boundary:c,rootBoundary:d,strategy:i})),g="floating"===u?{x:r,y:s,width:a.floating.width,height:a.floating.height}:a.reference,y=await(null==o.getOffsetParent?void 0:o.getOffsetParent(l.floating)),v=await(null==o.isElement?void 0:o.isElement(y))&&await(null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},w=yt(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:g,offsetParent:y,strategy:i}):g);return{top:(x.top-w.top+p.top)/v.y,bottom:(w.bottom-x.bottom+p.bottom)/v.y,left:(x.left-w.left+p.left)/v.x,right:(w.right-x.right+p.right)/v.x}}function bt(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function jt(e){return Ye.some(t=>e[t]>=0)}const Nt=new Set(["left","top"]);function St(){return"undefined"!=typeof window}function Ct(e){return Pt(e)?(e.nodeName||"").toLowerCase():"#document"}function kt(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Rt(e){var t;return null==(t=(Pt(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Pt(e){return!!St()&&(e instanceof Node||e instanceof kt(e).Node)}function At(e){return!!St()&&(e instanceof Element||e instanceof kt(e).Element)}function Dt(e){return!!St()&&(e instanceof HTMLElement||e instanceof kt(e).HTMLElement)}function Tt(e){return!(!St()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof kt(e).ShadowRoot)}function Et(e){const{overflow:t,overflowX:n,overflowY:r,display:s}=Ft(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&"inline"!==s&&"contents"!==s}function Ot(e){return/^(table|td|th)$/.test(Ct(e))}function _t(e){try{if(e.matches(":popover-open"))return!0}catch(t){}try{return e.matches(":modal")}catch(t){return!1}}const Mt=/transform|translate|scale|rotate|perspective|filter/,It=/paint|layout|strict|content/,Lt=e=>!!e&&"none"!==e;let Ht;function zt(e){const t=At(e)?Ft(e):e;return Lt(t.transform)||Lt(t.translate)||Lt(t.scale)||Lt(t.rotate)||Lt(t.perspective)||!Vt()&&(Lt(t.backdropFilter)||Lt(t.filter))||Mt.test(t.willChange||"")||It.test(t.contain||"")}function Vt(){return null==Ht&&(Ht="undefined"!=typeof CSS&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Ht}function Wt(e){return/^(html|body|#document)$/.test(Ct(e))}function Ft(e){return kt(e).getComputedStyle(e)}function Bt(e){return At(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function $t(e){if("html"===Ct(e))return e;const t=e.assignedSlot||e.parentNode||Tt(e)&&e.host||Rt(e);return Tt(t)?t.host:t}function Ut(e){const t=$t(e);return Wt(t)?e.ownerDocument?e.ownerDocument.body:e.body:Dt(t)&&Et(t)?t:Ut(t)}function Kt(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const s=Ut(e),o=s===(null==(r=e.ownerDocument)?void 0:r.body),a=kt(s);if(o){const e=qt(a);return t.concat(a,a.visualViewport||[],Et(s)?s:[],e&&n?Kt(e):[])}return t.concat(s,Kt(s,[],n))}function qt(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Xt(e){const t=Ft(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const s=Dt(e),o=s?e.offsetWidth:n,a=s?e.offsetHeight:r,l=Qe(n)!==o||Qe(r)!==a;return l&&(n=o,r=a),{width:n,height:r,$:l}}function Yt(e){return At(e)?e:e.contextElement}function Gt(e){const t=Yt(e);if(!Dt(t))return et(1);const n=t.getBoundingClientRect(),{width:r,height:s,$:o}=Xt(t);let a=(o?Qe(n.width):n.width)/r,l=(o?Qe(n.height):n.height)/s;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const Zt=et(0);function Qt(e){const t=kt(e);return Vt()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Zt}function Jt(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const s=e.getBoundingClientRect(),o=Yt(e);let a=et(1);t&&(r?At(r)&&(a=Gt(r)):a=Gt(e));const l=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==kt(e))&&t}(o,n,r)?Qt(o):et(0);let i=(s.left+l.x)/a.x,c=(s.top+l.y)/a.y,d=s.width/a.x,u=s.height/a.y;if(o){const e=kt(o),t=r&&At(r)?kt(r):r;let n=e,s=qt(n);for(;s&&r&&t!==n;){const e=Gt(s),t=s.getBoundingClientRect(),r=Ft(s),o=t.left+(s.clientLeft+parseFloat(r.paddingLeft))*e.x,a=t.top+(s.clientTop+parseFloat(r.paddingTop))*e.y;i*=e.x,c*=e.y,d*=e.x,u*=e.y,i+=o,c+=a,n=kt(s),s=qt(n)}}return yt({width:d,height:u,x:i,y:c})}function en(e,t){const n=Bt(e).scrollLeft;return t?t.left+n:Jt(Rt(e)).left+n}function tn(e,t){const n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-en(e,n),y:n.top+t.scrollTop}}function nn(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=kt(e),r=Rt(e),s=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,l=0,i=0;if(s){o=s.width,a=s.height;const e=Vt();(!e||e&&"fixed"===t)&&(l=s.offsetLeft,i=s.offsetTop)}const c=en(r);if(c<=0){const e=r.ownerDocument,t=e.body,n=getComputedStyle(t),s="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,a=Math.abs(r.clientWidth-t.clientWidth-s);a<=25&&(o-=a)}else c<=25&&(o+=c);return{width:o,height:a,x:l,y:i}}(e,n);else if("document"===t)r=function(e){const t=Rt(e),n=Bt(e),r=e.ownerDocument.body,s=Ze(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=Ze(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+en(e);const l=-n.scrollTop;return"rtl"===Ft(r).direction&&(a+=Ze(t.clientWidth,r.clientWidth)-s),{width:s,height:o,x:a,y:l}}(Rt(e));else if(At(t))r=function(e,t){const n=Jt(e,!0,"fixed"===t),r=n.top+e.clientTop,s=n.left+e.clientLeft,o=Dt(e)?Gt(e):et(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:s*o.x,y:r*o.y}}(t,n);else{const n=Qt(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return yt(r)}function rn(e,t){const n=$t(e);return!(n===t||!At(n)||Wt(n))&&("fixed"===Ft(n).position||rn(n,t))}function sn(e,t,n){const r=Dt(t),s=Rt(t),o="fixed"===n,a=Jt(e,!0,o,t);let l={scrollLeft:0,scrollTop:0};const i=et(0);function c(){i.x=en(s)}if(r||!r&&!o)if(("body"!==Ct(t)||Et(s))&&(l=Bt(t)),r){const e=Jt(t,!0,o,t);i.x=e.x+t.clientLeft,i.y=e.y+t.clientTop}else s&&c();o&&!r&&s&&c();const d=!s||r||o?et(0):tn(s,l);return{x:a.left+l.scrollLeft-i.x-d.x,y:a.top+l.scrollTop-i.y-d.y,width:a.width,height:a.height}}function on(e){return"static"===Ft(e).position}function an(e,t){if(!Dt(e)||"fixed"===Ft(e).position)return null;if(t)return t(e);let n=e.offsetParent;return Rt(e)===n&&(n=n.ownerDocument.body),n}function ln(e,t){const n=kt(e);if(_t(e))return n;if(!Dt(e)){let t=$t(e);for(;t&&!Wt(t);){if(At(t)&&!on(t))return t;t=$t(t)}return n}let r=an(e,t);for(;r&&Ot(r)&&on(r);)r=an(r,t);return r&&Wt(r)&&on(r)&&!zt(r)?n:r||function(e){let t=$t(e);for(;Dt(t)&&!Wt(t);){if(zt(t))return t;if(_t(t))return null;t=$t(t)}return null}(e)||n}const cn={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:s}=e;const o="fixed"===s,a=Rt(r),l=!!t&&_t(t.floating);if(r===a||l&&o)return n;let i={scrollLeft:0,scrollTop:0},c=et(1);const d=et(0),u=Dt(r);if((u||!u&&!o)&&(("body"!==Ct(r)||Et(a))&&(i=Bt(r)),u)){const e=Jt(r);c=Gt(r),d.x=e.x+r.clientLeft,d.y=e.y+r.clientTop}const h=!a||u||o?et(0):tn(a,i);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-i.scrollLeft*c.x+d.x+h.x,y:n.y*c.y-i.scrollTop*c.y+d.y+h.y}},getDocumentElement:Rt,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:s}=e;const o=[..."clippingAncestors"===n?_t(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=Kt(e,[],!1).filter(e=>At(e)&&"body"!==Ct(e)),s=null;const o="fixed"===Ft(e).position;let a=o?$t(e):e;for(;At(a)&&!Wt(a);){const t=Ft(a),n=zt(a);n||"fixed"!==t.position||(s=null),(o?!n&&!s:!n&&"static"===t.position&&s&&("absolute"===s.position||"fixed"===s.position)||Et(a)&&!n&&rn(e,a))?r=r.filter(e=>e!==a):s=t,a=$t(a)}return t.set(e,r),r}(t,this._c):[].concat(n),r],a=nn(t,o[0],s);let l=a.top,i=a.right,c=a.bottom,d=a.left;for(let u=1;u<o.length;u++){const e=nn(t,o[u],s);l=Ze(e.top,l),i=Ge(e.right,i),c=Ge(e.bottom,c),d=Ze(e.left,d)}return{width:i-d,height:c-l,x:d,y:l}},getOffsetParent:ln,getElementRects:async function(e){const t=this.getOffsetParent||ln,n=this.getDimensions,r=await n(e.floating);return{reference:sn(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Xt(e);return{width:t,height:n}},getScale:Gt,isElement:At,isRTL:function(e){return"rtl"===Ft(e).direction}};function dn(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function un(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:s=!0,ancestorResize:o=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:i=!1}=r,c=Yt(e),d=s||o?[...c?Kt(c):[],...t?Kt(t):[]]:[];d.forEach(e=>{s&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)});const u=c&&l?function(e,t){let n,r=null;const s=Rt(e);function o(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function a(l,i){void 0===l&&(l=!1),void 0===i&&(i=1),o();const c=e.getBoundingClientRect(),{left:d,top:u,width:h,height:f}=c;if(l||t(),!h||!f)return;const p={rootMargin:-Je(u)+"px "+-Je(s.clientWidth-(d+h))+"px "+-Je(s.clientHeight-(u+f))+"px "+-Je(d)+"px",threshold:Ze(0,Ge(1,i))||1};let m=!0;function x(t){const r=t[0].intersectionRatio;if(r!==i){if(!m)return a();r?a(!1,r):n=setTimeout(()=>{a(!1,1e-7)},1e3)}1!==r||dn(c,e.getBoundingClientRect())||a(),m=!1}try{r=new IntersectionObserver(x,{...p,root:s.ownerDocument})}catch(g){r=new IntersectionObserver(x,p)}r.observe(e)}(!0),o}(c,n):null;let h,f=-1,p=null;a&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===c&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;null==(e=p)||e.observe(t)})),n()}),c&&!i&&p.observe(c),t&&p.observe(t));let m=i?Jt(e):null;return i&&function t(){const r=Jt(e);m&&!dn(m,r)&&n();m=r,h=requestAnimationFrame(t)}(),n(),()=>{var e;d.forEach(e=>{s&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)}),null==u||u(),null==(e=p)||e.disconnect(),p=null,i&&cancelAnimationFrame(h)}}const hn=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:s,y:o,placement:a,middlewareData:l}=t,i=await async function(e,t){const{placement:n,platform:r,elements:s}=e,o=await(null==r.isRTL?void 0:r.isRTL(s.floating)),a=st(n),l=ot(n),i="y"===it(n),c=Nt.has(a)?-1:1,d=o&&i?-1:1,u=rt(t,e);let{mainAxis:h,crossAxis:f,alignmentAxis:p}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return l&&"number"==typeof p&&(f="end"===l?-1*p:p),i?{x:f*d,y:h*c}:{x:h*c,y:f*d}}(t,e);return a===(null==(n=l.offset)?void 0:n.placement)&&null!=(r=l.arrow)&&r.alignmentOffset?{}:{x:s+i.x,y:o+i.y,data:{...i,placement:a}}}}},fn=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:s,platform:o}=t,{mainAxis:a=!0,crossAxis:l=!1,limiter:i={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=rt(e,t),d={x:n,y:r},u=await o.detectOverflow(t,c),h=it(st(s)),f=at(h);let p=d[f],m=d[h];if(a){const e="y"===f?"bottom":"right";p=nt(p+u["y"===f?"top":"left"],p,p-u[e])}if(l){const e="y"===h?"bottom":"right";m=nt(m+u["y"===h?"top":"left"],m,m-u[e])}const x=i.fn({...t,[f]:p,[h]:m});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[f]:a,[h]:l}}}}}},pn=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:s,middlewareData:o,rects:a,initialPlacement:l,platform:i,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:m=!0,...x}=rt(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const g=st(s),y=it(l),v=st(l)===l,w=await(null==i.isRTL?void 0:i.isRTL(c.floating)),b=h||(v||!m?[xt(l)]:function(e){const t=xt(e);return[dt(e),t,dt(t)]}(l)),j="none"!==p;!h&&j&&b.push(...mt(l,m,p,w));const N=[l,...b],S=await i.detectOverflow(t,x),C=[];let k=(null==(r=o.flip)?void 0:r.overflows)||[];if(d&&C.push(S[g]),u){const e=function(e,t,n){void 0===n&&(n=!1);const r=ot(e),s=ct(e),o=lt(s);let a="x"===s?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=xt(a)),[a,xt(a)]}(s,a,w);C.push(S[e[0]],S[e[1]])}if(k=[...k,{placement:s,overflows:C}],!C.every(e=>e<=0)){var R,P;const e=((null==(R=o.flip)?void 0:R.index)||0)+1,t=N[e];if(t){if(!("alignment"===u&&y!==it(t))||k.every(e=>it(e.placement)!==y||e.overflows[0]>0))return{data:{index:e,overflows:k},reset:{placement:t}}}let n=null==(P=k.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:P.placement;if(!n)switch(f){case"bestFit":{var A;const e=null==(A=k.filter(e=>{if(j){const t=it(e.placement);return t===y||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:A[0];e&&(n=e);break}case"initialPlacement":n=l}if(s!==n)return{reset:{placement:n}}}return{}}}},mn=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:s,rects:o,platform:a,elements:l}=t,{apply:i=()=>{},...c}=rt(e,t),d=await a.detectOverflow(t,c),u=st(s),h=ot(s),f="y"===it(s),{width:p,height:m}=o.floating;let x,g;"top"===u||"bottom"===u?(x=u,g=h===(await(null==a.isRTL?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(g=u,x="end"===h?"top":"bottom");const y=m-d.top-d.bottom,v=p-d.left-d.right,w=Ge(m-d[x],y),b=Ge(p-d[g],v),j=!t.middlewareData.shift;let N=w,S=b;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(S=v),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(N=y),j&&!h){const e=Ze(d.left,0),t=Ze(d.right,0),n=Ze(d.top,0),r=Ze(d.bottom,0);f?S=p-2*(0!==e||0!==t?e+t:Ze(d.left,d.right)):N=m-2*(0!==n||0!==r?n+r:Ze(d.top,d.bottom))}await i({...t,availableWidth:S,availableHeight:N});const C=await a.getDimensions(l.floating);return p!==C.width||m!==C.height?{reset:{rects:!0}}:{}}}},xn=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:s="referenceHidden",...o}=rt(e,t);switch(s){case"referenceHidden":{const e=bt(await r.detectOverflow(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:jt(e)}}}case"escaped":{const e=bt(await r.detectOverflow(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:jt(e)}}}default:return{}}}}},gn=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:s,rects:o,platform:a,elements:l,middlewareData:i}=t,{element:c,padding:d=0}=rt(e,t)||{};if(null==c)return{};const u=gt(d),h={x:n,y:r},f=ct(s),p=lt(f),m=await a.getDimensions(c),x="y"===f,g=x?"top":"left",y=x?"bottom":"right",v=x?"clientHeight":"clientWidth",w=o.reference[p]+o.reference[f]-h[f]-o.floating[p],b=h[f]-o.reference[f],j=await(null==a.getOffsetParent?void 0:a.getOffsetParent(c));let N=j?j[v]:0;N&&await(null==a.isElement?void 0:a.isElement(j))||(N=l.floating[v]||o.floating[p]);const S=w/2-b/2,C=N/2-m[p]/2-1,k=Ge(u[g],C),R=Ge(u[y],C),P=k,A=N-m[p]-R,D=N/2-m[p]/2+S,T=nt(P,D,A),E=!i.arrow&&null!=ot(s)&&D!==T&&o.reference[p]/2-(D<P?k:R)-m[p]/2<0,O=E?D<P?D-P:D-A:0;return{[f]:h[f]+O,data:{[f]:T,centerOffset:D-T-O,...E&&{alignmentOffset:O}},reset:E}}}),yn=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:s,rects:o,middlewareData:a}=t,{offset:l=0,mainAxis:i=!0,crossAxis:c=!0}=rt(e,t),d={x:n,y:r},u=it(s),h=at(u);let f=d[h],p=d[u];const m=rt(l,t),x="number"==typeof m?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(i){const e="y"===h?"height":"width",t=o.reference[h]-o.floating[e]+x.mainAxis,n=o.reference[h]+o.reference[e]-x.mainAxis;f<t?f=t:f>n&&(f=n)}if(c){var g,y;const e="y"===h?"width":"height",t=Nt.has(st(s)),n=o.reference[u]-o.floating[e]+(t&&(null==(g=a.offset)?void 0:g[u])||0)+(t?0:x.crossAxis),r=o.reference[u]+o.reference[e]+(t?0:(null==(y=a.offset)?void 0:y[u])||0)-(t?x.crossAxis:0);p<n?p=n:p>r&&(p=r)}return{[h]:f,[u]:p}}}},vn=(e,t,n)=>{const r=new Map,s={platform:cn,...n},o={...s.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:s="absolute",middleware:o=[],platform:a}=n,l=a.detectOverflow?a:{...a,detectOverflow:wt},i=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:s}),{x:d,y:u}=vt(c,r,i),h=r,f=0;const p={};for(let m=0;m<o.length;m++){const n=o[m];if(!n)continue;const{name:x,fn:g}=n,{x:y,y:v,data:w,reset:b}=await g({x:d,y:u,initialPlacement:r,placement:h,strategy:s,middlewareData:p,rects:c,platform:l,elements:{reference:e,floating:t}});d=null!=y?y:d,u=null!=v?v:u,p[x]={...p[x],...w},b&&f<50&&(f++,"object"==typeof b&&(b.placement&&(h=b.placement),b.rects&&(c=!0===b.rects?await a.getElementRects({reference:e,floating:t,strategy:s}):b.rects),({x:d,y:u}=vt(c,h,i))),m=-1)}return{x:d,y:u,placement:h,strategy:s,middlewareData:p}})(e,t,{...s,platform:o})};var wn="undefined"!=typeof document?t.useLayoutEffect:function(){};function bn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,s;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!==r--;)if(!bn(e[r],t[r]))return!1;return!0}if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(r=n;0!==r--;)if(!{}.hasOwnProperty.call(t,s[r]))return!1;for(r=n;0!==r--;){const n=s[r];if(("_owner"!==n||!e.$$typeof)&&!bn(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function jn(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Nn(e,t){const n=jn(e);return Math.round(t*n)/n}function Sn(e){const n=t.useRef(e);return wn(()=>{n.current=e}),n}const Cn=(e,t)=>{const n=hn(e);return{name:n.name,fn:n.fn,options:[e,t]}},kn=(e,t)=>{const n=fn(e);return{name:n.name,fn:n.fn,options:[e,t]}},Rn=(e,t)=>{const n=pn(e);return{name:n.name,fn:n.fn,options:[e,t]}},Pn=(e,t)=>{const n=mn(e);return{name:n.name,fn:n.fn,options:[e,t]}},An=(e,t)=>{const n=xn(e);return{name:n.name,fn:n.fn,options:[e,t]}},Dn=(e,t)=>{const n=(e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&(s=n,{}.hasOwnProperty.call(s,"current"))?null!=n.current?gn({element:n.current,padding:r}).fn(t):{}:n?gn({element:n,padding:r}).fn(t):{};var s}}))(e);return{name:n.name,fn:n.fn,options:[e,t]}};var Tn=t.forwardRef((e,t)=>{const{children:n,width:r=10,height:s=5,...l}=e;return o.jsx(a.svg,{...l,ref:t,width:r,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:o.jsx("polygon",{points:"0,0 30,0 15,10"})})});Tn.displayName="Arrow";var En=Tn,On="Popper",[_n,Mn]=i(On),[In,Ln]=_n(On),Hn=e=>{const{__scopePopper:n,children:r}=e,[s,a]=t.useState(null);return o.jsx(In,{scope:n,anchor:s,onAnchorChange:a,children:r})};Hn.displayName=On;var zn="PopperAnchor",Vn=t.forwardRef((e,n)=>{const{__scopePopper:s,virtualRef:l,...i}=e,c=Ln(zn,s),d=t.useRef(null),u=r(n,d),h=t.useRef(null);return t.useEffect(()=>{const e=h.current;h.current=(null==l?void 0:l.current)||d.current,e!==h.current&&c.onAnchorChange(h.current)}),l?null:o.jsx(a.div,{...i,ref:u})});Vn.displayName=zn;var Wn="PopperContent",[Fn,Bn]=_n(Wn),$n=t.forwardRef((e,s)=>{var l,i,c,h,f,p;const{__scopePopper:m,side:x="bottom",sideOffset:g=0,align:y="center",alignOffset:v=0,arrowPadding:w=0,avoidCollisions:b=!0,collisionBoundary:j=[],collisionPadding:N=0,sticky:S="partial",hideWhenDetached:C=!1,updatePositionStrategy:k="optimized",onPlaced:R,...P}=e,A=Ln(Wn,m),[D,T]=t.useState(null),E=r(s,e=>T(e)),[O,_]=t.useState(null),M=Ie(O),I=(null==M?void 0:M.width)??0,L=(null==M?void 0:M.height)??0,H=x+("center"!==y?"-"+y:""),z="number"==typeof N?N:{top:0,right:0,bottom:0,left:0,...N},V=Array.isArray(j)?j:[j],W=V.length>0,F={padding:z,boundary:V.filter(Xn),altBoundary:W},{refs:B,floatingStyles:$,placement:U,isPositioned:K,middlewareData:q}=function(e){void 0===e&&(e={});const{placement:n="bottom",strategy:r="absolute",middleware:s=[],platform:o,elements:{reference:a,floating:l}={},transform:i=!0,whileElementsMounted:c,open:u}=e,[h,f]=t.useState({x:0,y:0,strategy:r,placement:n,middlewareData:{},isPositioned:!1}),[p,m]=t.useState(s);bn(p,s)||m(s);const[x,g]=t.useState(null),[y,v]=t.useState(null),w=t.useCallback(e=>{e!==S.current&&(S.current=e,g(e))},[]),b=t.useCallback(e=>{e!==C.current&&(C.current=e,v(e))},[]),j=a||x,N=l||y,S=t.useRef(null),C=t.useRef(null),k=t.useRef(h),R=null!=c,P=Sn(c),A=Sn(o),D=Sn(u),T=t.useCallback(()=>{if(!S.current||!C.current)return;const e={placement:n,strategy:r,middleware:p};A.current&&(e.platform=A.current),vn(S.current,C.current,e).then(e=>{const t={...e,isPositioned:!1!==D.current};E.current&&!bn(k.current,t)&&(k.current=t,d.flushSync(()=>{f(t)}))})},[p,n,r,A,D]);wn(()=>{!1===u&&k.current.isPositioned&&(k.current.isPositioned=!1,f(e=>({...e,isPositioned:!1})))},[u]);const E=t.useRef(!1);wn(()=>(E.current=!0,()=>{E.current=!1}),[]),wn(()=>{if(j&&(S.current=j),N&&(C.current=N),j&&N){if(P.current)return P.current(j,N,T);T()}},[j,N,T,P,R]);const O=t.useMemo(()=>({reference:S,floating:C,setReference:w,setFloating:b}),[w,b]),_=t.useMemo(()=>({reference:j,floating:N}),[j,N]),M=t.useMemo(()=>{const e={position:r,left:0,top:0};if(!_.floating)return e;const t=Nn(_.floating,h.x),n=Nn(_.floating,h.y);return i?{...e,transform:"translate("+t+"px, "+n+"px)",...jn(_.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:t,top:n}},[r,i,_.floating,h.x,h.y]);return t.useMemo(()=>({...h,update:T,refs:O,elements:_,floatingStyles:M}),[h,T,O,_,M])}({strategy:"fixed",placement:H,whileElementsMounted:(...e)=>un(...e,{animationFrame:"always"===k}),elements:{reference:A.anchor},middleware:[Cn({mainAxis:g+L,alignmentAxis:v}),b&&kn({mainAxis:!0,crossAxis:!1,limiter:"partial"===S?{fn:yn(X).fn,options:[X,Y]}:void 0,...F}),b&&Rn({...F}),Pn({...F,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:s,height:o}=t.reference,a=e.floating.style;a.setProperty("--radix-popper-available-width",`${n}px`),a.setProperty("--radix-popper-available-height",`${r}px`),a.setProperty("--radix-popper-anchor-width",`${s}px`),a.setProperty("--radix-popper-anchor-height",`${o}px`)}}),O&&Dn({element:O,padding:w}),Yn({arrowWidth:I,arrowHeight:L}),C&&An({strategy:"referenceHidden",...F})]});var X,Y;const[G,Z]=Gn(U),Q=u(R);n(()=>{K&&(null==Q||Q())},[K,Q]);const J=null==(l=q.arrow)?void 0:l.x,ee=null==(i=q.arrow)?void 0:i.y,te=0!==(null==(c=q.arrow)?void 0:c.centerOffset),[ne,re]=t.useState();return n(()=>{D&&re(window.getComputedStyle(D).zIndex)},[D]),o.jsx("div",{ref:B.setFloating,"data-radix-popper-content-wrapper":"",style:{...$,transform:K?$.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ne,"--radix-popper-transform-origin":[null==(h=q.transformOrigin)?void 0:h.x,null==(f=q.transformOrigin)?void 0:f.y].join(" "),...(null==(p=q.hide)?void 0:p.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:o.jsx(Fn,{scope:m,placedSide:G,onArrowChange:_,arrowX:J,arrowY:ee,shouldHideArrow:te,children:o.jsx(a.div,{"data-side":G,"data-align":Z,...P,ref:E,style:{...P.style,animation:K?void 0:"none"}})})})});$n.displayName=Wn;var Un="PopperArrow",Kn={top:"bottom",right:"left",bottom:"top",left:"right"},qn=t.forwardRef(function(e,t){const{__scopePopper:n,...r}=e,s=Bn(Un,n),a=Kn[s.placedSide];return o.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:o.jsx(En,{...r,ref:t,style:{...r.style,display:"block"}})})});function Xn(e){return null!==e}qn.displayName=Un;var Yn=e=>({name:"transformOrigin",options:e,fn(t){var n,r,s;const{placement:o,rects:a,middlewareData:l}=t,i=0!==(null==(n=l.arrow)?void 0:n.centerOffset),c=i?0:e.arrowWidth,d=i?0:e.arrowHeight,[u,h]=Gn(o),f={start:"0%",center:"50%",end:"100%"}[h],p=((null==(r=l.arrow)?void 0:r.x)??0)+c/2,m=((null==(s=l.arrow)?void 0:s.y)??0)+d/2;let x="",g="";return"bottom"===u?(x=i?f:`${p}px`,g=-d+"px"):"top"===u?(x=i?f:`${p}px`,g=`${a.floating.height+d}px`):"right"===u?(x=-d+"px",g=i?f:`${m}px`):"left"===u&&(x=`${a.floating.width+d}px`,g=i?f:`${m}px`),{data:{x:x,y:g}}}});function Gn(e){const[t,n="center"]=e.split("-");return[t,n]}var Zn=Hn,Qn=Vn,Jn=$n,er=qn;function tr(e){const n=nr(e),r=t.forwardRef((e,r)=>{const{children:s,...a}=e,l=t.Children.toArray(s),i=l.find(sr);if(i){const e=i.props.children,s=l.map(n=>n===i?t.Children.count(e)>1?t.Children.only(null):t.isValidElement(e)?e.props.children:null:n);return o.jsx(n,{...a,ref:r,children:t.isValidElement(e)?t.cloneElement(e,void 0,s):null})}return o.jsx(n,{...a,ref:r,children:s})});return r.displayName=`${e}.Slot`,r}function nr(e){const n=t.forwardRef((e,n)=>{const{children:r,...s}=e;if(t.isValidElement(r)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,s=r&&"isReactWarning"in r&&r.isReactWarning;if(s)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s)return e.props.ref;return e.props.ref||e.ref}(r),o=function(e,t){const n={...t};for(const r in t){const s=e[r],o=t[r];/^on[A-Z]/.test(r)?s&&o?n[r]=(...e)=>{const t=o(...e);return s(...e),t}:s&&(n[r]=s):"style"===r?n[r]={...s,...o}:"className"===r&&(n[r]=[s,o].filter(Boolean).join(" "))}return{...e,...n}}(s,r.props);return r.type!==t.Fragment&&(o.ref=n?h(n,e):e),t.cloneElement(r,o)}return t.Children.count(r)>1?t.Children.only(null):null});return n.displayName=`${e}.SlotClone`,n}var rr=Symbol("radix.slottable");function sr(e){return t.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===rr}var or=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"});t.forwardRef((e,t)=>o.jsx(a.span,{...e,ref:t,style:{...or,...e.style}})).displayName="VisuallyHidden";var ar=[" ","Enter","ArrowUp","ArrowDown"],lr=[" ","Enter"],ir="Select",[cr,dr,ur]=pe(ir),[hr]=i(ir,[ur,Mn]),fr=Mn(),[pr,mr]=hr(ir),[xr,gr]=hr(ir),yr=e=>{const{__scopeSelect:n,children:r,open:a,defaultOpen:l,onOpenChange:i,value:c,defaultValue:d,onValueChange:u,dir:h,name:p,autoComplete:m,disabled:x,required:g,form:y}=e,v=fr(n),[w,b]=t.useState(null),[j,N]=t.useState(null),[S,C]=t.useState(!1),k=fe(h),[R,P]=s({prop:a,defaultProp:l??!1,onChange:i,caller:ir}),[A,D]=s({prop:c,defaultProp:d,onChange:u,caller:ir}),T=t.useRef(null),E=!w||(y||!!w.closest("form")),[O,_]=t.useState(new Set),M=Array.from(O).map(e=>e.props.value).join(";");return o.jsx(Zn,{...v,children:o.jsxs(pr,{required:g,scope:n,trigger:w,onTriggerChange:b,valueNode:j,onValueNodeChange:N,valueNodeHasChildren:S,onValueNodeHasChildrenChange:C,contentId:f(),value:A,onValueChange:D,open:R,onOpenChange:P,dir:k,triggerPointerDownPosRef:T,disabled:x,children:[o.jsx(cr.Provider,{scope:n,children:o.jsx(xr,{scope:e.__scopeSelect,onNativeOptionAdd:t.useCallback(e=>{_(t=>new Set(t).add(e))},[]),onNativeOptionRemove:t.useCallback(e=>{_(t=>{const n=new Set(t);return n.delete(e),n})},[]),children:r})}),E?o.jsxs(ss,{"aria-hidden":!0,required:g,tabIndex:-1,name:p,autoComplete:m,value:A,onChange:e=>D(e.target.value),disabled:x,form:y,children:[void 0===A?o.jsx("option",{value:""}):null,Array.from(O)]},M):null]})})};yr.displayName=ir;var vr="SelectTrigger",wr=t.forwardRef((e,n)=>{const{__scopeSelect:s,disabled:i=!1,...c}=e,d=fr(s),u=mr(vr,s),h=u.disabled||i,f=r(n,u.onTriggerChange),p=dr(s),m=t.useRef("touch"),[x,g,y]=as(e=>{const t=p().filter(e=>!e.disabled),n=t.find(e=>e.value===u.value),r=ls(t,e,n);void 0!==r&&u.onValueChange(r.value)}),v=e=>{h||(u.onOpenChange(!0),y()),e&&(u.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})};return o.jsx(Qn,{asChild:!0,...d,children:o.jsx(a.button,{type:"button",role:"combobox","aria-controls":u.contentId,"aria-expanded":u.open,"aria-required":u.required,"aria-autocomplete":"none",dir:u.dir,"data-state":u.open?"open":"closed",disabled:h,"data-disabled":h?"":void 0,"data-placeholder":os(u.value)?"":void 0,...c,ref:f,onClick:l(c.onClick,e=>{e.currentTarget.focus(),"mouse"!==m.current&&v(e)}),onPointerDown:l(c.onPointerDown,e=>{m.current=e.pointerType;const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&"mouse"===e.pointerType&&(v(e),e.preventDefault())}),onKeyDown:l(c.onKeyDown,e=>{const t=""!==x.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||g(e.key),t&&" "===e.key||ar.includes(e.key)&&(v(),e.preventDefault())})})})});wr.displayName=vr;var br="SelectValue",jr=t.forwardRef((e,t)=>{const{__scopeSelect:s,className:l,style:i,children:c,placeholder:d="",...u}=e,h=mr(br,s),{onValueNodeHasChildrenChange:f}=h,p=void 0!==c,m=r(t,h.onValueNodeChange);return n(()=>{f(p)},[f,p]),o.jsx(a.span,{...u,ref:m,style:{pointerEvents:"none"},children:os(h.value)?o.jsx(o.Fragment,{children:d}):c})});jr.displayName=br;var Nr=t.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...s}=e;return o.jsx(a.span,{"aria-hidden":!0,...s,ref:t,children:r||"▼"})});Nr.displayName="SelectIcon";var Sr=e=>o.jsx(p,{asChild:!0,...e});Sr.displayName="SelectPortal";var Cr="SelectContent",kr=t.forwardRef((e,r)=>{const s=mr(Cr,e.__scopeSelect),[a,l]=t.useState();if(n(()=>{l(new DocumentFragment)},[]),!s.open){const t=a;return t?d.createPortal(o.jsx(Pr,{scope:e.__scopeSelect,children:o.jsx(cr.Slot,{scope:e.__scopeSelect,children:o.jsx("div",{children:e.children})})}),t):null}return o.jsx(Tr,{...e,ref:r})});kr.displayName=Cr;var Rr=10,[Pr,Ar]=hr(Cr),Dr=tr("SelectContent.RemoveScroll"),Tr=t.forwardRef((e,n)=>{const{__scopeSelect:s,position:a="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:c,onPointerDownOutside:d,side:u,sideOffset:h,align:f,alignOffset:p,arrowPadding:w,collisionBoundary:b,collisionPadding:j,sticky:N,hideWhenDetached:S,avoidCollisions:C,...k}=e,R=mr(Cr,s),[P,A]=t.useState(null),[D,T]=t.useState(null),E=r(n,e=>A(e)),[O,_]=t.useState(null),[M,I]=t.useState(null),L=dr(s),[H,z]=t.useState(!1),V=t.useRef(!1);t.useEffect(()=>{if(P)return m(P)},[P]),x();const W=t.useCallback(e=>{const[t,...n]=L().map(e=>e.ref.current),[r]=n.slice(-1),s=document.activeElement;for(const o of e){if(o===s)return;if(null==o||o.scrollIntoView({block:"nearest"}),o===t&&D&&(D.scrollTop=0),o===r&&D&&(D.scrollTop=D.scrollHeight),null==o||o.focus(),document.activeElement!==s)return}},[L,D]),F=t.useCallback(()=>W([O,P]),[W,O,P]);t.useEffect(()=>{H&&F()},[H,F]);const{onOpenChange:B,triggerPointerDownPosRef:$}=R;t.useEffect(()=>{if(P){let e={x:0,y:0};const t=t=>{var n,r;e={x:Math.abs(Math.round(t.pageX)-((null==(n=$.current)?void 0:n.x)??0)),y:Math.abs(Math.round(t.pageY)-((null==(r=$.current)?void 0:r.y)??0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():P.contains(n.target)||B(!1),document.removeEventListener("pointermove",t),$.current=null};return null!==$.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}},[P,B,$]),t.useEffect(()=>{const e=()=>B(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}},[B]);const[U,K]=as(e=>{const t=L().filter(e=>!e.disabled),n=t.find(e=>e.ref.current===document.activeElement),r=ls(t,e,n);r&&setTimeout(()=>r.ref.current.focus())}),q=t.useCallback((e,t,n)=>{const r=!V.current&&!n;(void 0!==R.value&&R.value===t||r)&&(_(e),r&&(V.current=!0))},[R.value]),X=t.useCallback(()=>null==P?void 0:P.focus(),[P]),Y=t.useCallback((e,t,n)=>{const r=!V.current&&!n;(void 0!==R.value&&R.value===t||r)&&I(e)},[R.value]),G="popper"===a?Or:Er,Z=G===Or?{side:u,sideOffset:h,align:f,alignOffset:p,arrowPadding:w,collisionBoundary:b,collisionPadding:j,sticky:N,hideWhenDetached:S,avoidCollisions:C}:{};return o.jsx(Pr,{scope:s,content:P,viewport:D,onViewportChange:T,itemRefCallback:q,selectedItem:O,onItemLeave:X,itemTextRefCallback:Y,focusSelectedItem:F,selectedItemText:M,position:a,isPositioned:H,searchRef:U,children:o.jsx(g,{as:Dr,allowPinchZoom:!0,children:o.jsx(y,{asChild:!0,trapped:R.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:l(i,e=>{var t;null==(t=R.trigger)||t.focus({preventScroll:!0}),e.preventDefault()}),children:o.jsx(v,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>R.onOpenChange(!1),children:o.jsx(G,{role:"listbox",id:R.contentId,"data-state":R.open?"open":"closed",dir:R.dir,onContextMenu:e=>e.preventDefault(),...k,...Z,onPlaced:()=>z(!0),ref:E,style:{display:"flex",flexDirection:"column",outline:"none",...k.style},onKeyDown:l(k.onKeyDown,e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||K(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=L().filter(e=>!e.disabled).map(e=>e.ref.current);if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout(()=>W(t)),e.preventDefault()}})})})})})})});Tr.displayName="SelectContentImpl";var Er=t.forwardRef((e,s)=>{const{__scopeSelect:l,onPlaced:i,...c}=e,d=mr(Cr,l),u=Ar(Cr,l),[h,f]=t.useState(null),[p,m]=t.useState(null),x=r(s,e=>m(e)),g=dr(l),y=t.useRef(!1),v=t.useRef(!0),{viewport:w,selectedItem:b,selectedItemText:j,focusSelectedItem:N}=u,S=t.useCallback(()=>{if(d.trigger&&d.valueNode&&h&&p&&w&&b&&j){const e=d.trigger.getBoundingClientRect(),t=p.getBoundingClientRect(),n=d.valueNode.getBoundingClientRect(),r=j.getBoundingClientRect();if("rtl"!==d.dir){const s=r.left-t.left,o=n.left-s,a=e.left-o,l=e.width+a,i=Math.max(l,t.width),c=window.innerWidth-Rr,d=me(o,[Rr,Math.max(Rr,c-i)]);h.style.minWidth=l+"px",h.style.left=d+"px"}else{const s=t.right-r.right,o=window.innerWidth-n.right-s,a=window.innerWidth-e.right-o,l=e.width+a,i=Math.max(l,t.width),c=window.innerWidth-Rr,d=me(o,[Rr,Math.max(Rr,c-i)]);h.style.minWidth=l+"px",h.style.right=d+"px"}const s=g(),o=window.innerHeight-2*Rr,a=w.scrollHeight,l=window.getComputedStyle(p),c=parseInt(l.borderTopWidth,10),u=parseInt(l.paddingTop,10),f=parseInt(l.borderBottomWidth,10),m=c+u+a+parseInt(l.paddingBottom,10)+f,x=Math.min(5*b.offsetHeight,m),v=window.getComputedStyle(w),N=parseInt(v.paddingTop,10),S=parseInt(v.paddingBottom,10),C=e.top+e.height/2-Rr,k=o-C,R=b.offsetHeight/2,P=c+u+(b.offsetTop+R),A=m-P;if(P<=C){const e=s.length>0&&b===s[s.length-1].ref.current;h.style.bottom="0px";const t=p.clientHeight-w.offsetTop-w.offsetHeight,n=P+Math.max(k,R+(e?S:0)+t+f);h.style.height=n+"px"}else{const e=s.length>0&&b===s[0].ref.current;h.style.top="0px";const t=Math.max(C,c+w.offsetTop+(e?N:0)+R)+A;h.style.height=t+"px",w.scrollTop=P-C+w.offsetTop}h.style.margin=`${Rr}px 0`,h.style.minHeight=x+"px",h.style.maxHeight=o+"px",null==i||i(),requestAnimationFrame(()=>y.current=!0)}},[g,d.trigger,d.valueNode,h,p,w,b,j,d.dir,i]);n(()=>S(),[S]);const[C,k]=t.useState();n(()=>{p&&k(window.getComputedStyle(p).zIndex)},[p]);const R=t.useCallback(e=>{e&&!0===v.current&&(S(),null==N||N(),v.current=!1)},[S,N]);return o.jsx(_r,{scope:l,contentWrapper:h,shouldExpandOnScrollRef:y,onScrollButtonChange:R,children:o.jsx("div",{ref:f,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:C},children:o.jsx(a.div,{...c,ref:x,style:{boxSizing:"border-box",maxHeight:"100%",...c.style}})})})});Er.displayName="SelectItemAlignedPosition";var Or=t.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:s=Rr,...a}=e,l=fr(n);return o.jsx(Jn,{...l,...a,ref:t,align:r,collisionPadding:s,style:{boxSizing:"border-box",...a.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Or.displayName="SelectPopperPosition";var[_r,Mr]=hr(Cr,{}),Ir="SelectViewport",Lr=t.forwardRef((e,n)=>{const{__scopeSelect:s,nonce:i,...c}=e,d=Ar(Ir,s),u=Mr(Ir,s),h=r(n,d.onViewportChange),f=t.useRef(0);return o.jsxs(o.Fragment,{children:[o.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:i}),o.jsx(cr.Slot,{scope:s,children:o.jsx(a.div,{"data-radix-select-viewport":"",role:"presentation",...c,ref:h,style:{position:"relative",flex:1,overflow:"hidden auto",...c.style},onScroll:l(c.onScroll,e=>{const t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=u;if((null==r?void 0:r.current)&&n){const e=Math.abs(f.current-t.scrollTop);if(e>0){const r=window.innerHeight-2*Rr,s=parseFloat(n.style.minHeight),o=parseFloat(n.style.height),a=Math.max(s,o);if(a<r){const s=a+e,o=Math.min(r,s),l=s-o;n.style.height=o+"px","0px"===n.style.bottom&&(t.scrollTop=l>0?l:0,n.style.justifyContent="flex-end")}}}f.current=t.scrollTop})})})]})});Lr.displayName=Ir;var Hr="SelectGroup",[zr,Vr]=hr(Hr);t.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=f();return o.jsx(zr,{scope:n,id:s,children:o.jsx(a.div,{role:"group","aria-labelledby":s,...r,ref:t})})}).displayName=Hr;var Wr="SelectLabel",Fr=t.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=Vr(Wr,n);return o.jsx(a.div,{id:s.id,...r,ref:t})});Fr.displayName=Wr;var Br="SelectItem",[$r,Ur]=hr(Br),Kr=t.forwardRef((e,n)=>{const{__scopeSelect:s,value:i,disabled:c=!1,textValue:d,...u}=e,h=mr(Br,s),p=Ar(Br,s),m=h.value===i,[x,g]=t.useState(d??""),[y,v]=t.useState(!1),w=r(n,e=>{var t;return null==(t=p.itemRefCallback)?void 0:t.call(p,e,i,c)}),b=f(),j=t.useRef("touch"),N=()=>{c||(h.onValueChange(i),h.onOpenChange(!1))};if(""===i)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return o.jsx($r,{scope:s,value:i,disabled:c,textId:b,isSelected:m,onItemTextChange:t.useCallback(e=>{g(t=>t||((null==e?void 0:e.textContent)??"").trim())},[]),children:o.jsx(cr.ItemSlot,{scope:s,value:i,disabled:c,textValue:x,children:o.jsx(a.div,{role:"option","aria-labelledby":b,"data-highlighted":y?"":void 0,"aria-selected":m&&y,"data-state":m?"checked":"unchecked","aria-disabled":c||void 0,"data-disabled":c?"":void 0,tabIndex:c?void 0:-1,...u,ref:w,onFocus:l(u.onFocus,()=>v(!0)),onBlur:l(u.onBlur,()=>v(!1)),onClick:l(u.onClick,()=>{"mouse"!==j.current&&N()}),onPointerUp:l(u.onPointerUp,()=>{"mouse"===j.current&&N()}),onPointerDown:l(u.onPointerDown,e=>{j.current=e.pointerType}),onPointerMove:l(u.onPointerMove,e=>{var t;j.current=e.pointerType,c?null==(t=p.onItemLeave)||t.call(p):"mouse"===j.current&&e.currentTarget.focus({preventScroll:!0})}),onPointerLeave:l(u.onPointerLeave,e=>{var t;e.currentTarget===document.activeElement&&(null==(t=p.onItemLeave)||t.call(p))}),onKeyDown:l(u.onKeyDown,e=>{var t;""!==(null==(t=p.searchRef)?void 0:t.current)&&" "===e.key||(lr.includes(e.key)&&N()," "===e.key&&e.preventDefault())})})})})});Kr.displayName=Br;var qr="SelectItemText",Xr=t.forwardRef((e,s)=>{const{__scopeSelect:l,className:i,style:c,...u}=e,h=mr(qr,l),f=Ar(qr,l),p=Ur(qr,l),m=gr(qr,l),[x,g]=t.useState(null),y=r(s,e=>g(e),p.onItemTextChange,e=>{var t;return null==(t=f.itemTextRefCallback)?void 0:t.call(f,e,p.value,p.disabled)}),v=null==x?void 0:x.textContent,w=t.useMemo(()=>o.jsx("option",{value:p.value,disabled:p.disabled,children:v},p.value),[p.disabled,p.value,v]),{onNativeOptionAdd:b,onNativeOptionRemove:j}=m;return n(()=>(b(w),()=>j(w)),[b,j,w]),o.jsxs(o.Fragment,{children:[o.jsx(a.span,{id:p.textId,...u,ref:y}),p.isSelected&&h.valueNode&&!h.valueNodeHasChildren?d.createPortal(u.children,h.valueNode):null]})});Xr.displayName=qr;var Yr="SelectItemIndicator",Gr=t.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return Ur(Yr,n).isSelected?o.jsx(a.span,{"aria-hidden":!0,...r,ref:t}):null});Gr.displayName=Yr;var Zr="SelectScrollUpButton",Qr=t.forwardRef((e,s)=>{const a=Ar(Zr,e.__scopeSelect),l=Mr(Zr,e.__scopeSelect),[i,c]=t.useState(!1),d=r(s,l.onScrollButtonChange);return n(()=>{if(a.viewport&&a.isPositioned){let e=function(){const e=t.scrollTop>0;c(e)};const t=a.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}},[a.viewport,a.isPositioned]),i?o.jsx(ts,{...e,ref:d,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=a;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}}):null});Qr.displayName=Zr;var Jr="SelectScrollDownButton",es=t.forwardRef((e,s)=>{const a=Ar(Jr,e.__scopeSelect),l=Mr(Jr,e.__scopeSelect),[i,c]=t.useState(!1),d=r(s,l.onScrollButtonChange);return n(()=>{if(a.viewport&&a.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;c(n)};const t=a.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}},[a.viewport,a.isPositioned]),i?o.jsx(ts,{...e,ref:d,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=a;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}}):null});es.displayName=Jr;var ts=t.forwardRef((e,r)=>{const{__scopeSelect:s,onAutoScroll:i,...c}=e,d=Ar("SelectScrollButton",s),u=t.useRef(null),h=dr(s),f=t.useCallback(()=>{null!==u.current&&(window.clearInterval(u.current),u.current=null)},[]);return t.useEffect(()=>()=>f(),[f]),n(()=>{var e;const t=h().find(e=>e.ref.current===document.activeElement);null==(e=null==t?void 0:t.ref.current)||e.scrollIntoView({block:"nearest"})},[h]),o.jsx(a.div,{"aria-hidden":!0,...c,ref:r,style:{flexShrink:0,...c.style},onPointerDown:l(c.onPointerDown,()=>{null===u.current&&(u.current=window.setInterval(i,50))}),onPointerMove:l(c.onPointerMove,()=>{var e;null==(e=d.onItemLeave)||e.call(d),null===u.current&&(u.current=window.setInterval(i,50))}),onPointerLeave:l(c.onPointerLeave,()=>{f()})})}),ns=t.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return o.jsx(a.div,{"aria-hidden":!0,...r,ref:t})});ns.displayName="SelectSeparator";var rs="SelectArrow";t.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=fr(n),a=mr(rs,n),l=Ar(rs,n);return a.open&&"popper"===l.position?o.jsx(er,{...s,...r,ref:t}):null}).displayName=rs;var ss=t.forwardRef(({__scopeSelect:e,value:n,...s},l)=>{const i=t.useRef(null),c=r(l,i),d=Me(n);return t.useEffect(()=>{const e=i.current;if(!e)return;const t=window.HTMLSelectElement.prototype,r=Object.getOwnPropertyDescriptor(t,"value").set;if(d!==n&&r){const t=new Event("change",{bubbles:!0});r.call(e,n),e.dispatchEvent(t)}},[d,n]),o.jsx(a.select,{...s,style:{...or,...s.style},ref:c,defaultValue:n})});function os(e){return""===e||void 0===e}function as(e){const n=u(e),r=t.useRef(""),s=t.useRef(0),o=t.useCallback(e=>{const t=r.current+e;n(t),function e(t){r.current=t,window.clearTimeout(s.current),""!==t&&(s.current=window.setTimeout(()=>e(""),1e3))}(t)},[n]),a=t.useCallback(()=>{r.current="",window.clearTimeout(s.current)},[]);return t.useEffect(()=>()=>window.clearTimeout(s.current),[]),[r,o,a]}function ls(e,t,n){const r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let o=(a=e,l=Math.max(s,0),a.map((e,t)=>a[(l+t)%a.length]));var a,l;1===r.length&&(o=o.filter(e=>e!==n));const i=o.find(e=>e.textValue.toLowerCase().startsWith(r.toLowerCase()));return i!==n?i:void 0}ss.displayName="SelectBubbleInput";var is=wr,cs=Nr,ds=Sr,us=kr,hs=Lr,fs=Fr,ps=Kr,ms=Xr,xs=Gr,gs=Qr,ys=es,vs=ns;const ws=yr,bs=jr,js=t.forwardRef(({className:e,children:t,...n},r)=>o.jsxs(is,{ref:r,className:c("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...n,children:[t,o.jsx(cs,{asChild:!0,children:o.jsx(Ne,{className:"h-4 w-4 opacity-50"})})]}));js.displayName=is.displayName;const Ns=t.forwardRef(({className:e,...t},n)=>o.jsx(gs,{ref:n,className:c("flex cursor-default items-center justify-center py-1",e),...t,children:o.jsx(Se,{className:"h-4 w-4"})}));Ns.displayName=gs.displayName;const Ss=t.forwardRef(({className:e,...t},n)=>o.jsx(ys,{ref:n,className:c("flex cursor-default items-center justify-center py-1",e),...t,children:o.jsx(Ne,{className:"h-4 w-4"})}));Ss.displayName=ys.displayName;const Cs=t.forwardRef(({className:e,children:t,position:n="popper",...r},s)=>o.jsx(ds,{children:o.jsxs(us,{ref:s,className:c("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:[o.jsx(Ns,{}),o.jsx(hs,{className:c("p-1","popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),o.jsx(Ss,{})]})}));Cs.displayName=us.displayName;t.forwardRef(({className:e,...t},n)=>o.jsx(fs,{ref:n,className:c("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t})).displayName=fs.displayName;const ks=t.forwardRef(({className:e,children:t,...n},r)=>o.jsxs(ps,{ref:r,className:c("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[o.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:o.jsx(xs,{children:o.jsx(w,{className:"h-4 w-4"})})}),o.jsx(ms,{children:t})]}));ks.displayName=ps.displayName;t.forwardRef(({className:e,...t},n)=>o.jsx(vs,{ref:n,className:c("-mx-1 my-1 h-px bg-muted",e),...t})).displayName=vs.displayName;const Rs={"google-drive":"Google Drive",onedrive:"OneDrive",dropbox:"Dropbox"};function Ps({open:e,onOpenChange:n,onAdded:r}){const[s,a]=t.useState([]),[l,i]=t.useState(!1),[c,d]=t.useState(null),[u,h]=t.useState(""),[f,p]=t.useState(""),[m,x]=t.useState(""),[g,y]=t.useState(""),[v,w]=t.useState(!1),[O,_]=t.useState(null);t.useEffect(()=>{e&&b().then(e=>a(e.available)).catch(()=>a([]))},[e]);const M=()=>{i(!1),d(null),h(""),p(""),x(""),y(""),w(!1),_(null)},I=s.length>0;return o.jsx(j,{open:e,onOpenChange:e=>{n(e),e||M()},children:o.jsxs(N,{className:"sm:max-w-md",children:[o.jsxs(S,{children:[o.jsxs(C,{className:"flex items-center gap-2",children:[o.jsx(De,{className:"h-5 w-5"}),"添加云盘账号"]}),o.jsx(k,{children:l?"手动填写 OAuth 凭据连接云盘":"选择云盘类型,点击后跳转登录授权"})]}),l?o.jsxs(o.Fragment,{children:[o.jsxs("div",{className:"space-y-4 py-2",children:[o.jsxs("div",{className:"space-y-2",children:[o.jsx(P,{children:"云盘类型"}),o.jsxs(ws,{value:u,onValueChange:h,children:[o.jsx(js,{children:o.jsx(bs,{placeholder:"选择云盘类型"})}),o.jsxs(Cs,{children:[o.jsx(ks,{value:"google-drive",children:"Google Drive"}),o.jsx(ks,{value:"onedrive",children:"OneDrive"}),o.jsx(ks,{value:"dropbox",children:"Dropbox"})]})]})]}),o.jsxs("div",{className:"space-y-2",children:[o.jsx(P,{children:"显示名称"}),o.jsx(A,{placeholder:"例如:我的 Google Drive",value:f,onChange:e=>p(e.target.value)})]}),o.jsxs("div",{className:"space-y-2",children:[o.jsx(P,{children:"Client ID"}),o.jsx(A,{placeholder:"OAuth Client ID",value:m,onChange:e=>x(e.target.value)})]}),o.jsxs("div",{className:"space-y-2",children:[o.jsx(P,{children:"Client Secret"}),o.jsx(A,{type:"password",placeholder:"OAuth Client Secret",value:g,onChange:e=>y(e.target.value)})]}),O&&o.jsx("p",{className:"text-sm text-destructive",children:O})]}),o.jsxs(D,{children:[o.jsx(R,{variant:"outline",onClick:()=>{i(!1),_(null)},children:"返回"}),o.jsx(R,{onClick:async()=>{if(u&&f&&m&&g){w(!0),_(null);try{const{id:e}=await T({type:u,label:f,clientId:m,clientSecret:g}),{url:t}=await E(e);window.open(t,"_blank"),M(),n(!1),r()}catch(e){_(e instanceof Error?e.message:"添加失败")}finally{w(!1)}}else _("请填写所有字段")},disabled:v,children:v?"添加中...":"添加并授权"})]})]}):o.jsxs("div",{className:"space-y-3 py-2",children:[I?o.jsx(o.Fragment,{children:s.map(e=>o.jsx(R,{variant:"outline",className:"w-full justify-start gap-3 h-12 text-base",onClick:()=>{(async e=>{d(e),_(null);try{const{id:t}=await T({type:e,label:Rs[e]||e}),{url:s}=await E(t);window.open(s,"_blank"),M(),n(!1),r()}catch(t){_(t instanceof Error?t.message:"添加失败"),d(null)}})(e)},disabled:null!==c,children:c===e?"连接中...":`连接 ${Rs[e]||e}`},e))}):o.jsx("p",{className:"text-sm text-muted-foreground text-center py-4",children:"暂无内置 OAuth 凭据,请使用手动模式添加"}),O&&o.jsx("p",{className:"text-sm text-destructive",children:O}),o.jsx("div",{className:"pt-2 border-t border-border",children:o.jsxs("button",{onClick:()=>{i(!0),_(null)},className:"flex items-center gap-1.5 text-xs text-muted-foreground hover:text-foreground transition-colors",children:[o.jsx(Oe,{className:"h-3.5 w-3.5"}),"手动填写 OAuth 凭据"]})})]})]})})}const As={"google-drive":"Google Drive",onedrive:"OneDrive",dropbox:"Dropbox"};function Ds({type:e}){switch(e){case"google-drive":return o.jsx(Te,{className:"h-5 w-5 text-blue-500"});case"onedrive":return o.jsx(De,{className:"h-5 w-5 text-sky-500"});case"dropbox":return o.jsx(Te,{className:"h-5 w-5 text-indigo-500"});default:return o.jsx(De,{className:"h-5 w-5"})}}function Ts({provider:e,onDelete:n,onReauth:r}){var s;const[a,l]=t.useState(!1),i=t.useRef(null);t.useEffect(()=>()=>{i.current&&clearTimeout(i.current)},[]);return o.jsxs(O,{children:[o.jsx(_,{className:"pb-3",children:o.jsxs("div",{className:"flex items-start justify-between",children:[o.jsxs("div",{className:"flex items-center gap-3",children:[o.jsx(Ds,{type:e.type}),o.jsxs("div",{children:[o.jsx(M,{className:"text-base",children:e.label}),o.jsx("p",{className:"text-sm text-muted-foreground",children:As[e.type]||e.type})]})]}),o.jsx(I,{variant:e.authorized?"default":"destructive",className:e.authorized?"bg-green-600 hover:bg-green-700":"",children:e.authorized?"已授权":"未授权"})]})}),o.jsxs(L,{children:[e.authorized&&(null==(s=e.tokens)?void 0:s.expiry)&&o.jsxs("p",{className:"text-xs text-muted-foreground mb-3",children:["授权到期:",new Date(e.tokens.expiry).toLocaleDateString("zh-CN")]}),o.jsxs("div",{className:"flex gap-2",children:[o.jsxs(R,{variant:"outline",size:"sm",onClick:()=>r(e.id),children:[o.jsx(H,{className:"h-3.5 w-3.5 mr-1"}),"重新授权"]}),o.jsxs(R,{variant:a?"destructive":"outline",size:"sm",onClick:()=>{a?(n(e.id),l(!1)):(l(!0),i.current=setTimeout(()=>l(!1),3e3))},children:[o.jsx(z,{className:"h-3.5 w-3.5 mr-1"}),a?"确认删除?":"删除"]})]})]})]})}const Es={success:{label:"成功",icon:Pe,className:"bg-green-600 hover:bg-green-700"},failed:{label:"失败",icon:_e,className:"bg-red-600 hover:bg-red-700"},partial:{label:"部分完成",icon:ke,className:"bg-yellow-600 hover:bg-yellow-700"}};function Os(e,t){const n=new Date(t).getTime()-new Date(e).getTime();if(n<1e3)return`${n}ms`;const r=Math.floor(n/1e3);if(r<60)return`${r}秒`;return`${Math.floor(r/60)}分${r%60}秒`}function _s({history:e}){const t=e.slice(0,20);return 0===t.length?o.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-muted-foreground",children:[o.jsx(Ae,{className:"h-10 w-10 mb-3 opacity-50"}),o.jsx("p",{className:"text-sm",children:"暂无备份记录"})]}):o.jsx("div",{className:"overflow-x-auto",children:o.jsxs("table",{className:"w-full text-sm",children:[o.jsx("thead",{children:o.jsxs("tr",{className:"border-b",children:[o.jsx("th",{className:"text-left py-3 px-2 font-medium text-muted-foreground",children:"时间"}),o.jsx("th",{className:"text-left py-3 px-2 font-medium text-muted-foreground",children:"项目"}),o.jsx("th",{className:"text-left py-3 px-2 font-medium text-muted-foreground",children:"云盘"}),o.jsx("th",{className:"text-left py-3 px-2 font-medium text-muted-foreground",children:"状态"}),o.jsx("th",{className:"text-left py-3 px-2 font-medium text-muted-foreground",children:"文件数"}),o.jsx("th",{className:"text-left py-3 px-2 font-medium text-muted-foreground",children:"耗时"})]})}),o.jsx("tbody",{children:t.map(e=>{const t=Es[e.status],n=t.icon;return o.jsxs("tr",{className:"border-b last:border-0 hover:bg-muted/50",children:[o.jsx("td",{className:"py-2.5 px-2 whitespace-nowrap",children:(r=e.startTime,new Date(r).toLocaleString("zh-CN",{month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"}))}),o.jsx("td",{className:"py-2.5 px-2",children:e.projectName}),o.jsx("td",{className:"py-2.5 px-2",children:e.providerLabel}),o.jsxs("td",{className:"py-2.5 px-2",children:[o.jsxs(I,{className:t.className,children:[o.jsx(n,{className:"h-3 w-3 mr-1"}),t.label]}),e.error&&o.jsx("p",{className:"text-xs text-destructive mt-1",children:e.error})]}),o.jsxs("td",{className:"py-2.5 px-2 whitespace-nowrap",children:[e.filesUploaded,"/",e.filesTotal]}),o.jsx("td",{className:"py-2.5 px-2 whitespace-nowrap",children:Os(e.startTime,e.endTime)})]},e.id);var r})})]})})}function Ms(){const[e,n]=t.useState(null),[r,s]=t.useState(!0),[a,l]=t.useState(!1),[i,c]=t.useState(!1),[d,u]=t.useState(!1),[h,f]=t.useState(""),[p,m]=t.useState("");t.useEffect(()=>{let e=!1;return V().then(t=>{e||(n(t),m(t.defaultExcludes.join("\n")))}).catch(e=>W.error(`加载同步配置失败: ${e.message}`)).finally(()=>{e||s(!1)}),()=>{e=!0}},[]);const x=(e,t)=>{n(n=>n?{...n,[e]:t}:n)};return r||!e?o.jsx("div",{className:"text-sm text-muted-foreground",children:"加载中…"}):o.jsxs("div",{className:"space-y-6",children:[o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-semibold mb-3",children:"服务器配置"}),o.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3",children:[o.jsxs("div",{children:[o.jsx(P,{htmlFor:"sync-host",children:"主机 (host)"}),o.jsx(A,{id:"sync-host",value:e.host,onChange:e=>x("host",e.target.value),placeholder:"example.com"})]}),o.jsxs("div",{children:[o.jsx(P,{htmlFor:"sync-port",children:"端口"}),o.jsx(A,{id:"sync-port",type:"number",value:e.port,onChange:e=>x("port",Number(e.target.value)||22)})]}),o.jsxs("div",{children:[o.jsx(P,{htmlFor:"sync-user",children:"用户名"}),o.jsx(A,{id:"sync-user",value:e.user,onChange:e=>x("user",e.target.value),placeholder:"tom"})]}),o.jsxs("div",{children:[o.jsx(P,{htmlFor:"sync-remote",children:"远端根路径"}),o.jsx(A,{id:"sync-remote",value:e.remoteRoot,onChange:e=>x("remoteRoot",e.target.value),placeholder:"/data/projects"}),o.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["每个项目会同步到 ",o.jsx("code",{children:"远端路径/项目文件夹"})]})]})]})]}),o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-semibold mb-3",children:"认证"}),o.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3",children:[o.jsxs("div",{children:[o.jsx(P,{children:"方式"}),o.jsxs(ws,{value:e.authMethod,onValueChange:e=>x("authMethod",e),children:[o.jsx(js,{children:o.jsx(bs,{})}),o.jsxs(Cs,{children:[o.jsx(ks,{value:"key",children:"SSH key"}),o.jsx(ks,{value:"password",children:"密码"})]})]})]}),"key"===e.authMethod?o.jsxs("div",{children:[o.jsx(P,{htmlFor:"sync-key",children:"私钥路径"}),o.jsx(A,{id:"sync-key",value:e.keyPath??"",onChange:e=>x("keyPath",e.target.value),placeholder:"~/.ssh/id_rsa"})]}):o.jsxs("div",{children:[o.jsx(P,{htmlFor:"sync-pw",children:"密码"}),o.jsx(A,{id:"sync-pw",type:"password",value:h,onChange:e=>f(e.target.value),placeholder:e.passwordSet?"已设置,留空保持不变":"未设置"}),o.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["需要系统安装 ",o.jsx("code",{children:"sshpass"}),"(密码通过 SSHPASS env 传递,不会出现在 argv 里)"]})]})]})]}),o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-semibold mb-3",children:"同步策略"}),o.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3",children:[o.jsxs("div",{children:[o.jsx(P,{children:"方向"}),o.jsxs(ws,{value:e.direction,onValueChange:e=>x("direction",e),children:[o.jsx(js,{children:o.jsx(bs,{})}),o.jsxs(Cs,{children:[o.jsx(ks,{value:"push",children:"单向:本地 → 远端(--delete)"}),o.jsx(ks,{value:"pull",children:"单向:远端 → 本地"}),o.jsx(ks,{value:"bidirectional",children:"双向(先 push 再 pull)"})]})]})]}),o.jsxs("div",{className:"flex items-end gap-2",children:[o.jsxs("div",{className:"flex-1",children:[o.jsx(P,{htmlFor:"sync-cron",children:"定时 cron 表达式"}),o.jsx(A,{id:"sync-cron",value:e.schedule.cron,onChange:t=>x("schedule",{...e.schedule,cron:t.target.value}),placeholder:"0 3 * * *"}),o.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["5 段:分 时 日 月 周。例:",o.jsx("code",{children:"0 3 * * *"})," 每天 03:00"]})]}),o.jsxs("div",{className:"flex items-center gap-2 pb-1.5",children:[o.jsx(Xe,{checked:e.schedule.enabled,onCheckedChange:t=>x("schedule",{...e.schedule,enabled:t})}),o.jsx("span",{className:"text-xs text-muted-foreground",children:"启用"})]})]})]})]}),o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-semibold mb-3",children:"默认排除(每行一个 glob)"}),o.jsx("textarea",{value:p,onChange:e=>m(e.target.value),rows:6,className:"w-full font-mono text-xs p-2 rounded border border-input bg-background resize-y",placeholder:"node_modules/\n.git/objects/\n*.log"}),o.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["作为 ",o.jsx("code",{children:"rsync --exclude"})," 传入。项目级的额外排除暂通过 API 设置。"]})]}),o.jsxs("div",{className:"flex flex-wrap gap-2 pt-2 border-t",children:[o.jsxs(R,{onClick:()=>{(async()=>{if(e){l(!0);try{const t=p.split("\n").map(e=>e.trim()).filter(Boolean),r={host:e.host,port:e.port,user:e.user,authMethod:e.authMethod,keyPath:e.keyPath,remoteRoot:e.remoteRoot,direction:e.direction,defaultExcludes:t,schedule:e.schedule};h&&"__keep__"!==h&&(r.password=h);const s=await $(r);n(s),m(s.defaultExcludes.join("\n")),f(""),W.success("已保存")}catch(t){W.error(`保存失败: ${t.message}`)}finally{l(!1)}}})()},disabled:a,children:[a?o.jsx(F,{className:"h-3.5 w-3.5 mr-1.5 animate-spin"}):o.jsx(xe,{className:"h-3.5 w-3.5 mr-1.5"}),"保存"]}),o.jsxs(R,{variant:"outline",onClick:()=>{(async()=>{c(!0);try{const e=await U();e.ok?W.success(e.message||"连接成功"):W.error(e.message||"连接失败")}catch(e){W.error(`测试失败: ${e.message}`)}finally{c(!1)}})()},disabled:i,children:[i?o.jsx(F,{className:"h-3.5 w-3.5 mr-1.5 animate-spin"}):o.jsx(Ee,{className:"h-3.5 w-3.5 mr-1.5"}),"测试连接"]}),o.jsx("div",{className:"flex-1"}),o.jsxs(R,{variant:"outline",onClick:()=>{(async()=>{u(!0);try{const e=await K(),t=e.results.filter(e=>e.ok).length,n=e.results.filter(e=>e.skipped).length,r=e.total-t-n;W.success(`同步完成:${t} 成功 / ${n} 跳过 / ${r} 失败`)}catch(e){W.error(`同步失败: ${e.message}`)}finally{u(!1)}})()},disabled:d,title:"按当前方向同步所有项目",children:[d?o.jsx(F,{className:"h-3.5 w-3.5 mr-1.5 animate-spin"}):o.jsx(ge,{className:"h-3.5 w-3.5 mr-1.5"}),"立即同步全部"]})]}),o.jsxs("div",{className:"border-t pt-4 text-xs text-muted-foreground",children:["一次性 push/pull 工具:进入项目内部,点击 header 的 ",o.jsx(ge,{className:"inline h-3 w-3"})," / ",o.jsx(B,{className:"inline h-3 w-3"})," 按钮。 或通过 API 调用 ",o.jsx("code",{children:"POST /api/sync/project/:id"})," with body ",o.jsx("code",{children:'{ "direction": "push" }'}),"。"]})]})}const Is=["node_modules",".git","dist","build","*.log",".DS_Store","*.tmp",".venv","__pycache__",".env"],Ls=[{value:"30",label:"30分钟"},{value:"60",label:"1小时"},{value:"360",label:"6小时"},{value:"720",label:"12小时"},{value:"1440",label:"24小时"}];function Hs(){const e=q(),[n,r]=t.useState([]),[s,a]=t.useState(!0),[l,i]=t.useState(!1),[c,d]=t.useState({enabled:!1,intervalMinutes:60}),[u,h]=t.useState(!0),[f,p]=t.useState([]),[m,x]=t.useState(!0),[g,y]=t.useState(""),[v,w]=t.useState(!1),[b,j]=t.useState(!1),[N,S]=t.useState([]),[C,k]=t.useState(!0),[D,T]=t.useState(()=>X()),[O,_]=t.useState(!1),[M,I]=t.useState({webhookEnabled:!1}),[L,z]=t.useState(""),[V,F]=t.useState(!1),[B,$]=t.useState(()=>Y(G.usageMonitorTool,"claude")),U=async()=>{try{const e=await oe();r(e)}catch{}finally{a(!1)}},K=async()=>{try{const e=await ie();S(e)}catch{}finally{k(!1)}};t.useEffect(()=>{U(),(async()=>{try{const e=await ae();d(e)}catch{}finally{h(!1)}})(),(async()=>{try{const e=await le();p(e.length>0?e:Is)}catch{p(Is)}finally{x(!1)}})(),K(),Z().then(e=>{I(e),z(e.webhookUrl??"")}).catch(()=>{})},[]);const fe=(e,t)=>{const n=parseInt(t,10);isNaN(n)||n<1||(T(t=>({...t,[e]:n})),_(!0))},pe=async e=>{try{await ce(e),r(t=>t.filter(t=>t.id!==e))}catch{}},me=async e=>{try{const{url:t}=await E(e);window.open(t,"_blank")}catch{}},ge=()=>{const e=g.trim();e&&!f.includes(e)&&(p(t=>[...t,e]),y(""),w(!0))};return o.jsx("div",{className:"min-h-screen bg-background",children:o.jsxs("div",{className:"max-w-4xl mx-auto p-6",children:[o.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[o.jsxs(R,{variant:"ghost",size:"sm",onClick:()=>e("/"),children:[o.jsx(Q,{className:"h-4 w-4 mr-1"}),"返回"]}),o.jsx("h1",{className:"text-2xl font-bold",children:"设置"})]}),o.jsxs(ye,{defaultValue:"providers",children:[o.jsxs(ve,{className:"mb-4",children:[o.jsxs(we,{value:"sync",children:[o.jsx(be,{className:"h-3.5 w-3.5 mr-1.5"}),"同步 (rsync)"]}),o.jsx(we,{value:"providers",children:"云盘账号"}),o.jsx(we,{value:"strategy",children:"备份策略"}),o.jsx(we,{value:"history",children:"备份记录"}),o.jsxs(we,{value:"notifications",children:[o.jsx(Re,{className:"h-3.5 w-3.5 mr-1.5"}),"通知"]}),o.jsxs(we,{value:"pomodoro",children:[o.jsx(J,{className:"h-3.5 w-3.5 mr-1.5"}),"番茄钟"]}),o.jsxs(we,{value:"usage",children:[o.jsx(Ce,{className:"h-3.5 w-3.5 mr-1.5"}),"用量监控"]})]}),o.jsx(je,{value:"sync",children:o.jsx(Ms,{})}),o.jsxs(je,{value:"providers",children:[o.jsxs("div",{className:"space-y-4",children:[o.jsx("div",{className:"flex justify-end",children:o.jsxs(R,{onClick:()=>i(!0),children:[o.jsx(ee,{className:"h-4 w-4 mr-1"}),"添加云盘"]})}),s?o.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"加载中..."}):0===n.length?o.jsx("p",{className:"text-sm text-muted-foreground text-center py-12",children:"暂无云盘账号,点击上方按钮添加"}):o.jsx("div",{className:"grid gap-4 sm:grid-cols-2",children:n.map(e=>o.jsx(Ts,{provider:e,onDelete:pe,onReauth:me},e.id))})]}),o.jsx(Ps,{open:l,onOpenChange:i,onAdded:()=>{U()}})]}),o.jsx(je,{value:"strategy",children:o.jsxs("div",{className:"space-y-8",children:[o.jsxs("div",{className:"space-y-4",children:[o.jsx("h3",{className:"text-lg font-medium",children:"排除规则"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"匹配这些模式的文件和目录将不会被备份"}),m?o.jsx("p",{className:"text-sm text-muted-foreground",children:"加载中..."}):o.jsxs(o.Fragment,{children:[o.jsx("div",{className:"flex flex-wrap gap-2",children:o.jsx(te,{children:f.map(e=>o.jsxs(ne.span,{layout:!0,initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.2},className:"inline-flex items-center gap-1 rounded-md bg-muted px-2.5 py-1 text-sm",children:[e,o.jsx("button",{onClick:()=>(e=>{p(t=>t.filter(t=>t!==e)),w(!0)})(e),className:"ml-0.5 rounded-sm hover:bg-muted-foreground/20 p-0.5",children:o.jsx(re,{className:"h-3 w-3"})})]},e))})}),o.jsxs("div",{className:"flex gap-2",children:[o.jsx(A,{placeholder:"输入排除模式,例如 *.log",value:g,onChange:e=>y(e.target.value),onKeyDown:e=>{"Enter"===e.key&&ge()},className:"max-w-xs"}),o.jsx(R,{variant:"outline",size:"sm",onClick:ge,children:"添加"})]}),v&&o.jsxs(R,{onClick:async()=>{j(!0);try{await de(f),w(!1)}catch{}finally{j(!1)}},disabled:b,children:[o.jsx(xe,{className:"h-4 w-4 mr-1"}),b?"保存中...":"保存"]})]})]}),o.jsxs("div",{className:"space-y-4",children:[o.jsx("h3",{className:"text-lg font-medium",children:"定时备份"}),u?o.jsx("p",{className:"text-sm text-muted-foreground",children:"加载中..."}):o.jsxs("div",{className:"space-y-4",children:[o.jsxs("div",{className:"flex items-center gap-3",children:[o.jsx(Xe,{checked:c.enabled,onCheckedChange:async e=>{const t=c;d({...c,enabled:e});try{await ue({enabled:e})}catch{d(t)}}}),o.jsx(P,{children:c.enabled?"已开启":"已关闭"})]}),o.jsxs("div",{className:"space-y-2",children:[o.jsx(P,{children:"备份间隔"}),o.jsxs(ws,{value:String(c.intervalMinutes),onValueChange:async e=>{const t=parseInt(e,10),n=c;d({...c,intervalMinutes:t});try{await ue({intervalMinutes:t})}catch{d(n)}},children:[o.jsx(js,{className:"w-48",children:o.jsx(bs,{})}),o.jsx(Cs,{children:Ls.map(e=>o.jsx(ks,{value:e.value,children:e.label},e.value))})]})]})]})]})]})}),o.jsx(je,{value:"history",children:o.jsxs("div",{className:"space-y-4",children:[o.jsx("div",{className:"flex justify-end",children:o.jsxs(R,{variant:"outline",size:"sm",onClick:()=>{k(!0),K()},children:[o.jsx(H,{className:"h-4 w-4 mr-1"}),"刷新"]})}),C?o.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"加载中..."}):o.jsx(_s,{history:N})]})}),o.jsx(je,{value:"notifications",children:o.jsxs("div",{className:"space-y-6",children:[o.jsxs("div",{className:"rounded-lg border border-border p-4 space-y-2",children:[o.jsx("h3",{className:"text-sm font-medium",children:"浏览器通知"}),o.jsx("p",{className:"text-xs text-muted-foreground",children:"当 Claude 完成任务时,浏览器将自动弹出通知。首次打开 Dashboard 时会请求通知权限。"})]}),o.jsxs("div",{className:"rounded-lg border border-border p-4 space-y-3",children:[o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-medium",children:"Webhook 通知"}),o.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Claude 完成任务时向指定 URL 发送 POST 请求(JSON: event, projectId, projectName, timestamp)"})]}),o.jsxs("div",{className:"space-y-1.5",children:[o.jsx(P,{className:"text-xs",children:"Webhook URL"}),o.jsxs("div",{className:"flex gap-2",children:[o.jsx(A,{placeholder:"https://hooks.slack.com/...",value:L,onChange:e=>z(e.target.value),className:"font-mono text-xs"}),o.jsx(R,{size:"sm",onClick:()=>{(async()=>{F(!0);try{const e=await he({webhookEnabled:L.trim().length>0,webhookUrl:L.trim()||void 0});I(e),W.success("Webhook 配置已保存")}catch{W.error("保存失败")}finally{F(!1)}})()},disabled:V,children:V?"保存中…":"保存"})]}),M.webhookEnabled&&M.webhookUrl&&o.jsxs("p",{className:"text-xs text-green-500",children:["已启用 → ",M.webhookUrl]})]})]})]})}),o.jsx(je,{value:"pomodoro",children:o.jsxs("div",{className:"space-y-6",children:[o.jsxs("div",{className:"rounded-lg border border-border p-4 space-y-4",children:[o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-medium",children:"番茄钟时间设置"}),o.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"修改后重新启动番茄钟生效"})]}),o.jsxs("div",{className:"grid grid-cols-2 gap-6 max-w-xs",children:[o.jsxs("div",{className:"space-y-1.5",children:[o.jsx(P,{className:"text-xs",children:"工作时长(分钟)"}),o.jsx(A,{type:"number",min:1,max:120,value:D.workMinutes,onChange:e=>fe("workMinutes",e.target.value),className:"w-full"})]}),o.jsxs("div",{className:"space-y-1.5",children:[o.jsx(P,{className:"text-xs",children:"休息时长(分钟)"}),o.jsx(A,{type:"number",min:1,max:60,value:D.breakMinutes,onChange:e=>fe("breakMinutes",e.target.value),className:"w-full"})]})]}),O&&o.jsxs(R,{size:"sm",onClick:()=>{se(G.pomodoroConfig,D,!0),_(!1),W.success("番茄钟设置已保存")},children:[o.jsx(xe,{className:"h-3.5 w-3.5 mr-1.5"}),"保存"]})]}),o.jsxs("div",{className:"rounded-lg border border-border p-4 space-y-2",children:[o.jsx("h3",{className:"text-sm font-medium",children:"使用说明"}),o.jsxs("ul",{className:"text-xs text-muted-foreground space-y-1 list-disc list-inside",children:[o.jsxs("li",{children:["在项目页面 Header 点击 ",o.jsx(J,{className:"h-3 w-3 inline-block mx-0.5"})," 图标启动番茄钟"]}),o.jsx("li",{children:"倒计时以大字体悬浮在屏幕上,不影响操作"}),o.jsx("li",{children:"工作阶段结束后自动切换为休息,并弹出通知"}),o.jsx("li",{children:"休息结束后自动切换回工作阶段"}),o.jsx("li",{children:"再次点击图标可停止并重置"})]})]})]})}),o.jsx(je,{value:"usage",children:o.jsxs("div",{className:"space-y-6",children:[o.jsxs("div",{className:"rounded-lg border border-border p-4 space-y-4",children:[o.jsxs("div",{children:[o.jsx("h3",{className:"text-sm font-medium",children:"监控工具"}),o.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"选择要监控用量的 CLI 工具,首页和项目页会显示对应的实时用量"})]}),o.jsx("div",{className:"grid gap-3 max-w-md",children:[{key:"claude",label:"Claude Code",desc:"Anthropic API — 5h/7d 用量窗口"},{key:"codex",label:"Codex",desc:"OpenAI — 用量查询暂未实现"},{key:"opencode",label:"OpenCode",desc:"OpenCode — 用量查询暂未实现"},{key:"qwen",label:"Qwen Code",desc:"Qwen — 用量查询暂未实现"},{key:"gemini",label:"Gemini CLI",desc:"Google — 用量查询暂未实现"}].map(e=>o.jsxs("label",{className:"flex items-start gap-3 rounded-lg border p-3 cursor-pointer transition-colors "+(B===e.key?"border-blue-500/50 bg-blue-500/5":"border-border hover:bg-muted/30"),children:[o.jsx("input",{type:"radio",name:"usageTool",value:e.key,checked:B===e.key,onChange:()=>{$(e.key),se(G.usageMonitorTool,e.key),window.dispatchEvent(new Event("ccweb:usage-tool-change")),W.success(`用量监控已切换为 ${e.label}`)},className:"mt-0.5"}),o.jsxs("div",{children:[o.jsx("div",{className:"text-sm font-medium",children:e.label}),o.jsx("div",{className:"text-xs text-muted-foreground",children:e.desc})]})]},e.key))})]}),o.jsxs("div",{className:"rounded-lg border border-border p-4 space-y-2",children:[o.jsx("h3",{className:"text-sm font-medium",children:"说明"}),o.jsxs("ul",{className:"text-xs text-muted-foreground space-y-1 list-disc list-inside",children:[o.jsx("li",{children:"用量数据显示在首页 Header 和项目页底部状态栏"}),o.jsx("li",{children:"Claude Code 通过 OAuth API 实时查询,每 5 分钟自动刷新"}),o.jsx("li",{children:"其他工具的用量查询将在后续版本中支持"}),o.jsx("li",{children:"切换后无需刷新页面,用量会自动更新"})]})]})]})})]})]})})}export{Hs as SettingsPage};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import{c as e,ad as s,r as t,bb as a,bc as r,t as l,bd as n,be as i,bf as d,j as c,B as o,ae as m,d as x,I as u,T as h,p,D as g,N as f,A as j,bg as b}from"./index-BFWZX3Hz.js";import{S as N}from"./search-CZ83atP-.js";import{C as y}from"./chevron-down-CyDTNuVw.js";
|
|
2
|
-
/**
|
|
3
|
-
* @license lucide-react v0.309.0 - ISC
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the ISC license.
|
|
6
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/const v=e("Power",[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]]),w=e("Puzzle",[["path",{d:"M19.439 7.85c-.049.322.059.648.289.878l1.568 1.568c.47.47.706 1.087.706 1.704s-.235 1.233-.706 1.704l-1.611 1.611a.98.98 0 0 1-.837.276c-.47-.07-.802-.48-.968-.925a2.501 2.501 0 1 0-3.214 3.214c.446.166.855.497.925.968a.979.979 0 0 1-.276.837l-1.61 1.61a2.404 2.404 0 0 1-1.705.707 2.402 2.402 0 0 1-1.704-.706l-1.568-1.568a1.026 1.026 0 0 0-.877-.29c-.493.074-.84.504-1.02.968a2.5 2.5 0 1 1-3.237-3.237c.464-.18.894-.527.967-1.02a1.026 1.026 0 0 0-.289-.877l-1.568-1.568A2.402 2.402 0 0 1 1.998 12c0-.617.236-1.234.706-1.704L4.23 8.77c.24-.24.581-.353.917-.303.515.077.877.528 1.073 1.01a2.5 2.5 0 1 0 3.259-3.259c-.482-.196-.933-.558-1.01-1.073-.05-.336.062-.676.303-.917l1.525-1.525A2.402 2.402 0 0 1 12 1.998c.617 0 1.234.236 1.704.706l1.568 1.568c.23.23.556.338.877.29.493-.074.84-.504 1.02-.968a2.5 2.5 0 1 1 3.237 3.237c-.464.18-.894.527-.967 1.02Z",key:"i0oyt7"}]]),k=e("Tag",[["path",{d:"M12 2H2v10l9.29 9.29c.94.94 2.48.94 3.42 0l6.58-6.58c.94-.94.94-2.48 0-3.42L12 2Z",key:"14b2ls"}],["path",{d:"M7 7h.01",key:"7u93v4"}]]),C=e("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);
|
|
8
|
-
/**
|
|
9
|
-
* @license lucide-react v0.309.0 - ISC
|
|
10
|
-
*
|
|
11
|
-
* This source code is licensed under the ISC license.
|
|
12
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
13
|
-
*/function S(){const e=s(),[S,_]=t.useState("skills"),[E,M]=t.useState([]),[z,L]=t.useState([]),[A,H]=t.useState(!1),[I,P]=t.useState(null);t.useEffect(()=>{"plugins"===S&&(H(!0),Promise.all([a().catch(()=>[]),fetch("/api/skillhub/plugins").then(e=>e.ok?e.json():[]).catch(()=>[])]).then(([e,s])=>{M(e),L(s)}).finally(()=>H(!1)))},[S]);const F=t.useCallback(async e=>{if(!I){P(e.id);try{await r(e.downloadUrl),l.success(`已安装 ${e.name}`);const s=await a().catch(()=>[]);M(s)}catch(s){l.error(s instanceof Error?s.message:"安装失败")}finally{P(null)}}},[I]),D=t.useCallback(async e=>{try{await n(e),M(s=>s.filter(s=>s.id!==e)),l.success("已卸载")}catch(s){l.error(s instanceof Error?s.message:"卸载失败")}},[]),O=t.useCallback(async(e,s)=>{try{await i(e,s),M(t=>t.map(t=>t.id===e?{...t,enabled:s}:t))}catch(t){l.error(t instanceof Error?t.message:"操作失败")}},[]),[T,U]=t.useState([]),[Z,$]=t.useState(!0),[B,q]=t.useState(null),[G,J]=t.useState(""),[K,Q]=t.useState(null),[R,V]=t.useState(null),[W,X]=t.useState(null),[Y,ee]=t.useState(new Set);t.useEffect(()=>{d().then(U).catch(e=>q(e instanceof Error?e.message:"Failed to load SkillHub")).finally(()=>$(!1))},[]);const se=t.useMemo(()=>{const e=new Set;return T.forEach(s=>{var t;return null==(t=s.tags)?void 0:t.forEach(s=>e.add(s))}),Array.from(e).sort()},[T]),te=t.useMemo(()=>T.some(e=>!e.tags||0===e.tags.length),[T]),ae=t.useMemo(()=>{let e=T;if("__untagged__"===K?e=e.filter(e=>!e.tags||0===e.tags.length):K&&(e=e.filter(e=>{var s;return null==(s=e.tags)?void 0:s.includes(K)})),G.trim()){const s=G.toLowerCase();e=e.filter(e=>{var t;return e.label.toLowerCase().includes(s)||e.description.toLowerCase().includes(s)||e.command.toLowerCase().includes(s)||e.author.toLowerCase().includes(s)||(null==(t=e.tags)?void 0:t.some(e=>e.toLowerCase().includes(s)))})}return e},[T,G,K]);return c.jsxs("div",{className:"min-h-screen bg-background",children:[c.jsx("header",{className:"border-b sticky top-0 bg-background z-10",children:c.jsxs("div",{className:"max-w-4xl mx-auto px-4 h-14 flex items-center gap-4",children:[c.jsxs(o,{variant:"ghost",size:"sm",onClick:()=>e("/"),children:[c.jsx(m,{className:"h-4 w-4 mr-1"}),"返回"]}),c.jsx("h1",{className:"font-semibold text-lg",children:"SkillHub"}),c.jsxs("div",{className:"flex items-center gap-1 ml-4",children:[c.jsx("button",{onClick:()=>_("skills"),className:x("px-3 py-1 rounded-md text-sm transition-colors","skills"===S?"bg-primary text-primary-foreground":"text-muted-foreground hover:bg-accent"),children:"技能"}),c.jsxs("button",{onClick:()=>_("plugins"),className:x("px-3 py-1 rounded-md text-sm transition-colors flex items-center gap-1","plugins"===S?"bg-primary text-primary-foreground":"text-muted-foreground hover:bg-accent"),children:[c.jsx(w,{className:"h-3.5 w-3.5"}),"插件"]})]}),c.jsx("div",{className:"flex-1"}),c.jsxs("div",{className:"relative w-64",children:[c.jsx(N,{className:"absolute left-2.5 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground"}),c.jsx(u,{placeholder:"搜索命令...",value:G,onChange:e=>J(e.target.value),className:"pl-8 h-9"})]})]})}),c.jsxs("main",{className:"max-w-4xl mx-auto px-4 py-6",children:["plugins"===S&&c.jsxs("div",{children:[A&&c.jsx("div",{className:"text-center text-muted-foreground py-20",children:"加载中..."}),!A&&c.jsxs(c.Fragment,{children:[E.length>0&&c.jsxs("div",{className:"mb-8",children:[c.jsx("h2",{className:"text-sm font-medium text-muted-foreground mb-3",children:"已安装"}),c.jsx("div",{className:"space-y-2",children:E.map(e=>c.jsxs("div",{className:"rounded-lg border bg-card p-4 flex items-center gap-4",children:[c.jsxs("div",{className:"flex-1 min-w-0",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("span",{className:"font-medium text-sm",children:e.name}),c.jsxs("span",{className:"text-xs text-muted-foreground",children:["v",e.version]}),c.jsx("span",{className:x("text-xs px-1.5 py-0.5 rounded",e.enabled?"bg-green-500/10 text-green-500":"bg-muted text-muted-foreground"),children:e.enabled?"启用":"禁用"})]}),c.jsx("p",{className:"text-xs text-muted-foreground mt-0.5 truncate",children:e.description}),e.permissions.length>0&&c.jsx("div",{className:"flex gap-1 mt-1 flex-wrap",children:e.permissions.map(e=>c.jsx("span",{className:"text-xs px-1.5 py-0.5 rounded bg-blue-500/10 text-blue-400",children:e},e))})]}),c.jsx(o,{size:"sm",variant:"ghost",onClick:()=>O(e.id,!e.enabled),title:e.enabled?"禁用":"启用",children:c.jsx(v,{className:x("h-4 w-4",e.enabled?"text-green-500":"text-muted-foreground")})}),c.jsx(o,{size:"sm",variant:"ghost",onClick:()=>D(e.id),title:"卸载",children:c.jsx(h,{className:"h-4 w-4 text-red-400"})})]},e.id))})]}),c.jsxs("div",{children:[c.jsx("h2",{className:"text-sm font-medium text-muted-foreground mb-3",children:E.length>0?"更多插件":"可用插件"}),0===z.length&&c.jsxs("div",{className:"text-center text-muted-foreground py-20",children:[c.jsx(w,{className:"h-10 w-10 mx-auto mb-3 opacity-30"}),c.jsx("p",{className:"text-sm",children:"插件中心暂无可用插件"})]}),c.jsx("div",{className:"space-y-2",children:z.filter(e=>!E.some(s=>s.id===e.id)).map((e,s)=>{const t=I===e.id;return c.jsxs(p.div,{initial:{opacity:0,y:12},animate:{opacity:1,y:0},transition:{duration:.25,delay:.03*s},className:"rounded-lg border bg-card p-4 flex items-center gap-4",children:[c.jsxs("div",{className:"flex-1 min-w-0",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("span",{className:"font-medium text-sm",children:e.name}),c.jsxs("span",{className:"text-xs text-muted-foreground",children:["v",e.version]}),c.jsxs("span",{className:"text-xs text-muted-foreground",children:["by ",e.author]})]}),c.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:e.description}),e.permissions.length>0&&c.jsx("div",{className:"flex gap-1 mt-1 flex-wrap",children:e.permissions.map(e=>c.jsx("span",{className:"text-xs px-1.5 py-0.5 rounded bg-blue-500/10 text-blue-400",children:e},e))})]}),c.jsxs(o,{size:"sm",disabled:t,onClick:()=>F(e),children:[c.jsx(g,{className:"h-3.5 w-3.5 mr-1"}),t?"安装中...":"安装"]})]},e.id)})})]})]})]}),"skills"===S&&c.jsxs(c.Fragment,{children:[se.length>0&&c.jsxs("div",{className:"flex flex-wrap gap-2 mb-6",children:[c.jsx("button",{className:x("px-3 py-1 rounded-full text-xs font-medium transition-colors",null===K?"bg-primary text-primary-foreground":"bg-muted text-muted-foreground hover:bg-accent"),onClick:()=>Q(null),children:"全部"}),se.map(e=>c.jsx("button",{className:x("px-3 py-1 rounded-full text-xs font-medium transition-colors",K===e?"bg-primary text-primary-foreground":"bg-muted text-muted-foreground hover:bg-accent"),onClick:()=>Q(K===e?null:e),children:e},e)),te&&c.jsx("button",{className:x("px-3 py-1 rounded-full text-xs font-medium transition-colors","__untagged__"===K?"bg-primary text-primary-foreground":"bg-muted text-muted-foreground hover:bg-accent"),onClick:()=>Q("__untagged__"===K?null:"__untagged__"),children:"无标签"})]}),Z&&c.jsx("div",{className:"text-center text-muted-foreground py-20",children:"加载中..."}),B&&c.jsx("div",{className:"text-center text-destructive py-20",children:B}),!Z&&!B&&0===T.length&&c.jsxs("div",{className:"text-center text-muted-foreground py-20",children:[c.jsx("p",{className:"text-lg mb-2",children:"SkillHub 还没有命令"}),c.jsx("p",{className:"text-sm",children:"在快捷命令面板中点击分享按钮来提交第一个命令吧!"})]}),!Z&&!B&&T.length>0&&0===ae.length&&c.jsx("div",{className:"text-center text-muted-foreground py-20",children:"没有匹配的命令"}),c.jsx("div",{className:"space-y-3",children:ae.map((e,s)=>{var t;const a=R===e.id,r=Y.has(e.id),n=W===e.id,i=e.parentId?T.find(s=>s.id===e.parentId):void 0;return c.jsxs(p.div,{layout:!0,initial:{opacity:0,y:12},animate:{opacity:1,y:0},transition:{duration:.25,delay:.03*s,ease:"easeOut"},className:"rounded-lg border bg-card p-4 cursor-pointer hover:border-muted-foreground/30 transition-colors",onClick:()=>V(a?null:e.id),children:[c.jsxs("div",{className:"flex items-start justify-between gap-4",children:[c.jsxs("div",{className:"flex-1 min-w-0",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("h3",{className:"font-medium text-sm truncate",children:e.label}),null==(t=e.tags)?void 0:t.map(e=>c.jsxs("span",{className:"inline-flex items-center gap-0.5 px-2 py-0.5 rounded-full text-xs bg-muted text-muted-foreground",children:[c.jsx(k,{className:"h-2.5 w-2.5"}),e]},e))]}),i&&c.jsxs("div",{className:"flex items-center gap-1 mt-1",children:[c.jsx(f,{className:"h-3 w-3 text-muted-foreground"}),c.jsxs("span",{className:"text-xs text-muted-foreground",children:["继承: ",i.label]})]}),e.description&&c.jsx("p",{className:"text-xs text-muted-foreground mt-1 truncate",children:e.description}),c.jsxs("div",{className:"flex items-center gap-3 mt-2 text-xs text-muted-foreground",children:[c.jsxs("span",{className:"flex items-center gap-1",children:[c.jsx(C,{className:"h-3 w-3"}),e.author]}),c.jsxs("span",{className:"flex items-center gap-1",children:[c.jsx(g,{className:"h-3 w-3"}),e.downloads||0]}),c.jsx("span",{children:e.createdAt})]})]}),c.jsxs("div",{className:"flex items-center gap-2 flex-shrink-0",children:[c.jsxs(o,{size:"sm",variant:r?"outline":"default",disabled:n||r,onClick:s=>(async(e,s)=>{if(s.stopPropagation(),!W&&!Y.has(e.id)){X(e.id);try{await b(e.id),ee(s=>new Set(s).add(e.id)),U(s=>s.map(s=>s.id===e.id?{...s,downloads:(s.downloads||0)+1}:s))}catch(t){l.error(t instanceof Error?t.message:"Download failed")}finally{X(null)}}})(e,s),title:i?`将同时下载继承的「${i.label}」`:void 0,children:[c.jsx(g,{className:"h-3.5 w-3.5 mr-1"}),r?"已下载":n?"下载中...":"下载"]}),c.jsx(p.span,{animate:{rotate:a?180:0},transition:{duration:.2},children:c.jsx(y,{className:"h-4 w-4 text-muted-foreground"})})]})]}),c.jsx(j,{children:a&&c.jsx(p.div,{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.2,ease:"easeInOut"},className:"overflow-hidden",children:c.jsx("div",{className:"mt-3 pt-3 border-t",children:c.jsx("pre",{className:"text-xs font-mono bg-muted rounded p-3 whitespace-pre-wrap break-words max-h-64 overflow-y-auto",children:e.command})})})})]},e.id)})})]})]})]})}export{S as SkillHubPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
*,:before,:after{--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: rgb(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: rgb(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: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;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;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}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,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color: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,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}:root{--background: 0 0% 100%;--foreground: 240 10% 3.9%;--card: 0 0% 100%;--card-foreground: 240 10% 3.9%;--popover: 0 0% 100%;--popover-foreground: 240 10% 3.9%;--primary: 240 5.9% 10%;--primary-foreground: 0 0% 98%;--secondary: 240 4.8% 95.9%;--secondary-foreground: 240 5.9% 10%;--muted: 240 4.8% 95.9%;--muted-foreground: 240 3.8% 46.1%;--accent: 240 4.8% 95.9%;--accent-foreground: 240 5.9% 10%;--destructive: 0 84.2% 60.2%;--destructive-foreground: 0 0% 98%;--border: 240 5.9% 90%;--input: 240 5.9% 90%;--ring: 240 5.9% 10%;--radius: .5rem;--chart-1: 12 76% 61%;--chart-2: 173 58% 39%;--chart-3: 197 37% 24%;--chart-4: 43 74% 66%;--chart-5: 27 87% 67%}.dark{--background: 240 10% 3.9%;--foreground: 0 0% 98%;--card: 240 10% 3.9%;--card-foreground: 0 0% 98%;--popover: 240 10% 3.9%;--popover-foreground: 0 0% 98%;--primary: 0 0% 98%;--primary-foreground: 240 5.9% 10%;--secondary: 240 3.7% 15.9%;--secondary-foreground: 0 0% 98%;--muted: 240 3.7% 15.9%;--muted-foreground: 240 5% 64.9%;--accent: 240 3.7% 15.9%;--accent-foreground: 0 0% 98%;--destructive: 0 62.8% 30.6%;--destructive-foreground: 0 0% 98%;--border: 240 3.7% 15.9%;--input: 240 3.7% 15.9%;--ring: 240 4.9% 83.9%;--chart-1: 220 70% 50%;--chart-2: 160 60% 45%;--chart-3: 30 80% 55%;--chart-4: 280 65% 60%;--chart-5: 340 75% 55%}*{border-color:hsl(var(--border))}body{background-color:hsl(var(--background));color:hsl(var(--foreground))}.container{width:100%;margin-right:auto;margin-left:auto;padding-right:2rem;padding-left:2rem}@media (min-width: 1400px){.container{max-width:1400px}}.prose{color:var(--tw-prose-body);max-width:65ch}.prose :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.prose :where(a):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}.prose :where(strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-bold);font-weight:600}.prose :where(a strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}.prose :where(ol[type=A]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=A s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=I]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type=I s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type="1"]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal}.prose :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{color:var(--tw-prose-bullets)}.prose :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}.prose :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}.prose :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-inline-start-width:.25rem;border-inline-start-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-inline-start:1em}.prose :where(blockquote p:first-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:open-quote}.prose :where(blockquote p:last-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:close-quote}.prose :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.prose :where(h1 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:900;color:inherit}.prose :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.prose :where(h2 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:800;color:inherit}.prose :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.prose :where(h3 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.prose :where(h4 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}.prose :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px var(--tw-prose-kbd-shadows),0 3px 0 var(--tw-prose-kbd-shadows);font-size:.875em;border-radius:.3125rem;padding-top:.1875em;padding-inline-end:.375em;padding-bottom:.1875em;padding-inline-start:.375em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:"`"}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:"`"}.prose :where(a code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h1 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.875em}.prose :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.9em}.prose :where(h4 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding-top:.8571429em;padding-inline-end:1.1428571em;padding-bottom:.8571429em;padding-inline-start:1.1428571em}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:none}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:none}.prose :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){width:100%;table-layout:auto;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.prose :where(thead):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}.prose :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}.prose :where(tbody tr):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}.prose :where(tbody tr:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:0}.prose :where(tbody td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:baseline}.prose :where(tfoot):not(:where([class~=not-prose],[class~=not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}.prose :where(tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:top}.prose :where(th,td):not(:where([class~=not-prose],[class~=not-prose] *)){text-align:start}.prose :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-kbd: #111827;--tw-prose-kbd-shadows: rgb(17 24 39 / 10%);--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: rgb(255 255 255 / 10%);--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}.prose :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;margin-bottom:.5em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}.prose :where(.prose>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(.prose>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(.prose>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;padding-inline-start:1.625em}.prose :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.5714286em;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}.prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(.prose>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(.prose>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.prose-sm{font-size:.875rem;line-height:1.7142857}.prose-sm :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.prose-sm :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}.prose-sm :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-inline-start:1.1111111em}.prose-sm :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}.prose-sm :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}.prose-sm :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}.prose-sm :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}.prose-sm :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-sm :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;border-radius:.3125rem;padding-top:.1428571em;padding-inline-end:.3571429em;padding-bottom:.1428571em;padding-inline-start:.3571429em}.prose-sm :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em}.prose-sm :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.9em}.prose-sm :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}.prose-sm :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}.prose-sm :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}.prose-sm :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}.prose-sm :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}.prose-sm :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}.prose-sm :where(.prose-sm>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.prose-sm :where(.prose-sm>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(.prose-sm>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}.prose-sm :where(.prose-sm>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(.prose-sm>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}.prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.prose-sm :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.prose-sm :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;padding-inline-start:1.5714286em}.prose-sm :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}.prose-sm :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.5}.prose-sm :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose-sm :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose-sm :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose-sm :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-sm :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}.prose-sm :where(.prose-sm>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(.prose-sm>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.visible{visibility:visible}.collapse{visibility:collapse}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.-bottom-0\.5{bottom:-.125rem}.bottom-0{bottom:0}.bottom-7{bottom:1.75rem}.left-0{left:0}.left-1\.5{left:.375rem}.left-1\/2{left:50%}.left-2{left:.5rem}.left-2\.5{left:.625rem}.left-\[50\%\]{left:50%}.right-0{right:0}.right-1{right:.25rem}.right-1\.5{right:.375rem}.right-2{right:.5rem}.right-2\.5{right:.625rem}.right-4{right:1rem}.top-0{top:0}.top-1{top:.25rem}.top-1\.5{top:.375rem}.top-1\/2{top:50%}.top-14{top:3.5rem}.top-2{top:.5rem}.top-2\.5{top:.625rem}.top-4{top:1rem}.top-\[50\%\]{top:50%}.top-full{top:100%}.z-10{z-index:10}.z-20{z-index:20}.z-40{z-index:40}.z-50{z-index:50}.-mx-1{margin-left:-.25rem;margin-right:-.25rem}.mx-0\.5{margin-left:.125rem;margin-right:.125rem}.mx-2{margin-left:.5rem;margin-right:.5rem}.mx-auto{margin-left:auto;margin-right:auto}.my-1{margin-top:.25rem;margin-bottom:.25rem}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.ml-0\.5{margin-left:.125rem}.ml-1{margin-left:.25rem}.ml-2{margin-left:.5rem}.ml-4{margin-left:1rem}.ml-auto{margin-left:auto}.mr-1{margin-right:.25rem}.mr-1\.5{margin-right:.375rem}.mr-2{margin-right:.5rem}.mr-auto{margin-right:auto}.mt-0{margin-top:0}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-10{margin-top:2.5rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.line-clamp-6{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:6}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.hidden{display:none}.h-1{height:.25rem}.h-1\.5{height:.375rem}.h-10{height:2.5rem}.h-11{height:2.75rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-2{height:.5rem}.h-2\.5{height:.625rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-4{height:1rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-64{height:16rem}.h-7{height:1.75rem}.h-8{height:2rem}.h-9{height:2.25rem}.h-\[1px\]{height:1px}.h-\[24px\]{height:24px}.h-\[60vh\]{height:60vh}.h-\[80vh\]{height:80vh}.h-\[var\(--radix-select-trigger-height\)\]{height:var(--radix-select-trigger-height)}.h-full{height:100%}.h-px{height:1px}.h-screen{height:100vh}.max-h-32{max-height:8rem}.max-h-40{max-height:10rem}.max-h-48{max-height:12rem}.max-h-64{max-height:16rem}.max-h-96{max-height:24rem}.max-h-\[200px\]{max-height:200px}.max-h-\[80vh\]{max-height:80vh}.max-h-\[85vh\]{max-height:85vh}.max-h-full{max-height:100%}.min-h-0{min-height:0px}.min-h-\[12px\]{min-height:12px}.min-h-\[200px\]{min-height:200px}.min-h-\[5\.25rem\]{min-height:5.25rem}.min-h-\[80px\]{min-height:80px}.min-h-full{min-height:100%}.min-h-screen{min-height:100vh}.w-1{width:.25rem}.w-1\.5{width:.375rem}.w-10{width:2.5rem}.w-12{width:3rem}.w-16{width:4rem}.w-2{width:.5rem}.w-2\.5{width:.625rem}.w-20{width:5rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-4{width:1rem}.w-44{width:11rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-64{width:16rem}.w-7{width:1.75rem}.w-72{width:18rem}.w-8{width:2rem}.w-\[1px\]{width:1px}.w-\[44px\]{width:44px}.w-\[700px\]{width:700px}.w-\[72vw\]{width:72vw}.w-auto{width:auto}.w-full{width:100%}.w-px{width:1px}.w-screen{width:100vw}.min-w-0{min-width:0px}.min-w-\[120px\]{min-width:120px}.min-w-\[140px\]{min-width:140px}.min-w-\[36px\]{min-width:36px}.min-w-\[80px\]{min-width:80px}.min-w-\[8rem\]{min-width:8rem}.min-w-\[var\(--radix-select-trigger-width\)\]{min-width:var(--radix-select-trigger-width)}.max-w-4xl{max-width:56rem}.max-w-6xl{max-width:72rem}.max-w-\[85\%\]{max-width:85%}.max-w-\[90\%\]{max-width:90%}.max-w-\[95vw\]{max-width:95vw}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-none{max-width:none}.max-w-sm{max-width:24rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.flex-shrink-0,.shrink-0{flex-shrink:0}.grow{flex-grow:1}.border-collapse{border-collapse:collapse}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-\[-50\%\]{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-\[-50\%\]{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rotate-90{--tw-rotate: -90deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate: 180deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-90{--tw-rotate: 90deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.scale-95{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-col-resize{cursor:col-resize}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-se-resize{cursor:se-resize}.touch-none{touch-action:none}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.select-text{-webkit-user-select:text;-moz-user-select:text;user-select:text}.resize-none{resize:none}.resize-y{resize:vertical}.resize{resize:both}.list-inside{list-style-position:inside}.list-disc{list-style-type:disc}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.items-baseline{align-items:baseline}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.gap-x-4{-moz-column-gap:1rem;column-gap:1rem}.gap-y-1{row-gap:.25rem}.space-y-0\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.125rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.125rem * var(--tw-space-y-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.space-y-5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.25rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.space-y-8>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(2rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(2rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.whitespace-pre{white-space:pre}.whitespace-pre-wrap{white-space:pre-wrap}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-\[inherit\]{border-radius:inherit}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-none{border-radius:0}.rounded-sm{border-radius:calc(var(--radius) - 4px)}.rounded-xl{border-radius:.75rem}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.rounded-bl-md{border-bottom-left-radius:calc(var(--radius) - 2px)}.rounded-bl-sm{border-bottom-left-radius:calc(var(--radius) - 4px)}.rounded-br-md{border-bottom-right-radius:calc(var(--radius) - 2px)}.rounded-br-sm{border-bottom-right-radius:calc(var(--radius) - 4px)}.border{border-width:1px}.border-0{border-width:0px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-b-0{border-bottom-width:0px}.border-l{border-left-width:1px}.border-t{border-top-width:1px}.border-dashed{border-style:dashed}.border-amber-500\/40{border-color:#f59e0b66}.border-black\/10{border-color:#0000001a}.border-blue-500{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity, 1))}.border-blue-500\/15{border-color:#3b82f626}.border-blue-500\/20{border-color:#3b82f633}.border-blue-500\/25{border-color:#3b82f640}.border-blue-500\/40{border-color:#3b82f666}.border-blue-500\/50{border-color:#3b82f680}.border-border{border-color:hsl(var(--border))}.border-border\/50{border-color:hsl(var(--border) / .5)}.border-destructive{border-color:hsl(var(--destructive))}.border-emerald-500\/40{border-color:#10b98166}.border-green-500\/20{border-color:#22c55e33}.border-input{border-color:hsl(var(--input))}.border-muted-foreground\/30{border-color:hsl(var(--muted-foreground) / .3)}.border-muted-foreground\/40{border-color:hsl(var(--muted-foreground) / .4)}.border-primary{border-color:hsl(var(--primary))}.border-red-500\/40{border-color:#ef444466}.border-red-500\/50{border-color:#ef444480}.border-transparent{border-color:transparent}.border-yellow-500\/20{border-color:#eab30833}.border-l-transparent{border-left-color:transparent}.border-t-transparent{border-top-color:transparent}.bg-accent\/30{background-color:hsl(var(--accent) / .3)}.bg-amber-500\/10{background-color:#f59e0b1a}.bg-background{background-color:hsl(var(--background))}.bg-background\/50{background-color:hsl(var(--background) / .5)}.bg-background\/55{background-color:hsl(var(--background) / .55)}.bg-background\/60{background-color:hsl(var(--background) / .6)}.bg-background\/95{background-color:hsl(var(--background) / .95)}.bg-black\/5{background-color:#0000000d}.bg-black\/60{background-color:#0009}.bg-black\/80{background-color:#000c}.bg-blue-100{--tw-bg-opacity: 1;background-color:rgb(219 234 254 / var(--tw-bg-opacity, 1))}.bg-blue-400{--tw-bg-opacity: 1;background-color:rgb(96 165 250 / var(--tw-bg-opacity, 1))}.bg-blue-500\/10{background-color:#3b82f61a}.bg-blue-500\/15{background-color:#3b82f626}.bg-blue-500\/20{background-color:#3b82f633}.bg-blue-500\/25{background-color:#3b82f640}.bg-blue-500\/5{background-color:#3b82f60d}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.bg-border{background-color:hsl(var(--border))}.bg-card{background-color:hsl(var(--card))}.bg-destructive{background-color:hsl(var(--destructive))}.bg-green-400\/5{background-color:#4ade800d}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity, 1))}.bg-green-500\/10{background-color:#22c55e1a}.bg-green-600{--tw-bg-opacity: 1;background-color:rgb(22 163 74 / var(--tw-bg-opacity, 1))}.bg-muted{background-color:hsl(var(--muted))}.bg-muted-foreground{background-color:hsl(var(--muted-foreground))}.bg-muted-foreground\/40{background-color:hsl(var(--muted-foreground) / .4)}.bg-muted\/20{background-color:hsl(var(--muted) / .2)}.bg-muted\/30{background-color:hsl(var(--muted) / .3)}.bg-muted\/50{background-color:hsl(var(--muted) / .5)}.bg-muted\/60{background-color:hsl(var(--muted) / .6)}.bg-popover{background-color:hsl(var(--popover))}.bg-primary{background-color:hsl(var(--primary))}.bg-primary\/40{background-color:hsl(var(--primary) / .4)}.bg-primary\/5{background-color:hsl(var(--primary) / .05)}.bg-purple-400{--tw-bg-opacity: 1;background-color:rgb(192 132 252 / var(--tw-bg-opacity, 1))}.bg-red-400\/5{background-color:#f871710d}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-500\/10{background-color:#ef44441a}.bg-red-500\/20{background-color:#ef444433}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.bg-secondary{background-color:hsl(var(--secondary))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-yellow-400{--tw-bg-opacity: 1;background-color:rgb(250 204 21 / var(--tw-bg-opacity, 1))}.bg-yellow-500{--tw-bg-opacity: 1;background-color:rgb(234 179 8 / var(--tw-bg-opacity, 1))}.bg-yellow-500\/10{background-color:#eab3081a}.bg-yellow-600{--tw-bg-opacity: 1;background-color:rgb(202 138 4 / var(--tw-bg-opacity, 1))}.bg-zinc-400{--tw-bg-opacity: 1;background-color:rgb(161 161 170 / var(--tw-bg-opacity, 1))}.fill-foreground{fill:hsl(var(--foreground))}.fill-muted-foreground\/60{fill:hsl(var(--muted-foreground) / .6)}.stroke-muted-foreground\/40{stroke:hsl(var(--muted-foreground) / .4)}.object-contain{-o-object-fit:contain;object-fit:contain}.p-0{padding:0}.p-0\.5{padding:.125rem}.p-1{padding:.25rem}.p-1\.5{padding:.375rem}.p-2{padding:.5rem}.p-2\.5{padding:.625rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.p-\[1px\]{padding:1px}.px-1{padding-left:.25rem;padding-right:.25rem}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.px-8{padding-left:2rem;padding-right:2rem}.py-0{padding-top:0;padding-bottom:0}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-20{padding-top:5rem;padding-bottom:5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-8{padding-top:2rem;padding-bottom:2rem}.py-\[3px\]{padding-top:3px;padding-bottom:3px}.py-px{padding-top:1px;padding-bottom:1px}.pb-0\.5{padding-bottom:.125rem}.pb-1{padding-bottom:.25rem}.pb-1\.5{padding-bottom:.375rem}.pb-2{padding-bottom:.5rem}.pb-3{padding-bottom:.75rem}.pb-\[env\(safe-area-inset-bottom\)\]{padding-bottom:env(safe-area-inset-bottom)}.pl-5{padding-left:1.25rem}.pl-8{padding-left:2rem}.pr-10{padding-right:2.5rem}.pr-14{padding-right:3.5rem}.pr-2{padding-right:.5rem}.pr-6{padding-right:1.5rem}.pr-7{padding-right:1.75rem}.pt-0{padding-top:0}.pt-1{padding-top:.25rem}.pt-2{padding-top:.5rem}.pt-3{padding-top:.75rem}.pt-4{padding-top:1rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\[10px\]{font-size:10px}.text-\[11px\]{font-size:11px}.text-\[9px\]{font-size:9px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.capitalize{text-transform:capitalize}.italic{font-style:italic}.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)}.leading-7{line-height:1.75rem}.leading-none{line-height:1}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-wider{letter-spacing:.05em}.tracking-widest{letter-spacing:.1em}.text-amber-500{--tw-text-opacity: 1;color:rgb(245 158 11 / var(--tw-text-opacity, 1))}.text-amber-700{--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity, 1))}.text-blue-300{--tw-text-opacity: 1;color:rgb(147 197 253 / var(--tw-text-opacity, 1))}.text-blue-400{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.text-blue-400\/80{color:#60a5facc}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.text-blue-900{--tw-text-opacity: 1;color:rgb(30 58 138 / var(--tw-text-opacity, 1))}.text-card-foreground{color:hsl(var(--card-foreground))}.text-destructive{color:hsl(var(--destructive))}.text-destructive-foreground{color:hsl(var(--destructive-foreground))}.text-emerald-400{--tw-text-opacity: 1;color:rgb(52 211 153 / var(--tw-text-opacity, 1))}.text-emerald-600{--tw-text-opacity: 1;color:rgb(5 150 105 / var(--tw-text-opacity, 1))}.text-foreground{color:hsl(var(--foreground))}.text-foreground\/90{color:hsl(var(--foreground) / .9)}.text-green-400{--tw-text-opacity: 1;color:rgb(74 222 128 / var(--tw-text-opacity, 1))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity, 1))}.text-green-600{--tw-text-opacity: 1;color:rgb(22 163 74 / var(--tw-text-opacity, 1))}.text-indigo-500{--tw-text-opacity: 1;color:rgb(99 102 241 / var(--tw-text-opacity, 1))}.text-inherit{color:inherit}.text-muted-foreground{color:hsl(var(--muted-foreground))}.text-muted-foreground\/30{color:hsl(var(--muted-foreground) / .3)}.text-muted-foreground\/40{color:hsl(var(--muted-foreground) / .4)}.text-muted-foreground\/50{color:hsl(var(--muted-foreground) / .5)}.text-muted-foreground\/60{color:hsl(var(--muted-foreground) / .6)}.text-muted-foreground\/70{color:hsl(var(--muted-foreground) / .7)}.text-muted-foreground\/80{color:hsl(var(--muted-foreground) / .8)}.text-orange-400{--tw-text-opacity: 1;color:rgb(251 146 60 / var(--tw-text-opacity, 1))}.text-popover-foreground{color:hsl(var(--popover-foreground))}.text-primary{color:hsl(var(--primary))}.text-primary-foreground{color:hsl(var(--primary-foreground))}.text-red-400{--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.text-red-400\/70{color:#f87171b3}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.text-secondary-foreground{color:hsl(var(--secondary-foreground))}.text-sky-400{--tw-text-opacity: 1;color:rgb(56 189 248 / var(--tw-text-opacity, 1))}.text-sky-500{--tw-text-opacity: 1;color:rgb(14 165 233 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-yellow-400{--tw-text-opacity: 1;color:rgb(250 204 21 / var(--tw-text-opacity, 1))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity, 1))}.text-yellow-600{--tw-text-opacity: 1;color:rgb(202 138 4 / var(--tw-text-opacity, 1))}.underline-offset-4{text-underline-offset:4px}.accent-primary{accent-color:hsl(var(--primary))}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-30{opacity:.3}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.outline{outline-style:solid}.ring{--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(3px + 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)}.ring-0{--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(0px + 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)}.ring-1{--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)}.ring-2{--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)}.ring-inset{--tw-ring-inset: inset}.ring-accent{--tw-ring-color: hsl(var(--accent))}.ring-blue-500\/50{--tw-ring-color: rgb(59 130 246 / .5)}.ring-green-500\/40{--tw-ring-color: rgb(34 197 94 / .4)}.ring-offset-background{--tw-ring-offset-color: hsl(var(--background))}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-md{--tw-backdrop-blur: blur(12px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:hsl(var(--border));border-radius:9999px;border:1px solid transparent;background-clip:content-box}::-webkit-scrollbar-thumb:hover{background:hsl(var(--muted-foreground) / .4);background-clip:content-box}::-webkit-scrollbar-corner{background:transparent}*{scrollbar-width:thin;scrollbar-color:hsl(var(--border)) transparent}@keyframes indeterminate{0%{transform:translate(-100%);width:40%}50%{transform:translate(100%);width:60%}to{transform:translate(-100%);width:40%}}@keyframes gradient-spin{0%{background-position:0% 50%}50%{background-position:100% 50%}to{background-position:0% 50%}}.card-active-glow{background:linear-gradient(270deg,#3b82f6,#8b5cf6,#ec4899,#f59e0b,#10b981,#3b82f6);background-size:400% 400%;animation:gradient-spin 2.5s ease infinite;padding:2px;border-radius:calc(var(--radius) + 2px)}.card-active-glow>*{background:linear-gradient(270deg,#dbeafe,#ede9fe,#fce7f3,#fef3c7,#d1fae5,#dbeafe);background-size:400% 400%;animation:gradient-spin 2.5s ease infinite;border-radius:var(--radius);overflow:hidden}.dark .card-active-glow>*{background:linear-gradient(270deg,#1e293b,#1e1b4b,#2d1b3d,#2d2305,#0d2818,#1e293b);background-size:400% 400%;animation:gradient-spin 2.5s ease infinite;border-radius:var(--radius);overflow:hidden}.dark\:prose-invert:is(.dark *){--tw-prose-body: var(--tw-prose-invert-body);--tw-prose-headings: var(--tw-prose-invert-headings);--tw-prose-lead: var(--tw-prose-invert-lead);--tw-prose-links: var(--tw-prose-invert-links);--tw-prose-bold: var(--tw-prose-invert-bold);--tw-prose-counters: var(--tw-prose-invert-counters);--tw-prose-bullets: var(--tw-prose-invert-bullets);--tw-prose-hr: var(--tw-prose-invert-hr);--tw-prose-quotes: var(--tw-prose-invert-quotes);--tw-prose-quote-borders: var(--tw-prose-invert-quote-borders);--tw-prose-captions: var(--tw-prose-invert-captions);--tw-prose-kbd: var(--tw-prose-invert-kbd);--tw-prose-kbd-shadows: var(--tw-prose-invert-kbd-shadows);--tw-prose-code: var(--tw-prose-invert-code);--tw-prose-pre-code: var(--tw-prose-invert-pre-code);--tw-prose-pre-bg: var(--tw-prose-invert-pre-bg);--tw-prose-th-borders: var(--tw-prose-invert-th-borders);--tw-prose-td-borders: var(--tw-prose-invert-td-borders)}.file\:border-0::file-selector-button{border-width:0px}.file\:bg-transparent::file-selector-button{background-color:transparent}.file\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\:font-medium::file-selector-button{font-weight:500}.placeholder\:text-muted-foreground::-moz-placeholder{color:hsl(var(--muted-foreground))}.placeholder\:text-muted-foreground::placeholder{color:hsl(var(--muted-foreground))}.placeholder\:text-muted-foreground\/40::-moz-placeholder{color:hsl(var(--muted-foreground) / .4)}.placeholder\:text-muted-foreground\/40::placeholder{color:hsl(var(--muted-foreground) / .4)}.placeholder\:text-muted-foreground\/50::-moz-placeholder{color:hsl(var(--muted-foreground) / .5)}.placeholder\:text-muted-foreground\/50::placeholder{color:hsl(var(--muted-foreground) / .5)}.last\:border-0:last-child{border-width:0px}.hover\:border-border\/80:hover{border-color:hsl(var(--border) / .8)}.hover\:border-muted-foreground\/30:hover{border-color:hsl(var(--muted-foreground) / .3)}.hover\:border-muted-foreground\/40:hover{border-color:hsl(var(--muted-foreground) / .4)}.hover\:border-transparent:hover{border-color:transparent}.hover\:border-zinc-400:hover{--tw-border-opacity: 1;border-color:rgb(161 161 170 / var(--tw-border-opacity, 1))}.hover\:bg-accent:hover{background-color:hsl(var(--accent))}.hover\:bg-black\/10:hover{background-color:#0000001a}.hover\:bg-blue-500:hover{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}.hover\:bg-blue-500\/15:hover{background-color:#3b82f626}.hover\:bg-blue-500\/20:hover{background-color:#3b82f633}.hover\:bg-blue-500\/60:hover{background-color:#3b82f699}.hover\:bg-destructive\/10:hover{background-color:hsl(var(--destructive) / .1)}.hover\:bg-destructive\/80:hover{background-color:hsl(var(--destructive) / .8)}.hover\:bg-destructive\/90:hover{background-color:hsl(var(--destructive) / .9)}.hover\:bg-emerald-500\/10:hover{background-color:#10b9811a}.hover\:bg-green-500\/20:hover{background-color:#22c55e33}.hover\:bg-green-700:hover{--tw-bg-opacity: 1;background-color:rgb(21 128 61 / var(--tw-bg-opacity, 1))}.hover\:bg-muted:hover{background-color:hsl(var(--muted))}.hover\:bg-muted-foreground\/20:hover{background-color:hsl(var(--muted-foreground) / .2)}.hover\:bg-muted\/30:hover{background-color:hsl(var(--muted) / .3)}.hover\:bg-muted\/50:hover{background-color:hsl(var(--muted) / .5)}.hover\:bg-muted\/80:hover{background-color:hsl(var(--muted) / .8)}.hover\:bg-primary\/80:hover{background-color:hsl(var(--primary) / .8)}.hover\:bg-primary\/90:hover{background-color:hsl(var(--primary) / .9)}.hover\:bg-red-500\/10:hover{background-color:#ef44441a}.hover\:bg-red-500\/20:hover{background-color:#ef444433}.hover\:bg-red-700:hover{--tw-bg-opacity: 1;background-color:rgb(185 28 28 / var(--tw-bg-opacity, 1))}.hover\:bg-secondary\/80:hover{background-color:hsl(var(--secondary) / .8)}.hover\:bg-white\/10:hover{background-color:#ffffff1a}.hover\:bg-yellow-700:hover{--tw-bg-opacity: 1;background-color:rgb(161 98 7 / var(--tw-bg-opacity, 1))}.hover\:text-accent-foreground:hover{color:hsl(var(--accent-foreground))}.hover\:text-blue-300:hover{--tw-text-opacity: 1;color:rgb(147 197 253 / var(--tw-text-opacity, 1))}.hover\:text-blue-400:hover{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.hover\:text-destructive:hover{color:hsl(var(--destructive))}.hover\:text-destructive-foreground:hover{color:hsl(var(--destructive-foreground))}.hover\:text-foreground:hover{color:hsl(var(--foreground))}.hover\:text-green-400:hover{--tw-text-opacity: 1;color:rgb(74 222 128 / var(--tw-text-opacity, 1))}.hover\:text-red-400:hover{--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:opacity-80:hover{opacity:.8}.hover\:shadow-md:hover{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus\:border-border:focus{border-color:hsl(var(--border))}.focus\:bg-accent:focus{background-color:hsl(var(--accent))}.focus\:bg-muted:focus{background-color:hsl(var(--muted))}.focus\:text-accent-foreground:focus{color:hsl(var(--accent-foreground))}.focus\:opacity-100:focus{opacity:1}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-1:focus{--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\:ring-2:focus{--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\:ring-ring:focus{--tw-ring-color: hsl(var(--ring))}.focus\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\:ring-0: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(0px + 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\: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\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--ring))}.focus-visible\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}.focus-visible\:ring-offset-background:focus-visible{--tw-ring-offset-color: hsl(var(--background))}.active\:cursor-grabbing:active{cursor:grabbing}.active\:bg-accent:active{background-color:hsl(var(--accent))}.active\:bg-blue-500\/10:active{background-color:#3b82f61a}.active\:bg-blue-500\/80:active{background-color:#3b82f6cc}.active\:text-blue-400:active{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.active\:text-foreground:active{color:hsl(var(--foreground))}.disabled\:pointer-events-none:disabled{pointer-events:none}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-30:disabled{opacity:.3}.disabled\:opacity-50:disabled{opacity:.5}.group:hover .group-hover\:opacity-100{opacity:1}.peer:disabled~.peer-disabled\:cursor-not-allowed{cursor:not-allowed}.peer:disabled~.peer-disabled\:opacity-70{opacity:.7}.data-\[disabled\]\:pointer-events-none[data-disabled]{pointer-events:none}.data-\[state\=inactive\]\:hidden[data-state=inactive]{display:none}.data-\[side\=bottom\]\:translate-y-1[data-side=bottom]{--tw-translate-y: .25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\[side\=left\]\:-translate-x-1[data-side=left]{--tw-translate-x: -.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\[side\=right\]\:translate-x-1[data-side=right]{--tw-translate-x: .25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\[side\=top\]\:-translate-y-1[data-side=top]{--tw-translate-y: -.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\[state\=checked\]\:translate-x-5[data-state=checked]{--tw-translate-x: 1.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\[state\=unchecked\]\:translate-x-0[data-state=unchecked]{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\[state\=active\]\:bg-background[data-state=active]{background-color:hsl(var(--background))}.data-\[state\=checked\]\:bg-primary[data-state=checked]{background-color:hsl(var(--primary))}.data-\[state\=open\]\:bg-accent[data-state=open]{background-color:hsl(var(--accent))}.data-\[state\=unchecked\]\:bg-input[data-state=unchecked]{background-color:hsl(var(--input))}.data-\[state\=active\]\:text-foreground[data-state=active]{color:hsl(var(--foreground))}.data-\[state\=open\]\:text-muted-foreground[data-state=open]{color:hsl(var(--muted-foreground))}.data-\[disabled\]\:opacity-50[data-disabled]{opacity:.5}.data-\[state\=active\]\:shadow-sm[data-state=active]{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.prose-code\:text-foreground :is(:where(code):not(:where([class~=not-prose],[class~=not-prose] *))){color:hsl(var(--foreground))}.prose-pre\:border :is(:where(pre):not(:where([class~=not-prose],[class~=not-prose] *))){border-width:1px}.prose-pre\:border-border :is(:where(pre):not(:where([class~=not-prose],[class~=not-prose] *))){border-color:hsl(var(--border))}.prose-pre\:bg-muted :is(:where(pre):not(:where([class~=not-prose],[class~=not-prose] *))){background-color:hsl(var(--muted))}.dark\:border-blue-500\/25:is(.dark *){border-color:#3b82f640}.dark\:border-white\/15:is(.dark *){border-color:#ffffff26}.dark\:bg-blue-500\/20:is(.dark *){background-color:#3b82f633}.dark\:bg-blue-600:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.dark\:bg-white\/10:is(.dark *){background-color:#ffffff1a}.dark\:text-amber-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 211 77 / var(--tw-text-opacity, 1))}.dark\:text-blue-300:is(.dark *){--tw-text-opacity: 1;color:rgb(147 197 253 / var(--tw-text-opacity, 1))}.dark\:text-emerald-400:is(.dark *){--tw-text-opacity: 1;color:rgb(52 211 153 / var(--tw-text-opacity, 1))}.dark\:text-red-400:is(.dark *){--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.dark\:text-white:is(.dark *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.dark\:hover\:bg-white\/20:hover:is(.dark *){background-color:#fff3}@media (min-width: 640px){.sm\:inline{display:inline}.sm\:max-w-2xl{max-width:42rem}.sm\:max-w-lg{max-width:32rem}.sm\:max-w-md{max-width:28rem}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:flex-row{flex-direction:row}.sm\:justify-end{justify-content:flex-end}.sm\:justify-between{justify-content:space-between}.sm\:space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.sm\:rounded-lg{border-radius:var(--radius)}.sm\:text-left{text-align:left}}@media (min-width: 768px){.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width: 1024px){.lg\:block{display:block}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}}.\[\&\>div\]\:\!block>div{display:block!important}.\[\&\>div\]\:\!w-full>div{width:100%!important}.\[\&\>span\]\:line-clamp-1>span{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.\[\&_a\]\:text-blue-400 a{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.\[\&_code\]\:rounded code{border-radius:.25rem}.\[\&_code\]\:px-1 code{padding-left:.25rem;padding-right:.25rem}.\[\&_code\]\:text-xs code{font-size:.75rem;line-height:1rem}.\[\&_h1\]\:text-base h1{font-size:1rem;line-height:1.5rem}.\[\&_h2\]\:text-sm h2,.\[\&_h3\]\:text-sm h3{font-size:.875rem;line-height:1.25rem}.\[\&_hr\]\:my-2 hr{margin-top:.5rem;margin-bottom:.5rem}.\[\&_ol\]\:my-1 ol,.\[\&_p\]\:my-1 p,.\[\&_pre\]\:my-1 pre{margin-top:.25rem;margin-bottom:.25rem}.\[\&_pre\]\:max-w-full pre{max-width:100%}.\[\&_pre\]\:overflow-x-auto pre{overflow-x:auto}.\[\&_pre\]\:rounded pre{border-radius:.25rem}.\[\&_pre\]\:p-2 pre{padding:.5rem}.\[\&_pre\]\:text-xs pre,.\[\&_table\]\:text-xs table{font-size:.75rem;line-height:1rem}.\[\&_ul\]\:my-1 ul{margin-top:.25rem;margin-bottom:.25rem}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import{c as e,r as t,j as n,aJ as r,as as o,R as a,ap as i,aK as s,aq as l,at as c,aH as u,au as d,ar as f,d as p}from"./index-BFWZX3Hz.js";
|
|
2
|
-
/**
|
|
3
|
-
* @license lucide-react v0.309.0 - ISC
|
|
4
|
-
*
|
|
5
|
-
* This source code is licensed under the ISC license.
|
|
6
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/const m=e("Save",[["path",{d:"M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z",key:"1owoqh"}],["polyline",{points:"17 21 17 13 7 13 7 21",key:"1md35c"}],["polyline",{points:"7 3 7 8 15 8",key:"8nz8an"}]]),v=e("UploadCloud",[["path",{d:"M4 14.899A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.5 8.242",key:"1pljnt"}],["path",{d:"M12 12v9",key:"192myk"}],["path",{d:"m16 16-4-4-4 4",key:"119tzi"}]]),b=e("Upload",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"17 8 12 3 7 8",key:"t8dd8p"}],["line",{x1:"12",x2:"12",y1:"3",y2:"15",key:"widbto"}]]);
|
|
8
|
-
/**
|
|
9
|
-
* @license lucide-react v0.309.0 - ISC
|
|
10
|
-
*
|
|
11
|
-
* This source code is licensed under the ISC license.
|
|
12
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
13
|
-
*/function y(e){const r=h(e),o=t.forwardRef((e,o)=>{const{children:a,...i}=e,s=t.Children.toArray(a),l=s.find(w);if(l){const e=l.props.children,a=s.map(n=>n===l?t.Children.count(e)>1?t.Children.only(null):t.isValidElement(e)?e.props.children:null:n);return n.jsx(r,{...i,ref:o,children:t.isValidElement(e)?t.cloneElement(e,void 0,a):null})}return n.jsx(r,{...i,ref:o,children:a})});return o.displayName=`${e}.Slot`,o}function h(e){const n=t.forwardRef((e,n)=>{const{children:o,...a}=e;if(t.isValidElement(o)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;if(o)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o)return e.props.ref;return e.props.ref||e.ref}(o),i=function(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{const t=a(...e);return o(...e),t}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}(a,o.props);return o.type!==t.Fragment&&(i.ref=n?r(n,e):e),t.cloneElement(o,i)}return t.Children.count(o)>1?t.Children.only(null):null});return n.displayName=`${e}.SlotClone`,n}var g=Symbol("radix.slottable");function w(e){return t.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===g}function x(e){const t=e+"CollectionProvider",[r,s]=o(t),[l,c]=r(t,{collectionRef:{current:null},itemMap:new Map}),u=e=>{const{scope:t,children:r}=e,o=a.useRef(null),i=a.useRef(new Map).current;return n.jsx(l,{scope:t,itemMap:i,collectionRef:o,children:r})};u.displayName=t;const d=e+"CollectionSlot",f=y(d),p=a.forwardRef((e,t)=>{const{scope:r,children:o}=e,a=c(d,r),s=i(t,a.collectionRef);return n.jsx(f,{ref:s,children:o})});p.displayName=d;const m=e+"CollectionItemSlot",v="data-radix-collection-item",b=y(m),h=a.forwardRef((e,t)=>{const{scope:r,children:o,...s}=e,l=a.useRef(null),u=i(t,l),d=c(m,r);return a.useEffect(()=>(d.itemMap.set(l,{ref:l,...s}),()=>{d.itemMap.delete(l)})),n.jsx(b,{[v]:"",ref:u,children:o})});return h.displayName=m,[{Provider:u,Slot:p,ItemSlot:h},function(t){const n=c(e+"CollectionConsumer",t);return a.useCallback(()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${v}]`));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])},s]}var R=t.createContext(void 0);function C(e){const n=t.useContext(R);return e||n||"ltr"}var j="rovingFocusGroup.onEntryFocus",I={bubbles:!1,cancelable:!0},S="RovingFocusGroup",[F,T,M]=x(S),[N,A]=o(S,[M]),[k,E]=N(S),_=t.forwardRef((e,t)=>n.jsx(F.Provider,{scope:e.__scopeRovingFocusGroup,children:n.jsx(F.Slot,{scope:e.__scopeRovingFocusGroup,children:n.jsx(D,{...e,ref:t})})}));_.displayName=S;var D=t.forwardRef((e,r)=>{const{__scopeRovingFocusGroup:o,orientation:a,loop:s=!1,dir:f,currentTabStopId:p,defaultCurrentTabStopId:m,onCurrentTabStopIdChange:v,onEntryFocus:b,preventScrollOnEntryFocus:y=!1,...h}=e,g=t.useRef(null),w=i(r,g),x=C(f),[R,F]=u({prop:p,defaultProp:m??null,onChange:v,caller:S}),[M,N]=t.useState(!1),A=d(b),E=T(o),_=t.useRef(!1),[D,K]=t.useState(0);return t.useEffect(()=>{const e=g.current;if(e)return e.addEventListener(j,A),()=>e.removeEventListener(j,A)},[A]),n.jsx(k,{scope:o,orientation:a,dir:x,loop:s,currentTabStopId:R,onItemFocus:t.useCallback(e=>F(e),[F]),onItemShiftTab:t.useCallback(()=>N(!0),[]),onFocusableItemAdd:t.useCallback(()=>K(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>K(e=>e-1),[]),children:n.jsx(l.div,{tabIndex:M||0===D?-1:0,"data-orientation":a,...h,ref:w,style:{outline:"none",...e.style},onMouseDown:c(e.onMouseDown,()=>{_.current=!0}),onFocus:c(e.onFocus,e=>{const t=!_.current;if(e.target===e.currentTarget&&t&&!M){const t=new CustomEvent(j,I);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){const e=E().filter(e=>e.focusable);O([e.find(e=>e.active),e.find(e=>e.id===R),...e].filter(Boolean).map(e=>e.ref.current),y)}}_.current=!1}),onBlur:c(e.onBlur,()=>N(!1))})})}),K="RovingFocusGroupItem",V=t.forwardRef((e,r)=>{const{__scopeRovingFocusGroup:o,focusable:a=!0,active:i=!1,tabStopId:u,children:d,...f}=e,p=s(),m=u||p,v=E(K,o),b=v.currentTabStopId===m,y=T(o),{onFocusableItemAdd:h,onFocusableItemRemove:g,currentTabStopId:w}=v;return t.useEffect(()=>{if(a)return h(),()=>g()},[a,h,g]),n.jsx(F.ItemSlot,{scope:o,id:m,focusable:a,active:i,children:n.jsx(l.span,{tabIndex:b?0:-1,"data-orientation":v.orientation,...f,ref:r,onMouseDown:c(e.onMouseDown,e=>{a?v.onItemFocus(m):e.preventDefault()}),onFocus:c(e.onFocus,()=>v.onItemFocus(m)),onKeyDown:c(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void v.onItemShiftTab();if(e.target!==e.currentTarget)return;const t=function(e,t,n){const r=function(e,t){return"rtl"!==t?e:"ArrowLeft"===e?"ArrowRight":"ArrowRight"===e?"ArrowLeft":e}(e.key,n);return"vertical"===t&&["ArrowLeft","ArrowRight"].includes(r)||"horizontal"===t&&["ArrowUp","ArrowDown"].includes(r)?void 0:P[r]}(e,v.orientation,v.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let o=y().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)o.reverse();else if("prev"===t||"next"===t){"prev"===t&&o.reverse();const a=o.indexOf(e.currentTarget);o=v.loop?(r=a+1,(n=o).map((e,t)=>n[(r+t)%n.length])):o.slice(a+1)}setTimeout(()=>O(o))}var n,r}),children:"function"==typeof d?d({isCurrentTabStop:b,hasTabStop:null!=w}):d})})});V.displayName=K;var P={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function O(e,t=!1){const n=document.activeElement;for(const r of e){if(r===n)return;if(r.focus({preventScroll:t}),document.activeElement!==n)return}}var G=_,L=V,$="Tabs",[U]=o($,[A]),z=A(),[q,B]=U($),H=t.forwardRef((e,t)=>{const{__scopeTabs:r,value:o,onValueChange:a,defaultValue:i,orientation:c="horizontal",dir:d,activationMode:f="automatic",...p}=e,m=C(d),[v,b]=u({prop:o,onChange:a,defaultProp:i??"",caller:$});return n.jsx(q,{scope:r,baseId:s(),value:v,onValueChange:b,orientation:c,dir:m,activationMode:f,children:n.jsx(l.div,{dir:m,"data-orientation":c,...p,ref:t})})});H.displayName=$;var W="TabsList",J=t.forwardRef((e,t)=>{const{__scopeTabs:r,loop:o=!0,...a}=e,i=B(W,r),s=z(r);return n.jsx(G,{asChild:!0,...s,orientation:i.orientation,dir:i.dir,loop:o,children:n.jsx(l.div,{role:"tablist","aria-orientation":i.orientation,...a,ref:t})})});J.displayName=W;var Z="TabsTrigger",Q=t.forwardRef((e,t)=>{const{__scopeTabs:r,value:o,disabled:a=!1,...i}=e,s=B(Z,r),u=z(r),d=ee(s.baseId,o),f=te(s.baseId,o),p=o===s.value;return n.jsx(L,{asChild:!0,...u,focusable:!a,active:p,children:n.jsx(l.button,{type:"button",role:"tab","aria-selected":p,"aria-controls":f,"data-state":p?"active":"inactive","data-disabled":a?"":void 0,disabled:a,id:d,...i,ref:t,onMouseDown:c(e.onMouseDown,e=>{a||0!==e.button||!1!==e.ctrlKey?e.preventDefault():s.onValueChange(o)}),onKeyDown:c(e.onKeyDown,e=>{[" ","Enter"].includes(e.key)&&s.onValueChange(o)}),onFocus:c(e.onFocus,()=>{const e="manual"!==s.activationMode;p||a||!e||s.onValueChange(o)})})})});Q.displayName=Z;var X="TabsContent",Y=t.forwardRef((e,r)=>{const{__scopeTabs:o,value:a,forceMount:i,children:s,...c}=e,u=B(X,o),d=ee(u.baseId,a),p=te(u.baseId,a),m=a===u.value,v=t.useRef(m);return t.useEffect(()=>{const e=requestAnimationFrame(()=>v.current=!1);return()=>cancelAnimationFrame(e)},[]),n.jsx(f,{present:i||m,children:({present:t})=>n.jsx(l.div,{"data-state":m?"active":"inactive","data-orientation":u.orientation,role:"tabpanel","aria-labelledby":d,hidden:!t,id:p,tabIndex:0,...c,ref:r,style:{...e.style,animationDuration:v.current?"0s":void 0},children:t&&s})})});function ee(e,t){return`${e}-trigger-${t}`}function te(e,t){return`${e}-content-${t}`}Y.displayName=X;var ne=J,re=Q,oe=Y;const ae=H,ie=t.forwardRef(({className:e,...t},r)=>n.jsx(ne,{ref:r,className:p("inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",e),...t}));ie.displayName=ne.displayName;const se=t.forwardRef(({className:e,...t},r)=>n.jsx(re,{ref:r,className:p("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",e),...t}));se.displayName=re.displayName;const le=t.forwardRef(({className:e,...t},r)=>n.jsx(oe,{ref:r,className:p("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));function ce(e,[t,n]){return Math.min(n,Math.max(t,e))}le.displayName=oe.displayName;export{m as S,ae as T,b as U,ie as a,se as b,le as c,v as d,ce as e,x as f,C as u};
|