@shawnstack/quickforge 1.6.12 → 1.7.0
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/dist/assets/AgentProfilesPage-DQ8URegq.js +1 -0
- package/dist/assets/ChatPanelHost-vi1tDqlJ.js +291 -0
- package/dist/assets/{PluginsPage-qXTjDrpd.js → PluginsPage-B8bHMwfv.js} +1 -1
- package/dist/assets/ScheduledTasksPage-AaUz5el2.js +2 -0
- package/dist/assets/{SettingsWorkspacePage-CnFDmGvW.js → SettingsWorkspacePage-BOP9CtoI.js} +112 -105
- package/dist/assets/{SharedConversationPage-CkQ-XwYS.js → SharedConversationPage-9A4L9UcQ.js} +1 -1
- package/dist/assets/TerminalDock-DQOXpaDe.js +2 -0
- package/dist/assets/WorkspaceInspector-DaM7TJHb.js +13 -0
- package/dist/assets/icons-ko_i0WpN.js +1 -0
- package/dist/assets/index-B2eauKpo.css +3 -0
- package/dist/assets/index-B8Awq5FV.js +63 -0
- package/dist/assets/{mcp-servers-dialog-CsRQxx7A.js → mcp-servers-dialog-XE4K8PCO.js} +2 -2
- package/dist/assets/{monaco-CdOyGlWD.js → monaco-C13M09wD.js} +1 -1
- package/dist/assets/{react-vendor-VqdnQHHS.js → react-vendor-2RKYr-A4.js} +1 -1
- package/dist/assets/{skills-dialog-CmVLi_h6.js → skills-dialog-MpoxntiV.js} +1 -1
- package/dist/index.html +6 -6
- package/dist/licenses/material-icon-theme.txt +8 -0
- package/package.json +1 -1
- package/server/agent-manager.mjs +182 -39
- package/server/auto-archive.mjs +137 -0
- package/server/auto-compaction.mjs +15 -18
- package/server/conversation-compaction.mjs +69 -3
- package/server/custom-commands.mjs +17 -0
- package/server/image-generation.mjs +130 -0
- package/server/index.mjs +12 -1
- package/server/provider-config.mjs +78 -0
- package/server/routes/agent.mjs +9 -0
- package/server/routes/session-assets.mjs +49 -0
- package/server/routes/shared-conversation.mjs +10 -0
- package/server/routes/storage.mjs +4 -0
- package/server/routes/tools.mjs +1 -1
- package/server/routes/workspace.mjs +5 -2
- package/server/session-assets.mjs +134 -0
- package/server/session-persistence-lock.mjs +9 -0
- package/server/storage.mjs +24 -1
- package/server/tools/definitions.mjs +10 -0
- package/server/tools/index.mjs +2 -0
- package/dist/assets/AgentProfilesPage-CooGLweI.js +0 -1
- package/dist/assets/ChatPanelHost-TEbv0lnL.js +0 -260
- package/dist/assets/ScheduledTasksPage-BBor8Yb2.js +0 -2
- package/dist/assets/TerminalDock-CvqBBMPg.js +0 -2
- package/dist/assets/WorkspaceInspector-6JGc6VGb.js +0 -13
- package/dist/assets/icons-C7j5jdKo.js +0 -1
- package/dist/assets/index-DxNzlPmc.js +0 -63
- package/dist/assets/index-HVxfqXfB.css +0 -3
package/dist/assets/{SharedConversationPage-CkQ-XwYS.js → SharedConversationPage-9A4L9UcQ.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-DWdDZTNf.js";import{Vt as t,ht as n,i as r}from"./icons-C7j5jdKo.js";import{n as i}from"./react-vendor-VqdnQHHS.js";import{S as a,b as o,d as s,f as c,p as l,u}from"./pi-web-ui-DoRGtREc.js";import{U as d}from"./pi-ai-Cr3rpCXT.js";import{t as f}from"./logger-B65Akg8A.js";import{G as p,J as m,K as h,Q as g,S as _,V as v,W as y,X as b,Y as x,c as S,dt as C,ht as w,l as T,s as E,st as D,ut as O}from"./index-DxNzlPmc.js";import{ChatPanelHost as k}from"./ChatPanelHost-TEbv0lnL.js";var A=e(t(),1),j=`quickforgeClientMessageId`;function M(e){let t=e?.metadata;return t&&typeof t==`object`&&!Array.isArray(t)?t:void 0}function N(e){let t=M(e)?.[j];return typeof t==`string`&&t?t:void 0}function P(){return`qfcm_${typeof crypto<`u`&&typeof crypto.randomUUID==`function`?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}`}function F(e){let t=N(e);if(t)return{message:e,clientMessageId:t};let n=P();return{message:{...e,metadata:{...M(e),[j]:n}},clientMessageId:n}}function I(e){return typeof e==`string`?e:Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.type===`text`).map(e=>e.text).filter(e=>typeof e==`string`).join(``):``}function L(e,t){if(!e||!t||e.role!==t.role)return!1;let n=N(e),r=N(t);return n&&r?n===r:I(e.content)===I(t.content)}async function R(e,t){let n=await fetch(e,{...t,cache:`no-store`,headers:{...t?.body?{"content-type":`application/json`}:void 0,...t?.headers}}),r=await n.json().catch(()=>null);if(!n.ok)throw Error(r?.error||`Request failed: ${n.status}`);return r}var z=class e{state;streamFn=d;getApiKey;sessionId;shareId;permission;listeners=new Set;eventSource=null;disposed=!1;reconnectTimer=null;reconnectDelay=1e3;baseUrl=``;syncingThinkingLevel=!1;planMode=!1;onPlanModeConsumed;constructor(e,t){this.shareId=e,this.sessionId=t.sessionId||t.id||e,this.permission=t.permission??`read`;let n={systemPrompt:t.systemPrompt??``,model:t.model??{provider:`shared`,id:`shared`},thinkingLevel:t.thinkingLevel??`off`,messages:t.messages?.slice()??[],tools:t.tools??[],isStreaming:!!t.isStreaming,streamingMessage:void 0,pendingToolCalls:new Set,errorMessage:t.errorMessage,contextCompaction:t.contextCompaction??null,contextUsage:t.contextUsage??null};this.state=new Proxy(n,{set:(e,t,n)=>{let r=e[t];return e[t]=n,t===`thinkingLevel`&&!this.syncingThinkingLevel&&n!==r&&this.updateThinkingLevel(n).catch(e=>{f.error(`Failed to update shared thinking level:`,e)}),!0}}),this.connectEvents()}subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}setNextPromptCapabilities(){}setPlanMode(e,t){this.planMode=e,this.onPlanModeConsumed=e?t:void 0}async prompt(e){if(this.disposed||this.permission!==`operate`)return;let{message:t,clientMessageId:n}=F(this.normalizeInput(e)),r=this.planMode?{type:`plan`}:void 0;if(this.planMode){this.planMode=!1;let e=this.onPlanModeConsumed;this.onPlanModeConsumed=void 0,e?.()}this.state.messages=[...this.state.messages,t],this.emit({type:`message_start`,message:t}),this.state.isStreaming||(this.state.isStreaming=!0,this.state.errorMessage=void 0,this.emit({type:`agent_start`}));try{await R(`/api/shared/${encodeURIComponent(this.shareId)}/message`,{method:`POST`,body:JSON.stringify({message:t,clientMessageId:n,command:r})})}catch(e){let t=e instanceof Error?e.message:String(e);throw this.state.errorMessage=t,this.state.isStreaming=!1,this.emit({type:`error`,error:t}),this.emit({type:`agent_end`,messages:this.state.messages}),e}}async updateModel(e){if(!(this.disposed||this.permission!==`operate`)){this.state.model=e;try{let t=await R(`/api/shared/${encodeURIComponent(this.shareId)}/model`,{method:`POST`,body:JSON.stringify({model:e})});t.model&&(this.state.model=t.model)}catch(e){let t=e instanceof Error?e.message:String(e);throw this.state.errorMessage=t,this.emit({type:`error`,error:t}),e}}}async updateThinkingLevel(e){if(!(this.disposed||this.permission!==`operate`)){!this.syncingThinkingLevel&&this.state.thinkingLevel!==e&&(this.state.thinkingLevel=e);try{let t=await R(`/api/shared/${encodeURIComponent(this.shareId)}/thinking-level`,{method:`POST`,body:JSON.stringify({thinkingLevel:e})});t.thinkingLevel&&(this.state.thinkingLevel=t.thinkingLevel)}catch(e){let t=e instanceof Error?e.message:String(e);throw this.state.errorMessage=t,this.emit({type:`error`,error:t}),e}}}abort(){this.permission===`operate`&&fetch(`/api/shared/${encodeURIComponent(this.shareId)}/abort`,{method:`POST`}).catch(e=>{f.error(`Failed to abort shared conversation:`,e)})}steer(){}followUp(){}reset(){this.state.messages=[],this.state.errorMessage=void 0,this.state.isStreaming=!1,this.state.streamingMessage=void 0,this.state.pendingToolCalls=new Set}async rollback(e){if(this.permission!==`operate`)return;let t=await R(`/api/shared/${encodeURIComponent(this.shareId)}/rollback`,{method:`POST`,body:JSON.stringify({messageIndex:e})});return this.applyState(t.session),this.emit({type:`messages_replaced`,messages:this.state.messages}),t}dispose(){this.disposed=!0,this.reconnectTimer&&clearTimeout(this.reconnectTimer),this.reconnectTimer=null,this.eventSource?.close(),this.eventSource=null,this.listeners.clear()}static async loadState(e){return R(`/api/shared/${encodeURIComponent(e)}/session`)}static async create(t){return new e(t,await e.loadState(t))}normalizeInput(e){return typeof e==`string`?{role:`user`,content:e,timestamp:Date.now()}:Array.isArray(e)?[...e].reverse().find(e=>e.role===`user`||e.role===`user-with-attachments`)??e[e.length-1]:e}connectEvents(){this.disposed||(this.eventSource?.close(),this.baseUrl=``,this.openEventSource())}openEventSource(){if(this.disposed)return;let e=`${this.baseUrl}/api/shared/${encodeURIComponent(this.shareId)}/events`;this.eventSource=new EventSource(e,{withCredentials:!0}),this.eventSource.onopen=()=>{this.reconnectDelay=1e3};let t=[`state`,`agent_start`,`agent_end`,`message_start`,`message_end`,`turn_start`,`turn_end`,`message_update`,`tool_execution_start`,`tool_execution_update`,`tool_execution_end`,`error`,`title_updated`,`messages_replaced`,`auto_compact_completed`],n=e=>t=>{try{let n=JSON.parse(t.data);this.handleEvent(e?{type:e,...n}:n)}catch{}};this.eventSource.onmessage=n();for(let e of t)this.eventSource.addEventListener(e,n(e));this.eventSource.onerror=()=>{this.eventSource?.close(),this.eventSource=null,this.scheduleReconnect()}}scheduleReconnect(){this.disposed||this.reconnectTimer||(this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.reconnectDelay=Math.min(this.reconnectDelay*2,3e4),this.openEventSource()},this.reconnectDelay))}handleEvent(e){if(e.type){switch(e.type){case`state`:this.applyState(e);break;case`agent_start`:this.state.isStreaming=!0,this.state.errorMessage=void 0;break;case`agent_end`:this.state.isStreaming=!1,this.state.streamingMessage=void 0;break;case`message_start`:if(e.message){let t=this.state.messages.findIndex(t=>L(t,e.message));if(t>=0){let n=this.state.messages.slice();n[t]=e.message,this.state.messages=n}else this.state.messages=[...this.state.messages,e.message];this.state.contextUsage=null}break;case`message_update`:e.message&&(this.state.streamingMessage=e.message);break;case`message_end`:e.message&&(this.state.messages=x(this.state.messages,e.message)),this.state.contextUsage=`contextUsage`in e?e.contextUsage:null,this.state.streamingMessage=void 0;break;case`messages_replaced`:e.messages&&(this.state.messages=e.messages,this.state.streamingMessage=void 0),`contextCompaction`in e&&(this.state.contextCompaction=e.contextCompaction),`contextUsage`in e&&(this.state.contextUsage=e.contextUsage);break;case`auto_compact_completed`:`contextCompaction`in e&&(this.state.contextCompaction=e.contextCompaction),`contextUsage`in e&&(this.state.contextUsage=e.contextUsage);break;case`tool_execution_start`:{let t=e;t.toolCallId&&(this.state.messages=b(this.state.messages,m(t),!0),this.state.pendingToolCalls=new Set([...this.state.pendingToolCalls,t.toolCallId]));break}case`tool_execution_update`:{let t=e;this.state.messages=b(this.state.messages,t,!0),t.toolCallId&&(this.state.pendingToolCalls=new Set([...this.state.pendingToolCalls,t.toolCallId]));break}case`tool_execution_end`:{let t=e;if(this.state.messages=b(this.state.messages,t,!1),t.toolCallId){let e=new Set(this.state.pendingToolCalls);e.delete(t.toolCallId),this.state.pendingToolCalls=e}break}case`error`:this.state.errorMessage=typeof e.error==`string`?e.error:`Unknown error`,this.state.isStreaming=!1;break}this.emit(e)}}applyState(e){this.sessionId=e.sessionId||e.id||this.sessionId,e.messages&&(this.state.messages=e.messages,this.state.contextUsage=e.contextUsage===void 0?null:e.contextUsage),e.systemPrompt!==void 0&&(this.state.systemPrompt=e.systemPrompt),e.model&&(this.state.model=e.model),e.thinkingLevel&&(this.syncingThinkingLevel=!0,this.state.thinkingLevel=e.thinkingLevel,this.syncingThinkingLevel=!1),e.tools&&(this.state.tools=e.tools),e.isStreaming!==void 0&&(this.state.isStreaming=!!e.isStreaming),e.errorMessage!==void 0&&(this.state.errorMessage=e.errorMessage),e.contextCompaction!==void 0&&(this.state.contextCompaction=e.contextCompaction),e.contextUsage!==void 0&&(this.state.contextUsage=e.contextUsage)}emit(e){for(let t of this.listeners)try{t(e)}catch{}}},B=i();function V(e){return{id:`shared-${e.provider}`,name:e.provider,type:e.api,baseUrl:e.baseUrl??``,models:[e]}}async function H(e,t){try{let t=await S(e);if(t.providers?.length)return t.providers}catch{}return t?[V(t)]:[]}function U(e,t){let n=t.model??{provider:`shared`,id:`shared`};return new z(e,{...t,model:n,thinkingLevel:t.thinkingLevel??g(n)})}function W(e,t){let n={settings:new u,providerKeys:new c,sessions:new s,customProviders:new l},r=new D(``,{blockedStores:[`sessions`,`provider-keys`],fakeProviderKeys:t?[t.provider]:void 0,storeOverrides:t?{"custom-providers":{keys:async()=>(await H(e,t)).map(e=>e.name),get:async n=>(await H(e,t)).find(e=>e.name===n)??null,has:async n=>(await H(e,t)).some(e=>e.name===n)}}:void 0});n.settings.setBackend(r),n.providerKeys.setBackend(r),n.sessions.setBackend(r),n.customProviders.setBackend(r),a(new o(n.settings,n.providerKeys,n.sessions,n.customProviders,r))}function G({shareId:e}){let[t,i]=(0,A.useState)(``),[a,o]=(0,A.useState)(null),[s,c]=(0,A.useState)(`read`),[l,u]=(0,A.useState)(`QuickForge 分享对话`),[d,m]=(0,A.useState)(),[g,b]=(0,A.useState)(!1),[x,S]=(0,A.useState)(),D=(0,A.useRef)(!1),j=s===`operate`,M=!!a,N=!!a?.state.tools?.length;(0,A.useEffect)(()=>{W(e,a?.state.model)},[a?.state.model,e]),(0,A.useEffect)(()=>()=>a?.dispose(),[a]);let P=(0,A.useCallback)(async(n=t.trim())=>{m(void 0),b(!0);try{let t=await T(e,n);c(t.permission),u(t.title||t.share.titleSnapshot||`QuickForge 分享对话`);let r=await z.loadState(e);W(e,r.model),o(U(e,r))}catch(e){m(e instanceof Error?e.message:`Failed to unlock shared conversation`)}finally{b(!1)}},[t,e]);(0,A.useEffect)(()=>{if(M||g||D.current)return;D.current=!0;let t=window.setTimeout(()=>{(async()=>{try{(await E(e)).share.hasPassword||await P(``)}catch(e){m(e instanceof Error?e.message:`Failed to load shared conversation`)}})()},0);return()=>window.clearTimeout(t)},[g,e,P,M]);let F=(0,A.useCallback)(async e=>{await y(e)},[]),I=(0,A.useCallback)(async()=>{if(!(!a||a.permission!==`operate`))try{let t=(await H(e,a.state.model)).flatMap(e=>e.models??[]);if(!t.length)return;_(a.state.model,t,t=>{!t.reasoning&&a.state.thinkingLevel!==`off`&&a.updateThinkingLevel(`off`).catch(e=>{f.error(`Failed to update shared thinking level:`,e)}),W(e,t),a.updateModel(t).catch(e=>{m(e instanceof Error?e.message:`Failed to update model`)})},void 0,{thinkingLevel:a.state.thinkingLevel,onThinkingLevelSelect:e=>{a.updateThinkingLevel(e).catch(e=>{f.error(`Failed to update shared thinking level:`,e),m(e instanceof Error?e.message:`Failed to update thinking level`)})}})}catch(e){m(e instanceof Error?e.message:`Failed to load models`)}},[a,e]),L=(0,A.useCallback)(e=>{S(t=>t?.id===e?void 0:t)},[]),R=(0,A.useCallback)(async e=>{if(!a||a.permission!==`operate`)return;if(m(void 0),a.state.isStreaming){v(w(`generationStillRunning`));return}let t=h(a.state.messages,e),n=t>=0?a.state.messages[t]:void 0;if(!n){v(w(`noConversationTurnToRollback`));return}try{await a.rollback(e),S({id:Date.now(),sessionId:a.sessionId,text:p(n),attachments:n.role===`user-with-attachments`?n.attachments:void 0})}catch(e){m(e instanceof Error?e.message:`Failed to roll back`)}},[a]);return M?(0,B.jsxs)(`div`,{className:`flex h-screen min-h-0 flex-col bg-background text-foreground`,children:[(0,B.jsx)(`header`,{className:C(`shrink-0 border-b px-4 py-3`,j?`border-red-300 bg-red-50 text-red-950`:`border-border bg-background`),children:(0,B.jsxs)(`div`,{className:`mx-auto flex max-w-4xl items-start gap-3`,children:[(0,B.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,B.jsx)(`div`,{className:`truncate text-sm font-semibold`,children:l}),(0,B.jsxs)(`div`,{className:`mt-1 flex flex-wrap items-center gap-x-2 gap-y-1 text-xs`,children:[(0,B.jsxs)(`span`,{className:C(`inline-flex items-center gap-1 rounded-full px-2 py-0.5 font-medium`,j?`bg-red-100 text-red-700`:`bg-muted text-muted-foreground`),children:[j?(0,B.jsx)(r,{className:`size-3.5`}):null,j?`高危可操作`:`只读分享`]}),(0,B.jsx)(`span`,{className:C(j?`text-red-800`:`text-muted-foreground`),children:j?`正在操作分享者的原始对话`:`只能查看,不能发送或修改`})]}),j?null:(0,B.jsx)(`div`,{className:`mt-1 text-xs leading-5 text-muted-foreground`,children:`界面与正常对话保持一致`})]}),(0,B.jsxs)(O,{variant:`ghost`,size:`sm`,className:C(`shrink-0`,j?`text-red-700 hover:bg-red-100 hover:text-red-800`:void 0),onClick:()=>void y(window.location.href),"aria-label":j?`复制高危分享链接`:`复制分享链接`,title:j?`复制高危分享链接`:`复制分享链接`,children:[(0,B.jsx)(n,{className:`size-4`}),(0,B.jsx)(`span`,{className:`hidden sm:inline`,children:j?`复制高危链接`:`复制链接`})]})]})}),d?(0,B.jsx)(`div`,{className:`mx-auto w-full max-w-4xl px-4 py-2 text-sm text-destructive`,children:d}):null,(0,B.jsx)(k,{agent:a,revision:0,agentAccessMode:N?`full-access`:`default`,workspaceToolsEnabled:N,onModelSelect:I,onAccessModeChange:()=>void 0,onRollbackFromMessage:R,onRetryFromMessage:()=>void 0,onCopyAnswer:F,onForkFromMessage:()=>void 0,onApproveToolCall:()=>void 0,onRejectToolCall:()=>void 0,disableFork:!0,rollbackConfirmTitle:w(`sharedRollbackConfirmTitle`),rollbackConfirmDescription:w(`sharedRollbackConfirm`),readOnly:!j,restoredDraft:x,onRestoredDraftConsumed:L,bypassClientApiKeyCheck:!0})]}):(0,B.jsx)(`div`,{className:`flex min-h-screen items-center justify-center bg-background p-6 text-foreground`,children:(0,B.jsxs)(`div`,{className:`w-full max-w-md rounded-2xl border border-border bg-background p-6 shadow-quickforge`,children:[(0,B.jsxs)(`div`,{className:`flex items-center gap-2 text-base font-semibold`,children:[(0,B.jsx)(r,{className:`size-5 text-amber-500`}),`QuickForge 局域网对话分享`]}),(0,B.jsx)(`p`,{className:`mt-2 text-sm text-muted-foreground`,children:`如果分享者设置了密码,请输入密码。未设置密码的链接会自动打开。`}),(0,B.jsx)(`input`,{type:`password`,value:t,onChange:e=>i(e.target.value),onKeyDown:e=>{e.key===`Enter`&&P()},className:`mt-5 h-10 w-full rounded-md border border-input bg-background px-3 text-sm outline-none focus:border-primary`,placeholder:`密码`,autoFocus:!0}),d?(0,B.jsx)(`div`,{className:`mt-3 rounded-md border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive`,children:d}):null,(0,B.jsx)(O,{className:`mt-5 w-full`,onClick:()=>void P(),disabled:g||!t.trim(),children:g?w(`loading`):`用密码打开分享对话`})]})})}export{G as SharedConversationPage};
|
|
1
|
+
import{i as e}from"./rolldown-runtime-DWdDZTNf.js";import{Ot as t,i as n,rt as r}from"./icons-ko_i0WpN.js";import{n as i}from"./react-vendor-2RKYr-A4.js";import{S as a,b as o,d as s,f as c,p as l,u}from"./pi-web-ui-DoRGtREc.js";import{U as d}from"./pi-ai-Cr3rpCXT.js";import{t as f}from"./logger-B65Akg8A.js";import{B as p,G as m,J as h,U as g,W as _,Y as v,Z as y,c as b,lt as x,mt as S,o as C,ot as w,q as T,s as E,ut as D,x as O}from"./index-B8Awq5FV.js";import{ChatPanelHost as k}from"./ChatPanelHost-vi1tDqlJ.js";var A=e(t(),1),j=`quickforgeClientMessageId`;function M(e){let t=e?.metadata;return t&&typeof t==`object`&&!Array.isArray(t)?t:void 0}function N(e){let t=M(e)?.[j];return typeof t==`string`&&t?t:void 0}function P(){return`qfcm_${typeof crypto<`u`&&typeof crypto.randomUUID==`function`?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}`}function F(e){let t=N(e);if(t)return{message:e,clientMessageId:t};let n=P();return{message:{...e,metadata:{...M(e),[j]:n}},clientMessageId:n}}function I(e){return typeof e==`string`?e:Array.isArray(e)?e.filter(e=>e&&typeof e==`object`&&e.type===`text`).map(e=>e.text).filter(e=>typeof e==`string`).join(``):``}function L(e,t){if(!e||!t||e.role!==t.role)return!1;let n=N(e),r=N(t);return n&&r?n===r:I(e.content)===I(t.content)}async function R(e,t){let n=await fetch(e,{...t,cache:`no-store`,headers:{...t?.body?{"content-type":`application/json`}:void 0,...t?.headers}}),r=await n.json().catch(()=>null);if(!n.ok)throw Error(r?.error||`Request failed: ${n.status}`);return r}var z=class e{state;streamFn=d;getApiKey;sessionId;shareId;permission;listeners=new Set;eventSource=null;disposed=!1;reconnectTimer=null;reconnectDelay=1e3;baseUrl=``;syncingThinkingLevel=!1;planMode=!1;onPlanModeConsumed;constructor(e,t){this.shareId=e,this.sessionId=t.sessionId||t.id||e,this.permission=t.permission??`read`;let n={systemPrompt:t.systemPrompt??``,model:t.model??{provider:`shared`,id:`shared`},thinkingLevel:t.thinkingLevel??`off`,messages:t.messages?.slice()??[],tools:t.tools??[],isStreaming:!!t.isStreaming,streamingMessage:void 0,pendingToolCalls:new Set,errorMessage:t.errorMessage,contextCompaction:t.contextCompaction??null,contextUsage:t.contextUsage??null};this.state=new Proxy(n,{set:(e,t,n)=>{let r=e[t];return e[t]=n,t===`thinkingLevel`&&!this.syncingThinkingLevel&&n!==r&&this.updateThinkingLevel(n).catch(e=>{f.error(`Failed to update shared thinking level:`,e)}),!0}}),this.connectEvents()}subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}setNextPromptCapabilities(){}setPlanMode(e,t){this.planMode=e,this.onPlanModeConsumed=e?t:void 0}async prompt(e){if(this.disposed||this.permission!==`operate`)return;let{message:t,clientMessageId:n}=F(this.normalizeInput(e)),r=this.planMode?{type:`plan`}:void 0;if(this.planMode){this.planMode=!1;let e=this.onPlanModeConsumed;this.onPlanModeConsumed=void 0,e?.()}this.state.messages=[...this.state.messages,t],this.emit({type:`message_start`,message:t}),this.state.isStreaming||(this.state.isStreaming=!0,this.state.errorMessage=void 0,this.emit({type:`agent_start`}));try{await R(`/api/shared/${encodeURIComponent(this.shareId)}/message`,{method:`POST`,body:JSON.stringify({message:t,clientMessageId:n,command:r})})}catch(e){let t=e instanceof Error?e.message:String(e);throw this.state.errorMessage=t,this.state.isStreaming=!1,this.emit({type:`error`,error:t}),this.emit({type:`agent_end`,messages:this.state.messages}),e}}async updateModel(e){if(!(this.disposed||this.permission!==`operate`)){this.state.model=e;try{let t=await R(`/api/shared/${encodeURIComponent(this.shareId)}/model`,{method:`POST`,body:JSON.stringify({model:e})});t.model&&(this.state.model=t.model)}catch(e){let t=e instanceof Error?e.message:String(e);throw this.state.errorMessage=t,this.emit({type:`error`,error:t}),e}}}async updateThinkingLevel(e){if(!(this.disposed||this.permission!==`operate`)){!this.syncingThinkingLevel&&this.state.thinkingLevel!==e&&(this.state.thinkingLevel=e);try{let t=await R(`/api/shared/${encodeURIComponent(this.shareId)}/thinking-level`,{method:`POST`,body:JSON.stringify({thinkingLevel:e})});t.thinkingLevel&&(this.state.thinkingLevel=t.thinkingLevel)}catch(e){let t=e instanceof Error?e.message:String(e);throw this.state.errorMessage=t,this.emit({type:`error`,error:t}),e}}}abort(){this.permission===`operate`&&fetch(`/api/shared/${encodeURIComponent(this.shareId)}/abort`,{method:`POST`}).catch(e=>{f.error(`Failed to abort shared conversation:`,e)})}steer(){}followUp(){}reset(){this.state.messages=[],this.state.errorMessage=void 0,this.state.isStreaming=!1,this.state.streamingMessage=void 0,this.state.pendingToolCalls=new Set}async rollback(e){if(this.permission!==`operate`)return;let t=await R(`/api/shared/${encodeURIComponent(this.shareId)}/rollback`,{method:`POST`,body:JSON.stringify({messageIndex:e})});return this.applyState(t.session),this.emit({type:`messages_replaced`,messages:this.state.messages}),t}dispose(){this.disposed=!0,this.reconnectTimer&&clearTimeout(this.reconnectTimer),this.reconnectTimer=null,this.eventSource?.close(),this.eventSource=null,this.listeners.clear()}static async loadState(e){return R(`/api/shared/${encodeURIComponent(e)}/session`)}static async create(t){return new e(t,await e.loadState(t))}normalizeInput(e){return typeof e==`string`?{role:`user`,content:e,timestamp:Date.now()}:Array.isArray(e)?[...e].reverse().find(e=>e.role===`user`||e.role===`user-with-attachments`)??e[e.length-1]:e}connectEvents(){this.disposed||(this.eventSource?.close(),this.baseUrl=``,this.openEventSource())}openEventSource(){if(this.disposed)return;let e=`${this.baseUrl}/api/shared/${encodeURIComponent(this.shareId)}/events`;this.eventSource=new EventSource(e,{withCredentials:!0}),this.eventSource.onopen=()=>{this.reconnectDelay=1e3};let t=[`state`,`agent_start`,`agent_end`,`message_start`,`message_end`,`turn_start`,`turn_end`,`message_update`,`tool_execution_start`,`tool_execution_update`,`tool_execution_end`,`error`,`title_updated`,`messages_replaced`,`auto_compact_completed`],n=e=>t=>{try{let n=JSON.parse(t.data);this.handleEvent(e?{type:e,...n}:n)}catch{}};this.eventSource.onmessage=n();for(let e of t)this.eventSource.addEventListener(e,n(e));this.eventSource.onerror=()=>{this.eventSource?.close(),this.eventSource=null,this.scheduleReconnect()}}scheduleReconnect(){this.disposed||this.reconnectTimer||(this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.reconnectDelay=Math.min(this.reconnectDelay*2,3e4),this.openEventSource()},this.reconnectDelay))}handleEvent(e){if(e.type){switch(e.type){case`state`:this.applyState(e);break;case`agent_start`:this.state.isStreaming=!0,this.state.errorMessage=void 0;break;case`agent_end`:this.state.isStreaming=!1,this.state.streamingMessage=void 0;break;case`message_start`:if(e.message){let t=this.state.messages.findIndex(t=>L(t,e.message));if(t>=0){let n=this.state.messages.slice();n[t]=e.message,this.state.messages=n}else this.state.messages=[...this.state.messages,e.message];this.state.contextUsage=null}break;case`message_update`:e.message&&(this.state.streamingMessage=e.message);break;case`message_end`:e.message&&(this.state.messages=h(this.state.messages,e.message)),this.state.contextUsage=`contextUsage`in e?e.contextUsage:null,this.state.streamingMessage=void 0;break;case`messages_replaced`:e.messages&&(this.state.messages=e.messages,this.state.streamingMessage=void 0),`contextCompaction`in e&&(this.state.contextCompaction=e.contextCompaction),`contextUsage`in e&&(this.state.contextUsage=e.contextUsage);break;case`auto_compact_completed`:`contextCompaction`in e&&(this.state.contextCompaction=e.contextCompaction),`contextUsage`in e&&(this.state.contextUsage=e.contextUsage);break;case`tool_execution_start`:{let t=e;t.toolCallId&&(this.state.messages=v(this.state.messages,T(t),!0),this.state.pendingToolCalls=new Set([...this.state.pendingToolCalls,t.toolCallId]));break}case`tool_execution_update`:{let t=e;this.state.messages=v(this.state.messages,t,!0),t.toolCallId&&(this.state.pendingToolCalls=new Set([...this.state.pendingToolCalls,t.toolCallId]));break}case`tool_execution_end`:{let t=e;if(this.state.messages=v(this.state.messages,t,!1),t.toolCallId){let e=new Set(this.state.pendingToolCalls);e.delete(t.toolCallId),this.state.pendingToolCalls=e}break}case`error`:this.state.errorMessage=typeof e.error==`string`?e.error:`Unknown error`,this.state.isStreaming=!1;break}this.emit(e)}}applyState(e){this.sessionId=e.sessionId||e.id||this.sessionId,e.messages&&(this.state.messages=e.messages,this.state.contextUsage=e.contextUsage===void 0?null:e.contextUsage),e.systemPrompt!==void 0&&(this.state.systemPrompt=e.systemPrompt),e.model&&(this.state.model=e.model),e.thinkingLevel&&(this.syncingThinkingLevel=!0,this.state.thinkingLevel=e.thinkingLevel,this.syncingThinkingLevel=!1),e.tools&&(this.state.tools=e.tools),e.isStreaming!==void 0&&(this.state.isStreaming=!!e.isStreaming),e.errorMessage!==void 0&&(this.state.errorMessage=e.errorMessage),e.contextCompaction!==void 0&&(this.state.contextCompaction=e.contextCompaction),e.contextUsage!==void 0&&(this.state.contextUsage=e.contextUsage)}emit(e){for(let t of this.listeners)try{t(e)}catch{}}},B=i();function V(e){return{id:`shared-${e.provider}`,name:e.provider,type:e.api,baseUrl:e.baseUrl??``,models:[e]}}async function H(e,t){try{let t=await E(e);if(t.providers?.length)return t.providers}catch{}return t?[V(t)]:[]}function U(e,t){let n=t.model??{provider:`shared`,id:`shared`};return new z(e,{...t,model:n,thinkingLevel:t.thinkingLevel??y(n)})}function W(e,t){let n={settings:new u,providerKeys:new c,sessions:new s,customProviders:new l},r=new w(``,{blockedStores:[`sessions`,`provider-keys`],fakeProviderKeys:t?[t.provider]:void 0,storeOverrides:t?{"custom-providers":{keys:async()=>(await H(e,t)).map(e=>e.name),get:async n=>(await H(e,t)).find(e=>e.name===n)??null,has:async n=>(await H(e,t)).some(e=>e.name===n)}}:void 0});n.settings.setBackend(r),n.providerKeys.setBackend(r),n.sessions.setBackend(r),n.customProviders.setBackend(r),a(new o(n.settings,n.providerKeys,n.sessions,n.customProviders,r))}function G({shareId:e}){let[t,i]=(0,A.useState)(``),[a,o]=(0,A.useState)(null),[s,c]=(0,A.useState)(`read`),[l,u]=(0,A.useState)(`QuickForge 分享对话`),[d,h]=(0,A.useState)(),[v,y]=(0,A.useState)(!1),[w,T]=(0,A.useState)(),E=(0,A.useRef)(!1),j=s===`operate`,M=!!a,N=!!a?.state.tools?.length;(0,A.useEffect)(()=>{W(e,a?.state.model)},[a?.state.model,e]),(0,A.useEffect)(()=>()=>a?.dispose(),[a]);let P=(0,A.useCallback)(async(n=t.trim())=>{h(void 0),y(!0);try{let t=await b(e,n);c(t.permission),u(t.title||t.share.titleSnapshot||`QuickForge 分享对话`);let r=await z.loadState(e);W(e,r.model),o(U(e,r))}catch(e){h(e instanceof Error?e.message:`Failed to unlock shared conversation`)}finally{y(!1)}},[t,e]);(0,A.useEffect)(()=>{if(M||v||E.current)return;E.current=!0;let t=window.setTimeout(()=>{(async()=>{try{(await C(e)).share.hasPassword||await P(``)}catch(e){h(e instanceof Error?e.message:`Failed to load shared conversation`)}})()},0);return()=>window.clearTimeout(t)},[v,e,P,M]);let F=(0,A.useCallback)(async e=>{await g(e)},[]),I=(0,A.useCallback)(async()=>{if(!(!a||a.permission!==`operate`))try{let t=(await H(e,a.state.model)).flatMap(e=>e.models??[]);if(!t.length)return;O(a.state.model,t,t=>{!t.reasoning&&a.state.thinkingLevel!==`off`&&a.updateThinkingLevel(`off`).catch(e=>{f.error(`Failed to update shared thinking level:`,e)}),W(e,t),a.updateModel(t).catch(e=>{h(e instanceof Error?e.message:`Failed to update model`)})},void 0,{thinkingLevel:a.state.thinkingLevel,onThinkingLevelSelect:e=>{a.updateThinkingLevel(e).catch(e=>{f.error(`Failed to update shared thinking level:`,e),h(e instanceof Error?e.message:`Failed to update thinking level`)})}})}catch(e){h(e instanceof Error?e.message:`Failed to load models`)}},[a,e]),L=(0,A.useCallback)(e=>{T(t=>t?.id===e?void 0:t)},[]),R=(0,A.useCallback)(async e=>{if(!a||a.permission!==`operate`)return;if(h(void 0),a.state.isStreaming){p(S(`generationStillRunning`));return}let t=m(a.state.messages,e),n=t>=0?a.state.messages[t]:void 0;if(!n){p(S(`noConversationTurnToRollback`));return}try{await a.rollback(e),T({id:Date.now(),sessionId:a.sessionId,text:_(n),attachments:n.role===`user-with-attachments`?n.attachments:void 0})}catch(e){h(e instanceof Error?e.message:`Failed to roll back`)}},[a]);return M?(0,B.jsxs)(`div`,{className:`flex h-screen min-h-0 flex-col bg-background text-foreground`,children:[(0,B.jsx)(`header`,{className:D(`shrink-0 border-b px-4 py-3`,j?`border-red-300 bg-red-50 text-red-950`:`border-border bg-background`),children:(0,B.jsxs)(`div`,{className:`mx-auto flex max-w-4xl items-start gap-3`,children:[(0,B.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,B.jsx)(`div`,{className:`truncate text-sm font-semibold`,children:l}),(0,B.jsxs)(`div`,{className:`mt-1 flex flex-wrap items-center gap-x-2 gap-y-1 text-xs`,children:[(0,B.jsxs)(`span`,{className:D(`inline-flex items-center gap-1 rounded-full px-2 py-0.5 font-medium`,j?`bg-red-100 text-red-700`:`bg-muted text-muted-foreground`),children:[j?(0,B.jsx)(n,{className:`size-3.5`}):null,j?`高危可操作`:`只读分享`]}),(0,B.jsx)(`span`,{className:D(j?`text-red-800`:`text-muted-foreground`),children:j?`正在操作分享者的原始对话`:`只能查看,不能发送或修改`})]}),j?null:(0,B.jsx)(`div`,{className:`mt-1 text-xs leading-5 text-muted-foreground`,children:`界面与正常对话保持一致`})]}),(0,B.jsxs)(x,{variant:`ghost`,size:`sm`,className:D(`shrink-0`,j?`text-red-700 hover:bg-red-100 hover:text-red-800`:void 0),onClick:()=>void g(window.location.href),"aria-label":j?`复制高危分享链接`:`复制分享链接`,title:j?`复制高危分享链接`:`复制分享链接`,children:[(0,B.jsx)(r,{className:`size-4`}),(0,B.jsx)(`span`,{className:`hidden sm:inline`,children:j?`复制高危链接`:`复制链接`})]})]})}),d?(0,B.jsx)(`div`,{className:`mx-auto w-full max-w-4xl px-4 py-2 text-sm text-destructive`,children:d}):null,(0,B.jsx)(k,{agent:a,revision:0,agentAccessMode:N?`full-access`:`default`,workspaceToolsEnabled:N,onModelSelect:I,onAccessModeChange:()=>void 0,onRollbackFromMessage:R,onRetryFromMessage:()=>void 0,onCopyAnswer:F,onForkFromMessage:()=>void 0,onApproveToolCall:()=>void 0,onRejectToolCall:()=>void 0,disableFork:!0,rollbackConfirmTitle:S(`sharedRollbackConfirmTitle`),rollbackConfirmDescription:S(`sharedRollbackConfirm`),readOnly:!j,restoredDraft:w,onRestoredDraftConsumed:L,bypassClientApiKeyCheck:!0})]}):(0,B.jsx)(`div`,{className:`flex min-h-screen items-center justify-center bg-background p-6 text-foreground`,children:(0,B.jsxs)(`div`,{className:`w-full max-w-md rounded-2xl border border-border bg-background p-6 shadow-quickforge`,children:[(0,B.jsxs)(`div`,{className:`flex items-center gap-2 text-base font-semibold`,children:[(0,B.jsx)(n,{className:`size-5 text-amber-500`}),`QuickForge 局域网对话分享`]}),(0,B.jsx)(`p`,{className:`mt-2 text-sm text-muted-foreground`,children:`如果分享者设置了密码,请输入密码。未设置密码的链接会自动打开。`}),(0,B.jsx)(`input`,{type:`password`,value:t,onChange:e=>i(e.target.value),onKeyDown:e=>{e.key===`Enter`&&P()},className:`mt-5 h-10 w-full rounded-md border border-input bg-background px-3 text-sm outline-none focus:border-primary`,placeholder:`密码`,autoFocus:!0}),d?(0,B.jsx)(`div`,{className:`mt-3 rounded-md border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive`,children:d}):null,(0,B.jsx)(x,{className:`mt-5 w-full`,onClick:()=>void P(),disabled:v||!t.trim(),children:v?S(`loading`):`用密码打开分享对话`})]})})}export{G as SharedConversationPage};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{i as e}from"./rolldown-runtime-DWdDZTNf.js";import{F as t,L as n,Ot as r,_t as i,j as a,n as o,s,x as c}from"./icons-ko_i0WpN.js";import{n as l}from"./react-vendor-2RKYr-A4.js";import{A as u,N as d,T as f,lt as p,mt as m,ut as h}from"./index-B8Awq5FV.js";import{n as ee,t as g}from"./xterm-CGiQzDiR.js";var _=e(r(),1);async function v(e,t){let n=await fetch(e,{cache:`no-store`,...t}),r=await n.json().catch(()=>null);if(!n.ok)throw Error(r?.error||`Request failed: ${n.status}`);return r}function y(){return v(`/api/terminal/capabilities`)}function b(e){return v(`/api/terminal/sessions${e?`?projectId=${encodeURIComponent(e)}`:``}`)}function x(e){return v(`/api/terminal/sessions`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify(e)})}function S(e){return v(`/api/terminal/sessions/${encodeURIComponent(e)}`,{method:`DELETE`})}function C(e,t){return v(`/api/terminal/sessions/${encodeURIComponent(e)}/input`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({data:t})})}function w(){return``}function te(){let e=w();if(e){let t=new URL(e);return t.protocol=t.protocol===`https:`?`wss:`:`ws:`,t.toString().replace(/\/$/,``)}return`${location.protocol===`https:`?`wss:`:`ws:`}//${location.host}`}function T(){let[e,t]=(0,_.useState)(()=>f());return(0,_.useEffect)(()=>{if(typeof document>`u`)return;let e=document.documentElement,n=()=>t(f());n();let r=new MutationObserver(n);return r.observe(e,{attributes:!0,attributeFilter:[`class`]}),()=>r.disconnect()},[]),e}var E=l(),D={light:{background:`#ffffff`,foreground:`#1f2937`,cursor:`#1f2937`,selectionBackground:`#dbeafe`},dark:{background:`#171717`,foreground:`#e5e7eb`,cursor:`#e5e7eb`,selectionBackground:`#3f3f46`}};function ne({session:e,active:t,height:n,onReady:r,onExited:i,onConnectionError:a}){let o=T(),s=D[o],c=(0,_.useRef)(null),l=(0,_.useRef)(null),f=(0,_.useRef)(null),p=(0,_.useRef)(null),h=(0,_.useRef)(null),v=(0,_.useRef)(null);return(0,_.useEffect)(()=>{let t=c.current;if(!t)return;let n=!1,o=!1,_=!1,y=!1,b=t=>{n||_||y||(y=!0,a(e.id,t))},x=d(),S=new ee({cursorBlink:!0,convertEol:!1,fontFamily:getComputedStyle(document.documentElement).getPropertyValue(`--font-mono`).trim()||`ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace`,fontSize:x.fontSize,lineHeight:x.lineHeight,scrollback:5e3,theme:s}),C=new g;S.loadAddon(C),S.open(t),S.writeln(`\x1b[2mConnected to ${e.cwd}\x1b[0m`),l.current=S,f.current=C;let w=()=>{if(t.isConnected)try{C.fit();let{cols:e,rows:t}=S,n=p.current;n?.readyState===WebSocket.OPEN&&n.send(JSON.stringify({type:`resize`,cols:e,rows:t}))}catch{}},T=new WebSocket(`${te()}/api/terminal/sessions/${encodeURIComponent(e.id)}/ws`);p.current=T,T.addEventListener(`open`,()=>{o=!0,y=!1,a(e.id,void 0),h.current=S.onData(e=>{T.readyState===WebSocket.OPEN&&T.send(JSON.stringify({type:`input`,data:e}))}),window.setTimeout(w,0)}),T.addEventListener(`message`,t=>{try{let n=JSON.parse(String(t.data));n.type===`ready`?r(e.id):n.type===`output`?S.write(n.data):n.type===`exit`?(_=!0,S.writeln(``),S.writeln(`\x1b[33m[process exited with code ${n.exitCode??`unknown`}]\x1b[0m`),i(e.id)):n.type===`error`&&S.writeln(`\x1b[31m${n.message}\x1b[0m`)}catch{}}),T.addEventListener(`error`,()=>{b(m(o?`terminalConnectionClosedUnexpectedly`:`terminalConnectionFailed`))}),T.addEventListener(`close`,e=>{h.current?.dispose(),h.current=null,!(n||_)&&(!e.wasClean||e.code!==1e3)&&b(m(o?`terminalConnectionClosedUnexpectedly`:`terminalConnectionFailed`))});let E=new ResizeObserver(()=>w());E.observe(t),v.current=E;let D=()=>{let e=d();S.options.fontSize=e.fontSize,S.options.lineHeight=e.lineHeight,window.setTimeout(w,0)};return window.addEventListener(u,D),window.setTimeout(w,50),()=>{n=!0,window.removeEventListener(u,D),E.disconnect(),v.current=null,h.current?.dispose(),h.current=null,T.close(),p.current=null,S.dispose(),l.current=null,f.current=null}},[o,a,i,r,e.cwd,e.id,s]),(0,_.useEffect)(()=>{if(!t)return;let e=f.current,n=l.current;window.setTimeout(()=>{try{e?.fit(),n?.focus()}catch{}},0)},[t,n]),(0,E.jsx)(`div`,{className:t?`h-full min-h-0 w-full pl-2 md:pl-3`:`hidden`,"aria-hidden":!t,children:(0,E.jsx)(`div`,{ref:c,className:`h-full min-h-0 w-full`})})}var re=180,ie=.7,ae=320;function O(e,t){let n=t?t.name:`Terminal`,r=new Set(e.map(e=>e.name));if(n!==`Terminal`&&!r.has(n))return n;let i=1;for(;r.has(`${n} ${i}`);)i+=1;return`${n} ${i}`}function k(e,t){let n=e?.terminalShellProfiles||[],r=t||e?.defaultTerminalShellProfileId||``;return n.find(e=>e.id===r)||n[0]}function A({project:e,onCollapse:r,pendingCommand:l,onPendingCommandHandled:u,variant:d=`dock`,singleSession:f=!1,panelInstanceId:ee,panelSessionId:g,onPanelSessionReady:v}){let[w,te]=(0,_.useState)(null),[T,D]=(0,_.useState)([]),[A,j]=(0,_.useState)(),[M,oe]=(0,_.useState)(ae),[N,se]=(0,_.useState)(!0),[P,ce]=(0,_.useState)(!1),[le,F]=(0,_.useState)(),[ue,I]=(0,_.useState)({}),[L,R]=(0,_.useState)(!1),[z,de]=(0,_.useState)(!1),B=(0,_.useRef)(!1),V=(0,_.useRef)(!1),H=(0,_.useRef)(new Set),fe=(0,_.useRef)(l),U=(0,_.useRef)(new Set),W=(0,_.useRef)(new Set),G=(0,_.useRef)(new Map),K=(0,_.useRef)(!0),pe=(0,_.useRef)(v),[me,he]=(0,_.useState)(()=>new Set),q=(0,_.useRef)(null),ge=(0,_.useRef)(null),J=e?.id,Y=d===`panel`&&!!ee,X=(0,_.useMemo)(()=>T.find(e=>e.id===A)??T[0],[A,T]);(0,_.useEffect)(()=>{fe.current=l},[l]),(0,_.useEffect)(()=>{pe.current=v},[v]),(0,_.useEffect)(()=>()=>{K.current=!1},[]);let _e=(0,_.useCallback)(async()=>{let e=await b(J);return D(e.sessions),j(t=>t&&e.sessions.some(e=>e.id===t)?t:e.sessions[0]?.id),e.sessions},[J]),ve=(0,_.useCallback)(async(e,t)=>{if(B.current)return;let n=k(w,t);B.current=!0,ce(!0),F(void 0),I({});try{let t=await x({projectId:J,name:O(e,n),cols:120,rows:30,shellProfileId:n?.id,shellProfileName:n?.name});D(e=>[...e,t]),j(t.id)}catch(e){F(e instanceof Error?e.message:m(`terminalCreateFailed`))}finally{B.current=!1,ce(!1)}},[w,J]);(0,_.useEffect)(()=>{let e=!1;return(async()=>{se(!0),F(void 0);try{let[t,n]=await Promise.all([y(),b(J)]);if(e)return;if(te(t),t.enabled&&Y&&g&&n.sessions.some(e=>e.id===g)){V.current=!0,D(n.sessions),j(g);return}if(t.enabled&&Y&&!V.current){V.current=!0;let r=k(t);try{let t=await x({projectId:J,name:O(n.sessions,r),cols:120,rows:30,shellProfileId:r?.id,shellProfileName:r?.name});if(e){S(t.id).catch(()=>{});return}D([...n.sessions,t]),j(t.id),pe.current?.(t.id);return}catch(t){e||F(t instanceof Error?t.message:m(`terminalCreateFailed`))}}if(D(n.sessions),j(n.sessions[0]?.id),t.enabled&&n.sessions.length===0&&!fe.current){let n=k(t);x({projectId:J,name:O([],n),cols:120,rows:30,shellProfileId:n?.id,shellProfileName:n?.name}).then(t=>{if(e){S(t.id).catch(()=>{});return}D([t]),j(t.id)}).catch(t=>{e||F(t instanceof Error?t.message:m(`terminalCreateFailed`))})}}catch(t){e||F(t instanceof Error?t.message:m(`terminalUnavailable`))}finally{e||se(!1)}})(),()=>{e=!0}},[Y,g,J]),(0,_.useEffect)(()=>{if(!L)return;let e=e=>{ge.current?.contains(e.target)||R(!1)},t=e=>{e.key===`Escape`&&R(!1)};return document.addEventListener(`pointerdown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`pointerdown`,e),document.removeEventListener(`keydown`,t)}},[L]),(0,_.useEffect)(()=>{if(!z)return;let e=e=>{e.key===`Escape`&&de(!1)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[z]),(0,_.useEffect)(()=>{if(!l||H.current.has(l.id)||G.current.has(l.id)||U.current.has(l.id)||N||P||!w)return;if(!w.enabled){H.current.add(l.id),window.setTimeout(()=>{F(w.reason||m(`terminalUnavailable`)),u?.(l.id)},0);return}let e=X&&!X.exited?X:T.find(e=>!e.exited);if(e){G.current.set(l.id,e.id),window.setTimeout(()=>{K.current&&j(e.id)},0);return}U.current.add(l.id),window.setTimeout(()=>{K.current&&F(void 0)},0);let t=k(w);x({projectId:J,name:O(T,t),cols:120,rows:30,shellProfileId:t?.id,shellProfileName:t?.name}).then(e=>{if(!K.current){S(e.id).catch(()=>{});return}G.current.set(l.id,e.id),D(t=>t.some(t=>t.id===e.id)?t:[...t,e]),j(e.id)}).catch(e=>{K.current&&(F(e instanceof Error?e.message:m(`terminalCommandExecuteFailed`)),H.current.add(l.id),u?.(l.id))}).finally(()=>{U.current.delete(l.id)})},[X,w,P,N,u,l,J,T]),(0,_.useEffect)(()=>{if(!l||H.current.has(l.id)||W.current.has(l.id))return;let e=G.current.get(l.id),t=e?T.find(t=>t.id===e):X&&!X.exited?X:T.find(e=>!e.exited);!t||t.exited||!me.has(t.id)||(W.current.add(l.id),window.setTimeout(()=>{K.current&&(j(t.id),F(void 0))},0),(async()=>{try{if(l.execute){let e=l.command.split(`
|
|
2
|
+
`),n=e.flatMap((t,n)=>n<e.length-1?[t,`\r`]:[t]);n.push(`\r`),await C(t.id,n.join(``))}else await C(t.id,l.command)}catch(e){K.current&&F(e instanceof Error?e.message:m(`terminalCommandExecuteFailed`))}finally{H.current.add(l.id),W.current.delete(l.id),G.current.delete(l.id),K.current&&u?.(l.id)}})())},[X,u,l,me,T]);let ye=async e=>{F(void 0),I(t=>{if(!t[e])return t;let n={...t};return delete n[e],n});let t=T.filter(t=>t.id!==e);D(t),A===e&&j(t[0]?.id);try{await S(e)}catch(e){F(e instanceof Error?e.message:m(`terminalCloseFailed`)),_e().catch(()=>{})}},be=(0,_.useCallback)(e=>{D(t=>t.map(t=>t.id===e?{...t,exited:!0}:t)),he(t=>{if(!t.has(e))return t;let n=new Set(t);return n.delete(e),n})},[]),xe=(0,_.useCallback)(e=>{he(t=>{if(t.has(e))return t;let n=new Set(t);return n.add(e),n})},[]),Se=(0,_.useCallback)((e,t)=>{I(n=>{if(!t){if(!n[e])return n;let t={...n};return delete t[e],t}return n[e]===t?n:{...n,[e]:t}})},[]),Ce=e=>{q.current={startY:e.clientY,startHeight:M},e.currentTarget.setPointerCapture(e.pointerId)},we=e=>{let t=q.current;if(!t)return;let n=Math.max(re,Math.floor(window.innerHeight*ie));oe(Math.min(n,Math.max(re,t.startHeight+t.startY-e.clientY)))},Te=e=>{q.current=null;try{e.currentTarget.releasePointerCapture(e.pointerId)}catch{}},Z=w?.terminalShellProfiles||[],Ee=w?.defaultTerminalShellProfileId||``,De=Z.find(e=>e.id===Ee)||Z[0],Oe=!!(w&&T.length>=w.maxSessions),ke=P||Oe,Ae=X?ue[X.id]:void 0,je=Y&&X?[X]:T,Q=le??Ae,$=d===`panel`,Me=$&&f,Ne=$?void 0:z?Q?`calc(100% - 4.25rem)`:`calc(100% - 2.25rem)`:Q?M-72:M-45;return(0,E.jsxs)(`div`,{className:h($?`flex min-h-0 flex-1 flex-col bg-background`:`shrink-0 border-t border-border bg-background`,z&&`quickforge-terminal-fullscreen z-40 flex flex-col border-t-0`),style:z||$?void 0:{height:M},children:[!z&&!$?(0,E.jsx)(`div`,{className:`h-1 cursor-row-resize bg-transparent hover:bg-border`,onPointerDown:Ce,onPointerMove:we,onPointerUp:Te,onPointerCancel:Te}):null,(0,E.jsxs)(`div`,{className:`flex h-9 items-center gap-1 border-b border-border px-2`,children:[(0,E.jsx)(s,{className:`size-4 shrink-0 text-muted-foreground/60`}),(0,E.jsx)(`div`,{className:`flex min-w-0 flex-1 items-center gap-1 overflow-x-auto`,children:je.map(e=>{let t=h(`flex max-w-44 shrink-0 items-center gap-1 rounded-md px-2 py-1 text-xs text-muted-foreground/72`,X?.id===e.id&&`bg-muted/28 text-foreground/90`);return Me?(0,E.jsxs)(`div`,{className:t,title:`${e.name} — ${e.cwd}`,children:[(0,E.jsx)(`span`,{className:h(`size-1.5 rounded-full`,e.exited?`bg-muted-foreground/40`:`bg-emerald-500/80`)}),(0,E.jsx)(`span`,{className:`truncate`,children:e.name})]},e.id):(0,E.jsxs)(`button`,{type:`button`,className:h(t,`hover:bg-muted/20 hover:text-foreground/85`),onClick:()=>j(e.id),title:`${e.name} — ${e.cwd}`,children:[(0,E.jsx)(`span`,{className:h(`size-1.5 rounded-full`,e.exited?`bg-muted-foreground/40`:`bg-emerald-500/80`)}),(0,E.jsx)(`span`,{className:`truncate`,children:e.name}),(0,E.jsx)(`span`,{role:`button`,tabIndex:0,className:`ml-1 rounded-sm p-0.5 opacity-60 hover:bg-background hover:opacity-100`,onClick:t=>{t.stopPropagation(),ye(e.id)},onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),t.stopPropagation(),ye(e.id))},"aria-label":m(`terminalCloseSession`,{name:e.name}),children:(0,E.jsx)(o,{className:`size-3`})})]},e.id)})}),Me?null:(0,E.jsxs)(`div`,{className:`relative shrink-0`,ref:ge,children:[(0,E.jsxs)(`div`,{className:`flex items-center overflow-hidden rounded-md border border-border bg-background`,children:[(0,E.jsx)(`button`,{type:`button`,className:`inline-flex h-7 w-7 items-center justify-center text-foreground/85 transition-colors hover:bg-muted/20 disabled:pointer-events-none disabled:opacity-50`,onClick:()=>void ve(T),disabled:ke,title:De?m(`terminalNewWithProfile`,{name:De.name}):m(`terminalNew`),"aria-label":m(`terminalNew`),children:P?(0,E.jsx)(n,{className:`size-3.5 animate-spin`}):(0,E.jsx)(c,{className:`size-3.5`})}),Z.length>0?(0,E.jsx)(`button`,{type:`button`,className:`inline-flex h-7 w-7 items-center justify-center border-l border-border text-muted-foreground/72 transition-colors hover:bg-muted/20 hover:text-foreground/85 disabled:pointer-events-none disabled:opacity-50`,onClick:()=>R(e=>!e),disabled:ke,title:m(`terminalSelectShell`),"aria-label":m(`terminalSelectShell`),"aria-expanded":L,children:(0,E.jsx)(i,{className:`size-3.5`})}):null]}),L?(0,E.jsxs)(`div`,{className:h(`absolute right-0 z-30 w-64 overflow-hidden rounded-lg border border-border bg-background p-1.5 shadow-[0_16px_38px_-22px_rgb(15_23_42_/_0.65)]`,$?`top-9`:`bottom-9`),children:[(0,E.jsx)(`div`,{className:`px-2 pb-1.5 pt-1 text-[11px] font-medium uppercase tracking-wide text-muted-foreground/60`,children:m(`terminalNewWith`)}),Z.map(e=>(0,E.jsxs)(`button`,{type:`button`,className:`flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-left text-xs text-muted-foreground/80 hover:bg-muted/20 hover:text-foreground/90`,onClick:()=>{R(!1),ve(T,e.id)},children:[(0,E.jsx)(`span`,{className:`inline-flex size-5 shrink-0 items-center justify-center rounded bg-muted/20 text-[10px] text-muted-foreground/70`,children:e.name.slice(0,1).toUpperCase()}),(0,E.jsxs)(`span`,{className:`min-w-0 flex-1`,children:[(0,E.jsx)(`span`,{className:`block truncate font-medium`,children:e.name}),(0,E.jsx)(`span`,{className:`block truncate font-mono text-[11px] text-muted-foreground/55`,children:e.command})]})]},e.id))]}):null]}),Me?null:(0,E.jsx)(p,{variant:`ghost`,size:`icon`,className:`size-7`,onClick:()=>de(e=>!e),title:m(z?`terminalExitFullscreen`:`terminalFullscreen`),"aria-label":m(z?`terminalExitFullscreen`:`terminalFullscreen`),children:z?(0,E.jsx)(a,{className:`size-3.5`}):(0,E.jsx)(t,{className:`size-3.5`})}),(0,E.jsx)(p,{variant:`ghost`,size:`icon`,className:h(`size-7`,$&&`hidden`),onClick:r,title:m(`terminalCollapse`),"aria-label":m(`terminalCollapse`),children:(0,E.jsx)(i,{className:`size-3.5`})})]}),Q?(0,E.jsx)(`div`,{className:`border-b border-border px-3 py-1.5 text-xs text-destructive`,children:Q}):null,(0,E.jsx)(`div`,{className:h(`min-h-0 bg-background`,$&&`flex-1`),style:Ne===void 0?void 0:{height:Ne},children:N?(0,E.jsxs)(`div`,{className:`flex h-full items-center justify-center gap-2 text-xs text-muted-foreground/60`,children:[(0,E.jsx)(n,{className:`size-4 animate-spin`}),` `,m(`terminalStarting`)]}):w&&!w.enabled?(0,E.jsx)(`div`,{className:`flex h-full items-center justify-center px-4 text-center text-xs text-muted-foreground/60`,children:w.reason||m(`terminalUnavailable`)}):T.length===0?(0,E.jsx)(`div`,{className:`flex h-full items-center justify-center text-xs text-muted-foreground/60`,children:m(`terminalNoSessions`)}):T.map(e=>(0,E.jsx)(ne,{session:e,active:e.id===X?.id,height:z?window.innerHeight-36:$?0:M,onReady:xe,onExited:be,onConnectionError:Se},e.id))})]})}export{A as TerminalDock,T as t};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import{i as e}from"./rolldown-runtime-DWdDZTNf.js";import{$ as t,A as n,B as r,F as i,G as a,H as o,L as s,Ot as c,Q as l,Tt as u,U as d,X as f,Z as p,_t as m,g as h,ht as g,it as _,j as v,n as y,nt as b,pt as x,rt as ee,s as S,v as C,vt as w,x as T,y as te}from"./icons-ko_i0WpN.js";import{n as ne}from"./react-vendor-2RKYr-A4.js";import{A as E,B as re,M as ie,V as ae,_ as oe,a as se,ct as ce,d as le,f as ue,g as de,h as fe,i as D,l as pe,lt as O,m as me,mt as k,n as he,p as ge,r as _e,t as A,u as ve,ut as j,v as ye,y as be}from"./index-B8Awq5FV.js";import{n as xe,r as Se,t as M}from"./mermaid-renderer-BmbSAmpG.js";import{TerminalDock as Ce,t as we}from"./TerminalDock-DQOXpaDe.js";import{n as N,t as Te}from"./monaco-C13M09wD.js";var P=e(c(),1),F=ne();function Ee(e){let t=e.trim();if(!t.startsWith(`/api/workspace/preview/`))return!1;try{let e=new URL(t,window.location.origin);return e.origin===window.location.origin&&e.pathname.startsWith(`/api/workspace/preview/`)}catch{return!1}}function De(e){let t=e.trim().replace(/\\/g,`/`);return t.startsWith(`/`)||/^[a-zA-Z]:\//.test(t)}function Oe(e,t){let n=e.trim();if(!t||!Ee(n))return n;try{let e=new URL(n,window.location.origin),r=`/api/workspace/preview/${encodeURIComponent(t)}/`;return e.pathname.startsWith(r)?e.pathname.slice(r.length).split(`/`).map(e=>decodeURIComponent(e)).join(`/`):n}catch{return n}}function ke(e,t){let n=e.trim();if(!n)return{url:``,displayUrl:``,error:``};if(Ee(n)){let e=new URL(n,window.location.origin);return{url:`${e.pathname}${e.search}${e.hash}`,displayUrl:Oe(n,t),error:``}}if(t&&De(n))return{url:se(t,n),displayUrl:n,error:``};let r=/^https?:\/\//i.test(n)?n:`http://${n}`;try{let e=new URL(r);return e.protocol!==`http:`&&e.protocol!==`https:`?{url:``,displayUrl:n,error:k(`invalidPreviewUrl`)}:{url:e.toString(),displayUrl:e.toString(),error:``}}catch{return{url:``,displayUrl:n,error:k(`invalidPreviewUrl`)}}}function Ae({url:e,onUrlChange:i,projectId:a}){let o=(0,P.useMemo)(()=>ke(e,a),[a,e]),[s,c]=(0,P.useState)({sourceUrl:e,value:o.displayUrl}),[l,d]=(0,P.useState)(``),[f,m]=(0,P.useState)(0),[h,g]=(0,P.useState)(!1),[_,v]=(0,P.useState)(100),y=(0,P.useRef)(null),b=(0,P.useRef)(null),x=o.url,ee=x.startsWith(`/api/workspace/preview/`)?`allow-scripts allow-same-origin allow-forms`:`allow-scripts allow-same-origin allow-forms allow-popups allow-downloads allow-modals allow-pointer-lock`,S=s.sourceUrl===e?s.value:o.displayUrl;(0,P.useEffect)(()=>{if(!h)return;function e(e){y.current?.contains(e.target)||g(!1)}return document.addEventListener(`pointerdown`,e),()=>document.removeEventListener(`pointerdown`,e)},[h]);function C(){try{b.current?.contentWindow?.history.back()}catch{}}function w(e=S){let t=ke(e,a);if(t.error){d(t.error);return}d(``),c({sourceUrl:t.displayUrl,value:t.displayUrl}),i(t.displayUrl),t.url&&m(e=>e+1)}function ne(){x&&m(e=>e+1)}function E(){x&&window.open(x,`_blank`,`noopener,noreferrer`)}return(0,F.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col`,children:[(0,F.jsxs)(`div`,{className:`flex shrink-0 flex-col gap-2 border-b border-border p-3`,children:[(0,F.jsxs)(`form`,{className:`flex items-center gap-2`,onSubmit:e=>{e.preventDefault(),w()},children:[(0,F.jsx)(O,{type:`button`,variant:`ghost`,size:`icon`,onClick:C,disabled:!x,"aria-label":k(`back`),title:k(`back`),children:(0,F.jsx)(u,{className:`size-4`})}),(0,F.jsx)(O,{type:`button`,variant:`ghost`,size:`icon`,onClick:ne,disabled:!x,"aria-label":k(`refreshPreview`),title:k(`refreshPreview`),children:(0,F.jsx)(te,{className:`size-4`})}),(0,F.jsxs)(`label`,{className:`mx-auto flex h-9 min-w-0 max-w-xl flex-1 items-center rounded-full border border-[color-mix(in_oklab,var(--border)_42%,transparent)] bg-muted/30 px-3 text-sm text-muted-foreground/65 focus-within:bg-background focus-within:text-foreground/85`,children:[(0,F.jsx)(`span`,{className:`sr-only`,children:k(`previewUrl`)}),(0,F.jsx)(`input`,{value:S,onChange:t=>{c({sourceUrl:e,value:t.target.value}),l&&d(``)},placeholder:k(`previewUrlPlaceholder`),className:`min-w-0 flex-1 bg-transparent text-center text-sm text-foreground/85 outline-none placeholder:text-muted-foreground/55`})]}),(0,F.jsx)(O,{type:`button`,variant:`ghost`,size:`icon`,onClick:E,disabled:!x,"aria-label":k(`openInBrowser`),title:k(`openInBrowser`),children:(0,F.jsx)(p,{className:`size-4`})}),(0,F.jsxs)(`div`,{ref:y,className:`relative shrink-0`,children:[(0,F.jsx)(O,{type:`button`,variant:`ghost`,size:`icon`,onClick:()=>g(e=>!e),"aria-label":k(`more`),title:k(`more`),"aria-haspopup":`menu`,"aria-expanded":h,children:(0,F.jsx)(t,{className:`size-4`})}),h?(0,F.jsxs)(`div`,{className:`absolute right-0 top-10 z-30 w-48 rounded-2xl border border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-popover p-2 shadow-quickforge`,role:`menu`,children:[(0,F.jsx)(`div`,{className:`px-2 py-1.5 text-xs font-medium text-muted-foreground`,children:k(`zoom`)}),(0,F.jsxs)(`div`,{className:`flex items-center justify-between gap-2 rounded-xl px-1 py-1.5`,children:[(0,F.jsx)(O,{type:`button`,variant:`ghost`,size:`icon`,className:`size-8`,onClick:()=>v(e=>Math.max(50,e-10)),"aria-label":k(`zoomOut`),title:k(`zoomOut`),children:(0,F.jsx)(n,{className:`size-4`})}),(0,F.jsxs)(`button`,{type:`button`,className:`min-w-14 rounded-lg px-2 py-1 text-sm font-medium text-foreground/85 hover:bg-muted/50`,onClick:()=>v(100),title:k(`resetZoom`),children:[_,`%`]}),(0,F.jsx)(O,{type:`button`,variant:`ghost`,size:`icon`,className:`size-8`,onClick:()=>v(e=>Math.min(200,e+10)),"aria-label":k(`zoomIn`),title:k(`zoomIn`),children:(0,F.jsx)(T,{className:`size-4`})})]})]}):null]})]}),l?(0,F.jsx)(`div`,{className:`text-xs text-destructive`,children:l}):null]}),(0,F.jsx)(`div`,{className:`min-h-0 flex-1 bg-muted/10`,children:x?(0,F.jsx)(`div`,{className:`h-full w-full overflow-auto bg-background`,children:(0,F.jsx)(`iframe`,{ref:b,title:k(`webPreview`),src:x,sandbox:ee,className:`origin-top-left border-0 bg-background`,style:{width:`${1e4/_}%`,height:`${1e4/_}%`,transform:`scale(${_/100})`}},`${x}:${f}`)}):(0,F.jsxs)(`div`,{className:`flex h-full flex-col items-center justify-center px-8 text-center`,children:[(0,F.jsx)(r,{className:`size-20 stroke-[1.55] text-muted-foreground/75`}),(0,F.jsx)(`div`,{className:`mt-8 text-xl font-semibold tracking-tight text-foreground/88`,children:k(`noPreviewUrlTitle`)}),(0,F.jsx)(`div`,{className:`mt-4 max-w-xs text-base leading-6 text-muted-foreground/82`,children:k(`noPreviewUrlDescription`)})]})})]})}function je({source:e}){let[t,n]=(0,P.useState)({source:e,value:`preview`}),[r,i]=(0,P.useState)({source:``,dataUrl:``,error:!1});(0,P.useEffect)(()=>{let t=!1;return Se(e).then(n=>{t||i({source:e,dataUrl:M(n),error:!1})}).catch(()=>{t||i({source:e,dataUrl:``,error:!0})}),()=>{t=!0}},[e]);let a=r.source===e?r:{source:e,dataUrl:``,error:!1},o=t.source===e?t.value:`preview`,s=r.source!==e,c=o===`source`||a.error;return(0,F.jsxs)(`figure`,{className:`my-5 overflow-hidden rounded-xl border border-border bg-muted/20`,children:[(0,F.jsxs)(`figcaption`,{className:`flex min-h-9 items-center justify-between gap-3 border-b border-border px-3 py-1.5`,children:[(0,F.jsx)(`span`,{className:`font-mono text-[11px] text-muted-foreground/65`,children:`mermaid`}),(0,F.jsxs)(`span`,{className:`inline-flex items-center gap-1 rounded-md bg-background/70 p-0.5`,children:[(0,F.jsx)(`button`,{type:`button`,className:`rounded px-2 py-1 text-[11px] text-muted-foreground transition-colors hover:text-foreground disabled:cursor-not-allowed disabled:opacity-40`,disabled:!a.dataUrl,"aria-pressed":!c,onClick:()=>n({source:e,value:`preview`}),children:k(`svgPreviewMode`)}),(0,F.jsx)(`button`,{type:`button`,className:`rounded px-2 py-1 text-[11px] text-muted-foreground transition-colors hover:text-foreground`,"aria-pressed":c,onClick:()=>n({source:e,value:`source`}),children:k(`svgSourceMode`)})]})]}),s?(0,F.jsx)(`div`,{className:`flex min-h-28 items-center justify-center px-4 py-8 text-xs text-muted-foreground/70`,role:`status`,children:k(`mermaidRendering`)}):c?(0,F.jsxs)(F.Fragment,{children:[a.error?(0,F.jsx)(`p`,{className:`px-4 pt-3 text-xs text-muted-foreground`,children:k(`mermaidRenderFailed`)}):null,(0,F.jsx)(`pre`,{className:`overflow-auto p-4 text-[12px] leading-5`,children:(0,F.jsx)(`code`,{children:e})})]}):(0,F.jsx)(`div`,{className:`flex min-h-28 justify-center overflow-auto bg-background/45 p-4`,children:(0,F.jsx)(`img`,{className:`h-auto max-w-full object-contain`,src:a.dataUrl,alt:k(`mermaidPreviewLabel`)})})]})}function Me(){let[e,t]=(0,P.useState)(()=>ie());return(0,P.useEffect)(()=>{if(typeof window>`u`)return;let e=()=>t(ie());return window.addEventListener(E,e),()=>window.removeEventListener(E,e)},[]),e}function Ne({path:e,content:t,language:n,wordWrap:r=!1}){let i=we(),a=Me();return(0,F.jsx)(Te,{value:t,language:n,theme:i===`dark`?`vs-dark`:`vs`,options:{readOnly:!0,contextmenu:!1,automaticLayout:!0,minimap:{enabled:!1},fontFamily:getComputedStyle(document.documentElement).getPropertyValue(`--font-mono`).trim()||`ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace`,fontSize:a.fontSize,lineHeight:a.lineHeight,lineNumbers:`on`,scrollBeyondLastLine:!1,wordWrap:r?`on`:`off`,renderLineHighlight:`line`,folding:!1,glyphMargin:!1,scrollbar:{horizontal:r?`auto`:`visible`,horizontalScrollbarSize:10,verticalScrollbarSize:8}}},e)}function I(e){let t=e.trim();if(t&&!/^(javascript|data|vbscript):/i.test(t)&&/^(https?:|mailto:|#|\/|\.\.?\/)/i.test(t))return t}function L(e,t){let n=[],r=/`([^`]+)`|\[([^\]]+)\]\(([^)\s]+)(?:\s+"[^"]*")?\)|\*\*([^*]+)\*\*|__([^_]+)__|\*([^*\n]+)\*|_([^_\n]+)_/g,i=0,a=0,o;for(;o=r.exec(e);){o.index>i&&n.push(e.slice(i,o.index));let s=`${t}-inline-${a++}`;if(o[1])n.push((0,F.jsx)(`code`,{className:`rounded bg-muted/35 px-1 py-0.5 font-mono text-[0.85em] text-foreground/90`,children:o[1]},s));else if(o[2]&&o[3]){let e=I(o[3]);n.push(e?(0,F.jsx)(`a`,{className:`text-primary underline-offset-4 hover:underline`,href:e,target:e.startsWith(`http`)?`_blank`:void 0,rel:`noreferrer`,children:o[2]},s):`[${o[2]}](${o[3]})`)}else o[4]||o[5]?n.push((0,F.jsx)(`strong`,{className:`font-semibold text-foreground/95`,children:o[4]||o[5]},s)):(o[6]||o[7])&&n.push((0,F.jsx)(`em`,{className:`italic`,children:o[6]||o[7]},s));i=r.lastIndex}return i<e.length&&n.push(e.slice(i)),n.length?n:[e]}function R(e,t){return e.split(`
|
|
2
|
+
`).flatMap((e,n)=>{let r=L(e,`${t}-line-${n}`);return n===0?r:[(0,F.jsx)(`br`,{},`${t}-br-${n}`),...r]})}function z(e){return/^\s*(```|~~~)/.test(e)}function Pe(e){return/^\s*\|?\s*:?-{3,}:?\s*(\|\s*:?-{3,}:?\s*)+\|?\s*$/.test(e)}function Fe(e,t){return!!(e[t]?.includes(`|`)&&e[t+1]&&Pe(e[t+1]))}function B(e,t){let n=e[t]??``;return z(n)||Fe(e,t)||/^\s{0,3}#{1,6}\s+/.test(n)||/^\s{0,3}([-*_])(?:\s*\1){2,}\s*$/.test(n)||/^\s{0,3}>\s?/.test(n)||/^\s{0,3}[-*+]\s+/.test(n)||/^\s{0,3}\d+[.)]\s+/.test(n)}function Ie(e){return e.trim().replace(/^\|/,``).replace(/\|$/,``).split(`|`).map(e=>e.trim())}function V(e){let t=e.replace(/\r\n?/g,`
|
|
3
|
+
`).split(`
|
|
4
|
+
`),n=[],r=0,i=0;for(;r<t.length;){let e=t[r],a=`markdown-block-${i++}`;if(!e.trim()){r+=1;continue}if(z(e)){let i=e.match(/^\s*(```|~~~)\s*([^`]*)$/),o=i?.[1]??"```",s=i?.[2]?.trim(),c=[];for(r+=1;r<t.length&&!t[r].trimStart().startsWith(o);)c.push(t[r]),r+=1;r<t.length&&(r+=1);let l=c.join(`
|
|
5
|
+
`);xe(s)?n.push((0,F.jsx)(je,{source:l},a)):n.push((0,F.jsxs)(`figure`,{className:`my-5 overflow-hidden rounded-xl border border-border bg-muted/20`,children:[s?(0,F.jsx)(`figcaption`,{className:`border-b border-border px-3 py-1.5 font-mono text-[11px] text-muted-foreground/65`,children:s}):null,(0,F.jsx)(`pre`,{className:`overflow-auto p-4 text-[12px] leading-5`,children:(0,F.jsx)(`code`,{children:l})})]},a));continue}let o=e.match(/^\s{0,3}(#{1,6})\s+(.+?)\s*#*\s*$/);if(o){let e=o[1].length,t=o[2],i=[`mt-8 mb-3 border-border text-foreground/95`,e===1?`border-b pb-3 text-3xl font-semibold tracking-tight`:``,e===2?`border-b pb-2 text-2xl font-semibold tracking-tight`:``,e===3?`text-xl font-semibold`:``,e===4?`text-lg font-semibold`:``,e>=5?`text-base font-semibold`:``].filter(Boolean).join(` `),s=L(t,`${a}-heading`);e===1?n.push((0,F.jsx)(`h1`,{className:i,children:s},a)):e===2?n.push((0,F.jsx)(`h2`,{className:i,children:s},a)):e===3?n.push((0,F.jsx)(`h3`,{className:i,children:s},a)):e===4?n.push((0,F.jsx)(`h4`,{className:i,children:s},a)):e===5?n.push((0,F.jsx)(`h5`,{className:i,children:s},a)):n.push((0,F.jsx)(`h6`,{className:i,children:s},a)),r+=1;continue}if(/^\s{0,3}([-*_])(?:\s*\1){2,}\s*$/.test(e)){n.push((0,F.jsx)(`hr`,{className:`my-6 border-border`},a)),r+=1;continue}if(Fe(t,r)){let e=Ie(t[r]);r+=2;let i=[];for(;r<t.length&&t[r].includes(`|`)&&t[r].trim();)i.push(Ie(t[r])),r+=1;n.push((0,F.jsx)(`div`,{className:`my-5 overflow-auto rounded-xl border border-border`,children:(0,F.jsxs)(`table`,{className:`w-full border-collapse text-left text-sm`,children:[(0,F.jsx)(`thead`,{className:`bg-muted/25 text-foreground/90`,children:(0,F.jsx)(`tr`,{children:e.map((e,t)=>(0,F.jsx)(`th`,{className:`border-b border-border px-3 py-2 font-semibold`,children:L(e,`${a}-th-${t}`)},`${a}-th-${t}`))})}),(0,F.jsx)(`tbody`,{children:i.map((t,n)=>(0,F.jsx)(`tr`,{className:`border-t border-border/70`,children:e.map((e,r)=>(0,F.jsx)(`td`,{className:`px-3 py-2 align-top text-foreground/85`,children:L(t[r]??``,`${a}-td-${n}-${r}`)},`${a}-td-${n}-${r}`))},`${a}-row-${n}`))})]})},a));continue}if(/^\s{0,3}>\s?/.test(e)){let e=[];for(;r<t.length&&/^\s{0,3}>\s?/.test(t[r]);)e.push(t[r].replace(/^\s{0,3}>\s?/,``)),r+=1;n.push((0,F.jsx)(`blockquote`,{className:`my-4 border-l-2 border-border pl-4 text-muted-foreground/85`,children:R(e.join(`
|
|
6
|
+
`),`${a}-quote`)},a));continue}if(/^\s{0,3}[-*+]\s+/.test(e)){let e=[];for(;r<t.length&&/^\s{0,3}[-*+]\s+/.test(t[r]);)e.push(t[r].replace(/^\s{0,3}[-*+]\s+/,``)),r+=1;n.push((0,F.jsx)(`ul`,{className:`my-4 list-disc space-y-1 pl-6`,children:e.map((e,t)=>(0,F.jsx)(`li`,{children:L(e,`${a}-li-${t}`)},`${a}-li-${t}`))},a));continue}if(/^\s{0,3}\d+[.)]\s+/.test(e)){let e=[];for(;r<t.length&&/^\s{0,3}\d+[.)]\s+/.test(t[r]);)e.push(t[r].replace(/^\s{0,3}\d+[.)]\s+/,``)),r+=1;n.push((0,F.jsx)(`ol`,{className:`my-4 list-decimal space-y-1 pl-6`,children:e.map((e,t)=>(0,F.jsx)(`li`,{children:L(e,`${a}-li-${t}`)},`${a}-li-${t}`))},a));continue}let s=[];for(;r<t.length&&t[r].trim()&&!B(t,r);)s.push(t[r].trim()),r+=1;n.push((0,F.jsx)(`p`,{className:`my-4 text-foreground/86`,children:L(s.join(` `),`${a}-p`)},a))}return n}function Le({path:e,content:t,language:n,mode:r,wordWrap:i=!1}){let a=(0,P.useMemo)(()=>V(t),[t]);return(0,F.jsx)(`div`,{className:`flex h-full min-h-0 flex-col bg-background`,children:(0,F.jsx)(`div`,{className:`min-h-0 flex-1`,children:r===`source`?(0,F.jsx)(Ne,{path:e,content:t,language:n,wordWrap:i}):(0,F.jsx)(`div`,{className:`h-full overflow-auto bg-background`,children:(0,F.jsx)(`article`,{className:`quickforge-markdown-reader mx-auto max-w-3xl px-8 py-7 text-sm leading-7 text-foreground/88`,children:a.length?a:(0,F.jsx)(`p`,{className:`text-muted-foreground/70`,children:`This Markdown file is empty.`})})})})})}function Re({path:e,oldContent:t,newContent:n,language:r,status:i}){let a=we(),o=Me();return(0,F.jsx)(N,{original:t,modified:n,language:r,theme:a===`dark`?`vs-dark`:`vs`,options:{readOnly:!0,contextmenu:!1,automaticLayout:!0,renderSideBySide:!0,minimap:{enabled:!1},fontFamily:getComputedStyle(document.documentElement).getPropertyValue(`--font-mono`).trim()||`ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace`,fontSize:o.fontSize,lineHeight:o.lineHeight,scrollBeyondLastLine:!1,ignoreTrimWhitespace:!1,folding:!1,glyphMargin:!1,scrollbar:{verticalScrollbarSize:8,horizontalScrollbarSize:8}}},`${i}:${e}`)}function ze(e,t){let n=e.replace(/\r\n?/g,`
|
|
7
|
+
`).split(`
|
|
8
|
+
`),r=t.replace(/\r\n?/g,`
|
|
9
|
+
`).split(`
|
|
10
|
+
`),i=n.length,a=r.length;if(i*a>4e6)return;let o=Array(a+1).fill(0),s=Array(a+1).fill(0);for(let e=1;e<=i;e++){let t=n[e-1];for(let e=1;e<=a;e++)s[e]=t===r[e-1]?o[e-1]+1:Math.max(o[e],s[e-1]);let i=o;o=s,s=i}let c=o[a];return{added:a-c,removed:i-c}}var Be=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ef5350'%20d='M16%202a14%2014%200%201%200%2014%2014A14%2014%200%200%200%2016%202m6%2010h-4v8a4%204%200%201%201-4-4%203.96%203.96%200%200%201%202%20.555V8h6Z'/%3e%3c/svg%3e`,Ve=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%230288d1'%20d='M19.563%2022A5.57%205.57%200%200%201%2014%2016.437v-2.873A5.57%205.57%200%200%201%2019.563%208H24V2h-4.437A11.563%2011.563%200%200%200%208%2013.563v2.873A11.564%2011.564%200%200%200%2019.563%2028H24v-6Z'/%3e%3c/svg%3e`,He=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%23ff5722'%20d='M2%202a1%201%200%200%200-1%201v7a1%201%200%200%200%201%201h6v3l2-1.25L12%2014v-3h2a1%201%200%200%200%201-1V3a1%201%200%200%200-1-1Zm0%201h4v1H2Zm6%200%202%201.25L12%203v2.5l2%201-2%201V10l-2-1.25L8%2010V7.5l-2-1%202-1zM2%205h3v1H2Zm0%202h3v1H2Zm0%202h4v1H2Z'/%3e%3c/svg%3e`,Ue=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%23ff7043'%20d='M2%202a1%201%200%200%200-1%201v10c0%20.554.446%201%201%201h12c.554%200%201-.446%201-1V3a1%201%200%200%200-1-1zm0%203h12v8H2zm1%202%202%202-2%202%201%201%203-3-3-3zm5%203.5V12h5v-1.5z'/%3e%3c/svg%3e`,We=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%230288d1'%20d='M28%2014v-4h-2v4h-6v-4h-2v4h-4v2h4v4h2v-4h6v4h2v-4h4v-2z'/%3e%3cpath%20fill='%230288d1'%20d='M13.563%2022A5.57%205.57%200%200%201%208%2016.437v-2.873A5.57%205.57%200%200%201%2013.563%208H18V2h-4.437A11.563%2011.563%200%200%200%202%2013.563v2.873A11.564%2011.564%200%200%200%2013.563%2028H18v-6Z'/%3e%3c/svg%3e`,Ge=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%230288d1'%20d='M30%2014v-2h-2V8h-2v4h-2V8h-2v4h-2v2h2v2h-2v2h2v4h2v-4h2v4h2v-4h2v-2h-2v-2Zm-4%202h-2v-2h2Zm-12.437%206A5.57%205.57%200%200%201%208%2016.437v-2.873A5.57%205.57%200%200%201%2013.563%208H18V2h-4.437A11.563%2011.563%200%200%200%202%2013.563v2.873A11.564%2011.564%200%200%200%2013.563%2028H18v-6Z'/%3e%3c/svg%3e`,Ke=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%237e57c2'%20d='M20%2018h-2v-2h-2v2c0%20.193%200%20.703%201.254%201.033A3.345%203.345%200%200%201%2020%2022h2v2h2v-2c0-.388-.562-.851-1.254-1.034C20.356%2020.34%2020%2018.84%2020%2018m-3.254%202.966C14.356%2020.34%2014%2018.84%2014%2018h-2v-2h-2v8h2v-2h4v2h2v-2c0-.388-.562-.851-1.254-1.034'/%3e%3cpath%20fill='%237e57c2'%20d='M24%204H4v20a4%204%200%200%200%204%204h16.16A3.84%203.84%200%200%200%2028%2024.16V8a4%204%200%200%200-4-4m2%2014h-2v-2h-2v2c0%20.193%200%20.703%201.254%201.033A3.345%203.345%200%200%201%2026%2022v2a2%202%200%200%201-2%202h-2a2%202%200%200%201-2-2%202%202%200%200%201-2%202h-2a2%202%200%200%201-2-2%202%202%200%200%201-2%202h-2a2%202%200%200%201-2-2v-8a2%202%200%200%201%202-2h2a2%202%200%200%201%202%202%202%202%200%200%201%202-2h2a2%202%200%200%201%202%202%202%202%200%200%201%202-2h2a2%202%200%200%201%202%202Z'/%3e%3c/svg%3e`,qe=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ffca28'%20d='M16%2024c-5.525%200-10-.9-10-2v4c0%201.1%204.475%202%2010%202s10-.9%2010-2v-4c0%201.1-4.475%202-10%202m0-8c-5.525%200-10-.9-10-2v4c0%201.1%204.475%202%2010%202s10-.9%2010-2v-4c0%201.1-4.475%202-10%202m0-12C10.477%204%206%204.895%206%206v4c0%201.1%204.475%202%2010%202s10-.9%2010-2V6c0-1.105-4.477-2-10-2'/%3e%3c/svg%3e`,Je=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%230288d1'%20d='M21.81%2010.25c-.06-.04-.56-.43-1.64-.43-.28%200-.56.03-.84.08-.21-1.4-1.38-2.11-1.43-2.14l-.29-.17-.18.27c-.24.36-.43.77-.51%201.19-.2.8-.08%201.56.33%202.21-.49.28-1.29.35-1.46.35H2.62c-.34%200-.62.28-.62.63%200%201.15.18%202.3.58%203.38.45%201.19%201.13%202.07%202%202.61.98.6%202.59.94%204.42.94.79%200%201.61-.07%202.42-.22%201.12-.2%202.2-.59%203.19-1.16A8.3%208.3%200%200%200%2016.78%2016c1.05-1.17%201.67-2.5%202.12-3.65h.19c1.14%200%201.85-.46%202.24-.85.26-.24.45-.53.59-.87l.08-.24zm-17.96.99h1.76c.08%200%20.16-.07.16-.16V9.5c0-.08-.07-.16-.16-.16H3.85c-.09%200-.16.07-.16.16v1.58c.01.09.07.16.16.16m2.43%200h1.76c.08%200%20.16-.07.16-.16V9.5c0-.08-.07-.16-.16-.16H6.28c-.09%200-.16.07-.16.16v1.58c.01.09.07.16.16.16m2.47%200h1.75c.1%200%20.17-.07.17-.16V9.5c0-.08-.06-.16-.17-.16H8.75c-.08%200-.15.07-.15.16v1.58c0%20.09.06.16.15.16m2.44%200h1.77c.08%200%20.15-.07.15-.16V9.5c0-.08-.06-.16-.15-.16h-1.77c-.08%200-.15.07-.15.16v1.58c0%20.09.07.16.15.16M6.28%209h1.76c.08%200%20.16-.09.16-.18V7.25c0-.09-.07-.16-.16-.16H6.28c-.09%200-.16.06-.16.16v1.57c.01.09.07.18.16.18m2.47%200h1.75c.1%200%20.17-.09.17-.18V7.25c0-.09-.06-.16-.17-.16H8.75c-.08%200-.15.06-.15.16v1.57c0%20.09.06.18.15.18m2.44%200h1.77c.08%200%20.15-.09.15-.18V7.25c0-.09-.07-.16-.15-.16h-1.77c-.08%200-.15.06-.15.16v1.57c0%20.09.07.18.15.18m0-2.28h1.77c.08%200%20.15-.07.15-.16V5c0-.1-.07-.17-.15-.17h-1.77c-.08%200-.15.06-.15.17v1.56c0%20.08.07.16.15.16m2.46%204.52h1.76c.09%200%20.16-.07.16-.16V9.5c0-.08-.07-.16-.16-.16h-1.76c-.08%200-.15.07-.15.16v1.58c0%20.09.07.16.15.16'/%3e%3c/svg%3e`,Ye=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2024%2024'%3e%3cpath%20d='M0%200h24v24H0z'/%3e%3cpath%20fill='%2342a5f5'%20d='M8%2016h8v2H8zm0-4h8v2H8zm6-10H6c-1.1%200-2%20.9-2%202v16c0%201.1.89%202%201.99%202H18c1.1%200%202-.9%202-2V8zm4%2018H6V4h7v5h5z'/%3e%3c/svg%3e`,H=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%233f51b5'%20d='M22.713%204H9.287a.5.5%200%200%200-.432.248l-6.708%2011.5a.5.5%200%200%200%200%20.504l6.708%2011.5a.5.5%200%200%200%20.432.248h13.426a.5.5%200%200%200%20.432-.248l6.708-11.5a.5.5%200%200%200%200-.504l-6.708-11.5A.5.5%200%200%200%2022.713%204m-6.937%2020.888-7.5-3.75A.5.5%200%200%201%208%2020.691v-9.382a.5.5%200%200%201%20.276-.447l7.5-3.75a.5.5%200%200%201%20.448%200l7.5%203.75a.5.5%200%200%201%20.276.447v9.382a.5.5%200%200%201-.276.447l-7.5%203.75a.5.5%200%200%201-.448%200'/%3e%3cpath%20fill='%237986cb'%20d='M22%2019.441v-6.882a.5.5%200%200%200-.276-.447l-5.5-2.75a.5.5%200%200%200-.448%200l-5.5%202.75a.5.5%200%200%200-.276.447v6.882a.5.5%200%200%200%20.276.447l5.5%202.75a.5.5%200%200%200%20.448%200l5.5-2.75a.5.5%200%200%200%20.276-.447'/%3e%3c/svg%3e`,Xe=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23f44336'%20d='M24%2028h4L18%204h-4L4%2028h4l8-19.422'/%3e%3cpath%20fill='%23f44336'%20d='M8%2020h16v4H8z'/%3e%3c/svg%3e`,Ze=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23e64a19'%20d='M13.172%202.828%2011.78%204.22l1.91%201.91%202%202A2.986%202.986%200%200%201%2020%2010.81a3.25%203.25%200%200%201-.31%201.31l2.06%202a2.68%202.68%200%200%201%203.37.57%202.86%202.86%200%200%201%20.88%202.117%203.02%203.02%200%200%201-.856%202.109A2.9%202.9%200%200%201%2023%2019.81a2.93%202.93%200%200%201-2.13-.87%202.694%202.694%200%200%201-.56-3.38l-2-2.06a3%203%200%200%201-.31.12V20a3%203%200%200%201%201.44%201.09%202.92%202.92%200%200%201%20.56%201.72%202.88%202.88%200%200%201-.878%202.128%202.98%202.98%200%200%201-2.048.871%202.981%202.981%200%200%201-2.514-4.719A3%203%200%200%201%2016%2020v-6.38a2.96%202.96%200%200%201-1.44-1.09%202.9%202.9%200%200%201-.56-1.72%202.9%202.9%200%200%201%20.31-1.31l-3.9-3.9-7.579%207.572a4%204%200%200%200-.001%205.658l10.342%2010.342a4%204%200%200%200%205.656%200l10.344-10.344a4%204%200%200%200%200-5.656L18.828%202.828a4%204%200%200%200-5.656%200'/%3e%3c/svg%3e`,Qe=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%2300acc1'%20d='M2%2012h4v2H2zm-2%204h6v2H0zm4%204h2v2H4zm16.954-5H14v3h3.239a4.42%204.42%200%200%201-3.531%202%202.65%202.65%200%200%201-2.053-.858%202.86%202.86%200%200%201-.628-2.28A4.515%204.515%200%200%201%2015.292%2013a2.73%202.73%200%200%201%201.749.584l2.962-1.185A5.6%205.6%200%200%200%2015.292%2010a7.526%207.526%200%200%200-7.243%206.5%205.614%205.614%200%200%200%205.659%206.5%207.526%207.526%200%200%200%207.243-6.5%206.4%206.4%200%200%200%20.003-1.5'/%3e%3cpath%20fill='%2300acc1'%20d='M26.292%2010a7.526%207.526%200%200%200-7.243%206.5%205.614%205.614%200%200%200%205.659%206.5%207.526%207.526%200%200%200%207.243-6.5%205.614%205.614%200%200%200-5.659-6.5m2.681%206.137A4.515%204.515%200%200%201%2024.708%2020a2.65%202.65%200%200%201-2.053-.858%202.86%202.86%200%200%201-.628-2.28A4.515%204.515%200%200%201%2026.292%2013a2.65%202.65%200%200%201%202.053.858%202.86%202.86%200%200%201%20.628%202.28Z'/%3e%3c/svg%3e`,U=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23e65100'%20d='m4%204%202%2022%2010%202%2010-2%202-22Zm19.72%207H11.28l.29%203h11.86l-.802%209.335L15.99%2025l-6.635-1.646L8.93%2019h3.02l.19%202%203.86.77%203.84-.77.29-4H8.84L8%208h16Z'/%3e%3c/svg%3e`,$e=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%2326a69a'%20d='M8.5%206h4l-4-4zM3.875%201H9.5l4%204v8.6c0%20.773-.616%201.4-1.375%201.4h-8.25c-.76%200-1.375-.627-1.375-1.4V2.4c0-.777.612-1.4%201.375-1.4M4%2013.6h8V8l-2.625%202.8L8%209.4zm1.25-7.7c-.76%200-1.375.627-1.375%201.4s.616%201.4%201.375%201.4c.76%200%201.375-.627%201.375-1.4S6.009%205.9%205.25%205.9'/%3e%3c/svg%3e`,et=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23f44336'%20d='M4%2026h24v2H4zM28%204H7a1%201%200%200%200-1%201v13a4%204%200%200%200%204%204h10a4%204%200%200%200%204-4v-4h4a2%202%200%200%200%202-2V6a2%202%200%200%200-2-2m0%208h-4V6h4Z'/%3e%3c/svg%3e`,tt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%23ffca28'%20d='M2%202v12h12V2zm6%206h1v4a1.003%201.003%200%200%201-1%201H7a1.003%201.003%200%200%201-1-1v-1h1v1h1zm3%200h2v1h-2v1h1a1.003%201.003%200%200%201%201%201v1a1.003%201.003%200%200%201-1%201h-2v-1h2v-1h-1a1.003%201.003%200%200%201-1-1V9a1.003%201.003%200%200%201%201-1'/%3e%3c/svg%3e`,W=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cg%20fill='%23ffca28'%3e%3cpath%20d='M12%205v1h1v7H6v-1H5l-.069%202%209.069.001V5z'/%3e%3cpath%20d='M2%202v9h9V2zm3%203h1v4a1.003%201.003%200%200%201-1%201H4a1.003%201.003%200%200%201-1-1V8h1v1h1zm3%200h2v1H8v1h1a1.003%201.003%200%200%201%201%201v1a1.003%201.003%200%200%201-1%201H7V9h2V8H8a1.003%201.003%200%200%201-1-1V6a1.003%201.003%200%200%201%201-1'/%3e%3c/g%3e%3c/svg%3e`,nt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%20-960%20960%20960'%3e%3cpath%20fill='%23f9a825'%20d='M560-160v-80h120q17%200%2028.5-11.5T720-280v-80q0-38%2022-69t58-44v-14q-36-13-58-44t-22-69v-80q0-17-11.5-28.5T680-720H560v-80h120q50%200%2085%2035t35%2085v80q0%2017%2011.5%2028.5T840-560h40v160h-40q-17%200-28.5%2011.5T800-360v80q0%2050-35%2085t-85%2035zm-280%200q-50%200-85-35t-35-85v-80q0-17-11.5-28.5T120-400H80v-160h40q17%200%2028.5-11.5T160-600v-80q0-50%2035-85t85-35h120v80H280q-17%200-28.5%2011.5T240-680v80q0%2038-22%2069t-58%2044v14q36%2013%2058%2044t22%2069v80q0%2017%2011.5%2028.5T280-240h120v80z'/%3e%3c/svg%3e`,rt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%2326a69a'%20d='M30%2014H17.738a8%208%200%201%200%200%204H24v4h4v-4h2Zm-20%205a3%203%200%201%201%203-3%203.003%203.003%200%200%201-3%203'/%3e%3c/svg%3e`,it=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20viewBox='0%200%2024%2024'%3e%3cdefs%3e%3clinearGradient%20id='a'%20x1='1.725'%20x2='22.185'%20y1='22.67'%20y2='1.982'%20gradientTransform='translate(1.306%201.129)scale(.89324)'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20offset='0'%20stop-color='%237c4dff'/%3e%3cstop%20offset='.5'%20stop-color='%23d500f9'/%3e%3cstop%20offset='1'%20stop-color='%23ef5350'/%3e%3c/linearGradient%3e%3c/defs%3e%3cpath%20fill='url(%23a)'%20d='M2.975%202.976v18.048h18.05v-.03l-4.478-4.511-4.48-4.515%204.48-4.515%204.443-4.477z'/%3e%3c/svg%3e`,at=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%230277bd'%20d='M8%203a2%202%200%200%200-2%202v4a2%202%200%200%201-2%202H3v2h1a2%202%200%200%201%202%202v4a2%202%200%200%200%202%202h2v-2H8v-5a2%202%200%200%200-2-2%202%202%200%200%200%202-2V5h2V3m6%200a2%202%200%200%201%202%202v4a2%202%200%200%200%202%202h1v2h-1a2%202%200%200%200-2%202v4a2%202%200%200%201-2%202h-2v-2h2v-5a2%202%200%200%201%202-2%202%202%200%200%201-2-2V5h-2V3z'/%3e%3c/svg%3e`,G=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%23ff5722'%20d='M8%201a5.5%205.5%200%200%200-4%209.26V15l4-1.5%204%201.5v-4.74A5.49%205.49%200%200%200%208%201m0%201.5a4%204%200%201%201%200%208%204%204%200%200%201%200-8m0%202a2%202%200%201%200%200%204%202%202%200%200%200%200-4'/%3e%3c/svg%3e`,ot=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ffd54f'%20d='M25%2012h-3V8a6%206%200%200%200-12%200v4H7a1%201%200%200%200-1%201v16a1%201%200%200%200%201%201h18a1%201%200%200%200%201-1V13a1%201%200%200%200-1-1M14%208a2%202%200%200%201%204%200v4h-4Zm2%2017a4%204%200%201%201%204-4%204%204%200%200%201-4%204'/%3e%3c/svg%3e`,K=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2024%2024'%3e%3cpath%20d='M0%200h24v24H0z'/%3e%3cpath%20fill='%23afb42b'%20d='M19%205v9h-5v5H5V5zm0-2H5c-1.1%200-2%20.9-2%202v14c0%201.1.9%202%202%202h10l6-6V5c0-1.1-.9-2-2-2m-7%2011H7v-2h5zm5-4H7V8h10z'/%3e%3c/svg%3e`,q=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ef5350'%20d='m29.5%2024.02-1.6-.92a4.4%204.4%200%200%200%20.09-.9A1.3%201.3%200%200%200%2028%2022a5.6%205.6%200%200%200-.1-1.1l1.6-.92a.493.493%200%200%200%20.18-.68l-1.5-2.6a.45.45%200%200%200-.18-.18V6.01a2.006%202.006%200%200%200-2-2H4a2.006%202.006%200%200%200-2%202V22a2.006%202.006%200%200%200%202%202h10.53l-.03.02a.493.493%200%200%200-.18.68l1.5%202.6a.493.493%200%200%200%20.68.18l1.6-.92a5.9%205.9%200%200%200%201.9%201.09v1.85a.495.495%200%200%200%20.5.5h3a.495.495%200%200%200%20.5-.5v-1.85a5.9%205.9%200%200%200%201.9-1.09l1.6.92a.493.493%200%200%200%20.68-.18l1.5-2.6a.493.493%200%200%200-.18-.68M24%2022.01a1.99%201.99%200%200%201-.88%201.65l-.18.11a2.04%202.04%200%200%201-1.88%200l-.18-.11a1.99%201.99%200%200%201-.88-1.65V22a2%202%200%200%201%20.88-1.66l.18-.11a2.04%202.04%200%200%201%201.88%200l.18.11A2%202%200%200%201%2024%2022Zm2-4.63-.1.06a5.9%205.9%200%200%200-1.9-1.09V14.5a.495.495%200%200%200-.5-.5h-3a.495.495%200%200%200-.5.5v1.85a5.9%205.9%200%200%200-1.9%201.09l-1.6-.92a.493.493%200%200%200-.68.18l-1.5%202.6a.493.493%200%200%200%20.18.68l1.6.92A5.6%205.6%200%200%200%2016%2022v.01L4%2022V10.01h22Z'/%3e%3c/svg%3e`,st=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%2342a5f5'%20d='m14%2010-4%203.5L6%2010H4v12h4v-6l2%202%202-2v6h4V10zm12%206v-6h-4v6h-4l6%208%206-8z'/%3e%3c/svg%3e`,ct=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%238bc34a'%20d='M16%2020.003v2h4a2%202%200%200%200%202-2v-2a2%202%200%200%200-2-2h-2v-2h4v-2h-4a2%202%200%200%200-2%202v2a2%202%200%200%200%202%202h2v2Z'/%3e%3cpath%20fill='%238bc34a'%20d='m16%203.003-12%207v14l4%202h6v-13.5a.5.5%200%200%200-.5-.5h-1a.5.5%200%200%200-.5.5v11.5H8l-2-1.034V11.15l10-5.833%2010%205.833v11.703l-10%205.833-1.745-1.022L13%2029.253l3%201.75%2012-7v-14Z'/%3e%3c/svg%3e`,lt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23e53935'%20d='M4%204v24h24V4Zm20%2020h-4V12h-4v12H8V8h16Z'/%3e%3c/svg%3e`,ut=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23ef5350'%20d='M13%209h5.5L13%203.5zM6%202h8l6%206v12a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V4a2%202%200%200%201%202-2m4.93%2010.44c.41.9.93%201.64%201.53%202.15l.41.32c-.87.16-2.07.44-3.34.93l-.11.04.5-1.04c.45-.87.78-1.66%201.01-2.4m6.48%203.81c.18-.18.27-.41.28-.66.03-.2-.02-.39-.12-.55-.29-.47-1.04-.69-2.28-.69l-1.29.07-.87-.58c-.63-.52-1.2-1.43-1.6-2.56l.04-.14c.33-1.33.64-2.94-.02-3.6a.85.85%200%200%200-.61-.24h-.24c-.37%200-.7.39-.79.77-.37%201.33-.15%202.06.22%203.27v.01c-.25.88-.57%201.9-1.08%202.93l-.96%201.8-.89.49c-1.2.75-1.77%201.59-1.88%202.12-.04.19-.02.36.05.54l.03.05.48.31.44.11c.81%200%201.73-.95%202.97-3.07l.18-.07c1.03-.33%202.31-.56%204.03-.75%201.03.51%202.24.74%203%20.74.44%200%20.74-.11.91-.3m-.41-.71.09.11c-.01.1-.04.11-.09.13h-.04l-.19.02c-.46%200-1.17-.19-1.9-.51.09-.1.13-.1.23-.1%201.4%200%201.8.25%201.9.35M7.83%2017c-.65%201.19-1.24%201.85-1.69%202%20.05-.38.5-1.04%201.21-1.69zm3.02-6.91c-.23-.9-.24-1.63-.07-2.05l.07-.12.15.05c.17.24.19.56.09%201.1l-.03.16-.16.82z'/%3e%3c/svg%3e`,dt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%231e88e5'%20d='M12%2018.08c-6.63%200-12-2.72-12-6.08s5.37-6.08%2012-6.08S24%208.64%2024%2012s-5.37%206.08-12%206.08m-5.19-7.95c.54%200%20.91.1%201.09.31.18.2.22.56.13%201.03-.1.53-.29.87-.58%201.09q-.42.33-1.29.33h-.87l.53-2.76zm-3.5%205.55h1.44l.34-1.75h1.23c.54%200%20.98-.06%201.33-.17.35-.12.67-.31.96-.58.24-.22.43-.46.58-.73.15-.26.26-.56.31-.88.16-.78.05-1.39-.33-1.82-.39-.44-.99-.65-1.82-.65H4.59zm7.25-8.33-1.28%206.58h1.42l.74-3.77h1.14c.36%200%20.6.06.71.18s.13.34.07.66l-.57%202.93h1.45l.59-3.07c.13-.62.03-1.07-.27-1.36-.3-.27-.85-.4-1.65-.4h-1.27L12%207.35zM18%2010.13c.55%200%20.91.1%201.09.31.18.2.22.56.13%201.03-.1.53-.29.87-.57%201.09-.29.22-.72.33-1.3.33h-.85l.5-2.76zm-3.5%205.55h1.44l.34-1.75h1.22c.55%200%201-.06%201.35-.17.35-.12.65-.31.95-.58.24-.22.44-.46.58-.73.15-.26.26-.56.32-.88.15-.78.04-1.39-.34-1.82-.36-.44-.99-.65-1.82-.65h-2.75z'/%3e%3c/svg%3e`,J=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23e64a19'%20d='M6%202h8l6%206v12a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V4a2%202%200%200%201%202-2m7%201.5V9h5.5zM8%2011v2h1v6H8v1h4v-1h-1v-2h2a3%203%200%200%200%203-3%203%203%200%200%200-3-3zm5%202a1%201%200%200%201%201%201%201%201%200%200%201-1%201h-2v-2z'/%3e%3c/svg%3e`,ft=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%2303a9f4'%20d='M29.07%206H7.677A1.535%201.535%200%200%200%206.24%207.113l-4.2%2017.774A.852.852%200%200%200%202.93%2026h21.393a1.535%201.535%200%200%200%201.436-1.113L29.96%207.112A.852.852%200%200%200%2029.07%206M8.626%2023.797a1.4%201.4%200%200%201-1.814-.31l-.007-.009a1.075%201.075%200%200%201%20.315-1.599l9.6-6.061-6.102-5.852-.01-.01a1.068%201.068%200%200%201%20.084-1.625l.037-.03a1.38%201.38%200%200%201%201.8.07l7.233%206.957a1.1%201.1%200%200%201%20.236.739%201.08%201.08%200%200%201-.412.79c-.074.04-.146.119-10.951%206.935ZM24%2022.94A1.135%201.135%200%200%201%2022.803%2024h-5.634a1.061%201.061%200%201%201%20.001-2.112h5.633A1.134%201.134%200%200%201%2024%2022.938Z'/%3e%3c/svg%3e`,pt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%23f44336'%20d='M2%208h4v1H2zm0%206h4v1H2zm9-10h3v1h-3zM2%202h3v1H2z'/%3e%3cpath%20fill='%23f9a825'%20d='M9%202h3v1H9zm1%204h4v1h-4zm-5%206h1v1H5zm-3-2h6v1H2z'/%3e%3cpath%20fill='%2326a69a'%20d='M2%2012h3v1H2zm7-4h5v1H9zM2%204h4v1H2zm3-2h4v1H5z'/%3e%3cpath%20fill='%23ba68c8'%20d='M2%206h3v1H2zm7-2h2v1H9zm-1%206h4v1H8z'/%3e%3c/svg%3e`,Y=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%230288d1'%20d='M9.86%202A2.86%202.86%200%200%200%207%204.86v1.68h4.29c.39%200%20.71.57.71.96H4.86A2.86%202.86%200%200%200%202%2010.36v3.781a2.86%202.86%200%200%200%202.86%202.86h1.18v-2.68a2.85%202.85%200%200%201%202.85-2.86h5.25c1.58%200%202.86-1.271%202.86-2.851V4.86A2.86%202.86%200%200%200%2014.14%202zm-.72%201.61c.4%200%20.72.12.72.71s-.32.891-.72.891c-.39%200-.71-.3-.71-.89s.32-.711.71-.711'/%3e%3cpath%20fill='%23fdd835'%20d='M17.959%207v2.68a2.85%202.85%200%200%201-2.85%202.859H9.86A2.85%202.85%200%200%200%207%2015.389v3.75a2.86%202.86%200%200%200%202.86%202.86h4.28A2.86%202.86%200%200%200%2017%2019.14v-1.68h-4.291c-.39%200-.709-.57-.709-.96h7.14A2.86%202.86%200%200%200%2022%2013.64V9.86A2.86%202.86%200%200%200%2019.14%207zM8.32%2011.513l-.004.004.038-.004zm6.54%207.276c.39%200%20.71.3.71.89a.71.71%200%200%201-.71.71c-.4%200-.72-.12-.72-.71s.32-.89.72-.89'/%3e%3c/svg%3e`,X=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%2300bcd4'%20d='M16%2012c7.444%200%2012%202.59%2012%204s-4.556%204-12%204-12-2.59-12-4%204.556-4%2012-4m0-2c-7.732%200-14%202.686-14%206s6.268%206%2014%206%2014-2.686%2014-6-6.268-6-14-6'/%3e%3cpath%20fill='%2300bcd4'%20d='M16%2014a2%202%200%201%200%202%202%202%202%200%200%200-2-2'/%3e%3cpath%20fill='%2300bcd4'%20d='M10.458%205.507c2.017%200%205.937%203.177%209.006%208.493%203.722%206.447%203.757%2011.687%202.536%2012.392a.9.9%200%200%201-.457.1c-2.017%200-5.938-3.176-9.007-8.492C8.814%2011.553%208.779%206.313%2010%205.608a.9.9%200%200%201%20.458-.1m-.001-2A2.87%202.87%200%200%200%209%203.875C6.13%205.532%206.938%2012.304%2010.804%2019c3.284%205.69%207.72%209.493%2010.74%209.493A2.87%202.87%200%200%200%2023%2028.124c2.87-1.656%202.062-8.428-1.804-15.124-3.284-5.69-7.72-9.493-10.74-9.493Z'/%3e%3cpath%20fill='%2300bcd4'%20d='M21.543%205.507a.9.9%200%200%201%20.457.1c1.221.706%201.186%205.946-2.536%2012.393-3.07%205.316-6.99%208.493-9.007%208.493a.9.9%200%200%201-.457-.1C8.779%2025.686%208.814%2020.446%2012.536%2014c3.07-5.316%206.99-8.493%209.007-8.493m0-2c-3.02%200-7.455%203.804-10.74%209.493C6.939%2019.696%206.13%2026.468%209%2028.124a2.87%202.87%200%200%200%201.457.369c3.02%200%207.455-3.804%2010.74-9.493C25.061%2012.304%2025.87%205.532%2023%203.876a2.87%202.87%200%200%200-1.457-.369'/%3e%3c/svg%3e`,mt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%230288d1'%20d='M16%2012c7.444%200%2012%202.59%2012%204s-4.556%204-12%204-12-2.59-12-4%204.556-4%2012-4m0-2c-7.732%200-14%202.686-14%206s6.268%206%2014%206%2014-2.686%2014-6-6.268-6-14-6'/%3e%3cpath%20fill='%230288d1'%20d='M16%2014a2%202%200%201%200%202%202%202%202%200%200%200-2-2'/%3e%3cpath%20fill='%230288d1'%20d='M10.458%205.507c2.017%200%205.937%203.177%209.006%208.493%203.722%206.447%203.757%2011.687%202.536%2012.392a.9.9%200%200%201-.457.1c-2.017%200-5.938-3.176-9.007-8.492C8.814%2011.553%208.779%206.313%2010%205.608a.9.9%200%200%201%20.458-.1m-.001-2A2.87%202.87%200%200%200%209%203.875C6.13%205.532%206.938%2012.304%2010.804%2019c3.284%205.69%207.72%209.493%2010.74%209.493A2.87%202.87%200%200%200%2023%2028.124c2.87-1.656%202.062-8.428-1.804-15.124-3.284-5.69-7.72-9.493-10.74-9.493Z'/%3e%3cpath%20fill='%230288d1'%20d='M21.543%205.507a.9.9%200%200%201%20.457.1c1.221.706%201.186%205.946-2.536%2012.393-3.07%205.316-6.99%208.493-9.007%208.493a.9.9%200%200%201-.457-.1C8.779%2025.686%208.814%2020.446%2012.536%2014c3.07-5.316%206.99-8.493%209.007-8.493m0-2c-3.02%200-7.455%203.804-10.74%209.493C6.939%2019.696%206.13%2026.468%209%2028.124a2.87%202.87%200%200%200%201.457.369c3.02%200%207.455-3.804%2010.74-9.493C25.061%2012.304%2025.87%205.532%2023%203.876a2.87%202.87%200%200%200-1.457-.369'/%3e%3c/svg%3e`,ht=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2016%2016'%3e%3cpath%20d='M0%200h24v24H0z'/%3e%3cpath%20fill='%2342a5f5'%20d='M8%201C4.136%201%201%204.136%201%208s3.136%207%207%207%207-3.136%207-7-3.136-7-7-7m1%2011H7V7.5h2zm0-6H7V4h2z'/%3e%3c/svg%3e`,Z=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23f44336'%20d='M18.041%203.177c2.24.382%202.879%201.919%202.843%203.527V6.67l-1.013%2013.266-13.132.897h.008c-1.093-.044-3.518-.151-3.634-3.545l1.217-2.222%202.462%205.74%202.097-6.77-.045.009.018-.018%206.85%202.186L13.945%209.3l6.53-.409-5.144-4.212%202.71-1.51v.009M3.113%2017.252v.017zM6.916%206.874c2.63-2.622%206.033-4.168%207.34-2.844%201.297%201.306-.072%204.523-2.702%207.135-2.666%202.613-6.015%204.248-7.322%202.933-1.306-1.324.036-4.612%202.675-7.224z'/%3e%3c/svg%3e`,gt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ff7043'%20d='m30%2012-4-2V6h-4l-2-4-4%202-4-2-2%204H6v4l-4%202%202%204-2%204%204%202v4h4l2%204%204-2%204%202%202-4h4v-4l4-2-2-4ZM6%2016a9.9%209.9%200%200%201%20.842-4H10v8H6.842A9.9%209.9%200%200%201%206%2016m10%2010a9.98%209.98%200%200%201-7.978-4H16v-2h-2v-2h4c.819.819.297%202.308%201.179%203.37a1.89%201.89%200%200%200%201.46.63h3.34A9.98%209.98%200%200%201%2016%2026m-2-12v-2h4a1%201%200%200%201%200%202Zm11.158%206H24a2.006%202.006%200%200%201-2-2%202%202%200%200%200-2-2%203%203%200%200%200%203-3q0-.08-.004-.161A3.115%203.115%200%200%200%2019.83%2010H8.022a9.986%209.986%200%200%201%2017.136%2010'/%3e%3c/svg%3e`,_t=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ec407a'%20d='M27.837%205.673a4.33%204.33%200%200%200-2.293-2.701c-2.362-1.261-6.11-1.298-9.548-.092a26.3%2026.3%200%200%200-8.76%204.966c-2.752%202.542-3.438%204.925-3.189%206.194.523%202.668%203.274%204.539%205.485%206.042.418.284.822.559%201.175.816-1.429.76-4.261%202.444-5.088%204.248a3.88%203.88%200%200%200-.118%203.332A2.37%202.37%200%200%200%206.869%2029.8a5.6%205.6%200%200%200%201.49.2%206.35%206.35%200%200%200%205.19-2.856%206.74%206.74%200%200%200%20.864-5.382%207.3%207.3%200%200%201%202.044-.03%203.92%203.92%200%200%201%202.816%201.311%201.82%201.82%200%200%201%20.423%201.262%201.55%201.55%200%200%201-.772%201.05c-.234.14-.586.355-.504.803.036.194.198.633.894.512a2.93%202.93%200%200%200%202.145-2.651%204%204%200%200%200-1.197-2.904%205.94%205.94%200%200%200-4.396-1.626%2010.6%2010.6%200%200%200-2.672.304%2020%2020%200%200%200-2.203-1.846c-1.712-1.3-3.33-2.529-3.235-4.26.125-2.263%202.468-4.532%206.964-6.744%204.016-1.976%207.254-2.037%208.944-1.438a2%202%200%200%201%201.204.883%202.77%202.77%200%200%201-.36%202.47%209.71%209.71%200%200%201-7.425%204.304%203.86%203.86%200%200%201-3.238-.757c-.278-.302-.593-.645-1.074-.383q-.565.31-.225%201.189a3.9%203.9%200%200%200%202.407%201.92%2011.7%2011.7%200%200%200%207.128-.671c3.527-1.35%206.681-5.202%205.756-8.787M11.895%2024.475a4%204%200%200%201-.192.468%204.5%204.5%200%200%201-.753%201.081%202.83%202.83%200%200%201-2.533%201.107c-.056-.032-.078-.146-.085-.193a3.28%203.28%200%200%201%201.076-2.284%2011.3%2011.3%200%200%201%202.644-1.933%203.85%203.85%200%200%201-.157%201.754'/%3e%3c/svg%3e`,vt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2024%2024'%3e%3cpath%20d='M0%200h24v24H0z'/%3e%3cpath%20fill='%2342a5f5'%20d='M19.43%2012.98c.04-.32.07-.64.07-.98s-.03-.66-.07-.98l2.11-1.65c.19-.15.24-.42.12-.64l-2-3.46a.5.5%200%200%200-.61-.22l-2.49%201c-.52-.4-1.08-.73-1.69-.98l-.38-2.65A.49.49%200%200%200%2014%202h-4c-.25%200-.46.18-.49.42l-.38%202.65c-.61.25-1.17.59-1.69.98l-2.49-1a.6.6%200%200%200-.18-.03c-.17%200-.34.09-.43.25l-2%203.46c-.13.22-.07.49.12.64l2.11%201.65c-.04.32-.07.65-.07.98s.03.66.07.98l-2.11%201.65c-.19.15-.24.42-.12.64l2%203.46a.5.5%200%200%200%20.61.22l2.49-1c.52.4%201.08.73%201.69.98l.38%202.65c.03.24.24.42.49.42h4c.25%200%20.46-.18.49-.42l.38-2.65c.61-.25%201.17-.59%201.69-.98l2.49%201q.09.03.18.03c.17%200%20.34-.09.43-.25l2-3.46c.12-.22.07-.49-.12-.64zm-1.98-1.71c.04.31.05.52.05.73s-.02.43-.05.73l-.14%201.13.89.7%201.08.84-.7%201.21-1.27-.51-1.04-.42-.9.68c-.43.32-.84.56-1.25.73l-1.06.43-.16%201.13-.2%201.35h-1.4l-.19-1.35-.16-1.13-1.06-.43c-.43-.18-.83-.41-1.23-.71l-.91-.7-1.06.43-1.27.51-.7-1.21%201.08-.84.89-.7-.14-1.13c-.03-.31-.05-.54-.05-.74s.02-.43.05-.73l.14-1.13-.89-.7-1.08-.84.7-1.21%201.27.51%201.04.42.9-.68c.43-.32.84-.56%201.25-.73l1.06-.43.16-1.13.2-1.35h1.39l.19%201.35.16%201.13%201.06.43c.43.18.83.41%201.23.71l.91.7%201.06-.43%201.27-.51.7%201.21-1.07.85-.89.7zM12%208c-2.21%200-4%201.79-4%204s1.79%204%204%204%204-1.79%204-4-1.79-4-4-4m0%206c-1.1%200-2-.9-2-2s.9-2%202-2%202%20.9%202%202-.9%202-2%202'/%3e%3c/svg%3e`,yt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ffb300'%20d='M29.168%2014.03a2.7%202.7%200%200%200-1.968-.83%202.51%202.51%200%200%200-1.929.8h-4.443l3.078-3.078a2.835%202.835%200%200%200%202.857-2.842%202.6%202.6%200%200%200-.831-1.969%202.82%202.82%200%200%200-2.014-.788%202.67%202.67%200%200%200-1.968.788%202.36%202.36%200%200%200-.812%201.922L18%2011.17V6.726a2.51%202.51%200%200%200%20.8-1.929%202.7%202.7%200%200%200-.832-1.968%202.745%202.745%200%200%200-3.936%200%202.7%202.7%200%200%200-.832%201.968%202.51%202.51%200%200%200%20.8%201.93v4.443l-3.138-3.138a2.36%202.36%200%200%200-.812-1.922%202.66%202.66%200%200%200-1.968-.788%202.83%202.83%200%200%200-2.014.788%202.6%202.6%200%200%200-.831%201.969%202.74%202.74%200%200%200%20.831%202.013%202.8%202.8%200%200%200%202.026.829l3.078%203.078H6.729a2.51%202.51%200%200%200-1.929-.8%202.7%202.7%200%200%200-1.968.831%202.745%202.745%200%200%200%200%203.937%202.7%202.7%200%200%200%201.968.832%202.51%202.51%200%200%200%201.929-.8h4.443l-3.078%203.077a2.835%202.835%200%200%200-2.857%202.842%202.6%202.6%200%200%200%20.831%201.969%202.82%202.82%200%200%200%202.014.788%202.67%202.67%200%200%200%201.968-.788%202.36%202.36%200%200%200%20.812-1.922L14%2020.827v4.444a2.51%202.51%200%200%200-.8%201.929%202.784%202.784%200%200%200%204.768%201.968A2.7%202.7%200%200%200%2018.8%2027.2a2.51%202.51%200%200%200-.8-1.929v-4.444l3.138%203.138a2.36%202.36%200%200%200%20.812%201.922%202.66%202.66%200%200%200%201.968.788%202.83%202.83%200%200%200%202.014-.788%202.6%202.6%200%200%200%20.831-1.969%202.74%202.74%200%200%200-.831-2.013%202.8%202.8%200%200%200-2.026-.829L20.828%2018h4.443a2.51%202.51%200%200%200%201.93.8%202.784%202.784%200%200%200%201.967-4.769Z'/%3e%3c/svg%3e`,bt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23ff6e40'%20d='M17.087%2019.721c-2.36%201.36-5.59%201.5-8.86.1a13.8%2013.8%200%200%201-6.23-5.32c.67.55%201.46%201%202.3%201.4%203.37%201.57%206.73%201.46%209.1%200-3.37-2.59-6.24-5.96-8.37-8.71-.45-.45-.78-1.01-1.12-1.51%208.28%206.05%207.92%207.59%202.41-1.01%204.89%204.94%209.43%207.74%209.43%207.74.16.09.25.16.36.22.1-.25.19-.51.26-.78.79-2.85-.11-6.12-2.08-8.81%204.55%202.75%207.25%207.91%206.12%2012.24-.03.11-.06.22-.05.39%202.24%202.83%201.64%205.78%201.35%205.22-1.21-2.39-3.48-1.65-4.62-1.17'/%3e%3c/svg%3e`,xt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%238bc34a'%20d='M6%202h8l6%206v12a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V4a2%202%200%200%201%202-2m7%201.5V9h5.5zm4%207.5h-4v2h1l-2%201.67L10%2013h1v-2H7v2h1l3%202.5L8%2018H7v2h4v-2h-1l2-1.67L14%2018h-1v2h4v-2h-1l-3-2.5%203-2.5h1z'/%3e%3c/svg%3e`,St=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%234db6ac'%20d='M23.5%2012H8c.89-2.3%204.02-4%207.75-4s6.86%201.7%207.75%204M14%2012h15.5c-.89%202.3-4.02%204-7.75%204s-6.86-1.7-7.75-4m3.5%208H2c.89-2.3%204.02-4%207.75-4s6.86%201.7%207.75%204M8%2020h15.5c-.89%202.3-4.02%204-7.75%204S8.89%2022.3%208%2020'/%3e%3c/svg%3e`,Ct=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ffca28'%20d='M20%204v2h-2v4.531l.264.461%207.473%2013.078a2%202%200%200%201%20.263.992V26a2%202%200%200%201-2%202H8a2%202%200%200%201-2-2v-.938a2%202%200%200%201%20.264-.992l7.473-13.078.263-.46V6h-2V4zm0-2h-8a2%202%200%200%200-2%202v2a2%202%200%200%200%202%202v2L4.527%2023.078A4%204%200%200%200%204%2025.062V26a4%204%200%200%200%204%204h16a4%204%200%200%200%204-4v-.938a4%204%200%200%200-.527-1.984L20%2010V8a2%202%200%200%200%202-2V4a2%202%200%200%200-2-2'/%3e%3ccircle%20cx='17'%20cy='17'%20r='1'%20fill='%23ffca28'/%3e%3cpath%20fill='%23ffca28'%20d='M19.72%2020.715a1%201%200%200%200-1.134-.318%205%205%200%200%201-1.18.262%203.95%203.95%200%200%201-1.862-.292%202.74%202.74%200%200%200-3.371.489%202%202%200%200%200-.237.35L10%2024h12Z'/%3e%3c/svg%3e`,wt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%2300bcd4'%20d='M20%204v2h-2v4.531l.264.461%207.473%2013.078a2%202%200%200%201%20.263.992V26a2%202%200%200%201-2%202H8a2%202%200%200%201-2-2v-.938a2%202%200%200%201%20.264-.992l7.473-13.078.263-.46V6h-2V4zm0-2h-8a2%202%200%200%200-2%202v2a2%202%200%200%200%202%202v2L4.527%2023.078A4%204%200%200%200%204%2025.062V26a4%204%200%200%200%204%204h16a4%204%200%200%200%204-4v-.938a4%204%200%200%200-.527-1.984L20%2010V8a2%202%200%200%200%202-2V4a2%202%200%200%200-2-2'/%3e%3ccircle%20cx='17'%20cy='17'%20r='1'%20fill='%2300bcd4'/%3e%3cpath%20fill='%2300bcd4'%20d='M19.72%2020.715a1%201%200%200%200-1.134-.318%205%205%200%200%201-1.18.262%203.95%203.95%200%200%201-1.862-.292%202.74%202.74%200%200%200-3.371.489%202%202%200%200%200-.237.35L10%2024h12Z'/%3e%3c/svg%3e`,Tt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%230288d1'%20d='M20%204v2h-2v4.531l.264.461%207.473%2013.078a2%202%200%200%201%20.263.992V26a2%202%200%200%201-2%202H8a2%202%200%200%201-2-2v-.938a2%202%200%200%201%20.264-.992l7.473-13.078.263-.46V6h-2V4zm0-2h-8a2%202%200%200%200-2%202v2a2%202%200%200%200%202%202v2L4.527%2023.078A4%204%200%200%200%204%2025.062V26a4%204%200%200%200%204%204h16a4%204%200%200%200%204-4v-.938a4%204%200%200%200-.527-1.984L20%2010V8a2%202%200%200%200%202-2V4a2%202%200%200%200-2-2'/%3e%3ccircle%20cx='17'%20cy='17'%20r='1'%20fill='%230288d1'/%3e%3cpath%20fill='%230288d1'%20d='M19.72%2020.715a1%201%200%200%200-1.134-.318%205%205%200%200%201-1.18.262%203.95%203.95%200%200%201-1.862-.292%202.74%202.74%200%200%200-3.371.489%202%202%200%200%200-.237.35L10%2024h12Z'/%3e%3c/svg%3e`,Et=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%23cfd8dc'%20d='M4%206V4h8v2H9v7H7V6z'/%3e%3cpath%20fill='%23ef5350'%20d='M4%201v1H2v12h2v1H1V1zm8%200v1h2v12h-2v1h3V1z'/%3e%3c/svg%3e`,Dt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23757575'%20d='M15%202H6a2.006%202.006%200%200%200-2%202v22a2.006%202.006%200%200%200%202%202h6v-4H6v-2h6v-2H6v-2h6v-2H6v-2h6v-2h2V4l8%208h2v-1Z'%20data-mit-no-recolor='true'/%3e%3cpath%20fill='%230288d1'%20d='M12%2012v18h18V12Zm8%206h-2v8h-2v-8h-2v-2h6Zm8%200h-4v2h2a2.006%202.006%200%200%201%202%202v2a2.006%202.006%200%200%201-2%202h-4v-2h4v-2h-2a2.006%202.006%200%200%201-2-2v-2a2.006%202.006%200%200%201%202-2h4Z'/%3e%3c/svg%3e`,Ot=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xml:space='preserve'%20viewBox='0%200%2016%2016'%3e%3cpath%20fill='%230288d1'%20d='M2%202v12h12V2zm4%206h3v1H8v4H7V9H6zm5%200h2v1h-2v1h1a1.003%201.003%200%200%201%201%201v1a1.003%201.003%200%200%201-1%201h-2v-1h2v-1h-1a1.003%201.003%200%200%201-1-1V9a1.003%201.003%200%200%201%201-1'/%3e%3c/svg%3e`,kt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cg%20fill='%230288d1'%3e%3cpath%20d='M2%202v12h12V2zm1%201h10v10H3z'/%3e%3cpath%20d='M5%207v1h1v4h1V8h1V7zm5%200a1.003%201.003%200%200%200-1%201v1a1.003%201.003%200%200%200%201%201h1v1H9v1h2a1.003%201.003%200%200%200%201-1v-1a1.003%201.003%200%200%200-1-1h-1V8h2V7z'/%3e%3c/g%3e%3c/svg%3e`,At=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23ff9800'%20d='m24%206%202%206h-4l-2-6h-3l2%206h-4l-2-6h-3l2%206H8L6%206H5a3%203%200%200%200-3%203v14a3%203%200%200%200%203%203h22a3%203%200%200%200%203-3V6Z'/%3e%3c/svg%3e`,jt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%3e%3cpath%20fill='%23a0f'%20d='M29.313%2012h-6.664a1.427%201.427%200%200%201-1.1-2.24l4.398-6.676A.703.703%200%200%200%2025.397%202H8.428a.62.62%200%200%200-.55.289l-5.77%208.627A.703.703%200%200%200%202.658%2012h8.175a1.427%201.427%200%200%201%201.099%202.24l-4.48%206.676A.702.702%200%200%200%208%2022l6.695.002A1.34%201.34%200%200%201%2016%2023.375v5.934a.652.652%200%200%200%201.168.433l12.694-16.586a.725.725%200%200%200-.55-1.156'/%3e%3c/svg%3e`,Mt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%2301579b'%20d='M6%202h8l6%206v12a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V4a2%202%200%200%201%202-2m7%201.5V9h5.5zM7%2013l1.5%207h2l1.5-3%201.5%203h2l1.5-7h1v-2h-4v2h1l-.9%204.2L13%2015h-2l-1.1%202.2L9%2013h1v-2H6v2z'/%3e%3c/svg%3e`,Nt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%238bc34a'%20d='M13%209h5.5L13%203.5zM6%202h8l6%206v12a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V4c0-1.11.89-2%202-2m.12%2013.5%203.74%203.74%201.42-1.41-2.33-2.33%202.33-2.33-1.42-1.41zm11.16%200-3.74-3.74-1.42%201.41%202.33%202.33-2.33%202.33%201.42%201.41z'/%3e%3c/svg%3e`,Pt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23ff5252'%20d='M13%209h5.5L13%203.5zM6%202h8l6%206v12c0%201.1-.9%202-2%202H6c-1.1%200-2-.9-2-2V4c0-1.1.9-2%202-2m12%2016v-2H9v2zm-4-4v-2H6v2z'/%3e%3c/svg%3e`,Ft=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill='%23afb42b'%20d='M14%2017h-2v-2h-2v-2h2v2h2m0-6h-2v2h2v2h-2v-2h-2V9h2V7h-2V5h2v2h2m5-4H5c-1.11%200-2%20.89-2%202v14a2%202%200%200%200%202%202h14a2%202%200%200%200%202-2V5a2%202%200%200%200-2-2'/%3e%3c/svg%3e`,It=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23fbc02d'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23fffde7'%20d='M10%209H8v1h3V7h-1zm4%200V7h-1v3h3V9Zm-6%204h2v2h1v-3H8Zm5%200v2h1v-2h2v-1h-3z'/%3e%3c/svg%3e`,Lt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%238d6e63'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23d7ccc8'%20d='M7.5%2011c-.277%200-.5.223-.5.5v2c0%20.277.223.5.5.5h8c.277%200%20.5-.223.5-.5v-2c0-.277-.223-.5-.5-.5Z'/%3e%3c/svg%3e`,Rt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23c0ca33'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23f0f4c3'%20d='M6%2010h4v4H6zm5%200h4v4h-4zM6%205h4v4H6zm4.172%202L13%204.172%2015.829%207%2013%209.829z'/%3e%3c/svg%3e`,Q=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%2300acc1'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%2380deea'%20d='M11.5%2012.075A1.6%201.6%200%200%201%209.882%2010.5a1.62%201.62%200%201%201%201.62%201.575m3.437-1.138a4%204%200%200%200%20.032-.438%204%204%200%200%200-.032-.45l.976-.733a.223.223%200%200%200%20.056-.288l-.926-1.556a.23.23%200%200%200-.283-.1l-1.15.45a3.4%203.4%200%200%200-.783-.44l-.171-1.193A.23.23%200%200%200%2012.425%206h-1.85a.23.23%200%200%200-.231.189l-.171%201.193a3.4%203.4%200%200%200-.781.44l-1.152-.45a.23.23%200%200%200-.282.1l-.926%201.556a.22.22%200%200%200%20.056.288l.975.734a4%204%200%200%200-.032.45%204%204%200%200%200%20.032.437l-.975.746a.22.22%200%200%200-.056.288l.925%201.558a.235.235%200%200%200%20.283.099l1.152-.455a3.2%203.2%200%200%200%20.781.446l.171%201.192a.23.23%200%200%200%20.232.189h1.85a.23.23%200%200%200%20.232-.189l.17-1.192a3.4%203.4%200%200%200%20.783-.446l1.15.455a.24.24%200%200%200%20.284-.1l.924-1.557a.223.223%200%200%200-.055-.288Z'/%3e%3c/svg%3e`,zt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20viewBox='0%200%2016%2016'%3e%3cdefs%3e%3cpath%20id='a'%20fill='%23d1c4e9'%20d='M7%2010V9H6v4h1v-1h1v1a1%201%200%200%201-1%201H6a1%201%200%200%201-1-1V9a1%201%200%200%201%201-1h1a1%201%200%200%201%201%201v1Zm5%200V9a1%201%200%200%200-1-1h-1a1%201%200%200%200-1%201v1c0%20.42.179%201.17%201.373%201.483.346.092.627.323.627.517v1h-1v-1H9v1a1%201%200%200%200%201%201h1a1%201%200%200%200%201-1v-1a1.67%201.67%200%200%200-1.373-1.483C10%2010.352%2010%2010.097%2010%2010V9h1v1Zm4%200V9a1%201%200%200%200-1-1h-1a1%201%200%200%200-1%201v1c0%20.42.179%201.17%201.373%201.483.346.092.627.323.627.517v1h-1v-1h-1v1a1%201%200%200%200%201%201h1a1%201%200%200%200%201-1v-1a1.67%201.67%200%200%200-1.373-1.483C14%2010.352%2014%2010.097%2014%2010V9h1v1Z'/%3e%3c/defs%3e%3cpath%20id='folder'%20fill='%237e57c2'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cg%20id='motive'%3e%3cuse%20xlink:href='%23a'/%3e%3cuse%20xlink:href='%23a'/%3e%3c/g%3e%3c/svg%3e`,Bt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%230277bd'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23b3e5fc'%20d='M12%205H8.5a.5.5%200%200%200-.5.5v8a.5.5%200%200%200%20.5.5h6a.5.5%200%200%200%20.5-.5V8Zm0%208H9v-1h3zm2-2H9v-1h5zm-2.414-2.586V6L14%208.414Z'/%3e%3c/svg%3e`,Vt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23ff7043'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23ffccbc'%20d='m6.297%209.295%202.892-2.897.846.85a.99.99%200%200%200%20.465%201.116v2.772a1%201%200%200%200-.5.865%201.001%201.001%200%200%200%202.001%200%201%201%200%200%200-.5-.865V8.704l1.035%201.046a.6.6%200%200%200-.035.25%201.001%201.001%200%201%200%201.001-1.001.6.6%200%200%200-.25.035l-1.287-1.285a.99.99%200%200%200-.575-1.171%201.05%201.05%200%200%200-.64-.045l-.851-.846.396-.39a.987.987%200%200%201%201.41%200l3.998%203.998a.987.987%200%200%201%200%201.41l-3.998%203.998a.987.987%200%200%201-1.41%200l-3.998-3.998a.987.987%200%200%201%200-1.41'/%3e%3c/svg%3e`,Ht=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%237e57c2'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23d1c4e9'%20d='M12.5%205A1.5%201.5%200%200%200%2011%206.5a1.5%201.5%200%200%200%201%201.41V12a1%201%200%200%201-2%200v-1h1L9%209v3a2%202%200%200%200%204%200V7.91a1.5%201.5%200%200%200%201-1.41A1.5%201.5%200%200%200%2012.5%205m0%201a.5.5%200%201%201%200%201%20.5.5%200%200%201%200-1'/%3e%3c/svg%3e`,Ut=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23009688'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23b2dfdb'%20d='M12%205H8.5a.5.5%200%200%200-.5.5v8a.5.5%200%200%200%20.5.5h6a.5.5%200%200%200%20.5-.5V8Zm-2%203a1%201%200%201%201-1%201%201.005%201.005%200%200%201%201-1m4%205H9l2-2%201%201%202-2zm-2.414-4.586V6L14%208.414Z'/%3e%3c/svg%3e`,Wt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23c0ca33'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23f0f4c3'%20d='M11.5%208a1.5%201.5%200%200%200%20.002-3H11.5A1.5%201.5%200%200%200%2010%206.5%201.5%201.5%200%200%200%2011.5%208m0%201.987C10.387%208.947%208.523%207.996%207%208v5c1.595%200%203.425%201.002%204.5%202%201.113-1.039%202.978-2.002%204.5-2V8c-1.522-.003-3.387.947-4.5%201.986'/%3e%3c/svg%3e`,Gt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23039be5'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23b3e5fc'%20d='M11%205a5%205%200%201%200%205%205%205%205%200%200%200-5-5m3.459%203H12.98a8%208%200%200%200-.671-1.77A4.02%204.02%200%200%201%2014.459%208M11%206a7%207%200%200%201%20.945%202h-1.89A7%207%200%200%201%2011%206m-1.309.23A8%208%200%200%200%209.02%208H7.541a4.02%204.02%200%200%201%202.15-1.77M7.131%2011a3.85%203.85%200%200%201%200-2h1.704a7.8%207.8%200%200%200%200%202zm.41%201H9.02a8%208%200%200%200%20.671%201.77A4.02%204.02%200%200%201%207.541%2012M11%2014a7%207%200%200%201-.945-2h1.89A7%207%200%200%201%2011%2014m1.155-3h-2.31a6.7%206.7%200%200%201%200-2h2.31a6.7%206.7%200%200%201%200%202m.154%202.77A8%208%200%200%200%2012.98%2012h1.479a4.02%204.02%200%200%201-2.15%201.77m2.56-2.77h-1.704a7.8%207.8%200%200%200%200-2h1.704a3.85%203.85%200%200%201%200%202'/%3e%3c/svg%3e`,Kt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23fbc02d'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23fff9c4'%20d='M9.5%206a.5.5%200%200%200-.5.5v6a.5.5%200%200%200%20.5.5h6a.5.5%200%200%200%20.5-.5v-6a.5.5%200%200%200-.5-.5zm.5%201h5v1h-5zM7%208v6.5a.5.5%200%200%200%20.5.5H14v-1H8V8zm3%201h5v1h-5zm0%202h3v1h-3z'/%3e%3c/svg%3e`,qt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%2343a047'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23c8e6c9'%20d='M8.707%207.293%2010%206H6v4l1.293-1.293%202.455%202.455a.85.85%200%200%201%20.252.608V14h2v-2.23a2.84%202.84%200%200%200-.838-2.022ZM14.68%206l-2.805%202.465.285.285a2.8%202.8%200%200%201%20.78%201.445L16%207.505Z'/%3e%3c/svg%3e`,Jt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23546e7a'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23cfd8dc'%20d='M14%206h-3a2%202%200%200%200-2%202v4h1V8h4v4.947a1.04%201.04%200%200%201-.832%201.04A1%201%200%200%201%2012%2013H8a2%202%200%200%200%202%202h3a2%202%200%200%200%202-2V8h1a2%202%200%200%200-2-2'/%3e%3c/svg%3e`,Yt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%23fbc02d'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23fffde7'%20d='M7%207.5v2a.5.5%200%200%200%20.5.5h8a.5.5%200%200%200%20.5-.5v-2a.5.5%200%200%200-.5-.5h-8a.5.5%200%200%200-.5.5M10%209H8V8h2zm2%200h-1V8h1zm-5%202.5v2a.5.5%200%200%200%20.5.5h8a.5.5%200%200%200%20.5-.5v-2a.5.5%200%200%200-.5-.5h-8a.5.5%200%200%200-.5.5m3%201.5H8v-1h2zm2%200h-1v-1h1z'/%3e%3c/svg%3e`,Xt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%234caf50'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23c8e6c9'%20d='M9.225%2015a.5.5%200%200%201-.12-.014.57.568%200%200%201-.414-.661l1.549-7.872a.566.565%200%200%201%20.254-.372.53.53%200%200%201%20.4-.067.57.57%200%200%201%20.415.662l-1.552%207.872a.56.56%200%200%201-.253.371.53.53%200%200%201-.28.081m3.105-1h-.038a.54.54%200%200%201-.382-.206.583.582%200%200%201%20.057-.774l2.664-2.483-2.653-2.312a.583.582%200%200%201-.08-.772.54.54%200%200%201%20.377-.218.53.53%200%200%201%20.406.129l3.126%202.727a.579.578%200%200%201%20.002.862l-3.114%202.904a.536.535%200%200%201-.365.144zm-4.661%200a.536.535%200%200%201-.365-.146L4.186%2010.95a.58.58%200%200%201-.005-.846l.01-.01%203.128-2.726a.516.515%200%200%201%20.4-.13.54.54%200%200%201%20.38.218.583.582%200%200%201-.08.773l-2.65%202.31%202.663%202.482a.579.578%200%200%201%20.056.774.536.535%200%200%201-.381.206z'/%3e%3c/svg%3e`,Zt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%2300bfa5'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23a7ffeb'%20d='M8%206v1h1v6a2%202%200%200%200%204%200V7h1V6Zm2.5%207a.5.5%200%201%201%20.5-.5.5.5%200%200%201-.5.5m1-2a.5.5%200%201%201%20.5-.5.5.5%200%200%201-.5.5m.5-2h-2V7h2z'/%3e%3c/svg%3e`,Qt=`data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2016%2016'%3e%3cpath%20id='folder'%20fill='%237cb342'%20d='m6.922%203.768-.644-.536A1%201%200%200%200%205.638%203H2a1%201%200%200%200-1%201v8a1%201%200%200%200%201%201h12a1%201%200%200%200%201-1V5a1%201%200%200%200-1-1H7.562a1%201%200%200%201-.64-.232'/%3e%3cpath%20id='motive'%20fill='%23dcedc8'%20d='M9.5%206a.5.5%200%200%200-.5.5v6a.5.5%200%200%200%20.5.5h6a.5.5%200%200%200%20.5-.5v-6a.5.5%200%200%200-.5-.5zM12%207h1v2h2v1h-2v2h-1v-2h-2V9h2zM7%208v6.5a.5.5%200%200%200%20.5.5H14v-1H8V8z'/%3e%3c/svg%3e`,$t=new Set([`png`,`jpg`,`jpeg`,`gif`,`ico`,`webp`,`bmp`,`avif`]),en=new Set([`zip`,`tar`,`gz`,`tgz`,`rar`,`7z`,`bz2`,`xz`]),tn=new Set([`csv`,`tsv`,`psv`,`xls`,`xlsx`,`xlsm`,`ods`]),nn=new Set([`aac`,`aiff`,`flac`,`m4a`,`mp3`,`ogg`,`opus`,`wav`,`wma`]),rn=new Set([`avi`,`flv`,`m4v`,`mkv`,`mov`,`mp4`,`mpeg`,`mpg`,`webm`,`wmv`]),an=new Set([`eot`,`otf`,`ttf`,`woff`,`woff2`]),on=new Set([`cer`,`cert`,`crt`,`der`,`p12`,`pfx`]),sn=new Set([`asc`,`key`,`pem`,`pub`]),cn=new Set([`doc`,`docx`,`odt`,`rtf`]),ln=new Set([`odp`,`pot`,`potx`,`pps`,`ppsx`,`ppt`,`pptx`]),un=new Set([`cfg`,`cnf`,`conf`,`config`,`ini`,`option`,`prefs`,`properties`,`props`,`settings`]);function dn(e){return e.replace(/\\/g,`/`)}function fn(e){let t=dn(e);return t.slice(t.lastIndexOf(`/`)+1)}function pn(e){let t=e.lastIndexOf(`.`);return t>0?e.slice(t+1):``}function mn(e){return/(?:^|[.\-_])(spec|test)\.[^.]+$/i.test(e)||/(?:^|[.\-_])tests?\.[^.]+$/i.test(e)}function hn(e){if(e===`readme`||e.startsWith(`readme.`))return`readme`;if(e===`license`||e.startsWith(`license.`)||e===`licence`||e.startsWith(`licence.`)||e===`copying`||e.startsWith(`copying.`))return`license`;if(e===`makefile`||e.startsWith(`makefile.`))return`makefile`;if(e===`dockerfile`||e.endsWith(`.dockerfile`)||e.startsWith(`docker-compose`)||e===`compose.yml`||e===`compose.yaml`)return`docker`;if(/^vite\.config\.(?:[cm]?[jt]s)$/.test(e))return`vite`;if(e===`package.json`||e===`package-lock.json`||e===`.nvmrc`||e===`.node-version`)return`nodejs`;if(e===`.npmignore`||e===`.npmrc`)return`npm`;if(e===`tsconfig.json`||e.startsWith(`tsconfig.`))return`tsconfig`;if(e===`eslint.config.js`||e===`eslint.config.mjs`||e===`eslint.config.cjs`||e===`eslint.config.ts`||e===`.eslintrc`||e.startsWith(`.eslintrc.`))return`eslint`;if(e===`.prettierrc`||e.startsWith(`.prettierrc.`)||e.startsWith(`prettier.config.`))return`prettier`;if(e.startsWith(`tailwind.config.`))return`tailwindcss`;if(e===`.gitignore`||e===`.gitattributes`||e===`.gitmodules`)return`git`;if(e===`.env`||e.startsWith(`.env.`))return`settings`;if(e.endsWith(`.lock`)||e.endsWith(`-lock.json`)||e.endsWith(`-lock.yaml`)||e.endsWith(`-lock.yml`))return`lock`}function gn(e){let t=fn(e).toLowerCase(),n=hn(t);if(n)return n;let r=pn(t);return r===`tsx`?mn(t)?`test-ts`:`react-ts`:r===`jsx`?mn(t)?`test-jsx`:`react`:r===`ts`?t.endsWith(`.d.ts`)?`typescript-def`:mn(t)?`test-ts`:`typescript`:r===`js`||r===`mjs`||r===`cjs`?mn(t)?`test-js`:`javascript`:t.endsWith(`.js.map`)||t.endsWith(`.mjs.map`)||t.endsWith(`.cjs.map`)?`javascript-map`:$t.has(r)?`image`:r===`svg`?`svg`:en.has(r)?`zip`:tn.has(r)?`table`:nn.has(r)?`audio`:rn.has(r)?`video`:an.has(r)?`font`:on.has(r)?`certificate`:sn.has(r)?`key`:cn.has(r)?`word`:ln.has(r)?`powerpoint`:un.has(r)?`settings`:r===`json`||r===`jsonc`?`json`:r===`html`||r===`htm`?`html`:r===`css`?`css`:r===`scss`?`sass`:r===`less`?`less`:r===`md`||r===`mdx`||r===`markdown`?`markdown`:r===`yml`||r===`yaml`?`yaml`:r===`toml`?`toml`:r===`xml`?`xml`:r===`sql`?`database`:r===`py`?`python`:r===`go`?`go`:r===`rs`?`rust`:r===`java`?`java`:r===`c`||r===`h`?`c`:r===`cpp`||r===`cc`||r===`cxx`||r===`hpp`?`cpp`:r===`cs`?`csharp`:r===`php`?`php`:r===`rb`?`ruby`:r===`swift`?`swift`:r===`kt`||r===`kts`?`kotlin`:r===`ps1`?`powershell`:r===`sh`||r===`bash`||r===`zsh`?`console`:r===`pdf`?`pdf`:r===`log`?`log`:`document`}function _n(e,t=!1){let n=fn(e).toLowerCase();return n===`.git`||n===`.svn`||n===`.hg`||n===`git`?`folder-git`:n===`src`||n===`source`||n===`sources`?`folder-src`:n===`components`||n===`widgets`||n===`fragments`?`folder-components`:n===`test`||n===`tests`||n===`__test__`||n===`__tests__`||n===`spec`||n===`specs`?`folder-test`:n===`doc`||n===`docs`||n===`documentation`?`folder-docs`:n===`server`||n===`servers`||n===`backend`||n===`backends`?`folder-server`:n===`api`||n===`apis`||n===`restapi`?`folder-api`:n===`asset`||n===`assets`||n===`resource`||n===`resources`||n===`static`?`folder-resource`:n===`image`||n===`images`||n===`img`||n===`imgs`||n===`icons`?`folder-images`:n===`public`||n===`www`||n===`wwwroot`?`folder-public`:n===`config`||n===`configs`||n===`configuration`||n===`.config`?`folder-config`:n===`lib`||n===`libs`||n===`library`||n===`vendor`?`folder-lib`:n===`hook`||n===`hooks`?`folder-hook`:n===`util`||n===`utils`||n===`utility`||n===`utilities`?`folder-utils`:n===`route`||n===`routes`||n===`router`||n===`routers`?`folder-routes`:n===`script`||n===`scripts`||n===`scripting`?`folder-scripts`:n===`style`||n===`styles`||n===`stylesheet`||n===`stylesheets`||n===`css`?`folder-css`:`folder-base`}var vn={audio:Be,c:Ve,certificate:He,console:Ue,cpp:We,csharp:Ge,css:Ke,database:qe,docker:Je,document:Ye,eslint:H,font:Xe,git:Ze,go:Qe,html:U,image:$e,java:et,javascript:tt,"javascript-map":W,json:nt,key:rt,kotlin:it,less:at,license:G,lock:ot,log:K,makefile:q,markdown:st,nodejs:ct,npm:lt,pdf:ut,php:dt,powerpoint:J,powershell:ft,prettier:pt,python:Y,react:X,"react-ts":mt,readme:ht,ruby:Z,rust:gt,sass:_t,settings:vt,svg:yt,swift:bt,table:xt,tailwindcss:St,"test-js":Ct,"test-jsx":wt,"test-ts":Tt,toml:Et,tsconfig:Dt,typescript:Ot,"typescript-def":kt,video:At,vite:jt,word:Mt,xml:Nt,yaml:Pt,zip:Ft},yn={"folder-api":It,"folder-base":Lt,"folder-components":Rt,"folder-config":Q,"folder-css":zt,"folder-docs":Bt,"folder-git":Vt,"folder-hook":Ht,"folder-images":Ut,"folder-lib":Wt,"folder-public":Gt,"folder-resource":Kt,"folder-routes":qt,"folder-scripts":Jt,"folder-server":Yt,"folder-src":Xt,"folder-test":Zt,"folder-utils":Qt};function bn({src:e,className:t=`size-3.5`}){return(0,F.jsx)(`img`,{src:e,alt:``,"aria-hidden":`true`,draggable:!1,className:t})}function xn({path:e,className:t}){return(0,F.jsx)(bn,{src:vn[gn(e)],className:t})}function Sn({name:e,open:t,className:n}){return(0,F.jsx)(bn,{src:yn[_n(e,t)],className:n})}function Cn(e){let t=e?.trim();if(t){if(/^[a-zA-Z]:[\\/]/.test(t)||t.startsWith(`/`)&&!t.startsWith(`/api/`))return t;try{let e=new URL(t);return e.protocol===`file:`?decodeURIComponent(e.pathname):void 0}catch{return}}}function wn(e){if(e.kind===`browser`)return Cn(e.url);if(e.kind===`reader`)return(e.readerTabs?.find(t=>t.id===e.activeReaderTabId)??e.readerTabs?.[0])?.path}var Tn=3,En=5e7;function Dn(e){let t=e.replace(/\r\n/g,`
|
|
11
|
+
`).replace(/\r/g,`
|
|
12
|
+
`).split(`
|
|
13
|
+
`);return t.length>1&&t[t.length-1]===``&&t.pop(),t}function On(e,t){let n=Dn(e),r=Dn(t);if(n.length*r.length>En)return;let i=Array.from({length:n.length+1},()=>new Uint32Array(r.length+1));for(let e=n.length-1;e>=0;--e)for(let t=r.length-1;t>=0;--t)i[e][t]=n[e]===r[t]?i[e+1][t+1]+1:Math.max(i[e+1][t],i[e][t+1]);let a=[],o=0,s=0,c=1,l=1;for(;o<n.length||s<r.length;){if(o<n.length&&s<r.length&&n[o]===r[s]){a.push({kind:`context`,oldLine:c,newLine:l,text:n[o]}),o+=1,s+=1,c+=1,l+=1;continue}if(s<r.length&&(o>=n.length||i[o][s+1]>=i[o+1][s])){a.push({kind:`add`,newLine:l,text:r[s]}),s+=1,l+=1;continue}o<n.length&&(a.push({kind:`delete`,oldLine:c,text:n[o]}),o+=1,c+=1)}return a}function kn(e){let t=e.map(e=>e.kind!==`context`);e.forEach((n,r)=>{if(n.kind===`context`)return;let i=Math.max(0,r-Tn),a=Math.min(e.length-1,r+Tn);for(let e=i;e<=a;e+=1)t[e]=!0});let n=[],r=0,i=0;for(;r<e.length;){if(t[r]||e[r].kind!==`context`){n.push(e[r]),r+=1;continue}let a=r;for(;r<e.length&&!t[r]&&e[r].kind===`context`;)r+=1;let o=e.slice(a,r);n.push({kind:`collapsed`,id:`collapsed-${i++}-${a}`,count:o.length,rows:o})}return n}function An(e){return e===`add`?`bg-emerald-500/12 text-foreground`:e===`delete`?`bg-red-500/12 text-foreground`:`bg-background text-foreground/90`}function jn(e){return e===`add`?`+`:e===`delete`?`-`:` `}function Mn({row:e}){let t=e.kind===`delete`?e.oldLine:e.newLine??e.oldLine;return(0,F.jsxs)(`div`,{className:j(`grid w-max min-w-full grid-cols-[3rem_auto] text-[13px] leading-6`,An(e.kind)),children:[(0,F.jsx)(`span`,{className:j(`select-none pr-3 text-right font-mono`,e.kind===`delete`&&`text-red-600 dark:text-red-500`,e.kind===`add`&&`text-emerald-600 dark:text-emerald-500`,e.kind===`context`&&`text-muted-foreground/62`),children:t??``}),(0,F.jsxs)(`code`,{className:`whitespace-pre pr-4 font-mono`,children:[(0,F.jsx)(`span`,{className:j(`mr-3 select-none`,e.kind===`add`&&`text-emerald-600 dark:text-emerald-500`,e.kind===`delete`&&`text-red-600 dark:text-red-500`),children:jn(e.kind)}),e.text||` `]})]})}function Nn(e,t,n){let r=new Set(e[t]??[]);return r.has(n)?r.delete(n):r.add(n),{...e,[t]:[...r]}}function Pn({diff:e,loading:t,error:n}){let[r,i]=(0,P.useState)({}),a=e?`${e.path}\u0000${e.oldContent.length}\u0000${e.newContent.length}`:``,o=(0,P.useMemo)(()=>new Set(r[a]??[]),[a,r]),s=(0,P.useMemo)(()=>{if(!e)return;let t=On(e.oldContent,e.newContent);return t?kn(t):void 0},[e]);return t?(0,F.jsx)(`div`,{className:`border-t border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-3 py-4 text-sm text-muted-foreground/70`,children:k(`workspaceLoadingDiff`)}):n?(0,F.jsx)(`div`,{className:`border-t border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-3 py-4 text-sm text-destructive`,children:n}):e?s?s.length===0?(0,F.jsx)(`div`,{className:`border-t border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-3 py-4 text-sm text-muted-foreground/70`,children:k(`workspaceNoDiffPreview`)}):(0,F.jsx)(`div`,{className:`min-w-0 max-w-full overflow-hidden rounded-b-xl border-t border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background`,children:(0,F.jsx)(`div`,{className:`max-h-[28rem] min-w-0 overflow-auto pb-1`,children:(0,F.jsx)(`div`,{className:`w-max min-w-full py-2`,children:s.map(e=>{if(e.kind!==`collapsed`)return(0,F.jsx)(Mn,{row:e},`${e.kind}:${e.oldLine??``}:${e.newLine??``}:${e.text}`);let t=o.has(e.id);return(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`div`,{className:`grid w-full min-w-0 grid-cols-[3rem_minmax(0,1fr)] gap-1 py-1 pr-4`,children:[(0,F.jsx)(`button`,{type:`button`,className:`flex h-12 items-center justify-center rounded-lg bg-muted/60 text-muted-foreground/75 transition-colors hover:bg-muted/78 hover:text-foreground/80`,onClick:()=>{i(t=>Nn(t,a,e.id))},"aria-expanded":t,title:k(`workspaceUnmodifiedLines`,{count:e.count}),children:(0,F.jsx)(m,{className:j(`size-4 transition-transform`,t&&`rotate-180`)})}),(0,F.jsx)(`button`,{type:`button`,className:`flex h-12 items-center rounded-lg bg-muted/60 px-4 text-left text-base font-medium text-muted-foreground/80 transition-colors hover:bg-muted/78 hover:text-foreground/80`,onClick:()=>{i(t=>Nn(t,a,e.id))},"aria-expanded":t,children:k(`workspaceUnmodifiedLines`,{count:e.count})})]}),t?e.rows.map(t=>(0,F.jsx)(Mn,{row:t},`hidden:${e.id}:${t.oldLine}:${t.newLine}`)):null]},e.id)})})})}):(0,F.jsx)(`div`,{className:`border-t border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-3 py-4 text-sm text-muted-foreground/70`,children:k(`workspaceDiffTooLarge`)}):(0,F.jsx)(`div`,{className:`border-t border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-3 py-4 text-sm text-muted-foreground/70`,children:k(`workspaceNoDiffPreview`)})}function Fn(e){return k(e===`added`?`workspaceStatusAdded`:e===`deleted`?`workspaceStatusDeleted`:e===`renamed`?`workspaceStatusRenamed`:e===`untracked`?`workspaceStatusUntracked`:e===`conflicted`?`workspaceStatusConflict`:`workspaceStatusModified`)}function In(e){let t=e.replace(/\\/g,`/`);return t.split(`/`).filter(Boolean).pop()||t||`—`}function Ln(e,t,n){return e?.action===t&&(n?e.path===n:!e.path)}function Rn(e){return!!(e.unstaged||e.status===`untracked`||e.conflict||!e.staged)}function zn({files:e,selectedPath:t,expandedDiff:r,expandedLoading:i,expandedError:a,onSelectFile:o,onRestoreFile:c,onStageFile:l,onUnstageFile:u,onOpenFile:d,onRestoreAll:f,onStageAll:m,onUnstageAll:h,showUnstageAll:g=!1,pendingAction:_,emptyMessage:v=k(`workspaceNoWorkingTreeChanges`)}){let y=e.filter(Rn),b=e.filter(e=>e.staged),x=Ln(_,`restore`),ee=Ln(_,`stage`),S=Ln(_,`unstage`),w=!!_;return(0,F.jsxs)(`div`,{className:`relative flex min-h-0 min-w-0 flex-1 flex-col bg-background`,children:[(0,F.jsx)(`div`,{className:`min-h-0 min-w-0 flex-1 overflow-auto px-2 pb-20 pt-1`,children:e.length===0?(0,F.jsx)(`div`,{className:`px-3 py-4 text-xs text-muted-foreground/70`,children:v}):(0,F.jsx)(`div`,{className:`min-w-0 divide-y divide-[color-mix(in_oklab,var(--border)_28%,transparent)]`,children:e.map(e=>{let f=t===e.path,m=In(e.path),h=Ln(_,`restore`,e.path),v=Ln(_,`stage`,e.path),y=Ln(_,`unstage`,e.path),b=e.status===`deleted`,x=g,ee=w||(x?!u||!e.staged:!l||!Rn(e)),S=w||!c,te=w||!d||b,ne=e.oldPath?`${e.oldPath} → ${e.path}`:e.path;return(0,F.jsxs)(`div`,{className:j(`group min-w-0 overflow-hidden`,f&&`rounded-xl bg-muted/30`),children:[(0,F.jsxs)(`div`,{className:j(`grid min-h-[40px] grid-cols-[minmax(0,1fr)_auto] items-center gap-2 rounded-xl transition-colors`,f?`bg-muted/40`:`hover:bg-muted/24`),children:[(0,F.jsxs)(`button`,{type:`button`,className:`grid min-w-0 grid-cols-[24px_minmax(0,1fr)_auto] items-center gap-3 px-3 py-2 text-left text-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring`,onClick:()=>o(e.path),title:`${Fn(e.status)} · ${ne}`,"aria-expanded":f,children:[(0,F.jsx)(xn,{path:e.path,className:`size-[15px] shrink-0`}),(0,F.jsx)(`span`,{className:`min-w-0 truncate font-medium leading-[18px] text-foreground/90`,children:m}),typeof e.additions==`number`&&typeof e.deletions==`number`?(0,F.jsxs)(`span`,{className:`min-w-[64px] shrink-0 whitespace-nowrap text-right font-mono text-sm font-medium leading-[18px]`,children:[(0,F.jsxs)(`span`,{className:`text-emerald-600 dark:text-emerald-500`,children:[`+`,e.additions]}),(0,F.jsxs)(`span`,{className:`ml-1.5 text-red-600 dark:text-red-500`,children:[`-`,e.deletions]})]}):(0,F.jsx)(`span`,{className:`min-w-[64px]`})]}),(0,F.jsxs)(`div`,{className:`flex shrink-0 items-center gap-1 pr-2 text-muted-foreground/55 opacity-80 transition-opacity group-hover:opacity-100`,children:[(0,F.jsx)(`button`,{type:`button`,className:`inline-flex size-[26px] items-center justify-center rounded-full transition-colors hover:bg-destructive/10 hover:text-destructive disabled:cursor-not-allowed disabled:opacity-40`,onClick:()=>c?.(e),disabled:S,"aria-label":k(`workspaceRestoreFile`),title:k(`workspaceRestoreFile`),children:h?(0,F.jsx)(s,{className:`size-3.5 animate-spin`}):(0,F.jsx)(C,{className:`size-4`})}),(0,F.jsx)(`button`,{type:`button`,className:j(`inline-flex size-[26px] items-center justify-center rounded-full transition-colors disabled:cursor-not-allowed disabled:opacity-40`,x?`hover:bg-amber-500/10 hover:text-amber-600 dark:hover:text-amber-500`:`hover:bg-emerald-500/10 hover:text-emerald-600 dark:hover:text-emerald-500`),onClick:()=>x?u?.(e):l?.(e),disabled:ee,"aria-label":k(x?`workspaceUnstageFile`:`workspaceStageFile`),title:k(x?`workspaceUnstageFile`:`workspaceStageFile`),children:v||y?(0,F.jsx)(s,{className:`size-3.5 animate-spin`}):x?(0,F.jsx)(n,{className:`size-4`}):(0,F.jsx)(T,{className:`size-4`})}),(0,F.jsx)(`button`,{type:`button`,className:`inline-flex size-[26px] items-center justify-center rounded-full transition-colors hover:bg-muted/35 hover:text-foreground/85 disabled:cursor-not-allowed disabled:opacity-40`,onClick:()=>d?.(e),disabled:te,"aria-label":k(`workspaceOpenFileInNewTab`),title:k(b?`workspaceCannotOpenDeletedFile`:`workspaceOpenFileInNewTab`),children:(0,F.jsx)(p,{className:`size-4`})})]})]}),f?(0,F.jsx)(Pn,{diff:r,loading:i,error:a}):null]},`${e.status}:${e.oldPath??``}:${e.path}`)})})}),(0,F.jsx)(`div`,{className:`pointer-events-none absolute inset-x-0 bottom-4 z-20 flex justify-center px-2`,children:(0,F.jsxs)(`div`,{className:`pointer-events-auto inline-flex max-w-full items-center gap-1 rounded-full border border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background/95 p-1 shadow-quickforge`,children:[(0,F.jsxs)(`button`,{type:`button`,className:`inline-flex h-8 min-w-0 items-center gap-2 rounded-full px-3 text-sm font-medium text-muted-foreground/78 transition-colors hover:bg-destructive/10 hover:text-destructive disabled:cursor-not-allowed disabled:opacity-40`,onClick:f,disabled:!f||e.length===0||w,"aria-label":k(`workspaceRestoreAll`),title:k(`workspaceRestoreAll`),children:[x?(0,F.jsx)(s,{className:`size-3.5 animate-spin`}):(0,F.jsx)(C,{className:`size-3.5`}),(0,F.jsx)(`span`,{className:`truncate`,children:k(`workspaceRestoreAll`)})]}),(0,F.jsxs)(`button`,{type:`button`,className:j(`inline-flex h-8 min-w-0 items-center gap-2 rounded-full px-3 text-sm font-medium text-muted-foreground/78 transition-colors disabled:cursor-not-allowed disabled:opacity-40`,g?`hover:bg-amber-500/10 hover:text-amber-600 dark:hover:text-amber-500`:`hover:bg-emerald-500/10 hover:text-emerald-600 dark:hover:text-emerald-500`),onClick:g?h:m,disabled:g?!h||b.length===0||w:!m||y.length===0||w,"aria-label":k(g?`workspaceUnstageAll`:`workspaceStageAll`),title:k(g?`workspaceUnstageAll`:`workspaceStageAll`),children:[ee||S?(0,F.jsx)(s,{className:`size-3.5 animate-spin`}):g?(0,F.jsx)(n,{className:`size-3.5`}):(0,F.jsx)(T,{className:`size-3.5`}),(0,F.jsx)(`span`,{className:`truncate`,children:k(g?`workspaceUnstageAll`:`workspaceStageAll`)})]})]})})]})}function Bn(e){return e?e.status===`added`?`A`:e.status===`deleted`?`D`:e.status===`renamed`?`R`:e.status===`untracked`?`U`:`M`:``}function Vn({projectId:e,path:t}){let[n,r]=(0,P.useState)(!1);return n?(0,F.jsx)(xn,{path:t,className:`size-4 shrink-0`}):(0,F.jsx)(`img`,{src:se(e,t),alt:``,"aria-hidden":!0,loading:`lazy`,decoding:`async`,onError:()=>r(!0),className:`size-4 shrink-0 rounded-[3px] object-cover ring-1 ring-black/5 dark:ring-white/10`})}function Hn({node:e,depth:t,selectedPath:n,gitStatuses:r,onSelectFile:i,onPreviewFile:a,projectId:o}){let[s,c]=(0,P.useState)(!1),l=e.type===`directory`,u=n===e.path,d=Bn(r[e.path]),p=(l?void 0:he(e.path))===`image`,m=!!o&&p,h=!!a&&_e(e.path);function _(){a?.(e.path)}return(0,F.jsxs)(`div`,{children:[(0,F.jsxs)(`button`,{type:`button`,className:`group flex h-8 w-full items-center gap-2 rounded-md px-2 text-left text-sm transition-colors ${u?`bg-muted/28 text-foreground/90`:`text-muted-foreground/72 hover:bg-muted/20 hover:text-foreground/85`}`,style:{paddingLeft:`${.5+t*.75}rem`},onClick:()=>{l?c(e=>!e):p&&a?_():i(e.path)},title:e.path,children:[l?(0,F.jsx)(g,{className:`size-3.5 shrink-0 transition-transform ${s?`rotate-90`:``}`}):(0,F.jsx)(`span`,{className:`w-3.5 shrink-0`}),l?(0,F.jsx)(Sn,{name:e.name,open:s,className:`size-4 shrink-0`}):m?(0,F.jsx)(Vn,{projectId:o,path:e.path}):(0,F.jsx)(xn,{path:e.path,className:`size-4 shrink-0`}),(0,F.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:e.name}),d?(0,F.jsx)(`span`,{className:`shrink-0 font-mono text-xs text-emerald-600 dark:text-emerald-500`,children:d}):null,h?(0,F.jsx)(`span`,{role:`button`,tabIndex:0,"aria-label":k(`openPreview`),title:k(`openPreview`),className:`-mr-1 shrink-0 rounded p-0.5 text-muted-foreground/60 opacity-0 transition-opacity hover:bg-muted/40 hover:text-foreground/85 focus-visible:opacity-100 focus-visible:text-foreground/85 focus-visible:outline-none group-hover:opacity-100`,onClick:e=>{e.stopPropagation(),_()},onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),e.stopPropagation(),_())},children:(0,F.jsx)(f,{className:`size-4`})}):null]}),l&&s?(0,F.jsx)(`div`,{children:(e.children??[]).map(e=>(0,F.jsx)(Hn,{node:e,depth:t+1,selectedPath:n,gitStatuses:r,onSelectFile:i,onPreviewFile:a,projectId:o},e.path))}):null]})}function Un({tree:e,selectedPath:t,gitStatuses:n={},onSelectFile:r,onPreviewFile:i,projectId:a}){return e.length===0?(0,F.jsx)(`div`,{className:`px-2 py-3 text-sm text-muted-foreground/70`,children:k(`workspaceNoFilesToDisplay`)}):(0,F.jsx)(`div`,{className:`space-y-0.5`,children:e.map(e=>(0,F.jsx)(Hn,{node:e,depth:0,selectedPath:t,gitStatuses:n,onSelectFile:r,onPreviewFile:i,projectId:a},e.path))})}function Wn(e,t,n){return!!(e&&t&&e.projectId===t&&e.id!==n)}var Gn=`quickforge:workspace-inspector-tabs:v1:`;function Kn(e){return`${Gn}${e}`}function qn(e,t){return e===`browser`?`browser`:`${e}:${t}`}function Jn(e){return e===`files`||e===`review`||e===`terminal`||e===`browser`||e===`reader`}function Yn(){try{return globalThis.localStorage}catch{return}}function Xn(e){if(!Array.isArray(e))return[];let t=new Set,n=[];for(let r of e){if(!r||typeof r!=`object`||Array.isArray(r))continue;let e=r;if(!(typeof e.id!=`string`||!e.id||!Jn(e.kind))){if(e.kind===`review`){if(t.has(e.kind))continue;t.add(e.kind)}if(e.kind===`reader`){let t=e.reader;if(!t||t.mode!==`file`||typeof t.path!=`string`||!t.path)continue;let r=qn(t.mode,t.path);n.push({id:e.id,kind:e.kind,readerTabs:[{id:r,mode:t.mode,path:t.path,loading:!0}],activeReaderTabId:r});continue}n.push({id:e.id,kind:e.kind,...e.kind===`browser`&&typeof e.url==`string`?{url:e.url}:{},...e.kind===`review`?{reviewView:e.reviewView===`review`?`review`:`changes`}:{},...e.kind===`terminal`&&typeof e.terminalSessionId==`string`?{terminalSessionId:e.terminalSessionId}:{},...e.kind===`files`||e.kind===`review`?{readerTabs:[],activeReaderTabId:void 0}:{}})}}return n}function Zn(e,t=Yn()){if(!t)return{tabs:[]};try{let n=t.getItem(Kn(e));if(!n)return{tabs:[]};let r=JSON.parse(n),i=Xn(r?.tabs),a=typeof r?.activePanelTabId==`string`&&i.some(e=>e.id===r.activePanelTabId)?r.activePanelTabId:i[0]?.id;return a?{tabs:i,activePanelTabId:a}:{tabs:i}}catch{return{tabs:[]}}}function Qn(e,t){let n=e.flatMap(e=>{if(e.kind===`reader`){let t=e.readerTabs?.find(t=>t.id===e.activeReaderTabId)??e.readerTabs?.[0];return!t||t.mode!==`file`?[]:[{id:e.id,kind:e.kind,reader:{mode:t.mode,path:t.path}}]}return[{id:e.id,kind:e.kind,...e.kind===`browser`?{url:e.url||``}:{},...e.kind===`review`?{reviewView:e.reviewView||`changes`}:{},...e.kind===`terminal`&&e.terminalSessionId?{terminalSessionId:e.terminalSessionId}:{}}]});return{tabs:n,activePanelTabId:t&&n.some(e=>e.id===t)?t:n[0]?.id}}function $n(e,t,n,r=Yn()){if(!r)return!1;try{return r.setItem(Kn(e),JSON.stringify(Qn(t,n))),!0}catch{return!1}}function er(e){return e.reduce((e,t)=>{let n=t.id.match(/-(\d+)$/);if(!n)return e;let r=Number(n[1]);return Number.isFinite(r)?Math.max(e,r):e},0)+1}function tr(){let e,t=0;return{token:n=>(n!==e&&(e=n,t+=1),{projectId:n,epoch:t}),isCurrent:n=>n.projectId===e&&n.epoch===t,invalidate:()=>(t+=1,t)}}function nr(){if(typeof window>`u`)return 0;let e=window.getComputedStyle(document.body).getPropertyValue(`--quickforge-desktop-titlebar-height`).trim();if(!e)return 0;let t=Number.parseFloat(e);return Number.isFinite(t)?t:0}function rr(e,t){return e===`browser`?`browser`:`${e}:${t}`}var ir=[{kind:`files`,label:k(`rightPanelFiles`),description:k(`rightPanelFilesDesc`),icon:a},{kind:`review`,label:k(`rightPanelReview`),description:k(`rightPanelReviewDesc`),icon:d},{kind:`terminal`,label:k(`rightPanelTerminal`),description:k(`rightPanelTerminalDesc`),icon:S},{kind:`browser`,label:k(`rightPanelBrowser`),description:k(`rightPanelBrowserDesc`),icon:r}],ar=[{value:`unstaged`,label:k(`workspaceReviewFilterUnstaged`)},{value:`staged`,label:k(`workspaceReviewFilterStaged`)},{value:`all`,label:k(`workspaceReviewFilterAllBranches`)},{value:`last`,label:k(`workspaceReviewFilterLastRun`)}],or=Object.fromEntries(ir.map(e=>[e.kind,e]));function sr(e){return e===`review`?`changes`:e}function cr(e){let t=e.trim();if(!t)return`about:blank`;if(/^[a-zA-Z]:[\\/]/.test(t))return A(t);try{let e=new URL(t);return e.protocol===`about:`?t:e.protocol===`file:`?A(decodeURIComponent(e.pathname)):e.host||t}catch{return A(t)}}function lr(e,t){if(e.kind===`terminal`)return t||k(`rightPanelTerminal`);if(e.kind===`browser`)return cr(e.url||``);if(e.kind===`reader`){let t=e.readerTabs?.find(t=>t.id===e.activeReaderTabId)??e.readerTabs?.[0];return t?A(t.path):k(`rightPanelFiles`)}return or[e.kind].label}function ur(e,t){return e.kind===`browser`?e.url||t:e.kind===`reader`&&(e.readerTabs?.find(t=>t.id===e.activeReaderTabId)??e.readerTabs?.[0])?.path||t}var dr=340,fr=380,$=640,pr=`quickforge_workspaceInspectorWidth_v2`,mr=140,hr=200,gr=400;function _r(){if(typeof window>`u`)return fr;try{let e=window.localStorage.getItem(pr);if(!e)return fr;let t=Number(e);return Number.isFinite(t)?Math.min($,Math.max(dr,t)):fr}catch{return fr}}function vr(e,t){let n=t.trim().toLowerCase();return n?e.flatMap(e=>{let t=e.children?vr(e.children,n):void 0;return!(e.name.toLowerCase().includes(n)||e.path.toLowerCase().includes(n))&&(!t||t.length===0)?[]:[{...e,...t?{children:t}:{}}]}):e}function yr(e,t){let n=e?.trim();if(!n)return``;let r=n.replace(/\\/g,`/`).replace(/^\.\/+/g,``),i=t?.trim().replace(/\\/g,`/`).replace(/\/+$/g,``);return i&&r.startsWith(`${i}/`)&&(r=r.slice(i.length+1)),r.replace(/^\/+/,``)}function br(e,t){let n=new Set;for(let r of e){let e=yr(r.path,t),i=yr(r.outputFile,t);e&&n.add(e),i&&n.add(i)}return n}function xr(e){return k(e===`staged`?`workspaceNoStagedChanges`:e===`last`?`workspaceNoLastRunChanges`:`workspaceNoWorkingTreeChanges`)}function Sr(e){return e?e.language===`markdown`||/\.(md|markdown)$/i.test(e.path):!1}function Cr(e){return`Diff for ${e.oldPath?`${e.oldPath} -> ${e.path}`:e.path}\n\n--- OLD\n${e.oldContent}\n\n--- NEW\n${e.newContent}`}function wr({project:e,path:t,mode:n,file:r,diff:i,loading:o,error:s,navigationVisible:c,onNavigationVisibleChange:u}){let[d,f]=(0,P.useState)(),[p,m]=(0,P.useState)(`preview`),[h,_]=(0,P.useState)(!1),[v,y]=(0,P.useState)(!1),x=(0,P.useRef)(null);async function S(e,t){t&&(await navigator.clipboard.writeText(t),f(e),_(!1),window.setTimeout(()=>f(void 0),1200))}async function C(t){if(!(!e?.id||!T))try{await ge(e.id,T,t)}catch(e){let n=k(t===`explorer`?`openInExplorerFailed`:t===`idea`?`openInIDEAFailed`:`openInVSCodeFailed`);await re(e instanceof Error?e.message:n)}}let T=n===`file`?r?.path||t:i?.path||t,te=(0,P.useMemo)(()=>yr(T).split(`/`).filter(Boolean),[T]),ne=[e?.name,...te].filter(Boolean).join(` > `),E=n===`file`&&Sr(r),ie=n===`file`&&(!E||p===`source`),ae=n===`file`?r?.content:i?Cr(i):void 0,oe=(0,P.useMemo)(()=>n===`diff`&&i?ze(i.oldContent,i.newContent):void 0,[n,i]);return(0,P.useEffect)(()=>{if(!h)return;let e=e=>{x.current?.contains(e.target)||_(!1)},t=e=>{e.key===`Escape`&&_(!1)};return document.addEventListener(`pointerdown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`pointerdown`,e),document.removeEventListener(`keydown`,t)}},[h]),(0,F.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col`,children:[(0,F.jsxs)(`div`,{className:`flex h-12 shrink-0 items-center gap-2 border-b border-border px-3`,children:[oe?(0,F.jsxs)(`span`,{className:`shrink-0 font-mono text-[11px] font-medium`,children:[(0,F.jsxs)(`span`,{className:`text-emerald-600 dark:text-emerald-400`,children:[`+`,oe.added]}),(0,F.jsxs)(`span`,{className:`ml-1.5 text-red-600 dark:text-red-400`,children:[`-`,oe.removed]})]}):null,(0,F.jsxs)(`div`,{className:`flex min-w-0 flex-1 items-center gap-1.5 overflow-hidden text-sm`,title:ne||T,children:[e?.name?(0,F.jsx)(`span`,{className:`shrink-0 truncate text-muted-foreground/75`,children:e.name}):null,te.map((t,n)=>{let r=n===te.length-1;return(0,F.jsxs)(`div`,{className:j(`flex min-w-0 items-center gap-1.5`,r?`min-w-0`:`shrink-0`),children:[e?.name||n>0?(0,F.jsx)(g,{className:`size-4 shrink-0 text-muted-foreground/55`}):null,(0,F.jsx)(`span`,{className:j(`truncate`,r?`font-medium text-foreground/92`:`text-muted-foreground/75`),children:t})]},`${t}-${n}`)})]}),(0,F.jsxs)(`div`,{ref:x,className:`flex shrink-0 items-center gap-1`,children:[E?(0,F.jsx)(`button`,{type:`button`,className:`inline-flex h-8 items-center rounded-xl px-2.5 text-sm font-medium text-foreground/82 transition-colors hover:bg-muted/30 hover:text-foreground`,onClick:()=>{m(e=>e===`preview`?`source`:`preview`),_(!1)},children:k(p===`preview`?`viewMarkdownSource`:`returnToMarkdownPreview`)}):null,(0,F.jsxs)(`div`,{className:`relative`,children:[(0,F.jsx)(O,{variant:`ghost`,size:`icon`,className:j(`size-8 rounded-xl text-muted-foreground/75`,h&&`bg-muted/45 text-foreground/90`),onClick:()=>_(e=>!e),"aria-label":k(`readerMoreActions`),title:k(`readerMoreActions`),"aria-haspopup":`menu`,"aria-expanded":h,children:(0,F.jsx)(l,{className:`size-4`})}),h?(0,F.jsxs)(`div`,{className:`absolute right-0 top-10 z-50 w-56 rounded-2xl border border-[color-mix(in_oklab,var(--border)_38%,transparent)] bg-popover p-1.5 text-popover-foreground shadow-quickforge`,role:`menu`,"aria-label":k(`readerMoreActions`),children:[(0,F.jsxs)(`button`,{type:`button`,className:`flex h-10 w-full items-center gap-3 rounded-xl px-3 text-left text-sm font-medium text-foreground/86 transition-colors hover:bg-accent hover:text-accent-foreground disabled:cursor-not-allowed disabled:opacity-45`,onClick:()=>void S(`path`,T),disabled:!T,role:`menuitem`,children:[d===`path`?(0,F.jsx)(w,{className:`size-4 shrink-0`}):(0,F.jsx)(ee,{className:`size-4 shrink-0 text-muted-foreground/80`}),(0,F.jsx)(`span`,{children:k(`copyPath`)})]}),(0,F.jsxs)(`button`,{type:`button`,className:`flex h-10 w-full items-center gap-3 rounded-xl px-3 text-left text-sm font-medium text-foreground/86 transition-colors hover:bg-accent hover:text-accent-foreground disabled:cursor-not-allowed disabled:opacity-45`,onClick:()=>void S(`content`,ae),disabled:!ae,role:`menuitem`,children:[d===`content`?(0,F.jsx)(w,{className:`size-4 shrink-0`}):(0,F.jsx)(ee,{className:`size-4 shrink-0 text-muted-foreground/80`}),(0,F.jsx)(`span`,{children:k(n===`file`?`copyFileContent`:`copyDiffContent`)})]}),(0,F.jsxs)(`button`,{type:`button`,className:`flex h-10 w-full items-center gap-3 rounded-xl px-3 text-left text-sm font-medium text-foreground/86 transition-colors hover:bg-accent hover:text-accent-foreground disabled:cursor-not-allowed disabled:opacity-45`,onClick:()=>{y(e=>!e),_(!1)},disabled:!ie,role:`menuitemcheckbox`,"aria-checked":v,children:[(0,F.jsx)(b,{className:`size-4 shrink-0 text-muted-foreground/80`}),(0,F.jsx)(`span`,{className:`min-w-0 flex-1`,children:k(`enableWordWrap`)}),v?(0,F.jsx)(w,{className:`size-4 shrink-0 text-muted-foreground/80`}):null]})]}):null]}),(0,F.jsx)(O,{variant:`ghost`,size:`icon`,className:j(`size-8 rounded-xl text-muted-foreground/75`,c&&`bg-muted/45 text-foreground/90`),onClick:()=>u(!c),"aria-label":k(c?`hideFileNavigation`:`showFileNavigation`),title:k(c?`hideFileNavigation`:`showFileNavigation`),"aria-pressed":c,children:(0,F.jsx)(a,{className:`size-4`})}),(0,F.jsx)(ce,{project:e,disabled:!T,onOpenInExplorer:()=>{C(`explorer`)},onOpenInVSCode:()=>{C(`vscode`)},onOpenInIDEA:()=>{C(`idea`)}})]})]}),(0,F.jsxs)(`div`,{className:`min-h-0 flex-1 bg-background`,children:[o?(0,F.jsx)(`div`,{className:`p-4 text-sm text-muted-foreground/70`,children:k(`openingReader`)}):null,!o&&s?(0,F.jsx)(`div`,{className:`p-4 text-sm text-destructive`,children:s}):null,!o&&!s&&n===`file`&&r?E?(0,F.jsx)(Le,{path:r.path,content:r.content,language:r.language,mode:p,wordWrap:v},r.path):(0,F.jsx)(Ne,{path:r.path,content:r.content,language:r.language,wordWrap:v}):null,!o&&!s&&n===`diff`&&i?(0,F.jsx)(Re,{path:i.path,oldContent:i.oldContent,newContent:i.newContent,language:i.language,status:i.status}):null]})]})}function Tr({project:e,artifacts:t,changesCount:n,changedPaths:r,isGitRepository:i,gitBranch:a,onSelectFile:o,onSelectDiff:s,onPreviewFile:c}){let[l,u]=(0,P.useState)(!1),[d,p]=(0,P.useState)(()=>new Set),h=D(t),g=t.filter(e=>e.command);function v(e){p(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})}return(0,F.jsxs)(`div`,{className:`space-y-3 p-2`,children:[(0,F.jsxs)(`div`,{className:`rounded-lg border border-border bg-background px-3 py-3`,children:[(0,F.jsxs)(`div`,{className:`flex items-center gap-2 text-xs font-semibold text-foreground/90`,children:[(0,F.jsx)(_,{className:`size-3.5 text-emerald-600 dark:text-emerald-500`}),k(`workspaceCurrentArtifacts`)]}),t.length===0?(0,F.jsx)(`div`,{className:`mt-2 text-xs leading-5 text-muted-foreground/70`,children:k(`workspaceNoArtifacts`)}):(0,F.jsxs)(`div`,{className:`mt-3 space-y-3`,children:[h.length?(0,F.jsxs)(`div`,{className:`space-y-1.5`,children:[(0,F.jsxs)(`div`,{className:`text-[11px] font-medium uppercase tracking-wide text-muted-foreground/60`,children:[k(`workspaceFiles`),` `,h.length]}),h.slice(0,8).map(e=>{let t=e.path,n=_e(t),i=r.has(t),a=typeof e.addedLines==`number`||typeof e.removedLines==`number`;return(0,F.jsxs)(`div`,{className:`group flex min-w-0 items-center gap-2 rounded-md px-2 py-1.5 text-xs text-foreground/85 transition-colors hover:bg-muted/20`,children:[(0,F.jsx)(xn,{path:t,className:`size-3.5 shrink-0`}),(0,F.jsx)(`button`,{type:`button`,className:`min-w-0 flex-1 truncate text-left font-medium`,onClick:()=>n?c(t):i?s(t):o(t),title:t,children:e.title||A(t)}),a?(0,F.jsxs)(`span`,{className:`shrink-0 font-mono text-[10px] font-medium`,children:[(0,F.jsxs)(`span`,{className:`text-emerald-600 dark:text-emerald-400`,children:[`+`,e.addedLines??0]}),(0,F.jsxs)(`span`,{className:`ml-1 text-red-600 dark:text-red-400`,children:[`-`,e.removedLines??0]})]}):null,(0,F.jsx)(`span`,{className:`shrink-0 rounded-full bg-muted/30 px-1.5 py-0.5 text-[10px] font-medium text-muted-foreground/70`,children:e.kind}),n?(0,F.jsx)(`button`,{type:`button`,className:`shrink-0 inline-flex size-5 items-center justify-center text-blue-600 opacity-0 transition-opacity hover:bg-blue-500/10 hover:text-blue-700 group-hover:opacity-100 dark:text-blue-400`,onClick:()=>c(t),"aria-label":k(`previewArtifact`),title:k(`previewArtifact`),children:(0,F.jsx)(f,{className:`size-3.5`})}):null,(0,F.jsx)(`button`,{type:`button`,className:`shrink-0 rounded-md px-1.5 py-0.5 text-[10px] font-medium text-muted-foreground/70 opacity-0 transition-opacity hover:bg-muted/25 group-hover:opacity-100`,onClick:()=>i?s(t):o(t),children:k(i?`workspaceViewDiff`:`artifactPreviewViewSource`)})]},e.id)}),h.length>8?(0,F.jsxs)(`div`,{className:`px-2 text-[11px] text-muted-foreground/60`,children:[`+`,h.length-8]}):null]}):null,g.length?(0,F.jsxs)(`div`,{className:`space-y-1.5`,children:[(0,F.jsxs)(`button`,{type:`button`,className:`flex w-full items-center gap-2 rounded-md px-1 py-1 text-left text-[11px] font-medium uppercase tracking-wide text-muted-foreground/60 transition-colors hover:bg-muted/15 hover:text-foreground/75`,onClick:()=>u(e=>!e),"aria-expanded":l,children:[(0,F.jsx)(m,{className:j(`size-3.5 transition-transform`,l?``:`-rotate-90`)}),(0,F.jsxs)(`span`,{className:`min-w-0 flex-1 truncate`,children:[k(`workspaceCommands`),` `,g.length]})]}),l?(0,F.jsx)(`div`,{className:`space-y-1`,children:g.map((e,t)=>{let n=d.has(e.id);return(0,F.jsxs)(`div`,{className:`rounded-md bg-muted/15 text-[11px] text-muted-foreground/80`,children:[(0,F.jsxs)(`button`,{type:`button`,className:`flex w-full items-center gap-2 px-2 py-1.5 text-left transition-colors hover:bg-muted/20`,onClick:()=>v(e.id),"aria-expanded":n,children:[(0,F.jsx)(m,{className:j(`size-3 shrink-0 transition-transform`,n?``:`-rotate-90`)}),(0,F.jsxs)(`span`,{className:`shrink-0 font-medium text-muted-foreground/65`,children:[`#`,t+1]}),(0,F.jsx)(`span`,{className:`min-w-0 flex-1 truncate font-mono`,children:e.command})]}),n?(0,F.jsxs)(`div`,{className:`space-y-1 px-2 pb-2 pt-1.5`,children:[(0,F.jsx)(`pre`,{className:`whitespace-pre-wrap break-words font-mono text-[11px] leading-5 text-foreground/80`,children:e.command}),e.outputFile?(0,F.jsxs)(`div`,{className:`text-[10px] text-muted-foreground/65`,children:[k(`workspaceCommandOutput`),`: `,(0,F.jsx)(`span`,{className:`font-mono`,children:e.outputFile})]}):null]}):null]},e.id)})}):null]}):null]})]}),(0,F.jsxs)(`div`,{className:`rounded-lg border border-border bg-muted/10 px-3 py-3`,children:[(0,F.jsx)(`div`,{className:`text-xs font-medium text-foreground/85`,children:e?.name??k(`noProjectSelected`)}),(0,F.jsx)(`div`,{className:`mt-1 text-[11px] text-muted-foreground/65`,children:i?`${k(`workspaceCurrentBranch`)}: ${a||k(`unknown`)} · ${n} ${k(`workspaceChangeCount`)}`:k(`workspaceNotGitRepository`)})]})]})}function Er({project:e,open:t,onOpenChange:n,onOpenCommitPush:r,onOpenProjectInExplorer:a,onOpenProjectInVSCode:s,onOpenProjectInIDEA:c,onPreviewArtifact:l,request:u,onRequestHandled:d,artifacts:f=[],pendingTerminalCommand:p,onPendingTerminalCommandHandled:g}){let[b,ee]=(0,P.useState)([]),[S,C]=(0,P.useState)([]),[ne,E]=(0,P.useState)(),[ie,se]=(0,P.useState)(!1),[D,he]=(0,P.useState)(!1),[_e,A]=(0,P.useState)(),[xe,Se]=(0,P.useState)(``),[M,we]=(0,P.useState)(`unstaged`),[N,Te]=(0,P.useState)(),[Ee,De]=(0,P.useState)(),[Oe,ke]=(0,P.useState)(!1),[je,Me]=(0,P.useState)(),Ne=(0,P.useRef)(void 0);Ne.current||=e?.id?Zn(e.id):{tabs:[]};let[I,L]=(0,P.useState)(()=>Ne.current?.tabs??[]),[R,z]=(0,P.useState)(()=>Ne.current?.activePanelTabId),[Pe,Fe]=(0,P.useState)(!1),[B,Ie]=(0,P.useState)(!1),[V,Le]=(0,P.useState)(!1),[Re,ze]=(0,P.useState)(),[Be,Ve]=(0,P.useState)(hr),[He,Ue]=(0,P.useState)(!0),[We,Ge]=(0,P.useState)(!1),[Ke,qe]=(0,P.useState)(t),[Je,Ye]=(0,P.useState)(!1),[H,Xe]=(0,P.useState)(_r),[Ze,Qe]=(0,P.useState)(!1),[U,$e]=(0,P.useState)(!1),[et,tt]=(0,P.useState)(!1),W=(0,P.useRef)(null),nt=(0,P.useRef)(null),rt=(0,P.useRef)(null),it=(0,P.useRef)(null),at=(0,P.useRef)(null),G=(0,P.useRef)(null),ot=(0,P.useRef)(null),K=(0,P.useRef)(null),q=(0,P.useRef)(null),st=(0,P.useRef)(null),ct=(0,P.useRef)(er(Ne.current?.tabs??[])),lt=(0,P.useRef)(void 0),ut=(0,P.useRef)(void 0),dt=(0,P.useRef)(void 0),J=(0,P.useRef)(tr()),ft=(0,P.useRef)(new Set),pt=(0,P.useRef)(0);(0,P.useEffect)(()=>{let e=J.current;return()=>{e.invalidate()}},[]);let Y=e?.id;Y&&J.current.token(Y);let X=(0,P.useMemo)(()=>I.find(e=>e.id===R),[R,I]),mt=X?.activeReaderTabId,ht=(0,P.useMemo)(()=>X?.readerTabs||[],[X?.readerTabs]),Z=(0,P.useMemo)(()=>ht.find(e=>e.id===mt),[mt,ht]),gt=!!(Z&&Z.mode!==`browser`&&(X?.kind===`reader`||X?.kind===`files`||X?.kind===`review`&&Z.mode===`diff`)),_t=!gt||He,vt=X?.kind===`review`?X.reviewView===`review`?`overview`:`changes`:`files`,yt=(0,P.useMemo)(()=>{let e={};for(let t of S)e[t.path]=t;return e},[S]),bt=(0,P.useMemo)(()=>{let e=new Set;for(let t of S)e.add(t.path),t.oldPath&&e.add(t.oldPath);return e},[S]),xt=(0,P.useMemo)(()=>vr(b,xe),[xe,b]),St=(0,P.useMemo)(()=>br(f,e?.path),[f,e?.path]),Ct=(0,P.useMemo)(()=>M===`staged`?S.filter(e=>e.staged):M===`all`?S:M===`last`?S.filter(e=>St.has(e.path)||(e.oldPath?St.has(e.oldPath):!1)):S.filter(e=>e.unstaged||e.status===`untracked`||e.conflict||e.status===`conflicted`),[S,St,M]),wt=N?Ct.find(e=>e.path===N):void 0;function Tt(e){C(e.files),E(e.branch),se(e.isGitRepository)}async function Et(e,t,n,r){ze({action:e,path:t});try{Tt(await n())}catch(e){await re(e instanceof Error?e.message:r)}finally{ze(void 0)}}async function Dt(e){Y&&await Et(`stage`,e.path,()=>oe(Y,e.path),k(`workspaceStageFailed`))}async function Ot(){Y&&await Et(`stage`,void 0,()=>de(Y),k(`workspaceStageFailed`))}async function kt(e){Y&&await Et(`unstage`,e.path,()=>be(Y,e.path),k(`workspaceUnstageFailed`))}async function At(){Y&&await Et(`unstage`,void 0,()=>ye(Y),k(`workspaceUnstageFailed`))}async function jt(e){Y&&await ae({title:k(`workspaceRestoreConfirmTitle`),description:k(`workspaceRestoreFileConfirm`,{path:e.path}),confirmLabel:k(`workspaceRestoreFile`),cancelLabel:k(`cancel`),variant:`destructive`})&&await Et(`restore`,e.path,()=>fe(Y,e.path),k(`workspaceRestoreFailed`))}async function Mt(){Y&&await ae({title:k(`workspaceRestoreConfirmTitle`),description:k(`workspaceRestoreAllConfirm`),confirmLabel:k(`workspaceRestoreAll`),cancelLabel:k(`cancel`),variant:`destructive`})&&await Et(`restore`,void 0,()=>me(Y),k(`workspaceRestoreFailed`))}function Nt(e){e.status!==`deleted`&&Ut(e.path)}async function Pt(t){if(e){if(!wt){t===`explorer`?a?.(e):t===`idea`?c?.(e):s?.(e);return}if(Y)try{await ge(Y,wt.path,t)}catch(e){let n=k(t===`explorer`?`openInExplorerFailed`:t===`idea`?`openInIDEAFailed`:`openInVSCodeFailed`);await re(e instanceof Error?e.message:n)}}}(0,P.useEffect)(()=>{!N||Ct.some(e=>e.path===N)||(Te(void 0),De(void 0),Me(void 0),ke(!1))},[N,Ct]),(0,P.useEffect)(()=>{if(t){let e=!1;return queueMicrotask(()=>{e||(qe(!0),window.requestAnimationFrame(()=>{e||Ye(!0)}))}),()=>{e=!0}}let e=!1;queueMicrotask(()=>{e||Ye(!1)});let n=window.setTimeout(()=>qe(!1),180);return()=>{e=!0,window.clearTimeout(n)}},[t]),(0,P.useEffect)(()=>{if(!Pe&&!B&&!V)return;let e=e=>{let t=e.target;Pe&&!nt.current?.contains(t)&&Fe(!1),B&&!rt.current?.contains(t)&&Ie(!1),V&&!it.current?.contains(t)&&Le(!1)},t=e=>{e.key===`Escape`&&(Fe(!1),Ie(!1),Le(!1))};return document.addEventListener(`pointerdown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`pointerdown`,e),document.removeEventListener(`keydown`,t)}},[Pe,V,B]),(0,P.useEffect)(()=>{!t||!Wn(u,Y,dt.current)||(dt.current=u.id,u.kind===`review`?lt.current?.(`review`,u.view):u.kind===`reader`?ut.current?.(u.path):u.kind===`browser`?lt.current?.(`browser`,`browser`,{url:u.url}):lt.current?.(u.kind,sr(u.kind)),d?.(u.id))},[d,t,Y,u]),(0,P.useEffect)(()=>{try{window.localStorage.setItem(pr,String(H))}catch{}},[H]);let Ft=(0,P.useCallback)(()=>{Xe(e=>e<$?$:e)},[]);(0,P.useEffect)(()=>{!Je||U||(X?.kind===`browser`||X?.kind===`terminal`||mt)&&Ft()},[X?.kind,mt,Je,U,Ft]);let It=(0,P.useCallback)(async e=>{if(Y){he(!0),A(void 0);try{let[t,n]=await Promise.all([ue(Y),ve(Y)]);if(e?.())return;ee(t.tree),C(n.files),E(n.branch),se(n.isGitRepository)}catch(t){e?.()||A(t instanceof Error?t.message:k(`workspaceLoadFailed`))}finally{e?.()||he(!1)}}},[Y]);(0,P.useEffect)(()=>{let e=!1;if(!(!Y||!t))return queueMicrotask(()=>{e||It(()=>e)}),()=>{e=!0}},[It,t,Y]),(0,P.useEffect)(()=>{Y&&$n(Y,I,R)},[R,I,Y]),(0,P.useEffect)(()=>{!R||I.some(e=>e.id===R)||z(I[0]?.id)},[R,I]),(0,P.useEffect)(()=>{if(!Y)return;let e=I.flatMap(e=>e.kind===`reader`?(e.readerTabs||[]).filter(e=>e.loading&&e.mode===`file`).map(t=>({panelTabId:e.id,reader:t})):[]);for(let{panelTabId:t,reader:n}of e){let e=`${Y}:${n.id}`;if(ft.current.has(e))continue;ft.current.add(e);let r=J.current.token(Y);le(Y,n.path).then(e=>({file:e})).then(e=>{J.current.isCurrent(r)&&Q(t,t=>({...t,readerTabs:(t.readerTabs||[]).map(t=>t.id===n.id?{...t,...e,loading:!1,error:void 0}:t)}))}).catch(e=>{J.current.isCurrent(r)&&Q(t,t=>({...t,readerTabs:(t.readerTabs||[]).map(t=>t.id===n.id?{...t,loading:!1,error:e instanceof Error?e.message:k(`workspaceOpenFileFailed`)}:t)}))}).finally(()=>{ft.current.delete(e)})}},[I,Y]);function Lt(e,t){let n=`${e}-${ct.current++}`;return e===`browser`?{id:n,kind:e,url:t?.url||``}:e===`reader`?{id:n,kind:e,readerTabs:t?.readerTab?[t.readerTab]:[],activeReaderTabId:t?.readerTab?.id}:e===`files`||e===`review`?{id:n,kind:e,...e===`review`?{reviewView:t?.reviewView||`changes`}:{},readerTabs:t?.readerTab?[t.readerTab]:[],activeReaderTabId:t?.readerTab?.id}:{id:n,kind:e}}function Rt(e){return Lt(`reader`,{readerTab:e})}function Q(e,t){L(n=>n.map(n=>n.id===e?t(n):n))}function zt(e,t=sr(e),n){let r=e===`review`?I.find(e=>e.kind===`review`):void 0,i=r||Lt(e,{...n,...e===`review`?{reviewView:t===`review`?`review`:`changes`}:{}});return r||L(e=>[...e,i]),r?.kind===`review`&&Q(r.id,e=>({...e,reviewView:t===`review`?`review`:`changes`})),z(i.id),Fe(!1),i}lt.current=zt;function Bt(e){z(e.id)}function Vt(e){L(t=>{let r=t.findIndex(t=>t.id===e),i=t.filter(t=>t.id!==e);return i.length===0?(z(void 0),n(!1),i):(R===e&&z((i[r]??i[r-1])?.id),i)})}function Ht(e){if(l&&Y){l(Y,e);return}Ut(e)}async function Ut(e){if(!Y)return;let t=J.current.token(Y),n=rr(`file`,e),r=I.find(e=>e.kind===`reader`&&e.readerTabs?.some(e=>e.id===n));if(r){z(r.id),Q(r.id,e=>({...e,activeReaderTabId:n}));return}let i=Rt({id:n,mode:`file`,path:e,loading:!0});L(e=>[...e,i]),z(i.id);try{let r=await le(Y,e);if(!J.current.isCurrent(t))return;Q(i.id,e=>({...e,readerTabs:(e.readerTabs||[]).map(e=>e.id===n?{...e,file:r,loading:!1,error:void 0}:e)}))}catch(e){if(!J.current.isCurrent(t))return;Q(i.id,t=>({...t,readerTabs:(t.readerTabs||[]).map(t=>t.id===n?{...t,loading:!1,error:e instanceof Error?e.message:k(`workspaceOpenFileFailed`)}:t)}))}}ut.current=Ut;async function Wt(e,t){if(!Y)return;let n=J.current.token(Y),r=I.find(e=>e.kind===`review`)||zt(`review`,t?`changes`:`review`);z(r.id),t&&r.kind===`review`&&Q(r.id,e=>({...e,reviewView:`changes`}));let i=rr(`diff`,e);if(r.readerTabs?.some(e=>e.id===i)){Q(r.id,e=>({...e,activeReaderTabId:i}));return}let a={id:i,mode:`diff`,path:e,loading:!0};Q(r.id,e=>({...e,readerTabs:[...e.readerTabs||[],a],activeReaderTabId:i}));try{let t=await pe(Y,e);if(!J.current.isCurrent(n))return;Q(r.id,e=>({...e,readerTabs:(e.readerTabs||[]).map(e=>e.id===i?{...e,diff:t,loading:!1,error:void 0}:e)}))}catch(e){if(!J.current.isCurrent(n))return;Q(r.id,t=>({...t,readerTabs:(t.readerTabs||[]).map(t=>t.id===i?{...t,loading:!1,error:e instanceof Error?e.message:k(`workspaceOpenDiffFailed`)}:t)}))}}async function Gt(e){if(!Y)return;let t=J.current.token(Y);if(N===e){pt.current+=1,Te(void 0),De(void 0),Me(void 0),ke(!1);return}let n=pt.current+1;pt.current=n,Te(e),De(void 0),Me(void 0),ke(!0);try{let r=await pe(Y,e);if(pt.current!==n||!J.current.isCurrent(t))return;De(r)}catch(e){if(pt.current!==n||!J.current.isCurrent(t))return;Me(e instanceof Error?e.message:k(`workspaceOpenDiffFailed`))}finally{pt.current===n&&J.current.isCurrent(t)&&ke(!1)}}async function Kt(e){await Wt(e,!1)}function qt(e){ot.current={startX:e.clientX,startWidth:H,currentWidth:H},st.current={cursor:document.body.style.cursor,userSelect:document.body.style.userSelect},document.body.style.cursor=`col-resize`,document.body.style.userSelect=`none`,Qe(!0),e.preventDefault();try{e.currentTarget.setPointerCapture(e.pointerId)}catch{}}function Jt(e){let t=ot.current,n=W.current;!t||!n||(t.currentWidth=Math.min($,Math.max(dr,t.startWidth+t.startX-e.clientX)),K.current===null&&(K.current=window.requestAnimationFrame(()=>{K.current=null;let e=ot.current;!e||!W.current||(W.current.style.width=`${e.currentWidth}px`)})))}function Yt(e){let t=ot.current?.currentWidth;ot.current=null,K.current!==null&&(window.cancelAnimationFrame(K.current),K.current=null),typeof t==`number`&&(W.current&&(W.current.style.width=`${t}px`),Xe(t));let n=st.current;n&&(document.body.style.cursor=n.cursor,document.body.style.userSelect=n.userSelect,st.current=null),Qe(!1);try{e.currentTarget.releasePointerCapture(e.pointerId)}catch{}}function Xt(e){at.current={startX:e.clientX,startWidth:Be,currentWidth:Be},document.body.style.cursor=`col-resize`,document.body.style.userSelect=`none`,Ge(!0),e.preventDefault();try{e.currentTarget.setPointerCapture(e.pointerId)}catch{}}function Zt(e){let t=at.current;t&&(t.currentWidth=Math.min(gr,Math.max(mr,t.startWidth+t.startX-e.clientX)),G.current===null&&(G.current=window.requestAnimationFrame(()=>{G.current=null;let e=at.current;e&&Ve(e.currentWidth)})))}function Qt(e){let t=at.current?.currentWidth;at.current=null,G.current!==null&&(window.cancelAnimationFrame(G.current),G.current=null),typeof t==`number`&&Ve(t),document.body.style.cursor=``,document.body.style.userSelect=``,Ge(!1);try{e.currentTarget.releasePointerCapture(e.pointerId)}catch{}}let $t=(0,P.useCallback)(()=>{let e=W.current;if(!e){$e(e=>!e);return}q.current?.cancel();let t=e.getBoundingClientRect(),n=window.innerWidth,r=nr(),i=window.innerHeight-r,a=`${r}px`,o=`${i}px`,s=`cubic-bezier(0.22, 1, 0.36, 1)`;if(tt(!0),!U){window.requestAnimationFrame(()=>{let e=W.current;if(!e)return;Object.assign(e.style,{position:`fixed`,left:`${t.left}px`,top:`${t.top}px`,right:`auto`,bottom:`auto`,width:`${t.width}px`,height:`${t.height}px`,minWidth:`0px`,maxWidth:`none`,zIndex:`40`});let r=e.animate([{left:`${t.left}px`,top:`${t.top}px`,width:`${t.width}px`,height:`${t.height}px`},{left:`0px`,top:a,width:`${n}px`,height:o}],{duration:240,easing:s,fill:`forwards`});q.current=r,r.onfinish=()=>{q.current=null,$e(!0),window.requestAnimationFrame(()=>{r.cancel(),e.removeAttribute(`style`),window.requestAnimationFrame(()=>tt(!1))})},r.oncancel=()=>{q.current=null,tt(!1)}});return}window.requestAnimationFrame(()=>{let e=W.current;if(!e)return;Object.assign(e.style,{position:`fixed`,left:`0px`,top:a,right:`auto`,bottom:`auto`,width:`${t.width}px`,height:o,zIndex:`40`});let r=n-H,i=e.animate([{left:`0px`,top:a,width:`${t.width}px`,height:o},{left:`${r}px`,top:a,width:`${H}px`,height:o}],{duration:240,easing:s,fill:`forwards`});q.current=i,i.onfinish=()=>{q.current=null,$e(!1),window.requestAnimationFrame(()=>{i.cancel(),e.style.position=``,e.style.left=``,e.style.top=``,e.style.right=``,e.style.bottom=``,e.style.height=``,e.style.zIndex=``,e.style.width=`${H}px`,e.style.minWidth=`${dr}px`,e.style.maxWidth=`${$}px`,window.requestAnimationFrame(()=>tt(!1))})},i.oncancel=()=>{q.current=null,tt(!1)}})},[U,H]);return(0,P.useEffect)(()=>{if(!U)return;let e=e=>{e.key===`Escape`&&$e(!1)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[U]),(0,P.useEffect)(()=>()=>{K.current!==null&&window.cancelAnimationFrame(K.current),G.current!==null&&window.cancelAnimationFrame(G.current),q.current?.cancel(),W.current&&W.current.removeAttribute(`style`);let e=st.current;e&&(document.body.style.cursor=e.cursor,document.body.style.userSelect=e.userSelect)},[]),Ke?(0,F.jsx)(F.Fragment,{children:(0,F.jsxs)(`aside`,{ref:W,className:j(`relative hidden shrink-0 overflow-hidden flex-col bg-background transition-[width,min-width,max-width,opacity,transform] duration-200 ease-out will-change-[width,opacity,transform] lg:flex`,Je?`translate-x-0 opacity-100`:`w-0 min-w-0 max-w-0 translate-x-4 opacity-0`,Ze?`transition-none`:``,U?`quickforge-workspace-inspector-fullscreen z-40 rounded-none border-l-0`:void 0),style:Je?U?void 0:{width:H,minWidth:dr,maxWidth:$}:void 0,children:[Je&&!U?(0,F.jsx)(`div`,{role:`separator`,"aria-orientation":`vertical`,"aria-valuemin":dr,"aria-valuemax":$,"aria-valuenow":H,className:j(`group absolute inset-y-0 -left-2 z-20 flex w-4 cursor-col-resize items-center justify-center bg-transparent transition-colors hover:bg-border/40`,Ze?`bg-border/45`:``),onPointerDown:qt,onPointerMove:Jt,onPointerUp:Yt,onPointerCancel:Yt,children:(0,F.jsx)(`div`,{className:j(`flex h-10 w-3 items-center justify-center rounded-full border border-border bg-background text-muted-foreground/60 opacity-0 shadow-sm transition-opacity`,Ze?`opacity-100`:`group-hover:opacity-100`),children:(0,F.jsx)(x,{className:`size-3`})})}):null,(0,F.jsxs)(`div`,{className:j(`flex h-14 shrink-0 items-center gap-2 border-b border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-3 pr-20 transition-opacity duration-150`,et?`opacity-0`:`opacity-100`),children:[I.length>0?(0,F.jsxs)(`div`,{ref:rt,className:`relative shrink-0`,children:[(0,F.jsx)(`button`,{type:`button`,className:`flex size-9 items-center justify-center rounded-2xl bg-transparent text-muted-foreground/85 transition-colors hover:bg-muted/45 hover:text-foreground/90`,onClick:()=>Ie(e=>!e),"aria-label":k(`rightPanelOpenTabsTitle`),title:k(`rightPanelOpenTabsTitle`),"aria-haspopup":`menu`,"aria-expanded":B,children:(0,F.jsx)(m,{className:j(`size-4 transition-transform`,B&&`rotate-180`)})}),B?(0,F.jsx)(`div`,{className:`absolute left-0 top-12 z-40 w-72 max-w-[calc(100vw-2rem)] rounded-2xl border border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-popover p-2 shadow-quickforge`,role:`menu`,children:I.map(t=>{let n=(t.kind===`reader`?void 0:or[t.kind])?.icon,r=wn(t),i=t.id===R,a=lr(t,e?.name),o=ur(t,a);return(0,F.jsxs)(`div`,{className:j(`group flex h-10 w-full items-center gap-2 rounded-xl px-2 transition-colors`,i?`bg-muted/55 text-foreground`:`text-foreground/86 hover:bg-muted/34 hover:text-foreground`),role:`none`,children:[(0,F.jsxs)(`button`,{type:`button`,className:`flex min-w-0 flex-1 items-center gap-2 text-left text-sm font-medium`,onClick:()=>{Bt(t),Ie(!1)},role:`menuitem`,title:o,children:[r?(0,F.jsx)(xn,{path:r,className:`size-4 shrink-0`}):n?(0,F.jsx)(n,{className:`size-4 shrink-0 text-muted-foreground/80`}):(0,F.jsx)(_,{className:`size-4 shrink-0 text-muted-foreground/80`}),(0,F.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:a})]}),(0,F.jsx)(`button`,{type:`button`,className:`inline-flex size-7 shrink-0 items-center justify-center rounded-full text-muted-foreground/70 opacity-70 transition-colors hover:bg-destructive/10 hover:text-destructive group-hover:opacity-100`,onClick:e=>{e.stopPropagation(),Vt(t.id)},"aria-label":k(`close`),children:(0,F.jsx)(y,{className:`size-3.5`})})]},t.id)})}):null]}):null,(0,F.jsxs)(`div`,{className:`flex min-w-0 flex-1 items-center gap-1 overflow-hidden`,children:[I.map((t,n)=>{let r=(t.kind===`reader`?void 0:or[t.kind])?.icon,i=wn(t),a=t.id===R,o=lr(t,e?.name),s=ur(t,o);return(0,F.jsxs)(`div`,{className:`flex shrink-0 items-center gap-1`,children:[n>0?(0,F.jsx)(`span`,{"aria-hidden":`true`,className:`mx-0.5 h-3.5 w-px bg-[color-mix(in_oklab,var(--muted-foreground)_18%,transparent)]`}):null,(0,F.jsxs)(`button`,{type:`button`,className:j(`group flex h-10 max-w-40 items-center gap-2 rounded-2xl px-3 text-[13px] font-medium transition-colors`,a?`bg-[color-mix(in_oklab,var(--muted)_86%,transparent)] text-foreground/82 hover:bg-[color-mix(in_oklab,var(--muted)_86%,transparent)]`:`text-muted-foreground/45 hover:bg-[color-mix(in_oklab,var(--muted)_72%,transparent)] hover:text-muted-foreground/72`),onClick:()=>Bt(t),title:s,children:[i?(0,F.jsx)(xn,{path:i,className:j(`size-4 shrink-0 transition-opacity`,a?`opacity-100`:`opacity-55 group-hover:opacity-85`)}):r?(0,F.jsx)(r,{className:j(`size-4 shrink-0`,a?`text-foreground/74`:`text-muted-foreground/45 group-hover:text-muted-foreground/72`)}):(0,F.jsx)(_,{className:j(`size-4 shrink-0`,a?`text-foreground/74`:`text-muted-foreground/45 group-hover:text-muted-foreground/72`)}),(0,F.jsx)(`span`,{className:`min-w-0 truncate`,children:o}),(0,F.jsx)(`span`,{role:`button`,tabIndex:0,className:j(`ml-0.5 inline-flex size-5 shrink-0 items-center justify-center rounded-full opacity-0 transition-all hover:bg-black hover:text-white group-hover:opacity-100`,a&&`opacity-100`),onClick:e=>{e.stopPropagation(),Vt(t.id)},onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),e.stopPropagation(),Vt(t.id))},"aria-label":k(`close`),children:(0,F.jsx)(y,{className:`size-3.5`})})]})]},t.id)}),I.length===0?(0,F.jsx)(`div`,{className:`min-w-0 flex-1`}):null]}),I.length>0?(0,F.jsxs)(`div`,{ref:nt,className:`relative shrink-0`,children:[(0,F.jsx)(`button`,{type:`button`,className:`flex size-9 items-center justify-center rounded-2xl bg-transparent text-muted-foreground/85 transition-colors hover:bg-muted/45 hover:text-foreground/90`,onClick:()=>Fe(e=>!e),"aria-label":k(`rightPanelAddTab`),title:k(`rightPanelAddTab`),"aria-haspopup":`menu`,"aria-expanded":Pe,children:(0,F.jsx)(T,{className:`size-4 stroke-[1.9]`})}),Pe?(0,F.jsx)(`div`,{className:`absolute right-0 top-12 z-40 w-64 rounded-2xl border border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-popover p-2 shadow-quickforge`,role:`menu`,children:ir.map(e=>{let t=e.icon;return(0,F.jsxs)(`button`,{type:`button`,className:j(`flex w-full items-center gap-3 rounded-xl px-3 py-2.5 text-left text-[15px] font-medium transition-colors`,e.kind===X?.kind?`bg-muted/55 text-foreground`:`text-foreground/86 hover:bg-muted/34 hover:text-foreground`),onClick:()=>zt(e.kind,sr(e.kind)),role:`menuitem`,children:[(0,F.jsx)(t,{className:`size-4 shrink-0 text-muted-foreground/80`}),(0,F.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:e.label})]},e.kind)})}):null]}):null,(0,F.jsx)(O,{variant:`ghost`,size:`icon`,className:`shrink-0`,onClick:$t,"aria-label":k(U?`workspaceExitFullscreen`:`workspaceFullscreen`),title:k(U?`workspaceExitFullscreen`:`workspaceFullscreen`),children:U?(0,F.jsx)(v,{className:`size-4`}):(0,F.jsx)(i,{className:`size-4`})})]}),(0,F.jsx)(`div`,{className:j(`flex min-h-0 flex-1 transition-opacity duration-150`,et?`opacity-0`:`opacity-100`),children:e?.id?X?X.kind===`browser`?(0,F.jsx)(Ae,{url:X.url||``,onUrlChange:e=>{Q(X.id,t=>({...t,url:e}))},projectId:e.id}):X.kind===`terminal`?(0,F.jsx)(Ce,{project:e,pendingCommand:p,onPendingCommandHandled:g,onCollapse:()=>Vt(X.id),variant:`panel`,singleSession:!0,panelInstanceId:X.id,panelSessionId:X.terminalSessionId,onPanelSessionReady:e=>Q(X.id,t=>({...t,terminalSessionId:e}))},X.id):(0,F.jsxs)(F.Fragment,{children:[gt?(0,F.jsx)(`div`,{className:`flex min-w-0 flex-1 flex-col bg-background`,children:Z?(0,F.jsx)(wr,{project:e,path:Z.path,mode:Z.mode,file:Z.file,diff:Z.diff,loading:Z.loading,error:Z.error,navigationVisible:He,onNavigationVisibleChange:Ue},Z.id):null}):null,gt&&He?(0,F.jsx)(`div`,{role:`separator`,"aria-orientation":`vertical`,"aria-valuemin":mr,"aria-valuemax":gr,"aria-valuenow":Be,className:j(`group relative z-10 w-1.5 shrink-0 cursor-col-resize bg-transparent transition-colors`,We?`bg-primary/30`:`hover:bg-[color-mix(in_oklab,var(--border)_52%,transparent)]`),onPointerDown:Xt,onPointerMove:Zt,onPointerUp:Qt,onPointerCancel:Qt}):null,_t?(0,F.jsx)(`div`,{className:j(`flex min-h-0 min-w-0 flex-col bg-muted/20`,gt?`shrink-0 border-l-[0.5px] border-[color-mix(in_oklab,var(--border)_34%,transparent)]`:`flex-1`),style:gt?{width:Be,minWidth:mr,maxWidth:gr}:void 0,children:_e?(0,F.jsx)(`div`,{className:`p-4 text-sm text-destructive`,children:_e}):(0,F.jsxs)(`div`,{className:j(`min-h-0 min-w-0 flex-1 p-2`,vt===`changes`?`flex flex-col overflow-hidden`:`overflow-auto`),children:[D?(0,F.jsx)(`div`,{className:`px-2 py-3 text-xs text-muted-foreground/70`,children:k(`workspaceLoading`)}):null,!D&&vt===`overview`?(0,F.jsx)(Tr,{project:e,artifacts:f,changesCount:S.length,changedPaths:bt,isGitRepository:ie,gitBranch:ne,onSelectFile:Ut,onSelectDiff:Kt,onPreviewFile:Ht}):null,!D&&vt===`files`?(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)(`div`,{className:`mb-2 flex items-center gap-1`,children:[(0,F.jsxs)(`label`,{className:`flex min-w-0 flex-1 items-center gap-2 rounded-md border-[0.5px] border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-background px-2.5 py-2 text-sm text-muted-foreground/65 focus-within:text-foreground/85`,children:[(0,F.jsx)(h,{className:`size-4 shrink-0`}),(0,F.jsx)(`input`,{value:xe,onChange:e=>Se(e.target.value),placeholder:k(`workspaceFilterFiles`),className:`min-w-0 flex-1 bg-transparent text-sm text-foreground/85 outline-none placeholder:text-muted-foreground/50`})]}),(0,F.jsx)(`button`,{type:`button`,className:`inline-flex size-8 shrink-0 items-center justify-center rounded-xl text-muted-foreground/72 transition-colors hover:bg-muted/30 hover:text-foreground/85 disabled:cursor-not-allowed disabled:opacity-60`,onClick:()=>void It(),disabled:D,"aria-label":k(`refreshWorkspace`),title:k(`refreshWorkspace`),children:(0,F.jsx)(te,{className:j(`size-3.5`,D&&`animate-spin`)})})]}),(0,F.jsx)(Un,{tree:xt,selectedPath:Z?.mode===`file`?Z.path:void 0,gitStatuses:yt,onSelectFile:Ut,onPreviewFile:Ht,projectId:Y})]}):null,!D&&vt===`changes`?ie?(0,F.jsxs)(`div`,{className:`flex min-h-0 min-w-0 flex-1 flex-col`,children:[(0,F.jsxs)(`div`,{className:`flex min-w-0 shrink-0 flex-wrap items-center justify-between gap-x-2 gap-y-1.5 pb-2`,children:[(0,F.jsxs)(`div`,{ref:it,className:`relative min-w-24 flex-1`,children:[(0,F.jsxs)(`button`,{type:`button`,className:`inline-flex h-8 w-full min-w-0 max-w-full items-center gap-2 rounded-xl border border-[color-mix(in_oklab,var(--border)_45%,transparent)] bg-background px-3 text-sm font-medium text-foreground/86 transition-colors hover:border-border/60 hover:bg-muted/30 hover:text-foreground`,onClick:()=>Le(e=>!e),"aria-haspopup":`menu`,"aria-expanded":V,title:k(`workspaceReviewFilter`),children:[(0,F.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-left`,children:ar.find(e=>e.value===M)?.label}),(0,F.jsx)(m,{className:j(`size-3.5 shrink-0 text-muted-foreground/70 transition-transform`,V&&`rotate-180`)})]}),V?(0,F.jsx)(`div`,{className:`absolute left-0 top-10 z-40 w-48 rounded-2xl border border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-popover p-1.5 shadow-quickforge`,role:`menu`,"aria-label":k(`workspaceReviewFilter`),children:ar.map(e=>{let t=e.value===M;return(0,F.jsxs)(`button`,{type:`button`,className:j(`flex h-9 w-full items-center gap-2 rounded-xl px-2.5 text-left text-sm font-medium transition-colors`,t?`bg-muted/55 text-foreground`:`text-foreground/82 hover:bg-muted/34 hover:text-foreground`),onClick:()=>{we(e.value),Le(!1)},role:`menuitemradio`,"aria-checked":t,children:[(0,F.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:e.label}),t?(0,F.jsx)(w,{className:`size-3.5 shrink-0 text-muted-foreground/80`}):null]},e.value)})}):null]}),(0,F.jsxs)(`div`,{className:`ml-auto flex shrink-0 items-center gap-1`,children:[(0,F.jsx)(`button`,{type:`button`,className:`inline-flex size-8 shrink-0 items-center justify-center rounded-xl text-muted-foreground/72 transition-colors hover:bg-muted/30 hover:text-foreground/85 disabled:cursor-not-allowed disabled:opacity-60`,onClick:()=>void It(),disabled:D,"aria-label":k(`refreshWorkspace`),title:k(`refreshWorkspace`),children:(0,F.jsx)(te,{className:j(`size-3.5`,D&&`animate-spin`)})}),(0,F.jsx)(ce,{project:e,disabledTargets:wt?.status===`deleted`?{vscode:!0,idea:!0}:void 0,targetDisabledLabel:k(`workspaceCannotOpenDeletedFile`),onOpenInExplorer:()=>{Pt(`explorer`)},onOpenInVSCode:()=>{Pt(`vscode`)},onOpenInIDEA:()=>{Pt(`idea`)}}),r?(0,F.jsx)(`button`,{type:`button`,className:`inline-flex size-8 shrink-0 items-center justify-center rounded-xl text-muted-foreground/72 transition-colors hover:bg-muted/30 hover:text-foreground/85`,onClick:r,"aria-label":k(`gitToolsCommitOrPush`),title:k(`gitToolsCommitOrPush`),children:(0,F.jsx)(o,{className:`size-3.5`})}):null]})]}),(0,F.jsx)(zn,{files:Ct,selectedPath:N,expandedDiff:Ee,expandedLoading:Oe,expandedError:je,onSelectFile:Gt,onRestoreFile:jt,onStageFile:Dt,onUnstageFile:kt,onOpenFile:Nt,onRestoreAll:Mt,onStageAll:Ot,onUnstageAll:At,showUnstageAll:M===`staged`,pendingAction:Re,emptyMessage:xr(M)})]}):(0,F.jsx)(`div`,{className:`px-2 py-3 text-xs text-muted-foreground/70`,children:k(`workspaceNotGitRepository`)}):null]})}):null]}):(0,F.jsx)(`div`,{className:`flex min-h-0 flex-1 items-center justify-center px-5`,children:(0,F.jsxs)(`div`,{className:`w-full max-w-[26rem] space-y-4`,children:[(0,F.jsxs)(`div`,{className:`text-center font-sans`,children:[(0,F.jsx)(`div`,{className:`text-lg font-semibold leading-tight tracking-[-0.01em] text-foreground/90`,children:k(`rightPanelOpenTabsTitle`)}),(0,F.jsx)(`div`,{className:`mt-2 text-sm leading-5 text-muted-foreground/70`,children:k(`rightPanelOpenTabsDescription`)})]}),(0,F.jsx)(`div`,{className:`space-y-2`,children:ir.map(e=>{let t=e.icon;return(0,F.jsxs)(`button`,{type:`button`,className:`flex w-full cursor-pointer items-center gap-3 rounded-xl border border-[color-mix(in_oklab,var(--border)_34%,transparent)] bg-muted/60 px-4 py-3 text-left transition-colors hover:bg-muted/72 active:bg-muted/82`,onClick:()=>zt(e.kind,sr(e.kind)),children:[(0,F.jsx)(t,{className:`size-4 shrink-0 text-muted-foreground/78`}),(0,F.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,F.jsx)(`div`,{className:`text-sm font-medium text-foreground/90`,children:e.label}),(0,F.jsx)(`div`,{className:`mt-0.5 text-xs leading-4 text-muted-foreground/60`,children:e.description})]})]},e.kind)})})]})}):(0,F.jsx)(`div`,{className:`p-4 text-sm text-muted-foreground/70`,children:k(`workspaceSelectProject`)})})]})}):null}export{Er as WorkspaceInspector};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e,t}from"./rolldown-runtime-DWdDZTNf.js";var n=t((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function k(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var A=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?k(``+e.key):t.toString(36)}function M(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function N(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,N(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(A,`$&/`)+`/`),N(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(A,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+j(a,u),c+=N(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+j(a,u++),c+=N(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return N(M(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function P(e,t,n){if(e==null)return e;var r=[],i=0;return N(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function F(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var I=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},L={map:P,forEach:function(e,t,n){P(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return P(e,function(){t++}),t},toArray:function(e){return P(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=L,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:F}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,I)}catch(e){I(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.5`})),r=t(((e,t)=>{t.exports=n()})),i=e(r(),1),a=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),o=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),s=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),c=e=>{let t=s(e);return t.charAt(0).toUpperCase()+t.slice(1)},l={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`},u=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},d=(0,i.createContext)({});function f({children:e,size:t,color:n,strokeWidth:r,absoluteStrokeWidth:a,className:o}){let s=(0,i.useMemo)(()=>({size:t,color:n,strokeWidth:r,absoluteStrokeWidth:a,className:o}),[t,n,r,a,o]);return(0,i.createElement)(d.Provider,{value:s},e)}var p=()=>(0,i.useContext)(d),m=(0,i.forwardRef)(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:r,className:o=``,children:s,iconNode:c,...d},f)=>{let{size:m=24,strokeWidth:h=2,absoluteStrokeWidth:g=!1,color:_=`currentColor`,className:v=``}=p()??{},y=r??g?Number(n??h)*24/Number(t??m):n??h;return(0,i.createElement)(`svg`,{ref:f,...l,width:t??m??l.width,height:t??m??l.height,stroke:e??_,strokeWidth:y,className:a(`lucide`,v,o),...!s&&!u(d)&&{"aria-hidden":`true`},...d},[...c.map(([e,t])=>(0,i.createElement)(e,t)),...Array.isArray(s)?s:[s]])}),h=(e,t)=>{let n=(0,i.forwardRef)(({className:n,...r},s)=>(0,i.createElement)(m,{ref:s,iconNode:t,className:a(`lucide-${o(c(e))}`,`lucide-${e}`,n),...r}));return n.displayName=c(e),n},g=h(`archive`,[[`rect`,{width:`20`,height:`5`,x:`2`,y:`3`,rx:`1`,key:`1wp1u1`}],[`path`,{d:`M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8`,key:`1s80jp`}],[`path`,{d:`M10 12h4`,key:`a56b0p`}]]),_=h(`arrow-left`,[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]),v=h(`arrow-up-from-line`,[[`path`,{d:`m18 9-6-6-6 6`,key:`kcunyi`}],[`path`,{d:`M12 3v14`,key:`7cf3v8`}],[`path`,{d:`M5 21h14`,key:`11awu3`}]]),y=h(`book-open`,[[`path`,{d:`M12 7v14`,key:`1akyts`}],[`path`,{d:`M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z`,key:`ruj8y`}]]),b=h(`bot`,[[`path`,{d:`M12 8V4H8`,key:`hb8ula`}],[`rect`,{width:`16`,height:`12`,x:`4`,y:`8`,rx:`2`,key:`enze0r`}],[`path`,{d:`M2 14h2`,key:`vft8re`}],[`path`,{d:`M20 14h2`,key:`4cs60a`}],[`path`,{d:`M15 13v2`,key:`1xurst`}],[`path`,{d:`M9 13v2`,key:`rq6x2g`}]]),x=h(`brain`,[[`path`,{d:`M12 18V5`,key:`adv99a`}],[`path`,{d:`M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4`,key:`1e3is1`}],[`path`,{d:`M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5`,key:`1gqd8o`}],[`path`,{d:`M17.997 5.125a4 4 0 0 1 2.526 5.77`,key:`iwvgf7`}],[`path`,{d:`M18 18a4 4 0 0 0 2-7.464`,key:`efp6ie`}],[`path`,{d:`M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517`,key:`1gq6am`}],[`path`,{d:`M6 18a4 4 0 0 1-2-7.464`,key:`k1g0md`}],[`path`,{d:`M6.003 5.125a4 4 0 0 0-2.526 5.77`,key:`q97ue3`}]]),S=h(`calendar-clock`,[[`path`,{d:`M16 14v2.2l1.6 1`,key:`fo4ql5`}],[`path`,{d:`M16 2v4`,key:`4m81vk`}],[`path`,{d:`M21 7.5V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h3.5`,key:`1osxxc`}],[`path`,{d:`M3 10h5`,key:`r794hk`}],[`path`,{d:`M8 2v4`,key:`1cmpym`}],[`circle`,{cx:`16`,cy:`16`,r:`6`,key:`qoo3c4`}]]),C=h(`calendar-plus`,[[`path`,{d:`M16 19h6`,key:`xwg31i`}],[`path`,{d:`M16 2v4`,key:`4m81vk`}],[`path`,{d:`M19 16v6`,key:`tddt3s`}],[`path`,{d:`M21 12.598V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h8.5`,key:`1glfrc`}],[`path`,{d:`M3 10h18`,key:`8toen8`}],[`path`,{d:`M8 2v4`,key:`1cmpym`}]]),w=h(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),T=h(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),E=h(`chevron-left`,[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]),D=h(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),O=h(`chevrons-down-up`,[[`path`,{d:`m7 20 5-5 5 5`,key:`13a0gw`}],[`path`,{d:`m7 4 5 5 5-5`,key:`1kwcof`}]]),k=h(`chevrons-left-right`,[[`path`,{d:`m9 7-5 5 5 5`,key:`j5w590`}],[`path`,{d:`m15 7 5 5-5 5`,key:`1bl6da`}]]),A=h(`chevrons-up-down`,[[`path`,{d:`m7 15 5 5 5-5`,key:`1hf1tw`}],[`path`,{d:`m7 9 5-5 5 5`,key:`sgt6xg`}]]),j=h(`circle-check-big`,[[`path`,{d:`M21.801 10A10 10 0 1 1 17 3.335`,key:`yps3ct`}],[`path`,{d:`m9 11 3 3L22 4`,key:`1pflzl`}]]),M=h(`circle-check`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),N=h(`circle-x`,[[`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`}]]),P=h(`clock-3`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6h4`,key:`135r8i`}]]),F=h(`clock`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6l4 2`,key:`mmk7yg`}]]),I=h(`cloud-download`,[[`path`,{d:`M12 13v8l-4-4`,key:`1f5nwf`}],[`path`,{d:`m12 21 4-4`,key:`1lfcce`}],[`path`,{d:`M4.393 15.269A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.436 8.284`,key:`ui1hmy`}]]),L=h(`cloud-upload`,[[`path`,{d:`M12 13v8`,key:`1l5pq0`}],[`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:`m8 17 4-4 4 4`,key:`1quai1`}]]),ee=h(`code-xml`,[[`path`,{d:`m18 16 4-4-4-4`,key:`1inbqp`}],[`path`,{d:`m6 8-4 4 4 4`,key:`15zrgr`}],[`path`,{d:`m14.5 4-5 16`,key:`e7oirm`}]]),te=h(`copy`,[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),R=h(`corner-down-left`,[[`path`,{d:`M20 4v7a4 4 0 0 1-4 4H4`,key:`6o5b7l`}],[`path`,{d:`m9 10-5 5 5 5`,key:`1kshq7`}]]),z=h(`database`,[[`ellipse`,{cx:`12`,cy:`5`,rx:`9`,ry:`3`,key:`msslwz`}],[`path`,{d:`M3 5V19A9 3 0 0 0 21 19V5`,key:`1wlel7`}],[`path`,{d:`M3 12A9 3 0 0 0 21 12`,key:`mv7ke4`}]]),B=h(`earth`,[[`path`,{d:`M21.54 15H17a2 2 0 0 0-2 2v4.54`,key:`1djwo0`}],[`path`,{d:`M7 3.34V5a3 3 0 0 0 3 3a2 2 0 0 1 2 2c0 1.1.9 2 2 2a2 2 0 0 0 2-2c0-1.1.9-2 2-2h3.17`,key:`1tzkfa`}],[`path`,{d:`M11 21.95V18a2 2 0 0 0-2-2a2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05`,key:`14pb5j`}],[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}]]),V=h(`ellipsis-vertical`,[[`circle`,{cx:`12`,cy:`12`,r:`1`,key:`41hilf`}],[`circle`,{cx:`12`,cy:`5`,r:`1`,key:`gxeob9`}],[`circle`,{cx:`12`,cy:`19`,r:`1`,key:`lyex9k`}]]),H=h(`ellipsis`,[[`circle`,{cx:`12`,cy:`12`,r:`1`,key:`41hilf`}],[`circle`,{cx:`19`,cy:`12`,r:`1`,key:`1wjl8i`}],[`circle`,{cx:`5`,cy:`12`,r:`1`,key:`1pcz8c`}]]),U=h(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]),W=h(`eye`,[[`path`,{d:`M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0`,key:`1nclc0`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),G=h(`file-braces`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`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`}]]),K=h(`file-diff`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M9 10h6`,key:`9gxzsh`}],[`path`,{d:`M12 13V7`,key:`h0r20n`}],[`path`,{d:`M9 17h6`,key:`r8uit2`}]]),q=h(`folder-open`,[[`path`,{d:`m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2`,key:`usdka0`}]]),J=h(`folder-plus`,[[`path`,{d:`M12 10v6`,key:`1bos4e`}],[`path`,{d:`M9 13h6`,key:`1uhe8q`}],[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),Y=h(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),X=h(`gauge`,[[`path`,{d:`m12 14 4-4`,key:`9kzdfg`}],[`path`,{d:`M3.34 19a10 10 0 1 1 17.32 0`,key:`19p75a`}]]),Z=h(`git-branch`,[[`path`,{d:`M15 6a9 9 0 0 0-9 9V3`,key:`1cii5b`}],[`circle`,{cx:`18`,cy:`6`,r:`3`,key:`1h7g24`}],[`circle`,{cx:`6`,cy:`18`,r:`3`,key:`fqmcym`}]]),Q=h(`git-commit-horizontal`,[[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}],[`line`,{x1:`3`,x2:`9`,y1:`12`,y2:`12`,key:`1dyftd`}],[`line`,{x1:`15`,x2:`21`,y1:`12`,y2:`12`,key:`oup4p8`}]]),ne=h(`git-graph`,[[`circle`,{cx:`5`,cy:`6`,r:`3`,key:`1qnov2`}],[`path`,{d:`M5 9v6`,key:`158jrl`}],[`circle`,{cx:`5`,cy:`18`,r:`3`,key:`104gr9`}],[`path`,{d:`M12 3v18`,key:`108xh3`}],[`circle`,{cx:`19`,cy:`6`,r:`3`,key:`108a5v`}],[`path`,{d:`M16 15.7A9 9 0 0 0 19 9`,key:`1e3vqb`}]]),re=h(`globe`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,key:`13o1zl`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}]]),ie=h(`info`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 16v-4`,key:`1dtifu`}],[`path`,{d:`M12 8h.01`,key:`e9boi3`}]]),ae=h(`list`,[[`path`,{d:`M3 5h.01`,key:`18ugdj`}],[`path`,{d:`M3 12h.01`,key:`nlz23k`}],[`path`,{d:`M3 19h.01`,key:`noohij`}],[`path`,{d:`M8 5h13`,key:`1pao27`}],[`path`,{d:`M8 12h13`,key:`1za7za`}],[`path`,{d:`M8 19h13`,key:`m83p4d`}]]),oe=h(`loader-circle`,[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]]),se=h(`log-out`,[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]),ce=h(`maximize-2`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`m21 3-7 7`,key:`1l2asr`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M9 21H3v-6`,key:`wtvkvv`}]]),le=h(`menu`,[[`path`,{d:`M4 5h16`,key:`1tepv9`}],[`path`,{d:`M4 12h16`,key:`1lakjw`}],[`path`,{d:`M4 19h16`,key:`1djgab`}]]),ue=h(`message-square-plus`,[[`path`,{d:`M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z`,key:`18887p`}],[`path`,{d:`M12 8v6`,key:`1ib9pf`}],[`path`,{d:`M9 11h6`,key:`1fldmi`}]]),de=h(`message-square-text`,[[`path`,{d:`M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z`,key:`18887p`}],[`path`,{d:`M7 11h10`,key:`1twpyw`}],[`path`,{d:`M7 15h6`,key:`d9of3u`}],[`path`,{d:`M7 7h8`,key:`af5zfr`}]]),fe=h(`minimize-2`,[[`path`,{d:`m14 10 7-7`,key:`oa77jy`}],[`path`,{d:`M20 10h-6V4`,key:`mjg0md`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M4 14h6v6`,key:`rmj7iw`}]]),pe=h(`minus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}]]),me=h(`palette`,[[`path`,{d:`M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z`,key:`e79jfc`}],[`circle`,{cx:`13.5`,cy:`6.5`,r:`.5`,fill:`currentColor`,key:`1okk4w`}],[`circle`,{cx:`17.5`,cy:`10.5`,r:`.5`,fill:`currentColor`,key:`f64h9f`}],[`circle`,{cx:`6.5`,cy:`12.5`,r:`.5`,fill:`currentColor`,key:`qy21gx`}],[`circle`,{cx:`8.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`fotxhn`}]]),he=h(`panel-left-open`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}],[`path`,{d:`m14 9 3 3-3 3`,key:`8010ee`}]]),ge=h(`panel-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}]]),_e=h(`panel-right`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M15 3v18`,key:`14nvp0`}]]),ve=h(`pen-line`,[[`path`,{d:`M13 21h8`,key:`1jsn5i`}],[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}]]),ye=h(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),be=h(`pin-off`,[[`path`,{d:`M12 17v5`,key:`bb1du9`}],[`path`,{d:`M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89`,key:`znwnzq`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}],[`path`,{d:`M9 9v1.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h11`,key:`c9qhm2`}]]),xe=h(`pin`,[[`path`,{d:`M12 17v5`,key:`bb1du9`}],[`path`,{d:`M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z`,key:`1nkz8b`}]]),Se=h(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),Ce=h(`puzzle`,[[`path`,{d:`M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z`,key:`w46dr5`}]]),we=h(`refresh-cw`,[[`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,key:`v9h5vc`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}],[`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,key:`3uifl3`}],[`path`,{d:`M8 16H3v5`,key:`1cv678`}]]),Te=h(`rotate-ccw`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}]]),Ee=h(`rotate-cw`,[[`path`,{d:`M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8`,key:`1p45f6`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}]]),De=h(`search`,[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]),Oe=h(`server`,[[`rect`,{width:`20`,height:`8`,x:`2`,y:`2`,rx:`2`,ry:`2`,key:`ngkwjq`}],[`rect`,{width:`20`,height:`8`,x:`2`,y:`14`,rx:`2`,ry:`2`,key:`iecqi9`}],[`line`,{x1:`6`,x2:`6.01`,y1:`6`,y2:`6`,key:`16zg32`}],[`line`,{x1:`6`,x2:`6.01`,y1:`18`,y2:`18`,key:`nzw8ys`}]]),ke=h(`settings`,[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),Ae=h(`settings-2`,[[`path`,{d:`M14 17H5`,key:`gfn3mx`}],[`path`,{d:`M19 7h-9`,key:`6i9tg`}],[`circle`,{cx:`17`,cy:`17`,r:`3`,key:`18b49y`}],[`circle`,{cx:`7`,cy:`7`,r:`3`,key:`dfmy0x`}]]),je=h(`share-2`,[[`circle`,{cx:`18`,cy:`5`,r:`3`,key:`gq8acd`}],[`circle`,{cx:`6`,cy:`12`,r:`3`,key:`w7nqdw`}],[`circle`,{cx:`18`,cy:`19`,r:`3`,key:`1xt0gg`}],[`line`,{x1:`8.59`,x2:`15.42`,y1:`13.51`,y2:`17.49`,key:`47mynk`}],[`line`,{x1:`15.41`,x2:`8.59`,y1:`6.51`,y2:`10.49`,key:`1n3mei`}]]),Me=h(`shield-check`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),Ne=h(`shield`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}]]),Pe=h(`sliders-horizontal`,[[`path`,{d:`M10 5H3`,key:`1qgfaw`}],[`path`,{d:`M12 19H3`,key:`yhmn1j`}],[`path`,{d:`M14 3v4`,key:`1sua03`}],[`path`,{d:`M16 17v4`,key:`1q0r14`}],[`path`,{d:`M21 12h-9`,key:`1o4lsq`}],[`path`,{d:`M21 19h-5`,key:`1rlt1p`}],[`path`,{d:`M21 5h-7`,key:`1oszz2`}],[`path`,{d:`M8 10v4`,key:`tgpxqk`}],[`path`,{d:`M8 12H3`,key:`a7s4jb`}]]),$=h(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),Fe=h(`square-terminal`,[[`path`,{d:`m7 11 2-2-2-2`,key:`1lz0vl`}],[`path`,{d:`M11 13h4`,key:`1p7l4v`}],[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,ry:`2`,key:`1m3agn`}]]),Ie=h(`tag`,[[`path`,{d:`M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z`,key:`vktsd0`}],[`circle`,{cx:`7.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`kqv944`}]]),Le=h(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),Re=h(`triangle-alert`,[[`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-3`,key:`wmoenq`}],[`path`,{d:`M12 9v4`,key:`juzpu7`}],[`path`,{d:`M12 17h.01`,key:`p32p05`}]]),ze=h(`wrench`,[[`path`,{d:`M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z`,key:`1ngwbx`}]]),Be=h(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),Ve=h(`zap`,[[`path`,{d:`M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z`,key:`1xq2db`}]]);export{V as $,pe as A,re as B,be as C,y as Ct,ge as D,f as Dt,_e as E,g as Et,ce as F,Y as G,Q as H,se as I,K as J,J as K,oe as L,de as M,ue as N,he as O,r as Ot,le as P,H as Q,ae as R,xe as S,b as St,ve as T,_ as Tt,Z as U,ne as V,X as W,W as X,G as Y,U as Z,Ee as _,T as _t,Le as a,L as at,Ce as b,S as bt,$ as c,P as ct,Me as d,j as dt,B as et,je as f,A as ft,De as g,E as gt,Oe as h,D as ht,Re as i,ee as it,fe as j,me as k,Pe as l,N as lt,ke as m,O as mt,Be as n,R as nt,Ie as o,I as ot,Ae as p,k as pt,q,ze as r,te as rt,Fe as s,F as st,Ve as t,z as tt,Ne as u,M as ut,Te as v,w as vt,ye as w,v as wt,Se as x,x as xt,we as y,C as yt,ie as z};
|