@axiom-lattice/react-sdk 10.0.1 → 10.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AgentDetailSideApp-RJDUVH6V.mjs → AgentDetailSideApp-TBRWTSRK.mjs} +11 -11
- package/dist/AgentGovernanceWorkbench-AHFQR42S.mjs +24 -0
- package/dist/{LangfuseDashboard-LK6FMAUK.mjs → LangfuseDashboard-IQVQ65ZY.mjs} +2 -2
- package/dist/{MessageGraph-KTEIZSCZ.mjs → MessageGraph-SOU3QSYM.mjs} +7 -7
- package/dist/{ReactChart-HZBWORWI.mjs → ReactChart-33DCEDLY.mjs} +7 -7
- package/dist/SkillFlow-KWMQYLOM.mjs +14 -0
- package/dist/{TasksSideApp-SBPJZOKE.mjs → TasksSideApp-66BUD5LP.mjs} +8 -8
- package/dist/ThreadMaintenancePanel-ISI24BAC.mjs +12 -0
- package/dist/{TopologyRuntimeView-IONHOJFM.mjs → TopologyRuntimeView-ANIQQMP5.mjs} +8 -8
- package/dist/WorkflowAutomationView-I6CODQ2V.mjs +22 -0
- package/dist/{chunk-WQEPGDQ7.mjs → chunk-3L3D2DOF.mjs} +221 -85
- package/dist/chunk-3L3D2DOF.mjs.map +1 -0
- package/dist/{chunk-ZHGPRA23.mjs → chunk-75Q63EWC.mjs} +3 -3
- package/dist/{chunk-FFMVKPES.mjs → chunk-7RJ6O6NC.mjs} +7 -7
- package/dist/{chunk-VUYGRLOR.mjs → chunk-B3YV6ACN.mjs} +4 -4
- package/dist/{chunk-X5U6JFUH.mjs → chunk-K3N4JG7L.mjs} +3 -3
- package/dist/{chunk-SWNS75PP.mjs → chunk-MALQGEZT.mjs} +4 -4
- package/dist/{chunk-Z4X6WD6O.mjs → chunk-OAZGMAMX.mjs} +10 -10
- package/dist/{chunk-ZSCS4Z7B.mjs → chunk-OOMJJ4W3.mjs} +3 -3
- package/dist/{chunk-VO6IQKQE.mjs → chunk-PN5AX2AV.mjs} +4 -4
- package/dist/{chunk-4JSHDMRW.mjs → chunk-RJQSM4Z6.mjs} +2 -2
- package/dist/{chunk-ET6QYRK3.mjs → chunk-RXELOKHZ.mjs} +8 -8
- package/dist/{chunk-ARD4OJRP.mjs → chunk-RZIYUI3J.mjs} +3 -3
- package/dist/{chunk-6GMM7FIQ.mjs → chunk-S44KQ2OB.mjs} +3 -3
- package/dist/{chunk-2R3WX6FB.mjs → chunk-XWELHNBD.mjs} +3 -3
- package/dist/{embed-page-AgentDetailSideApp-L37KFUAY.js → embed-page-AgentDetailSideApp-RTJXIZJ6.js} +1 -1
- package/dist/{embed-page-AgentGovernanceWorkbench-LDNC3EUU.js → embed-page-AgentGovernanceWorkbench-IVML6LV6.js} +1 -1
- package/dist/{embed-page-LangfuseDashboard-CZUVA4MI.js → embed-page-LangfuseDashboard-NJSQW3LX.js} +1 -1
- package/dist/{embed-page-MessageGraph-KSPQ5GHB.js → embed-page-MessageGraph-CATE2Z5W.js} +1 -1
- package/dist/{embed-page-ReactChart-MH7DGSYJ.js → embed-page-ReactChart-6H2GVFRY.js} +1 -1
- package/dist/{embed-page-SkillFlow-TFHDI63I.js → embed-page-SkillFlow-Z5GOUWPH.js} +1 -1
- package/dist/{embed-page-TasksSideApp-ZOQ34RII.js → embed-page-TasksSideApp-S6ZAHIYP.js} +1 -1
- package/dist/{embed-page-ThreadMaintenancePanel-PTUGZRLJ.js → embed-page-ThreadMaintenancePanel-NRNZHEND.js} +1 -1
- package/dist/{embed-page-TopologyRuntimeView-EHN2VA2Z.js → embed-page-TopologyRuntimeView-5UWD6CMT.js} +1 -1
- package/dist/{embed-page-WorkflowAutomationView-IUGJ54RV.js → embed-page-WorkflowAutomationView-2EWPK4ZK.js} +1 -1
- package/dist/{embed-page-chunk-K74FZI4X.js → embed-page-chunk-4D5PY2CF.js} +1 -1
- package/dist/{embed-page-chunk-3E5B2KJT.js → embed-page-chunk-7XPK5RLA.js} +1 -1
- package/dist/{embed-page-chunk-UJCEOILF.js → embed-page-chunk-HKFKNIOM.js} +1 -1
- package/dist/embed-page-chunk-JPRKPIYC.js +6947 -0
- package/dist/{embed-page-chunk-VEBSRO4A.js → embed-page-chunk-PSWN2QFI.js} +1 -1
- package/dist/{embed-page-chunk-5DSJCBZF.js → embed-page-chunk-PY2HBRFF.js} +1 -1
- package/dist/{embed-page-chunk-3PGODDQW.js → embed-page-chunk-RFN7O6VH.js} +1 -1
- package/dist/{embed-page-chunk-XVDCWRYF.js → embed-page-chunk-VQMQROAS.js} +1 -1
- package/dist/{embed-page-chunk-5GAHI45T.js → embed-page-chunk-WR44MKDA.js} +1 -1
- package/dist/{embed-page-chunk-FU755EE4.js → embed-page-chunk-YCEMHL2H.js} +1 -1
- package/dist/{embed-page-en-XKIIMNZ7.js → embed-page-en-TQ2XQQ5G.js} +1 -1
- package/dist/{embed-page-zh-F4WCA6SW.js → embed-page-zh-HRXFYKH4.js} +1 -1
- package/dist/embed-page.js +1 -1
- package/dist/{en-BN5NSY7L.mjs → en-NQWIZVRF.mjs} +5 -2
- package/dist/{en-BN5NSY7L.mjs.map → en-NQWIZVRF.mjs.map} +1 -1
- package/dist/index.d.mts +16 -1
- package/dist/index.d.ts +16 -1
- package/dist/index.js +1894 -1752
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +14 -14
- package/dist/web-app.js +8 -2
- package/dist/web-app.js.map +1 -1
- package/dist/web-app.mjs +2 -2
- package/dist/{zh-MRVMQMO7.mjs → zh-33HUODZ6.mjs} +5 -2
- package/dist/{zh-MRVMQMO7.mjs.map → zh-33HUODZ6.mjs.map} +1 -1
- package/package.json +3 -3
- package/dist/AgentGovernanceWorkbench-SM54EUAP.mjs +0 -24
- package/dist/SkillFlow-R6WFP542.mjs +0 -14
- package/dist/ThreadMaintenancePanel-P27YA2AI.mjs +0 -12
- package/dist/WorkflowAutomationView-EMCAY3OI.mjs +0 -22
- package/dist/chunk-WQEPGDQ7.mjs.map +0 -1
- package/dist/embed-page-chunk-4N7B6POU.js +0 -6947
- /package/dist/{AgentDetailSideApp-RJDUVH6V.mjs.map → AgentDetailSideApp-TBRWTSRK.mjs.map} +0 -0
- /package/dist/{AgentGovernanceWorkbench-SM54EUAP.mjs.map → AgentGovernanceWorkbench-AHFQR42S.mjs.map} +0 -0
- /package/dist/{LangfuseDashboard-LK6FMAUK.mjs.map → LangfuseDashboard-IQVQ65ZY.mjs.map} +0 -0
- /package/dist/{MessageGraph-KTEIZSCZ.mjs.map → MessageGraph-SOU3QSYM.mjs.map} +0 -0
- /package/dist/{ReactChart-HZBWORWI.mjs.map → ReactChart-33DCEDLY.mjs.map} +0 -0
- /package/dist/{SkillFlow-R6WFP542.mjs.map → SkillFlow-KWMQYLOM.mjs.map} +0 -0
- /package/dist/{TasksSideApp-SBPJZOKE.mjs.map → TasksSideApp-66BUD5LP.mjs.map} +0 -0
- /package/dist/{ThreadMaintenancePanel-P27YA2AI.mjs.map → ThreadMaintenancePanel-ISI24BAC.mjs.map} +0 -0
- /package/dist/{TopologyRuntimeView-IONHOJFM.mjs.map → TopologyRuntimeView-ANIQQMP5.mjs.map} +0 -0
- /package/dist/{WorkflowAutomationView-EMCAY3OI.mjs.map → WorkflowAutomationView-I6CODQ2V.mjs.map} +0 -0
- /package/dist/{chunk-ZHGPRA23.mjs.map → chunk-75Q63EWC.mjs.map} +0 -0
- /package/dist/{chunk-FFMVKPES.mjs.map → chunk-7RJ6O6NC.mjs.map} +0 -0
- /package/dist/{chunk-VUYGRLOR.mjs.map → chunk-B3YV6ACN.mjs.map} +0 -0
- /package/dist/{chunk-X5U6JFUH.mjs.map → chunk-K3N4JG7L.mjs.map} +0 -0
- /package/dist/{chunk-SWNS75PP.mjs.map → chunk-MALQGEZT.mjs.map} +0 -0
- /package/dist/{chunk-Z4X6WD6O.mjs.map → chunk-OAZGMAMX.mjs.map} +0 -0
- /package/dist/{chunk-ZSCS4Z7B.mjs.map → chunk-OOMJJ4W3.mjs.map} +0 -0
- /package/dist/{chunk-VO6IQKQE.mjs.map → chunk-PN5AX2AV.mjs.map} +0 -0
- /package/dist/{chunk-4JSHDMRW.mjs.map → chunk-RJQSM4Z6.mjs.map} +0 -0
- /package/dist/{chunk-ET6QYRK3.mjs.map → chunk-RXELOKHZ.mjs.map} +0 -0
- /package/dist/{chunk-ARD4OJRP.mjs.map → chunk-RZIYUI3J.mjs.map} +0 -0
- /package/dist/{chunk-6GMM7FIQ.mjs.map → chunk-S44KQ2OB.mjs.map} +0 -0
- /package/dist/{chunk-2R3WX6FB.mjs.map → chunk-XWELHNBD.mjs.map} +0 -0
package/dist/{embed-page-LangfuseDashboard-CZUVA4MI.js → embed-page-LangfuseDashboard-NJSQW3LX.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as X}from"./embed-page-chunk-D7YTSCUO.js";import{K as q,Na as Q,P as J,Wa as de,a as j}from"./embed-page-chunk-F7ZUYG42.js";import{k as G,l as H}from"./embed-page-chunk-5GAHI45T.js";import{a as Y}from"./embed-page-chunk-QV7QAJ4N.js";import{Ra as p,W as T,_a as w,bb as R,qa as F,ta as c}from"./embed-page-chunk-F7TA3LRH.js";import"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-EUOOO2LS.js";import{f as I}from"./embed-page-chunk-QBTAJ2YI.js";var re=I(de());var t=I(Y()),O=["#6366f1","#8b5cf6","#10b981","#f59e0b","#ef4444","#0ea5e9","#ec4899","#14b8a6"],Z="#6366f1",ee="#10b981",te="#8b5cf6",oe="#ef4444",be="#f59e0b",ue="#0ea5e9";function v(o){return o!==null&&typeof o=="object"&&!Array.isArray(o)}function d(o){return Array.isArray(o)&&o.every(e=>v(e)&&typeof e.bucket=="string"&&(e.value===null||typeof e.value=="number"))}function pe(o){if(!v(o)||!v(o.kpis)||!v(o.series))return!1;let e=o.series,n=e.tokens,r=e.latency;return typeof o.samplingRate=="number"&&typeof o.kpis.traces=="number"&&typeof o.kpis.costUsd=="number"&&typeof o.kpis.inputTokens=="number"&&typeof o.kpis.outputTokens=="number"&&typeof o.kpis.errorRate=="number"&&d(e.traces)&&d(e.cost)&&d(e.errorRate)&&d(e.toolCalls)&&v(n)&&d(n.input)&&d(n.output)&&v(r)&&d(r.p50)&&d(r.p95)&&d(r.p99)&&Array.isArray(o.agents)&&Array.isArray(o.models)&&Array.isArray(o.tools)}function ne(o,e){let n=(0,re.default)(o);return e==="7d"||e==="30d"?n.format("MM-DD"):n.format("MM-DD HH:mm")}function k(o,e){return o.map(n=>ne(n.bucket,e))}function b(o){return o.map(e=>e.value??0)}function u(o){return o.some(e=>(e.value??0)!==0)}var ye=new Intl.NumberFormat(void 0,{notation:"compact",maximumFractionDigits:1});function D(o){return ye.format(o)}function P(o){return Number.isFinite(o)?o.toLocaleString():"0"}function ae(o){return`$${(Number.isFinite(o)?o:0).toFixed(4)}`}function ie(o,e){let n=Number(o);if(!Number.isFinite(n))return"\u2014";switch(e){case"currency":return ae(n);case"tokens":return D(n);case"percent":return`${(n*100).toFixed(1)}%`;case"ms":return`${Math.round(n)} ms`;default:return P(n)}}function se(o){return{backgroundColor:o.background,borderColor:o.border,borderWidth:1,textStyle:{color:o.text,fontSize:12},extraCssText:"box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12); border-radius: 12px;"}}function he(o,e){return{color:o.textSecondary,fontSize:11,...e?{formatter:e}:{}}}function V(o,e,n=!1){return{type:"category",data:e,axisLine:{show:!1},axisTick:{show:!1},axisLabel:{color:o.textSecondary,fontSize:11,hideOverlap:!0,...n?{formatter:r=>r.length>18?`${r.slice(0,17)}\u2026`:r}:{}},splitLine:{show:!1}}}function $(o,e,n){return{type:"value",...e?{max:1}:{},axisLine:{show:!1},axisTick:{show:!1},axisLabel:he(o,e?r=>`${Math.round(r*100)}%`:void 0),splitLine:{lineStyle:{color:o.border,type:"dashed"}},...n==="number"?{}:{}}}function C(o,e,n){let r=n.kind??(n.percent?"percent":"number");return{color:O,tooltip:{trigger:"axis",...se(n.theme),valueFormatter:i=>ie(i,r)},legend:{top:0,right:0,icon:"circle",itemWidth:8,itemHeight:8,textStyle:{color:n.theme.textSecondary,fontSize:11}},grid:{left:8,right:16,top:36,bottom:8,containLabel:!0},xAxis:V(n.theme,o),yAxis:$(n.theme,n.percent===!0,r),series:e.map((i,s)=>({name:i.name,type:"line",smooth:.35,symbol:"none",lineStyle:{width:2},...n.stacked?{stack:"total"}:{},...n.area?{areaStyle:{opacity:n.stacked?.18:.12,color:O[s%O.length]}}:{},data:i.data}))}}function y(o,e,n){let r=n.kind??(n.percent?"percent":"number"),i=n.horizontal===!0;return{color:O,tooltip:{trigger:"axis",...se(n.theme),valueFormatter:s=>ie(s,r)},legend:{top:0,right:0,icon:"circle",itemWidth:8,itemHeight:8,textStyle:{color:n.theme.textSecondary,fontSize:11}},grid:i?{left:8,right:24,top:16,bottom:8,containLabel:!0}:{left:8,right:16,top:36,bottom:8,containLabel:!0},xAxis:i?$(n.theme,n.percent===!0,r):V(n.theme,o),yAxis:i?V(n.theme,o,!0):$(n.theme,n.percent===!0,r),series:e.map(s=>({name:s.name,type:"bar",...n.stacked?{stack:"total"}:{},barMaxWidth:i?18:28,itemStyle:{borderRadius:i?[0,6,6,0]:[6,6,0,0]},emphasis:{focus:"series"},data:s.data}))}}var A=({title:o,value:e,hint:n,accent:r,icon:i})=>{let{token:s}=w.useToken();return(0,t.jsx)(F,{size:"small",style:{borderRadius:16,border:`1px solid ${s.colorBorderSecondary}`,background:s.colorBgContainer,boxShadow:s.boxShadowTertiary,height:"100%"},styles:{body:{padding:16}},children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:12},children:[(0,t.jsx)("div",{style:{width:40,height:40,flexShrink:0,borderRadius:12,display:"grid",placeItems:"center",background:`${r}1a`,color:r},children:i}),(0,t.jsxs)("div",{style:{minWidth:0},children:[(0,t.jsx)("div",{style:{fontSize:11,fontWeight:600,letterSpacing:.6,textTransform:"uppercase",color:s.colorTextSecondary,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:o}),(0,t.jsx)("div",{style:{fontSize:24,fontWeight:700,lineHeight:1.2,color:s.colorText,fontVariantNumeric:"tabular-nums"},children:e}),(0,t.jsx)("div",{style:{fontSize:11,color:s.colorTextTertiary,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:n})]})]})})},f=({title:o,accent:e})=>(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginTop:4},children:[(0,t.jsx)("span",{style:{width:4,height:16,borderRadius:2,background:e}}),(0,t.jsx)(R.Text,{strong:!0,style:{fontSize:14},children:o})]}),m=({title:o,option:e,hasData:n})=>{let{token:r}=w.useToken(),i=H();return(0,t.jsx)(F,{size:"small",title:(0,t.jsx)("span",{style:{fontSize:12,fontWeight:600,color:r.colorTextSecondary},children:o}),style:{borderRadius:16,border:`1px solid ${r.colorBorderSecondary}`,background:r.colorBgContainer,boxShadow:r.boxShadowTertiary,height:"100%"},styles:{header:{borderBottom:"none",padding:"12px 16px 0",minHeight:0},body:{padding:"4px 8px 10px"}},children:n?(0,t.jsx)(X,{option:e,height:200}):(0,t.jsx)("div",{style:{height:200,display:"grid",placeItems:"center"},children:(0,t.jsx)(R.Text,{type:"secondary",style:{fontSize:12},children:i("common.observability.empty")})})})},Te=({data:o})=>{let e=H(),{token:n}=w.useToken();if(o.version!==G)return(0,t.jsx)(T,{type:"warning",showIcon:!0,message:e("common.observability.unsupportedVersion")});if(!pe(o.payload))return(0,t.jsx)(T,{type:"warning",showIcon:!0,message:e("common.observability.unsupportedVersion")});let r=o.payload,i=o.range,s=r.series.traces,L=r.series.cost,_=r.series.costByModel??[],x=r.series.tokens,h=r.series.latency,E=r.series.errorRate,z=r.series.toolCalls,l={text:n.colorText,textSecondary:n.colorTextTertiary,border:n.colorBorderSecondary,background:n.colorBgElevated},W=r.agents.map(a=>a.name&&a.name.trim()?a.name:a.assistantId==="unattributed"?e("common.observability.unknownAgent"):a.assistantId?a.assistantId.slice(0,8):e("common.observability.unknownAgent")),B=r.models.map(a=>a.model),ce=r.tools.slice(0,10).map(a=>a.tool),K=new Set;for(let a of _)for(let g of a.points)K.add(g.bucket);let U=[...K].sort(),le=U.map(a=>ne(a,i)),M=_.map(a=>{let g=new Map(a.points.map(S=>[S.bucket,S.value??0]));return{name:a.model,data:U.map(S=>g.get(S)??0)}}),N=M.length>0,me=r.agents.reduce((a,g)=>a+g.errorCount,0);return(0,t.jsxs)("div",{style:{display:"grid",gap:20},children:[(0,t.jsx)(R.Text,{type:"secondary",style:{fontSize:12},children:e("common.observability.scopeNote",{environment:r.environment??e("common.observability.allEnvironments"),range:i})}),o.warnings&&o.warnings.length>0?(0,t.jsx)(T,{type:"warning",showIcon:!0,message:e("common.observability.partial")}):null,r.samplingRate<1?(0,t.jsx)(T,{type:"info",showIcon:!0,message:e("common.observability.sampling",{rate:Math.round(r.samplingRate*100)})}):null,(0,t.jsxs)(p,{gutter:[12,12],children:[(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.traces"),value:P(r.kpis.traces),hint:e("common.observability.kpi.tracesHint"),accent:Z,icon:(0,t.jsx)(j,{size:18})})}),(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.cost"),value:ae(r.kpis.costUsd),hint:"USD",accent:ee,icon:(0,t.jsx)(J,{size:18})})}),(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.tokens"),value:D(r.kpis.inputTokens+r.kpis.outputTokens),hint:e("common.observability.kpi.tokensHint",{input:D(r.kpis.inputTokens),output:D(r.kpis.outputTokens)}),accent:te,icon:(0,t.jsx)(q,{size:18})})}),(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.errorRate"),value:`${(r.kpis.errorRate*100).toFixed(2)}%`,hint:e("common.observability.kpi.errorsHint",{count:P(me)}),accent:oe,icon:(0,t.jsx)(Q,{size:18})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.traces"),accent:Z}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tracesByAssistant"),hasData:r.agents.length>0,option:y(W,[{name:e("common.observability.table.calls"),data:r.agents.map(a=>a.calls)}],{theme:l,horizontal:!0,kind:"number"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tracesOverTime"),hasData:u(s),option:y(k(s,i),[{name:e("common.observability.kpi.traces"),data:b(s)}],{theme:l,kind:"number"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.cost"),accent:ee}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.costByModel"),hasData:r.models.length>0,option:y(B,[{name:e("common.observability.kpi.cost"),data:r.models.map(a=>a.costUsd)}],{theme:l,kind:"currency"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e(N?"common.observability.chart.costByModelOverTime":"common.observability.chart.costOverTime"),hasData:N?M.some(a=>a.data.some(g=>g!==0)):u(L),option:N?C(le,M,{theme:l,stacked:!0,area:!0,kind:"currency"}):C(k(L,i),[{name:e("common.observability.kpi.cost"),data:b(L)}],{theme:l,area:!0,kind:"currency"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.tokens"),accent:te}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tokensByModel"),hasData:r.models.length>0,option:y(B,[{name:e("common.observability.table.inputTokens"),data:r.models.map(a=>a.inputTokens)},{name:e("common.observability.table.outputTokens"),data:r.models.map(a=>a.outputTokens)}],{theme:l,stacked:!0,kind:"tokens"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tokensOverTime"),hasData:u(x.input)||u(x.output),option:C(k(x.input,i),[{name:"input",data:b(x.input)},{name:"output",data:b(x.output)}],{theme:l,area:!0,stacked:!0,kind:"tokens"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.errors"),accent:oe}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.errorRateByAssistant"),hasData:r.agents.length>0,option:y(W,[{name:e("common.observability.kpi.errorRate"),data:r.agents.map(a=>a.errorRate)}],{theme:l,horizontal:!0,percent:!0})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.errorRateOverTime"),hasData:u(E),option:C(k(E,i),[{name:e("common.observability.kpi.errorRate"),data:b(E)}],{theme:l,percent:!0,area:!0})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.latency"),accent:be}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.p95ByModel"),hasData:r.models.length>0,option:y(B,[{name:e("common.observability.kpi.p95"),data:r.models.map(a=>a.p95LatencyMs??0)}],{theme:l,horizontal:!0,kind:"ms"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.latencyOverTime"),hasData:u(h.p50)||u(h.p95)||u(h.p99),option:C(k(h.p95,i),[{name:"p50",data:b(h.p50)},{name:"p95",data:b(h.p95)},{name:"p99",data:b(h.p99)}],{theme:l,kind:"ms"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.tools"),accent:ue}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.toolsByTool"),hasData:r.tools.length>0,option:y(ce,[{name:e("common.observability.table.calls"),data:r.tools.slice(0,10).map(a=>a.count)}],{theme:l,horizontal:!0,kind:"number"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.toolsOverTime"),hasData:u(z),option:y(k(z,i),[{name:e("common.observability.table.calls"),data:b(z)}],{theme:l,kind:"number"})})})]})]})};export{Te as LangfuseDashboard};
|
|
1
|
+
import{a as X}from"./embed-page-chunk-D7YTSCUO.js";import{K as q,Na as Q,P as J,Wa as de,a as j}from"./embed-page-chunk-F7ZUYG42.js";import{k as G,l as H}from"./embed-page-chunk-WR44MKDA.js";import{a as Y}from"./embed-page-chunk-QV7QAJ4N.js";import{Ra as p,W as T,_a as w,bb as R,qa as F,ta as c}from"./embed-page-chunk-F7TA3LRH.js";import"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-EUOOO2LS.js";import{f as I}from"./embed-page-chunk-QBTAJ2YI.js";var re=I(de());var t=I(Y()),O=["#6366f1","#8b5cf6","#10b981","#f59e0b","#ef4444","#0ea5e9","#ec4899","#14b8a6"],Z="#6366f1",ee="#10b981",te="#8b5cf6",oe="#ef4444",be="#f59e0b",ue="#0ea5e9";function v(o){return o!==null&&typeof o=="object"&&!Array.isArray(o)}function d(o){return Array.isArray(o)&&o.every(e=>v(e)&&typeof e.bucket=="string"&&(e.value===null||typeof e.value=="number"))}function pe(o){if(!v(o)||!v(o.kpis)||!v(o.series))return!1;let e=o.series,n=e.tokens,r=e.latency;return typeof o.samplingRate=="number"&&typeof o.kpis.traces=="number"&&typeof o.kpis.costUsd=="number"&&typeof o.kpis.inputTokens=="number"&&typeof o.kpis.outputTokens=="number"&&typeof o.kpis.errorRate=="number"&&d(e.traces)&&d(e.cost)&&d(e.errorRate)&&d(e.toolCalls)&&v(n)&&d(n.input)&&d(n.output)&&v(r)&&d(r.p50)&&d(r.p95)&&d(r.p99)&&Array.isArray(o.agents)&&Array.isArray(o.models)&&Array.isArray(o.tools)}function ne(o,e){let n=(0,re.default)(o);return e==="7d"||e==="30d"?n.format("MM-DD"):n.format("MM-DD HH:mm")}function k(o,e){return o.map(n=>ne(n.bucket,e))}function b(o){return o.map(e=>e.value??0)}function u(o){return o.some(e=>(e.value??0)!==0)}var ye=new Intl.NumberFormat(void 0,{notation:"compact",maximumFractionDigits:1});function D(o){return ye.format(o)}function P(o){return Number.isFinite(o)?o.toLocaleString():"0"}function ae(o){return`$${(Number.isFinite(o)?o:0).toFixed(4)}`}function ie(o,e){let n=Number(o);if(!Number.isFinite(n))return"\u2014";switch(e){case"currency":return ae(n);case"tokens":return D(n);case"percent":return`${(n*100).toFixed(1)}%`;case"ms":return`${Math.round(n)} ms`;default:return P(n)}}function se(o){return{backgroundColor:o.background,borderColor:o.border,borderWidth:1,textStyle:{color:o.text,fontSize:12},extraCssText:"box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12); border-radius: 12px;"}}function he(o,e){return{color:o.textSecondary,fontSize:11,...e?{formatter:e}:{}}}function V(o,e,n=!1){return{type:"category",data:e,axisLine:{show:!1},axisTick:{show:!1},axisLabel:{color:o.textSecondary,fontSize:11,hideOverlap:!0,...n?{formatter:r=>r.length>18?`${r.slice(0,17)}\u2026`:r}:{}},splitLine:{show:!1}}}function $(o,e,n){return{type:"value",...e?{max:1}:{},axisLine:{show:!1},axisTick:{show:!1},axisLabel:he(o,e?r=>`${Math.round(r*100)}%`:void 0),splitLine:{lineStyle:{color:o.border,type:"dashed"}},...n==="number"?{}:{}}}function C(o,e,n){let r=n.kind??(n.percent?"percent":"number");return{color:O,tooltip:{trigger:"axis",...se(n.theme),valueFormatter:i=>ie(i,r)},legend:{top:0,right:0,icon:"circle",itemWidth:8,itemHeight:8,textStyle:{color:n.theme.textSecondary,fontSize:11}},grid:{left:8,right:16,top:36,bottom:8,containLabel:!0},xAxis:V(n.theme,o),yAxis:$(n.theme,n.percent===!0,r),series:e.map((i,s)=>({name:i.name,type:"line",smooth:.35,symbol:"none",lineStyle:{width:2},...n.stacked?{stack:"total"}:{},...n.area?{areaStyle:{opacity:n.stacked?.18:.12,color:O[s%O.length]}}:{},data:i.data}))}}function y(o,e,n){let r=n.kind??(n.percent?"percent":"number"),i=n.horizontal===!0;return{color:O,tooltip:{trigger:"axis",...se(n.theme),valueFormatter:s=>ie(s,r)},legend:{top:0,right:0,icon:"circle",itemWidth:8,itemHeight:8,textStyle:{color:n.theme.textSecondary,fontSize:11}},grid:i?{left:8,right:24,top:16,bottom:8,containLabel:!0}:{left:8,right:16,top:36,bottom:8,containLabel:!0},xAxis:i?$(n.theme,n.percent===!0,r):V(n.theme,o),yAxis:i?V(n.theme,o,!0):$(n.theme,n.percent===!0,r),series:e.map(s=>({name:s.name,type:"bar",...n.stacked?{stack:"total"}:{},barMaxWidth:i?18:28,itemStyle:{borderRadius:i?[0,6,6,0]:[6,6,0,0]},emphasis:{focus:"series"},data:s.data}))}}var A=({title:o,value:e,hint:n,accent:r,icon:i})=>{let{token:s}=w.useToken();return(0,t.jsx)(F,{size:"small",style:{borderRadius:16,border:`1px solid ${s.colorBorderSecondary}`,background:s.colorBgContainer,boxShadow:s.boxShadowTertiary,height:"100%"},styles:{body:{padding:16}},children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:12},children:[(0,t.jsx)("div",{style:{width:40,height:40,flexShrink:0,borderRadius:12,display:"grid",placeItems:"center",background:`${r}1a`,color:r},children:i}),(0,t.jsxs)("div",{style:{minWidth:0},children:[(0,t.jsx)("div",{style:{fontSize:11,fontWeight:600,letterSpacing:.6,textTransform:"uppercase",color:s.colorTextSecondary,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:o}),(0,t.jsx)("div",{style:{fontSize:24,fontWeight:700,lineHeight:1.2,color:s.colorText,fontVariantNumeric:"tabular-nums"},children:e}),(0,t.jsx)("div",{style:{fontSize:11,color:s.colorTextTertiary,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:n})]})]})})},f=({title:o,accent:e})=>(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginTop:4},children:[(0,t.jsx)("span",{style:{width:4,height:16,borderRadius:2,background:e}}),(0,t.jsx)(R.Text,{strong:!0,style:{fontSize:14},children:o})]}),m=({title:o,option:e,hasData:n})=>{let{token:r}=w.useToken(),i=H();return(0,t.jsx)(F,{size:"small",title:(0,t.jsx)("span",{style:{fontSize:12,fontWeight:600,color:r.colorTextSecondary},children:o}),style:{borderRadius:16,border:`1px solid ${r.colorBorderSecondary}`,background:r.colorBgContainer,boxShadow:r.boxShadowTertiary,height:"100%"},styles:{header:{borderBottom:"none",padding:"12px 16px 0",minHeight:0},body:{padding:"4px 8px 10px"}},children:n?(0,t.jsx)(X,{option:e,height:200}):(0,t.jsx)("div",{style:{height:200,display:"grid",placeItems:"center"},children:(0,t.jsx)(R.Text,{type:"secondary",style:{fontSize:12},children:i("common.observability.empty")})})})},Te=({data:o})=>{let e=H(),{token:n}=w.useToken();if(o.version!==G)return(0,t.jsx)(T,{type:"warning",showIcon:!0,message:e("common.observability.unsupportedVersion")});if(!pe(o.payload))return(0,t.jsx)(T,{type:"warning",showIcon:!0,message:e("common.observability.unsupportedVersion")});let r=o.payload,i=o.range,s=r.series.traces,L=r.series.cost,_=r.series.costByModel??[],x=r.series.tokens,h=r.series.latency,E=r.series.errorRate,z=r.series.toolCalls,l={text:n.colorText,textSecondary:n.colorTextTertiary,border:n.colorBorderSecondary,background:n.colorBgElevated},W=r.agents.map(a=>a.name&&a.name.trim()?a.name:a.assistantId==="unattributed"?e("common.observability.unknownAgent"):a.assistantId?a.assistantId.slice(0,8):e("common.observability.unknownAgent")),B=r.models.map(a=>a.model),ce=r.tools.slice(0,10).map(a=>a.tool),K=new Set;for(let a of _)for(let g of a.points)K.add(g.bucket);let U=[...K].sort(),le=U.map(a=>ne(a,i)),M=_.map(a=>{let g=new Map(a.points.map(S=>[S.bucket,S.value??0]));return{name:a.model,data:U.map(S=>g.get(S)??0)}}),N=M.length>0,me=r.agents.reduce((a,g)=>a+g.errorCount,0);return(0,t.jsxs)("div",{style:{display:"grid",gap:20},children:[(0,t.jsx)(R.Text,{type:"secondary",style:{fontSize:12},children:e("common.observability.scopeNote",{environment:r.environment??e("common.observability.allEnvironments"),range:i})}),o.warnings&&o.warnings.length>0?(0,t.jsx)(T,{type:"warning",showIcon:!0,message:e("common.observability.partial")}):null,r.samplingRate<1?(0,t.jsx)(T,{type:"info",showIcon:!0,message:e("common.observability.sampling",{rate:Math.round(r.samplingRate*100)})}):null,(0,t.jsxs)(p,{gutter:[12,12],children:[(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.traces"),value:P(r.kpis.traces),hint:e("common.observability.kpi.tracesHint"),accent:Z,icon:(0,t.jsx)(j,{size:18})})}),(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.cost"),value:ae(r.kpis.costUsd),hint:"USD",accent:ee,icon:(0,t.jsx)(J,{size:18})})}),(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.tokens"),value:D(r.kpis.inputTokens+r.kpis.outputTokens),hint:e("common.observability.kpi.tokensHint",{input:D(r.kpis.inputTokens),output:D(r.kpis.outputTokens)}),accent:te,icon:(0,t.jsx)(q,{size:18})})}),(0,t.jsx)(c,{xs:12,md:6,children:(0,t.jsx)(A,{title:e("common.observability.kpi.errorRate"),value:`${(r.kpis.errorRate*100).toFixed(2)}%`,hint:e("common.observability.kpi.errorsHint",{count:P(me)}),accent:oe,icon:(0,t.jsx)(Q,{size:18})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.traces"),accent:Z}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tracesByAssistant"),hasData:r.agents.length>0,option:y(W,[{name:e("common.observability.table.calls"),data:r.agents.map(a=>a.calls)}],{theme:l,horizontal:!0,kind:"number"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tracesOverTime"),hasData:u(s),option:y(k(s,i),[{name:e("common.observability.kpi.traces"),data:b(s)}],{theme:l,kind:"number"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.cost"),accent:ee}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.costByModel"),hasData:r.models.length>0,option:y(B,[{name:e("common.observability.kpi.cost"),data:r.models.map(a=>a.costUsd)}],{theme:l,kind:"currency"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e(N?"common.observability.chart.costByModelOverTime":"common.observability.chart.costOverTime"),hasData:N?M.some(a=>a.data.some(g=>g!==0)):u(L),option:N?C(le,M,{theme:l,stacked:!0,area:!0,kind:"currency"}):C(k(L,i),[{name:e("common.observability.kpi.cost"),data:b(L)}],{theme:l,area:!0,kind:"currency"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.tokens"),accent:te}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tokensByModel"),hasData:r.models.length>0,option:y(B,[{name:e("common.observability.table.inputTokens"),data:r.models.map(a=>a.inputTokens)},{name:e("common.observability.table.outputTokens"),data:r.models.map(a=>a.outputTokens)}],{theme:l,stacked:!0,kind:"tokens"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.tokensOverTime"),hasData:u(x.input)||u(x.output),option:C(k(x.input,i),[{name:"input",data:b(x.input)},{name:"output",data:b(x.output)}],{theme:l,area:!0,stacked:!0,kind:"tokens"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.errors"),accent:oe}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.errorRateByAssistant"),hasData:r.agents.length>0,option:y(W,[{name:e("common.observability.kpi.errorRate"),data:r.agents.map(a=>a.errorRate)}],{theme:l,horizontal:!0,percent:!0})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.errorRateOverTime"),hasData:u(E),option:C(k(E,i),[{name:e("common.observability.kpi.errorRate"),data:b(E)}],{theme:l,percent:!0,area:!0})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.latency"),accent:be}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.p95ByModel"),hasData:r.models.length>0,option:y(B,[{name:e("common.observability.kpi.p95"),data:r.models.map(a=>a.p95LatencyMs??0)}],{theme:l,horizontal:!0,kind:"ms"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.latencyOverTime"),hasData:u(h.p50)||u(h.p95)||u(h.p99),option:C(k(h.p95,i),[{name:"p50",data:b(h.p50)},{name:"p95",data:b(h.p95)},{name:"p99",data:b(h.p99)}],{theme:l,kind:"ms"})})})]}),(0,t.jsx)(f,{title:e("common.observability.section.tools"),accent:ue}),(0,t.jsxs)(p,{gutter:[16,16],children:[(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.toolsByTool"),hasData:r.tools.length>0,option:y(ce,[{name:e("common.observability.table.calls"),data:r.tools.slice(0,10).map(a=>a.count)}],{theme:l,horizontal:!0,kind:"number"})})}),(0,t.jsx)(c,{xs:24,md:12,children:(0,t.jsx)(m,{title:e("common.observability.chart.toolsOverTime"),hasData:u(z),option:y(k(z,i),[{name:e("common.observability.table.calls"),data:b(z)}],{theme:l,kind:"number"})})})]})]})};export{Te as LangfuseDashboard};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as $,d as J}from"./embed-page-chunk-FE6KYRCO.js";import{b as R,d as V,e as S}from"./embed-page-chunk-DJKD2PHO.js";import"./embed-page-chunk-S4XZPBRM.js";import{j as N,k as H,l as L,m as U,n as W,x as A,y as K,z as Y}from"./embed-page-chunk-
|
|
1
|
+
import{c as $,d as J}from"./embed-page-chunk-FE6KYRCO.js";import{b as R,d as V,e as S}from"./embed-page-chunk-DJKD2PHO.js";import"./embed-page-chunk-S4XZPBRM.js";import{j as N,k as H,l as L,m as U,n as W,x as A,y as K,z as Y}from"./embed-page-chunk-JPRKPIYC.js";import"./embed-page-chunk-4D5PY2CF.js";import"./embed-page-chunk-PY2HBRFF.js";import"./embed-page-chunk-RFN7O6VH.js";import"./embed-page-chunk-F7ZUYG42.js";import{l as w}from"./embed-page-chunk-WR44MKDA.js";import{a as g}from"./embed-page-chunk-QV7QAJ4N.js";import"./embed-page-chunk-VW3NF5NT.js";import"./embed-page-chunk-34RWKVD7.js";import{Aa as G,Oa as _,ab as z,bb as k,eb as F,t as E,y as D}from"./embed-page-chunk-B2KNZ3EW.js";import{Za as P,_ as T,ha as B}from"./embed-page-chunk-F7TA3LRH.js";import{a as b}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-QOWM3LMZ.js";import"./embed-page-chunk-EUOOO2LS.js";import"./embed-page-chunk-5JDQ456X.js";import{f}from"./embed-page-chunk-QBTAJ2YI.js";var n=f(b());var I=f(b());var o=f(g());var ae="tracePulse 1.4s ease-in-out infinite",le={running:(0,o.jsx)(G,{style:{color:"#1890ff"}}),success:(0,o.jsx)(E,{style:{color:"#52c41a"}}),error:(0,o.jsx)(D,{style:{color:"#ff4d4f"}})};function de({kind:e}){switch(e){case"human":return(0,o.jsx)(F,{});case"agent":return(0,o.jsx)(z,{});case"tool":return(0,o.jsx)(k,{});case"ai":return(0,o.jsx)(_,{});default:return(0,o.jsx)(k,{})}}var M=I.default.createContext({}),ce=()=>I.default.useContext(M),pe=({data:e,selected:i})=>{let l=w(),{onJumpToMessage:t}=ce(),s=e.isAnswer===!0,a=e.status==="running",p=(e.parallelCount??1)>1,m=!!(t&&e.messageId&&!e.messageId.startsWith("summary:")),v=e.toolCall?L(e.toolCall.name):e.label,y=()=>{if((e.kind==="tool"||e.kind==="agent")&&e.toolCall){let h=U(e.toolCall.response);return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(H,{data:{name:e.toolCall.name,parameters:e.toolCall.args,type:"tool_call"},component_key:`${e.toolCall.id}-params`,interactive:!1}),h&&(0,o.jsx)("div",{style:{marginTop:8},children:(0,o.jsx)(N,{content:h})}),(0,o.jsx)(W,{ui:e.toolCall.ui})]})}return e.content?(0,o.jsx)(N,{content:e.content}):(0,o.jsx)("span",{style:{color:"#8c8c8c"},children:e.label})};return(0,o.jsxs)("div",{"data-testid":"trace-card",style:{height:"100%",display:"flex",flexDirection:"column",border:`1px solid ${s||i?"#6366f1":a?"#91caff":"#e5e7eb"}`,borderRadius:12,background:s?"#eef2ff":"#fff",boxShadow:a?"0 0 0 2px rgba(24,144,255,0.18)":i?"0 0 0 2px rgba(99,102,241,0.2)":"none",animation:a?ae:void 0,overflow:"hidden",fontSize:13},children:[(0,o.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,padding:"8px 12px",borderBottom:"1px solid #f0f0f0",background:"rgba(0,0,0,0.02)"},children:[(0,o.jsx)(de,{kind:e.kind}),(0,o.jsx)("span",{style:{fontWeight:s?700:600,flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:v}),p&&(0,o.jsx)(P,{color:"purple",style:{marginInlineEnd:0,fontSize:10},children:l("chat.trace.parallelBadge",{count:e.parallelCount??1})}),le[e.status],m&&(0,o.jsx)(T,{type:"text",size:"small",onClick:()=>t?.(e.messageId),children:l("chat.trace.jumpToChat")})]}),(0,o.jsx)("div",{style:{flex:1,minHeight:0,overflow:"auto",padding:12},children:y()})]})},fe=({data:e,selected:i})=>(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(S,{type:"target",position:R.Top}),(0,o.jsx)(pe,{data:e,selected:i}),(0,o.jsx)(S,{type:"source",position:R.Bottom})]}),j={trace:fe};var Z=f(b());var u=f(g()),ue={running:"#1890ff",success:"#52c41a",error:"#ff4d4f"},q=({graph:e,activeNodeId:i,onSelectNode:l})=>{let t=Z.default.useMemo(()=>new Map(e.nodes.map(s=>[s.id,s])),[e.nodes]);return(0,u.jsx)("div",{"data-testid":"trace-overview-rail",style:{display:"flex",flexDirection:"column",gap:10,width:160,padding:8,overflowY:"auto",borderRight:"1px solid #f0f0f0"},children:e.phases.map(s=>(0,u.jsxs)("div",{"data-testid":"trace-rail-phase",children:[(0,u.jsx)("div",{style:{fontSize:12,color:"#8c8c8c",marginBottom:4},children:s.title}),(0,u.jsx)("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:s.nodeIds.map(a=>{let p=t.get(a);if(!p)return null;let m=a===i;return(0,u.jsx)(B,{title:p.data.label,children:(0,u.jsx)("button",{type:"button","data-testid":"trace-rail-tick",onClick:()=>l?.(a),style:{width:m?12:8,height:m?12:8,borderRadius:"50%",border:"none",padding:0,cursor:"pointer",background:ue[p.data.status],outline:m?"2px solid #6366f1":"none"}})},a)})})]},s.id))})};var d=f(g()),Q=3,X=()=>{},me=`
|
|
2
2
|
@keyframes tracePulse {
|
|
3
3
|
0%, 100% { box-shadow: 0 0 0 2px rgba(24,144,255,0.18); }
|
|
4
4
|
50% { box-shadow: 0 0 0 6px rgba(24,144,255,0.05); }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as D}from"./embed-page-chunk-UDSGGVJH.js";import{i as E}from"./embed-page-chunk-
|
|
1
|
+
import{s as D}from"./embed-page-chunk-UDSGGVJH.js";import{i as E}from"./embed-page-chunk-JPRKPIYC.js";import"./embed-page-chunk-4D5PY2CF.js";import"./embed-page-chunk-PY2HBRFF.js";import{a as T}from"./embed-page-chunk-RFN7O6VH.js";import"./embed-page-chunk-F7ZUYG42.js";import{l as v}from"./embed-page-chunk-WR44MKDA.js";import{a as C}from"./embed-page-chunk-QV7QAJ4N.js";import"./embed-page-chunk-VW3NF5NT.js";import"./embed-page-chunk-34RWKVD7.js";import"./embed-page-chunk-B2KNZ3EW.js";import{qa as x}from"./embed-page-chunk-F7TA3LRH.js";import{a as w}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-QOWM3LMZ.js";import"./embed-page-chunk-EUOOO2LS.js";import"./embed-page-chunk-5JDQ456X.js";import{f as p}from"./embed-page-chunk-QBTAJ2YI.js";var u=p(w());var R=p(T());var y=p(C());function g(l,i){if(!l||l.length===0)return{title:{text:i("genui.chart.title"),left:"left"},tooltip:{trigger:"axis"},legend:{right:0,orient:"vertical"},xAxis:{type:"category",data:[]},yAxis:{type:"value"},series:[{type:"line",name:i("genui.chart.seriesDefault",{n:1}),data:[]}],grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0}};let s=l[0],t=Object.keys(s);if(t.length===0)return g([],i);let r=t.filter(e=>{let n=s[e];return typeof n=="number"||!isNaN(Number(n))});if(r.length>0){let e=r[0],n=t.find(a=>!r.includes(a))||t[0],o=l.map((a,c)=>a[n]!==void 0?String(a[n]):i("genui.chart.itemDefault",{n:c+1})),f=l.map(a=>{let c=a[e];return typeof c=="number"?c:Number(c)||0});return{title:{text:i("genui.chart.title"),left:"left"},tooltip:{trigger:"axis"},legend:{right:0,orient:"vertical",data:[e]},xAxis:{type:"category",data:o},yAxis:{type:"value"},series:[{type:"line",name:e,data:f}],grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0}}}return{title:{text:i("genui.chart.title"),left:"left"},tooltip:{trigger:"axis"},legend:{right:0,orient:"vertical"},xAxis:{type:"category",data:l.map((e,n)=>i("genui.chart.itemDefault",{n:n+1}))},yAxis:{type:"value"},series:[{type:"bar",name:i("genui.chart.countSeries"),data:l.map(()=>1)}],grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0}}}function j(l,i){if(!l||typeof l!="object"||!l.series||!Array.isArray(l.series)||l.series.length===0)return null;let s=l.series.map((e,n)=>{if(!e||typeof e!="object"||!e.type||!e.data||!Array.isArray(e.data)||e.data.length===0)return null;let o={...e,name:e.name||i("genui.chart.seriesDefault",{n:n+1})};if(e.type==="pie"){let f=e.data.map((a,c)=>typeof a=="object"&&a!==null&&"value"in a?{value:a.value,name:a.name||i("genui.chart.itemDefault",{n:c+1})}:typeof a=="number"?{value:a,name:i("genui.chart.itemDefault",{n:c+1})}:null).filter(a=>a!==null);return f.length===0?null:{...o,data:f}}return o}).filter(e=>e!==null);if(s.length===0)return null;let t={...l,series:s},r=s[0].type;if(r!=="pie"){if(!t.xAxis)t.xAxis={type:"category",data:[]};else if(typeof t.xAxis=="object"&&!Array.isArray(t.xAxis)){let e=t.xAxis;if(e.type||(e.type="category"),e.type==="category"&&!e.data){let n=s[0].data;Array.isArray(n)&&n.length>0?Array.isArray(n[0])?e.data=n.map(o=>o[0]):e.data=n.map((o,f)=>i("genui.chart.itemDefault",{n:f+1})):e.data=[]}t.xAxis=e}t.yAxis?typeof t.yAxis=="object"&&!Array.isArray(t.yAxis)&&(t.yAxis.type||(t.yAxis.type="value")):t.yAxis={type:"value"}}if(!t.title)t.title={text:i("genui.chart.title"),left:"left"};else if(typeof t.title=="object"){let e=t.title;e.left||(e.left="left"),e.text||(e.text=i("genui.chart.title")),t.title=e}if(t.tooltip||(t.tooltip={trigger:r==="pie"?"item":"axis"}),!t.legend)s.length>1&&(t.legend={right:0,orient:"vertical"});else if(typeof t.legend=="object"){let e=t.legend;t.legend=e}return r!=="pie"&&!t.grid&&(t.grid={left:"3%",right:"4%",bottom:"3%",containLabel:!0}),t}function O(l,i){let s=null;try{let n=typeof l=="string"?l:l.join("");s=(0,R.parse)(n)}catch(n){return{data:null,error:`Failed to parse JSON: ${n instanceof Error?n.message:String(n)}`}}if(!s||typeof s!="object")return{data:null,error:"Parsed data is not an object"};let t=s.series&&Array.isArray(s.series)&&s.series.length>0,r={table:Array.isArray(s.table)?s.table:void 0},e=null;if(s.echarts?e=s.echarts:t&&(e=s),e){let n=j(e,i);if(n)r.echarts=n;else if(r.table&&r.table.length>0)r.echarts=g(r.table,i);else return{data:null,error:"ECharts configuration is invalid or incomplete. Required: series array with at least one series containing type and data."}}else r.table&&r.table.length>0?r.echarts=g(r.table,i):r.echarts=g([],i);return{data:r,error:null}}var K=l=>{let{children:i}=l,s=v(),t=(0,u.useRef)(null),r=(0,u.useRef)(null),e=(0,u.useRef)(null),[n,o]=(0,u.useState)(null);(0,u.useEffect)(()=>{if(!t.current)return;r.current||(r.current=D(t.current));let a=null;if((typeof i=="string"||Array.isArray(i))&&(a=i),!a){r.current&&r.current.clear(),o(null);return}let{data:c,error:m}=O(a,s);if(m||!c){console.warn("ReactChart failed to parse chart data:",m||"Unknown parse error"),r.current&&r.current.clear(),o(null);return}if(c.table&&Array.isArray(c.table)&&o(c.table),c.echarts)try{r.current.setOption(c.echarts,!0)}catch(d){let A=d instanceof Error?d.message:"Failed to render chart";console.error("Failed to set ECharts option:",d),r.current&&r.current.clear(),o(null)}let h=()=>{r.current&&r.current.resize()};return e.current&&(e.current.disconnect(),e.current=null),t.current&&typeof ResizeObserver<"u"&&(e.current=new ResizeObserver(d=>{requestAnimationFrame(()=>{h()})}),e.current.observe(t.current)),window.addEventListener("resize",h),()=>{e.current&&(e.current.disconnect(),e.current=null),window.removeEventListener("resize",h)}},[i,s]),(0,u.useEffect)(()=>()=>{e.current&&(e.current.disconnect(),e.current=null),r.current&&(r.current.dispose(),r.current=null)},[]);let f=a=>{if(!a||a.length===0)return[];if(Array.isArray(a[0])){let c=a[0];return a.slice(1).map((h,d)=>{let A={};return h.forEach((S,b)=>{A[c[b]||`col_${b}`]=S}),A})}return a};return(0,y.jsxs)(x,{children:[(0,y.jsx)("div",{ref:t,style:{width:"100%",height:"400px",minHeight:"300px"}}),n&&n.length>0&&(0,y.jsx)("div",{style:{marginTop:16},children:(0,y.jsx)(E,{component_key:"chart_table_data",data:{dataSource:f(n),message:s("genui.chart.dataDetails")},interactive:!0,default_open_in_side_app:!0})})]})};export{K as ReactChart};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as Z,c as he,e as ee,f as Se,g as xe,h as ve,i as be,l as Te,m as Ce}from"./embed-page-chunk-DJKD2PHO.js";import{a as fe,b as ge,c as me,d as ue,e as ke}from"./embed-page-chunk-SV2BM3WO.js";import"./embed-page-chunk-S4XZPBRM.js";import{a as V,b as we}from"./embed-page-chunk-5DSJCBZF.js";import{o as se,t as ne}from"./embed-page-chunk-3PGODDQW.js";import{l as q}from"./embed-page-chunk-5GAHI45T.js";import{a as K}from"./embed-page-chunk-QV7QAJ4N.js";import{D as ce,E as de,Ja as U,ea as pe,o as re,sa as ye}from"./embed-page-chunk-B2KNZ3EW.js";import{Ia as R,La as C,Ma as le,Za as E,_ as v,_a as _,bb as ae,ua as ie,za as B}from"./embed-page-chunk-F7TA3LRH.js";import{a as oe}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-EUOOO2LS.js";import{f as W}from"./embed-page-chunk-QBTAJ2YI.js";var h=W(oe());var k=W(oe());var e=W(K()),{Text:d}=ae,{TextArea:Ne}=R,Ee=({data:b})=>{let s=q(),{token:o}=_.useToken(),{config:w}=ne(),{put:Y}=V(),I=he(t=>t.transform[2])>.6,G=se("__GLOBAL__");if(!b)return null;let{skill:g,onClick:D,onDelete:S}=b;if(!g)return null;let[i,A]=(0,k.useState)(g),O=i.subSkills&&i.subSkills.length>0,m=i.subSkills?.length||0,F=(0,k.useMemo)(()=>Math.min(12+Math.sqrt(m)*10,48),[m]),X=i.metadata&&i.metadata.category||"global",T=(0,k.useMemo)(()=>i.metadata?Object.entries(i.metadata).filter(([t,a])=>t&&a):[],[i.metadata]),P=t=>{if(!t)return"";let a=t instanceof Date?t:new Date(t);return Number.isNaN(a.getTime())?"":a.toLocaleString()},J=t=>{navigator.clipboard.writeText(t)},[z,x]=(0,k.useState)(!1),[p,n]=(0,k.useState)({...g,id:g.name}),[c,u]=(0,k.useState)(T.map(([t,a])=>({key:t,value:a}))),[$,M]=(0,k.useState)(!1),[Q,L]=(0,k.useState)(!1);(0,k.useEffect)(()=>{x(!1),A(g),n({...g,id:g.name}),u(Object.entries(g.metadata||{}).map(([t,a])=>({key:t,value:a})))},[g]);let l=(t,a)=>{if(t==="name"){n(r=>({...r,name:a,id:a}));return}n(r=>({...r,[t]:a}))},H=async t=>{t?.stopPropagation(),t?.preventDefault();try{let a=i.id||i.name;if(!a){C.error(s("chatWorkspace.skillNode.idMissing"));return}await G.skills.delete(a),C.success(s("chatWorkspace.skillNode.deleted")),M(!1),S&&await S()}catch(a){C.error(a?.message||s("chatWorkspace.skillNode.deleteFailed"))}},j=t=>{u(t);let a=t.reduce((r,y)=>(y.key&&(r[y.key]=y.value),r),{});n(r=>({...r,metadata:a}))},te=(t,a,r)=>{let y=[...c];y[t]={...y[t],[a]:r},j(y)},We=()=>{j([...c,{key:"",value:""}])},Be=async()=>{try{L(!0);let t={"Content-Type":"application/json"};w.apiKey&&(t.Authorization=`Bearer ${w.apiKey}`);let a={name:p.name,description:p.description,license:p.license||void 0,compatibility:p.compatibility||void 0,metadata:p.metadata||void 0,content:p.content||void 0,subSkills:p.subSkills||void 0},r=await Y(`/api/skills/${i.id}`,a);if(r.success){C.success(s("chatWorkspace.skillNode.updated"));let y=r.data||p;A(y),n({...y,id:y.name}),u(Object.entries(y.metadata||{}).map(([Fe,Me])=>({key:Fe,value:Me}))),x(!1),D?.(y)}else C.error(r.message||s("chatWorkspace.skillNode.updateFailed"))}catch(t){C.error(t.message||s("chatWorkspace.skillNode.updateError"))}finally{L(!1)}},Re=(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"row",gap:24},children:[(0,e.jsxs)("div",{style:{flex:"0 0 320px",display:"flex",flexDirection:"column",gap:12},children:[(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:6},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.description")}),(0,e.jsx)(Ne,{value:p.description,onChange:t=>l("description",t.target.value),placeholder:s("chatWorkspace.skills.field.description"),rows:3})]}),(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:6},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.license")}),(0,e.jsx)(R,{value:p.license,onChange:t=>l("license",t.target.value),placeholder:s("chatWorkspace.skills.field.license")})]}),(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:6},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.compatibility")}),(0,e.jsx)(R,{value:p.compatibility,onChange:t=>l("compatibility",t.target.value),placeholder:s("chatWorkspace.skills.field.compatibility")})]}),(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:500},children:s("chatWorkspace.skills.field.metadata")}),(0,e.jsx)(v,{size:"small",icon:(0,e.jsx)(U,{}),onClick:We,children:s("chatWorkspace.skillNode.add")})]}),(0,e.jsxs)(B,{direction:"vertical",size:8,style:{width:"100%"},children:[c.length===0&&(0,e.jsx)(d,{style:{fontSize:11,color:o.colorTextTertiary},children:s("chatWorkspace.skillNode.noMetadata")}),c.map((t,a)=>(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:4,width:"100%"},children:[(0,e.jsx)(d,{style:{fontSize:11,color:o.colorTextSecondary},children:s("chatWorkspace.skillNode.meta",{index:a+1})}),(0,e.jsxs)(B,{style:{width:"100%"},size:8,wrap:!0,children:[(0,e.jsx)(R,{value:t.key,placeholder:s("chatWorkspace.skillNode.keyPlaceholder"),style:{width:120},onChange:r=>te(a,"key",r.target.value)}),(0,e.jsx)(R,{value:t.value,placeholder:s("chatWorkspace.skillNode.valuePlaceholder"),style:{flex:1,minWidth:160},onChange:r=>te(a,"value",r.target.value)})]})]},a))]})]}),(0,e.jsxs)("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:6,minWidth:400},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.content")}),(0,e.jsx)(Ne,{value:p.content,onChange:t=>l("content",t.target.value),placeholder:s("chatWorkspace.skillNode.contentPlaceholder"),rows:30,style:{fontFamily:"monospace",fontSize:13,flex:1,minHeight:600}})]})]}),Ie=(0,e.jsxs)("div",{style:{width:z?960:720,maxHeight:"95vh",overflowY:"auto",padding:24},children:[(0,e.jsx)("div",{style:{display:"flex",alignItems:"flex-start",justifyContent:"space-between",marginBottom:16},children:(0,e.jsxs)("div",{style:{flex:1},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(d,{strong:!0,style:{fontSize:18,fontWeight:600,color:o.colorText},children:i.name}),(0,e.jsx)(E,{style:{margin:0,fontSize:10,padding:"2px 8px",fontWeight:600},color:"geekblue",children:X.toUpperCase()})]}),(0,e.jsx)("div",{style:{display:"flex",alignItems:"center",gap:6},children:(0,e.jsx)(d,{style:{fontSize:11,color:o.colorTextTertiary,fontFamily:"monospace"},children:`>_ ${i.id}`})})]})}),z?Re:(0,e.jsxs)(e.Fragment,{children:[i.description&&(0,e.jsx)("div",{style:{marginBottom:16},children:(0,e.jsxs)(d,{style:{fontSize:12,color:o.colorText,lineHeight:1.6,fontStyle:"italic"},children:['"',i.description,'"']})}),T.length>0&&(0,e.jsxs)("div",{style:{marginBottom:16},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(ye,{style:{fontSize:14,color:o.colorTextSecondary}}),(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:500},children:s("chatWorkspace.skillNode.metadataCount",{count:T.length})})]}),(0,e.jsx)("div",{style:{border:`1px solid ${o.colorBorderSecondary}`,borderRadius:6,overflow:"hidden"},children:T.map(([t,a],r)=>(0,e.jsxs)("div",{style:{display:"flex",alignItems:"stretch",borderBottom:r===T.length-1?"none":`1px solid ${o.colorBorderSecondary}`},children:[(0,e.jsx)("div",{style:{width:140,padding:"8px 10px",background:o.colorFillTertiary,borderRight:`1px solid ${o.colorBorderSecondary}`,fontSize:11,color:o.colorTextSecondary,fontWeight:600,textTransform:"capitalize"},children:t}),(0,e.jsx)("div",{style:{flex:1,padding:"8px 10px",fontSize:11,color:o.colorText,wordBreak:"break-word"},children:a})]},t))})]}),O&&(0,e.jsxs)("div",{style:{marginBottom:16},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(re,{style:{fontSize:14,color:o.colorTextSecondary}}),(0,e.jsxs)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:500},children:["Sub-Skills (",i.subSkills.length,")"]})]}),(0,e.jsx)(B,{size:[8,8],wrap:!0,children:i.subSkills.map((t,a)=>(0,e.jsx)(E,{style:{fontSize:11,padding:"4px 12px",backgroundColor:o.colorFillTertiary,color:o.colorText,border:`1px solid ${o.colorBorderSecondary}`},children:t},a))})]}),(i.license||i.compatibility)&&(0,e.jsx)("div",{style:{marginBottom:16},children:(0,e.jsxs)(B,{size:[8,8],wrap:!0,children:[i.license&&(0,e.jsx)(E,{icon:(0,e.jsx)(de,{}),style:{margin:0,fontSize:11,padding:"4px 12px",borderRadius:6,backgroundColor:o.colorInfoBg,color:o.colorInfo,border:`1px solid ${o.colorInfoBorder}`,fontWeight:500,lineHeight:"16px"},children:i.license}),i.compatibility&&(0,e.jsx)(E,{style:{margin:0,fontSize:11,padding:"4px 12px",borderRadius:6,backgroundColor:o.colorSuccessBg,color:o.colorSuccess,border:`1px solid ${o.colorSuccessBorder}`,fontWeight:500,lineHeight:"16px",display:"inline-flex",alignItems:"center",gap:4},children:i.compatibility})]})}),(i.createdAt||i.updatedAt)&&(0,e.jsx)("div",{style:{marginBottom:16},children:(0,e.jsxs)(B,{direction:"vertical",size:4,children:[i.createdAt&&(0,e.jsxs)(d,{style:{fontSize:11,color:o.colorTextTertiary,fontFamily:"monospace"},children:["Created: ",P(i.createdAt)]}),i.updatedAt&&(0,e.jsxs)(d,{style:{fontSize:11,color:o.colorTextTertiary,fontFamily:"monospace"},children:["Updated: ",P(i.updatedAt)]})]})}),i.content&&(0,e.jsxs)("div",{style:{marginBottom:0},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(pe,{style:{fontSize:14,color:o.colorTextSecondary}}),(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:600,letterSpacing:.5},children:s("chatWorkspace.skillNode.contentSection")})]}),(0,e.jsx)("div",{style:{padding:16,background:o.colorFillTertiary,border:`1px solid ${o.colorBorderSecondary}`,borderRadius:6,maxHeight:400,overflowY:"auto"},children:(0,e.jsx)(d,{style:{fontSize:12,color:o.colorText,lineHeight:1.7,whiteSpace:"pre-wrap",fontFamily:"monospace"},children:i.content})})]})]}),(0,e.jsx)(ie,{style:{margin:"16px 0"}}),(0,e.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8},children:z?(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(v,{block:!0,onClick:()=>{x(!1),n(g)},style:{flex:1},children:s("common.cancel")}),(0,e.jsx)(v,{type:"primary",block:!0,onClick:Be,loading:Q,style:{flex:1},children:s("common.save")})]}):(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(v,{type:"primary",block:!0,onClick:()=>x(!0),style:{flex:1},children:s("chatWorkspace.skillNode.edit")}),(0,e.jsx)(v,{danger:!0,onClick:t=>{t.stopPropagation(),H(t)},children:s("common.delete")}),(0,e.jsx)(v,{icon:(0,e.jsx)(ce,{}),onClick:()=>J(i.id),title:s("chatWorkspace.skillNode.copyId")})]})})]});return(0,e.jsxs)("div",{style:{position:"relative",padding:4,overflow:"visible"},children:[(0,e.jsx)(ee,{type:"source",position:Z.Top,style:{left:"50%",top:"50%",transform:"translate(-50%, -50%)",background:"transparent",border:"none",width:1,height:1,borderRadius:"50%",pointerEvents:"none"},isConnectable:!1}),(0,e.jsx)(ee,{type:"target",position:Z.Top,style:{left:"50%",top:"50%",transform:"translate(-50%, -50%)",background:"transparent",border:"none",width:1,height:1,borderRadius:"50%",pointerEvents:"none"},isConnectable:!1}),(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:6,cursor:"pointer",position:"relative"},onClick:()=>M(!0),children:[(0,e.jsx)("div",{style:{width:F,height:F,borderRadius:"50%",background:"#999",flexShrink:0,boxShadow:"0 1px 4px rgba(0,0,0,0.15)",transition:"transform 0.15s ease"},onMouseEnter:t=>{t.currentTarget.style.transform="scale(1.15)"},onMouseLeave:t=>{t.currentTarget.style.transform="scale(1)"}}),I&&(0,e.jsx)(d,{style:{position:"absolute",top:"100%",left:"50%",transform:"translateX(-50%)",marginTop:4,fontSize:10,color:o.colorTextSecondary,opacity:.45,whiteSpace:"nowrap",pointerEvents:"none",userSelect:"none"},children:i.name})]}),(0,e.jsx)(le,{open:$,onCancel:()=>{M(!1),x(!1),n({...i,id:i.name})},footer:null,width:z?1e3:760,destroyOnClose:!0,title:null,styles:{body:{padding:0}},children:Ie})]})},ze=Ee;var f=W(K()),De=({onNodeClick:b})=>{let s=q(),[o,w,Y]=ve([]),[N,I,G]=be([]),[g,D]=(0,h.useState)(!1),[S,i]=(0,h.useState)([]),[A,O]=(0,h.useState)(!1),[m,F]=(0,h.useState)(null),{token:X}=_.useToken(),{get:T}=V(),P=(0,h.useMemo)(()=>({skill:ze}),[]),J=(0,h.useMemo)(()=>m===null?o:o.map(n=>{let c=n.id===m||N.some(u=>u.source===m&&u.target===n.id||u.target===m&&u.source===n.id);return{...n,style:{opacity:c?1:.2,transition:"opacity 0.2s ease"}}}),[o,N,m]),z=(0,h.useMemo)(()=>m===null?N.map(n=>({...n,style:{stroke:"#1677ff",strokeWidth:1.5,opacity:.25,transition:"opacity 0.2s ease"}})):N.map(n=>{let c=n.source===m||n.target===m;return{...n,style:{stroke:"#1677ff",strokeWidth:c?2.5:1,opacity:c?1:.04,transition:"opacity 0.2s ease"}}}),[N,m]),x=async()=>{O(!0);try{let n=await T("/api/skills");n.success&&n.data&&Array.isArray(n.data.records)&&i(n.data.records)}catch(n){console.error("Failed to fetch skills:",n),i([])}finally{O(!1)}};(0,h.useEffect)(()=>{x()},[]),(0,h.useEffect)(()=>{if(!S||S.length===0){w([]),I([]);return}let n=[],c=new Map,u=[];S.forEach(l=>{c.set(l.name,l),l.subSkills&&l.subSkills.length>0&&l.subSkills.forEach(H=>{S.find(j=>j.name===H)&&u.push({source:l.name,target:H})})});let $=S.map(l=>({id:l.name})),M=u.map(l=>({source:l.source,target:l.target})),Q=ue($).force("link",me(M).id(l=>l.id).distance(80)).force("charge",ke().strength(-300)).force("center",fe(0,0)).force("collide",ge(30)).stop();for(let l=0;l<300;l++)Q.tick();let L=$.map(l=>({id:l.id,type:"skill",data:{skill:c.get(l.id),onClick:()=>b?.(c.get(l.id)),onDelete:x},position:{x:l.x,y:l.y}}));u.forEach(l=>{c.has(l.source)&&c.has(l.target)&&n.push({id:`e${l.source}-${l.target}`,source:l.source,target:l.target,style:{stroke:"#1677ff",strokeWidth:2},type:"straight"})}),w(L),I(n)},[S,w,I,b]);let p=async()=>{await x()};return A?(0,f.jsx)("div",{style:{width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",background:"#fafafa"},children:s("chat.skills.loading")}):(0,f.jsxs)("div",{style:{width:"100%",height:"100%",background:"#fafafa",position:"relative"},children:[(0,f.jsxs)(xe,{nodes:J,edges:z,onNodesChange:Y,onEdgesChange:G,onNodeMouseEnter:(n,c)=>F(c.id),onNodeMouseLeave:()=>F(null),nodeTypes:P,fitView:!0,children:[(0,f.jsx)(Te,{color:"#eee",gap:20}),(0,f.jsx)(Ce,{})]}),(0,f.jsx)("div",{style:{position:"absolute",top:20,right:20,zIndex:10},children:(0,f.jsx)(v,{type:"primary",size:"large",icon:(0,f.jsx)(U,{}),onClick:()=>D(!0),style:{height:48,width:48,borderRadius:"50%",boxShadow:X.boxShadowTertiary,display:"flex",alignItems:"center",justifyContent:"center",padding:0}})}),(0,f.jsx)(we,{open:g,onCancel:()=>D(!1),onSuccess:p})]})},Ae=b=>(0,f.jsx)(Se,{children:(0,f.jsx)(De,{...b})}),nt=Ae;export{nt as default};
|
|
1
|
+
import{b as Z,c as he,e as ee,f as Se,g as xe,h as ve,i as be,l as Te,m as Ce}from"./embed-page-chunk-DJKD2PHO.js";import{a as fe,b as ge,c as me,d as ue,e as ke}from"./embed-page-chunk-SV2BM3WO.js";import"./embed-page-chunk-S4XZPBRM.js";import{a as V,b as we}from"./embed-page-chunk-PY2HBRFF.js";import{o as se,t as ne}from"./embed-page-chunk-RFN7O6VH.js";import{l as q}from"./embed-page-chunk-WR44MKDA.js";import{a as K}from"./embed-page-chunk-QV7QAJ4N.js";import{D as ce,E as de,Ja as U,ea as pe,o as re,sa as ye}from"./embed-page-chunk-B2KNZ3EW.js";import{Ia as R,La as C,Ma as le,Za as E,_ as v,_a as _,bb as ae,ua as ie,za as B}from"./embed-page-chunk-F7TA3LRH.js";import{a as oe}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-EUOOO2LS.js";import{f as W}from"./embed-page-chunk-QBTAJ2YI.js";var h=W(oe());var k=W(oe());var e=W(K()),{Text:d}=ae,{TextArea:Ne}=R,Ee=({data:b})=>{let s=q(),{token:o}=_.useToken(),{config:w}=ne(),{put:Y}=V(),I=he(t=>t.transform[2])>.6,G=se("__GLOBAL__");if(!b)return null;let{skill:g,onClick:D,onDelete:S}=b;if(!g)return null;let[i,A]=(0,k.useState)(g),O=i.subSkills&&i.subSkills.length>0,m=i.subSkills?.length||0,F=(0,k.useMemo)(()=>Math.min(12+Math.sqrt(m)*10,48),[m]),X=i.metadata&&i.metadata.category||"global",T=(0,k.useMemo)(()=>i.metadata?Object.entries(i.metadata).filter(([t,a])=>t&&a):[],[i.metadata]),P=t=>{if(!t)return"";let a=t instanceof Date?t:new Date(t);return Number.isNaN(a.getTime())?"":a.toLocaleString()},J=t=>{navigator.clipboard.writeText(t)},[z,x]=(0,k.useState)(!1),[p,n]=(0,k.useState)({...g,id:g.name}),[c,u]=(0,k.useState)(T.map(([t,a])=>({key:t,value:a}))),[$,M]=(0,k.useState)(!1),[Q,L]=(0,k.useState)(!1);(0,k.useEffect)(()=>{x(!1),A(g),n({...g,id:g.name}),u(Object.entries(g.metadata||{}).map(([t,a])=>({key:t,value:a})))},[g]);let l=(t,a)=>{if(t==="name"){n(r=>({...r,name:a,id:a}));return}n(r=>({...r,[t]:a}))},H=async t=>{t?.stopPropagation(),t?.preventDefault();try{let a=i.id||i.name;if(!a){C.error(s("chatWorkspace.skillNode.idMissing"));return}await G.skills.delete(a),C.success(s("chatWorkspace.skillNode.deleted")),M(!1),S&&await S()}catch(a){C.error(a?.message||s("chatWorkspace.skillNode.deleteFailed"))}},j=t=>{u(t);let a=t.reduce((r,y)=>(y.key&&(r[y.key]=y.value),r),{});n(r=>({...r,metadata:a}))},te=(t,a,r)=>{let y=[...c];y[t]={...y[t],[a]:r},j(y)},We=()=>{j([...c,{key:"",value:""}])},Be=async()=>{try{L(!0);let t={"Content-Type":"application/json"};w.apiKey&&(t.Authorization=`Bearer ${w.apiKey}`);let a={name:p.name,description:p.description,license:p.license||void 0,compatibility:p.compatibility||void 0,metadata:p.metadata||void 0,content:p.content||void 0,subSkills:p.subSkills||void 0},r=await Y(`/api/skills/${i.id}`,a);if(r.success){C.success(s("chatWorkspace.skillNode.updated"));let y=r.data||p;A(y),n({...y,id:y.name}),u(Object.entries(y.metadata||{}).map(([Fe,Me])=>({key:Fe,value:Me}))),x(!1),D?.(y)}else C.error(r.message||s("chatWorkspace.skillNode.updateFailed"))}catch(t){C.error(t.message||s("chatWorkspace.skillNode.updateError"))}finally{L(!1)}},Re=(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"row",gap:24},children:[(0,e.jsxs)("div",{style:{flex:"0 0 320px",display:"flex",flexDirection:"column",gap:12},children:[(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:6},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.description")}),(0,e.jsx)(Ne,{value:p.description,onChange:t=>l("description",t.target.value),placeholder:s("chatWorkspace.skills.field.description"),rows:3})]}),(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:6},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.license")}),(0,e.jsx)(R,{value:p.license,onChange:t=>l("license",t.target.value),placeholder:s("chatWorkspace.skills.field.license")})]}),(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:6},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.compatibility")}),(0,e.jsx)(R,{value:p.compatibility,onChange:t=>l("compatibility",t.target.value),placeholder:s("chatWorkspace.skills.field.compatibility")})]}),(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:500},children:s("chatWorkspace.skills.field.metadata")}),(0,e.jsx)(v,{size:"small",icon:(0,e.jsx)(U,{}),onClick:We,children:s("chatWorkspace.skillNode.add")})]}),(0,e.jsxs)(B,{direction:"vertical",size:8,style:{width:"100%"},children:[c.length===0&&(0,e.jsx)(d,{style:{fontSize:11,color:o.colorTextTertiary},children:s("chatWorkspace.skillNode.noMetadata")}),c.map((t,a)=>(0,e.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:4,width:"100%"},children:[(0,e.jsx)(d,{style:{fontSize:11,color:o.colorTextSecondary},children:s("chatWorkspace.skillNode.meta",{index:a+1})}),(0,e.jsxs)(B,{style:{width:"100%"},size:8,wrap:!0,children:[(0,e.jsx)(R,{value:t.key,placeholder:s("chatWorkspace.skillNode.keyPlaceholder"),style:{width:120},onChange:r=>te(a,"key",r.target.value)}),(0,e.jsx)(R,{value:t.value,placeholder:s("chatWorkspace.skillNode.valuePlaceholder"),style:{flex:1,minWidth:160},onChange:r=>te(a,"value",r.target.value)})]})]},a))]})]}),(0,e.jsxs)("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:6,minWidth:400},children:[(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary},children:s("chatWorkspace.skills.field.content")}),(0,e.jsx)(Ne,{value:p.content,onChange:t=>l("content",t.target.value),placeholder:s("chatWorkspace.skillNode.contentPlaceholder"),rows:30,style:{fontFamily:"monospace",fontSize:13,flex:1,minHeight:600}})]})]}),Ie=(0,e.jsxs)("div",{style:{width:z?960:720,maxHeight:"95vh",overflowY:"auto",padding:24},children:[(0,e.jsx)("div",{style:{display:"flex",alignItems:"flex-start",justifyContent:"space-between",marginBottom:16},children:(0,e.jsxs)("div",{style:{flex:1},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(d,{strong:!0,style:{fontSize:18,fontWeight:600,color:o.colorText},children:i.name}),(0,e.jsx)(E,{style:{margin:0,fontSize:10,padding:"2px 8px",fontWeight:600},color:"geekblue",children:X.toUpperCase()})]}),(0,e.jsx)("div",{style:{display:"flex",alignItems:"center",gap:6},children:(0,e.jsx)(d,{style:{fontSize:11,color:o.colorTextTertiary,fontFamily:"monospace"},children:`>_ ${i.id}`})})]})}),z?Re:(0,e.jsxs)(e.Fragment,{children:[i.description&&(0,e.jsx)("div",{style:{marginBottom:16},children:(0,e.jsxs)(d,{style:{fontSize:12,color:o.colorText,lineHeight:1.6,fontStyle:"italic"},children:['"',i.description,'"']})}),T.length>0&&(0,e.jsxs)("div",{style:{marginBottom:16},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(ye,{style:{fontSize:14,color:o.colorTextSecondary}}),(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:500},children:s("chatWorkspace.skillNode.metadataCount",{count:T.length})})]}),(0,e.jsx)("div",{style:{border:`1px solid ${o.colorBorderSecondary}`,borderRadius:6,overflow:"hidden"},children:T.map(([t,a],r)=>(0,e.jsxs)("div",{style:{display:"flex",alignItems:"stretch",borderBottom:r===T.length-1?"none":`1px solid ${o.colorBorderSecondary}`},children:[(0,e.jsx)("div",{style:{width:140,padding:"8px 10px",background:o.colorFillTertiary,borderRight:`1px solid ${o.colorBorderSecondary}`,fontSize:11,color:o.colorTextSecondary,fontWeight:600,textTransform:"capitalize"},children:t}),(0,e.jsx)("div",{style:{flex:1,padding:"8px 10px",fontSize:11,color:o.colorText,wordBreak:"break-word"},children:a})]},t))})]}),O&&(0,e.jsxs)("div",{style:{marginBottom:16},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(re,{style:{fontSize:14,color:o.colorTextSecondary}}),(0,e.jsxs)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:500},children:["Sub-Skills (",i.subSkills.length,")"]})]}),(0,e.jsx)(B,{size:[8,8],wrap:!0,children:i.subSkills.map((t,a)=>(0,e.jsx)(E,{style:{fontSize:11,padding:"4px 12px",backgroundColor:o.colorFillTertiary,color:o.colorText,border:`1px solid ${o.colorBorderSecondary}`},children:t},a))})]}),(i.license||i.compatibility)&&(0,e.jsx)("div",{style:{marginBottom:16},children:(0,e.jsxs)(B,{size:[8,8],wrap:!0,children:[i.license&&(0,e.jsx)(E,{icon:(0,e.jsx)(de,{}),style:{margin:0,fontSize:11,padding:"4px 12px",borderRadius:6,backgroundColor:o.colorInfoBg,color:o.colorInfo,border:`1px solid ${o.colorInfoBorder}`,fontWeight:500,lineHeight:"16px"},children:i.license}),i.compatibility&&(0,e.jsx)(E,{style:{margin:0,fontSize:11,padding:"4px 12px",borderRadius:6,backgroundColor:o.colorSuccessBg,color:o.colorSuccess,border:`1px solid ${o.colorSuccessBorder}`,fontWeight:500,lineHeight:"16px",display:"inline-flex",alignItems:"center",gap:4},children:i.compatibility})]})}),(i.createdAt||i.updatedAt)&&(0,e.jsx)("div",{style:{marginBottom:16},children:(0,e.jsxs)(B,{direction:"vertical",size:4,children:[i.createdAt&&(0,e.jsxs)(d,{style:{fontSize:11,color:o.colorTextTertiary,fontFamily:"monospace"},children:["Created: ",P(i.createdAt)]}),i.updatedAt&&(0,e.jsxs)(d,{style:{fontSize:11,color:o.colorTextTertiary,fontFamily:"monospace"},children:["Updated: ",P(i.updatedAt)]})]})}),i.content&&(0,e.jsxs)("div",{style:{marginBottom:0},children:[(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:8},children:[(0,e.jsx)(pe,{style:{fontSize:14,color:o.colorTextSecondary}}),(0,e.jsx)(d,{style:{fontSize:12,color:o.colorTextSecondary,fontWeight:600,letterSpacing:.5},children:s("chatWorkspace.skillNode.contentSection")})]}),(0,e.jsx)("div",{style:{padding:16,background:o.colorFillTertiary,border:`1px solid ${o.colorBorderSecondary}`,borderRadius:6,maxHeight:400,overflowY:"auto"},children:(0,e.jsx)(d,{style:{fontSize:12,color:o.colorText,lineHeight:1.7,whiteSpace:"pre-wrap",fontFamily:"monospace"},children:i.content})})]})]}),(0,e.jsx)(ie,{style:{margin:"16px 0"}}),(0,e.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8},children:z?(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(v,{block:!0,onClick:()=>{x(!1),n(g)},style:{flex:1},children:s("common.cancel")}),(0,e.jsx)(v,{type:"primary",block:!0,onClick:Be,loading:Q,style:{flex:1},children:s("common.save")})]}):(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(v,{type:"primary",block:!0,onClick:()=>x(!0),style:{flex:1},children:s("chatWorkspace.skillNode.edit")}),(0,e.jsx)(v,{danger:!0,onClick:t=>{t.stopPropagation(),H(t)},children:s("common.delete")}),(0,e.jsx)(v,{icon:(0,e.jsx)(ce,{}),onClick:()=>J(i.id),title:s("chatWorkspace.skillNode.copyId")})]})})]});return(0,e.jsxs)("div",{style:{position:"relative",padding:4,overflow:"visible"},children:[(0,e.jsx)(ee,{type:"source",position:Z.Top,style:{left:"50%",top:"50%",transform:"translate(-50%, -50%)",background:"transparent",border:"none",width:1,height:1,borderRadius:"50%",pointerEvents:"none"},isConnectable:!1}),(0,e.jsx)(ee,{type:"target",position:Z.Top,style:{left:"50%",top:"50%",transform:"translate(-50%, -50%)",background:"transparent",border:"none",width:1,height:1,borderRadius:"50%",pointerEvents:"none"},isConnectable:!1}),(0,e.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:6,cursor:"pointer",position:"relative"},onClick:()=>M(!0),children:[(0,e.jsx)("div",{style:{width:F,height:F,borderRadius:"50%",background:"#999",flexShrink:0,boxShadow:"0 1px 4px rgba(0,0,0,0.15)",transition:"transform 0.15s ease"},onMouseEnter:t=>{t.currentTarget.style.transform="scale(1.15)"},onMouseLeave:t=>{t.currentTarget.style.transform="scale(1)"}}),I&&(0,e.jsx)(d,{style:{position:"absolute",top:"100%",left:"50%",transform:"translateX(-50%)",marginTop:4,fontSize:10,color:o.colorTextSecondary,opacity:.45,whiteSpace:"nowrap",pointerEvents:"none",userSelect:"none"},children:i.name})]}),(0,e.jsx)(le,{open:$,onCancel:()=>{M(!1),x(!1),n({...i,id:i.name})},footer:null,width:z?1e3:760,destroyOnClose:!0,title:null,styles:{body:{padding:0}},children:Ie})]})},ze=Ee;var f=W(K()),De=({onNodeClick:b})=>{let s=q(),[o,w,Y]=ve([]),[N,I,G]=be([]),[g,D]=(0,h.useState)(!1),[S,i]=(0,h.useState)([]),[A,O]=(0,h.useState)(!1),[m,F]=(0,h.useState)(null),{token:X}=_.useToken(),{get:T}=V(),P=(0,h.useMemo)(()=>({skill:ze}),[]),J=(0,h.useMemo)(()=>m===null?o:o.map(n=>{let c=n.id===m||N.some(u=>u.source===m&&u.target===n.id||u.target===m&&u.source===n.id);return{...n,style:{opacity:c?1:.2,transition:"opacity 0.2s ease"}}}),[o,N,m]),z=(0,h.useMemo)(()=>m===null?N.map(n=>({...n,style:{stroke:"#1677ff",strokeWidth:1.5,opacity:.25,transition:"opacity 0.2s ease"}})):N.map(n=>{let c=n.source===m||n.target===m;return{...n,style:{stroke:"#1677ff",strokeWidth:c?2.5:1,opacity:c?1:.04,transition:"opacity 0.2s ease"}}}),[N,m]),x=async()=>{O(!0);try{let n=await T("/api/skills");n.success&&n.data&&Array.isArray(n.data.records)&&i(n.data.records)}catch(n){console.error("Failed to fetch skills:",n),i([])}finally{O(!1)}};(0,h.useEffect)(()=>{x()},[]),(0,h.useEffect)(()=>{if(!S||S.length===0){w([]),I([]);return}let n=[],c=new Map,u=[];S.forEach(l=>{c.set(l.name,l),l.subSkills&&l.subSkills.length>0&&l.subSkills.forEach(H=>{S.find(j=>j.name===H)&&u.push({source:l.name,target:H})})});let $=S.map(l=>({id:l.name})),M=u.map(l=>({source:l.source,target:l.target})),Q=ue($).force("link",me(M).id(l=>l.id).distance(80)).force("charge",ke().strength(-300)).force("center",fe(0,0)).force("collide",ge(30)).stop();for(let l=0;l<300;l++)Q.tick();let L=$.map(l=>({id:l.id,type:"skill",data:{skill:c.get(l.id),onClick:()=>b?.(c.get(l.id)),onDelete:x},position:{x:l.x,y:l.y}}));u.forEach(l=>{c.has(l.source)&&c.has(l.target)&&n.push({id:`e${l.source}-${l.target}`,source:l.source,target:l.target,style:{stroke:"#1677ff",strokeWidth:2},type:"straight"})}),w(L),I(n)},[S,w,I,b]);let p=async()=>{await x()};return A?(0,f.jsx)("div",{style:{width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",background:"#fafafa"},children:s("chat.skills.loading")}):(0,f.jsxs)("div",{style:{width:"100%",height:"100%",background:"#fafafa",position:"relative"},children:[(0,f.jsxs)(xe,{nodes:J,edges:z,onNodesChange:Y,onEdgesChange:G,onNodeMouseEnter:(n,c)=>F(c.id),onNodeMouseLeave:()=>F(null),nodeTypes:P,fitView:!0,children:[(0,f.jsx)(Te,{color:"#eee",gap:20}),(0,f.jsx)(Ce,{})]}),(0,f.jsx)("div",{style:{position:"absolute",top:20,right:20,zIndex:10},children:(0,f.jsx)(v,{type:"primary",size:"large",icon:(0,f.jsx)(U,{}),onClick:()=>D(!0),style:{height:48,width:48,borderRadius:"50%",boxShadow:X.boxShadowTertiary,display:"flex",alignItems:"center",justifyContent:"center",padding:0}})}),(0,f.jsx)(we,{open:g,onCancel:()=>D(!1),onSuccess:p})]})},Ae=b=>(0,f.jsx)(Se,{children:(0,f.jsx)(De,{...b})}),nt=Ae;export{nt as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as Ze}from"./embed-page-chunk-
|
|
1
|
+
import{a as Ze}from"./embed-page-chunk-HKFKNIOM.js";import{c as qe,d as Ke}from"./embed-page-chunk-FE6KYRCO.js";import{b as Ne,e as Ie,h as He,i as We}from"./embed-page-chunk-DJKD2PHO.js";import"./embed-page-chunk-S4XZPBRM.js";import{C as Ve,D as Ue,E as ue,F as Re,G as Ye,H as Qe,I as Je,K as Xe,L as et,M as tt,N as ot,r as Ge}from"./embed-page-chunk-JPRKPIYC.js";import{g as q,i as _e}from"./embed-page-chunk-4D5PY2CF.js";import"./embed-page-chunk-PY2HBRFF.js";import{l as Ee,o as Oe}from"./embed-page-chunk-RFN7O6VH.js";import{I as Fe,Qa as me,n as ce,ya as pe}from"./embed-page-chunk-F7ZUYG42.js";import{l as j}from"./embed-page-chunk-WR44MKDA.js";import{a as A}from"./embed-page-chunk-QV7QAJ4N.js";import"./embed-page-chunk-VW3NF5NT.js";import"./embed-page-chunk-34RWKVD7.js";import"./embed-page-chunk-B2KNZ3EW.js";import{Da as W,Ia as Ce,Ja as J,Ma as ze,Sa as le,Za as Me,_ as ae,aa as Be,ba as Le,bb as de,fa as be,va as De}from"./embed-page-chunk-F7TA3LRH.js";import{a as se}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-QOWM3LMZ.js";import"./embed-page-chunk-EUOOO2LS.js";import"./embed-page-chunk-5JDQ456X.js";import{f as T}from"./embed-page-chunk-QBTAJ2YI.js";var n=T(se());var it=T(se());var s=T(A()),Tt=[{key:"pending",color:"#7A7A7A"},{key:"in_progress",color:"#3b82f6"},{key:"failed",color:"#ef4444"},{key:"interrupted",color:"#8b5cf6"},{key:"completed",color:"#22c55e"}],rt={high:"#ef4444",medium:"#f59e0b",low:"#22c55e"};function bt(e){return e==="high"||e==="low"?e:"medium"}function Ct(e,i){let f=typeof e=="string"?new Date(e):e,a=new Date().getTime()-f.getTime(),k=Math.floor(a/1e3),o=Math.floor(k/60),r=Math.floor(o/60),l=Math.floor(r/24);return k<60?i("common.time.justNow"):o<60?i("common.time.minutesAgo",{count:o}):r<24?i("common.time.hoursAgo",{count:r}):l<30?i("common.time.daysAgo",{count:l}):f.toLocaleDateString(i.locale)}var Nt=q(({css:e,token:i})=>({container:e`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
height: 100%;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{k as ue,q as he}from"./embed-page-chunk-
|
|
1
|
+
import{k as ue,q as he}from"./embed-page-chunk-4D5PY2CF.js";import{o as oe}from"./embed-page-chunk-RFN7O6VH.js";import{Aa as le,L as ce,La as de,O as se,Wa as Ae}from"./embed-page-chunk-F7ZUYG42.js";import{l as re}from"./embed-page-chunk-WR44MKDA.js";import{a as ie}from"./embed-page-chunk-QV7QAJ4N.js";import"./embed-page-chunk-B2KNZ3EW.js";import{Ma as ae,Oa as C,W as d,Ya as L,Za as S,_ as u,ba as F,bb as c,qa as te,xa as ne,za as h}from"./embed-page-chunk-F7TA3LRH.js";import{a as Pe}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-EUOOO2LS.js";import{f as I}from"./embed-page-chunk-QBTAJ2YI.js";var a=I(Pe());var _=I(Ae());var t=I(ie());function f(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)}function Ee(r){if(!f(r))return;let e=r.checkpoint;if(f(e)&&typeof e.checkpoint_id=="string")return e.checkpoint_id;let o=r.config;if(f(o)&&f(o.configurable)){let s=o.configurable.checkpoint_id;if(typeof s=="string")return s}}function ze(r){if(!f(r))return;if(typeof r.createdAt=="string")return r.createdAt;let e=r.checkpoint;if(f(e)&&typeof e.ts=="string")return e.ts}function He(r){switch(r){case"pending":return"blue";case"running":return"processing";case"success":return"green";case"error":case"failed":case"timeout":return"red";case"interrupted":return"orange";default:return}}function Fe(r){return r==="pending"||r==="running"}function Le(r){return r<1024?`${r} B`:r<1024*1024?`${(r/1024).toFixed(1)} KB`:`${(r/(1024*1024)).toFixed(2)} MB`}var We=({data:r})=>{let e=re(),o=r?.threadId,s=r?.assistantId,l=oe(s||"__no_assistant__"),D=(0,a.useContext)(ue),{closeSideApp:pe}=he(),[m,ge]=(0,a.useState)(null),[T,ye]=(0,a.useState)(null),[fe,me]=(0,a.useState)([]),[Te,Me]=(0,a.useState)([]),[v,R]=(0,a.useState)(!0),[K,M]=(0,a.useState)(null),[Y,O]=(0,a.useState)(null),[p,J]=(0,a.useState)({}),[b,N]=(0,a.useState)(null),[xe,W]=(0,a.useState)(!1),[ke,B]=(0,a.useState)(""),[we,$]=(0,a.useState)(!1),[Ce,G]=(0,a.useState)(!1),[P,Ie]=(0,a.useState)(null),[U,V]=(0,a.useState)(!1),[A,j]=(0,a.useState)(5),E=(0,a.useRef)(0),x=(0,a.useRef)(0),g=(0,a.useCallback)(async()=>{if(!o||!s){R(!1);return}let n=++E.current;R(!0),J({});let[i,k,X,Z]=await Promise.allSettled([l.getThreadStatus(o),l.getThreadStorage(o),l.getThreadHistory(o,{limit:10}),l.runs.list(o,s)]);if(n!==E.current)return;let w={};i.status==="fulfilled"?ge(i.value):w.status=e("chat.threadMaintenance.statusLoadFailed"),k.status==="fulfilled"?ye(k.value):w.storage=e("chat.threadMaintenance.storageLoadFailed"),X.status==="fulfilled"?me(X.value.flatMap(H=>{let ee=Ee(H);return ee===void 0?[]:[{id:ee,createdAt:ze(H),raw:H}]})):w.history=e("chat.threadMaintenance.historyLoadFailed"),Z.status==="fulfilled"?Me(Z.value):w.runs=e("chat.threadMaintenance.runsLoadFailed"),J(w),R(!1)},[s,l,e,o]);(0,a.useEffect)(()=>(g(),()=>{E.current+=1}),[g]);let Se=async n=>{if(!o)return;let i=++x.current;W(!0),$(!0),B("");try{let k=await l.getThreadStateAtCheckpoint(o,n.id);i===x.current&&B(JSON.stringify(k,null,2))}catch{i===x.current&&B(e("chat.threadMaintenance.stateFailed"))}finally{i===x.current&&$(!1)}},ve=()=>{x.current+=1,W(!1)},Re=async()=>{if(o){G(!0),M(null);try{let n=await l.copyThread(o);Ie(n.id)}catch{M(e("chat.threadMaintenance.copyFailed"))}finally{G(!1)}}},q=async n=>{if(!o)return;V(!0),M(null);let i=Math.min(100,Math.max(1,Math.trunc(A)));j(i);try{if(!(await l.pruneThread(o,n==="delete"?{strategy:n}:{strategy:n,keep:i})).pruned){M(e("chat.threadMaintenance.pruneFailed"));return}if(n==="delete"){pe();return}await g()}catch{M(e("chat.threadMaintenance.pruneFailed"))}finally{V(!1)}},z=(0,a.useCallback)(async(n,i)=>{if(!(!o||!s)){N(n),O(null);try{await l.runs.cancel(o,n,{action:i},s),await g()}catch{O(e("chat.threadMaintenance.runCancelFailed"))}finally{N(null)}}},[s,l,g,e,o]),Q=m?.interrupts??[],be=(0,a.useMemo)(()=>[{title:e("chat.threadMaintenance.runStatus"),dataIndex:"status",render:n=>(0,t.jsx)(S,{color:He(n),children:n})},{title:e("chat.threadMaintenance.runId"),dataIndex:"runId",render:n=>(0,t.jsx)(c.Text,{code:!0,ellipsis:{tooltip:n},style:{maxWidth:180},children:n})},{title:e("chat.threadMaintenance.runCreated"),dataIndex:"createdAt",render:n=>(0,_.default)(n).format("YYYY-MM-DD HH:mm:ss")},{title:e("chat.threadMaintenance.runOwner"),key:"owner",render:(n,i)=>(0,t.jsxs)(h,{size:4,children:[(0,t.jsx)(c.Text,{children:i.owner??"\u2014"}),(0,t.jsx)(c.Text,{type:"secondary",children:"/"}),(0,t.jsx)(c.Text,{type:"secondary",children:i.attempts})]})},{key:"actions",render:(n,i)=>Fe(i.status)?(0,t.jsxs)(h,{size:4,children:[(0,t.jsx)(C,{title:e("chat.threadMaintenance.interruptRunConfirm"),okText:e("chat.threadMaintenance.interruptRun"),cancelText:e("common.cancel"),onConfirm:()=>void z(i.runId,"interrupt"),children:(0,t.jsx)(u,{size:"small",type:"link",loading:b===i.runId,children:e("chat.threadMaintenance.interruptRun")})}),(0,t.jsx)(C,{title:e("chat.threadMaintenance.rollbackRunConfirm"),okText:e("chat.threadMaintenance.rollbackRun"),cancelText:e("common.cancel"),onConfirm:()=>void z(i.runId,"rollback"),children:(0,t.jsx)(u,{size:"small",type:"link",danger:!0,loading:b===i.runId,children:e("chat.threadMaintenance.rollbackRun")})})]}):null}],[z,b,e]),Be=(0,a.useMemo)(()=>[{title:e("chat.threadMaintenance.checkpointId"),dataIndex:"id",render:n=>(0,t.jsx)(c.Text,{code:!0,children:n})},{title:e("chat.threadMaintenance.checkpointTime"),dataIndex:"createdAt",render:n=>n?(0,_.default)(n).format("YYYY-MM-DD HH:mm:ss"):e("chat.threadMaintenance.unknown")},{key:"actions",render:(n,i)=>(0,t.jsx)(u,{size:"small",type:"link",onClick:()=>void Se(i),children:e("chat.threadMaintenance.viewState")})}],[e]);return!o||!s?(0,t.jsx)(d,{type:"warning",showIcon:!0,message:e("chat.threadMaintenance.missingContext")}):(0,t.jsxs)(te,{title:(0,t.jsxs)(h,{children:[(0,t.jsx)(se,{size:16}),e("chat.threadMaintenance.title")]}),extra:(0,t.jsxs)(h,{wrap:!0,children:[(0,t.jsx)(u,{icon:(0,t.jsx)(le,{size:14}),onClick:()=>void g(),loading:v,children:e("common.refresh")}),(0,t.jsx)(u,{icon:(0,t.jsx)(ce,{size:14}),loading:Ce,onClick:()=>void Re(),children:e("chat.threadMaintenance.copy")})]}),children:[(0,t.jsxs)(h,{direction:"vertical",size:14,style:{width:"100%"},children:[K?(0,t.jsx)(d,{type:"error",showIcon:!0,message:K}):null,p.status?(0,t.jsx)(d,{type:"error",showIcon:!0,message:p.status}):null,p.storage?(0,t.jsx)(d,{type:"warning",showIcon:!0,message:p.storage}):null,p.history?(0,t.jsx)(d,{type:"warning",showIcon:!0,message:p.history}):null,p.runs?(0,t.jsx)(d,{type:"warning",showIcon:!0,message:p.runs}):null,P?(0,t.jsx)(d,{type:"success",showIcon:!0,message:e("chat.threadMaintenance.copySuccess",{id:P}),action:D?.selectThread?(0,t.jsx)(u,{size:"small",onClick:()=>D.selectThread(P),children:e("chat.threadMaintenance.switchToCopy")}):null}):null,(0,t.jsxs)(h,{wrap:!0,size:16,children:[(0,t.jsx)(y,{label:e("chat.threadMaintenance.status"),children:(0,t.jsx)(S,{color:m?.status==="idle"?"green":m?.status==="error"?"red":"blue",children:m?.status??e("chat.threadMaintenance.unknown")})}),(0,t.jsx)(y,{label:e("chat.threadMaintenance.pendingMessages"),children:m?.pendingMessages??0}),(0,t.jsx)(y,{label:e("chat.threadMaintenance.storage"),children:T?Le(T.totalBytes):e("chat.threadMaintenance.unknown")}),(0,t.jsx)(y,{label:e("chat.threadMaintenance.checkpoints"),children:T?.checkpoints.count??0}),(0,t.jsx)(y,{label:e("chat.threadMaintenance.channelValues"),children:T?.channelValues.count??0}),(0,t.jsx)(y,{label:e("chat.threadMaintenance.pendingWrites"),children:T?.pendingWrites.count??0})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Text,{strong:!0,children:e("chat.threadMaintenance.interrupts")}),(0,t.jsx)("div",{style:{marginTop:6},children:Q.length===0?(0,t.jsx)(c.Text,{type:"secondary",children:e("chat.threadMaintenance.noInterrupts")}):(0,t.jsx)(h,{wrap:!0,children:Q.map(n=>(0,t.jsxs)(S,{color:"orange",children:[n.type,": ",n.interruptId]},n.interruptId))})})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Text,{strong:!0,children:e("chat.threadMaintenance.runs")}),Y?(0,t.jsx)(d,{type:"error",showIcon:!0,message:Y,style:{marginTop:6}}):null,(0,t.jsx)(L,{rowKey:"runId",size:"small",columns:be,dataSource:Te,pagination:!1,loading:v,locale:{emptyText:(0,t.jsx)(F,{description:e("chat.threadMaintenance.noRuns")})}})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Text,{strong:!0,children:e("chat.threadMaintenance.history")}),(0,t.jsx)(L,{rowKey:"id",size:"small",columns:Be,dataSource:fe,pagination:!1,loading:v,locale:{emptyText:(0,t.jsx)(F,{description:e("chat.threadMaintenance.noHistory")})}})]}),(0,t.jsxs)(h,{wrap:!0,children:[(0,t.jsx)(C,{title:e("chat.threadMaintenance.pruneDeleteTitle"),description:e("chat.threadMaintenance.pruneDeleteConfirm"),okText:e("common.delete"),cancelText:e("common.cancel"),okButtonProps:{danger:!0},onConfirm:()=>void q("delete"),children:(0,t.jsx)(u,{danger:!0,icon:(0,t.jsx)(de,{size:14}),loading:U,children:e("chat.threadMaintenance.pruneDelete")})}),(0,t.jsx)(ne,{"aria-label":e("chat.threadMaintenance.keepLabel"),min:1,max:100,precision:0,step:1,value:A,onChange:n=>{j(typeof n=="number"?Math.min(100,Math.max(1,Math.trunc(n))):1)}}),(0,t.jsx)(C,{title:e("chat.threadMaintenance.pruneKeepTitle"),description:e("chat.threadMaintenance.pruneKeepConfirm",{count:A}),okText:e("chat.threadMaintenance.pruneKeepLatest"),cancelText:e("common.cancel"),onConfirm:()=>void q("keep_latest"),children:(0,t.jsx)(u,{loading:U,children:e("chat.threadMaintenance.pruneKeepLatest")})})]})]}),(0,t.jsx)(ae,{open:xe,title:e("chat.threadMaintenance.stateTitle"),footer:null,onCancel:ve,width:720,children:we?(0,t.jsx)(c.Text,{children:e("chat.threadMaintenance.loadingState")}):(0,t.jsx)("pre",{style:{maxHeight:"60vh",overflow:"auto",margin:0},children:ke})})]})},y=({label:r,children:e})=>(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Text,{type:"secondary",style:{display:"block",fontSize:12},children:r}),(0,t.jsx)(c.Text,{strong:!0,children:e})]});export{We as ThreadMaintenancePanel};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as ue,c as fe}from"./embed-page-chunk-
|
|
1
|
+
import{a as ue,c as fe}from"./embed-page-chunk-7XPK5RLA.js";import{a as xe}from"./embed-page-chunk-FE6KYRCO.js";import{a as ie,b as G,e as V,f as U,g as re,h as se,i as ae,k as le,l as de,m as ce,n as pe}from"./embed-page-chunk-DJKD2PHO.js";import"./embed-page-chunk-S4XZPBRM.js";import{j as O}from"./embed-page-chunk-JPRKPIYC.js";import"./embed-page-chunk-4D5PY2CF.js";import{a as j}from"./embed-page-chunk-PY2HBRFF.js";import"./embed-page-chunk-RFN7O6VH.js";import{A as oe,E as $,Pa as ne,g as te,ma as H,y as L}from"./embed-page-chunk-F7ZUYG42.js";import{l as N}from"./embed-page-chunk-WR44MKDA.js";import{a as D}from"./embed-page-chunk-QV7QAJ4N.js";import"./embed-page-chunk-VW3NF5NT.js";import"./embed-page-chunk-34RWKVD7.js";import{G as Q,Ma as ee}from"./embed-page-chunk-B2KNZ3EW.js";import{Ja as M,Ka as K,Oa as Z,Sa as X,Za as I,ba as P,bb as q,ha as B,ya as J,za as F}from"./embed-page-chunk-F7TA3LRH.js";import{a as Y}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-QOWM3LMZ.js";import"./embed-page-chunk-EUOOO2LS.js";import"./embed-page-chunk-5JDQ456X.js";import{f as T}from"./embed-page-chunk-QBTAJ2YI.js";var s=T(Y());var _=T(xe());var ge=T(Y());var ye=T(D()),me=({steps:t,graphDefinition:o,assistantId:r})=>{let n=(0,ge.useMemo)(()=>fe(o),[o]);return(0,ye.jsx)(ue,{dsl:n,steps:t,assistantId:r})};var e=T(D()),ve=`
|
|
2
2
|
@keyframes spin {
|
|
3
3
|
from { transform: rotate(0deg); }
|
|
4
4
|
to { transform: rotate(360deg); }
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{a as $e,b as Ue}from"./embed-page-chunk-
|
|
1
|
+
import{a as $e,b as Ue}from"./embed-page-chunk-VQMQROAS.js";import{b as Xe,c as me}from"./embed-page-chunk-7XPK5RLA.js";import"./embed-page-chunk-FE6KYRCO.js";import{f as Ye}from"./embed-page-chunk-DJKD2PHO.js";import"./embed-page-chunk-S4XZPBRM.js";import{T as Ge,j as Ke}from"./embed-page-chunk-JPRKPIYC.js";import{i as te}from"./embed-page-chunk-4D5PY2CF.js";import{a as ne}from"./embed-page-chunk-PY2HBRFF.js";import"./embed-page-chunk-RFN7O6VH.js";import{Ea as q,Ha as fe,I as ce,Ja as qe,O as pe,Ra as ue,Sa as ee,Ta as He,Y as je,_ as Ee,aa as ge,fa as _e,ia as Fe,l as Oe,na as Be,o as de,t as Pe,za as Ne}from"./embed-page-chunk-F7ZUYG42.js";import{l as O}from"./embed-page-chunk-WR44MKDA.js";import{a as j}from"./embed-page-chunk-QV7QAJ4N.js";import"./embed-page-chunk-VW3NF5NT.js";import"./embed-page-chunk-34RWKVD7.js";import{Ba as De,G as Te,Ja as le,Ra as Le,sa as Me}from"./embed-page-chunk-B2KNZ3EW.js";import{Da as J,Ia as V,Ja as ae,Ma as Q,Oa as Ae,W as ze,_ as $,ba as U,bb as Z,ha as X,qa as Ie}from"./embed-page-chunk-F7TA3LRH.js";import{a as se}from"./embed-page-chunk-R5QL57JJ.js";import"./embed-page-chunk-QOWM3LMZ.js";import"./embed-page-chunk-EUOOO2LS.js";import"./embed-page-chunk-5JDQ456X.js";import{f as I}from"./embed-page-chunk-QBTAJ2YI.js";var i=I(se());var oe=I(se());var P=I(j());function ft(r){let o=r.split(/[\n\r.。;;!!??]+/).filter(Boolean)[0]?.trim()||"";return o=o.replace(/[,,]+$/,"").trim(),o.length>50&&(o=o.slice(0,50)),o||(o=r.slice(0,50).trim()),o}function ut(r){let e=5381;for(let o=0;o<r.length;o++)e=(e<<5)+e+r.charCodeAt(o)>>>0;return e.toString(36).slice(0,6)}var be=({open:r,onCancel:e,onCreated:o})=>{let{post:w}=ne(),v=O(),{trainingProjects:d,loading:u}=te(),[y,p]=(0,oe.useState)(null),[g]=J.useForm(),b=d.find(h=>h.id===y)??d[0]??null;(0,oe.useEffect)(()=>{r&&(g.resetFields(),p(null))},[r,g]);let R=async()=>{if(!b)return;let m=((await g.validateFields()).purpose||"").trim(),A=ft(m),z=`wf-${ut(m+Date.now())}`,E={key:z,name:A,description:m,type:"workflow",prompt:"Complete the assigned task accurately and concisely.",metadata:{trainingProjectId:b?.id},workflowYaml:`name: ${z}
|
|
2
2
|
steps: []
|
|
3
3
|
`};await w("/api/assistants",{id:z,name:A,description:m,graphDefinition:E}),g.resetFields(),o(z,m,b?.id)};return(0,P.jsx)(Q,{title:v("chatConfig.workflow.create.title"),open:r,onCancel:e,onOk:R,okText:v("common.create"),okButtonProps:{disabled:u||!b},destroyOnClose:!0,children:(0,P.jsxs)(J,{form:g,layout:"vertical",initialValues:{purpose:""},children:[(0,P.jsx)(J.Item,{name:"purpose",label:v("chatConfig.workflow.field.purpose"),rules:[{required:!0,message:v("chatConfig.workflow.validation.purposeRequired")}],children:(0,P.jsx)(V.TextArea,{placeholder:v("chatConfig.workflow.field.purposePlaceholder"),rows:4})}),(0,P.jsx)($e,{project:b,value:b?.id??null,onChange:p,loading:u})]})})};var Qe=I(se());var t=I(j()),{Text:ye}=Z;function mt(r){if(!r||typeof r!="object")return null;let e=r;return{modelKey:e.modelKey||e.model||void 0,tools:Array.isArray(e.tools)?e.tools:[],middleware:Array.isArray(e.middleware)?e.middleware.filter(o=>o&&typeof o=="object"&&o.type):[],subAgents:Array.isArray(e.subAgents)?e.subAgents:[],skillCategories:Array.isArray(e.skillCategories)?e.skillCategories:[],runConfig:e.runConfig&&typeof e.runConfig=="object"?e.runConfig:void 0}}var bt={filesystem:(0,t.jsx)(je,{size:12}),code_eval:(0,t.jsx)(qe,{size:12}),browser:(0,t.jsx)(ge,{size:12}),sql:(0,t.jsx)(pe,{size:12}),skill:(0,t.jsx)(fe,{size:12}),http:(0,t.jsx)(Fe,{size:12}),scheduler:(0,t.jsx)(ce,{size:12}),metrics:(0,t.jsx)(Oe,{size:12}),ask_user_to_clarify:(0,t.jsx)(Be,{size:12}),widget:(0,t.jsx)(de,{size:12}),date:(0,t.jsx)(Pe,{size:12}),task:(0,t.jsx)(Ee,{size:12}),custom:(0,t.jsx)(Ne,{size:12}),claw:(0,t.jsx)(q,{size:12}),collection:(0,t.jsx)(_e,{size:12})},yt={filesystem:{bg:"rgba(34,197,94,0.08)",text:"#16a34a",border:"rgba(34,197,94,0.2)"},code_eval:{bg:"rgba(99,102,241,0.08)",text:"#4f46e5",border:"rgba(99,102,241,0.2)"},browser:{bg:"rgba(59,130,246,0.08)",text:"#2563eb",border:"rgba(59,130,246,0.2)"},sql:{bg:"rgba(249,115,22,0.08)",text:"#ea580c",border:"rgba(249,115,22,0.2)"},skill:{bg:"rgba(168,85,247,0.08)",text:"#9333ea",border:"rgba(168,85,247,0.2)"},http:{bg:"rgba(20,184,166,0.08)",text:"#0d9488",border:"rgba(20,184,166,0.2)"},scheduler:{bg:"rgba(245,158,11,0.08)",text:"#d97706",border:"rgba(245,158,11,0.2)"},metrics:{bg:"rgba(236,72,153,0.08)",text:"#db2777",border:"rgba(236,72,153,0.2)"},ask_user_to_clarify:{bg:"rgba(245,158,11,0.08)",text:"#d97706",border:"rgba(245,158,11,0.2)"},widget:{bg:"rgba(20,184,166,0.08)",text:"#0d9488",border:"rgba(20,184,166,0.2)"},date:{bg:"rgba(139,92,246,0.08)",text:"#7c3aed",border:"rgba(139,92,246,0.2)"},task:{bg:"rgba(99,102,241,0.08)",text:"#4f46e5",border:"rgba(99,102,241,0.2)"},custom:{bg:"rgba(107,114,128,0.08)",text:"#4b5563",border:"rgba(107,114,128,0.2)"},claw:{bg:"rgba(107,114,128,0.08)",text:"#4b5563",border:"rgba(107,114,128,0.2)"},collection:{bg:"rgba(6,182,212,0.08)",text:"#0891b2",border:"rgba(6,182,212,0.2)"}},wt={bg:"rgba(107,114,128,0.08)",text:"#4b5563",border:"rgba(107,114,128,0.2)"};function ht(r){let e=r.split(/[_-]+/).filter(Boolean);return e.length===1?e[0].slice(0,2).toUpperCase():e.map(o=>o[0]).join("").toUpperCase().slice(0,2)}var Je=[{bg:"rgba(99,102,241,0.1)",text:"#6366f1"},{bg:"rgba(34,197,94,0.1)",text:"#22c55e"},{bg:"rgba(245,158,11,0.1)",text:"#f59e0b"},{bg:"rgba(59,130,246,0.1)",text:"#3b82f6"},{bg:"rgba(239,68,68,0.1)",text:"#ef4444"},{bg:"rgba(168,85,247,0.1)",text:"#a855f7"},{bg:"rgba(20,184,166,0.1)",text:"#14b8a6"},{bg:"rgba(236,72,153,0.1)",text:"#ec4899"}];function Ve(r){return Je[r%Je.length]}var H=({icon:r,label:e,count:o,children:w})=>(0,t.jsxs)("div",{style:{marginBottom:10},children:[(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:6,marginBottom:6},children:[(0,t.jsx)("span",{style:{color:"#6366f1",display:"flex",alignItems:"center"},children:r}),(0,t.jsx)(ye,{strong:!0,style:{fontSize:11,color:"#52525b",textTransform:"uppercase",letterSpacing:"0.3px"},children:e}),(0,t.jsx)("span",{style:{fontSize:9,fontWeight:600,color:"#a1a1aa",background:"rgba(0,0,0,0.04)",borderRadius:8,padding:"1px 6px",lineHeight:"16px"},children:o})]}),w]}),Ze=({graphDef:r})=>{let e=O(),o=(0,Qe.useMemo)(()=>mt(r),[r]);if(!o)return null;let w=o.middleware.filter(d=>d.enabled!==!1),v=!1;return o.tools.length===0&&w.length===0&&o.subAgents.length===0?null:(0,t.jsx)("div",{style:{pointerEvents:"auto"},children:(0,t.jsxs)("div",{style:{background:"rgba(255,255,255,0.5)",borderRadius:8,width:250,transition:"all 0.25s ease",overflow:"hidden"},children:[(0,t.jsx)("div",{style:{display:"flex",alignItems:"center",gap:8,padding:"8px 12px",background:"rgba(99,102,241,0.02)",borderBottom:"1px solid rgba(0,0,0,0.03)"},children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8},children:[(0,t.jsx)("div",{style:{width:24,height:24,borderRadius:6,background:"rgba(99,102,241,0.05)",display:"flex",alignItems:"center",justifyContent:"center",color:"#6366f1"},children:(0,t.jsx)(q,{size:13})}),(0,t.jsx)(ye,{strong:!0,style:{fontSize:12,color:"#1a1a1a"},children:e("chat.environment.title")})]})}),(0,t.jsxs)("div",{style:{padding:"10px 12px 12px",maxHeight:"calc(60vh - 48px)",overflowY:"auto"},children:[o.tools.length>0&&(0,t.jsx)(H,{icon:(0,t.jsx)(He,{size:12}),label:e("chat.environment.tools"),count:o.tools.length,children:(0,t.jsx)("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:o.tools.map((d,u)=>{let y=Ve(u);return(0,t.jsx)(X,{title:d,placement:"top",children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:4,padding:"3px 8px",borderRadius:6,fontSize:10,fontWeight:500,color:y.text,background:y.bg,cursor:"default",whiteSpace:"nowrap",lineHeight:"16px"},children:[(0,t.jsx)("span",{style:{fontWeight:700,fontSize:9,opacity:.7},children:ht(d)}),(0,t.jsx)("span",{children:d})]})},d)})})}),w.length>0&&(0,t.jsx)(H,{icon:(0,t.jsx)(de,{size:12}),label:e("chat.environment.capabilities"),count:w.length,children:(0,t.jsx)("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:w.map(d=>{let u=yt[d.type]||wt,y=bt[d.type]||(0,t.jsx)(q,{size:12});return(0,t.jsx)(X,{title:d.name||d.type,placement:"top",children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:4,padding:"3px 8px",borderRadius:6,fontSize:10,fontWeight:500,color:u.text,background:u.bg,border:`1px solid ${u.border}`,cursor:"default",whiteSpace:"nowrap",lineHeight:"16px"},children:[y,(0,t.jsx)("span",{children:d.name||d.type})]})},d.type)})})}),o.subAgents.length>0&&(0,t.jsx)(H,{icon:(0,t.jsx)(ue,{size:12}),label:e("chat.environment.subAgents"),count:o.subAgents.length,children:(0,t.jsx)("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:o.subAgents.map((d,u)=>{let y=Ve(u+3);return(0,t.jsx)(X,{title:d,placement:"top",children:(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:4,padding:"3px 8px",borderRadius:6,fontSize:10,fontWeight:500,color:y.text,background:y.bg,cursor:"default",whiteSpace:"nowrap",lineHeight:"16px"},children:[(0,t.jsx)(ue,{size:10}),(0,t.jsx)("span",{children:d})]})},d)})})}),(o.modelKey||o.runConfig)&&(0,t.jsx)(H,{icon:(0,t.jsx)(ce,{size:12}),label:e("chat.environment.runtime"),count:o.modelKey?1:0,children:(0,t.jsxs)("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:[o.modelKey&&(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:4,padding:"3px 8px",borderRadius:6,fontSize:10,fontWeight:500,color:"#4f46e5",background:"rgba(99,102,241,0.08)",border:"1px solid rgba(99,102,241,0.2)",cursor:"default",whiteSpace:"nowrap",lineHeight:"16px"},children:[(0,t.jsx)(q,{size:10}),(0,t.jsx)("span",{children:e("chat.environment.model",{model:o.modelKey})})]}),!!o.runConfig?.databaseKey&&(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:4,padding:"3px 8px",borderRadius:6,fontSize:10,fontWeight:500,color:"#ea580c",background:"rgba(249,115,22,0.08)",border:"1px solid rgba(249,115,22,0.2)",cursor:"default",whiteSpace:"nowrap",lineHeight:"16px"},children:[(0,t.jsx)(pe,{size:10}),(0,t.jsx)("span",{children:e("chat.environment.db",{db:String(o.runConfig?.databaseKey)})})]}),o.skillCategories&&o.skillCategories.length>0&&(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:4,padding:"3px 8px",borderRadius:6,fontSize:10,fontWeight:500,color:"#9333ea",background:"rgba(168,85,247,0.08)",border:"1px solid rgba(168,85,247,0.2)",cursor:"default",whiteSpace:"nowrap",lineHeight:"16px"},children:[(0,t.jsx)(fe,{size:10}),(0,t.jsx)("span",{children:e("chat.environment.skills",{skills:o.skillCategories.join(", ")})})]})]})}),v&&(0,t.jsx)(H,{icon:(0,t.jsx)(ge,{size:12}),label:e("chat.environment.channels"),count:0,children:(0,t.jsx)(ye,{type:"secondary",style:{fontSize:10,fontStyle:"italic"},children:e("chat.environment.noChannels")})})]})]})})};var n=I(j()),{Text:K}=Z,xt=300;function et(r){if(typeof r=="string")try{let e=JSON.parse(r);return e&&typeof e=="object"&&!Array.isArray(e)?e:null}catch{return null}return r&&typeof r=="object"&&!Array.isArray(r)?r:null}function kt(r){let e=null;if(typeof r=="string")try{e=JSON.parse(r)}catch{return null}else r&&typeof r=="object"&&(e=r);if(!e)return null;if(e.type!=="workflow")return console.warn("[extractDSL] type is not 'workflow':",e.type),null;if(typeof e.workflowYaml!="string")return console.warn("[extractDSL] workflowYaml not found or not a string, keys:",Object.keys(e)),null;try{return me(e.workflowYaml)}catch(o){return console.error("[extractDSL] expandWorkflow failed:",o.message,o),null}}function vt({workflows:r,selectedId:e,onSelect:o,onCreate:w,onDelete:v,dsl:d,agentNameMap:u,onSpecClick:y,environmentConfig:p}){let g=O(),b=r.find(f=>f.id===e),[R,h]=(0,i.useState)(!0),[m,A]=(0,i.useState)(""),z=(0,i.useMemo)(()=>{let f=m.trim().toLowerCase();return f?r.filter(C=>C.name.toLowerCase().includes(f)||C.description.toLowerCase().includes(f)):r},[r,m]);(0,i.useEffect)(()=>{e?h(!1):(h(!0),A(""))},[e]);let E=f=>{o(f),h(!1)};return(0,n.jsx)("div",{style:{display:"flex",height:"100%",width:"100%"},children:(0,n.jsxs)("div",{style:{flex:1,position:"relative"},children:[b?(0,n.jsxs)(n.Fragment,{children:[d?(0,n.jsx)(Xe,{dsl:d,agentNameMap:u}):(0,n.jsx)("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%"},children:(0,n.jsx)(ae,{tip:g("chatWorkspace.workflowAutomation.loadingDsl")})}),!R&&(0,n.jsx)("div",{style:{position:"absolute",top:12,left:12,zIndex:10},children:(0,n.jsx)($,{type:"default",icon:(0,n.jsx)(De,{}),onClick:()=>h(!0),style:{width:32,height:32,borderRadius:10,boxShadow:"0 2px 12px rgba(0,0,0,0.08)",border:"1px solid #f0f0f0",background:"rgba(255,255,255,0.95)",color:"#6366f1",display:"flex",alignItems:"center",justifyContent:"center"}})}),(0,n.jsxs)("div",{style:{position:"absolute",top:12,left:R?12:56,zIndex:10,display:"flex",alignItems:"center",gap:6,height:32,padding:"0 14px",background:"rgba(255,255,255,0.95)",borderRadius:10,boxShadow:"0 2px 12px rgba(0,0,0,0.08)",border:"1px solid #f0f0f0"},children:[(0,n.jsx)(ee,{size:16,color:"#6366f1"}),(0,n.jsx)(K,{strong:!0,style:{fontSize:13},children:b.name}),(0,n.jsx)(Me,{style:{color:"#6366f1",cursor:"pointer",fontSize:15},onClick:y})]}),(0,n.jsx)("div",{style:{position:"absolute",top:12,right:12,zIndex:10,display:"flex",alignItems:"center",height:32,padding:"0 14px",background:"rgba(255,255,255,0.95)",borderRadius:10,boxShadow:"0 2px 12px rgba(0,0,0,0.08)",border:"1px solid #f0f0f0"},children:(0,n.jsx)(Ae,{title:g("chatWorkspace.workflowAutomation.deleteTitle"),description:g("chatWorkspace.workflowAutomation.deleteBody"),onConfirm:()=>v(b.id),okText:g("common.delete"),cancelText:g("common.cancel"),okButtonProps:{danger:!0},children:(0,n.jsx)(Te,{style:{color:"#ff4d4f",cursor:"pointer",fontSize:15}})})}),!R&&(0,n.jsx)("div",{style:{position:"absolute",top:52,left:R?12:56,zIndex:20},children:(0,n.jsx)(Ze,{graphDef:p},b.id)})]}):(0,n.jsx)("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%"},children:(0,n.jsx)(U,{description:g("chatWorkspace.workflowAutomation.selectWorkflow")})}),R&&(0,n.jsxs)(n.Fragment,{children:[e&&(0,n.jsx)("div",{onClick:()=>h(!1),style:{position:"absolute",inset:0,zIndex:25,background:"transparent"}}),(0,n.jsxs)(Ie,{size:"small",title:(0,n.jsx)(K,{strong:!0,style:{fontSize:15,color:"#1a1a1a"},children:g("chatWorkspace.workflowAutomation.title")}),extra:(0,n.jsx)($,{type:"text",size:"small",icon:(0,n.jsx)(le,{}),onClick:w,style:{color:"#6366f1"}}),styles:{body:{padding:"12px 16px 16px"},header:{padding:"14px 16px 10px",borderBottom:"1px solid rgba(0,0,0,0.04)"}},style:{position:"absolute",left:16,top:e?56:48,bottom:16,width:300,zIndex:30,borderRadius:16,boxShadow:"0 4px 24px rgba(0,0,0,0.12)",border:"1px solid #f0f0f0",overflow:"auto",background:"rgba(255, 255, 255, 0.92)"},children:[(0,n.jsx)("div",{style:{marginBottom:12},children:(0,n.jsx)(V,{prefix:(0,n.jsx)(Le,{style:{color:"#bbb"}}),placeholder:g("chatWorkspace.workflowAutomation.filterPlaceholder"),value:m,onChange:f=>A(f.target.value),allowClear:!0,size:"small",style:{borderRadius:10,border:"1px solid rgba(0,0,0,0.06)"}})}),z.length===0?(0,n.jsxs)("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",padding:"32px 16px",color:"#bbb"},children:[(0,n.jsx)(ee,{size:28,style:{marginBottom:10,opacity:.4}}),(0,n.jsx)(K,{type:"secondary",style:{fontSize:13},children:m.trim()?g("chatWorkspace.workflowAutomation.noMatch"):g("chatWorkspace.workflowAutomation.emptyTitle")})]}):z.map(f=>{let C=e===f.id;return(0,n.jsxs)("div",{onClick:()=>E(f.id),style:{display:"flex",alignItems:"center",gap:12,padding:"13px 15px",borderRadius:12,cursor:"pointer",transition:"all 0.2s ease",background:C?"rgba(99, 102, 241, 0.07)":"rgba(255, 255, 255, 0.5)",border:C?"1px solid rgba(99, 102, 241, 0.25)":"1px solid transparent",marginBottom:6},onMouseEnter:S=>{C||(S.currentTarget.style.background="rgba(255, 255, 255, 0.92)",S.currentTarget.style.boxShadow="0 2px 8px rgba(0,0,0,0.05)",S.currentTarget.style.transform="translateY(-1px)",S.currentTarget.style.borderColor="rgba(0,0,0,0.06)")},onMouseLeave:S=>{C||(S.currentTarget.style.background="rgba(255, 255, 255, 0.5)",S.currentTarget.style.boxShadow="none",S.currentTarget.style.transform="translateY(0)",S.currentTarget.style.borderColor="transparent")},children:[(0,n.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",width:38,height:38,borderRadius:10,background:C?"rgba(99, 102, 241, 0.12)":"rgba(0, 0, 0, 0.04)",flexShrink:0,transition:"background 0.2s ease"},children:(0,n.jsx)(ee,{size:18,color:C?"#6366f1":"#888"})}),(0,n.jsxs)("div",{style:{flex:1,minWidth:0},children:[(0,n.jsx)(K,{strong:!0,ellipsis:{tooltip:f.name},style:{fontSize:14,color:C?"#6366f1":"#1a1a1a",transition:"color 0.2s ease"},children:f.name}),f.description&&(0,n.jsx)("div",{style:{fontSize:12,color:"#999",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",marginTop:3,lineHeight:"18px"},children:f.description})]})]},f.id)})]})]})]})})}var Ct=()=>{let r=O(),{get:e,del:o}=ne(),{workspaceId:w,trainingProjects:v,loading:d}=te(),[u,y]=(0,i.useState)([]),[p,g]=(0,i.useState)(null),[b,R]=(0,i.useState)(null),[h,m]=(0,i.useState)(null),[A,z]=(0,i.useState)([]),[E,f]=(0,i.useState)(new Map),C=(0,i.useCallback)(async()=>{try{let s=await e("/api/assistants");if(s.success&&s.data?.records){let c=[],a=new Map;for(let l of s.data.records){if(l.id&&l.name){let x=typeof l.graphDefinition=="object"&&l.graphDefinition!==null?l.graphDefinition:void 0;a.set(l.id,{name:l.name,type:x?.type??"unknown"})}if(l.graphDefinition)if(typeof l.graphDefinition=="string")try{c.push(JSON.parse(l.graphDefinition))}catch{}else typeof l.graphDefinition=="object"&&c.push(l.graphDefinition)}z(c),f(a)}}catch{}},[e]),[S,we]=(0,i.useState)(!0),[re,tt]=(0,i.useState)(420),_=(0,i.useRef)(null),[nt,ot]=(0,i.useState)(!0),[he,xe]=(0,i.useState)(null),[rt,ke]=(0,i.useState)(!1),[ve,F]=(0,i.useState)(!1),[it,Ce]=(0,i.useState)(null),st=(0,i.useMemo)(()=>["create_workflow","update_workflow","validate_workflow","create_agent","update_agent","delete_agent"],[]),T=(0,i.useCallback)(async()=>{let s=await e("/api/assistants");if(s.success&&s.data?.records){let c=s.data.records.filter(a=>(et(a.graphDefinition)??void 0)?.type==="workflow").map(a=>{let l=et(a.graphDefinition)??void 0,x=typeof l?.workflowYaml=="string"?l.workflowYaml:"",B=l?.metadata,N=0;try{N=me(x).nodes.filter(W=>W.type!=="terminal").length}catch{}return{id:a.id,name:a.name,description:a.description||"",type:"workflow",stepCount:N,trainingProjectId:typeof B?.trainingProjectId=="string"?B.trainingProjectId:void 0}});y(c)}xe(null)},[e]),Y=(0,i.useCallback)(async s=>{try{let c=await e(`/api/assistants/${s}`);if(c.success&&c.data){let a=c.data.graphDefinition,l=kt(a);if(R(l),!a)m(null);else if(typeof a=="string")try{m(JSON.parse(a))}catch{m(null)}else m(typeof a=="object"?a:null)}}catch{R(null),m(null)}},[e]);(0,i.useEffect)(()=>{let s=!1;return(async()=>{try{await T(),await C()}catch(a){s||xe(a instanceof Error?a.message:r("chatWorkspace.workflowAutomation.loadFailed"))}finally{s||ot(!1)}})(),()=>{s=!0}},[T]),(0,i.useEffect)(()=>{p?Y(p):R(null)},[p,Y]);let at=(0,i.useCallback)(s=>{s.preventDefault(),_.current={startX:s.clientX,startWidth:re}},[re]);(0,i.useEffect)(()=>{let s=a=>{if(!_.current)return;let l=_.current.startX-a.clientX,x=Math.min(900,Math.max(400,_.current.startWidth+l));tt(x)},c=()=>{_.current=null};return window.addEventListener("mousemove",s),window.addEventListener("mouseup",c),()=>{window.removeEventListener("mousemove",s),window.removeEventListener("mouseup",c)}},[]);let D=(0,i.useRef)(null),Se=(0,i.useRef)({fetchWorkflows:T,fetchDSL:Y});Se.current={fetchWorkflows:T,fetchDSL:Y};let Re=(0,i.useRef)(p);Re.current=p;let lt=(0,i.useCallback)(()=>{D.current&&clearTimeout(D.current),D.current=setTimeout(()=>{D.current=null;let{fetchWorkflows:s,fetchDSL:c}=Se.current;s().catch(l=>{console.warn("Failed to refresh workflows:",l)});let a=Re.current;a&&c(a).catch(l=>{console.warn("Failed to refresh workflow DSL:",l)})},xt)},[]);(0,i.useEffect)(()=>()=>{D.current&&(clearTimeout(D.current),D.current=null)},[]);let dt=(0,i.useCallback)(s=>{g(s)},[]),We=(0,i.useCallback)((s,c,a)=>{F(!1),T().then(()=>{g(s),a&&y(l=>l.map(x=>x.id===s?{...x,trainingProjectId:a}:x)),c&&Ce({requestId:s,content:c})})},[T]),ct=(0,i.useCallback)(async s=>{await o(`/api/assistants/${s}`),p===s&&g(null),await T()},[o,T,p]),L=(0,i.useMemo)(()=>u.find(s=>s.id===p)||null,[u,p]),G=L?.trainingProjectId??v[0]?.id??null,pt=(0,i.useMemo)(()=>p&&L?{id:p,name:L.name,type:"workflow"}:null,[p,L]),gt=(0,i.useMemo)(()=>{let s=b?.nodes.filter(k=>k.type!=="terminal"&&k.ref).map(k=>k.ref).filter((k,W,M)=>M.indexOf(k)===W)??[];if(s.length===0)return h;let c=A.filter(k=>{let W=k.key;return W&&s.includes(W)});if(c.length===0)return h;let a={...h??{}},l=new Set(a.tools??[]),x=[...a.middleware??[]],B=new Set(a.subAgents??[]),N=new Set(x.map(k=>k.type).filter(Boolean));for(let k of c){let W=k;for(let M of W.tools??[])l.add(M);for(let M of W.middleware??[]){let ie=M.type;ie&&!N.has(ie)&&(x.push(M),N.add(ie))}for(let M of W.subAgents??[])B.add(M)}return a.tools=Array.from(l),a.middleware=x,a.subAgents=Array.from(B),a},[b,h,A]);return nt?(0,n.jsx)("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%"},children:(0,n.jsx)(ae,{size:"large",tip:r("chatWorkspace.workflowAutomation.loading")})}):he?(0,n.jsx)(U,{description:he}):u.length===0?(0,n.jsxs)("div",{style:{width:"100%",height:"100%"},children:[(0,n.jsx)(be,{open:ve,onCancel:()=>F(!1),onCreated:We}),(0,n.jsx)(U,{description:r("chatWorkspace.workflowAutomation.noDefinitions"),children:(0,n.jsx)($,{type:"primary",icon:(0,n.jsx)(le,{}),onClick:()=>F(!0),children:r("chatWorkspace.workflowAutomation.createWorkflow")})})]}):(0,n.jsxs)("div",{style:{width:"100%",height:"100%"},children:[(0,n.jsx)(be,{open:ve,onCancel:()=>F(!1),onCreated:We}),(0,n.jsx)(Q,{title:L?.name,open:rt,onCancel:()=>ke(!1),footer:null,width:"85vw",centered:!0,styles:{body:{maxHeight:"calc(85vh - 120px)",overflow:"auto",padding:"12px 24px 24px"}},children:L?.description?(0,n.jsx)(Ke,{content:L.description}):(0,n.jsx)(K,{type:"secondary",children:r("chatWorkspace.workflowAutomation.noDescription")})}),(0,n.jsx)(Ye,{children:(0,n.jsxs)("div",{style:{height:"100%",width:"100%",position:"relative",overflow:"hidden"},children:[v.length===0&&!d&&(0,n.jsx)(ze,{type:"warning",showIcon:!0,style:{position:"absolute",top:48,left:"clamp(16px, 32vw, 332px)",right:16,zIndex:40,margin:0},message:r("governance.learning.noProject"),description:r("governance.learning.noProjectDescription")}),(0,n.jsx)(vt,{workflows:u,selectedId:p,onSelect:dt,onCreate:()=>F(!0),onDelete:ct,dsl:b,agentNameMap:E,onSpecClick:()=>ke(!0),environmentConfig:gt}),!S&&p&&G&&(0,n.jsx)("div",{style:{position:"absolute",right:0,top:"50%",transform:"translateY(-50%)",zIndex:20},children:(0,n.jsx)("div",{onClick:()=>we(!0),style:{writingMode:"vertical-rl",textOrientation:"mixed",padding:"16px 8px",background:"#6366f1",color:"#fff",borderRadius:"8px 0 0 8px",cursor:"pointer",fontSize:12,fontWeight:500,userSelect:"none"},children:r("chatWorkspace.workflowAutomation.copilot")})}),S&&p&&G&&!d&&(0,n.jsxs)("div",{style:{position:"absolute",right:16,top:48,bottom:12,zIndex:15,width:re,borderRadius:16,overflow:"hidden",boxShadow:"0 4px 24px rgba(0,0,0,0.12)"},children:[(0,n.jsx)("div",{onMouseDown:at,style:{position:"absolute",left:0,top:0,bottom:0,width:6,cursor:"ew-resize",zIndex:2,background:"transparent"}}),(0,n.jsx)(Ge,{defaultWorkspaceId:w??void 0,defaultProjectId:G??void 0,children:(0,n.jsx)(Ue,{workflowContext:pt,onClose:()=>we(!1),onToolCompleted:s=>{st.includes(s)&<()},initialMessageRequest:it,onInitialMessageSubmitted:s=>Ce(c=>c?.requestId===s?null:c)})},`${w??"default"}:${G??"default"}`)]})]})})]})},Zt=Ct;export{Ct as WorkflowAutomationView,Zt as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{f as Nr,h as Lr,j as zr,l as we,o as xt,t as yt}from"./embed-page-chunk-3PGODDQW.js";import{b as jr,l as Ce}from"./embed-page-chunk-5GAHI45T.js";import{a as B}from"./embed-page-chunk-QV7QAJ4N.js";import{La as Mr,M as ht,Ma as Ir,N as ae,Na as Fr,O as We,P as Er,Q as Ie,R as A,U as Rr,V as $r,_a as Fe,b as Pr,bb as gt,j as Ar,o as kr}from"./embed-page-chunk-F7TA3LRH.js";import{a as z}from"./embed-page-chunk-R5QL57JJ.js";import{c as Jt,f as y}from"./embed-page-chunk-QBTAJ2YI.js";var Po=Jt(W=>{"use strict";var Z=typeof Symbol=="function"&&Symbol.for,nr=Z?Symbol.for("react.element"):60103,sr=Z?Symbol.for("react.portal"):60106,Et=Z?Symbol.for("react.fragment"):60107,Rt=Z?Symbol.for("react.strict_mode"):60108,$t=Z?Symbol.for("react.profiler"):60114,Mt=Z?Symbol.for("react.provider"):60109,It=Z?Symbol.for("react.context"):60110,ar=Z?Symbol.for("react.async_mode"):60111,Ft=Z?Symbol.for("react.concurrent_mode"):60111,jt=Z?Symbol.for("react.forward_ref"):60112,Nt=Z?Symbol.for("react.suspense"):60113,ws=Z?Symbol.for("react.suspense_list"):60120,Lt=Z?Symbol.for("react.memo"):60115,zt=Z?Symbol.for("react.lazy"):60116,Ss=Z?Symbol.for("react.block"):60121,Ts=Z?Symbol.for("react.fundamental"):60117,Ps=Z?Symbol.for("react.responder"):60118,As=Z?Symbol.for("react.scope"):60119;function de(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case nr:switch(e=e.type,e){case ar:case Ft:case Et:case $t:case Rt:case Nt:return e;default:switch(e=e&&e.$$typeof,e){case It:case jt:case zt:case Lt:case Mt:return e;default:return t}}case sr:return t}}}function To(e){return de(e)===Ft}W.AsyncMode=ar;W.ConcurrentMode=Ft;W.ContextConsumer=It;W.ContextProvider=Mt;W.Element=nr;W.ForwardRef=jt;W.Fragment=Et;W.Lazy=zt;W.Memo=Lt;W.Portal=sr;W.Profiler=$t;W.StrictMode=Rt;W.Suspense=Nt;W.isAsyncMode=function(e){return To(e)||de(e)===ar};W.isConcurrentMode=To;W.isContextConsumer=function(e){return de(e)===It};W.isContextProvider=function(e){return de(e)===Mt};W.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===nr};W.isForwardRef=function(e){return de(e)===jt};W.isFragment=function(e){return de(e)===Et};W.isLazy=function(e){return de(e)===zt};W.isMemo=function(e){return de(e)===Lt};W.isPortal=function(e){return de(e)===sr};W.isProfiler=function(e){return de(e)===$t};W.isStrictMode=function(e){return de(e)===Rt};W.isSuspense=function(e){return de(e)===Nt};W.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===Et||e===Ft||e===$t||e===Rt||e===Nt||e===ws||typeof e=="object"&&e!==null&&(e.$$typeof===zt||e.$$typeof===Lt||e.$$typeof===Mt||e.$$typeof===It||e.$$typeof===jt||e.$$typeof===Ts||e.$$typeof===Ps||e.$$typeof===As||e.$$typeof===Ss)};W.typeOf=de});var ko=Jt(($i,Ao)=>{"use strict";Ao.exports=Po()});var jo=Jt((Mi,Fo)=>{"use strict";var ir=ko(),ks={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Es={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},Rs={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Mo={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},cr={};cr[ir.ForwardRef]=Rs;cr[ir.Memo]=Mo;function Eo(e){return ir.isMemo(e)?Mo:cr[e.$$typeof]||ks}var $s=Object.defineProperty,Ms=Object.getOwnPropertyNames,Ro=Object.getOwnPropertySymbols,Is=Object.getOwnPropertyDescriptor,Fs=Object.getPrototypeOf,$o=Object.prototype;function Io(e,t,r){if(typeof t!="string"){if($o){var o=Fs(t);o&&o!==$o&&Io(e,o,r)}var n=Ms(t);Ro&&(n=n.concat(Ro(t)));for(var s=Eo(e),a=Eo(t),i=0;i<n.length;++i){var c=n[i];if(!Es[c]&&!(r&&r[c])&&!(a&&a[c])&&!(s&&s[c])){var l=Is(t,c);try{$s(e,c,l)}catch{}}}}return e}Fo.exports=Io});var rs=!1;function os(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function ns(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var Or=(function(){function e(r){var o=this;this._insertTag=function(n){var s;o.tags.length===0?o.insertionPoint?s=o.insertionPoint.nextSibling:o.prepend?s=o.container.firstChild:s=o.before:s=o.tags[o.tags.length-1].nextSibling,o.container.insertBefore(n,s),o.tags.push(n)},this.isSpeedy=r.speedy===void 0?!rs:r.speedy,this.tags=[],this.ctr=0,this.nonce=r.nonce,this.key=r.key,this.container=r.container,this.prepend=r.prepend,this.insertionPoint=r.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(o){o.forEach(this._insertTag)},t.insert=function(o){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(ns(this));var n=this.tags[this.tags.length-1];if(this.isSpeedy){var s=os(n);try{s.insertRule(o,s.cssRules.length)}catch{}}else n.appendChild(document.createTextNode(o));this.ctr++},t.flush=function(){this.tags.forEach(function(o){var n;return(n=o.parentNode)==null?void 0:n.removeChild(o)}),this.tags=[],this.ctr=0},e})();var ee="-ms-",nt="-moz-",N="-webkit-",vt="comm",Be="rule",Ue="decl";var Wr="@import";var bt="@keyframes";var Br="@layer";var Ur=Math.abs,je=String.fromCharCode,Dr=Object.assign;function _r(e,t){return K(e,0)^45?(((t<<2^K(e,0))<<2^K(e,1))<<2^K(e,2))<<2^K(e,3):0}function Ct(e){return e.trim()}function Qt(e,t){return(e=t.exec(e))?e[0]:e}function F(e,t,r){return e.replace(t,r)}function st(e,t){return e.indexOf(t)}function K(e,t){return e.charCodeAt(t)|0}function Se(e,t,r){return e.slice(t,r)}function oe(e){return e.length}function De(e){return e.length}function _e(e,t){return t.push(e),e}function Zt(e,t){return e.map(t).join("")}var wt=1,Ve=1,Vr=0,ne=0,Y=0,Ge="";function at(e,t,r,o,n,s,a){return{value:e,root:t,parent:r,type:o,props:n,children:s,line:wt,column:Ve,length:a,return:""}}function qe(e,t){return Dr(at("",null,null,"",null,null,0),e,{length:-e.length},t)}function Hr(){return Y}function Gr(){return Y=ne>0?K(Ge,--ne):0,Ve--,Y===10&&(Ve=1,wt--),Y}function se(){return Y=ne<Vr?K(Ge,ne++):0,Ve++,Y===10&&(Ve=1,wt++),Y}function pe(){return K(Ge,ne)}function it(){return ne}function Ke(e,t){return Se(Ge,e,t)}function He(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function St(e){return wt=Ve=1,Vr=oe(Ge=e),ne=0,[]}function Tt(e){return Ge="",e}function Xe(e){return Ct(Ke(ne-1,er(e===91?e+2:e===40?e+1:e)))}function qr(e){for(;(Y=pe())&&Y<33;)se();return He(e)>2||He(Y)>3?"":" "}function Kr(e,t){for(;--t&&se()&&!(Y<48||Y>102||Y>57&&Y<65||Y>70&&Y<97););return Ke(e,it()+(t<6&&pe()==32&&se()==32))}function er(e){for(;se();)switch(Y){case e:return ne;case 34:case 39:e!==34&&e!==39&&er(Y);break;case 40:e===41&&er(e);break;case 92:se();break}return ne}function Xr(e,t){for(;se()&&e+Y!==57;)if(e+Y===84&&pe()===47)break;return"/*"+Ke(t,ne-1)+"*"+je(e===47?e:se())}function Yr(e){for(;!He(pe());)se();return Ke(e,ne)}function Zr(e){return Tt(Pt("",null,null,null,[""],e=St(e),0,[0],e))}function Pt(e,t,r,o,n,s,a,i,c){for(var l=0,p=0,x=a,u=0,w=0,h=0,m=1,d=1,f=1,g=0,T="",j=n,L=s,O=o,v=T;d;)switch(h=g,g=se()){case 40:if(h!=108&&K(v,x-1)==58){st(v+=F(Xe(g),"&","&\f"),"&\f")!=-1&&(f=-1);break}case 34:case 39:case 91:v+=Xe(g);break;case 9:case 10:case 13:case 32:v+=qr(h);break;case 92:v+=Kr(it()-1,7);continue;case 47:switch(pe()){case 42:case 47:_e(ss(Xr(se(),it()),t,r),c);break;default:v+="/"}break;case 123*m:i[l++]=oe(v)*f;case 125*m:case 59:case 0:switch(g){case 0:case 125:d=0;case 59+p:f==-1&&(v=F(v,/\f/g,"")),w>0&&oe(v)-x&&_e(w>32?Qr(v+";",o,r,x-1):Qr(F(v," ","")+";",o,r,x-2),c);break;case 59:v+=";";default:if(_e(O=Jr(v,t,r,l,p,n,i,T,j=[],L=[],x),s),g===123)if(p===0)Pt(v,t,O,O,j,s,x,i,L);else switch(u===99&&K(v,3)===110?100:u){case 100:case 108:case 109:case 115:Pt(e,O,O,o&&_e(Jr(e,O,O,0,0,n,i,T,n,j=[],x),L),n,L,x,i,o?j:L);break;default:Pt(v,O,O,O,[""],L,0,i,L)}}l=p=w=0,m=f=1,T=v="",x=a;break;case 58:x=1+oe(v),w=h;default:if(m<1){if(g==123)--m;else if(g==125&&m++==0&&Gr()==125)continue}switch(v+=je(g),g*m){case 38:f=p>0?1:(v+="\f",-1);break;case 44:i[l++]=(oe(v)-1)*f,f=1;break;case 64:pe()===45&&(v+=Xe(se())),u=pe(),p=x=oe(T=v+=Yr(it())),g++;break;case 45:h===45&&oe(v)==2&&(m=0)}}return s}function Jr(e,t,r,o,n,s,a,i,c,l,p){for(var x=n-1,u=n===0?s:[""],w=De(u),h=0,m=0,d=0;h<o;++h)for(var f=0,g=Se(e,x+1,x=Ur(m=a[h])),T=e;f<w;++f)(T=Ct(m>0?u[f]+" "+g:F(g,/&\f/g,u[f])))&&(c[d++]=T);return at(e,t,r,n===0?Be:i,c,l,p)}function ss(e,t,r){return at(e,t,r,vt,je(Hr()),Se(e,2,-2),0)}function Qr(e,t,r,o){return at(e,t,r,Ue,Se(e,0,o),Se(e,o+1,-1),o)}function Ne(e,t){for(var r="",o=De(e),n=0;n<o;n++)r+=t(e[n],n,e,t)||"";return r}function eo(e,t,r,o){switch(e.type){case Br:if(e.children.length)break;case Wr:case Ue:return e.return=e.return||e.value;case vt:return"";case bt:return e.return=e.value+"{"+Ne(e.children,o)+"}";case Be:e.value=e.props.join(",")}return oe(r=Ne(e.children,o))?e.return=e.value+"{"+r+"}":""}function to(e){var t=De(e);return function(r,o,n,s){for(var a="",i=0;i<t;i++)a+=e[i](r,o,n,s)||"";return a}}function ro(e){return function(t){t.root||(t=t.return)&&e(t)}}var tr=function(t){var r=new WeakMap;return function(o){if(r.has(o))return r.get(o);var n=t(o);return r.set(o,n),n}};function oo(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var as=function(t,r,o){for(var n=0,s=0;n=s,s=pe(),n===38&&s===12&&(r[o]=1),!He(s);)se();return Ke(t,ne)},is=function(t,r){var o=-1,n=44;do switch(He(n)){case 0:n===38&&pe()===12&&(r[o]=1),t[o]+=as(ne-1,r,o);break;case 2:t[o]+=Xe(n);break;case 4:if(n===44){t[++o]=pe()===58?"&\f":"",r[o]=t[o].length;break}default:t[o]+=je(n)}while(n=se());return t},cs=function(t,r){return Tt(is(St(t),r))},no=new WeakMap,ls=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var r=t.value,o=t.parent,n=t.column===o.column&&t.line===o.line;o.type!=="rule";)if(o=o.parent,!o)return;if(!(t.props.length===1&&r.charCodeAt(0)!==58&&!no.get(o))&&!n){no.set(t,!0);for(var s=[],a=cs(r,s),i=o.props,c=0,l=0;c<a.length;c++)for(var p=0;p<i.length;p++,l++)t.props[l]=s[c]?a[c].replace(/&\f/g,i[p]):i[p]+" "+a[c]}}},ds=function(t){if(t.type==="decl"){var r=t.value;r.charCodeAt(0)===108&&r.charCodeAt(2)===98&&(t.return="",t.value="")}};function so(e,t){switch(_r(e,t)){case 5103:return N+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return N+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return N+e+nt+e+ee+e+e;case 6828:case 4268:return N+e+ee+e+e;case 6165:return N+e+ee+"flex-"+e+e;case 5187:return N+e+F(e,/(\w+).+(:[^]+)/,N+"box-$1$2"+ee+"flex-$1$2")+e;case 5443:return N+e+ee+"flex-item-"+F(e,/flex-|-self/,"")+e;case 4675:return N+e+ee+"flex-line-pack"+F(e,/align-content|flex-|-self/,"")+e;case 5548:return N+e+ee+F(e,"shrink","negative")+e;case 5292:return N+e+ee+F(e,"basis","preferred-size")+e;case 6060:return N+"box-"+F(e,"-grow","")+N+e+ee+F(e,"grow","positive")+e;case 4554:return N+F(e,/([^-])(transform)/g,"$1"+N+"$2")+e;case 6187:return F(F(F(e,/(zoom-|grab)/,N+"$1"),/(image-set)/,N+"$1"),e,"")+e;case 5495:case 3959:return F(e,/(image-set\([^]*)/,N+"$1$`$1");case 4968:return F(F(e,/(.+:)(flex-)?(.*)/,N+"box-pack:$3"+ee+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+N+e+e;case 4095:case 3583:case 4068:case 2532:return F(e,/(.+)-inline(.+)/,N+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(oe(e)-1-t>6)switch(K(e,t+1)){case 109:if(K(e,t+4)!==45)break;case 102:return F(e,/(.+:)(.+)-([^]+)/,"$1"+N+"$2-$3$1"+nt+(K(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~st(e,"stretch")?so(F(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(K(e,t+1)!==115)break;case 6444:switch(K(e,oe(e)-3-(~st(e,"!important")&&10))){case 107:return F(e,":",":"+N)+e;case 101:return F(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+N+(K(e,14)===45?"inline-":"")+"box$3$1"+N+"$2$3$1"+ee+"$2box$3")+e}break;case 5936:switch(K(e,t+11)){case 114:return N+e+ee+F(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return N+e+ee+F(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return N+e+ee+F(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return N+e+ee+e+e}return e}var us=function(t,r,o,n){if(t.length>-1&&!t.return)switch(t.type){case Ue:t.return=so(t.value,t.length);break;case bt:return Ne([qe(t,{value:F(t.value,"@","@"+N)})],n);case Be:if(t.length)return Zt(t.props,function(s){switch(Qt(s,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Ne([qe(t,{props:[F(s,/:(read-\w+)/,":"+nt+"$1")]})],n);case"::placeholder":return Ne([qe(t,{props:[F(s,/:(plac\w+)/,":"+N+"input-$1")]}),qe(t,{props:[F(s,/:(plac\w+)/,":"+nt+"$1")]}),qe(t,{props:[F(s,/:(plac\w+)/,ee+"input-$1")]})],n)}return""})}},fs=[us],At=function(t){var r=t.key;if(r==="css"){var o=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(o,function(m){var d=m.getAttribute("data-emotion");d.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var n=t.stylisPlugins||fs,s={},a,i=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+r+' "]'),function(m){for(var d=m.getAttribute("data-emotion").split(" "),f=1;f<d.length;f++)s[d[f]]=!0;i.push(m)});var c,l=[ls,ds];{var p,x=[eo,ro(function(m){p.insert(m)})],u=to(l.concat(n,x)),w=function(d){return Ne(Zr(d),u)};c=function(d,f,g,T){p=g,w(d?d+"{"+f.styles+"}":f.styles),T&&(h.inserted[f.name]=!0)}}var h={key:r,sheet:new Or({key:r,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:s,registered:{},insert:c};return h.sheet.hydrate(i),h};function ao(e){for(var t=0,r,o=0,n=e.length;n>=4;++o,n-=4)r=e.charCodeAt(o)&255|(e.charCodeAt(++o)&255)<<8|(e.charCodeAt(++o)&255)<<16|(e.charCodeAt(++o)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(n){case 3:t^=(e.charCodeAt(o+2)&255)<<16;case 2:t^=(e.charCodeAt(o+1)&255)<<8;case 1:t^=e.charCodeAt(o)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var io={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};var ps=!1,ms=/[A-Z]|^ms/g,hs=/_EMO_([^_]+?)_([^]*?)_EMO_/g,fo=function(t){return t.charCodeAt(1)===45},co=function(t){return t!=null&&typeof t!="boolean"},rr=oo(function(e){return fo(e)?e:e.replace(ms,"-$&").toLowerCase()}),lo=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(hs,function(o,n,s){return xe={name:n,styles:s,next:xe},n})}return io[t]!==1&&!fo(t)&&typeof r=="number"&&r!==0?r+"px":r},gs="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function ct(e,t,r){if(r==null)return"";var o=r;if(o.__emotion_styles!==void 0)return o;switch(typeof r){case"boolean":return"";case"object":{var n=r;if(n.anim===1)return xe={name:n.name,styles:n.styles,next:xe},n.name;var s=r;if(s.styles!==void 0){var a=s.next;if(a!==void 0)for(;a!==void 0;)xe={name:a.name,styles:a.styles,next:xe},a=a.next;var i=s.styles+";";return i}return xs(e,t,r)}case"function":{if(e!==void 0){var c=xe,l=r(e);return xe=c,ct(e,t,l)}break}}var p=r;if(t==null)return p;var x=t[p];return x!==void 0?x:p}function xs(e,t,r){var o="";if(Array.isArray(r))for(var n=0;n<r.length;n++)o+=ct(e,t,r[n])+";";else for(var s in r){var a=r[s];if(typeof a!="object"){var i=a;t!=null&&t[i]!==void 0?o+=s+"{"+t[i]+"}":co(i)&&(o+=rr(s)+":"+lo(s,i)+";")}else{if(s==="NO_COMPONENT_SELECTOR"&&ps)throw new Error(gs);if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var c=0;c<a.length;c++)co(a[c])&&(o+=rr(s)+":"+lo(s,a[c])+";");else{var l=ct(e,t,a);switch(s){case"animation":case"animationName":{o+=rr(s)+":"+l+";";break}default:o+=s+"{"+l+"}"}}}}return o}var uo=/label:\s*([^\s;{]+)\s*(;|$)/g,xe;function ie(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var o=!0,n="";xe=void 0;var s=e[0];if(s==null||s.raw===void 0)o=!1,n+=ct(r,t,s);else{var a=s;n+=a[0]}for(var i=1;i<e.length;i++)if(n+=ct(r,t,e[i]),o){var c=s;n+=c[i]}uo.lastIndex=0;for(var l="",p;(p=uo.exec(n))!==null;)l+="-"+p[1];var x=ao(n)+l;return{name:x,styles:n,next:xe}}var ys=!0;function Te(e,t,r){var o="";return r.split(" ").forEach(function(n){e[n]!==void 0?t.push(e[n]+";"):n&&(o+=n+" ")}),o}var Ye=function(t,r,o){var n=t.key+"-"+r.name;(o===!1||ys===!1)&&t.registered[n]===void 0&&(t.registered[n]=r.styles)},Je=function(t,r,o){Ye(t,r,o);var n=t.key+"-"+r.name;if(t.inserted[r.name]===void 0){var s=r;do t.insert(r===s?"."+n:"",s,t.sheet,!0),s=s.next;while(s!==void 0)}};function po(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function mo(e,t,r){var o=[],n=Te(e,o,r);return o.length<2?r:n+t(o)}var Le=function(t){var r=At(t);r.sheet.speedy=function(i){this.isSpeedy=i},r.compat=!0;var o=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];var x=ie(l,r.registered,void 0);return Je(r,x,!1),r.key+"-"+x.name},n=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];var x=ie(l,r.registered),u="animation-"+x.name;return po(r,{name:x.name,styles:"@keyframes "+u+"{"+x.styles+"}"}),u},s=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];var x=ie(l,r.registered);po(r,x)},a=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];return mo(r.registered,o,vs(l))};return{css:o,cx:a,injectGlobal:s,keyframes:n,hydrate:function(c){c.forEach(function(l){r.inserted[l]=!0})},flush:function(){r.registered={},r.inserted={},r.sheet.flush()},sheet:r.sheet,cache:r,getRegisteredStyles:Te.bind(null,r.registered),merge:mo.bind(null,r.registered,o)}},vs=function e(t){for(var r="",o=0;o<t.length;o++){var n=t[o];if(n!=null){var s=void 0;switch(typeof n){case"boolean":break;case"object":{if(Array.isArray(n))s=e(n);else{s="";for(var a in n)n[a]&&a&&(s&&(s+=" "),s+=a)}break}default:s=n}s&&(r&&(r+=" "),r+=s)}}return r};var ye=Le({key:"css"}),Xa=ye.flush,Ya=ye.hydrate,Ja=ye.cx,Qa=ye.merge,Za=ye.getRegisteredStyles,ei=ye.injectGlobal,ti=ye.keyframes,ri=ye.css,oi=ye.sheet,ho=ye.cache;var go=(function(){function e(){Rr(this,e),Er(this,"_cacheList",[ho])}return $r(e,[{key:"add",value:function(r){var o=this.getCache(r.key);return o||(this._cacheList.push(r),r)}},{key:"delete",value:function(r){this._cacheList=this._cacheList.filter(function(o){return o.key!==r.key})}},{key:"hasCache",value:function(r){return this._cacheList.some(function(o){return o.key===r.key})}},{key:"getCache",value:function(r){return this._cacheList.find(function(o){return o.key===r})}},{key:"getCacheList",value:function(){return this._cacheList}}]),e})();var xo=typeof document<"u",or=function(t,r){return"".concat(t,"-").concat(r)},yo=function(t,r,o,n){var s=n.hashPriority||"high";Ye(t,r,o);var a=".".concat(or(t.key,r.name)),i=s==="low"?":where(".concat(a,")"):a;if(t.inserted[r.name]===void 0){var c="",l=r;do{var p=t.insert(r===l?i:"",l,t.sheet,!0);!xo&&p!==void 0&&(c+=p),l=l.next}while(l!==void 0);if(!xo&&c.length!==0)return c}};var Qe=function(t){return We(t)==="object"&&"styles"in t&&"name"in t&&"toString"in t},vo=function e(t){for(var r="",o=0;o<t.length;o++){var n=t[o];if(n!==null){var s=void 0;switch(We(n)){case"boolean":break;case"object":{if(Array.isArray(n))s=e(n);else{s="";for(var a in n)n[a]&&a&&(s&&(s+=" "),s+=a)}break}default:s=n}s&&(r&&(r+=" "),r+=s)}}return r},bo=function(t,r,o){var n=[],s=Te(t,n,o);return n.length<2?o:s+r(n)};var bs=function(t,r){return function(){for(var o=arguments.length,n=new Array(o),s=0;s<o;s++)n[s]=arguments[s];var a=ie(n,t.registered,void 0);return yo(t,a,!1,r),or(t.key,a.name)}},Cs=function(t,r){return function(){for(var o=arguments.length,n=new Array(o),s=0;s<o;s++)n[s]=arguments[s];var a=n.map(function(i){return Qe(i)?r(i):i});return bo(t.registered,r,vo(a))}},kt=function(t,r){var o=bs(t,{hashPriority:r.hashPriority||"high",label:r.label}),n=Cs(t,o);return{css:o,cx:n}};var he=function(){for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return ie(r)};var Co="acss";var yr=y(z());var wo=y(z()),So=function(t){return(0,wo.createContext)(t)};var ce=y(z()),Ot=y(z());var lt=y(z()),js=function(t){return t()},No=lt.useInsertionEffect?lt.useInsertionEffect:!1,lr=No||js,dr=No||lt.useLayoutEffect;var Lo=!1,zo=ce.createContext(typeof HTMLElement<"u"?At({key:"css"}):null),Ns=zo.Provider;var Wt=function(t){return(0,Ot.forwardRef)(function(r,o){var n=(0,Ot.useContext)(zo);return t(r,n,o)})},Pe=ce.createContext({});var Ls=function(t,r){if(typeof r=="function"){var o=r(t);return o}return Pr({},t,r)},zs=tr(function(e){return tr(function(t){return Ls(e,t)})}),fr=function(t){var r=ce.useContext(Pe);return t.theme!==r&&(r=zs(r)(t.theme)),ce.createElement(Pe.Provider,{value:r},t.children)};var Bt={}.hasOwnProperty,ur="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Oo=function(t,r){var o={};for(var n in r)Bt.call(r,n)&&(o[n]=r[n]);return o[ur]=t,o},Os=function(t){var r=t.cache,o=t.serialized,n=t.isStringTag;return Ye(r,o,n),lr(function(){return Je(r,o,n)}),null},Ws=Wt(function(e,t,r){var o=e.css;typeof o=="string"&&t.registered[o]!==void 0&&(o=t.registered[o]);var n=e[ur],s=[o],a="";typeof e.className=="string"?a=Te(t.registered,s,e.className):e.className!=null&&(a=e.className+" ");var i=ie(s,void 0,ce.useContext(Pe));a+=t.key+"-"+i.name;var c={};for(var l in e)Bt.call(e,l)&&l!=="css"&&l!==ur&&!Lo&&(c[l]=e[l]);return c.className=a,r&&(c.ref=r),ce.createElement(ce.Fragment,null,ce.createElement(Os,{cache:t,serialized:i,isStringTag:typeof n=="string"}),ce.createElement(n,c))}),Wo=Ws;var Ae=y(z());var Yi=y(jo()),Bo=function(t,r){var o=arguments;if(r==null||!Bt.call(r,"css"))return Ae.createElement.apply(void 0,o);var n=o.length,s=new Array(n);s[0]=Wo,s[1]=Oo(t,r);for(var a=2;a<n;a++)s[a]=o[a];return Ae.createElement.apply(null,s)};(function(e){var t;t||(t=e.JSX||(e.JSX={}))})(Bo||(Bo={}));var Uo=Wt(function(e,t){var r=e.styles,o=ie([r],void 0,Ae.useContext(Pe)),n=Ae.useRef();return dr(function(){var s=t.key+"-global",a=new t.sheet.constructor({key:s,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),i=!1,c=document.querySelector('style[data-emotion="'+s+" "+o.name+'"]');return t.sheet.tags.length&&(a.before=t.sheet.tags[0]),c!==null&&(i=!0,c.setAttribute("data-emotion",s),a.hydrate([c])),n.current=[a,i],function(){a.flush()}},[t]),dr(function(){var s=n.current,a=s[0],i=s[1];if(i){s[1]=!1;return}if(o.next!==void 0&&Je(t,o.next,!0),a.tags.length){var c=a.tags[a.tags.length-1].nextElementSibling;a.before=c,a.flush()}t.insert("",o,a,!1)},[t,o.name]),null});var Do=y(z()),_o=y(B()),Vo=function(t){return function(){for(var r=arguments.length,o=new Array(r),n=0;n<r;n++)o[n]=arguments[n];return(0,Do.memo)(function(s){var a=t();return(0,_o.jsx)(Uo,{styles:ie(o,void 0,A(A({},s),{},{theme:a}))})})}};var Ho=function(t){return function(r){var o=t(r);return function(n){var s=o(n),a=s.styles;return a}}};var ke=y(z()),pr=y(B()),Bs=["children","prefix","speedy","getStyleManager","container","nonce","insertionPoint","stylisPlugins","linters"],Go=function(t){return(0,ke.memo)(function(r){var o=r.children,n=r.prefix,s=r.speedy,a=r.getStyleManager,i=r.container,c=r.nonce,l=r.insertionPoint,p=r.stylisPlugins,x=r.linters,u=Ie(r,Bs),w=(0,ke.useContext)(t),h=n??w.sheet.key,m=i??w.sheet.container,d=s??w.sheet.isSpeedy,f=(0,ke.useMemo)(function(){var T=!1,j=Le({speedy:d??T,key:h,container:m,nonce:c,insertionPoint:l,stylisPlugins:p});if(typeof global<"u"){var L=global.__ANTD_STYLE_CACHE_MANAGER_FOR_SSR__;L&&(j.cache=L.add(j.cache))}return j},[h,d,m,c,l,p]);(0,ke.useEffect)(function(){a?.(f)},[f]);var g=(0,pr.jsx)(t.Provider,{value:f,children:o});return Object.keys(u).length||m?(0,pr.jsx)(kr,A(A({linters:x,container:m},u),{},{children:g})):g})};var dt=y(z());var Jo=y(z());var qo=function(t){var r=t.css,o=t.token;return{buttonDefaultHover:r({backgroundColor:o.colorBgContainer,border:"1px solid ".concat(o.colorBorder),cursor:"pointer",":hover":{color:o.colorPrimaryHover,borderColor:o.colorPrimaryHover},":active":{color:o.colorPrimaryActive,borderColor:o.colorPrimaryActive}})}};var Ko=function(t){return Object.fromEntries(Object.entries(t).map(function(r){var o=ae(r,2),n=o[0],s=o[1];return[n,s.styles]}))};var Ze=function(){var t=Fe.useToken(),r=t.token;return r};var Yo=y(z());var Xo=y(z());var Ee=function(t){return typeof window<"u"?matchMedia&&matchMedia("(prefers-color-scheme: ".concat(t,")")):{matches:!1}};var mr,Ut=(0,Xo.createContext)({appearance:"light",setAppearance:function(){},isDarkMode:!1,themeMode:"light",setThemeMode:function(){},browserPrefers:(mr=Ee("dark"))!==null&&mr!==void 0&&mr.matches?"dark":"light"});var Re=function(){return(0,Yo.useContext)(Ut)};var Qo=function(){var t=Ze(),r=Re(),o=r.appearance,n=r.isDarkMode;return(0,Jo.useMemo)(function(){return Ko(qo({token:t,css:he,appearance:o,isDarkMode:n}))},[t,o,n])};var Zo=y(z());var Dt=function(){var t=Ze(),r=Qo();return(0,Zo.useMemo)(function(){return A(A({},t),{},{stylish:r})},[t,r])};var en=function(t){return A(A({},t),{},{mobile:t.xs,tablet:t.md,laptop:t.lg,desktop:t.xxl})};var tn=y(z()),rn=function(){var t=Ze(),r={xs:"@media (max-width: ".concat(t.screenXSMax,"px)"),sm:"@media (max-width: ".concat(t.screenSMMax,"px)"),md:"@media (max-width: ".concat(t.screenMDMax,"px)"),lg:"@media (max-width: ".concat(t.screenLGMax,"px)"),xl:"@media (max-width: ".concat(t.screenXLMax,"px)"),xxl:"@media (min-width: ".concat(t.screenXXLMin,"px)")};return(0,tn.useMemo)(function(){return en(r)},[t])},on=function(t,r){return Object.entries(t).map(function(o){var n=ae(o,2),s=n[0],a=n[1],i=a;return Qe(a)||(i=he(a)),r[s]?"".concat(r[s]," {").concat(i.styles,"}"):""}).join("")};var Us=["stylish","appearance","isDarkMode","prefixCls","iconPrefixCls"],Ds=["prefixCls","iconPrefixCls"],nn=function(t){var r=t.hashPriority,o=t.useTheme,n=t.EmotionContext;return function(s,a){var i=a?.__BABEL_FILE_NAME__,c=!!i;return function(l){var p=o(),x=(0,dt.useContext)(n),u=x.cache,w=kt(u,{hashPriority:a?.hashPriority||r,label:a?.label}),h=w.cx,m=w.css,d=rn(),f=(0,dt.useMemo)(function(){var g;if(s instanceof Function){var T=p.stylish,j=p.appearance,L=p.isDarkMode,O=p.prefixCls,v=p.iconPrefixCls,G=Ie(p,Us),Q=function(_){return on(_,d)};Object.assign(Q,d),g=s({token:G,stylish:T,appearance:j,isDarkMode:L,prefixCls:O,iconPrefixCls:v,cx:h,css:he,responsive:Q},l)}else g=s;return We(g)==="object"&&(Qe(g)?g=m(g):g=Object.fromEntries(Object.entries(g).map(function(ue){var _=ae(ue,2),be=_[0],fe=_[1],tt=c?"".concat(i,"-").concat(be):void 0;return We(fe)==="object"?c?[be,m(fe,"label:".concat(tt))]:[be,m(fe)]:[be,fe]}))),g},[l,p]);return(0,dt.useMemo)(function(){var g=p.prefixCls,T=p.iconPrefixCls,j=Ie(p,Ds);return{styles:f,cx:h,theme:j,prefixCls:g,iconPrefixCls:T}},[f,p])}}};var pt=y(z());var sn=y(B()),hr=function(t){if(t.ThemeProvider)return t.ThemeProvider;var r=t.ThemeContext;return function(o){return(0,sn.jsx)(r.Provider,{value:o.theme,children:o.children})}};var an=fr,_t=Pe;var et=y(z());var cn=y(B()),ln=(0,et.memo)(function(e){var t=e.children,r=e.theme,o=e.prefixCls,n=e.getStaticInstance,s=e.staticInstanceConfig,a=Re(),i=a.appearance,c=a.isDarkMode,l=Mr.useMessage(s?.message),p=ae(l,2),x=p[0],u=p[1],w=Fr.useNotification(s?.notification),h=ae(w,2),m=h[0],d=h[1],f=Ir.useModal(),g=ae(f,2),T=g[0],j=g[1];(0,et.useEffect)(function(){n?.({message:x,modal:T,notification:m})},[]);var L=(0,et.useMemo)(function(){var O=c?Fe.darkAlgorithm:Fe.defaultAlgorithm,v=r;if(typeof r=="function"&&(v=r(i)),!v)return{algorithm:O};var G=v.algorithm?v.algorithm instanceof Array?v.algorithm:[v.algorithm]:[];return A(A({},v),{},{algorithm:v.algorithm?[O].concat(Ar(G)):O})},[r,c]);return(0,cn.jsxs)(ht,{prefixCls:o,theme:L,children:[u,d,j,t]})});ln.displayName="AntdProvider";var dn=ln;var ze=y(z());var fn=y(z());function _s(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var o,n,s,a,i=[],c=!0,l=!1;try{if(s=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;c=!1}else for(;!(c=(o=s.call(r)).done)&&(i.push(o.value),i.length!==t);c=!0);}catch(p){l=!0,n=p}finally{try{if(!c&&r.return!=null&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw n}}return i}}function Vs(e,t){return Hs(e)||_s(e,t)||Gs(e,t)||qs()}function Hs(e){if(Array.isArray(e))return e}function Gs(e,t){if(e){if(typeof e=="string")return un(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return un(e,t)}}function un(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,o=new Array(t);r<t;r++)o[r]=e[r];return o}function qs(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
1
|
+
import{f as Nr,h as Lr,j as zr,l as we,o as xt,t as yt}from"./embed-page-chunk-RFN7O6VH.js";import{b as jr,l as Ce}from"./embed-page-chunk-WR44MKDA.js";import{a as B}from"./embed-page-chunk-QV7QAJ4N.js";import{La as Mr,M as ht,Ma as Ir,N as ae,Na as Fr,O as We,P as Er,Q as Ie,R as A,U as Rr,V as $r,_a as Fe,b as Pr,bb as gt,j as Ar,o as kr}from"./embed-page-chunk-F7TA3LRH.js";import{a as z}from"./embed-page-chunk-R5QL57JJ.js";import{c as Jt,f as y}from"./embed-page-chunk-QBTAJ2YI.js";var Po=Jt(W=>{"use strict";var Z=typeof Symbol=="function"&&Symbol.for,nr=Z?Symbol.for("react.element"):60103,sr=Z?Symbol.for("react.portal"):60106,Et=Z?Symbol.for("react.fragment"):60107,Rt=Z?Symbol.for("react.strict_mode"):60108,$t=Z?Symbol.for("react.profiler"):60114,Mt=Z?Symbol.for("react.provider"):60109,It=Z?Symbol.for("react.context"):60110,ar=Z?Symbol.for("react.async_mode"):60111,Ft=Z?Symbol.for("react.concurrent_mode"):60111,jt=Z?Symbol.for("react.forward_ref"):60112,Nt=Z?Symbol.for("react.suspense"):60113,ws=Z?Symbol.for("react.suspense_list"):60120,Lt=Z?Symbol.for("react.memo"):60115,zt=Z?Symbol.for("react.lazy"):60116,Ss=Z?Symbol.for("react.block"):60121,Ts=Z?Symbol.for("react.fundamental"):60117,Ps=Z?Symbol.for("react.responder"):60118,As=Z?Symbol.for("react.scope"):60119;function de(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case nr:switch(e=e.type,e){case ar:case Ft:case Et:case $t:case Rt:case Nt:return e;default:switch(e=e&&e.$$typeof,e){case It:case jt:case zt:case Lt:case Mt:return e;default:return t}}case sr:return t}}}function To(e){return de(e)===Ft}W.AsyncMode=ar;W.ConcurrentMode=Ft;W.ContextConsumer=It;W.ContextProvider=Mt;W.Element=nr;W.ForwardRef=jt;W.Fragment=Et;W.Lazy=zt;W.Memo=Lt;W.Portal=sr;W.Profiler=$t;W.StrictMode=Rt;W.Suspense=Nt;W.isAsyncMode=function(e){return To(e)||de(e)===ar};W.isConcurrentMode=To;W.isContextConsumer=function(e){return de(e)===It};W.isContextProvider=function(e){return de(e)===Mt};W.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===nr};W.isForwardRef=function(e){return de(e)===jt};W.isFragment=function(e){return de(e)===Et};W.isLazy=function(e){return de(e)===zt};W.isMemo=function(e){return de(e)===Lt};W.isPortal=function(e){return de(e)===sr};W.isProfiler=function(e){return de(e)===$t};W.isStrictMode=function(e){return de(e)===Rt};W.isSuspense=function(e){return de(e)===Nt};W.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===Et||e===Ft||e===$t||e===Rt||e===Nt||e===ws||typeof e=="object"&&e!==null&&(e.$$typeof===zt||e.$$typeof===Lt||e.$$typeof===Mt||e.$$typeof===It||e.$$typeof===jt||e.$$typeof===Ts||e.$$typeof===Ps||e.$$typeof===As||e.$$typeof===Ss)};W.typeOf=de});var ko=Jt(($i,Ao)=>{"use strict";Ao.exports=Po()});var jo=Jt((Mi,Fo)=>{"use strict";var ir=ko(),ks={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Es={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},Rs={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Mo={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},cr={};cr[ir.ForwardRef]=Rs;cr[ir.Memo]=Mo;function Eo(e){return ir.isMemo(e)?Mo:cr[e.$$typeof]||ks}var $s=Object.defineProperty,Ms=Object.getOwnPropertyNames,Ro=Object.getOwnPropertySymbols,Is=Object.getOwnPropertyDescriptor,Fs=Object.getPrototypeOf,$o=Object.prototype;function Io(e,t,r){if(typeof t!="string"){if($o){var o=Fs(t);o&&o!==$o&&Io(e,o,r)}var n=Ms(t);Ro&&(n=n.concat(Ro(t)));for(var s=Eo(e),a=Eo(t),i=0;i<n.length;++i){var c=n[i];if(!Es[c]&&!(r&&r[c])&&!(a&&a[c])&&!(s&&s[c])){var l=Is(t,c);try{$s(e,c,l)}catch{}}}}return e}Fo.exports=Io});var rs=!1;function os(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function ns(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var Or=(function(){function e(r){var o=this;this._insertTag=function(n){var s;o.tags.length===0?o.insertionPoint?s=o.insertionPoint.nextSibling:o.prepend?s=o.container.firstChild:s=o.before:s=o.tags[o.tags.length-1].nextSibling,o.container.insertBefore(n,s),o.tags.push(n)},this.isSpeedy=r.speedy===void 0?!rs:r.speedy,this.tags=[],this.ctr=0,this.nonce=r.nonce,this.key=r.key,this.container=r.container,this.prepend=r.prepend,this.insertionPoint=r.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(o){o.forEach(this._insertTag)},t.insert=function(o){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(ns(this));var n=this.tags[this.tags.length-1];if(this.isSpeedy){var s=os(n);try{s.insertRule(o,s.cssRules.length)}catch{}}else n.appendChild(document.createTextNode(o));this.ctr++},t.flush=function(){this.tags.forEach(function(o){var n;return(n=o.parentNode)==null?void 0:n.removeChild(o)}),this.tags=[],this.ctr=0},e})();var ee="-ms-",nt="-moz-",N="-webkit-",vt="comm",Be="rule",Ue="decl";var Wr="@import";var bt="@keyframes";var Br="@layer";var Ur=Math.abs,je=String.fromCharCode,Dr=Object.assign;function _r(e,t){return K(e,0)^45?(((t<<2^K(e,0))<<2^K(e,1))<<2^K(e,2))<<2^K(e,3):0}function Ct(e){return e.trim()}function Qt(e,t){return(e=t.exec(e))?e[0]:e}function F(e,t,r){return e.replace(t,r)}function st(e,t){return e.indexOf(t)}function K(e,t){return e.charCodeAt(t)|0}function Se(e,t,r){return e.slice(t,r)}function oe(e){return e.length}function De(e){return e.length}function _e(e,t){return t.push(e),e}function Zt(e,t){return e.map(t).join("")}var wt=1,Ve=1,Vr=0,ne=0,Y=0,Ge="";function at(e,t,r,o,n,s,a){return{value:e,root:t,parent:r,type:o,props:n,children:s,line:wt,column:Ve,length:a,return:""}}function qe(e,t){return Dr(at("",null,null,"",null,null,0),e,{length:-e.length},t)}function Hr(){return Y}function Gr(){return Y=ne>0?K(Ge,--ne):0,Ve--,Y===10&&(Ve=1,wt--),Y}function se(){return Y=ne<Vr?K(Ge,ne++):0,Ve++,Y===10&&(Ve=1,wt++),Y}function pe(){return K(Ge,ne)}function it(){return ne}function Ke(e,t){return Se(Ge,e,t)}function He(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function St(e){return wt=Ve=1,Vr=oe(Ge=e),ne=0,[]}function Tt(e){return Ge="",e}function Xe(e){return Ct(Ke(ne-1,er(e===91?e+2:e===40?e+1:e)))}function qr(e){for(;(Y=pe())&&Y<33;)se();return He(e)>2||He(Y)>3?"":" "}function Kr(e,t){for(;--t&&se()&&!(Y<48||Y>102||Y>57&&Y<65||Y>70&&Y<97););return Ke(e,it()+(t<6&&pe()==32&&se()==32))}function er(e){for(;se();)switch(Y){case e:return ne;case 34:case 39:e!==34&&e!==39&&er(Y);break;case 40:e===41&&er(e);break;case 92:se();break}return ne}function Xr(e,t){for(;se()&&e+Y!==57;)if(e+Y===84&&pe()===47)break;return"/*"+Ke(t,ne-1)+"*"+je(e===47?e:se())}function Yr(e){for(;!He(pe());)se();return Ke(e,ne)}function Zr(e){return Tt(Pt("",null,null,null,[""],e=St(e),0,[0],e))}function Pt(e,t,r,o,n,s,a,i,c){for(var l=0,p=0,x=a,u=0,w=0,h=0,m=1,d=1,f=1,g=0,T="",j=n,L=s,O=o,v=T;d;)switch(h=g,g=se()){case 40:if(h!=108&&K(v,x-1)==58){st(v+=F(Xe(g),"&","&\f"),"&\f")!=-1&&(f=-1);break}case 34:case 39:case 91:v+=Xe(g);break;case 9:case 10:case 13:case 32:v+=qr(h);break;case 92:v+=Kr(it()-1,7);continue;case 47:switch(pe()){case 42:case 47:_e(ss(Xr(se(),it()),t,r),c);break;default:v+="/"}break;case 123*m:i[l++]=oe(v)*f;case 125*m:case 59:case 0:switch(g){case 0:case 125:d=0;case 59+p:f==-1&&(v=F(v,/\f/g,"")),w>0&&oe(v)-x&&_e(w>32?Qr(v+";",o,r,x-1):Qr(F(v," ","")+";",o,r,x-2),c);break;case 59:v+=";";default:if(_e(O=Jr(v,t,r,l,p,n,i,T,j=[],L=[],x),s),g===123)if(p===0)Pt(v,t,O,O,j,s,x,i,L);else switch(u===99&&K(v,3)===110?100:u){case 100:case 108:case 109:case 115:Pt(e,O,O,o&&_e(Jr(e,O,O,0,0,n,i,T,n,j=[],x),L),n,L,x,i,o?j:L);break;default:Pt(v,O,O,O,[""],L,0,i,L)}}l=p=w=0,m=f=1,T=v="",x=a;break;case 58:x=1+oe(v),w=h;default:if(m<1){if(g==123)--m;else if(g==125&&m++==0&&Gr()==125)continue}switch(v+=je(g),g*m){case 38:f=p>0?1:(v+="\f",-1);break;case 44:i[l++]=(oe(v)-1)*f,f=1;break;case 64:pe()===45&&(v+=Xe(se())),u=pe(),p=x=oe(T=v+=Yr(it())),g++;break;case 45:h===45&&oe(v)==2&&(m=0)}}return s}function Jr(e,t,r,o,n,s,a,i,c,l,p){for(var x=n-1,u=n===0?s:[""],w=De(u),h=0,m=0,d=0;h<o;++h)for(var f=0,g=Se(e,x+1,x=Ur(m=a[h])),T=e;f<w;++f)(T=Ct(m>0?u[f]+" "+g:F(g,/&\f/g,u[f])))&&(c[d++]=T);return at(e,t,r,n===0?Be:i,c,l,p)}function ss(e,t,r){return at(e,t,r,vt,je(Hr()),Se(e,2,-2),0)}function Qr(e,t,r,o){return at(e,t,r,Ue,Se(e,0,o),Se(e,o+1,-1),o)}function Ne(e,t){for(var r="",o=De(e),n=0;n<o;n++)r+=t(e[n],n,e,t)||"";return r}function eo(e,t,r,o){switch(e.type){case Br:if(e.children.length)break;case Wr:case Ue:return e.return=e.return||e.value;case vt:return"";case bt:return e.return=e.value+"{"+Ne(e.children,o)+"}";case Be:e.value=e.props.join(",")}return oe(r=Ne(e.children,o))?e.return=e.value+"{"+r+"}":""}function to(e){var t=De(e);return function(r,o,n,s){for(var a="",i=0;i<t;i++)a+=e[i](r,o,n,s)||"";return a}}function ro(e){return function(t){t.root||(t=t.return)&&e(t)}}var tr=function(t){var r=new WeakMap;return function(o){if(r.has(o))return r.get(o);var n=t(o);return r.set(o,n),n}};function oo(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var as=function(t,r,o){for(var n=0,s=0;n=s,s=pe(),n===38&&s===12&&(r[o]=1),!He(s);)se();return Ke(t,ne)},is=function(t,r){var o=-1,n=44;do switch(He(n)){case 0:n===38&&pe()===12&&(r[o]=1),t[o]+=as(ne-1,r,o);break;case 2:t[o]+=Xe(n);break;case 4:if(n===44){t[++o]=pe()===58?"&\f":"",r[o]=t[o].length;break}default:t[o]+=je(n)}while(n=se());return t},cs=function(t,r){return Tt(is(St(t),r))},no=new WeakMap,ls=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var r=t.value,o=t.parent,n=t.column===o.column&&t.line===o.line;o.type!=="rule";)if(o=o.parent,!o)return;if(!(t.props.length===1&&r.charCodeAt(0)!==58&&!no.get(o))&&!n){no.set(t,!0);for(var s=[],a=cs(r,s),i=o.props,c=0,l=0;c<a.length;c++)for(var p=0;p<i.length;p++,l++)t.props[l]=s[c]?a[c].replace(/&\f/g,i[p]):i[p]+" "+a[c]}}},ds=function(t){if(t.type==="decl"){var r=t.value;r.charCodeAt(0)===108&&r.charCodeAt(2)===98&&(t.return="",t.value="")}};function so(e,t){switch(_r(e,t)){case 5103:return N+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return N+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return N+e+nt+e+ee+e+e;case 6828:case 4268:return N+e+ee+e+e;case 6165:return N+e+ee+"flex-"+e+e;case 5187:return N+e+F(e,/(\w+).+(:[^]+)/,N+"box-$1$2"+ee+"flex-$1$2")+e;case 5443:return N+e+ee+"flex-item-"+F(e,/flex-|-self/,"")+e;case 4675:return N+e+ee+"flex-line-pack"+F(e,/align-content|flex-|-self/,"")+e;case 5548:return N+e+ee+F(e,"shrink","negative")+e;case 5292:return N+e+ee+F(e,"basis","preferred-size")+e;case 6060:return N+"box-"+F(e,"-grow","")+N+e+ee+F(e,"grow","positive")+e;case 4554:return N+F(e,/([^-])(transform)/g,"$1"+N+"$2")+e;case 6187:return F(F(F(e,/(zoom-|grab)/,N+"$1"),/(image-set)/,N+"$1"),e,"")+e;case 5495:case 3959:return F(e,/(image-set\([^]*)/,N+"$1$`$1");case 4968:return F(F(e,/(.+:)(flex-)?(.*)/,N+"box-pack:$3"+ee+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+N+e+e;case 4095:case 3583:case 4068:case 2532:return F(e,/(.+)-inline(.+)/,N+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(oe(e)-1-t>6)switch(K(e,t+1)){case 109:if(K(e,t+4)!==45)break;case 102:return F(e,/(.+:)(.+)-([^]+)/,"$1"+N+"$2-$3$1"+nt+(K(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~st(e,"stretch")?so(F(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(K(e,t+1)!==115)break;case 6444:switch(K(e,oe(e)-3-(~st(e,"!important")&&10))){case 107:return F(e,":",":"+N)+e;case 101:return F(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+N+(K(e,14)===45?"inline-":"")+"box$3$1"+N+"$2$3$1"+ee+"$2box$3")+e}break;case 5936:switch(K(e,t+11)){case 114:return N+e+ee+F(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return N+e+ee+F(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return N+e+ee+F(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return N+e+ee+e+e}return e}var us=function(t,r,o,n){if(t.length>-1&&!t.return)switch(t.type){case Ue:t.return=so(t.value,t.length);break;case bt:return Ne([qe(t,{value:F(t.value,"@","@"+N)})],n);case Be:if(t.length)return Zt(t.props,function(s){switch(Qt(s,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Ne([qe(t,{props:[F(s,/:(read-\w+)/,":"+nt+"$1")]})],n);case"::placeholder":return Ne([qe(t,{props:[F(s,/:(plac\w+)/,":"+N+"input-$1")]}),qe(t,{props:[F(s,/:(plac\w+)/,":"+nt+"$1")]}),qe(t,{props:[F(s,/:(plac\w+)/,ee+"input-$1")]})],n)}return""})}},fs=[us],At=function(t){var r=t.key;if(r==="css"){var o=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(o,function(m){var d=m.getAttribute("data-emotion");d.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var n=t.stylisPlugins||fs,s={},a,i=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+r+' "]'),function(m){for(var d=m.getAttribute("data-emotion").split(" "),f=1;f<d.length;f++)s[d[f]]=!0;i.push(m)});var c,l=[ls,ds];{var p,x=[eo,ro(function(m){p.insert(m)})],u=to(l.concat(n,x)),w=function(d){return Ne(Zr(d),u)};c=function(d,f,g,T){p=g,w(d?d+"{"+f.styles+"}":f.styles),T&&(h.inserted[f.name]=!0)}}var h={key:r,sheet:new Or({key:r,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:s,registered:{},insert:c};return h.sheet.hydrate(i),h};function ao(e){for(var t=0,r,o=0,n=e.length;n>=4;++o,n-=4)r=e.charCodeAt(o)&255|(e.charCodeAt(++o)&255)<<8|(e.charCodeAt(++o)&255)<<16|(e.charCodeAt(++o)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(n){case 3:t^=(e.charCodeAt(o+2)&255)<<16;case 2:t^=(e.charCodeAt(o+1)&255)<<8;case 1:t^=e.charCodeAt(o)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var io={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};var ps=!1,ms=/[A-Z]|^ms/g,hs=/_EMO_([^_]+?)_([^]*?)_EMO_/g,fo=function(t){return t.charCodeAt(1)===45},co=function(t){return t!=null&&typeof t!="boolean"},rr=oo(function(e){return fo(e)?e:e.replace(ms,"-$&").toLowerCase()}),lo=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(hs,function(o,n,s){return xe={name:n,styles:s,next:xe},n})}return io[t]!==1&&!fo(t)&&typeof r=="number"&&r!==0?r+"px":r},gs="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function ct(e,t,r){if(r==null)return"";var o=r;if(o.__emotion_styles!==void 0)return o;switch(typeof r){case"boolean":return"";case"object":{var n=r;if(n.anim===1)return xe={name:n.name,styles:n.styles,next:xe},n.name;var s=r;if(s.styles!==void 0){var a=s.next;if(a!==void 0)for(;a!==void 0;)xe={name:a.name,styles:a.styles,next:xe},a=a.next;var i=s.styles+";";return i}return xs(e,t,r)}case"function":{if(e!==void 0){var c=xe,l=r(e);return xe=c,ct(e,t,l)}break}}var p=r;if(t==null)return p;var x=t[p];return x!==void 0?x:p}function xs(e,t,r){var o="";if(Array.isArray(r))for(var n=0;n<r.length;n++)o+=ct(e,t,r[n])+";";else for(var s in r){var a=r[s];if(typeof a!="object"){var i=a;t!=null&&t[i]!==void 0?o+=s+"{"+t[i]+"}":co(i)&&(o+=rr(s)+":"+lo(s,i)+";")}else{if(s==="NO_COMPONENT_SELECTOR"&&ps)throw new Error(gs);if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var c=0;c<a.length;c++)co(a[c])&&(o+=rr(s)+":"+lo(s,a[c])+";");else{var l=ct(e,t,a);switch(s){case"animation":case"animationName":{o+=rr(s)+":"+l+";";break}default:o+=s+"{"+l+"}"}}}}return o}var uo=/label:\s*([^\s;{]+)\s*(;|$)/g,xe;function ie(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var o=!0,n="";xe=void 0;var s=e[0];if(s==null||s.raw===void 0)o=!1,n+=ct(r,t,s);else{var a=s;n+=a[0]}for(var i=1;i<e.length;i++)if(n+=ct(r,t,e[i]),o){var c=s;n+=c[i]}uo.lastIndex=0;for(var l="",p;(p=uo.exec(n))!==null;)l+="-"+p[1];var x=ao(n)+l;return{name:x,styles:n,next:xe}}var ys=!0;function Te(e,t,r){var o="";return r.split(" ").forEach(function(n){e[n]!==void 0?t.push(e[n]+";"):n&&(o+=n+" ")}),o}var Ye=function(t,r,o){var n=t.key+"-"+r.name;(o===!1||ys===!1)&&t.registered[n]===void 0&&(t.registered[n]=r.styles)},Je=function(t,r,o){Ye(t,r,o);var n=t.key+"-"+r.name;if(t.inserted[r.name]===void 0){var s=r;do t.insert(r===s?"."+n:"",s,t.sheet,!0),s=s.next;while(s!==void 0)}};function po(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function mo(e,t,r){var o=[],n=Te(e,o,r);return o.length<2?r:n+t(o)}var Le=function(t){var r=At(t);r.sheet.speedy=function(i){this.isSpeedy=i},r.compat=!0;var o=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];var x=ie(l,r.registered,void 0);return Je(r,x,!1),r.key+"-"+x.name},n=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];var x=ie(l,r.registered),u="animation-"+x.name;return po(r,{name:x.name,styles:"@keyframes "+u+"{"+x.styles+"}"}),u},s=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];var x=ie(l,r.registered);po(r,x)},a=function(){for(var c=arguments.length,l=new Array(c),p=0;p<c;p++)l[p]=arguments[p];return mo(r.registered,o,vs(l))};return{css:o,cx:a,injectGlobal:s,keyframes:n,hydrate:function(c){c.forEach(function(l){r.inserted[l]=!0})},flush:function(){r.registered={},r.inserted={},r.sheet.flush()},sheet:r.sheet,cache:r,getRegisteredStyles:Te.bind(null,r.registered),merge:mo.bind(null,r.registered,o)}},vs=function e(t){for(var r="",o=0;o<t.length;o++){var n=t[o];if(n!=null){var s=void 0;switch(typeof n){case"boolean":break;case"object":{if(Array.isArray(n))s=e(n);else{s="";for(var a in n)n[a]&&a&&(s&&(s+=" "),s+=a)}break}default:s=n}s&&(r&&(r+=" "),r+=s)}}return r};var ye=Le({key:"css"}),Xa=ye.flush,Ya=ye.hydrate,Ja=ye.cx,Qa=ye.merge,Za=ye.getRegisteredStyles,ei=ye.injectGlobal,ti=ye.keyframes,ri=ye.css,oi=ye.sheet,ho=ye.cache;var go=(function(){function e(){Rr(this,e),Er(this,"_cacheList",[ho])}return $r(e,[{key:"add",value:function(r){var o=this.getCache(r.key);return o||(this._cacheList.push(r),r)}},{key:"delete",value:function(r){this._cacheList=this._cacheList.filter(function(o){return o.key!==r.key})}},{key:"hasCache",value:function(r){return this._cacheList.some(function(o){return o.key===r.key})}},{key:"getCache",value:function(r){return this._cacheList.find(function(o){return o.key===r})}},{key:"getCacheList",value:function(){return this._cacheList}}]),e})();var xo=typeof document<"u",or=function(t,r){return"".concat(t,"-").concat(r)},yo=function(t,r,o,n){var s=n.hashPriority||"high";Ye(t,r,o);var a=".".concat(or(t.key,r.name)),i=s==="low"?":where(".concat(a,")"):a;if(t.inserted[r.name]===void 0){var c="",l=r;do{var p=t.insert(r===l?i:"",l,t.sheet,!0);!xo&&p!==void 0&&(c+=p),l=l.next}while(l!==void 0);if(!xo&&c.length!==0)return c}};var Qe=function(t){return We(t)==="object"&&"styles"in t&&"name"in t&&"toString"in t},vo=function e(t){for(var r="",o=0;o<t.length;o++){var n=t[o];if(n!==null){var s=void 0;switch(We(n)){case"boolean":break;case"object":{if(Array.isArray(n))s=e(n);else{s="";for(var a in n)n[a]&&a&&(s&&(s+=" "),s+=a)}break}default:s=n}s&&(r&&(r+=" "),r+=s)}}return r},bo=function(t,r,o){var n=[],s=Te(t,n,o);return n.length<2?o:s+r(n)};var bs=function(t,r){return function(){for(var o=arguments.length,n=new Array(o),s=0;s<o;s++)n[s]=arguments[s];var a=ie(n,t.registered,void 0);return yo(t,a,!1,r),or(t.key,a.name)}},Cs=function(t,r){return function(){for(var o=arguments.length,n=new Array(o),s=0;s<o;s++)n[s]=arguments[s];var a=n.map(function(i){return Qe(i)?r(i):i});return bo(t.registered,r,vo(a))}},kt=function(t,r){var o=bs(t,{hashPriority:r.hashPriority||"high",label:r.label}),n=Cs(t,o);return{css:o,cx:n}};var he=function(){for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return ie(r)};var Co="acss";var yr=y(z());var wo=y(z()),So=function(t){return(0,wo.createContext)(t)};var ce=y(z()),Ot=y(z());var lt=y(z()),js=function(t){return t()},No=lt.useInsertionEffect?lt.useInsertionEffect:!1,lr=No||js,dr=No||lt.useLayoutEffect;var Lo=!1,zo=ce.createContext(typeof HTMLElement<"u"?At({key:"css"}):null),Ns=zo.Provider;var Wt=function(t){return(0,Ot.forwardRef)(function(r,o){var n=(0,Ot.useContext)(zo);return t(r,n,o)})},Pe=ce.createContext({});var Ls=function(t,r){if(typeof r=="function"){var o=r(t);return o}return Pr({},t,r)},zs=tr(function(e){return tr(function(t){return Ls(e,t)})}),fr=function(t){var r=ce.useContext(Pe);return t.theme!==r&&(r=zs(r)(t.theme)),ce.createElement(Pe.Provider,{value:r},t.children)};var Bt={}.hasOwnProperty,ur="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Oo=function(t,r){var o={};for(var n in r)Bt.call(r,n)&&(o[n]=r[n]);return o[ur]=t,o},Os=function(t){var r=t.cache,o=t.serialized,n=t.isStringTag;return Ye(r,o,n),lr(function(){return Je(r,o,n)}),null},Ws=Wt(function(e,t,r){var o=e.css;typeof o=="string"&&t.registered[o]!==void 0&&(o=t.registered[o]);var n=e[ur],s=[o],a="";typeof e.className=="string"?a=Te(t.registered,s,e.className):e.className!=null&&(a=e.className+" ");var i=ie(s,void 0,ce.useContext(Pe));a+=t.key+"-"+i.name;var c={};for(var l in e)Bt.call(e,l)&&l!=="css"&&l!==ur&&!Lo&&(c[l]=e[l]);return c.className=a,r&&(c.ref=r),ce.createElement(ce.Fragment,null,ce.createElement(Os,{cache:t,serialized:i,isStringTag:typeof n=="string"}),ce.createElement(n,c))}),Wo=Ws;var Ae=y(z());var Yi=y(jo()),Bo=function(t,r){var o=arguments;if(r==null||!Bt.call(r,"css"))return Ae.createElement.apply(void 0,o);var n=o.length,s=new Array(n);s[0]=Wo,s[1]=Oo(t,r);for(var a=2;a<n;a++)s[a]=o[a];return Ae.createElement.apply(null,s)};(function(e){var t;t||(t=e.JSX||(e.JSX={}))})(Bo||(Bo={}));var Uo=Wt(function(e,t){var r=e.styles,o=ie([r],void 0,Ae.useContext(Pe)),n=Ae.useRef();return dr(function(){var s=t.key+"-global",a=new t.sheet.constructor({key:s,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),i=!1,c=document.querySelector('style[data-emotion="'+s+" "+o.name+'"]');return t.sheet.tags.length&&(a.before=t.sheet.tags[0]),c!==null&&(i=!0,c.setAttribute("data-emotion",s),a.hydrate([c])),n.current=[a,i],function(){a.flush()}},[t]),dr(function(){var s=n.current,a=s[0],i=s[1];if(i){s[1]=!1;return}if(o.next!==void 0&&Je(t,o.next,!0),a.tags.length){var c=a.tags[a.tags.length-1].nextElementSibling;a.before=c,a.flush()}t.insert("",o,a,!1)},[t,o.name]),null});var Do=y(z()),_o=y(B()),Vo=function(t){return function(){for(var r=arguments.length,o=new Array(r),n=0;n<r;n++)o[n]=arguments[n];return(0,Do.memo)(function(s){var a=t();return(0,_o.jsx)(Uo,{styles:ie(o,void 0,A(A({},s),{},{theme:a}))})})}};var Ho=function(t){return function(r){var o=t(r);return function(n){var s=o(n),a=s.styles;return a}}};var ke=y(z()),pr=y(B()),Bs=["children","prefix","speedy","getStyleManager","container","nonce","insertionPoint","stylisPlugins","linters"],Go=function(t){return(0,ke.memo)(function(r){var o=r.children,n=r.prefix,s=r.speedy,a=r.getStyleManager,i=r.container,c=r.nonce,l=r.insertionPoint,p=r.stylisPlugins,x=r.linters,u=Ie(r,Bs),w=(0,ke.useContext)(t),h=n??w.sheet.key,m=i??w.sheet.container,d=s??w.sheet.isSpeedy,f=(0,ke.useMemo)(function(){var T=!1,j=Le({speedy:d??T,key:h,container:m,nonce:c,insertionPoint:l,stylisPlugins:p});if(typeof global<"u"){var L=global.__ANTD_STYLE_CACHE_MANAGER_FOR_SSR__;L&&(j.cache=L.add(j.cache))}return j},[h,d,m,c,l,p]);(0,ke.useEffect)(function(){a?.(f)},[f]);var g=(0,pr.jsx)(t.Provider,{value:f,children:o});return Object.keys(u).length||m?(0,pr.jsx)(kr,A(A({linters:x,container:m},u),{},{children:g})):g})};var dt=y(z());var Jo=y(z());var qo=function(t){var r=t.css,o=t.token;return{buttonDefaultHover:r({backgroundColor:o.colorBgContainer,border:"1px solid ".concat(o.colorBorder),cursor:"pointer",":hover":{color:o.colorPrimaryHover,borderColor:o.colorPrimaryHover},":active":{color:o.colorPrimaryActive,borderColor:o.colorPrimaryActive}})}};var Ko=function(t){return Object.fromEntries(Object.entries(t).map(function(r){var o=ae(r,2),n=o[0],s=o[1];return[n,s.styles]}))};var Ze=function(){var t=Fe.useToken(),r=t.token;return r};var Yo=y(z());var Xo=y(z());var Ee=function(t){return typeof window<"u"?matchMedia&&matchMedia("(prefers-color-scheme: ".concat(t,")")):{matches:!1}};var mr,Ut=(0,Xo.createContext)({appearance:"light",setAppearance:function(){},isDarkMode:!1,themeMode:"light",setThemeMode:function(){},browserPrefers:(mr=Ee("dark"))!==null&&mr!==void 0&&mr.matches?"dark":"light"});var Re=function(){return(0,Yo.useContext)(Ut)};var Qo=function(){var t=Ze(),r=Re(),o=r.appearance,n=r.isDarkMode;return(0,Jo.useMemo)(function(){return Ko(qo({token:t,css:he,appearance:o,isDarkMode:n}))},[t,o,n])};var Zo=y(z());var Dt=function(){var t=Ze(),r=Qo();return(0,Zo.useMemo)(function(){return A(A({},t),{},{stylish:r})},[t,r])};var en=function(t){return A(A({},t),{},{mobile:t.xs,tablet:t.md,laptop:t.lg,desktop:t.xxl})};var tn=y(z()),rn=function(){var t=Ze(),r={xs:"@media (max-width: ".concat(t.screenXSMax,"px)"),sm:"@media (max-width: ".concat(t.screenSMMax,"px)"),md:"@media (max-width: ".concat(t.screenMDMax,"px)"),lg:"@media (max-width: ".concat(t.screenLGMax,"px)"),xl:"@media (max-width: ".concat(t.screenXLMax,"px)"),xxl:"@media (min-width: ".concat(t.screenXXLMin,"px)")};return(0,tn.useMemo)(function(){return en(r)},[t])},on=function(t,r){return Object.entries(t).map(function(o){var n=ae(o,2),s=n[0],a=n[1],i=a;return Qe(a)||(i=he(a)),r[s]?"".concat(r[s]," {").concat(i.styles,"}"):""}).join("")};var Us=["stylish","appearance","isDarkMode","prefixCls","iconPrefixCls"],Ds=["prefixCls","iconPrefixCls"],nn=function(t){var r=t.hashPriority,o=t.useTheme,n=t.EmotionContext;return function(s,a){var i=a?.__BABEL_FILE_NAME__,c=!!i;return function(l){var p=o(),x=(0,dt.useContext)(n),u=x.cache,w=kt(u,{hashPriority:a?.hashPriority||r,label:a?.label}),h=w.cx,m=w.css,d=rn(),f=(0,dt.useMemo)(function(){var g;if(s instanceof Function){var T=p.stylish,j=p.appearance,L=p.isDarkMode,O=p.prefixCls,v=p.iconPrefixCls,G=Ie(p,Us),Q=function(_){return on(_,d)};Object.assign(Q,d),g=s({token:G,stylish:T,appearance:j,isDarkMode:L,prefixCls:O,iconPrefixCls:v,cx:h,css:he,responsive:Q},l)}else g=s;return We(g)==="object"&&(Qe(g)?g=m(g):g=Object.fromEntries(Object.entries(g).map(function(ue){var _=ae(ue,2),be=_[0],fe=_[1],tt=c?"".concat(i,"-").concat(be):void 0;return We(fe)==="object"?c?[be,m(fe,"label:".concat(tt))]:[be,m(fe)]:[be,fe]}))),g},[l,p]);return(0,dt.useMemo)(function(){var g=p.prefixCls,T=p.iconPrefixCls,j=Ie(p,Ds);return{styles:f,cx:h,theme:j,prefixCls:g,iconPrefixCls:T}},[f,p])}}};var pt=y(z());var sn=y(B()),hr=function(t){if(t.ThemeProvider)return t.ThemeProvider;var r=t.ThemeContext;return function(o){return(0,sn.jsx)(r.Provider,{value:o.theme,children:o.children})}};var an=fr,_t=Pe;var et=y(z());var cn=y(B()),ln=(0,et.memo)(function(e){var t=e.children,r=e.theme,o=e.prefixCls,n=e.getStaticInstance,s=e.staticInstanceConfig,a=Re(),i=a.appearance,c=a.isDarkMode,l=Mr.useMessage(s?.message),p=ae(l,2),x=p[0],u=p[1],w=Fr.useNotification(s?.notification),h=ae(w,2),m=h[0],d=h[1],f=Ir.useModal(),g=ae(f,2),T=g[0],j=g[1];(0,et.useEffect)(function(){n?.({message:x,modal:T,notification:m})},[]);var L=(0,et.useMemo)(function(){var O=c?Fe.darkAlgorithm:Fe.defaultAlgorithm,v=r;if(typeof r=="function"&&(v=r(i)),!v)return{algorithm:O};var G=v.algorithm?v.algorithm instanceof Array?v.algorithm:[v.algorithm]:[];return A(A({},v),{},{algorithm:v.algorithm?[O].concat(Ar(G)):O})},[r,c]);return(0,cn.jsxs)(ht,{prefixCls:o,theme:L,children:[u,d,j,t]})});ln.displayName="AntdProvider";var dn=ln;var ze=y(z());var fn=y(z());function _s(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var o,n,s,a,i=[],c=!0,l=!1;try{if(s=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;c=!1}else for(;!(c=(o=s.call(r)).done)&&(i.push(o.value),i.length!==t);c=!0);}catch(p){l=!0,n=p}finally{try{if(!c&&r.return!=null&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw n}}return i}}function Vs(e,t){return Hs(e)||_s(e,t)||Gs(e,t)||qs()}function Hs(e){if(Array.isArray(e))return e}function Gs(e,t){if(e){if(typeof e=="string")return un(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return un(e,t)}}function un(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,o=new Array(t);r<t;r++)o[r]=e[r];return o}function qs(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
2
2
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ks(e,t){var r=t||{},o=r.defaultValue,n=r.value,s=r.onChange,a=r.postState,i=fn.default.useState(function(){return n!==void 0?n:o!==void 0?typeof o=="function"?o():o:typeof e=="function"?e():e}),c=Vs(i,2),l=c[0],p=c[1],x=n!==void 0?n:l;a&&(x=a(x));function u(w){p(w),x!==w&&s&&s(w,x)}return[x,u]}var gr=Ks;var xr=y(z()),Vt=function(t){typeof xr.startTransition=="function"?(0,xr.startTransition)(t):t()};var pn=y(B()),mn=y(B()),$e,Xs=function(t){var r=t.themeMode,o=t.setAppearance,n=t.setBrowserPrefers,s=function(){Vt(function(){Ee("dark").matches?o("dark"):o("light")})},a=function(){Vt(function(){Ee("dark").matches?n("dark"):n("light")})};return(0,ze.useLayoutEffect)(function(){if(r!=="auto"){Vt(function(){o(r)});return}return setTimeout(s,1),$e||($e=Ee("dark")),$e.addEventListener("change",s),function(){$e.removeEventListener("change",s)}},[r]),(0,ze.useLayoutEffect)(function(){return $e||($e=Ee("dark")),$e.addEventListener("change",a),function(){$e.removeEventListener("change",a)}},[]),null},hn=(0,ze.memo)(function(e){var t,r=e.children,o=e.appearance,n=e.defaultAppearance,s=e.onAppearanceChange,a=e.themeMode,i=e.defaultThemeMode,c=e.onThemeModeChange,l=e.useTheme,p=l(),x=p.appearance,u=p.themeMode,w=gr("light",{value:a,defaultValue:i??u,onChange:function(ue){return c?.(ue)}}),h=ae(w,2),m=h[0],d=h[1],f=gr("light",{value:o,defaultValue:n??x,onChange:function(ue){return s?.(ue)}}),g=ae(f,2),T=g[0],j=g[1],L=(0,ze.useState)((t=Ee("dark"))!==null&&t!==void 0&&t.matches?"dark":"light"),O=ae(L,2),v=O[0],G=O[1];return(0,mn.jsxs)(Ut.Provider,{value:{themeMode:m,setThemeMode:d,appearance:T,setAppearance:j,isDarkMode:T==="dark",browserPrefers:v},children:[typeof window<"u"&&(0,pn.jsx)(Xs,{themeMode:m,setAppearance:j,setBrowserPrefers:G}),r]})});hn.displayName="ThemeSwitcher";var gn=hn;var ut=y(z());var xn=y(B()),Ys=["stylish"],Js=function(t){var r=t.children,o=t.customToken,n=t.defaultCustomToken,s=t.customStylish,a=t.prefixCls,i=t.StyledThemeProvider,c=Re(),l=c.appearance,p=c.isDarkMode,x=Dt(),u=x.stylish,w=Ie(x,Ys),h=(0,ut.useMemo)(function(){return n?n instanceof Function?n({token:w,appearance:l,isDarkMode:p}):n:{}},[n,w,l]),m=(0,ut.useMemo)(function(){return o instanceof Function?A(A({},h),o({token:w,appearance:l,isDarkMode:p})):A(A({},h),o)},[h,o,w,l]),d=(0,ut.useMemo)(function(){return s?s({token:A(A({},w),m),stylish:u,appearance:l,isDarkMode:p,css:he}):{}},[s,w,m,u,l]),f=(0,ut.useMemo)(function(){return A(A({},d),u)},[d,u]),g=A(A(A(A({},w),m),{},{stylish:f},c),{},{prefixCls:a});return(0,xn.jsx)(i,{theme:g,children:r})},yn=Js;var ft=y(B()),vn=function(t){var r=t.styledConfig?hr(t.styledConfig):void 0,o=t.StyleEngineContext;return(0,pt.memo)(function(n){var s=n.children,a=n.customToken,i=n.customStylish,c=n.theme,l=n.getStaticInstance,p=n.prefixCls,x=n.staticInstanceConfig,u=n.appearance,w=n.defaultAppearance,h=n.onAppearanceChange,m=n.themeMode,d=n.defaultThemeMode,f=n.onThemeModeChange,g=n.styled,T=(0,pt.useContext)(o),j=T.prefixCls,L=T.StyledThemeContext,O=T.CustomThemeContext,v=(0,pt.useContext)(O),G=g?hr(g):r||an,Q=p||j;return(0,ft.jsx)(o.Provider,{value:{prefixCls:Q,StyledThemeContext:g?.ThemeContext||L||_t,CustomThemeContext:O},children:(0,ft.jsx)(gn,{themeMode:m,defaultThemeMode:d,onThemeModeChange:f,defaultAppearance:w,appearance:u,onAppearanceChange:h,useTheme:t.useTheme,children:(0,ft.jsx)(dn,{prefixCls:Q,staticInstanceConfig:x,theme:c,getStaticInstance:l,children:(0,ft.jsx)(yn,{prefixCls:Q,customToken:a,defaultCustomToken:v,customStylish:i,StyledThemeProvider:G,children:s})})})})})};var Oe=y(z());var bn=function(t){return function(){var r=t.StyleEngineContext,o=(0,Oe.useContext)(r),n=o.StyledThemeContext,s=o.CustomThemeContext,a=o.prefixCls,i=Dt(),c=Re(),l=(0,Oe.useContext)(s),p=(0,Oe.useContext)(n??_t)||{},x=(0,Oe.useContext)(ht.ConfigContext),u=x.iconPrefixCls,w=x.getPrefixCls,h=w(),m=a&&a!=="ant"?a:h,d=(0,Oe.useMemo)(function(){return A(A(A(A({},i),c),l),{},{prefixCls:m,iconPrefixCls:u})},[i,c,l,m,u]);return!p||Object.keys(p).length===0?d:A(A({},p),{},{prefixCls:m,iconPrefixCls:u})}};var Cn=new go;typeof global<"u"&&(global.__ANTD_STYLE_CACHE_MANAGER_FOR_SSR__=Cn);var wn=function(t){var r,o,n,s=A(A({},t),{},{key:(r=t.key)!==null&&r!==void 0?r:"zcss",speedy:(o=t.speedy)!==null&&o!==void 0?o:!1}),a=Le({key:s.key,speedy:s.speedy,container:s.container}),i=So(a),c=Go(i);a.cache=Cn.add(a.cache);var l=(0,yr.createContext)(s.customToken?s.customToken:{}),p=(n=s.styled)===null||n===void 0?void 0:n.ThemeContext,x=(0,yr.createContext)({CustomThemeContext:l,StyledThemeContext:p,prefixCls:s?.prefixCls,iconPrefixCls:s?.iconPrefixCls}),u=bn({StyleEngineContext:x}),w=nn({hashPriority:s.hashPriority,useTheme:u,EmotionContext:i}),h=Vo(u),m=Ho(w),d=vn({styledConfig:s.styled,StyleEngineContext:x,useTheme:u});d.displayName="AntdStyleThemeProvider";var f=kt(a.cache,{hashPriority:s.hashPriority}),g=f.cx,T=a.injectGlobal,j=a.keyframes;return{createStyles:w,createGlobalStyle:h,createStylish:m,css:he,cx:g,keyframes:j,injectGlobal:T,styleManager:a,useTheme:u,StyleProvider:c,ThemeProvider:d}};var ge=wn({key:Co,speedy:!1}),Sn=ge.createStyles,zl=ge.createGlobalStyle,Ol=ge.createStylish,Wl=ge.css,Bl=ge.cx,Ul=ge.keyframes,Dl=ge.injectGlobal,_l=ge.styleManager,Vl=ge.ThemeProvider,Hl=ge.StyleProvider,Gl=ge.useTheme;var C=y(z());var ra=y(z());var Tn={primary:{50:"#f0f4ff",100:"#e0e7ff",200:"#c7d2fe",300:"#a5b4fc",400:"#818cf8",500:"#6366f1",600:"#4f46e5",700:"#4338ca",800:"#3730a3",900:"#312e81"},success:"#22c55e",warning:"#f59e0b",error:"#ef4444",info:"#3b82f6",light:{bg:"#fafafa",surface:"rgba(255, 255, 255, 1)",surfaceHover:"#f9fafb",surfaceActive:"#f3f4f6",border:"#e5e7eb",borderHover:"#d1d5db",text:"#111827",textSecondary:"#6b7280",textMuted:"#9ca3af"},dark:{bg:"#0a0a0a",surface:"rgba(23, 23, 23, 0.95)",surfaceHover:"#1f1f1f",surfaceActive:"#262626",border:"#27272a",borderHover:"#3f3f46",text:"#fafafa",textSecondary:"#a1a1aa",textMuted:"#71717a"}},Pn={none:"0",sm:"4px",md:"10px",lg:"16px",xl:"20px",xxl:"28px",xxxl:"32px",full:"9999px"},An={0:"0",1:"4px",2:"8px",3:"12px",4:"16px",5:"20px",6:"24px",8:"32px",10:"40px",12:"48px"},kn={none:"none",sm:"0 1px 2px rgba(0, 0, 0, 0.04)",md:"0 2px 8px rgba(0, 0, 0, 0.06)",lg:"0 4px 12px rgba(0, 0, 0, 0.08)",xl:"0 8px 24px rgba(0, 0, 0, 0.1)"},En={fontFamily:'Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',sizes:{xs:{size:"12px",lineHeight:"16px",weight:400},sm:{size:"14px",lineHeight:"20px",weight:400},base:{size:"16px",lineHeight:"24px",weight:400},lg:{size:"18px",lineHeight:"28px",weight:500},xl:{size:"20px",lineHeight:"28px",weight:600},"2xl":{size:"24px",lineHeight:"32px",weight:600}}},Rn={duration:{fast:"150ms",normal:"250ms",slow:"350ms"},easing:{default:"cubic-bezier(0.4, 0, 0.2, 1)",bounce:"cubic-bezier(0.68, -0.55, 0.265, 1.55)"}},I={colors:Tn,radius:Pn,spacing:An,shadows:kn,typography:En,animation:Rn};var mt={token:{colorPrimary:I.colors.primary[500],colorPrimaryHover:I.colors.primary[600],colorPrimaryActive:I.colors.primary[700],colorSuccess:I.colors.success,colorWarning:I.colors.warning,colorError:I.colors.error,colorInfo:I.colors.info,colorText:I.colors.light.text,colorTextSecondary:I.colors.light.textSecondary,colorTextTertiary:I.colors.light.textMuted,colorBgContainer:I.colors.light.surface,colorBgElevated:I.colors.light.surface,colorBgLayout:I.colors.light.bg,colorBorder:I.colors.light.border,colorBorderSecondary:I.colors.light.borderHover,fontFamily:I.typography.fontFamily,fontSize:16,fontSizeSM:14,fontSizeLG:18,lineHeight:1.5,borderRadius:8,borderRadiusLG:12,borderRadiusSM:4,borderRadiusXS:2,boxShadow:I.shadows.md,boxShadowSecondary:I.shadows.lg,boxShadowTertiary:I.shadows.xl,motionDurationFast:I.animation.duration.fast,motionDurationMid:I.animation.duration.normal,motionDurationSlow:I.animation.duration.slow},components:{Card:{borderRadius:12,boxShadow:"0 2px 8px rgba(0, 0, 0, 0.06)"},Button:{borderRadius:8,controlHeight:40,controlHeightLG:44,controlHeightSM:32},Input:{borderRadius:8,controlHeight:40},Modal:{borderRadius:16},Select:{borderRadius:8,controlHeight:40},Tag:{borderRadius:4},Alert:{borderRadius:8},Menu:{borderRadius:8},Dropdown:{borderRadius:8}}},Qs={...mt,token:{...mt.token,colorText:I.colors.dark.text,colorTextSecondary:I.colors.dark.textSecondary,colorTextTertiary:I.colors.dark.textMuted,colorBgContainer:I.colors.dark.surface,colorBgElevated:I.colors.dark.surface,colorBgLayout:I.colors.dark.bg,colorBgMask:"rgba(0, 0, 0, 0.7)",colorBorder:I.colors.dark.border,colorBorderSecondary:I.colors.dark.borderHover},components:{...mt.components,Modal:{...mt.components?.Modal,colorBgElevated:I.colors.dark.surface}}};var{colors:Ql,radius:Zl,spacing:ed,shadows:td,typography:rd,animation:od}=I;var Mn=y(B()),{Text:xd}=gt;var vr=y(B()),{Text:Td}=gt;var Ht=y(z());var In=y(z());var na=y(B());var sa=y(z());var Fn=y(B()),{useToken:Bd}=Fe;var Ud=Sn(({token:e,css:t})=>({surface:t`
|
|
3
3
|
position: relative;
|
|
4
4
|
display: flex;
|