@yxp934/prompt-tree 0.1.0 → 0.2.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/.next/standalone/.next/BUILD_ID +1 -1
- package/.next/standalone/.next/app-path-routes-manifest.json +3 -3
- package/.next/standalone/.next/build-manifest.json +2 -2
- package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_global-error.html +2 -2
- package/.next/standalone/.next/server/app/_global-error.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found/page.js +2 -2
- package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found.html +1 -1
- package/.next/standalone/.next/server/app/_not-found.rsc +14 -13
- package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +14 -13
- package/.next/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +5 -4
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/api/agent/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/chat/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/providers/health/route.js +1 -1
- package/.next/standalone/.next/server/app/api/providers/health/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/providers/models/route.js +1 -1
- package/.next/standalone/.next/server/app/api/providers/models/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/providers/test/route.js +1 -1
- package/.next/standalone/.next/server/app/api/providers/test/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tools/mcp/call-tool/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tools/mcp/list-tools/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tools/mcp/test/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tools/python/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tools/search/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/index.html +2 -2
- package/.next/standalone/.next/server/app/index.rsc +15 -14
- package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +15 -14
- package/.next/standalone/.next/server/app/index.segments/_head.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/index.segments/_index.segment.rsc +5 -4
- package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/page.js +3 -3
- package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/settings/page.js +2 -2
- package/.next/standalone/.next/server/app/settings/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/settings.html +1 -1
- package/.next/standalone/.next/server/app/settings.rsc +15 -14
- package/.next/standalone/.next/server/app/settings.segments/_full.segment.rsc +15 -14
- package/.next/standalone/.next/server/app/settings.segments/_head.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/settings.segments/_index.segment.rsc +5 -4
- package/.next/standalone/.next/server/app/settings.segments/_tree.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/settings.segments/settings.segment.rsc +1 -1
- package/.next/standalone/.next/server/app-paths-manifest.json +3 -3
- package/.next/standalone/.next/server/chunks/{368.js → 116.js} +1 -1
- package/.next/standalone/.next/server/chunks/689.js +1 -0
- package/.next/standalone/.next/server/chunks/732.js +30 -0
- package/.next/standalone/.next/server/chunks/734.js +1 -0
- package/.next/standalone/.next/server/chunks/913.js +2 -2
- package/.next/standalone/.next/server/pages/404.html +1 -1
- package/.next/standalone/.next/server/pages/500.html +2 -2
- package/.next/standalone/.next/static/chunks/308-9aca2a7bf1797568.js +2 -0
- package/.next/standalone/.next/static/chunks/394-1e8c9367852fd6d7.js +30 -0
- package/.next/standalone/.next/static/chunks/787-56a48f915165efd3.js +1 -0
- package/.next/standalone/.next/static/chunks/app/layout-7950581b06dcfcd2.js +1 -0
- package/.next/standalone/.next/static/chunks/app/page-c273f2f3b7ce1609.js +1 -0
- package/.next/standalone/.next/static/chunks/app/settings/page-0fc8a4cbf639025c.js +1 -0
- package/.next/standalone/.next/static/css/100bba9d1b2ebade.css +1 -0
- package/.next/standalone/package.json +1 -1
- package/README.md +32 -26
- package/package.json +1 -1
- package/.next/standalone/.next/server/chunks/852.js +0 -30
- package/.next/standalone/.next/server/chunks/918.js +0 -1
- package/.next/standalone/.next/static/chunks/745-34771ca05b57a010.js +0 -2
- package/.next/standalone/.next/static/chunks/769-1bd3beb633de2683.js +0 -30
- package/.next/standalone/.next/static/chunks/app/layout-cf74cd021b6f9316.js +0 -1
- package/.next/standalone/.next/static/chunks/app/page-bba3294cfe651287.js +0 -1
- package/.next/standalone/.next/static/chunks/app/settings/page-9b21761d8caa6149.js +0 -1
- package/.next/standalone/.next/static/css/990efe10b798511e.css +0 -1
- /package/.next/standalone/.next/static/{YhDyHybhyTmPCC6Vg7eEa → wYfac0R-RsurEa801s_qH}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{YhDyHybhyTmPCC6Vg7eEa → wYfac0R-RsurEa801s_qH}/_ssgManifest.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[662],{92:(e,t,s)=>{"use strict";s.d(t,{ConnectedModelSelector:()=>x});var r=s(5155),n=s(2115),o=s(4394),a=s(513),l=s(1766),i=s(6222);function d({category:e,models:t,selectedIds:s,onToggle:o,onAddSelected:l}){let d=(0,a.k)(),[c,x]=(0,n.useState)(!0);if(0===t.length)return null;let h=t.filter(e=>s.has(e.id)),m=d("chat"===e?"modelCategory.chat":"reasoning"===e?"modelCategory.reasoning":"vision"===e?"modelCategory.vision":"embedding"===e?"modelCategory.embedding":"tool"===e?"modelCategory.tool":"modelCategory.other");return(0,r.jsxs)("div",{className:"mb-3 rounded-xl border border-parchment bg-cream overflow-hidden",children:[(0,r.jsxs)("button",{type:"button",className:"flex w-full items-center gap-3 px-4 py-3 text-left transition-colors hover:bg-paper/50",onClick:()=>x(!c),children:[(0,r.jsx)("span",{className:`transition-transform duration-200 ${c?"rotate-0":"-rotate-90"}`,children:(0,r.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:(0,r.jsx)("path",{d:"m6 9 6 6 6-6"})})}),(0,r.jsx)("span",{className:"flex-1 font-body text-[0.9rem] font-medium text-ink",children:m}),(0,r.jsx)("span",{className:"rounded-full bg-parchment px-2 py-0.5 font-mono text-[0.7rem] text-clay",children:t.length}),h.length>0&&(0,r.jsx)("button",{type:"button",className:"rounded-lg bg-copper px-2.5 py-1 font-body text-[0.8rem] text-white transition-colors hover:bg-copper/90",onClick:e=>{e.stopPropagation(),l()},children:d("modelSelector.addCount",{count:h.length})})]}),c&&(0,r.jsx)("div",{className:"border-t border-parchment px-4 pb-3",children:(0,r.jsx)("div",{className:"space-y-1 pt-2",children:t.map(e=>{let t=s.has(e.id);return(0,r.jsxs)("div",{className:`group flex items-center gap-3 rounded-lg px-3 py-2.5 transition-all ${t?"bg-copper/10":"hover:bg-paper/50"}`,children:[(0,r.jsx)("button",{type:"button",className:`flex h-5 w-5 flex-shrink-0 items-center justify-center rounded border transition-all ${t?"border-copper bg-copper text-white":"border-parchment bg-transparent hover:border-sand"}`,onClick:()=>o(e.id),children:t&&(0,r.jsx)(i.Sr,{})}),(0,r.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,r.jsx)("div",{className:"font-mono text-[0.85rem] text-ink truncate",children:e.id}),e.name!==e.id&&(0,r.jsx)("div",{className:"font-body text-[0.75rem] text-sand truncate",children:e.name})]})]},e.id)})})})]})}function c({open:e,onClose:t}){let s=(0,a.k)(),c=(0,o.CU)(e=>e.providers),x=(0,o.CU)(e=>e.modelSelector);(0,o.CU)(e=>e.closeModelSelector);let h=(0,o.CU)(e=>e.setModelSelectorSearch),m=(0,o.CU)(e=>e.setModelSelectorTab),p=(0,o.CU)(e=>e.fetchModelsForSelector),g=(0,o.CU)(e=>e.addFetchedModels),[u,b]=(0,n.useState)(new Set),f=c.find(e=>e.id===x.providerId),y=new Set(f?.models.map(e=>e.id)||[]),j=x.fetchedModels.filter(e=>!y.has(e.id)).filter(e=>{let t=!x.searchQuery||e.id.toLowerCase().includes(x.searchQuery.toLowerCase())||e.name.toLowerCase().includes(x.searchQuery.toLowerCase()),s="all"===x.activeTab||e.category===x.activeTab;return t&&s}),v={};for(let e of j){let t=e.category||"chat";v[t]||(v[t]=[]),v[t].push(e)}let N=e=>{b(t=>{let s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s})};return((0,n.useEffect)(()=>{e&&f&&0===x.fetchedModels.length&&p(f.id)},[e]),(0,n.useEffect)(()=>{e||b(new Set)},[e]),e)?(0,r.jsxs)("div",{className:"fixed inset-0 z-50 flex",children:[(0,r.jsx)("div",{className:"absolute inset-0 bg-ink/20 backdrop-blur-sm",onClick:t}),(0,r.jsxs)("div",{className:"relative mx-auto my-8 flex h-full w-full max-w-xl flex-col rounded-2xl bg-paper shadow-xl",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between border-b border-parchment px-6 py-4",children:[(0,r.jsxs)("h3",{className:"font-display text-xl text-ink",children:[f?.name||s("modelSelector.providerFallback")," - ",s("modelSelector.models")]}),(0,r.jsx)("button",{type:"button",className:"rounded-lg p-2 text-clay transition-colors hover:text-ink",onClick:t,children:(0,r.jsx)(i.US,{})})]}),(0,r.jsx)("div",{className:"border-b border-parchment px-6 py-4",children:(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsxs)("div",{className:"flex-1 relative",children:[(0,r.jsx)(i.WI,{}),(0,r.jsx)("input",{type:"text",value:x.searchQuery,onChange:e=>h(e.target.value),placeholder:s("modelSelector.searchPlaceholder"),className:"w-full rounded-xl border border-parchment bg-cream pl-10 pr-4 py-2.5 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]"})]}),(0,r.jsx)("button",{type:"button",className:`flex-shrink-0 rounded-xl border border-parchment p-2.5 text-clay transition-all hover:border-copper hover:text-copper ${x.isLoading?"animate-spin":""}`,onClick:()=>{f&&p(f.id)},disabled:x.isLoading,children:(0,r.jsx)(i.fN,{})})]})}),(0,r.jsx)("div",{className:"flex items-center gap-1 border-b border-parchment px-6 py-3 overflow-x-auto",children:["all","chat","reasoning","vision","embedding","tool"].map(e=>(0,r.jsx)("button",{type:"button",className:`whitespace-nowrap rounded-lg px-3 py-1.5 font-body text-[0.8rem] transition-all ${x.activeTab===e?"bg-copper text-white":"text-clay hover:bg-cream hover:text-ink"}`,onClick:()=>m(e),children:(e=>{switch(e){case"all":return s("modelCategory.all");case"chat":return s("modelCategory.chat");case"reasoning":return s("modelCategory.reasoning");case"vision":return s("modelCategory.vision");case"embedding":return s("modelCategory.embedding");case"tool":return s("modelCategory.tool");default:return s("modelCategory.other")}})(e)},e))}),(0,r.jsx)("div",{className:"flex-1 overflow-y-auto px-6 py-4",children:x.isLoading?(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center py-12",children:[(0,r.jsx)("div",{className:"mb-4 h-8 w-8 animate-spin rounded-full border-2 border-copper border-t-transparent"}),(0,r.jsx)("p",{className:"font-body text-[0.9rem] text-sand",children:s("modelSelector.fetching")})]}):x.error?(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center py-12",children:[(0,r.jsx)("div",{className:"mb-4 text-red-400",children:(0,r.jsxs)("svg",{width:"48",height:"48",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",children:[(0,r.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,r.jsx)("path",{d:"m15 9-6 6m0-6 6 6"})]})}),(0,r.jsx)("p",{className:"mb-1 font-body text-[0.9rem] text-clay",children:s("modelSelector.fetchFailed")}),(0,r.jsx)("p",{className:"font-body text-[0.8rem] text-sand",children:(0,l.d)(x.error)?s(x.error):x.error})]}):0===j.length?(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center py-12",children:[(0,r.jsx)("div",{className:"mb-4 text-sand",children:(0,r.jsxs)("svg",{width:"48",height:"48",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1",children:[(0,r.jsx)("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2"}),(0,r.jsx)("path",{d:"M9 9h6v6H9z"})]})}),(0,r.jsx)("p",{className:"mb-1 font-body text-[0.9rem] text-clay",children:x.searchQuery?s("modelSelector.noMatches"):s("modelSelector.noModels")}),(0,r.jsx)("p",{className:"font-body text-[0.8rem] text-sand",children:x.searchQuery?s("modelSelector.tryOtherQuery"):s("modelSelector.configureApiKey")})]}):(0,r.jsx)("div",{children:Object.entries(v).map(([e,t])=>(0,r.jsx)(d,{category:e,models:t,selectedIds:u,onToggle:N,onAddSelected:()=>{let e=t.filter(e=>u.has(e.id)).map(e=>e.id);e.length>0&&(g(e),e.forEach(e=>u.delete(e)),b(new Set(u)))}},e))})}),u.size>0&&(0,r.jsxs)("div",{className:"flex items-center justify-between border-t border-parchment px-6 py-4",children:[(0,r.jsx)("span",{className:"font-body text-[0.85rem] text-sand",children:s("modelSelector.selectedCount",{count:u.size})}),(0,r.jsxs)("button",{type:"button",className:"flex items-center gap-2 rounded-lg bg-copper px-4 py-2.5 font-body text-[0.9rem] text-white transition-colors hover:bg-copper/90",onClick:()=>{u.size>0&&(g(Array.from(u)),b(new Set))},children:[(0,r.jsx)(i.c1,{}),s("modelSelector.addSelected")]})]})]})]}):null}function x(){let e=(0,o.CU)(e=>e.modelSelector),t=(0,o.CU)(e=>e.closeModelSelector);return(0,r.jsx)(c,{open:e.open,onClose:t})}},3409:(e,t,s)=>{Promise.resolve().then(s.bind(s,92)),Promise.resolve().then(s.bind(s,9362)),Promise.resolve().then(s.bind(s,6531)),Promise.resolve().then(s.bind(s,4333)),Promise.resolve().then(s.bind(s,7977))},4333:(e,t,s)=>{"use strict";s.d(t,{SettingsPage:()=>T});var r=s(5155),n=s(8500),o=s.n(n),a=s(2115),l=s(4394),i=s(513),d=s(6531),c=s(9362),x=s(7977),h=s(92),m=s(1379),p=s(3653),g=s(6290),u=s(4752),b=s(9113),f=s(8353),y=s(5746),j=s(5989),v=s(5432),N=s(6222);function w(e){return"object"==typeof e&&null!==e}function k({title:e,description:t,action:s,children:n}){return(0,r.jsxs)("div",{className:"flex h-full flex-1 flex-col bg-shoji-white",children:[(0,r.jsx)("div",{className:"border-b border-parchment/10 px-8 py-8",children:(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("h2",{className:"font-zen-display text-2xl font-light text-ink-black tracking-wide",children:e}),t&&(0,r.jsx)("p",{className:"mt-2 max-w-xl font-zen-body text-sm text-stone-gray font-light",children:t})]}),s]})}),(0,r.jsx)("div",{className:"flex-1 overflow-y-auto",children:(0,r.jsx)("div",{className:"max-w-3xl px-8 py-8",children:n})})]})}function C({title:e,description:t}){return(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center rounded-2xl border-1.5 border-dashed border-parchment/20 bg-washi-cream/50 p-10 text-center",children:[(0,r.jsx)("div",{className:"mb-4 rounded-xl bg-shoji-white p-4 text-stone-gray",children:(0,r.jsxs)("svg",{width:"28",height:"28",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",children:[(0,r.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,r.jsx)("path",{d:"M12 16v-4"}),(0,r.jsx)("path",{d:"M12 8h.01"})]})}),(0,r.jsx)("p",{className:"mb-2 font-zen-body text-sm text-stone-gray font-light",children:e}),(0,r.jsx)("p",{className:"font-zen-body text-xs text-stone-gray/70 font-light",children:t})]})}function M(){let e=(0,i.k)(),t=(0,l.CU)(e=>e.providers),s=(0,l.CU)(e=>e.compressionModel),n=(0,l.CU)(e=>e.summaryModel),o=(0,l.CU)(e=>e.setLLMSettings),d=(0,l.CU)(e=>e.selectedModels),c=(0,l.CU)(e=>e.setSelectedModels),[x,h]=(0,a.useState)("idle"),[m,p]=(0,a.useState)(null),[g,u]=(0,a.useState)(null),b=(0,a.useMemo)(()=>(0,f.n)(t),[t]),j=(0,a.useMemo)(()=>new Set(d.map(f.R)),[d]),w=(0,a.useMemo)(()=>{let e=new Map;for(let t of b)e.has(t.providerId)||e.set(t.providerId,{providerId:t.providerId,providerName:t.providerName,models:[]}),e.get(t.providerId).models.push(t);return Array.from(e.values()).sort((e,t)=>e.providerName.localeCompare(t.providerName))},[b]);(0,a.useEffect)(()=>{let e=new Set(b.map(f.R)),t=d.filter(t=>e.has((0,f.R)(t)));t.length!==d.length&&c(t)},[b,d,c]),(0,a.useEffect)(()=>{let e=new Set(b.map(f.R)),t=s?(0,f.R)(s):null;t&&!e.has(t)&&o({compressionModel:null});let r=n?(0,f.R)(n):null;r&&!e.has(r)&&o({summaryModel:null})},[s,b,o,n]);let M=e=>({providerId:e.providerId,modelId:e.modelId}),S=async()=>{let s=d[0];if(!s){h("error"),p(e("settings.defaultModel.test.selectModelFirst"));return}let r=t.find(e=>e.id===s.providerId)??null;if(!r){h("error"),p(e("settings.defaultModel.test.providerMissing"));return}let n=(0,v.aA)(r);if(!n){h("error"),p(e("errors.missingApiKey"));return}h("running"),p(null),u(null);let o=await (0,y.DT)(n.value,r.baseUrl,s.modelId,{headers:r.headers,timeout:r.timeout,prompt:"ping"});if(u(o.responseTime??null),"healthy"===o.status){h("success"),p(o.content||e("settings.defaultModel.test.success"));return}h("error"),p(o.error||e("settings.defaultModel.test.failed"))},z=s?(0,f.R)(s):"",L=n?(0,f.R)(n):"";return(0,r.jsx)(k,{title:e("settings.defaultModel.title"),description:e("settings.defaultModel.description"),children:(0,r.jsxs)("div",{className:"space-y-8",children:[(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.defaultModel.enabledModels.title")}),(0,r.jsx)("p",{className:"mt-2 font-zen-body text-sm text-stone-gray font-light",children:e("settings.defaultModel.enabledModels.description")})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/20 bg-shoji-white px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>{c(b.map(e=>M(e)))},disabled:0===b.length,children:e("common.selectAll")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/20 bg-shoji-white px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>{c([])},disabled:0===d.length,children:e("common.clear")})]})]}),0===b.length?(0,r.jsx)("div",{className:"mt-6",children:(0,r.jsx)(C,{title:e("settings.defaultModel.enabledModels.emptyTitle"),description:e("settings.defaultModel.enabledModels.emptyDescription")})}):(0,r.jsx)("div",{className:"mt-6 space-y-6",children:w.map(e=>(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"mb-3 font-zen-body text-xs text-stone-gray font-light",children:e.providerName}),(0,r.jsx)("div",{className:"space-y-2",children:e.models.map(e=>{let t=j.has((0,f.R)(e));return(0,r.jsxs)("button",{type:"button",className:`flex w-full items-center gap-3 rounded-xl border px-4 py-3 text-left transition-all duration-200 ${t?"border-matcha-green/40 bg-matcha-green/10":"border-parchment/20 bg-shoji-white hover:border-matcha-green/30"}`,onClick:()=>{let t;return t=(0,f.R)(e),void c(j.has(t)?d.filter(e=>(0,f.R)(e)!==t):[...d,M(e)])},children:[(0,r.jsx)("span",{className:`flex h-5 w-5 items-center justify-center rounded border text-[0.7rem] ${t?"border-matcha-green bg-matcha-green text-shoji-white":"border-parchment bg-transparent text-transparent"}`,children:"✓"}),(0,r.jsxs)("div",{className:"flex-1",children:[(0,r.jsx)("div",{className:"font-mono text-sm text-ink-black",children:e.modelId}),(0,r.jsx)("div",{className:"text-xs text-stone-gray font-light",children:e.label})]})]},e.modelId)})})]},e.providerId))})]}),(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsx)("div",{className:"mb-3 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.defaultModel.compressionModel.title")}),(0,r.jsxs)("select",{value:z,onChange:e=>{var t;let s;return t=e.target.value,void o({compressionModel:(s=b.find(e=>(0,f.R)(e)===t))?M(s):null,...s?{model:s.modelId}:{}})},disabled:0===b.length,className:"w-full rounded-xl border border-parchment/20 bg-shoji-white px-5 py-4 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50 disabled:opacity-60",children:[(0,r.jsx)("option",{value:"",children:e("settings.defaultModel.compressionModel.placeholder")}),b.map(e=>(0,r.jsx)("option",{value:(0,f.R)(e),children:e.label},`${e.providerId}-${e.modelId}`))]}),(0,r.jsx)("p",{className:"mt-3 font-zen-body text-xs text-stone-gray font-light",children:e("settings.defaultModel.compressionModel.description")})]}),(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsx)("div",{className:"mb-3 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.defaultModel.summaryModel.title")}),(0,r.jsxs)("select",{value:L,onChange:e=>{var t;let s;return t=e.target.value,void o({summaryModel:(s=b.find(e=>(0,f.R)(e)===t))?M(s):null})},disabled:0===b.length,className:"w-full rounded-xl border border-parchment/20 bg-shoji-white px-5 py-4 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50 disabled:opacity-60",children:[(0,r.jsx)("option",{value:"",children:e("settings.defaultModel.summaryModel.placeholder")}),b.map(e=>(0,r.jsx)("option",{value:(0,f.R)(e),children:e.label},`${e.providerId}-${e.modelId}`))]}),(0,r.jsx)("p",{className:"mt-3 font-zen-body text-xs text-stone-gray font-light",children:e("settings.defaultModel.summaryModel.description")})]}),(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.defaultModel.test.title")}),null!==g&&(0,r.jsx)("div",{className:"mt-2 font-mono text-xs text-stone-gray",children:e("settings.defaultModel.test.latency",{ms:g})})]}),(0,r.jsx)("button",{type:"button",className:`flex items-center gap-2 rounded-lg px-4 py-2.5 font-zen-body text-sm transition-all duration-300 ${"running"===x?"bg-washi-cream text-stone-gray cursor-wait":"bg-matcha-green/10 text-matcha-green hover:bg-matcha-green/20 font-light"}`,onClick:S,disabled:"running"===x||0===d.length,children:"running"===x?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(N.fN,{}),e("settings.defaultModel.test.running")]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(N.Sr,{}),e("settings.defaultModel.test.button")]})})]}),m&&(0,r.jsx)("p",{className:`mt-3 font-zen-body text-xs font-light ${{idle:"text-stone-gray",running:"text-kintsugi-gold",success:"text-matcha-green",error:"text-red-500"}[x]}`,children:m})]})]})})}function S(){let e=(0,i.k)(),t=(0,l.CU)(e=>e.temperature),s=(0,l.CU)(e=>e.maxTokens),n=(0,l.CU)(e=>e.setLLMSettings),[o,d]=(0,a.useState)(""),[c,x]=(0,a.useState)(u.rd),[h,m]=(0,a.useState)(t.toString()),[p,b]=(0,a.useState)(s.toString()),[f,y]=(0,a.useState)(!1),[j,v]=(0,a.useState)(null);return(0,a.useEffect)(()=>{d((0,g.sK)()??""),x((0,u.LB)())},[]),(0,a.useEffect)(()=>{m(t.toString())},[t]),(0,a.useEffect)(()=>{b(s.toString())},[s]),(0,r.jsx)(k,{title:e("settings.general.title"),description:e("settings.general.description"),children:(0,r.jsxs)("div",{className:"space-y-8",children:[(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsx)("div",{className:"mb-4 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.general.api.title")}),(0,r.jsxs)("div",{className:"space-y-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("label",{className:"mb-2 block font-zen-body text-xs text-stone-gray font-light",children:e("settings.general.api.apiKeyLabel")}),(0,r.jsxs)("div",{className:"relative",children:[(0,r.jsx)("input",{type:f?"text":"password",value:o,onChange:e=>d(e.target.value),placeholder:"sk-...",className:"w-full rounded-xl border border-parchment/20 bg-shoji-white px-5 py-4 pr-10 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"}),(0,r.jsx)("button",{type:"button",className:"absolute right-4 top-1/2 -translate-y-1/2 text-stone-gray transition-colors hover:text-ink-black",onClick:()=>y(e=>!e),children:f?(0,r.jsx)(N.aR,{}):(0,r.jsx)(N.bM,{})})]})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("label",{className:"mb-2 block font-zen-body text-xs text-stone-gray font-light",children:e("settings.general.api.baseUrlLabel")}),(0,r.jsx)("input",{type:"text",value:c,onChange:e=>x(e.target.value),placeholder:u.rd,className:"w-full rounded-xl border border-parchment/20 bg-shoji-white px-5 py-4 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"})]})]})]}),(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsx)("div",{className:"mb-4 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.general.generation.title")}),(0,r.jsxs)("div",{className:"grid gap-4 md:grid-cols-2",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("label",{className:"mb-2 block font-zen-body text-xs text-stone-gray font-light",children:e("settings.general.generation.temperature")}),(0,r.jsx)("input",{type:"number",min:"0",max:"2",step:"0.1",value:h,onChange:e=>m(e.target.value),className:"w-full rounded-xl border border-parchment/20 bg-shoji-white px-5 py-4 font-zen-body text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("label",{className:"mb-2 block font-zen-body text-xs text-stone-gray font-light",children:e("settings.general.generation.maxTokens")}),(0,r.jsx)("input",{type:"number",min:"1",value:p,onChange:e=>b(e.target.value),className:"w-full rounded-xl border border-parchment/20 bg-shoji-white px-5 py-4 font-zen-body text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"})]})]})]}),(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:j??e("settings.general.saveHint")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg bg-matcha-green px-6 py-3 font-zen-body text-sm text-shoji-white transition-all duration-200 hover:bg-bamboo-light",onClick:()=>{let r=Number.parseFloat(h),a=Number.parseInt(p,10),l={temperature:Number.isFinite(r)?r:t,maxTokens:Number.isFinite(a)?a:s};(0,g.YA)(o),(0,u.$t)(c),n(l),v(e("settings.general.saved")),setTimeout(()=>v(null),2e3)},children:e("settings.general.saveButton")})]})]})})}function z(){let e=(0,i.k)(),t=(0,l.CU)(e=>e.theme),s=(0,l.CU)(e=>e.setTheme),n=(0,l.CU)(e=>e.locale),o=(0,l.CU)(e=>e.setLocale),a=[{id:"light",label:e("settings.display.theme.light"),description:e("settings.display.theme.lightDesc")},{id:"dark",label:e("settings.display.theme.dark"),description:e("settings.display.theme.darkDesc")}],d=[{id:"en",label:e("settings.display.language.en"),description:e("settings.display.language.enDesc")},{id:"zh-CN",label:e("settings.display.language.zhCN"),description:e("settings.display.language.zhCNDesc")}];return(0,r.jsx)(k,{title:e("settings.display.title"),description:e("settings.display.description"),children:(0,r.jsxs)("div",{className:"space-y-8",children:[(0,r.jsxs)("section",{children:[(0,r.jsx)("div",{className:"mb-4 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.display.theme")}),(0,r.jsx)("div",{className:"grid gap-4 md:grid-cols-2",children:a.map(e=>(0,r.jsxs)("button",{type:"button",className:`rounded-2xl border px-6 py-5 text-left transition-all duration-300 ${t===e.id?"border-matcha-green/40 bg-matcha-green/10":"border-parchment/20 bg-washi-cream/50 hover:border-matcha-green/40"}`,onClick:()=>s(e.id),children:[(0,r.jsx)("div",{className:"font-zen-display text-lg font-light text-ink-black",children:e.label}),(0,r.jsx)("div",{className:"mt-2 font-zen-body text-xs text-stone-gray font-light",children:e.description})]},e.id))})]}),(0,r.jsxs)("section",{children:[(0,r.jsx)("div",{className:"mb-4 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.display.language")}),(0,r.jsx)("div",{className:"grid gap-4 md:grid-cols-2",children:d.map(e=>(0,r.jsxs)("button",{type:"button",className:`rounded-2xl border px-6 py-5 text-left transition-all duration-300 ${n===e.id?"border-matcha-green/40 bg-matcha-green/10":"border-parchment/20 bg-washi-cream/50 hover:border-matcha-green/40"}`,onClick:()=>o(e.id),children:[(0,r.jsx)("div",{className:"font-zen-display text-lg font-light text-ink-black",children:e.label}),(0,r.jsx)("div",{className:"mt-2 font-zen-body text-xs text-stone-gray font-light",children:e.description})]},e.id))})]})]})})}function L(){let e=(0,i.k)(),t=(0,l.CU)(e=>e.setLLMSettings),s=(0,l.CU)(e=>e.setTheme),[n,o]=(0,a.useState)(!1),[d,c]=(0,a.useState)(!1),[x,h]=(0,a.useState)(!1),[m,f]=(0,a.useState)(!1),[y,v]=(0,a.useState)(null),N=async()=>{o(!0),v(null);try{await (0,p.MR)(),v(e("settings.data.clear.success")),setTimeout(()=>window.location.reload(),800)}catch(t){v(t instanceof Error?t.message:e("settings.data.clear.failed")),o(!1)}},w=async()=>{c(!0),v(null);try{(0,g.YA)(""),(0,u.$t)(""),(0,j.Ny)(),(0,j.k8)(),t(b.ES),s("light"),v(e("settings.data.reset.success")),setTimeout(()=>window.location.reload(),800)}catch(t){v(t instanceof Error?t.message:e("settings.data.reset.failed")),c(!1)}};return(0,r.jsx)(k,{title:e("settings.data.title"),description:e("settings.data.description"),children:(0,r.jsxs)("div",{className:"space-y-6",children:[(0,r.jsx)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-display text-lg font-light text-ink-black",children:e("settings.data.clear.title")}),(0,r.jsx)("p",{className:"mt-2 font-zen-body text-xs text-stone-gray font-light",children:e("settings.data.clear.description")})]}),x?(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)("button",{type:"button",className:"rounded-lg bg-red-500 px-4 py-2 text-sm text-white",onClick:N,disabled:n,children:n?e("settings.data.clear.running"):e("settings.data.clear.confirm")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/30 px-4 py-2 text-sm text-stone-gray",onClick:()=>h(!1),children:e("common.cancel")})]}):(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-red-200 bg-red-50 px-5 py-2.5 font-zen-body text-sm text-red-600 transition-all duration-200 hover:bg-red-100",onClick:()=>h(!0),children:e("settings.data.clear.button")})]})}),(0,r.jsx)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-display text-lg font-light text-ink-black",children:e("settings.data.reset.title")}),(0,r.jsx)("p",{className:"mt-2 font-zen-body text-xs text-stone-gray font-light",children:e("settings.data.reset.description")})]}),m?(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)("button",{type:"button",className:"rounded-lg bg-matcha-green px-4 py-2 text-sm text-shoji-white",onClick:w,disabled:d,children:d?e("settings.data.reset.running"):e("settings.data.reset.confirm")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/30 px-4 py-2 text-sm text-stone-gray",onClick:()=>f(!1),children:e("common.cancel")})]}):(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/30 bg-shoji-white px-5 py-2.5 font-zen-body text-sm text-stone-gray transition-all duration-200 hover:border-matcha-green/50 hover:text-matcha-green",onClick:()=>f(!0),children:e("settings.data.reset.button")})]})}),y&&(0,r.jsx)("p",{className:"font-zen-body text-xs text-stone-gray font-light",children:y})]})})}function U(){let e=(0,i.k)(),t=[{label:e("settings.about.version.label"),value:e("settings.about.version.value")},{label:e("settings.about.framework.label"),value:e("settings.about.framework.value")},{label:e("settings.about.storage.label"),value:e("settings.about.storage.value")},{label:e("settings.about.ui.label"),value:e("settings.about.ui.value")}];return(0,r.jsx)(k,{title:e("settings.about.title"),description:e("settings.about.description"),children:(0,r.jsx)("div",{className:"space-y-4",children:t.map(e=>(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-3 rounded-2xl border border-parchment/20 bg-washi-cream/50 px-6 py-4",children:[(0,r.jsx)("span",{className:"font-zen-body text-sm text-stone-gray font-light",children:e.label}),(0,r.jsx)("span",{className:"font-zen-display text-lg font-light text-ink-black",children:e.value})]},e.label))})})}function _(){let e=(0,i.k)(),t=(0,l.CU)(e=>e.toolSettings),s=(0,l.CU)(e=>e.setToolSettings),n=(0,l.CU)(e=>e.upsertMcpServer),o=(0,l.CU)(e=>e.deleteMcpServer),[d,c]=(0,a.useState)(!1),[x,h]=(0,a.useState)(!1),[p,g]=(0,a.useState)({status:"idle"}),u=async()=>{let s=t.search.provider,r="exa"===s?t.search.exaApiKey:t.search.tavilyApiKey;if(!r.trim())return void g({status:"error",message:e("settings.tools.search.missingApiKey",{provider:"exa"===s?"Exa":"Tavily"})});g({status:"running",message:void 0,latencyMs:void 0});let n=Date.now();try{let o=await fetch("/api/tools/search",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:s,apiKey:r,query:"OpenAI",maxResults:1,searchDepth:t.search.searchDepth})}),a=Math.max(0,Date.now()-n),l=await o.json().catch(()=>null);if(!o.ok){let t=w(l)&&"error"in l?String(l.error??""):"";throw Error(t||e("errors.requestFailedWithStatus",{status:o.status}))}let i=w(l)&&Array.isArray(l.results)&&l.results[0]&&w(l.results[0])&&"string"==typeof l.results[0].title?l.results[0].title:"";g({status:"success",latencyMs:a,message:i?e("settings.tools.search.test.successWithTitle",{title:i}):e("settings.tools.search.test.success")})}catch(t){g({status:"error",message:t instanceof Error?t.message:e("settings.tools.search.test.failed")})}},b={idle:"text-stone-gray",running:"text-kintsugi-gold",success:"text-matcha-green",error:"text-red-500"}[p.status],[f,y]=(0,a.useState)({}),[j,v]=(0,a.useState)({}),[M,S]=(0,a.useState)({}),z=(e,t)=>{let s=t.replace(/\x1B\[[0-?]*[ -/]*[@-~]/g,"").replace(/\r/g,"").split("\n").map(e=>e.trimEnd()).filter(Boolean);0!==s.length&&y(t=>{let r=t[e],n=[...r?.logs??[],...s],o=n.slice(Math.max(0,n.length-200));return{...t,[e]:{...r??{status:"running"},logs:o}}})},L=async s=>{let r=t.mcp.servers.find(e=>e.id===s)??null;if(!r)return void y(t=>({...t,[s]:{status:"error",message:e("settings.tools.mcp.serverNotFound")}}));y(e=>({...e,[s]:{status:"running",message:void 0,tools:void 0,logs:[]}})),S(e=>({...e,[s]:!0}));let n=Date.now();try{let t=await fetch("/api/tools/mcp/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({server:r})});if(!t.ok){let s=await t.json().catch(()=>null),r="object"==typeof s&&null!==s&&"error"in s?String(s.error??""):"";throw Error(r||e("errors.requestFailedWithStatus",{status:t.status}))}let o=t.headers.get("content-type")??"";if(!t.body||!o.includes("text/event-stream"))throw Error(e("settings.tools.mcp.invalidTestResponse"));let a=t.body.getReader(),l=new TextDecoder("utf-8"),i="",d=!1,c=!1;for(;!d;){let t=await a.read();if(t.done)break;let r=(i+=l.decode(t.value,{stream:!0})).split(/\r?\n\r?\n/);for(let t of(i=r.pop()??"",r)){for(let r of t.split(/\r?\n/)){if(!r.startsWith("data:"))continue;let t=r.replace(/^data:\s*/,"");if(t){if("[DONE]"===t){d=!0;break}try{let r=JSON.parse(t);if("log"===r.type)z(s,r.text);else if("status"===r.type)y(e=>({...e,[s]:{...e[s]??{status:"running"},message:r.phase}}));else if("result"===r.type)c=!0,y(t=>({...t,[s]:{...t[s]??{status:"success"},status:"success",message:e("settings.tools.mcp.test.success",{count:r.tools.length}),latencyMs:r.latencyMs??Math.max(0,Date.now()-n),tools:r.tools,testedAt:Date.now()}})),v(e=>({...e,[s]:!0}));else if("error"===r.type)throw Error(r.message)}catch(r){let t=r instanceof Error?r.message:e("settings.tools.mcp.test.failed");z(s,t)}}}if(d)break}}if(!c)throw Error(e("settings.tools.mcp.test.noResult"))}catch(o){let t=Math.max(0,Date.now()-n),r=o instanceof Error?o.message:e("settings.tools.mcp.test.failed");y(e=>({...e,[s]:{...e[s]??{status:"error"},status:"error",message:r,latencyMs:t,tools:e[s]?.tools??[],testedAt:Date.now()}}))}},[U,_]=(0,a.useState)(!1),[P,T]=(0,a.useState)(null),[E,K]=(0,a.useState)(null),W=()=>{K(null),T({id:`mcp_${Date.now().toString(36)}`,name:e("settings.tools.mcp.newServerName"),transport:"http",token:"",configJson:JSON.stringify({url:"http://localhost:3000/mcp",protocolVersion:"2024-11-05"},null,2)}),_(!0)};return(0,r.jsxs)(k,{title:e("settings.tools.title"),description:e("settings.tools.description"),action:(0,r.jsx)("button",{type:"button",className:"rounded-lg bg-matcha-green px-4 py-2 text-sm text-shoji-white transition-all duration-200 hover:bg-matcha-green/90",onClick:W,children:e("settings.tools.mcp.add")}),children:[(0,r.jsxs)("div",{className:"space-y-10",children:[(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsx)("div",{className:"mb-5 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.tools.search.title")}),(0,r.jsxs)("div",{className:"grid gap-5 md:grid-cols-2",children:[(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:e("settings.tools.search.defaultProvider")}),(0,r.jsxs)("select",{className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.search.provider,onChange:e=>s({...t,search:{...t.search,provider:"exa"===e.target.value?"exa":"tavily"}}),children:[(0,r.jsx)("option",{value:"tavily",children:"Tavily"}),(0,r.jsx)("option",{value:"exa",children:"Exa"})]})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:e("settings.tools.search.searchDepth")}),(0,r.jsxs)("select",{className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.search.searchDepth,onChange:e=>s({...t,search:{...t.search,searchDepth:"advanced"===e.target.value?"advanced":"basic"}}),children:[(0,r.jsx)("option",{value:"basic",children:e("settings.tools.search.depth.basic")}),(0,r.jsx)("option",{value:"advanced",children:e("settings.tools.search.depth.advanced")})]})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:e("settings.tools.search.maxResults")}),(0,r.jsx)("input",{type:"number",min:1,max:20,className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.search.maxResults,onChange:e=>s({...t,search:{...t.search,maxResults:Math.max(1,Math.min(20,Number(e.target.value||0)))}})})]})]}),(0,r.jsxs)("div",{className:"mt-6 grid gap-5 md:grid-cols-2",children:[(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:"Tavily API Key"}),(0,r.jsxs)("button",{type:"button",className:"flex items-center gap-2 rounded-lg border border-parchment/20 bg-shoji-white px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>c(e=>!e),children:[d?(0,r.jsx)(N.aR,{}):(0,r.jsx)(N.bM,{}),d?e("common.hide"):e("common.show")]})]}),(0,r.jsx)("input",{type:d?"text":"password",className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.search.tavilyApiKey,onChange:e=>s({...t,search:{...t.search,tavilyApiKey:e.target.value}}),placeholder:"tvly-..."})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:"Exa API Key"}),(0,r.jsxs)("button",{type:"button",className:"flex items-center gap-2 rounded-lg border border-parchment/20 bg-shoji-white px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>h(e=>!e),children:[x?(0,r.jsx)(N.aR,{}):(0,r.jsx)(N.bM,{}),x?e("common.hide"):e("common.show")]})]}),(0,r.jsx)("input",{type:x?"text":"password",className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.search.exaApiKey,onChange:e=>s({...t,search:{...t.search,exaApiKey:e.target.value}}),placeholder:"exa_..."})]})]}),(0,r.jsxs)("div",{className:"mt-6 flex flex-wrap items-center justify-between gap-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.tools.search.test.title")}),void 0!==p.latencyMs?(0,r.jsx)("div",{className:"mt-2 font-mono text-xs text-stone-gray",children:e("settings.tools.search.test.latency",{ms:p.latencyMs})}):null]}),(0,r.jsx)("button",{type:"button",className:`flex items-center gap-2 rounded-lg px-4 py-2.5 font-zen-body text-sm transition-all duration-300 ${"running"===p.status?"bg-washi-cream text-stone-gray cursor-wait":"bg-matcha-green/10 text-matcha-green hover:bg-matcha-green/20 font-light"}`,onClick:()=>void u(),disabled:"running"===p.status,children:"running"===p.status?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(N.fN,{}),e("settings.tools.search.test.running")]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(N.Sr,{}),e("settings.tools.search.test.button")]})})]}),p.message?(0,r.jsx)("p",{className:`mt-3 font-zen-body text-xs font-light ${b}`,children:p.message}):null]}),(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsxs)("div",{className:"mb-5 flex flex-wrap items-center justify-between gap-3",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:"MCP Servers"}),(0,r.jsx)("p",{className:"mt-2 font-zen-body text-sm text-stone-gray font-light",children:e("settings.tools.mcp.description")})]}),(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/30 bg-shoji-white px-4 py-2 text-sm text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:W,children:e("common.new")})]}),0===t.mcp.servers.length?(0,r.jsx)(C,{title:e("settings.tools.mcp.empty.title"),description:e("settings.tools.mcp.empty.description")}):(0,r.jsx)("div",{className:"space-y-3",children:t.mcp.servers.map(s=>{let n,a,l,i;return(0,r.jsx)("div",{className:"rounded-2xl border border-parchment/20 bg-shoji-white px-6 py-4",children:(n=f[s.id]??{status:"idle"},a=j[s.id]??!1,l=M[s.id]??!1,i="success"===n.status?"text-matcha-green":"error"===n.status?"text-red-500":"running"===n.status?"text-kintsugi-gold":"text-stone-gray",(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"font-zen-display text-lg font-light text-ink-black",children:s.name}),(0,r.jsxs)("div",{className:"mt-1 font-mono text-[0.7rem] text-stone-gray",children:[s.id," \xb7 ",s.transport.toUpperCase()]})]}),(0,r.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/20 bg-washi-cream px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green disabled:opacity-60",onClick:()=>void L(s.id),disabled:"running"===n.status,children:"running"===n.status?e("settings.tools.mcp.test.running"):e("settings.tools.mcp.test.button")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/20 bg-washi-cream px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>{var e;let r;return e=s.id,void((r=t.mcp.servers.find(t=>t.id===e))&&(K(null),T({id:r.id,name:r.name,transport:r.transport,token:r.token,configJson:r.configJson}),_(!0)))},children:e("common.edit")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/20 bg-washi-cream px-3 py-2 text-xs text-stone-gray transition-all duration-200 hover:border-red-300 hover:text-red-500",onClick:()=>o(s.id),children:e("common.delete")})]})]}),"idle"!==n.status?(0,r.jsxs)("div",{className:"mt-3",children:[(0,r.jsxs)("div",{className:`font-mono text-[0.75rem] ${i}`,children:[n.message??("running"===n.status?e("settings.tools.mcp.test.running"):""),"number"==typeof n.latencyMs?(0,r.jsxs)("span",{className:"ml-2 text-stone-gray",children:[n.latencyMs,"ms"]}):null]}),n.logs&&n.logs.length>0?(0,r.jsxs)("div",{className:"mt-2 rounded-xl border border-parchment/20 bg-washi-cream/60 px-4 py-3",children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[(0,r.jsx)("div",{className:"font-mono text-[0.65rem] uppercase tracking-[0.12em] text-stone-gray",children:e("settings.tools.mcp.logs")}),(0,r.jsxs)("button",{type:"button",className:"rounded-lg border border-parchment/30 bg-shoji-white px-3 py-1.5 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>S(e=>({...e,[s.id]:!l})),children:[l?e("settings.tools.mcp.collapse"):e("settings.tools.mcp.expand")," (",n.logs.length,")"]})]}),l?(0,r.jsx)("pre",{className:"mt-3 max-h-[260px] overflow-auto rounded-lg bg-shoji-white px-3 py-2 font-mono text-[0.7rem] text-ink-black",children:n.logs.join("\n")}):null]}):null,"success"===n.status&&n.tools&&(0,r.jsxs)("div",{className:"mt-2 rounded-xl border border-parchment/20 bg-washi-cream/60 px-4 py-3",children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[(0,r.jsx)("div",{className:"font-mono text-[0.65rem] uppercase tracking-[0.12em] text-stone-gray",children:e("settings.tools.mcp.tools")}),(0,r.jsxs)("button",{type:"button",className:"rounded-lg border border-parchment/30 bg-shoji-white px-3 py-1.5 text-xs text-stone-gray transition-all duration-200 hover:border-matcha-green/40 hover:text-matcha-green",onClick:()=>v(e=>({...e,[s.id]:!a})),children:[a?e("settings.tools.mcp.collapse"):e("settings.tools.mcp.expand")," (",n.tools.length,")"]})]}),a?(0,r.jsx)("div",{className:"mt-3 max-h-[260px] space-y-2 overflow-auto pr-1",children:0===n.tools.length?(0,r.jsx)("div",{className:"rounded-lg bg-shoji-white px-3 py-2 text-xs text-stone-gray",children:e("settings.tools.mcp.noTools")}):n.tools.map(e=>(0,r.jsxs)("div",{className:"rounded-lg bg-shoji-white px-3 py-2",children:[(0,r.jsx)("div",{className:"font-mono text-[0.75rem] text-ink-black",children:e.name}),e.description?(0,r.jsx)("div",{className:"mt-1 text-xs text-stone-gray",children:e.description}):null]},e.name))}):null]})]}):null]}))},s.id)})})]}),(0,r.jsxs)("section",{className:"rounded-2xl border border-parchment/20 bg-washi-cream/50 p-6",children:[(0,r.jsx)("div",{className:"mb-5 font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:e("settings.tools.python.title")}),(0,r.jsxs)("div",{className:"grid gap-5 md:grid-cols-2",children:[(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:e("settings.tools.python.timeoutSeconds")}),(0,r.jsx)("input",{type:"number",min:1,max:120,className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:Math.round(t.python.timeoutMs/1e3),onChange:e=>{let r=Math.max(1,Math.min(120,Number(e.target.value||0)));s({...t,python:{...t.python,timeoutMs:1e3*r}})}})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:e("settings.tools.python.maxOutputChars")}),(0,r.jsx)("input",{type:"number",min:1e3,max:2e5,className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.python.maxOutputChars,onChange:e=>{let r=Math.max(1e3,Math.min(2e5,Number(e.target.value||0)));s({...t,python:{...t.python,maxOutputChars:r}})}})]}),(0,r.jsxs)("label",{className:"space-y-2 md:col-span-2",children:[(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray font-light",children:e("settings.tools.python.command")}),(0,r.jsx)("input",{className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:t.python.pythonCommand,onChange:e=>s({...t,python:{...t.python,pythonCommand:e.target.value}}),placeholder:"python3"}),(0,r.jsx)("p",{className:"font-zen-body text-xs text-stone-gray/70 font-light",children:e("settings.tools.python.note")})]})]})]})]}),(0,r.jsx)(m.a,{open:U,title:P?e("settings.tools.mcp.modal.titleWithName",{name:P.name}):e("settings.tools.mcp.modal.title"),onClose:()=>_(!1),children:P?(0,r.jsxs)("div",{className:"space-y-4",children:[E?(0,r.jsx)("div",{className:"rounded-xl border border-red-200 bg-red-50 px-4 py-3 text-sm text-red-700",children:E}):null,(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"text-xs text-sand",children:e("settings.tools.mcp.editor.serverId")}),(0,r.jsx)("input",{className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-mono text-[0.85rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:P.id,onChange:e=>T({...P,id:e.target.value})})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"text-xs text-sand",children:e("settings.tools.mcp.editor.name")}),(0,r.jsx)("input",{className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:P.name,onChange:e=>T({...P,name:e.target.value})})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"text-xs text-sand",children:e("settings.tools.mcp.editor.transport")}),(0,r.jsxs)("select",{className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-body text-[0.9rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:P.transport,onChange:e=>{let t="stdio"===e.target.value?"stdio":"sse"===e.target.value?"sse":"http",s="http"===t?JSON.stringify({url:"http://localhost:3000/mcp",protocolVersion:"2024-11-05"},null,2):"sse"===t?JSON.stringify({sseUrl:"http://localhost:3000/mcp",messagesUrl:"http://localhost:3000/messages",protocolVersion:"2024-11-05"},null,2):JSON.stringify({command:"node",args:["server.js"],protocolVersion:"2024-11-05",stdioFraming:"content-length"},null,2);T({...P,transport:t,configJson:P.configJson.trim()?P.configJson:s})},children:[(0,r.jsx)("option",{value:"http",children:"streamable http"}),(0,r.jsx)("option",{value:"sse",children:"legacy sse"}),(0,r.jsx)("option",{value:"stdio",children:"stdio"})]})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"text-xs text-sand",children:e("settings.tools.mcp.editor.token")}),(0,r.jsx)("input",{type:"password",className:"w-full rounded-xl border border-parchment bg-paper px-4 py-3 font-mono text-[0.85rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:P.token,onChange:e=>T({...P,token:e.target.value}),placeholder:e("settings.tools.mcp.editor.tokenPlaceholder")})]}),(0,r.jsxs)("label",{className:"space-y-2",children:[(0,r.jsx)("div",{className:"text-xs text-sand",children:e("settings.tools.mcp.editor.configJson")}),(0,r.jsx)("textarea",{className:"h-[220px] w-full resize-none rounded-xl border border-parchment bg-paper px-4 py-3 font-mono text-[0.8rem] text-ink outline-none transition-all duration-200 focus:border-copper focus:shadow-[0_0_0_3px_var(--copper-glow)]",value:P.configJson,onChange:e=>T({...P,configJson:e.target.value}),spellCheck:!1}),(0,r.jsx)("p",{className:"font-zen-body text-xs text-stone-gray/70 font-light",children:e("settings.tools.mcp.editor.configNote")})]}),(0,r.jsxs)("div",{className:"flex justify-end gap-2",children:[(0,r.jsx)("button",{type:"button",className:"rounded-lg border border-parchment/30 bg-shoji-white px-4 py-2 text-sm text-stone-gray",onClick:()=>_(!1),children:e("common.cancel")}),(0,r.jsx)("button",{type:"button",className:"rounded-lg bg-matcha-green px-4 py-2 text-sm text-shoji-white",onClick:()=>{if(!P)return;let t=P.id.trim(),s=P.name.trim();t?s?(n({id:t,name:s,transport:P.transport,token:P.token,configJson:P.configJson}),_(!1)):K(e("settings.tools.mcp.editor.nameRequired")):K(e("settings.tools.mcp.editor.idRequired"))},children:e("common.save")})]})]}):null})]})}function P(){let e=(0,i.k)();return(0,r.jsxs)(o(),{href:"/",className:"fixed bottom-8 left-8 z-50 flex items-center gap-3 rounded-2xl border border-parchment/30 bg-shoji-white/95 backdrop-blur-sm px-5 py-3 font-zen-body text-sm text-stone-gray shadow-lg transition-all duration-200 hover:border-matcha-green/50 hover:text-matcha-green hover:shadow-xl",children:[(0,r.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M19 12H5M12 19l-7-7 7-7"})}),e("settings.backToHome")]})}function T(){let e=(0,l.CU)(e=>e.providers),t=(0,l.CU)(e=>e.selectedProviderId),s=(0,l.CU)(e=>e.loadProviders),n=(0,a.useRef)(null),[o,i]=(0,a.useState)("providers");(0,a.useEffect)(()=>{s()},[s]),(0,a.useEffect)(()=>{!t&&e.length>0&&l.jL.getState().selectProvider(e[0].id)},[t,e]);let m=()=>"providers"===o?(0,r.jsx)(c.ProviderConfig,{}):"models"===o?(0,r.jsx)(M,{}):"general"===o?(0,r.jsx)(S,{}):"display"===o?(0,r.jsx)(z,{}):"tools"===o?(0,r.jsx)(_,{}):"data"===o?(0,r.jsx)(L,{}):"about"===o?(0,r.jsx)(U,{}):(0,r.jsx)(c.ProviderConfig,{}),p="providers"===o||"models"===o;return(0,r.jsxs)("div",{ref:n,className:"fixed inset-0 z-[100] flex bg-shoji-white",style:{height:"100vh",maxHeight:"100vh"},children:[(0,r.jsx)(x.SettingsSidebar,{activeId:o,onSelect:i}),p?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(d.ProviderList,{}),m(),(0,r.jsx)(h.ConnectedModelSelector,{})]}):m(),(0,r.jsx)(P,{})]})}},6222:(e,t,s)=>{"use strict";s.d(t,{GQ:()=>o,PX:()=>c,RY:()=>b,Sr:()=>g,Td:()=>f,US:()=>u,WI:()=>m,aR:()=>v,bM:()=>j,bN:()=>i,c1:()=>x,fN:()=>p,hp:()=>n,mo:()=>d,qY:()=>y,uc:()=>h,v1:()=>a,yo:()=>l});var r=s(5155);function n(){return(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M17.5 19c0-1.7-1.3-3-3-3h-11c-1.7 0-3 1.3-3 3s1.3 3 3 3h11c1.7 0 3-1.3 3-3z"}),(0,r.jsx)("path",{d:"M19 16c2.8 0 5-2.2 5-5s-2.2-5-5-5c-.5 0-1 .1-1.4.2"}),(0,r.jsx)("path",{d:"M6.5 6C8.4 3.7 11.5 2.5 14.5 3c2.3.4 4.3 1.9 5.5 4"})]})}function o(){return(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2"}),(0,r.jsx)("path",{d:"M9 9h6v6H9z"}),(0,r.jsx)("path",{d:"M9 1v3"}),(0,r.jsx)("path",{d:"M15 1v3"}),(0,r.jsx)("path",{d:"M9 20v3"}),(0,r.jsx)("path",{d:"M15 20v3"}),(0,r.jsx)("path",{d:"M20 9h3"}),(0,r.jsx)("path",{d:"M20 15h3"}),(0,r.jsx)("path",{d:"M1 9h3"}),(0,r.jsx)("path",{d:"M1 15h3"})]})}function a(){return(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("circle",{cx:"13.5",cy:"6.5",r:"0.5",fill:"currentColor"}),(0,r.jsx)("circle",{cx:"17.5",cy:"10.5",r:"0.5",fill:"currentColor"}),(0,r.jsx)("circle",{cx:"8.5",cy:"7.5",r:"0.5",fill:"currentColor"}),(0,r.jsx)("circle",{cx:"6.5",cy:"12.5",r:"0.5",fill:"currentColor"}),(0,r.jsx)("path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10c.926 0 1.648-.746 1.648-1.688 0-.437-.18-.835-.437-1.125-.29-.289-.438-.652-.438-1.125a1.64 1.64 0 0 1 1.668-1.668h1.996c3.051 0 5.555-2.503 5.555-5.554C21.965 6.012 17.461 2 12 2z"})]})}function l(){return(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("rect",{x:"2",y:"3",width:"20",height:"14",rx:"2"}),(0,r.jsx)("path",{d:"M8 21h8"}),(0,r.jsx)("path",{d:"M12 17v4"})]})}function i(){return(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("ellipse",{cx:"12",cy:"5",rx:"9",ry:"3"}),(0,r.jsx)("path",{d:"M21 12c0 1.66-4 3-9 3s-9-1.34-9-3"}),(0,r.jsx)("path",{d:"M3 5v14c0 1.66 4 3 9 3s9-1.34 9-3V5"})]})}function d(){return(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,r.jsx)("path",{d:"M12 16v-4"}),(0,r.jsx)("path",{d:"M12 8h.01"})]})}function c(){return(0,r.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M14.7 6.3a4 4 0 0 1-5.65 5.65L3 18v3h3l6.05-6.05a4 4 0 0 1 5.65-5.65l-2.1 2.1 1.4 1.4 2.1-2.1Z"})})}function x(){return(0,r.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M12 5v14M5 12h14"})})}function h(){return(0,r.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M3 6h18M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"})})}function m(){return(0,r.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("circle",{cx:"11",cy:"11",r:"8"}),(0,r.jsx)("path",{d:"m21 21-4.35-4.35"})]})}function p(){return(0,r.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}),(0,r.jsx)("path",{d:"M3 3v5h5"}),(0,r.jsx)("path",{d:"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16"}),(0,r.jsx)("path",{d:"M16 16h5v5"})]})}function g(){return(0,r.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M20 6 9 17l-5-5"})})}function u(){return(0,r.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M18 6 6 18M6 6l12 12"})})}function b(){return(0,r.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,r.jsx)("path",{d:"M21 2l-2 2m-7.61 7.61a5.5 5.5 0 1 1-7.778 7.778 5.5 5.5 0 0 1 7.777-7.777zm0 0L15.5 7.5m0 0l3 3L22 7l-3-3m-3.5 3.5L19 4"})})}function f(){return(0,r.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2"}),(0,r.jsx)("path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"})]})}function y(){return(0,r.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"}),(0,r.jsx)("path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"})]})}function j(){return(0,r.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z"}),(0,r.jsx)("circle",{cx:"12",cy:"12",r:"3"})]})}function v(){return(0,r.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,r.jsx)("path",{d:"M9.88 9.88a3 3 0 1 0 4.24 4.24"}),(0,r.jsx)("path",{d:"M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68"}),(0,r.jsx)("path",{d:"M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61"}),(0,r.jsx)("line",{x1:"2",x2:"22",y1:"2",y2:"22"})]})}},6531:(e,t,s)=>{"use strict";s.d(t,{ProviderList:()=>h});var r=s(5155),n=s(2115),o=s(4394),a=s(513),l=s(6222);function i({name:e}){let t=e.trim().charAt(0).toUpperCase(),s=["bg-matcha-green","bg-kintsugi-gold","bg-stone-gray"],n=e.charCodeAt(0)%s.length,o=s[n];return(0,r.jsx)("div",{className:`flex h-9 w-9 flex-shrink-0 items-center justify-center rounded-lg ${o} text-shoji-white text-lg font-medium shadow-sm`,children:t})}function d({enabled:e,onToggle:t}){return(0,r.jsx)("button",{type:"button",className:`relative flex h-6 w-11 flex-shrink-0 items-center rounded-full transition-all duration-300 ${e?"bg-matcha-green":"bg-stone-gray/30"}`,onClick:e=>{e.stopPropagation(),t()},"aria-pressed":e,children:(0,r.jsx)("span",{className:`block h-4.5 w-4.5 transform rounded-full bg-white shadow-sm transition-all duration-300 ${e?"translate-x-6":"translate-x-0.5"}`})})}function c({provider:e,isActive:t,onSelect:s,onToggle:n,onDelete:o}){let c=(0,a.k)();return(0,r.jsx)("div",{className:`group relative mb-2 cursor-pointer rounded-xl p-4 transition-all duration-300 ${t?"bg-washi-cream/70 border border-matcha-green/20 shadow-sm":"hover:bg-washi-cream/30 border border-transparent"}`,onClick:s,role:"button",tabIndex:0,onKeyDown:e=>"Enter"===e.key&&s(),children:(0,r.jsxs)("div",{className:"flex w-full items-center gap-4 text-left",children:[(0,r.jsx)(i,{name:e.name}),(0,r.jsx)("span",{className:"flex-1 truncate font-zen-body text-sm font-normal text-ink-black",children:e.name}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(d,{enabled:e.enabled,onToggle:n}),(0,r.jsx)("button",{type:"button",className:"flex-shrink-0 rounded-lg p-2 text-stone-gray opacity-0 transition-all duration-200 hover:bg-sakura-pink/30 hover:text-red-500 group-hover:opacity-100 group-hover:pointer-events-auto pointer-events-none",onClick:e=>{e.stopPropagation(),o()},"aria-label":c("providers.deleteAria"),children:(0,r.jsx)(l.uc,{})})]})]})})}function x({open:e,onClose:t,onAdd:s}){let o=(0,a.k)(),[l,i]=(0,n.useState)("");return e?(0,r.jsx)("div",{className:"fixed inset-0 z-[200] flex items-center justify-center bg-ink-black/20 backdrop-blur-sm",children:(0,r.jsxs)("div",{className:"w-full max-w-md rounded-2xl bg-shoji-white p-8 shadow-lg border border-parchment/10",children:[(0,r.jsx)("h3",{className:"mb-6 font-zen-display text-2xl font-light text-ink-black tracking-wide",children:o("providers.dialog.title")}),(0,r.jsxs)("form",{onSubmit:e=>{e.preventDefault();let r=l.trim();r&&(s(r),i(""),t())},children:[(0,r.jsxs)("div",{className:"mb-6",children:[(0,r.jsx)("label",{className:"mb-3 block font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:o("providers.dialog.nameLabel")}),(0,r.jsx)("input",{type:"text",value:l,onChange:e=>i(e.target.value),placeholder:o("providers.dialog.namePlaceholder"),className:"w-full rounded-xl border border-parchment/20 bg-washi-cream px-5 py-4 font-zen-body text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50 focus:shadow-sm",autoFocus:!0})]}),(0,r.jsxs)("div",{className:"flex justify-end gap-3",children:[(0,r.jsx)("button",{type:"button",className:"rounded-xl border border-parchment/20 px-6 py-3 font-zen-body text-sm text-stone-gray transition-all duration-200 hover:border-stone-gray/30 hover:text-ink-black",onClick:t,children:o("common.cancel")}),(0,r.jsx)("button",{type:"submit",className:"rounded-xl bg-matcha-green px-6 py-3 font-zen-body text-sm text-shoji-white transition-all duration-200 hover:bg-bamboo-light",children:o("common.add")})]})]})]})}):null}function h(){let e=(0,a.k)(),t=(0,o.CU)(e=>e.providers),s=(0,o.CU)(e=>e.selectedProviderId),i=(0,o.CU)(e=>e.selectProvider),d=(0,o.CU)(e=>e.toggleProviderEnabled),h=(0,o.CU)(e=>e.deleteProvider),m=(0,o.CU)(e=>e.addProvider),[p,g]=(0,n.useState)(!1),[u,b]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{b(!0)},[]),(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{className:"flex h-full w-[320px] flex-shrink-0 flex-col border-r border-parchment/10 bg-washi-cream/50",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between border-b border-parchment/10 px-6 py-6",children:[(0,r.jsx)("div",{className:"font-zen-display text-xl font-normal text-ink-black tracking-wide",children:e("providers.title")}),(0,r.jsx)("div",{className:"flex h-7 min-h-7 w-7 min-w-7 items-center justify-center rounded-full bg-washi-cream font-zen-body text-xs text-stone-gray font-light",children:u?t.length:"-"})]}),(0,r.jsx)("div",{className:"flex-1 overflow-y-auto px-4 py-6",children:0===t.length?(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center py-16 text-center",children:[(0,r.jsx)("div",{className:"mb-4 rounded-2xl bg-washi-cream/50 p-6 text-stone-gray",children:(0,r.jsxs)("svg",{width:"48",height:"48",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1",className:"mx-auto",children:[(0,r.jsx)("path",{d:"M17.5 19c0-1.7-1.3-3-3-3h-11c-1.7 0-3 1.3-3 3s1.3 3 3 3h11c1.7 0 3-1.3 3-3z"}),(0,r.jsx)("path",{d:"M19 16c2.8 0 5-2.2 5-5s-2.2-5-5-5c-.5 0-1 .1-1.4.2"}),(0,r.jsx)("path",{d:"M6.5 6C8.4 3.7 11.5 2.5 14.5 3c2.3.4 4.3 1.9 5.5 4"})]})}),(0,r.jsx)("p",{className:"mb-2 font-zen-body text-sm text-stone-gray font-light",children:e("providers.empty.title")}),(0,r.jsx)("p",{className:"font-zen-body text-xs text-stone-gray/70 font-light",children:e("providers.empty.description")})]}):t.map((e,t)=>(0,r.jsx)("div",{style:{animation:`slideInUp 0.5s ease-out ${.05*t}s backwards`},children:(0,r.jsx)(c,{provider:e,isActive:s===e.id,onSelect:()=>i(e.id),onToggle:()=>d(e.id),onDelete:()=>h(e.id)})},e.id))}),(0,r.jsx)("div",{className:"border-t border-parchment/10 p-5",children:(0,r.jsxs)("button",{type:"button",className:"flex w-full items-center justify-center gap-2 rounded-xl border-1.5 border-dashed border-parchment/30 px-5 py-4 font-zen-body text-sm text-stone-gray font-light transition-all duration-300 hover:border-matcha-green/50 hover:bg-matcha-green/5 hover:text-matcha-green",onClick:()=>g(!0),children:[(0,r.jsx)(l.c1,{}),e("providers.add")]})})]}),(0,r.jsx)(x,{open:p,onClose:()=>g(!1),onAdd:e=>m(e)})]})}},7977:(e,t,s)=>{"use strict";s.d(t,{SettingsSidebar:()=>i});var r=s(5155),n=s(513),o=s(6222);let a=[{id:"providers",labelKey:"settings.nav.providers",icon:(0,r.jsx)(o.hp,{})},{id:"models",labelKey:"settings.nav.defaultModel",icon:(0,r.jsx)(o.GQ,{})},{id:"tools",labelKey:"settings.nav.tools",icon:(0,r.jsx)(o.PX,{})},{id:"general",labelKey:"settings.nav.general",icon:(0,r.jsx)(o.yo,{})},{id:"display",labelKey:"settings.nav.display",icon:(0,r.jsx)(o.v1,{})}],l=[{id:"data",labelKey:"settings.nav.data",icon:(0,r.jsx)(o.bN,{})},{id:"about",labelKey:"settings.nav.about",icon:(0,r.jsx)(o.mo,{})}];function i({activeId:e,onSelect:t}){let s=(0,n.k)(),o=[{label:s("settings.nav.configuration"),items:a},{label:s("settings.nav.data"),items:l}];return(0,r.jsxs)("nav",{className:"flex h-full w-[240px] flex-shrink-0 flex-col border-r border-parchment/10 bg-shoji-white",children:[(0,r.jsxs)("div",{className:"border-b border-parchment/10 px-8 py-12",children:[(0,r.jsx)("div",{className:"font-zen-display text-2xl font-light tracking-[0.15em] text-ink-black",children:s("common.settings")}),(0,r.jsx)("div",{className:"mt-1 font-zen-body text-[0.6rem] tracking-[0.2em] text-stone-gray font-light uppercase",children:s("common.appName")})]}),(0,r.jsx)("div",{className:"flex-1 overflow-y-auto px-6 py-8",children:o.map((n,o)=>(0,r.jsxs)("div",{className:0===o?"mb-8":"",children:[(0,r.jsx)("div",{className:"mb-5 px-3 font-zen-body text-[0.65rem] tracking-[0.25em] text-stone-gray uppercase font-light",children:n.label}),(0,r.jsx)("div",{className:"space-y-1",children:n.items.map((n,o)=>(0,r.jsxs)("button",{className:`group relative flex w-full items-center gap-3 rounded-lg px-5 py-3 font-zen-body text-sm font-light transition-all duration-300 ${e===n.id?"bg-washi-cream text-matcha-green border border-matcha-green/15 shadow-sm":"text-stone-gray hover:bg-washi-cream/50 hover:text-ink-black"}`,style:{animation:`fadeIn 0.8s ease-out ${.05*o}s backwards`},onClick:()=>t(n.id),children:[(0,r.jsx)("div",{className:`absolute left-0 top-0 h-full w-0.5 bg-matcha-green transition-transform duration-300 ${e===n.id?"scale-y-100":"scale-y-0"}`}),(0,r.jsx)("span",{className:"flex-shrink-0 text-base opacity-70 group-hover:opacity-100 transition-opacity",children:n.icon}),(0,r.jsx)("span",{className:"font-light tracking-wide",children:s(n.labelKey)})]},n.id))})]},n.label))}),(0,r.jsx)("div",{className:"border-t border-parchment/10 px-8 py-7",children:(0,r.jsxs)("div",{className:"font-zen-display text-sm text-stone-gray font-light tracking-[0.1em]",children:[s("common.appName")," v1.0.0"]})})]})}},9362:(e,t,s)=>{"use strict";s.d(t,{ProviderConfig:()=>m});var r=s(5155),n=s(2115),o=s(4394),a=s(513),l=s(5746),i=s(6222);function d({apiKey:e,onUpdate:t,onDelete:s,onSetPrimary:o,isPrimary:l}){let d=(0,a.k)(),[c,x]=(0,n.useState)(!1),h=async()=>{try{await navigator.clipboard.writeText(e.value)}catch{}},m={healthy:"text-matcha-green",error:"text-red-500",checking:"text-kintsugi-gold",unknown:"text-stone-gray"}[e.healthStatus||"unknown"];return(0,r.jsxs)("div",{className:"group relative rounded-xl border border-parchment/10 bg-washi-cream p-5 transition-all duration-300 hover:border-matcha-green/20 hover:shadow-sm",children:[(0,r.jsxs)("div",{className:"mb-3 flex items-center justify-between",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)("input",{type:"text",value:e.name||"",onChange:e=>t({name:e.target.value}),placeholder:d("providerConfig.apiKeys.namePlaceholder"),className:"w-32 bg-transparent font-zen-body text-sm font-normal text-ink-black outline-none placeholder:text-stone-gray/50"}),l&&(0,r.jsx)("span",{className:"rounded-lg bg-kintsugi-gold/10 px-2 py-1 font-zen-body text-xs text-kintsugi-gold font-light",children:d("providerConfig.apiKeys.primary")})]}),(0,r.jsx)("div",{className:"flex items-center gap-1",children:(0,r.jsx)("span",{className:`flex-shrink-0 ${m}`,children:"healthy"===e.healthStatus?(0,r.jsx)("svg",{width:"10",height:"10",viewBox:"0 0 24 24",fill:"currentColor",children:(0,r.jsx)("circle",{cx:"12",cy:"12",r:"10"})}):"error"===e.healthStatus?(0,r.jsxs)("svg",{width:"10",height:"10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:[(0,r.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,r.jsx)("path",{d:"m15 9-6 6m0-6 6 6"})]}):(0,r.jsxs)("svg",{width:"10",height:"10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:[(0,r.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,r.jsx)("path",{d:"M12 6v6l4 2"})]})})})]}),(0,r.jsx)("div",{className:"flex items-center gap-2",children:(0,r.jsxs)("div",{className:"relative flex-1",children:[(0,r.jsx)("input",{type:c?"text":"password",value:e.value,onChange:e=>t({value:e.target.value}),placeholder:"sk-...",className:"w-full rounded-lg border border-parchment/20 bg-shoji-white px-4 py-3 pr-10 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"}),(0,r.jsx)("button",{type:"button",className:"absolute right-3 top-1/2 -translate-y-1/2 text-stone-gray transition-colors hover:text-ink-black",onClick:()=>x(!c),children:c?(0,r.jsx)(i.aR,{}):(0,r.jsx)(i.bM,{})})]})}),(0,r.jsxs)("div",{className:"mt-3 flex items-center justify-between",children:[(0,r.jsx)("div",{className:"flex items-center gap-1",children:!l&&(0,r.jsx)("button",{type:"button",className:"rounded-lg px-3 py-1.5 font-zen-body text-xs text-stone-gray font-light transition-colors hover:text-matcha-green",onClick:o,children:d("providerConfig.apiKeys.setPrimary")})}),(0,r.jsxs)("div",{className:"flex items-center gap-1",children:[(0,r.jsx)("button",{type:"button",className:"rounded-lg p-2 text-stone-gray transition-colors hover:text-ink-black",onClick:h,title:d("common.copy"),children:(0,r.jsx)(i.Td,{})}),(0,r.jsx)("button",{type:"button",className:"rounded-lg p-2 text-stone-gray transition-colors hover:text-red-500",onClick:s,title:d("common.delete"),children:(0,r.jsx)(i.uc,{})})]})]})]})}function c({model:e,onRemove:t,onToggleEnabled:s,onToggleStreaming:n}){let o=(0,a.k)(),l=e.supportsStreaming??!1;return(0,r.jsxs)("div",{className:"group flex items-center gap-3 rounded-lg border border-parchment/10 bg-washi-cream px-4 py-3 transition-all duration-300 hover:border-matcha-green/20",children:[(0,r.jsx)("button",{type:"button",className:`flex h-6 w-6 flex-shrink-0 items-center justify-center rounded-lg border transition-all duration-300 ${e.enabled?"border-matcha-green bg-matcha-green text-shoji-white":"border-stone-gray/30 bg-transparent text-transparent hover:border-stone-gray/50"}`,onClick:s,children:(0,r.jsx)("svg",{width:"10",height:"10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"3",children:(0,r.jsx)("path",{d:"M5 12l6 6 8-8"})})}),(0,r.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,r.jsx)("div",{className:"font-mono text-sm text-ink-black truncate font-light",children:e.id}),e.name!==e.id&&(0,r.jsx)("div",{className:"font-zen-body text-xs text-stone-gray truncate font-light",children:e.name})]}),(0,r.jsxs)("button",{type:"button",className:`flex items-center gap-1.5 rounded-full border px-3 py-1 text-[0.65rem] transition-all ${l?"border-copper/50 bg-copper/10 text-copper":"border-parchment/40 text-sand hover:border-copper/40 hover:text-ink"}`,onClick:n,children:[(0,r.jsx)("span",{className:`h-2 w-2 rounded-full border ${l?"border-copper bg-copper":"border-parchment/60 bg-transparent"}`}),o("providerConfig.models.streaming")]}),(0,r.jsx)("button",{type:"button",className:"flex-shrink-0 rounded-lg p-2 text-stone-gray opacity-0 transition-all hover:text-red-500 group-hover:opacity-100",onClick:t,children:(0,r.jsx)(i.uc,{})})]})}function x({icon:e,title:t,description:s}){return(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center rounded-2xl border-1.5 border-dashed border-parchment/20 bg-washi-cream/50 p-10 text-center",children:[(0,r.jsx)("div",{className:"mb-4 rounded-xl bg-shoji-white p-4 text-stone-gray",children:(0,r.jsx)(e,{className:"h-8 w-8"})}),(0,r.jsx)("p",{className:"mb-2 font-zen-body text-sm text-stone-gray font-light",children:t}),(0,r.jsx)("p",{className:"font-zen-body text-xs text-stone-gray/70 font-light",children:s})]})}function h({open:e,onClose:t,onAdd:s}){let o=(0,a.k)(),[l,i]=(0,n.useState)(""),[d,c]=(0,n.useState)("");return((0,n.useEffect)(()=>{e||(i(""),c(""))},[e]),e)?(0,r.jsx)("div",{className:"fixed inset-0 z-[220] flex items-center justify-center bg-ink-black/20 backdrop-blur-sm",children:(0,r.jsxs)("div",{className:"w-full max-w-md rounded-2xl bg-shoji-white p-8 shadow-lg border border-parchment/10",children:[(0,r.jsx)("h3",{className:"mb-6 font-zen-display text-2xl font-light text-ink-black tracking-wide",children:o("providerConfig.addKey.title")}),(0,r.jsxs)("form",{onSubmit:e=>{e.preventDefault();let r=d.trim(),n=l.trim();r&&(s(r,n||void 0),t())},children:[(0,r.jsxs)("div",{className:"mb-5",children:[(0,r.jsx)("label",{className:"mb-2 block font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:o("providerConfig.addKey.nameLabel")}),(0,r.jsx)("input",{type:"text",value:l,onChange:e=>i(e.target.value),placeholder:o("providerConfig.addKey.namePlaceholder"),className:"w-full rounded-xl border border-parchment/20 bg-washi-cream px-5 py-4 font-zen-body text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"})]}),(0,r.jsxs)("div",{className:"mb-6",children:[(0,r.jsx)("label",{className:"mb-2 block font-zen-body text-[0.7rem] uppercase tracking-[0.15em] text-stone-gray font-light",children:o("providerConfig.addKey.valueLabel")}),(0,r.jsx)("input",{type:"password",value:d,onChange:e=>c(e.target.value),placeholder:"sk-...",className:"w-full rounded-xl border border-parchment/20 bg-washi-cream px-5 py-4 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50",autoFocus:!0})]}),(0,r.jsxs)("div",{className:"flex justify-end gap-3",children:[(0,r.jsx)("button",{type:"button",className:"rounded-xl border border-parchment/20 px-6 py-3 font-zen-body text-sm text-stone-gray transition-all duration-200 hover:border-stone-gray/30 hover:text-ink-black",onClick:t,children:o("common.cancel")}),(0,r.jsx)("button",{type:"submit",className:"rounded-xl bg-matcha-green px-6 py-3 font-zen-body text-sm text-shoji-white transition-all duration-200 hover:bg-bamboo-light",children:o("common.add")})]})]})]})}):null}function m(){let e=(0,a.k)(),t=(0,o.CU)(e=>e.providers),s=(0,o.CU)(e=>e.selectedProviderId),m=(0,o.CU)(e=>e.updateProvider),p=(0,o.CU)(e=>e.updateModel),g=(0,o.CU)(e=>e.addApiKey),u=(0,o.CU)(e=>e.updateApiKey),b=(0,o.CU)(e=>e.deleteApiKey),f=(0,o.CU)(e=>e.setPrimaryApiKey),y=(0,o.CU)(e=>e.removeModel),j=(0,o.CU)(e=>e.toggleModelEnabled),v=(0,o.CU)(e=>e.checkProviderHealth),N=(0,o.CU)(e=>e.openModelSelector),[w,k]=(0,n.useState)(""),[C,M]=(0,n.useState)(""),[S,z]=(0,n.useState)(!1),[L,U]=(0,n.useState)(!1),[_,P]=(0,n.useState)(null),T=t.find(e=>e.id===s)||null;(0,n.useEffect)(()=>{T?(k(T.name),M(T.baseUrl)):(k(""),M("")),P(null)},[s]);let E=async()=>{if(T){z(!0),P(null);try{await v(T.id)}catch(t){P(t instanceof Error?t.message:e("errors.connectionFailed"))}finally{z(!1)}}},K=T?.models.filter(e=>e.enabled)??[],W=T?.models.filter(e=>!e.enabled)??[];return T?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{className:"flex h-full flex-1 flex-col bg-shoji-white",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between border-b border-parchment/10 px-8 py-8",children:[(0,r.jsxs)("div",{className:"flex items-center gap-4",children:[(0,r.jsx)("div",{className:"flex h-12 w-12 items-center justify-center rounded-lg bg-matcha-green text-xl font-medium text-shoji-white shadow-sm",children:T.name.charAt(0).toUpperCase()}),(0,r.jsx)("input",{type:"text",value:w,onChange:e=>{var t;k(t=e.target.value),T&&m(T.id,{name:t})},className:"bg-transparent font-zen-display text-2xl font-light text-ink-black outline-none tracking-wide"})]}),(0,r.jsxs)("div",{className:"flex flex-col items-end gap-2",children:[(0,r.jsx)("button",{type:"button",className:`flex items-center gap-2.5 rounded-lg px-5 py-3 font-zen-body text-sm transition-all duration-300 ${S?"bg-washi-cream text-stone-gray cursor-wait":"bg-matcha-green/10 text-matcha-green hover:bg-matcha-green/20 font-light"}`,onClick:E,disabled:S,children:S?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(i.fN,{}),e("providerConfig.check.running")]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(i.fN,{}),e("providerConfig.check.button")]})}),_&&(0,r.jsx)("p",{className:"font-zen-body text-xs text-red-500 font-light",children:_})]})]}),(0,r.jsx)("div",{className:"flex-1 overflow-y-auto",children:(0,r.jsxs)("div",{className:"max-w-3xl px-8 py-8",children:[(0,r.jsxs)("section",{className:"mb-10",children:[(0,r.jsxs)("div",{className:"mb-5 flex items-center gap-3",children:[(0,r.jsx)("div",{className:"rounded-lg bg-washi-cream p-2.5 text-stone-gray",children:(0,r.jsx)(i.RY,{})}),(0,r.jsx)("h3",{className:"font-zen-display text-xl font-light text-ink-black tracking-wide",children:e("providerConfig.apiKeys.title")})]}),(0,r.jsx)("div",{className:"space-y-3",children:T.apiKeys.map(e=>(0,r.jsx)(d,{apiKey:e,onUpdate:t=>u(T.id,e.id,t),onDelete:()=>b(T.id,e.id),onSetPrimary:()=>f(T.id,e.id),isPrimary:e.isPrimary||1===T.apiKeys.length},e.id))}),(0,r.jsxs)("button",{type:"button",className:"mt-4 flex w-full items-center justify-center gap-2.5 rounded-xl border-1.5 border-dashed border-parchment/30 bg-washi-cream/50 px-5 py-4 font-zen-body text-sm text-stone-gray transition-all duration-300 hover:border-matcha-green/50 hover:bg-matcha-green/5 hover:text-matcha-green font-light",onClick:()=>{T&&U(!0)},children:[(0,r.jsx)(i.c1,{}),e("providerConfig.apiKeys.add")]})]}),(0,r.jsxs)("section",{className:"mb-10",children:[(0,r.jsxs)("div",{className:"mb-5 flex items-center gap-3",children:[(0,r.jsx)("div",{className:"rounded-lg bg-washi-cream p-2.5 text-stone-gray",children:(0,r.jsx)(i.qY,{})}),(0,r.jsx)("h3",{className:"font-zen-display text-xl font-light text-ink-black tracking-wide",children:e("providerConfig.baseUrl.title")})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("input",{type:"text",value:C,onChange:e=>{var t;M(t=e.target.value),T&&m(T.id,{baseUrl:(0,l.qT)(t)})},placeholder:"https://api.openai.com/v1",className:"w-full rounded-xl border border-parchment/20 bg-washi-cream px-5 py-4 font-mono text-sm text-ink-black outline-none transition-all duration-300 focus:border-matcha-green/50"}),(0,r.jsx)("p",{className:"mt-3 font-zen-body text-xs text-stone-gray font-light",children:e("providerConfig.baseUrl.preview",{url:`${(0,l.qT)(C)}/chat/completions`})})]})]}),(0,r.jsxs)("section",{children:[(0,r.jsxs)("div",{className:"mb-5 flex items-center justify-between",children:[(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)("div",{className:"rounded-lg bg-washi-cream p-2.5 text-stone-gray",children:(0,r.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",children:[(0,r.jsx)("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2"}),(0,r.jsx)("path",{d:"M9 9h6v6H9z"})]})}),(0,r.jsx)("h3",{className:"font-zen-display text-xl font-light text-ink-black tracking-wide",children:e("providerConfig.models.title")}),(0,r.jsx)("span",{className:"rounded-full bg-washi-cream px-3 py-1 font-mono text-xs text-stone-gray font-light",children:T.models.length})]}),(0,r.jsxs)("button",{type:"button",className:"flex items-center gap-2 rounded-lg border border-parchment/20 bg-washi-cream px-4 py-2.5 font-zen-body text-sm text-stone-gray transition-all duration-300 hover:border-matcha-green/50 hover:text-matcha-green font-light",onClick:()=>N(T.id),children:[(0,r.jsx)(i.WI,{}),e("providerConfig.models.select")]})]}),0===T.models.length?(0,r.jsx)(x,{icon:e=>(0,r.jsxs)("svg",{...e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1",children:[(0,r.jsx)("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2"}),(0,r.jsx)("path",{d:"M9 9h6v6H9z"})]}),title:e("providerConfig.models.empty.title"),description:e("providerConfig.models.empty.description")}):(0,r.jsxs)("div",{className:"space-y-6",children:[K.length>0&&(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"mb-3 font-mono text-xs text-stone-gray font-light",children:e("providerConfig.models.enabled",{count:K.length})}),(0,r.jsx)("div",{className:"space-y-2",children:K.map(e=>(0,r.jsx)(c,{model:e,onRemove:()=>y(T.id,e.id),onToggleEnabled:()=>j(T.id,e.id),onToggleStreaming:()=>p(T.id,e.id,{supportsStreaming:!e.supportsStreaming})},e.id))})]}),W.length>0&&(0,r.jsxs)("div",{children:[(0,r.jsx)("div",{className:"mb-3 font-mono text-xs text-stone-gray font-light",children:e("providerConfig.models.disabled",{count:W.length})}),(0,r.jsx)("div",{className:"space-y-2",children:W.map(e=>(0,r.jsx)(c,{model:e,onRemove:()=>y(T.id,e.id),onToggleEnabled:()=>j(T.id,e.id),onToggleStreaming:()=>p(T.id,e.id,{supportsStreaming:!e.supportsStreaming})},e.id))})]})]})]})]})})]}),(0,r.jsx)(h,{open:L,onClose:()=>U(!1),onAdd:(e,t)=>{T&&g(T.id,e,t)}})]}):(0,r.jsx)("div",{className:"flex h-full flex-1 items-center justify-center bg-shoji-white",children:(0,r.jsx)(x,{icon:e=>(0,r.jsxs)("svg",{...e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1",children:[(0,r.jsx)("path",{d:"M17.5 19c0-1.7-1.3-3-3-3h-11c-1.7 0-3 1.3-3 3s1.3 3 3 3h11c1.7 0 3-1.3 3-3z"}),(0,r.jsx)("path",{d:"M19 16c2.8 0 5-2.2 5-5s-2.2-5-5-5c-.5 0-1 .1-1.4.2"}),(0,r.jsx)("path",{d:"M6.5 6C8.4 3.7 11.5 2.5 14.5 3c2.3.4 4.3 1.9 5.5 4"})]}),title:e("providerConfig.empty.title"),description:e("providerConfig.empty.description")})})}}},e=>{e.O(0,[307,394,787,441,794,358],()=>e(e.s=3409)),_N_E=e.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@import "https://fonts.googleapis.com/css2?family=DM+Sans:wght@300;400;500;600&family=IBM+Plex+Mono:wght@300;400;500&family=Instrument+Serif:ital@0;1&display=swap";@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,::backdrop,:after,:before{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}}}@layer theme{:host,:root{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:"IBM Plex Mono",ui-monospace,SFMono-Regular,Menlo,monospace;--color-red-50:oklch(97.1% .013 17.38);--color-red-100:oklch(93.6% .032 17.717);--color-red-200:oklch(88.5% .062 18.334);--color-red-300:oklch(80.8% .114 19.571);--color-red-400:oklch(70.4% .191 22.216);--color-red-500:oklch(63.7% .237 25.331);--color-red-600:oklch(57.7% .245 27.325);--color-red-700:oklch(50.5% .213 27.518);--color-white:#fff;--spacing:.25rem;--container-md:28rem;--container-xl:36rem;--container-3xl:48rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height:calc(1.5/1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--font-weight-light:300;--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--tracking-tight:-.025em;--tracking-normal:0em;--tracking-wide:.025em;--tracking-widest:.1em;--leading-tight:1.25;--leading-snug:1.375;--leading-relaxed:1.625;--radius-sm:.25rem;--radius-md:.375rem;--radius-lg:.5rem;--radius-xl:.75rem;--radius-2xl:1rem;--ease-out:cubic-bezier(0,0,.2,1);--ease-in-out:cubic-bezier(.4,0,.2,1);--animate-spin:spin 1s linear infinite;--animate-pulse:pulse 2s cubic-bezier(.4,0,.6,1)infinite;--blur-sm:8px;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:"IBM Plex Mono",ui-monospace,SFMono-Regular,Menlo,monospace;--font-display:"Instrument Serif",Georgia,serif;--font-body:"DM Sans",-apple-system,sans-serif;--space-xs:.5rem;--space-sm:1rem;--space-md:1.5rem;--space-lg:2rem;--space-xl:3rem;--space-2xl:4rem}}@layer base{*,::backdrop,:after,:before{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}:host,html{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}menu,ol,ul{list-style:none}audio,canvas,embed,iframe,img,object,svg,video{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,optgroup,select,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit,::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}*,:after,:before{box-sizing:border-box;margin:0;padding:0}}@layer components;@layer utilities{.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.collapse{visibility:collapse}.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.inset-0{inset:calc(var(--spacing)*0)}.inset-y-0{inset-block:calc(var(--spacing)*0)}.top-0{top:calc(var(--spacing)*0)}.top-1\/2{top:50%}.top-2\.5{top:calc(var(--spacing)*2.5)}.top-3{top:calc(var(--spacing)*3)}.top-4{top:calc(var(--spacing)*4)}.top-6{top:calc(var(--spacing)*6)}.right-0{right:calc(var(--spacing)*0)}.right-2\.5{right:calc(var(--spacing)*2.5)}.right-3{right:calc(var(--spacing)*3)}.right-4{right:calc(var(--spacing)*4)}.right-6{right:calc(var(--spacing)*6)}.bottom-3{bottom:calc(var(--spacing)*3)}.bottom-5{bottom:calc(var(--spacing)*5)}.bottom-8{bottom:calc(var(--spacing)*8)}.bottom-full{bottom:100%}.left-0{left:calc(var(--spacing)*0)}.left-8{left:calc(var(--spacing)*8)}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\[60\]{z-index:60}.z-\[100\]{z-index:100}.z-\[200\]{z-index:200}.z-\[220\]{z-index:220}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.mx-5{margin-inline:calc(var(--spacing)*5)}.mx-auto{margin-inline:auto}.my-8{margin-block:calc(var(--spacing)*8)}.-mt-1{margin-top:calc(var(--spacing)*-1)}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-3{margin-top:calc(var(--spacing)*3)}.mt-4{margin-top:calc(var(--spacing)*4)}.mt-5{margin-top:calc(var(--spacing)*5)}.mt-6{margin-top:calc(var(--spacing)*6)}.mb-1{margin-bottom:calc(var(--spacing)*1)}.mb-1\.5{margin-bottom:calc(var(--spacing)*1.5)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.mb-2\.5{margin-bottom:calc(var(--spacing)*2.5)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.mb-4{margin-bottom:calc(var(--spacing)*4)}.mb-5{margin-bottom:calc(var(--spacing)*5)}.mb-6{margin-bottom:calc(var(--spacing)*6)}.mb-8{margin-bottom:calc(var(--spacing)*8)}.mb-10{margin-bottom:calc(var(--spacing)*10)}.ml-2{margin-left:calc(var(--spacing)*2)}.ml-auto{margin-left:auto}.line-clamp-1{-webkit-line-clamp:1}.line-clamp-1,.line-clamp-2{-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.\!h-2\.5{height:calc(var(--spacing)*2.5)!important}.h-0{height:calc(var(--spacing)*0)}.h-1\.5{height:calc(var(--spacing)*1.5)}.h-2{height:calc(var(--spacing)*2)}.h-3{height:calc(var(--spacing)*3)}.h-3\.5{height:calc(var(--spacing)*3.5)}.h-4{height:calc(var(--spacing)*4)}.h-4\.5{height:calc(var(--spacing)*4.5)}.h-5{height:calc(var(--spacing)*5)}.h-6{height:calc(var(--spacing)*6)}.h-7{height:calc(var(--spacing)*7)}.h-8{height:calc(var(--spacing)*8)}.h-9{height:calc(var(--spacing)*9)}.h-10{height:calc(var(--spacing)*10)}.h-12{height:calc(var(--spacing)*12)}.h-32{height:calc(var(--spacing)*32)}.h-48{height:calc(var(--spacing)*48)}.h-\[18px\]{height:18px}.h-\[46px\]{height:46px}.h-\[74px\]{height:74px}.h-\[110px\]{height:110px}.h-\[220px\]{height:220px}.h-full{height:100%}.h-screen{height:100vh}.max-h-44{max-height:calc(var(--spacing)*44)}.max-h-\[50vh\]{max-height:50vh}.max-h-\[52vh\]{max-height:52vh}.max-h-\[140px\]{max-height:140px}.max-h-\[180px\]{max-height:180px}.max-h-\[220px\]{max-height:220px}.max-h-\[240px\]{max-height:240px}.max-h-\[260px\]{max-height:260px}.min-h-0{min-height:calc(var(--spacing)*0)}.min-h-7{min-height:calc(var(--spacing)*7)}.min-h-\[60px\]{min-height:60px}.min-h-\[120px\]{min-height:120px}.\!w-2\.5{width:calc(var(--spacing)*2.5)!important}.w-0\.5{width:calc(var(--spacing)*.5)}.w-1\.5{width:calc(var(--spacing)*1.5)}.w-2{width:calc(var(--spacing)*2)}.w-3{width:calc(var(--spacing)*3)}.w-3\.5{width:calc(var(--spacing)*3.5)}.w-4{width:calc(var(--spacing)*4)}.w-4\.5{width:calc(var(--spacing)*4.5)}.w-5{width:calc(var(--spacing)*5)}.w-6{width:calc(var(--spacing)*6)}.w-7{width:calc(var(--spacing)*7)}.w-8{width:calc(var(--spacing)*8)}.w-9{width:calc(var(--spacing)*9)}.w-10{width:calc(var(--spacing)*10)}.w-11{width:calc(var(--spacing)*11)}.w-12{width:calc(var(--spacing)*12)}.w-32{width:calc(var(--spacing)*32)}.w-52{width:calc(var(--spacing)*52)}.w-\[3px\]{width:3px}.w-\[18px\]{width:18px}.w-\[82vw\]{width:82vw}.w-\[90vw\]{width:90vw}.w-\[124px\]{width:124px}.w-\[170px\]{width:170px}.w-\[200px\]{width:200px}.w-\[240px\]{width:240px}.w-\[260px\]{width:260px}.w-\[320px\]{width:320px}.w-full{width:100%}.max-w-3xl{max-width:var(--container-3xl)}.max-w-\[42ch\]{max-width:42ch}.max-w-\[280px\]{max-width:280px}.max-w-\[360px\]{max-width:360px}.max-w-\[520px\]{max-width:520px}.max-w-\[680px\]{max-width:680px}.max-w-md{max-width:var(--container-md)}.max-w-xl{max-width:var(--container-xl)}.min-w-0{min-width:calc(var(--spacing)*0)}.min-w-7{min-width:calc(var(--spacing)*7)}.min-w-\[180px\]{min-width:180px}.min-w-\[220px\]{min-width:220px}.flex-1{flex:1}.flex-shrink-0,.shrink-0{flex-shrink:0}.-translate-x-full{--tw-translate-x:-100%}.-translate-x-full,.translate-x-0{translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-0{--tw-translate-x:calc(var(--spacing)*0)}.translate-x-0\.5{--tw-translate-x:calc(var(--spacing)*.5)}.translate-x-0\.5,.translate-x-6{translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-6{--tw-translate-x:calc(var(--spacing)*6)}.translate-x-full{--tw-translate-x:100%}.-translate-y-1\/2,.translate-x-full{translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\/2{--tw-translate-y:calc(calc(1/2*100%)*-1)}.scale-y-0{--tw-scale-y:0%}.scale-y-0,.scale-y-100{scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-y-100{--tw-scale-y:100%}.-rotate-90{rotate:-90deg}.rotate-0{rotate:none}.rotate-180{rotate:180deg}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-pulse{animation:var(--animate-pulse)}.animate-spin{animation:var(--animate-spin)}.cursor-col-resize{cursor:col-resize}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-wait{cursor:wait}.touch-none{touch-action:none}.resize{resize:both}.resize-none{resize:none}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-rows-\[minmax\(0\,1fr\)_auto\]{grid-template-rows:minmax(0,1fr) auto}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-baseline{align-items:baseline}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.items-stretch{align-items:stretch}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-1{gap:calc(var(--spacing)*1)}.gap-1\.5{gap:calc(var(--spacing)*1.5)}.gap-2{gap:calc(var(--spacing)*2)}.gap-2\.5{gap:calc(var(--spacing)*2.5)}.gap-3{gap:calc(var(--spacing)*3)}.gap-4{gap:calc(var(--spacing)*4)}.gap-5{gap:calc(var(--spacing)*5)}.gap-6{gap:calc(var(--spacing)*6)}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*1)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*2)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*3)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*4)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*6)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*6)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-8>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*8)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*8)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-10>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*10)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*10)*calc(1 - var(--tw-space-y-reverse)))}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.\!rounded-xl{border-radius:var(--radius-xl)!important}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-\[10px\]{border-radius:10px}.rounded-\[18px\]{border-radius:18px}.rounded-full{border-radius:3.40282e+38px}.rounded-lg{border-radius:var(--radius-lg)}.rounded-md{border-radius:var(--radius-md)}.rounded-sm{border-radius:var(--radius-sm)}.rounded-xl{border-radius:var(--radius-xl)}.rounded-r-sm{border-top-right-radius:var(--radius-sm);border-bottom-right-radius:var(--radius-sm)}.\!border-0{border-style:var(--tw-border-style)!important;border-width:0!important}.border{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-r{border-right-style:var(--tw-border-style);border-right-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-none{--tw-border-style:none;border-style:none}.border-\[\#e74c3c\]\/30{border-color:oklab(63.0682% .168954 .0953622/.3)}.border-\[\#e74c3c\]\/40{border-color:oklab(63.0682% .168954 .0953622/.4)}.border-\[rgba\(255\,255\,255\,0\.4\)\]{border-color:#fff6}.border-copper,.border-copper\/50{border-color:var(--copper)}@supports (color:color-mix(in lab,red,red)){.border-copper\/50{border-color:color-mix(in oklab,var(--copper)50%,transparent)}}.border-matcha-green,.border-matcha-green\/15{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.border-matcha-green\/15{border-color:color-mix(in oklab,var(--matcha-green)15%,transparent)}}.border-matcha-green\/20{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.border-matcha-green\/20{border-color:color-mix(in oklab,var(--matcha-green)20%,transparent)}}.border-matcha-green\/40{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.border-matcha-green\/40{border-color:color-mix(in oklab,var(--matcha-green)40%,transparent)}}.border-parchment,.border-parchment\/10{border-color:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.border-parchment\/10{border-color:color-mix(in oklab,var(--parchment)10%,transparent)}}.border-parchment\/20{border-color:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.border-parchment\/20{border-color:color-mix(in oklab,var(--parchment)20%,transparent)}}.border-parchment\/30{border-color:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.border-parchment\/30{border-color:color-mix(in oklab,var(--parchment)30%,transparent)}}.border-parchment\/40{border-color:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.border-parchment\/40{border-color:color-mix(in oklab,var(--parchment)40%,transparent)}}.border-parchment\/60{border-color:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.border-parchment\/60{border-color:color-mix(in oklab,var(--parchment)60%,transparent)}}.border-red-200{border-color:var(--color-red-200)}.border-stone-gray\/30{border-color:var(--stone-gray)}@supports (color:color-mix(in lab,red,red)){.border-stone-gray\/30{border-color:color-mix(in oklab,var(--stone-gray)30%,transparent)}}.border-transparent{border-color:#0000}.border-t-transparent{border-top-color:#0000}.\!bg-\[rgba\(250\,249\,247\,0\.55\)\]{background-color:#faf9f78c!important}.\!bg-paper\/70{background-color:var(--paper)!important}@supports (color:color-mix(in lab,red,red)){.\!bg-paper\/70{background-color:color-mix(in oklab,var(--paper)70%,transparent)!important}}.bg-\[\#e74c3c\]{background-color:#e74c3c}.bg-\[\#e74c3c\]\/10{background-color:oklab(63.0682% .168954 .0953622/.1)}.bg-\[\#fff5f2\]{background-color:#fff5f2}.bg-\[rgba\(255\,255\,255\,0\.12\)\]{background-color:#ffffff1f}.bg-copper{background-color:var(--copper)}.bg-copper-glow{background-color:var(--copper-glow)}.bg-copper\/10{background-color:var(--copper)}@supports (color:color-mix(in lab,red,red)){.bg-copper\/10{background-color:color-mix(in oklab,var(--copper)10%,transparent)}}.bg-cream,.bg-cream\/60{background-color:var(--cream)}@supports (color:color-mix(in lab,red,red)){.bg-cream\/60{background-color:color-mix(in oklab,var(--cream)60%,transparent)}}.bg-cream\/95{background-color:var(--cream)}@supports (color:color-mix(in lab,red,red)){.bg-cream\/95{background-color:color-mix(in oklab,var(--cream)95%,transparent)}}.bg-human{background-color:var(--human)}.bg-ink{background-color:var(--ink)}.bg-ink-black\/20{background-color:var(--ink-black)}@supports (color:color-mix(in lab,red,red)){.bg-ink-black\/20{background-color:color-mix(in oklab,var(--ink-black)20%,transparent)}}.bg-ink\/20{background-color:var(--ink)}@supports (color:color-mix(in lab,red,red)){.bg-ink\/20{background-color:color-mix(in oklab,var(--ink)20%,transparent)}}.bg-ink\/30{background-color:var(--ink)}@supports (color:color-mix(in lab,red,red)){.bg-ink\/30{background-color:color-mix(in oklab,var(--ink)30%,transparent)}}.bg-kintsugi-gold,.bg-kintsugi-gold\/10{background-color:var(--kintsugi-gold)}@supports (color:color-mix(in lab,red,red)){.bg-kintsugi-gold\/10{background-color:color-mix(in oklab,var(--kintsugi-gold)10%,transparent)}}.bg-machine{background-color:var(--machine)}.bg-matcha-green,.bg-matcha-green\/10{background-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.bg-matcha-green\/10{background-color:color-mix(in oklab,var(--matcha-green)10%,transparent)}}.bg-paper,.bg-paper\/40{background-color:var(--paper)}@supports (color:color-mix(in lab,red,red)){.bg-paper\/40{background-color:color-mix(in oklab,var(--paper)40%,transparent)}}.bg-paper\/50{background-color:var(--paper)}@supports (color:color-mix(in lab,red,red)){.bg-paper\/50{background-color:color-mix(in oklab,var(--paper)50%,transparent)}}.bg-paper\/60{background-color:var(--paper)}@supports (color:color-mix(in lab,red,red)){.bg-paper\/60{background-color:color-mix(in oklab,var(--paper)60%,transparent)}}.bg-parchment,.bg-parchment\/25{background-color:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.bg-parchment\/25{background-color:color-mix(in oklab,var(--parchment)25%,transparent)}}.bg-red-50{background-color:var(--color-red-50)}.bg-red-500{background-color:var(--color-red-500)}.bg-shoji-white,.bg-shoji-white\/95{background-color:var(--shoji-white)}@supports (color:color-mix(in lab,red,red)){.bg-shoji-white\/95{background-color:color-mix(in oklab,var(--shoji-white)95%,transparent)}}.bg-stone-gray,.bg-stone-gray\/30{background-color:var(--stone-gray)}@supports (color:color-mix(in lab,red,red)){.bg-stone-gray\/30{background-color:color-mix(in oklab,var(--stone-gray)30%,transparent)}}.bg-system{background-color:var(--system)}.bg-transparent{background-color:#0000}.bg-washi-cream,.bg-washi-cream\/50{background-color:var(--washi-cream)}@supports (color:color-mix(in lab,red,red)){.bg-washi-cream\/50{background-color:color-mix(in oklab,var(--washi-cream)50%,transparent)}}.bg-washi-cream\/60{background-color:var(--washi-cream)}@supports (color:color-mix(in lab,red,red)){.bg-washi-cream\/60{background-color:color-mix(in oklab,var(--washi-cream)60%,transparent)}}.bg-washi-cream\/70{background-color:var(--washi-cream)}@supports (color:color-mix(in lab,red,red)){.bg-washi-cream\/70{background-color:color-mix(in oklab,var(--washi-cream)70%,transparent)}}.bg-white{background-color:var(--color-white)}.bg-gradient-to-br{--tw-gradient-position:to bottom right in oklab}.bg-gradient-to-br,.bg-gradient-to-r{background-image:linear-gradient(var(--tw-gradient-stops))}.bg-gradient-to-r{--tw-gradient-position:to right in oklab}.from-copper{--tw-gradient-from:var(--copper);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-human{--tw-gradient-from:var(--human);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-machine{--tw-gradient-from:var(--machine);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-system{--tw-gradient-from:var(--system);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-\[\#3a5432\]{--tw-gradient-to:#3a5432;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-\[\#3d4a5c\]{--tw-gradient-to:#3d4a5c;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-\[\#5a4a3f\]{--tw-gradient-to:#5a4a3f;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-\[\#9a5e2a\]{--tw-gradient-to:#9a5e2a;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-copper-light{--tw-gradient-to:var(--copper-light);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.fill-copper{fill:var(--copper)}.fill-ink\/60{fill:var(--ink)}@supports (color:color-mix(in lab,red,red)){.fill-ink\/60{fill:color-mix(in oklab,var(--ink)60%,transparent)}}.stroke-ink\/10{stroke:var(--ink)}@supports (color:color-mix(in lab,red,red)){.stroke-ink\/10{stroke:color-mix(in oklab,var(--ink)10%,transparent)}}.stroke-parchment\/80{stroke:var(--parchment)}@supports (color:color-mix(in lab,red,red)){.stroke-parchment\/80{stroke:color-mix(in oklab,var(--parchment)80%,transparent)}}.p-1{padding:calc(var(--spacing)*1)}.p-2{padding:calc(var(--spacing)*2)}.p-2\.5{padding:calc(var(--spacing)*2.5)}.p-3{padding:calc(var(--spacing)*3)}.p-3\.5{padding:calc(var(--spacing)*3.5)}.p-4{padding:calc(var(--spacing)*4)}.p-5{padding:calc(var(--spacing)*5)}.p-6{padding:calc(var(--spacing)*6)}.p-8{padding:calc(var(--spacing)*8)}.p-10{padding:calc(var(--spacing)*10)}.px-0{padding-inline:calc(var(--spacing)*0)}.px-1{padding-inline:calc(var(--spacing)*1)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-2\.5{padding-inline:calc(var(--spacing)*2.5)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.px-5{padding-inline:calc(var(--spacing)*5)}.px-6{padding-inline:calc(var(--spacing)*6)}.px-7{padding-inline:calc(var(--spacing)*7)}.px-8{padding-inline:calc(var(--spacing)*8)}.py-0{padding-block:calc(var(--spacing)*0)}.py-0\.5{padding-block:calc(var(--spacing)*.5)}.py-1{padding-block:calc(var(--spacing)*1)}.py-1\.5{padding-block:calc(var(--spacing)*1.5)}.py-2{padding-block:calc(var(--spacing)*2)}.py-2\.5{padding-block:calc(var(--spacing)*2.5)}.py-3{padding-block:calc(var(--spacing)*3)}.py-3\.5{padding-block:calc(var(--spacing)*3.5)}.py-4{padding-block:calc(var(--spacing)*4)}.py-5{padding-block:calc(var(--spacing)*5)}.py-6{padding-block:calc(var(--spacing)*6)}.py-7{padding-block:calc(var(--spacing)*7)}.py-8{padding-block:calc(var(--spacing)*8)}.py-12{padding-block:calc(var(--spacing)*12)}.py-16{padding-block:calc(var(--spacing)*16)}.pt-2{padding-top:calc(var(--spacing)*2)}.pt-5{padding-top:calc(var(--spacing)*5)}.pt-7{padding-top:calc(var(--spacing)*7)}.pt-8{padding-top:calc(var(--spacing)*8)}.pr-1{padding-right:calc(var(--spacing)*1)}.pr-4{padding-right:calc(var(--spacing)*4)}.pr-10{padding-right:calc(var(--spacing)*10)}.pr-\[120px\]{padding-right:120px}.pb-1{padding-bottom:calc(var(--spacing)*1)}.pb-2{padding-bottom:calc(var(--spacing)*2)}.pb-3{padding-bottom:calc(var(--spacing)*3)}.pb-5{padding-bottom:calc(var(--spacing)*5)}.pb-6{padding-bottom:calc(var(--spacing)*6)}.pl-10{padding-left:calc(var(--spacing)*10)}.pl-11{padding-left:calc(var(--spacing)*11)}.text-center{text-align:center}.text-left{text-align:left}.font-body{font-family:DM Sans,-apple-system,sans-serif}.font-display{font-family:Instrument Serif,Georgia,serif}.font-mono{font-family:IBM Plex Mono,ui-monospace,SFMono-Regular,Menlo,monospace}.font-zen-body{font-family:var(--font-body)}.font-zen-display{font-family:var(--font-display)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\[0\.6rem\]{font-size:.6rem}.text-\[0\.7rem\]{font-size:.7rem}.text-\[0\.8rem\]{font-size:.8rem}.text-\[0\.9rem\]{font-size:.9rem}.text-\[0\.65rem\]{font-size:.65rem}.text-\[0\.75rem\]{font-size:.75rem}.text-\[0\.85rem\]{font-size:.85rem}.text-\[0\.95rem\]{font-size:.95rem}.text-\[1\.1rem\]{font-size:1.1rem}.text-\[1\.2rem\]{font-size:1.2rem}.text-\[1\.15rem\]{font-size:1.15rem}.text-\[1\.35rem\]{font-size:1.35rem}.text-\[1\.75rem\]{font-size:1.75rem}.leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.font-light{--tw-font-weight:var(--font-weight-light);font-weight:var(--font-weight-light)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-\[0\.1em\]{--tw-tracking:.1em;letter-spacing:.1em}.tracking-\[0\.2em\]{--tw-tracking:.2em;letter-spacing:.2em}.tracking-\[0\.12em\]{--tw-tracking:.12em;letter-spacing:.12em}.tracking-\[0\.15em\]{--tw-tracking:.15em;letter-spacing:.15em}.tracking-\[0\.25em\]{--tw-tracking:.25em;letter-spacing:.25em}.tracking-normal{--tw-tracking:var(--tracking-normal);letter-spacing:var(--tracking-normal)}.tracking-tight{--tw-tracking:var(--tracking-tight);letter-spacing:var(--tracking-tight)}.tracking-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.text-\[\#b73c2b\]{color:#b73c2b}.text-\[\#b1382c\]{color:#b1382c}.text-\[\#e74c3c\]{color:#e74c3c}.text-charcoal{color:var(--charcoal)}.text-clay{color:var(--clay)}.text-copper{color:var(--copper)}.text-cream,.text-cream\/80{color:var(--cream)}@supports (color:color-mix(in lab,red,red)){.text-cream\/80{color:color-mix(in oklab,var(--cream)80%,transparent)}}.text-ink{color:var(--ink)}.text-ink-black{color:var(--ink-black)}.text-kintsugi-gold{color:var(--kintsugi-gold)}.text-matcha-green{color:var(--matcha-green)}.text-red-400{color:var(--color-red-400)}.text-red-500{color:var(--color-red-500)}.text-red-600{color:var(--color-red-600)}.text-red-700{color:var(--color-red-700)}.text-sand{color:var(--sand)}.text-shoji-white{color:var(--shoji-white)}.text-stone-gray,.text-stone-gray\/70{color:var(--stone-gray)}@supports (color:color-mix(in lab,red,red)){.text-stone-gray\/70{color:color-mix(in oklab,var(--stone-gray)70%,transparent)}}.text-transparent{color:#0000}.text-white{color:var(--color-white)}.normal-case{text-transform:none}.uppercase{text-transform:uppercase}.italic{font-style:italic}.underline{text-decoration-line:underline}.underline-offset-2{text-underline-offset:2px}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-40{opacity:.4}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-75{opacity:.75}.opacity-80{opacity:.8}.opacity-95{opacity:.95}.opacity-100{opacity:1}.shadow-\[0_8px_24px_rgba\(26\,24\,22\,0\.05\)\]{--tw-shadow:0 8px 24px var(--tw-shadow-color,#1a18160d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_8px_28px_rgba\(26\,24\,22\,0\.12\)\,0_0_0_1px_rgba\(255\,255\,255\,0\.08\)\]{--tw-shadow:0 8px 28px var(--tw-shadow-color,#1a18161f),0 0 0 1px var(--tw-shadow-color,#ffffff14);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_8px_28px_rgba\(26\,24\,22\,0\.14\)\,0_0_0_1px_rgba\(184\,115\,51\,0\.35\)\]{--tw-shadow:0 8px 28px var(--tw-shadow-color,#1a181624),0 0 0 1px var(--tw-shadow-color,#b8733359);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_8px_28px_rgba\(26\,24\,22\,0\.18\)\,0_0_0_2px_rgba\(196\,189\,180\,0\.9\)\]{--tw-shadow:0 8px 28px var(--tw-shadow-color,#1a18162e),0 0 0 2px var(--tw-shadow-color,#c4bdb4e6);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_10px_28px_rgba\(26\,24\,22\,0\.06\)\]{--tw-shadow:0 10px 28px var(--tw-shadow-color,#1a18160f)}.shadow-\[0_10px_28px_rgba\(26\,24\,22\,0\.06\)\],.shadow-\[0_10px_36px_rgba\(184\,115\,51\,0\.32\)\,0_0_0_2px_var\(--copper\)\]{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_10px_36px_rgba\(184\,115\,51\,0\.32\)\,0_0_0_2px_var\(--copper\)\]{--tw-shadow:0 10px 36px var(--tw-shadow-color,#b8733352),0 0 0 2px var(--tw-shadow-color,var(--copper))}.shadow-\[0_12px_32px_rgba\(26\,24\,22\,0\.08\)\]{--tw-shadow:0 12px 32px var(--tw-shadow-color,#1a181614)}.shadow-\[0_12px_32px_rgba\(26\,24\,22\,0\.08\)\],.shadow-\[0_16px_38px_rgba\(26\,24\,22\,0\.12\)\]{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_16px_38px_rgba\(26\,24\,22\,0\.12\)\]{--tw-shadow:0 16px 38px var(--tw-shadow-color,#1a18161f)}.shadow-\[0_16px_40px_rgba\(35\,31\,28\,0\.18\)\]{--tw-shadow:0 16px 40px var(--tw-shadow-color,#231f1c2e)}.shadow-\[0_16px_40px_rgba\(35\,31\,28\,0\.18\)\],.shadow-\[0_22px_60px_rgba\(35\,31\,28\,0\.18\)\]{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_22px_60px_rgba\(35\,31\,28\,0\.18\)\]{--tw-shadow:0 22px 60px var(--tw-shadow-color,#231f1c2e)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a)}.shadow-lg,.shadow-sm{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a),0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.\!backdrop-blur-sm{--tw-backdrop-blur:blur(var(--blur-sm))!important;-webkit-backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,)!important;backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,)!important}.backdrop-blur-sm{--tw-backdrop-blur:blur(var(--blur-sm))}.backdrop-blur-sm,.backdrop-filter{-webkit-backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-150{--tw-duration:.15s;transition-duration:.15s}.duration-200{--tw-duration:.2s;transition-duration:.2s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.duration-500{--tw-duration:.5s;transition-duration:.5s}.ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}@media (hover:hover){.group-hover\:pointer-events-auto:is(:where(.group):hover *){pointer-events:auto}.group-hover\:bg-copper:is(:where(.group):hover *){background-color:var(--copper)}.group-hover\:opacity-100:is(:where(.group):hover *){opacity:1}}.placeholder\:text-sand::placeholder{color:var(--sand)}.placeholder\:text-stone-gray\/50::placeholder{color:var(--stone-gray)}@supports (color:color-mix(in lab,red,red)){.placeholder\:text-stone-gray\/50::placeholder{color:color-mix(in oklab,var(--stone-gray)50%,transparent)}}.focus-within\:shadow-\[0_18px_40px_rgba\(26\,24\,22\,0\.12\)\]:focus-within{--tw-shadow:0 18px 40px var(--tw-shadow-color,#1a18161f);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}@media (hover:hover){.hover\:-translate-y-px:hover{--tw-translate-y:-1px;translate:var(--tw-translate-x)var(--tw-translate-y)}.hover\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\:border-\[\#e74c3c\]:hover{border-color:#e74c3c}.hover\:border-\[rgba\(255\,255\,255\,0\.7\)\]:hover{border-color:#ffffffb3}.hover\:border-copper:hover,.hover\:border-copper\/40:hover{border-color:var(--copper)}@supports (color:color-mix(in lab,red,red)){.hover\:border-copper\/40:hover{border-color:color-mix(in oklab,var(--copper)40%,transparent)}}.hover\:border-matcha-green\/20:hover{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:border-matcha-green\/20:hover{border-color:color-mix(in oklab,var(--matcha-green)20%,transparent)}}.hover\:border-matcha-green\/30:hover{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:border-matcha-green\/30:hover{border-color:color-mix(in oklab,var(--matcha-green)30%,transparent)}}.hover\:border-matcha-green\/40:hover{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:border-matcha-green\/40:hover{border-color:color-mix(in oklab,var(--matcha-green)40%,transparent)}}.hover\:border-matcha-green\/50:hover{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:border-matcha-green\/50:hover{border-color:color-mix(in oklab,var(--matcha-green)50%,transparent)}}.hover\:border-red-300:hover{border-color:var(--color-red-300)}.hover\:border-sand:hover{border-color:var(--sand)}.hover\:border-stone-gray\/30:hover{border-color:var(--stone-gray)}@supports (color:color-mix(in lab,red,red)){.hover\:border-stone-gray\/30:hover{border-color:color-mix(in oklab,var(--stone-gray)30%,transparent)}}.hover\:border-stone-gray\/50:hover{border-color:var(--stone-gray)}@supports (color:color-mix(in lab,red,red)){.hover\:border-stone-gray\/50:hover{border-color:color-mix(in oklab,var(--stone-gray)50%,transparent)}}.hover\:bg-\[\#d64533\]:hover{background-color:#d64533}.hover\:bg-\[\#e74c3c\]:hover{background-color:#e74c3c}.hover\:bg-\[\#e74c3c\]\/10:hover{background-color:oklab(63.0682% .168954 .0953622/.1)}.hover\:bg-bamboo-light:hover{background-color:var(--bamboo-light)}.hover\:bg-charcoal:hover{background-color:var(--charcoal)}.hover\:bg-copper-glow:hover{background-color:var(--copper-glow)}.hover\:bg-copper\/90:hover{background-color:var(--copper)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-copper\/90:hover{background-color:color-mix(in oklab,var(--copper)90%,transparent)}}.hover\:bg-cream:hover{background-color:var(--cream)}.hover\:bg-matcha-green\/5:hover{background-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-matcha-green\/5:hover{background-color:color-mix(in oklab,var(--matcha-green)5%,transparent)}}.hover\:bg-matcha-green\/20:hover{background-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-matcha-green\/20:hover{background-color:color-mix(in oklab,var(--matcha-green)20%,transparent)}}.hover\:bg-matcha-green\/90:hover{background-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-matcha-green\/90:hover{background-color:color-mix(in oklab,var(--matcha-green)90%,transparent)}}.hover\:bg-paper:hover,.hover\:bg-paper\/50:hover{background-color:var(--paper)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-paper\/50:hover{background-color:color-mix(in oklab,var(--paper)50%,transparent)}}.hover\:bg-red-100:hover{background-color:var(--color-red-100)}.hover\:bg-sakura-pink\/30:hover{background-color:var(--sakura-pink)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-sakura-pink\/30:hover{background-color:color-mix(in oklab,var(--sakura-pink)30%,transparent)}}.hover\:bg-washi-cream\/30:hover{background-color:var(--washi-cream)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-washi-cream\/30:hover{background-color:color-mix(in oklab,var(--washi-cream)30%,transparent)}}.hover\:bg-washi-cream\/50:hover{background-color:var(--washi-cream)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-washi-cream\/50:hover{background-color:color-mix(in oklab,var(--washi-cream)50%,transparent)}}.hover\:text-\[\#e74c3c\]:hover{color:#e74c3c}.hover\:text-copper:hover{color:var(--copper)}.hover\:text-ink:hover{color:var(--ink)}.hover\:text-ink-black:hover{color:var(--ink-black)}.hover\:text-matcha-green:hover{color:var(--matcha-green)}.hover\:text-red-500:hover{color:var(--color-red-500)}.hover\:text-white:hover{color:var(--color-white)}.hover\:underline:hover{text-decoration-line:underline}.hover\:shadow-\[0_14px_38px_rgba\(184\,115\,51\,0\.12\)\]:hover{--tw-shadow:0 14px 38px var(--tw-shadow-color,#b873331f)}.hover\:shadow-\[0_14px_38px_rgba\(184\,115\,51\,0\.12\)\]:hover,.hover\:shadow-\[0_18px_40px_rgba\(26\,24\,22\,0\.12\)\]:hover{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.hover\:shadow-\[0_18px_40px_rgba\(26\,24\,22\,0\.12\)\]:hover{--tw-shadow:0 18px 40px var(--tw-shadow-color,#1a18161f)}.hover\:shadow-sm:hover{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a)}.hover\:shadow-sm:hover,.hover\:shadow-xl:hover{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.hover\:shadow-xl:hover{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a),0 8px 10px -6px var(--tw-shadow-color,#0000001a)}}.focus\:border-copper:focus{border-color:var(--copper)}.focus\:border-matcha-green\/50:focus{border-color:var(--matcha-green)}@supports (color:color-mix(in lab,red,red)){.focus\:border-matcha-green\/50:focus{border-color:color-mix(in oklab,var(--matcha-green)50%,transparent)}}.focus\:shadow-\[0_0_0_3px_var\(--copper-glow\)\]:focus{--tw-shadow:0 0 0 3px var(--tw-shadow-color,var(--copper-glow))}.focus\:shadow-\[0_0_0_3px_var\(--copper-glow\)\]:focus,.focus\:shadow-sm:focus{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus\:shadow-sm:focus{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a)}.active\:cursor-grabbing:active{cursor:grabbing}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-50:disabled{opacity:.5}.disabled\:opacity-60:disabled{opacity:.6}@media (min-width:48rem){.md\:col-span-2{grid-column:span 2/span 2}.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width:64rem){.lg\:absolute{position:absolute}.lg\:static{position:static}.lg\:top-0{top:calc(var(--spacing)*0)}.lg\:top-6{top:calc(var(--spacing)*6)}.lg\:right-0{right:calc(var(--spacing)*0)}.lg\:right-8{right:calc(var(--spacing)*8)}.lg\:left-0{left:calc(var(--spacing)*0)}.lg\:z-auto{z-index:auto}.lg\:flex{display:flex}.lg\:grid{display:grid}.lg\:hidden{display:none}.lg\:h-\[130px\]{height:130px}.lg\:h-full{height:100%}.lg\:max-h-0{max-height:calc(var(--spacing)*0)}.lg\:w-\[210px\]{width:210px}.lg\:w-full{width:100%}.lg\:max-w-none{max-width:none}.lg\:translate-x-0{--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.lg\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.lg\:grid-rows-\[minmax\(0\,1fr\)\]{grid-template-rows:minmax(0,1fr)}.lg\:flex-row{flex-direction:row}.lg\:items-center{align-items:center}.lg\:justify-between{justify-content:space-between}.lg\:gap-6{gap:calc(var(--spacing)*6)}.lg\:px-8{padding-inline:calc(var(--spacing)*8)}.lg\:py-2{padding-block:calc(var(--spacing)*2)}.lg\:py-5{padding-block:calc(var(--spacing)*5)}.lg\:opacity-0{opacity:0}.lg\:group-focus-within\:max-h-\[240px\]:is(:where(.group):focus-within *){max-height:240px}.lg\:group-focus-within\:opacity-100:is(:where(.group):focus-within *){opacity:1}@media (hover:hover){.lg\:group-hover\:max-h-\[240px\]:is(:where(.group):hover *){max-height:240px}.lg\:group-hover\:opacity-100:is(:where(.group):hover *){opacity:1}}.lg\:focus-within\:h-\[min\(640px\,62vh\)\]:focus-within{height:min(640px,62vh)}.lg\:focus-within\:w-\[min\(920px\,calc\(100vw_-_3rem\)\)\]:focus-within{width:min(920px,100vw - 3rem)}.lg\:focus-within\:bg-paper:focus-within{background-color:var(--paper)}@media (hover:hover){.lg\:hover\:h-\[min\(640px\,62vh\)\]:hover{height:min(640px,62vh)}.lg\:hover\:w-\[min\(920px\,calc\(100vw_-_3rem\)\)\]:hover{width:min(920px,100vw - 3rem)}.lg\:hover\:bg-paper:hover{background-color:var(--paper)}}}.\[\&_\.react-flow__attribution\]\:hidden .react-flow attribution{display:none}.\[\&_\.react-flow__background\]\:opacity-0 .react-flow background{opacity:0}.\[\&_\.react-flow__background\]\:transition-opacity .react-flow background{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.\[\&_\.react-flow__background\]\:duration-200 .react-flow background{--tw-duration:.2s;transition-duration:.2s}@media (min-width:64rem){.lg\:group-focus-within\:\[\&_\.react-flow__background\]\:opacity-100:is(:where(.group):focus-within *) .react-flow background{opacity:1}@media (hover:hover){.lg\:group-hover\:\[\&_\.react-flow__background\]\:opacity-100:is(:where(.group):hover *) .react-flow background{opacity:1}}}.\[\&_\.react-flow__minimap\]\:\!inset-0 .react-flow minimap{inset:calc(var(--spacing)*0)!important}.\[\&_\.react-flow__minimap\]\:\!h-full .react-flow minimap{height:100%!important}.\[\&_\.react-flow__minimap\]\:\!w-full .react-flow minimap{width:100%!important}.\[\&_\.react-flow__minimap\]\:overflow-hidden .react-flow minimap{overflow:hidden}@media (min-width:64rem){.lg\:group-focus-within\:\[\&_\.react-flow__minimap\]\:\!top-auto:is(:where(.group):focus-within *) .react-flow minimap{top:auto!important}.lg\:group-focus-within\:\[\&_\.react-flow__minimap\]\:\!right-4:is(:where(.group):focus-within *) .react-flow minimap{right:calc(var(--spacing)*4)!important}.lg\:group-focus-within\:\[\&_\.react-flow__minimap\]\:\!bottom-4:is(:where(.group):focus-within *) .react-flow minimap{bottom:calc(var(--spacing)*4)!important}.lg\:group-focus-within\:\[\&_\.react-flow__minimap\]\:\!left-auto:is(:where(.group):focus-within *) .react-flow minimap{left:auto!important}.lg\:group-focus-within\:\[\&_\.react-flow__minimap\]\:\!h-\[150px\]:is(:where(.group):focus-within *) .react-flow minimap{height:150px!important}.lg\:group-focus-within\:\[\&_\.react-flow__minimap\]\:\!w-\[210px\]:is(:where(.group):focus-within *) .react-flow minimap{width:210px!important}@media (hover:hover){.lg\:group-hover\:\[\&_\.react-flow__minimap\]\:\!top-auto:is(:where(.group):hover *) .react-flow minimap{top:auto!important}.lg\:group-hover\:\[\&_\.react-flow__minimap\]\:\!right-4:is(:where(.group):hover *) .react-flow minimap{right:calc(var(--spacing)*4)!important}.lg\:group-hover\:\[\&_\.react-flow__minimap\]\:\!bottom-4:is(:where(.group):hover *) .react-flow minimap{bottom:calc(var(--spacing)*4)!important}.lg\:group-hover\:\[\&_\.react-flow__minimap\]\:\!left-auto:is(:where(.group):hover *) .react-flow minimap{left:auto!important}.lg\:group-hover\:\[\&_\.react-flow__minimap\]\:\!h-\[150px\]:is(:where(.group):hover *) .react-flow minimap{height:150px!important}.lg\:group-hover\:\[\&_\.react-flow__minimap\]\:\!w-\[210px\]:is(:where(.group):hover *) .react-flow minimap{width:210px!important}}}.\[\&_\.react-flow__minimap_svg\]\:\!h-full .react-flow minimap svg{height:100%!important}.\[\&_\.react-flow__minimap_svg\]\:\!w-full .react-flow minimap svg{width:100%!important}@media (min-width:64rem){.lg\:group-focus-within\:\[\&_\.react-flow__minimap_svg\]\:\!h-\[150px\]:is(:where(.group):focus-within *) .react-flow minimap svg{height:150px!important}.lg\:group-focus-within\:\[\&_\.react-flow__minimap_svg\]\:\!w-\[210px\]:is(:where(.group):focus-within *) .react-flow minimap svg{width:210px!important}@media (hover:hover){.lg\:group-hover\:\[\&_\.react-flow__minimap_svg\]\:\!h-\[150px\]:is(:where(.group):hover *) .react-flow minimap svg{height:150px!important}.lg\:group-hover\:\[\&_\.react-flow__minimap_svg\]\:\!w-\[210px\]:is(:where(.group):hover *) .react-flow minimap svg{width:210px!important}}}.\[\&_\.react-flow__panel\]\:\!m-0 .react-flow panel{margin:calc(var(--spacing)*0)!important}.\[\&_\.react-flow__renderer\]\:pointer-events-none .react-flow renderer{pointer-events:none}.\[\&_\.react-flow__renderer\]\:opacity-0 .react-flow renderer{opacity:0}.\[\&_\.react-flow__renderer\]\:transition-opacity .react-flow renderer{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.\[\&_\.react-flow__renderer\]\:duration-200 .react-flow renderer{--tw-duration:.2s;transition-duration:.2s}@media (min-width:64rem){.lg\:group-focus-within\:\[\&_\.react-flow__renderer\]\:pointer-events-auto:is(:where(.group):focus-within *) .react-flow renderer{pointer-events:auto}.lg\:group-focus-within\:\[\&_\.react-flow__renderer\]\:opacity-100:is(:where(.group):focus-within *) .react-flow renderer{opacity:1}@media (hover:hover){.lg\:group-hover\:\[\&_\.react-flow__renderer\]\:pointer-events-auto:is(:where(.group):hover *) .react-flow renderer{pointer-events:auto}.lg\:group-hover\:\[\&_\.react-flow__renderer\]\:opacity-100:is(:where(.group):hover *) .react-flow renderer{opacity:1}}}.\[\&_\[data-tree-controls\]\]\:hidden [data-tree-controls]{display:none}@media (min-width:64rem){.lg\:group-focus-within\:\[\&_\[data-tree-controls\]\]\:\!flex:is(:where(.group):focus-within *) [data-tree-controls]{display:flex!important}@media (hover:hover){.lg\:group-hover\:\[\&_\[data-tree-controls\]\]\:\!flex:is(:where(.group):hover *) [data-tree-controls]{display:flex!important}}}}:root{--shoji-white:var(--paper);--washi-cream:var(--cream);--matcha-green:var(--copper);--bamboo-light:var(--copper-light);--stone-gray:var(--sand);--ink-black:var(--ink);--kintsugi-gold:var(--copper-light);--sakura-pink:var(--copper-light);--shadow-soft:#2c2c2c0f;--ink:#1a1816;--charcoal:#2d2926;--stone:#3d3835;--clay:#5c5550;--sand:#8a8279;--parchment:#c4bdb4;--cream:#f5f2ed;--paper:#faf9f7;--copper:#b87333;--copper-light:#d4956a;--copper-glow:#b8733326;--human:#6b5b4f;--machine:#4a6741;--system:#4f5b6b;--font-display:"Instrument Serif",Georgia,serif;--font-body:"DM Sans",-apple-system,sans-serif;--font-mono:"IBM Plex Mono",monospace;--font-zen-display:var(--font-display);--font-zen-body:var(--font-body)}:root[data-theme=dark]{--ink:#f5f2ed;--charcoal:#e6dfd6;--stone:#cfc6bb;--clay:#b2a79c;--sand:#9a8f83;--parchment:#3d342c;--cream:#2a2521;--paper:#1c1815;--copper:#d48a46;--copper-light:#e4a266;--copper-glow:#d48a4640;--human:#7a695d;--machine:#5a7452;--system:#5f6e81}html{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:15px}body{font-family:var(--font-body);background:var(--paper);color:var(--ink);height:100vh;transition:background-color .2s,color .2s;overflow:hidden}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{background:0 0}::-webkit-scrollbar-thumb{background:var(--parchment);border:2px solid var(--paper);border-radius:4px}::-webkit-scrollbar-thumb:hover{background:var(--sand)}*{scrollbar-width:thin;scrollbar-color:var(--parchment)transparent}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeInRight{0%{opacity:0;transform:translate(20px)}to{opacity:1;transform:translate(0)}}@keyframes slideInUp{0%{opacity:0;transform:translateY(15px)}to{opacity:1;transform:translateY(0)}}@keyframes messageIn{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}@keyframes typing{0%,60%,to{opacity:.4;transform:translateY(0)}30%{opacity:1;transform:translateY(-6px)}}.animate-message-in{animation:messageIn .4s}.animate-typing{animation:typing 1.4s infinite}.animate-typing-delay-1{animation-delay:.2s}.animate-typing-delay-2{animation-delay:.4s}.node-transition{transition:all .3s cubic-bezier(.34,1.56,.64,1)}.node-transition:hover{transform:scale(1.04)translateY(-2px)}.thread-indicator{background:var(--copper);border-radius:0 2px 2px 0;width:3px;height:0;transition:height .2s;position:absolute;top:50%;left:0;transform:translateY(-50%)}.thread-item-active .thread-indicator{height:24px}.tree-canvas-bg{background:radial-gradient(circle at 20% 30%,var(--copper-glow)0,transparent 50%),linear-gradient(180deg,var(--cream)0,var(--paper)100%)}.tree-canvas-grid:before{content:"";background-image:radial-gradient(circle at center,var(--parchment)1px,transparent 1px);opacity:.5;background-size:48px 48px;position:absolute;inset:0}.input-area-gradient{background:linear-gradient(180deg,transparent 0,var(--cream)100%)}.context-card-hover:hover{border-color:var(--copper);transform:translate(4px)}.context-card-hover:hover .context-card-remove{opacity:1}.drop-zone-active{border-color:var(--copper);background:var(--copper-glow)}.prose-prompt-tree code{font-family:var(--font-mono);background:var(--cream);color:var(--copper);border-radius:4px;padding:2px 6px;font-size:.85em}.prose-prompt-tree pre{background:var(--ink);color:var(--cream);font-family:var(--font-mono);border-radius:12px;margin:16px 0;padding:20px 24px;font-size:.8rem;line-height:1.6;overflow-x:auto}.prose-prompt-tree pre code{color:inherit;background:0 0;padding:0}.brand-dot:before{content:"";background:var(--copper);border-radius:50%;width:8px;height:8px;margin-bottom:2px;display:inline-block}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"<length-percentage>";inherits:false;initial-value:0}@property --tw-gradient-via-position{syntax:"<length-percentage>";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"<length-percentage>";inherits:false;initial-value:100%}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes spin{to{transform:rotate(1turn)}}@keyframes pulse{50%{opacity:.5}}
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Prompt Tree - AI Dialogue Topology Client
|
|
2
2
|
|
|
3
3
|
<p align="center">
|
|
4
4
|
<img src="https://img.shields.io/badge/Next.js-16-black?style=flat-square&logo=next.js" alt="Next.js 16" />
|
|
@@ -14,47 +14,53 @@
|
|
|
14
14
|
- 🌳 **树状对话管理** - 可视化对话分支,随时回溯和分叉
|
|
15
15
|
- 📦 **上下文组装台** - 自由拖拽节点组装上下文,精确控制Token使用
|
|
16
16
|
- 🗜️ **智能压缩** - AI辅助压缩历史对话,提取元指令
|
|
17
|
-
- 🎨 **优雅设计** -
|
|
17
|
+
- 🎨 **优雅设计** - Prompt Tree 设计系统,温暖的编辑风格美学
|
|
18
18
|
|
|
19
19
|
## 🚀 快速开始
|
|
20
20
|
|
|
21
21
|
### 环境要求
|
|
22
22
|
|
|
23
23
|
- Node.js 18+
|
|
24
|
-
- npm
|
|
24
|
+
- npm(或 pnpm)
|
|
25
25
|
|
|
26
|
-
###
|
|
26
|
+
### npm(用户方式:一条命令安装 / 一条命令启动)
|
|
27
27
|
|
|
28
28
|
```bash
|
|
29
|
-
#
|
|
30
|
-
|
|
31
|
-
cd ai-chat-client
|
|
32
|
-
|
|
33
|
-
# 安装依赖
|
|
34
|
-
npm install
|
|
29
|
+
# 安装(全局安装后才能直接在终端输入 `tree`)
|
|
30
|
+
npm i -g @yxp934/prompt-tree
|
|
35
31
|
|
|
36
|
-
#
|
|
37
|
-
|
|
32
|
+
# 启动(默认端口 1666)
|
|
33
|
+
tree
|
|
38
34
|
```
|
|
39
35
|
|
|
40
36
|
访问 http://localhost:1666 查看应用。
|
|
41
37
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
> 注意:命令名设置为 `tree` 可能会与系统自带/已安装的 `tree` 命令冲突;如果你希望避免冲突,建议改成更独特的名字(例如 `cortex-tree`)。
|
|
38
|
+
可选:修改端口
|
|
45
39
|
|
|
46
40
|
```bash
|
|
47
|
-
|
|
48
|
-
|
|
41
|
+
tree --port 7777
|
|
42
|
+
```
|
|
49
43
|
|
|
50
|
-
|
|
51
|
-
|
|
44
|
+
可选:不做全局安装(一次性运行)
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
npx -y --package @yxp934/prompt-tree tree
|
|
52
48
|
```
|
|
53
49
|
|
|
54
|
-
|
|
50
|
+
> 注意:命令名设置为 `tree` 可能会与系统自带/已安装的 `tree` 命令冲突;如果你希望避免冲突,建议改成更独特的名字(例如 `prompt-tree`)。
|
|
51
|
+
|
|
52
|
+
### 开发者本地运行(从仓库启动)
|
|
55
53
|
|
|
56
54
|
```bash
|
|
57
|
-
|
|
55
|
+
# 克隆项目
|
|
56
|
+
git clone <repository-url>
|
|
57
|
+
cd ai-chat-client
|
|
58
|
+
|
|
59
|
+
# 安装依赖
|
|
60
|
+
npm install
|
|
61
|
+
|
|
62
|
+
# 启动开发服务器
|
|
63
|
+
npm run dev
|
|
58
64
|
```
|
|
59
65
|
|
|
60
66
|
### Docker(推荐:一条命令安装 / 一条命令启动)
|
|
@@ -63,17 +69,17 @@ tree --port 7777
|
|
|
63
69
|
|
|
64
70
|
```bash
|
|
65
71
|
# 安装(拉取镜像)
|
|
66
|
-
docker pull ghcr.io/<OWNER>/
|
|
72
|
+
docker pull ghcr.io/<OWNER>/prompt-tree:latest
|
|
67
73
|
|
|
68
74
|
# 启动
|
|
69
|
-
docker run --rm -p 1666:1666 ghcr.io/<OWNER>/
|
|
75
|
+
docker run --rm -p 1666:1666 ghcr.io/<OWNER>/prompt-tree:latest
|
|
70
76
|
```
|
|
71
77
|
|
|
72
78
|
还未发布镜像时,也可以在本地构建并启动(在 `ai-chat-client/` 下执行):
|
|
73
79
|
|
|
74
80
|
```bash
|
|
75
|
-
docker build -t
|
|
76
|
-
docker run --rm -p 1666:1666
|
|
81
|
+
docker build -t prompt-tree .
|
|
82
|
+
docker run --rm -p 1666:1666 prompt-tree
|
|
77
83
|
```
|
|
78
84
|
|
|
79
85
|
## 📁 项目结构
|
|
@@ -120,7 +126,7 @@ ai-chat-client/
|
|
|
120
126
|
- **Inter** - 正文内容(现代无衬线)
|
|
121
127
|
- **IBM Plex Mono** - 代码和数据(等宽)
|
|
122
128
|
|
|
123
|
-
###
|
|
129
|
+
### Prompt Tree (原)
|
|
124
130
|
|
|
125
131
|
温暖的编辑风格美学。
|
|
126
132
|
|