hermes-web-ui 0.2.2 → 0.2.4

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.
Files changed (99) hide show
  1. package/README.md +30 -6
  2. package/bin/hermes-web-ui.mjs +34 -4
  3. package/dist/assets/{Button-CpNld4Mc.js → Button-sJ2BpaPl.js} +14 -14
  4. package/dist/assets/{ChannelsView-BWEvTQwM.css → ChannelsView-C2h4_vNn.css} +1 -1
  5. package/dist/assets/ChannelsView-CD_79lUP.js +1 -0
  6. package/dist/assets/ChatView-CLIjlJ1x.js +142 -0
  7. package/dist/assets/ChatView-CX_ZYhvz.css +1 -0
  8. package/dist/assets/Close-2w73mIOt.js +45 -0
  9. package/dist/assets/FormItem-XpOdWzQ0.js +110 -0
  10. package/dist/assets/Input-BzhYBEbH.js +234 -0
  11. package/dist/assets/InputNumber-8txyKuLX.js +13 -0
  12. package/dist/assets/JobsView-C-1FgnDL.js +2 -0
  13. package/dist/assets/{JobsView-DkwaDky6.css → JobsView-OYrxaGgM.css} +1 -1
  14. package/dist/assets/LoginView-BD15AZNF.js +1 -0
  15. package/dist/assets/LoginView-BHThbj0n.css +1 -0
  16. package/dist/assets/LogsView-DmQ4ttpe.js +1 -0
  17. package/dist/assets/LogsView-DzYGlYxF.css +1 -0
  18. package/dist/assets/{MarkdownRenderer-C2pkccH2.js → MarkdownRenderer-DJm5zGZj.js} +2 -2
  19. package/dist/assets/MemoryView-DBtvO2X2.js +5 -0
  20. package/dist/assets/MemoryView-WR7DvkW0.css +1 -0
  21. package/dist/assets/Modal-D421R1s7.js +232 -0
  22. package/dist/assets/{ModelsView-CLdtVeiJ.css → ModelsView-Dm1vBT2p.css} +1 -1
  23. package/dist/assets/ModelsView-Dt3deKCr.js +1 -0
  24. package/dist/assets/Popover-pOQtxFC1.js +117 -0
  25. package/dist/assets/Select-rOqAn7Lj.js +340 -0
  26. package/dist/assets/SettingRow-CndAlF8Z.js +1 -0
  27. package/dist/assets/SettingsView-CIcrKeJw.css +1 -0
  28. package/dist/assets/SettingsView-CxEQl8Fh.js +352 -0
  29. package/dist/assets/SkillsView-4FLTf1XD.css +1 -0
  30. package/dist/assets/SkillsView-BopVAaC6.js +1 -0
  31. package/dist/assets/Spin-CaLC5eru.js +43 -0
  32. package/dist/assets/Suffix-C1X_jn5E.js +101 -0
  33. package/dist/assets/Switch-BeZgnVyD.js +102 -0
  34. package/dist/assets/Tag-DFrN7AVl.js +71 -0
  35. package/dist/assets/Tooltip-ClSL1Ac2.js +1 -0
  36. package/dist/assets/{UsageView-CXSijPwc.css → UsageView-Bdck_cnA.css} +1 -1
  37. package/dist/assets/UsageView-BvGRIGlC.js +1 -0
  38. package/dist/assets/_plugin-vue_export-helper-DQGaK6t5.js +3 -0
  39. package/dist/assets/app-DHhjDueA.js +1 -0
  40. package/dist/assets/app-DqRfMAIZ.js +1 -0
  41. package/dist/assets/browser-Bf2Q3p4g.js +47 -0
  42. package/dist/assets/chat-B0V07VGa.js +6 -0
  43. package/dist/assets/context-Bm7UPqDk.js +1 -0
  44. package/dist/assets/index-BR3ulF5g.css +1 -0
  45. package/dist/assets/index-Bdq3IZmO.js +306 -0
  46. package/dist/assets/jobs-QM3wEm9o.js +1 -0
  47. package/dist/assets/logo-CiQBpLPw.js +1 -0
  48. package/dist/assets/pinia-bZ6_VpBU.js +1 -0
  49. package/dist/assets/router-Ddepf70Q.js +4 -0
  50. package/dist/assets/{sessions-DYkP_X2v.js → sessions-r2FX4lYx.js} +1 -1
  51. package/dist/assets/{skills-C6QBmS9j.js → skills-DtNdlEJd.js} +1 -1
  52. package/dist/assets/use-message-DAtcV1hg.js +1 -0
  53. package/dist/index.html +18 -18
  54. package/dist/server/index.js +104 -61
  55. package/dist/server/routes/filesystem.js +38 -0
  56. package/dist/server/services/auth.d.ts +9 -0
  57. package/dist/server/services/auth.js +67 -0
  58. package/dist/server/services/hermes-cli.js +13 -1
  59. package/package.json +2 -2
  60. package/dist/assets/ChannelsView-BGXB46ZU.js +0 -1
  61. package/dist/assets/ChatView-BVHQ6KhU.css +0 -1
  62. package/dist/assets/ChatView-CaO-j1NR.js +0 -142
  63. package/dist/assets/Close-BAvirVyH.js +0 -45
  64. package/dist/assets/FormItem-DUC1YCrh.js +0 -110
  65. package/dist/assets/Input-CCmp4iGM.js +0 -234
  66. package/dist/assets/InputNumber-DpIdrMEW.js +0 -13
  67. package/dist/assets/JobsView-t5o1pB0r.js +0 -2
  68. package/dist/assets/LogsView-B2TeFIUX.css +0 -1
  69. package/dist/assets/LogsView-QqOV3ZEf.js +0 -1
  70. package/dist/assets/MemoryView-CHeaa1-C.css +0 -1
  71. package/dist/assets/MemoryView-oeAn8ZfB.js +0 -5
  72. package/dist/assets/Modal-BljFqAJF.js +0 -232
  73. package/dist/assets/ModelsView-DvK44HBy.js +0 -1
  74. package/dist/assets/Popover-BQMR8Xxo.js +0 -117
  75. package/dist/assets/Select-D33SMWcz.js +0 -340
  76. package/dist/assets/SettingRow-BxCsRfGG.js +0 -102
  77. package/dist/assets/SettingsView-CK9ArFcg.js +0 -352
  78. package/dist/assets/SettingsView-Cl1ts-YY.css +0 -1
  79. package/dist/assets/SkillsView-BvNhRbMq.css +0 -1
  80. package/dist/assets/SkillsView-_z2SQ9kJ.js +0 -1
  81. package/dist/assets/Spin-CwbBDHwW.js +0 -43
  82. package/dist/assets/Suffix-CKUJBJSi.js +0 -101
  83. package/dist/assets/Tag-87KswiOb.js +0 -71
  84. package/dist/assets/Tooltip-CuLVJgy8.js +0 -1
  85. package/dist/assets/UsageView-COiUupLe.js +0 -1
  86. package/dist/assets/_plugin-vue_export-helper-C7dadZ10.js +0 -49
  87. package/dist/assets/app-DX-WvBe8.js +0 -1
  88. package/dist/assets/app-DwI_Lyfm.js +0 -1
  89. package/dist/assets/chat-De2jGIM6.js +0 -6
  90. package/dist/assets/client-D-w1KhaU.js +0 -1
  91. package/dist/assets/context-vjXbZCu8.js +0 -1
  92. package/dist/assets/index-D3MGnlpF.js +0 -307
  93. package/dist/assets/index-DCNlSGk-.css +0 -1
  94. package/dist/assets/jobs-B2WdYQNb.js +0 -1
  95. package/dist/assets/pinia-B4dETPKk.js +0 -1
  96. package/dist/assets/preload-helper-D4M6sveU.js +0 -1
  97. package/dist/assets/use-message-BeTKmVAO.js +0 -1
  98. package/dist/assets/vue.runtime.esm-bundler-BoqZ7fRe.js +0 -3
  99. /package/dist/{assets/logo-BAarh-tH.png → logo.png} +0 -0
@@ -0,0 +1,47 @@
1
+ import{B as e,C as t,F as n,I as r,K as i,N as a,U as o,V as s,X as c,Z as l,ct as u,d,dt as f,j as p,lt as m,st as ee,v as te,y as ne}from"./router-Ddepf70Q.js";function re(e){let t=`.`,n=`__`,r=`--`,i;if(e){let i=e.blockPrefix;i&&(t=i),i=e.elementPrefix,i&&(n=i),i=e.modifierPrefix,i&&(r=i)}let a={install(e){i=e.c;let t=e.context;t.bem={},t.bem.b=null,t.bem.els=null}};function o(e){let n,r;return{before(e){n=e.bem.b,r=e.bem.els,e.bem.els=null},after(e){e.bem.b=n,e.bem.els=r},$({context:n,props:r}){return e=typeof e==`string`?e:e({context:n,props:r}),n.bem.b=e,`${r?.bPrefix||t}${n.bem.b}`}}}function s(e){let r;return{before(e){r=e.bem.els},after(e){e.bem.els=r},$({context:r,props:i}){return e=typeof e==`string`?e:e({context:r,props:i}),r.bem.els=e.split(`,`).map(e=>e.trim()),r.bem.els.map(e=>`${i?.bPrefix||t}${r.bem.b}${n}${e}`).join(`, `)}}}function c(e){return{$({context:i,props:a}){e=typeof e==`string`?e:e({context:i,props:a});let o=e.split(`,`).map(e=>e.trim());function s(e){return o.map(o=>`&${a?.bPrefix||t}${i.bem.b}${e===void 0?``:`${n}${e}`}${r}${o}`).join(`, `)}let c=i.bem.els;return c===null?s():s(c[0])}}}function l(e){return{$({context:i,props:a}){e=typeof e==`string`?e:e({context:i,props:a});let o=i.bem.els;return`&:not(${a?.bPrefix||t}${i.bem.b}${o!==null&&o.length>0?`${n}${o[0]}`:``}${r}${e})`}}}return Object.assign(a,{cB:((...e)=>i(o(e[0]),e[1],e[2])),cE:((...e)=>i(s(e[0]),e[1],e[2])),cM:((...e)=>i(c(e[0]),e[1],e[2])),cNotM:((...e)=>i(l(e[0]),e[1],e[2]))}),a}function ie(e){let t=0;for(let n=0;n<e.length;++n)e[n]===`&`&&++t;return t}var ae=/\s*,(?![^(]*\))\s*/g,oe=/\s+/g;function se(e,t){let n=[];return t.split(ae).forEach(t=>{let r=ie(t);if(!r){e.forEach(e=>{n.push((e&&e+` `)+t)});return}else if(r===1){e.forEach(e=>{n.push(t.replace(`&`,e))});return}let i=[t];for(;r--;){let t=[];i.forEach(n=>{e.forEach(e=>{t.push(n.replace(`&`,e))})}),i=t}i.forEach(e=>n.push(e))}),n}function ce(e,t){let n=[];return t.split(ae).forEach(t=>{e.forEach(e=>{n.push((e&&e+` `)+t)})}),n}function le(e){let t=[``];return e.forEach(e=>{e&&=e.trim(),e&&(t=e.includes(`&`)?se(t,e):ce(t,e))}),t.join(`, `).replace(oe,` `)}function ue(e){if(!e)return;let t=e.parentElement;t&&t.removeChild(e)}function de(e,t){return(t??document.head).querySelector(`style[cssr-id="${e}"]`)}function fe(e){let t=document.createElement(`style`);return t.setAttribute(`cssr-id`,e),t}function h(e){return e?/^\s*@(s|m)/.test(e):!1}var pe=/[A-Z]/g;function me(e){return e.replace(pe,e=>`-`+e.toLowerCase())}function he(e,t=` `){return typeof e==`object`&&e?` {
2
+ `+Object.entries(e).map(e=>t+` ${me(e[0])}: ${e[1]};`).join(`
3
+ `)+`
4
+ `+t+`}`:`: ${e};`}function ge(e,t,n){return typeof e==`function`?e({context:t.context,props:n}):e}function _e(e,t,n,r){if(!t)return``;let i=ge(t,n,r);if(!i)return``;if(typeof i==`string`)return`${e} {\n${i}\n}`;let a=Object.keys(i);if(a.length===0)return n.config.keepEmptyBlock?e+` {
5
+ }`:``;let o=e?[e+` {`]:[];return a.forEach(e=>{let t=i[e];if(e===`raw`){o.push(`
6
+ `+t+`
7
+ `);return}e=me(e),t!=null&&o.push(` ${e}${he(t)}`)}),e&&o.push(`}`),o.join(`
8
+ `)}function ve(e,t,n){e&&e.forEach(e=>{if(Array.isArray(e))ve(e,t,n);else if(typeof e==`function`){let r=e(t);Array.isArray(r)?ve(r,t,n):r&&n(r)}else e&&n(e)})}function ye(e,t,n,r,i){let a=e.$,o=``;if(!a||typeof a==`string`)h(a)?o=a:t.push(a);else if(typeof a==`function`){let e=a({context:r.context,props:i});h(e)?o=e:t.push(e)}else if(a.before&&a.before(r.context),!a.$||typeof a.$==`string`)h(a.$)?o=a.$:t.push(a.$);else if(a.$){let e=a.$({context:r.context,props:i});h(e)?o=e:t.push(e)}let s=le(t),c=_e(s,e.props,r,i);o?n.push(`${o} {`):c.length&&n.push(c),e.children&&ve(e.children,{context:r.context,props:i},e=>{if(typeof e==`string`){let t=_e(s,{raw:e},r,i);n.push(t)}else ye(e,t,n,r,i)}),t.pop(),o&&n.push(`}`),a&&a.after&&a.after(r.context)}function be(e,t,n){let r=[];return ye(e,[],r,t,n),r.join(`
9
+
10
+ `)}function xe(e){for(var t=0,n,r=0,i=e.length;i>=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&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)}typeof window<`u`&&(window.__cssrContext={});function Se(e,t,n,r){let{els:i}=t;if(n===void 0)i.forEach(ue),t.els=[];else{let e=de(n,r);e&&i.includes(e)&&(ue(e),t.els=i.filter(t=>t!==e))}}function Ce(e,t){e.push(t)}function we(e,t,n,r,i,a,o,s,c){let l;if(n===void 0&&(l=t.render(r),n=xe(l)),c){c.adapter(n,l??t.render(r));return}s===void 0&&(s=document.head);let u=de(n,s);if(u!==null&&!a)return u;let d=u??fe(n);if(l===void 0&&(l=t.render(r)),d.textContent=l,u!==null)return u;if(o){let e=s.querySelector(`meta[name="${o}"]`);if(e)return s.insertBefore(d,e),Ce(t.els,d),d}return i?s.insertBefore(d,s.querySelector(`style, link`)):s.appendChild(d),Ce(t.els,d),d}function Te(e){return be(this,this.instance,e)}function Ee(e={}){let{id:t,ssr:n,props:r,head:i=!1,force:a=!1,anchorMetaName:o,parent:s}=e;return we(this.instance,this,t,r,i,a,o,s,n)}function De(e={}){let{id:t,parent:n}=e;Se(this.instance,this,t,n)}var Oe=function(e,t,n,r){return{instance:e,$:t,props:n,children:r,els:[],render:Te,mount:Ee,unmount:De}},ke=function(e,t,n,r){return Array.isArray(t)?Oe(e,{$:null},null,t):Array.isArray(n)?Oe(e,t,null,n):Array.isArray(r)?Oe(e,t,n,r):Oe(e,t,n,null)};function Ae(e={}){let t={c:((...e)=>ke(t,...e)),use:(e,...n)=>e.install(t,...n),find:de,context:{},config:e};return t}function je(e,t){if(e===void 0)return!1;if(t){let{context:{ids:n}}=t;return n.has(e)}return de(e)!==null}var g=`.n-`,Me=`__`,Ne=`--`,Pe=Ae(),Fe=re({blockPrefix:g,elementPrefix:Me,modifierPrefix:Ne});Pe.use(Fe);var{c:_,find:Ie}=Pe,{cB:Le,cE:v,cM:Re,cNotM:ze}=Fe;function Be(e){return _(({props:{bPrefix:e}})=>`${e||g}modal, ${e||g}drawer`,[e])}function Ve(e){return _(({props:{bPrefix:e}})=>`${e||g}popover`,[e])}function He(e){return _(({props:{bPrefix:e}})=>`&${e||g}modal`,e)}var Ue=(...e)=>_(`>`,[Le(...e)]);function We(e,t){return e+(t===`default`?``:t.replace(/^[a-z]/,e=>e.toUpperCase()))}var Ge={aliceblue:`#F0F8FF`,antiquewhite:`#FAEBD7`,aqua:`#0FF`,aquamarine:`#7FFFD4`,azure:`#F0FFFF`,beige:`#F5F5DC`,bisque:`#FFE4C4`,black:`#000`,blanchedalmond:`#FFEBCD`,blue:`#00F`,blueviolet:`#8A2BE2`,brown:`#A52A2A`,burlywood:`#DEB887`,cadetblue:`#5F9EA0`,chartreuse:`#7FFF00`,chocolate:`#D2691E`,coral:`#FF7F50`,cornflowerblue:`#6495ED`,cornsilk:`#FFF8DC`,crimson:`#DC143C`,cyan:`#0FF`,darkblue:`#00008B`,darkcyan:`#008B8B`,darkgoldenrod:`#B8860B`,darkgray:`#A9A9A9`,darkgrey:`#A9A9A9`,darkgreen:`#006400`,darkkhaki:`#BDB76B`,darkmagenta:`#8B008B`,darkolivegreen:`#556B2F`,darkorange:`#FF8C00`,darkorchid:`#9932CC`,darkred:`#8B0000`,darksalmon:`#E9967A`,darkseagreen:`#8FBC8F`,darkslateblue:`#483D8B`,darkslategray:`#2F4F4F`,darkslategrey:`#2F4F4F`,darkturquoise:`#00CED1`,darkviolet:`#9400D3`,deeppink:`#FF1493`,deepskyblue:`#00BFFF`,dimgray:`#696969`,dimgrey:`#696969`,dodgerblue:`#1E90FF`,firebrick:`#B22222`,floralwhite:`#FFFAF0`,forestgreen:`#228B22`,fuchsia:`#F0F`,gainsboro:`#DCDCDC`,ghostwhite:`#F8F8FF`,gold:`#FFD700`,goldenrod:`#DAA520`,gray:`#808080`,grey:`#808080`,green:`#008000`,greenyellow:`#ADFF2F`,honeydew:`#F0FFF0`,hotpink:`#FF69B4`,indianred:`#CD5C5C`,indigo:`#4B0082`,ivory:`#FFFFF0`,khaki:`#F0E68C`,lavender:`#E6E6FA`,lavenderblush:`#FFF0F5`,lawngreen:`#7CFC00`,lemonchiffon:`#FFFACD`,lightblue:`#ADD8E6`,lightcoral:`#F08080`,lightcyan:`#E0FFFF`,lightgoldenrodyellow:`#FAFAD2`,lightgray:`#D3D3D3`,lightgrey:`#D3D3D3`,lightgreen:`#90EE90`,lightpink:`#FFB6C1`,lightsalmon:`#FFA07A`,lightseagreen:`#20B2AA`,lightskyblue:`#87CEFA`,lightslategray:`#778899`,lightslategrey:`#778899`,lightsteelblue:`#B0C4DE`,lightyellow:`#FFFFE0`,lime:`#0F0`,limegreen:`#32CD32`,linen:`#FAF0E6`,magenta:`#F0F`,maroon:`#800000`,mediumaquamarine:`#66CDAA`,mediumblue:`#0000CD`,mediumorchid:`#BA55D3`,mediumpurple:`#9370DB`,mediumseagreen:`#3CB371`,mediumslateblue:`#7B68EE`,mediumspringgreen:`#00FA9A`,mediumturquoise:`#48D1CC`,mediumvioletred:`#C71585`,midnightblue:`#191970`,mintcream:`#F5FFFA`,mistyrose:`#FFE4E1`,moccasin:`#FFE4B5`,navajowhite:`#FFDEAD`,navy:`#000080`,oldlace:`#FDF5E6`,olive:`#808000`,olivedrab:`#6B8E23`,orange:`#FFA500`,orangered:`#FF4500`,orchid:`#DA70D6`,palegoldenrod:`#EEE8AA`,palegreen:`#98FB98`,paleturquoise:`#AFEEEE`,palevioletred:`#DB7093`,papayawhip:`#FFEFD5`,peachpuff:`#FFDAB9`,peru:`#CD853F`,pink:`#FFC0CB`,plum:`#DDA0DD`,powderblue:`#B0E0E6`,purple:`#800080`,rebeccapurple:`#663399`,red:`#F00`,rosybrown:`#BC8F8F`,royalblue:`#4169E1`,saddlebrown:`#8B4513`,salmon:`#FA8072`,sandybrown:`#F4A460`,seagreen:`#2E8B57`,seashell:`#FFF5EE`,sienna:`#A0522D`,silver:`#C0C0C0`,skyblue:`#87CEEB`,slateblue:`#6A5ACD`,slategray:`#708090`,slategrey:`#708090`,snow:`#FFFAFA`,springgreen:`#00FF7F`,steelblue:`#4682B4`,tan:`#D2B48C`,teal:`#008080`,thistle:`#D8BFD8`,tomato:`#FF6347`,turquoise:`#40E0D0`,violet:`#EE82EE`,wheat:`#F5DEB3`,white:`#FFF`,whitesmoke:`#F5F5F5`,yellow:`#FF0`,yellowgreen:`#9ACD32`,transparent:`#0000`};function Ke(e,t,n){t/=100,n/=100;let r=(r,i=(r+e/60)%6)=>n-n*t*Math.max(Math.min(i,4-i,1),0);return[r(5)*255,r(3)*255,r(1)*255]}function qe(e,t,n){t/=100,n/=100;let r=t*Math.min(n,1-n),i=(t,i=(t+e/30)%12)=>n-r*Math.max(Math.min(i-3,9-i,1),-1);return[i(0)*255,i(8)*255,i(4)*255]}var y=`^\\s*`,b=`\\s*$`,x=`\\s*((\\.\\d+)|(\\d+(\\.\\d*)?))%\\s*`,S=`\\s*((\\.\\d+)|(\\d+(\\.\\d*)?))\\s*`,C=`([0-9A-Fa-f])`,w=`([0-9A-Fa-f]{2})`,Je=RegExp(`${y}hsl\\s*\\(${S},${x},${x}\\)${b}`),Ye=RegExp(`${y}hsv\\s*\\(${S},${x},${x}\\)${b}`),Xe=RegExp(`${y}hsla\\s*\\(${S},${x},${x},${S}\\)${b}`),Ze=RegExp(`${y}hsva\\s*\\(${S},${x},${x},${S}\\)${b}`),Qe=RegExp(`${y}rgb\\s*\\(${S},${S},${S}\\)${b}`),$e=RegExp(`${y}rgba\\s*\\(${S},${S},${S},${S}\\)${b}`),et=RegExp(`${y}#${C}${C}${C}${b}`),tt=RegExp(`${y}#${w}${w}${w}${b}`),nt=RegExp(`${y}#${C}${C}${C}${C}${b}`),rt=RegExp(`${y}#${w}${w}${w}${w}${b}`);function T(e){return parseInt(e,16)}function it(e){try{let t;if(t=Xe.exec(e))return[dt(t[1]),A(t[5]),A(t[9]),O(t[13])];if(t=Je.exec(e))return[dt(t[1]),A(t[5]),A(t[9]),1];throw Error(`[seemly/hsla]: Invalid color value ${e}.`)}catch(e){throw e}}function at(e){try{let t;if(t=Ze.exec(e))return[dt(t[1]),A(t[5]),A(t[9]),O(t[13])];if(t=Ye.exec(e))return[dt(t[1]),A(t[5]),A(t[9]),1];throw Error(`[seemly/hsva]: Invalid color value ${e}.`)}catch(e){throw e}}function E(e){try{let t;if(t=tt.exec(e))return[T(t[1]),T(t[2]),T(t[3]),1];if(t=Qe.exec(e))return[k(t[1]),k(t[5]),k(t[9]),1];if(t=$e.exec(e))return[k(t[1]),k(t[5]),k(t[9]),O(t[13])];if(t=et.exec(e))return[T(t[1]+t[1]),T(t[2]+t[2]),T(t[3]+t[3]),1];if(t=rt.exec(e))return[T(t[1]),T(t[2]),T(t[3]),O(T(t[4])/255)];if(t=nt.exec(e))return[T(t[1]+t[1]),T(t[2]+t[2]),T(t[3]+t[3]),O(T(t[4]+t[4])/255)];if(e in Ge)return E(Ge[e]);if(Je.test(e)||Xe.test(e)){let[t,n,r,i]=it(e);return[...qe(t,n,r),i]}else if(Ye.test(e)||Ze.test(e)){let[t,n,r,i]=at(e);return[...Ke(t,n,r),i]}throw Error(`[seemly/rgba]: Invalid color value ${e}.`)}catch(e){throw e}}function ot(e){return e>1?1:e<0?0:e}function st(e,t,n,r){return`rgba(${k(e)}, ${k(t)}, ${k(n)}, ${ot(r)})`}function ct(e,t,n,r,i){return k((e*t*(1-r)+n*r)/i)}function lt(e,t){Array.isArray(e)||(e=E(e)),Array.isArray(t)||(t=E(t));let n=e[3],r=t[3],i=O(n+r-n*r);return st(ct(e[0],n,t[0],r,i),ct(e[1],n,t[1],r,i),ct(e[2],n,t[2],r,i),i)}function ut(e,t){let[n,r,i,a=1]=Array.isArray(e)?e:E(e);return typeof t.alpha==`number`?st(n,r,i,t.alpha):st(n,r,i,a)}function D(e,t){let[n,r,i,a=1]=Array.isArray(e)?e:E(e),{lightness:o=1,alpha:s=1}=t;return ft([n*o,r*o,i*o,a*s])}function O(e){let t=Math.round(Number(e)*100)/100;return t>1?1:t<0?0:t}function dt(e){let t=Math.round(Number(e));return t>=360||t<0?0:t}function k(e){let t=Math.round(Number(e));return t>255?255:t<0?0:t}function A(e){let t=Math.round(Number(e));return t>100?100:t<0?0:t}function ft(e){let[t,n,r]=e;return 3 in e?`rgba(${k(t)}, ${k(n)}, ${k(r)}, ${O(e[3])})`:`rgba(${k(t)}, ${k(n)}, ${k(r)}, 1)`}function pt(e){let n=t(e),r=u(n.value);return c(n,e=>{r.value=e}),typeof e==`function`?r:{__v_isRef:!0,get value(){return r.value},set value(t){e.set(t)}}}function mt(){let e=u(!1);return o(()=>{e.value=!0}),ee(e)}function ht(e){return e}var gt=typeof document<`u`&&typeof window<`u`,_t=`@css-render/vue3-ssr`;function vt(e,t){return`<style cssr-id="${e}">\n${t}\n</style>`}function yt(e,t,n){let{styles:r,ids:i}=n;i.has(e)||r!==null&&(i.add(e),r.push(vt(e,t)))}var bt=typeof document<`u`;function j(){if(bt)return;let e=n(_t,null);if(e!==null)return{adapter:(t,n)=>yt(t,n,e),context:e}}function xt(e,t){console.error(`[naive/${e}]: ${t}`)}function St(e,t){throw Error(`[naive/${e}]: ${t}`)}function Ct(e,...t){if(Array.isArray(e))e.forEach(e=>Ct(e,...t));else return e(...t)}function M(e){return e.some(e=>r(e)?!(e.type===te||e.type===ne&&!M(e.children)):!0)?e:null}function wt(e,t){return e&&M(e())||t()}function Tt(e,t,n){return e&&M(e(t))||n(t)}function Et(e,t){return t(e&&M(e())||null)}function Dt(e){return!(e&&M(e()))}var N=ht(`n-config-provider`);function Ot(e={},r={defaultBordered:!0}){let i=n(N,null);return{inlineThemeDisabled:i?.inlineThemeDisabled,mergedRtlRef:i?.mergedRtlRef,mergedComponentPropsRef:i?.mergedComponentPropsRef,mergedBreakpointsRef:i?.mergedBreakpointsRef,mergedBorderedRef:t(()=>{let{bordered:t}=e;return t===void 0?i?.mergedBorderedRef.value??r.defaultBordered??!0:t}),mergedClsPrefixRef:i?i.mergedClsPrefixRef:m(`n`),namespaceRef:t(()=>i?.mergedNamespaceRef.value)}}function kt(e,t,r,i){r||St(`useThemeClass`,`cssVarsRef is not passed`);let a=n(N,null),o=a?.mergedThemeHashRef,s=a?.styleMountTarget,c=u(``),d=j(),f,p=`__${e}`,m=()=>{let e=p,n=t?t.value:void 0,a=o?.value;a&&(e+=`-${a}`),n&&(e+=`-${n}`);let{themeOverrides:l,builtinThemeOverrides:u}=i;l&&(e+=`-${xe(JSON.stringify(l))}`),u&&(e+=`-${xe(JSON.stringify(u))}`),c.value=e,f=()=>{let t=r.value,n=``;for(let e in t)n+=`${e}: ${t[e]};`;_(`.${e}`,n).mount({id:e,ssr:d,parent:s}),f=void 0}};return l(()=>{m()}),{themeClass:c,onRender:()=>{f?.()}}}var At=ht(`n-form-item`);function jt(e,{defaultSize:r=`medium`,mergedSize:a,mergedDisabled:o}={}){let c=n(At,null);i(At,null);let l=t(a?()=>a(c):()=>{let{size:t}=e;if(t)return t;if(c){let{mergedSize:e}=c;if(e.value!==void 0)return e.value}return r}),u=t(o?()=>o(c):()=>{let{disabled:t}=e;return t===void 0?c?c.disabled.value:!1:t}),d=t(()=>{let{status:t}=e;return t||c?.mergedValidationStatus.value});return s(()=>{c&&c.restoreValidation()}),{mergedSizeRef:l,mergedDisabledRef:u,mergedStatusRef:d,nTriggerFormBlur(){c&&c.handleContentBlur()},nTriggerFormChange(){c&&c.handleContentChange()},nTriggerFormFocus(){c&&c.handleContentFocus()},nTriggerFormInput(){c&&c.handleContentInput()}}}var Mt=typeof global==`object`&&global&&global.Object===Object&&global,Nt=typeof self==`object`&&self&&self.Object===Object&&self,P=Mt||Nt||Function(`return this`)(),F=P.Symbol,Pt=Object.prototype,Ft=Pt.hasOwnProperty,It=Pt.toString,I=F?F.toStringTag:void 0;function Lt(e){var t=Ft.call(e,I),n=e[I];try{e[I]=void 0;var r=!0}catch{}var i=It.call(e);return r&&(t?e[I]=n:delete e[I]),i}var Rt=Object.prototype.toString;function zt(e){return Rt.call(e)}var Bt=`[object Null]`,Vt=`[object Undefined]`,Ht=F?F.toStringTag:void 0;function L(e){return e==null?e===void 0?Vt:Bt:Ht&&Ht in Object(e)?Lt(e):zt(e)}function R(e){return typeof e==`object`&&!!e}var z=Array.isArray;function B(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}function Ut(e){return e}var Wt=`[object AsyncFunction]`,Gt=`[object Function]`,Kt=`[object GeneratorFunction]`,qt=`[object Proxy]`;function Jt(e){if(!B(e))return!1;var t=L(e);return t==Gt||t==Kt||t==Wt||t==qt}var Yt=P[`__core-js_shared__`],Xt=function(){var e=/[^.]+$/.exec(Yt&&Yt.keys&&Yt.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function Zt(e){return!!Xt&&Xt in e}var Qt=Function.prototype.toString;function $t(e){if(e!=null){try{return Qt.call(e)}catch{}try{return e+``}catch{}}return``}var en=/[\\^$.*+?()[\]{}|]/g,tn=/^\[object .+?Constructor\]$/,nn=Function.prototype,rn=Object.prototype,an=nn.toString,on=rn.hasOwnProperty,sn=RegExp(`^`+an.call(on).replace(en,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function cn(e){return!B(e)||Zt(e)?!1:(Jt(e)?sn:tn).test($t(e))}function ln(e,t){return e?.[t]}function V(e,t){var n=ln(e,t);return cn(n)?n:void 0}var un=Object.create,dn=function(){function e(){}return function(t){if(!B(t))return{};if(un)return un(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function fn(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function pn(e,t){var n=-1,r=e.length;for(t||=Array(r);++n<r;)t[n]=e[n];return t}var mn=800,hn=16,gn=Date.now;function _n(e){var t=0,n=0;return function(){var r=gn(),i=hn-(r-n);if(n=r,i>0){if(++t>=mn)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function vn(e){return function(){return e}}var yn=function(){try{var e=V(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),bn=_n(yn?function(e,t){return yn(e,`toString`,{configurable:!0,enumerable:!1,value:vn(t),writable:!0})}:Ut),xn=9007199254740991,Sn=/^(?:0|[1-9]\d*)$/;function Cn(e,t){var n=typeof e;return t??=xn,!!t&&(n==`number`||n!=`symbol`&&Sn.test(e))&&e>-1&&e%1==0&&e<t}function wn(e,t,n){t==`__proto__`&&yn?yn(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function H(e,t){return e===t||e!==e&&t!==t}var Tn=Object.prototype.hasOwnProperty;function En(e,t,n){var r=e[t];(!(Tn.call(e,t)&&H(r,n))||n===void 0&&!(t in e))&&wn(e,t,n)}function Dn(e,t,n,r){var i=!n;n||={};for(var a=-1,o=t.length;++a<o;){var s=t[a],c=r?r(n[s],e[s],s,n,e):void 0;c===void 0&&(c=e[s]),i?wn(n,s,c):En(n,s,c)}return n}var On=Math.max;function kn(e,t,n){return t=On(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,a=On(r.length-t,0),o=Array(a);++i<a;)o[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(o),fn(e,this,s)}}function An(e,t){return bn(kn(e,t,Ut),e+``)}var jn=9007199254740991;function Mn(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=jn}function Nn(e){return e!=null&&Mn(e.length)&&!Jt(e)}function Pn(e,t,n){if(!B(n))return!1;var r=typeof t;return(r==`number`?Nn(n)&&Cn(t,n.length):r==`string`&&t in n)?H(n[t],e):!1}function Fn(e){return An(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&Pn(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var s=n[r];s&&e(t,s,r,a)}return t})}var In=Object.prototype;function Ln(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||In)}function Rn(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var zn=`[object Arguments]`;function Bn(e){return R(e)&&L(e)==zn}var Vn=Object.prototype,Hn=Vn.hasOwnProperty,Un=Vn.propertyIsEnumerable,Wn=Bn(function(){return arguments}())?Bn:function(e){return R(e)&&Hn.call(e,`callee`)&&!Un.call(e,`callee`)};function Gn(){return!1}var Kn=typeof exports==`object`&&exports&&!exports.nodeType&&exports,qn=Kn&&typeof module==`object`&&module&&!module.nodeType&&module,Jn=qn&&qn.exports===Kn?P.Buffer:void 0,Yn=(Jn?Jn.isBuffer:void 0)||Gn,Xn=`[object Arguments]`,Zn=`[object Array]`,Qn=`[object Boolean]`,$n=`[object Date]`,er=`[object Error]`,tr=`[object Function]`,nr=`[object Map]`,rr=`[object Number]`,ir=`[object Object]`,ar=`[object RegExp]`,or=`[object Set]`,sr=`[object String]`,cr=`[object WeakMap]`,lr=`[object ArrayBuffer]`,ur=`[object DataView]`,dr=`[object Float32Array]`,fr=`[object Float64Array]`,pr=`[object Int8Array]`,mr=`[object Int16Array]`,hr=`[object Int32Array]`,gr=`[object Uint8Array]`,_r=`[object Uint8ClampedArray]`,vr=`[object Uint16Array]`,yr=`[object Uint32Array]`,U={};U[dr]=U[fr]=U[pr]=U[mr]=U[hr]=U[gr]=U[_r]=U[vr]=U[yr]=!0,U[Xn]=U[Zn]=U[lr]=U[Qn]=U[ur]=U[$n]=U[er]=U[tr]=U[nr]=U[rr]=U[ir]=U[ar]=U[or]=U[sr]=U[cr]=!1;function br(e){return R(e)&&Mn(e.length)&&!!U[L(e)]}function xr(e){return function(t){return e(t)}}var Sr=typeof exports==`object`&&exports&&!exports.nodeType&&exports,W=Sr&&typeof module==`object`&&module&&!module.nodeType&&module,Cr=W&&W.exports===Sr&&Mt.process,wr=function(){try{return W&&W.require&&W.require(`util`).types||Cr&&Cr.binding&&Cr.binding(`util`)}catch{}}(),Tr=wr&&wr.isTypedArray,Er=Tr?xr(Tr):br,Dr=Object.prototype.hasOwnProperty;function Or(e,t){var n=z(e),r=!n&&Wn(e),i=!n&&!r&&Yn(e),a=!n&&!r&&!i&&Er(e),o=n||r||i||a,s=o?Rn(e.length,String):[],c=s.length;for(var l in e)(t||Dr.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||Cn(l,c)))&&s.push(l);return s}function kr(e,t){return function(n){return e(t(n))}}function Ar(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var jr=Object.prototype.hasOwnProperty;function Mr(e){if(!B(e))return Ar(e);var t=Ln(e),n=[];for(var r in e)r==`constructor`&&(t||!jr.call(e,r))||n.push(r);return n}function Nr(e){return Nn(e)?Or(e,!0):Mr(e)}var G=V(Object,`create`);function Pr(){this.__data__=G?G(null):{},this.size=0}function Fr(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}var Ir=`__lodash_hash_undefined__`,Lr=Object.prototype.hasOwnProperty;function Rr(e){var t=this.__data__;if(G){var n=t[e];return n===Ir?void 0:n}return Lr.call(t,e)?t[e]:void 0}var zr=Object.prototype.hasOwnProperty;function Br(e){var t=this.__data__;return G?t[e]!==void 0:zr.call(t,e)}var Vr=`__lodash_hash_undefined__`;function Hr(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=G&&t===void 0?Vr:t,this}function K(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}K.prototype.clear=Pr,K.prototype.delete=Fr,K.prototype.get=Rr,K.prototype.has=Br,K.prototype.set=Hr;function Ur(){this.__data__=[],this.size=0}function Wr(e,t){for(var n=e.length;n--;)if(H(e[n][0],t))return n;return-1}var Gr=Array.prototype.splice;function Kr(e){var t=this.__data__,n=Wr(t,e);return n<0?!1:(n==t.length-1?t.pop():Gr.call(t,n,1),--this.size,!0)}function qr(e){var t=this.__data__,n=Wr(t,e);return n<0?void 0:t[n][1]}function Jr(e){return Wr(this.__data__,e)>-1}function Yr(e,t){var n=this.__data__,r=Wr(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function q(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}q.prototype.clear=Ur,q.prototype.delete=Kr,q.prototype.get=qr,q.prototype.has=Jr,q.prototype.set=Yr;var Xr=V(P,`Map`);function Zr(){this.size=0,this.__data__={hash:new K,map:new(Xr||q),string:new K}}function Qr(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}function $r(e,t){var n=e.__data__;return Qr(t)?n[typeof t==`string`?`string`:`hash`]:n.map}function ei(e){var t=$r(this,e).delete(e);return this.size-=+!!t,t}function ti(e){return $r(this,e).get(e)}function ni(e){return $r(this,e).has(e)}function ri(e,t){var n=$r(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function J(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}J.prototype.clear=Zr,J.prototype.delete=ei,J.prototype.get=ti,J.prototype.has=ni,J.prototype.set=ri;var ii=kr(Object.getPrototypeOf,Object),ai=`[object Object]`,oi=Function.prototype,si=Object.prototype,ci=oi.toString,li=si.hasOwnProperty,ui=ci.call(Object);function di(e){if(!R(e)||L(e)!=ai)return!1;var t=ii(e);if(t===null)return!0;var n=li.call(t,`constructor`)&&t.constructor;return typeof n==`function`&&n instanceof n&&ci.call(n)==ui}function fi(){this.__data__=new q,this.size=0}function pi(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function mi(e){return this.__data__.get(e)}function hi(e){return this.__data__.has(e)}var gi=200;function _i(e,t){var n=this.__data__;if(n instanceof q){var r=n.__data__;if(!Xr||r.length<gi-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new J(r)}return n.set(e,t),this.size=n.size,this}function Y(e){this.size=(this.__data__=new q(e)).size}Y.prototype.clear=fi,Y.prototype.delete=pi,Y.prototype.get=mi,Y.prototype.has=hi,Y.prototype.set=_i;var vi=typeof exports==`object`&&exports&&!exports.nodeType&&exports,yi=vi&&typeof module==`object`&&module&&!module.nodeType&&module,bi=yi&&yi.exports===vi?P.Buffer:void 0,xi=bi?bi.allocUnsafe:void 0;function Si(e,t){if(t)return e.slice();var n=e.length,r=xi?xi(n):new e.constructor(n);return e.copy(r),r}var Ci=P.Uint8Array;function wi(e){var t=new e.constructor(e.byteLength);return new Ci(t).set(new Ci(e)),t}function Ti(e,t){var n=t?wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function Ei(e){return typeof e.constructor==`function`&&!Ln(e)?dn(ii(e)):{}}function Di(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}var Oi=Di();function ki(e,t,n){(n!==void 0&&!H(e[t],n)||n===void 0&&!(t in e))&&wn(e,t,n)}function Ai(e){return R(e)&&Nn(e)}function ji(e,t){if(!(t===`constructor`&&typeof e[t]==`function`)&&t!=`__proto__`)return e[t]}function Mi(e){return Dn(e,Nr(e))}function Ni(e,t,n,r,i,a,o){var s=ji(e,n),c=ji(t,n),l=o.get(c);if(l){ki(e,n,l);return}var u=a?a(s,c,n+``,e,t,o):void 0,d=u===void 0;if(d){var f=z(c),p=!f&&Yn(c),m=!f&&!p&&Er(c);u=c,f||p||m?z(s)?u=s:Ai(s)?u=pn(s):p?(d=!1,u=Si(c,!0)):m?(d=!1,u=Ti(c,!0)):u=[]:di(c)||Wn(c)?(u=s,Wn(s)?u=Mi(s):(!B(s)||Jt(s))&&(u=Ei(c))):d=!1}d&&(o.set(c,u),i(u,c,r,a,o),o.delete(c)),ki(e,n,u)}function Pi(e,t,n,r,i){e!==t&&Oi(t,function(a,o){if(i||=new Y,B(a))Ni(e,t,o,n,Pi,r,i);else{var s=r?r(ji(e,o),a,o+``,e,t,i):void 0;s===void 0&&(s=a),ki(e,o,s)}},Nr)}var X=Fn(function(e,t,n){Pi(e,t,n)}),Z=`naive-ui-style`;function Fi(r,i,a){if(!i)return;let o=j(),s=t(()=>{let{value:e}=i;if(!e)return;let t=e[r];if(t)return t}),c=n(N,null),u=()=>{l(()=>{let{value:e}=a,t=`${e}${r}Rtl`;if(je(t,o))return;let{value:n}=s;n&&n.style.mount({id:t,head:!0,anchorMetaName:Z,props:{bPrefix:e?`.${e}-`:void 0},ssr:o,parent:c?.styleMountTarget})})};return o?u():e(u),s}var Ii={fontFamily:`v-sans, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"`,fontFamilyMono:`v-mono, SFMono-Regular, Menlo, Consolas, Courier, monospace`,fontWeight:`400`,fontWeightStrong:`500`,cubicBezierEaseInOut:`cubic-bezier(.4, 0, .2, 1)`,cubicBezierEaseOut:`cubic-bezier(0, 0, .2, 1)`,cubicBezierEaseIn:`cubic-bezier(.4, 0, 1, 1)`,borderRadius:`3px`,borderRadiusSmall:`2px`,fontSize:`14px`,fontSizeMini:`12px`,fontSizeTiny:`12px`,fontSizeSmall:`14px`,fontSizeMedium:`14px`,fontSizeLarge:`15px`,fontSizeHuge:`16px`,lineHeight:`1.6`,heightMini:`16px`,heightTiny:`22px`,heightSmall:`28px`,heightMedium:`34px`,heightLarge:`40px`,heightHuge:`46px`},{fontSize:Li,fontFamily:Ri,lineHeight:zi}=Ii,Bi=_(`body`,`
11
+ margin: 0;
12
+ font-size: ${Li};
13
+ font-family: ${Ri};
14
+ line-height: ${zi};
15
+ -webkit-text-size-adjust: 100%;
16
+ -webkit-tap-highlight-color: transparent;
17
+ `,[_(`input`,`
18
+ font-family: inherit;
19
+ font-size: inherit;
20
+ `)]);function Vi(t,r,i){if(!r)return;let a=j(),o=n(N,null),s=()=>{let e=i.value;r.mount({id:e===void 0?t:e+t,head:!0,anchorMetaName:Z,props:{bPrefix:e?`.${e}-`:void 0},ssr:a,parent:o?.styleMountTarget}),o?.preflightStyleDisabled||Bi.mount({id:`n-global`,head:!0,anchorMetaName:Z,ssr:a,parent:o?.styleMountTarget})};a?s():e(s)}function Hi(e){return e}function Ui(r,i,a,o,s,c){let l=j(),u=n(N,null);if(a){let t=()=>{let e=c?.value;a.mount({id:e===void 0?i:e+i,head:!0,props:{bPrefix:e?`.${e}-`:void 0},anchorMetaName:Z,ssr:l,parent:u?.styleMountTarget}),u?.preflightStyleDisabled||Bi.mount({id:`n-global`,head:!0,anchorMetaName:Z,ssr:l,parent:u?.styleMountTarget})};l?t():e(t)}return t(()=>{let{theme:{common:e,self:t,peers:n={}}={},themeOverrides:i={},builtinThemeOverrides:a={}}=s,{common:c,peers:l}=i,{common:d=void 0,[r]:{common:f=void 0,self:p=void 0,peers:m={}}={}}=u?.mergedThemeRef.value||{},{common:ee=void 0,[r]:te={}}=u?.mergedThemeOverridesRef.value||{},{common:ne,peers:re={}}=te,ie=X({},e||f||d||o.common,ee,ne,c);return{common:ie,self:X((t||p||o.self)?.(ie),a,te,i),peers:X({},o.peers,m,n),peerOverrides:X({},a.peers,re,l)}})}Ui.props={theme:Object,themeOverrides:Object,builtinThemeOverrides:Object};var Wi=p({name:`BaseIconSwitchTransition`,setup(e,{slots:t}){let n=mt();return()=>a(d,{name:`icon-switch-transition`,appear:n.value},t)}}),{cubicBezierEaseInOut:Gi}=Ii;function Ki({originalTransform:e=``,left:t=0,top:n=0,transition:r=`all .3s ${Gi} !important`}={}){return[_(`&.icon-switch-transition-enter-from, &.icon-switch-transition-leave-to`,{transform:`${e} scale(0.75)`,left:t,top:n,opacity:0}),_(`&.icon-switch-transition-enter-to, &.icon-switch-transition-leave-from`,{transform:`scale(1) ${e}`,left:t,top:n,opacity:1}),_(`&.icon-switch-transition-enter-active, &.icon-switch-transition-leave-active`,{transformOrigin:`center`,position:`absolute`,left:t,top:n,transition:r})]}var qi=_([_(`@keyframes rotator`,`
21
+ 0% {
22
+ -webkit-transform: rotate(0deg);
23
+ transform: rotate(0deg);
24
+ }
25
+ 100% {
26
+ -webkit-transform: rotate(360deg);
27
+ transform: rotate(360deg);
28
+ }`),Le(`base-loading`,`
29
+ position: relative;
30
+ line-height: 0;
31
+ width: 1em;
32
+ height: 1em;
33
+ `,[v(`transition-wrapper`,`
34
+ position: absolute;
35
+ width: 100%;
36
+ height: 100%;
37
+ `,[Ki()]),v(`placeholder`,`
38
+ position: absolute;
39
+ left: 50%;
40
+ top: 50%;
41
+ transform: translateX(-50%) translateY(-50%);
42
+ `,[Ki({left:`50%`,top:`50%`,originalTransform:`translateX(-50%) translateY(-50%)`})]),v(`container`,`
43
+ animation: rotator 3s linear infinite both;
44
+ `,[v(`icon`,`
45
+ height: 1em;
46
+ width: 1em;
47
+ `)])])]),Ji=`1.6s`,Yi={strokeWidth:{type:Number,default:28},stroke:{type:String,default:void 0},scale:{type:Number,default:1},radius:{type:Number,default:100}},Xi=p({name:`BaseLoading`,props:Object.assign({clsPrefix:{type:String,required:!0},show:{type:Boolean,default:!0}},Yi),setup(e){Vi(`-base-loading`,qi,f(e,`clsPrefix`))},render(){let{clsPrefix:e,radius:t,strokeWidth:n,stroke:r,scale:i}=this,o=t/i;return a(`div`,{class:`${e}-base-loading`,role:`img`,"aria-label":`loading`},a(Wi,null,{default:()=>this.show?a(`div`,{key:`icon`,class:`${e}-base-loading__transition-wrapper`},a(`div`,{class:`${e}-base-loading__container`},a(`svg`,{class:`${e}-base-loading__icon`,viewBox:`0 0 ${2*o} ${2*o}`,xmlns:`http://www.w3.org/2000/svg`,style:{color:r}},a(`g`,null,a(`animateTransform`,{attributeName:`transform`,type:`rotate`,values:`0 ${o} ${o};270 ${o} ${o}`,begin:`0s`,dur:Ji,fill:`freeze`,repeatCount:`indefinite`}),a(`circle`,{class:`${e}-base-loading__icon`,fill:`none`,stroke:`currentColor`,"stroke-width":n,"stroke-linecap":`round`,cx:o,cy:o,r:t-n/2,"stroke-dasharray":5.67*t,"stroke-dashoffset":18.48*t},a(`animateTransform`,{attributeName:`transform`,type:`rotate`,values:`0 ${o} ${o};135 ${o} ${o};450 ${o} ${o}`,begin:`0s`,dur:Ji,fill:`freeze`,repeatCount:`indefinite`}),a(`animate`,{attributeName:`stroke-dashoffset`,values:`${5.67*t};${1.42*t};${5.67*t}`,begin:`0s`,dur:Ji,fill:`freeze`,repeatCount:`indefinite`})))))):a(`div`,{key:`placeholder`,class:`${e}-base-loading__placeholder`},this.$slots)}))}}),Q={neutralBase:`#FFF`,neutralInvertBase:`#000`,neutralTextBase:`#000`,neutralPopover:`#fff`,neutralCard:`#fff`,neutralModal:`#fff`,neutralBody:`#fff`,alpha1:`0.82`,alpha2:`0.72`,alpha3:`0.38`,alpha4:`0.24`,alpha5:`0.18`,alphaClose:`0.6`,alphaDisabled:`0.5`,alphaDisabledInput:`0.02`,alphaPending:`0.05`,alphaTablePending:`0.02`,alphaPressed:`0.07`,alphaAvatar:`0.2`,alphaRail:`0.14`,alphaProgressRail:`.08`,alphaBorder:`0.12`,alphaDivider:`0.06`,alphaInput:`0`,alphaAction:`0.02`,alphaTab:`0.04`,alphaScrollbar:`0.25`,alphaScrollbarHover:`0.4`,alphaCode:`0.05`,alphaTag:`0.02`,primaryHover:`#36ad6a`,primaryDefault:`#18a058`,primaryActive:`#0c7a43`,primarySuppl:`#36ad6a`,infoHover:`#4098fc`,infoDefault:`#2080f0`,infoActive:`#1060c9`,infoSuppl:`#4098fc`,errorHover:`#de576d`,errorDefault:`#d03050`,errorActive:`#ab1f3f`,errorSuppl:`#de576d`,warningHover:`#fcb040`,warningDefault:`#f0a020`,warningActive:`#c97c10`,warningSuppl:`#fcb040`,successHover:`#36ad6a`,successDefault:`#18a058`,successActive:`#0c7a43`,successSuppl:`#36ad6a`},Zi=E(Q.neutralBase),Qi=E(Q.neutralInvertBase),$i=`rgba(${Qi.slice(0,3).join(`, `)}, `;function ea(e){return`${$i+String(e)})`}function $(e){let t=Array.from(Qi);return t[3]=Number(e),lt(Zi,t)}var ta=Object.assign(Object.assign({name:`common`},Ii),{baseColor:Q.neutralBase,primaryColor:Q.primaryDefault,primaryColorHover:Q.primaryHover,primaryColorPressed:Q.primaryActive,primaryColorSuppl:Q.primarySuppl,infoColor:Q.infoDefault,infoColorHover:Q.infoHover,infoColorPressed:Q.infoActive,infoColorSuppl:Q.infoSuppl,successColor:Q.successDefault,successColorHover:Q.successHover,successColorPressed:Q.successActive,successColorSuppl:Q.successSuppl,warningColor:Q.warningDefault,warningColorHover:Q.warningHover,warningColorPressed:Q.warningActive,warningColorSuppl:Q.warningSuppl,errorColor:Q.errorDefault,errorColorHover:Q.errorHover,errorColorPressed:Q.errorActive,errorColorSuppl:Q.errorSuppl,textColorBase:Q.neutralTextBase,textColor1:`rgb(31, 34, 37)`,textColor2:`rgb(51, 54, 57)`,textColor3:`rgb(118, 124, 130)`,textColorDisabled:$(Q.alpha4),placeholderColor:$(Q.alpha4),placeholderColorDisabled:$(Q.alpha5),iconColor:$(Q.alpha4),iconColorHover:D($(Q.alpha4),{lightness:.75}),iconColorPressed:D($(Q.alpha4),{lightness:.9}),iconColorDisabled:$(Q.alpha5),opacity1:Q.alpha1,opacity2:Q.alpha2,opacity3:Q.alpha3,opacity4:Q.alpha4,opacity5:Q.alpha5,dividerColor:`rgb(239, 239, 245)`,borderColor:`rgb(224, 224, 230)`,closeIconColor:$(Number(Q.alphaClose)),closeIconColorHover:$(Number(Q.alphaClose)),closeIconColorPressed:$(Number(Q.alphaClose)),closeColorHover:`rgba(0, 0, 0, .09)`,closeColorPressed:`rgba(0, 0, 0, .13)`,clearColor:$(Q.alpha4),clearColorHover:D($(Q.alpha4),{lightness:.75}),clearColorPressed:D($(Q.alpha4),{lightness:.9}),scrollbarColor:ea(Q.alphaScrollbar),scrollbarColorHover:ea(Q.alphaScrollbarHover),scrollbarWidth:`5px`,scrollbarHeight:`5px`,scrollbarBorderRadius:`5px`,progressRailColor:$(Q.alphaProgressRail),railColor:`rgb(219, 219, 223)`,popoverColor:Q.neutralPopover,tableColor:Q.neutralCard,cardColor:Q.neutralCard,modalColor:Q.neutralModal,bodyColor:Q.neutralBody,tagColor:`#eee`,avatarColor:$(Q.alphaAvatar),invertedColor:`rgb(0, 20, 40)`,inputColor:$(Q.alphaInput),codeColor:`rgb(244, 244, 248)`,tabColor:`rgb(247, 247, 250)`,actionColor:`rgb(250, 250, 252)`,tableHeaderColor:`rgb(250, 250, 252)`,hoverColor:`rgb(243, 243, 245)`,tableColorHover:`rgba(0, 0, 100, 0.03)`,tableColorStriped:`rgba(0, 0, 100, 0.02)`,pressedColor:`rgb(237, 237, 239)`,opacityDisabled:Q.alphaDisabled,inputColorDisabled:`rgb(250, 250, 252)`,buttonColor2:`rgba(46, 51, 56, .05)`,buttonColor2Hover:`rgba(46, 51, 56, .09)`,buttonColor2Pressed:`rgba(46, 51, 56, .13)`,boxShadow1:`0 1px 2px -2px rgba(0, 0, 0, .08), 0 3px 6px 0 rgba(0, 0, 0, .06), 0 5px 12px 4px rgba(0, 0, 0, .04)`,boxShadow2:`0 3px 6px -4px rgba(0, 0, 0, .12), 0 6px 16px 0 rgba(0, 0, 0, .08), 0 9px 28px 8px rgba(0, 0, 0, .05)`,boxShadow3:`0 6px 16px -9px rgba(0, 0, 0, .08), 0 9px 28px 0 rgba(0, 0, 0, .05), 0 12px 48px 16px rgba(0, 0, 0, .03)`}),na=gt&&`chrome`in window;gt&&navigator.userAgent.includes(`Firefox`);var ra=gt&&navigator.userAgent.includes(`Safari`)&&!na;export{mt as $,Ut as A,Ot as B,Ln as C,Cn as D,H as E,F,Tt as G,M as H,P as I,St as J,Et as K,At as L,z as M,R as N,V as O,L as P,ht as Q,jt as R,Wn as S,Mn as T,Dt as U,N as V,wt as W,j as X,xt as Y,gt as Z,Xr as _,Ki as a,_ as at,Er as b,Ui as c,v as ct,Fi as d,We as dt,pt as et,X as f,Be as ft,J as g,Y as h,xe as ht,Yi as i,He as it,B as j,$t as k,Vi as l,Re as lt,Ci as m,Ae as mt,ta as n,lt as nt,Wi as o,Le as ot,Oi as p,Ve as pt,Ct as q,Xi as r,E as rt,Hi as s,Ue as st,ra as t,ut as tt,Ii as u,ze as ut,kr as v,Nn as w,Yn as x,Or as y,kt as z};
@@ -0,0 +1,6 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/app-DqRfMAIZ.js","assets/app-DHhjDueA.js","assets/router-Ddepf70Q.js","assets/pinia-bZ6_VpBU.js"])))=>i.map(i=>d[i]);
2
+ import{ct as e,i as t,n,o as r,r as i}from"./router-Ddepf70Q.js";import{n as a}from"./pinia-bZ6_VpBU.js";import{t as o}from"./app-DHhjDueA.js";import{n as s,r as c,t as l}from"./sessions-r2FX4lYx.js";async function u(e){return r(`/v1/runs`,{method:`POST`,body:JSON.stringify(e)})}function d(e,n,r,a){let o=t(),s=i(),c=`${o}/v1/runs/${e}/events${s?`?token=${encodeURIComponent(s)}`:``}`,l=!1,u=new EventSource(c);return u.onmessage=e=>{if(!l)try{let t=JSON.parse(e.data);n(t),(t.event===`run.completed`||t.event===`run.failed`)&&(l=!0,u.close(),r())}catch{n({event:`message`,delta:e.data})}},u.onerror=()=>{l||(l=!0,u.close(),a(Error(`SSE connection error`)))},{abort:()=>{l||(l=!0,u.close())}}}function f(){return Date.now().toString(36)+Math.random().toString(36).slice(2,8)}async function p(e){if(e.length===0)return[];let t=new FormData;for(let n of e)n.file&&t.append(`file`,n.file,n.name);let n=await fetch(`/upload`,{method:`POST`,body:t});if(!n.ok)throw Error(`Upload failed: ${n.status}`);return(await n.json()).files}function m(e){let t=new Map,n=new Map;for(let r of e)if(r.role===`assistant`&&r.tool_calls)for(let e of r.tool_calls)e.id&&(e.function?.name&&t.set(e.id,e.function.name),e.function?.arguments&&n.set(e.id,e.function.arguments));let r=[];for(let i of e){if(i.role===`assistant`&&i.tool_calls?.length&&!i.content?.trim()){for(let e of i.tool_calls)r.push({id:String(i.id)+`_`+e.id,role:`tool`,content:``,timestamp:Math.round(i.timestamp*1e3),toolName:e.function?.name||`Tool`,toolArgs:e.function?.arguments||void 0,toolStatus:`done`});continue}if(i.role===`tool`){let e=i.tool_call_id||``,a=i.tool_name||t.get(e)||`Tool`,o=n.get(e)||void 0,s=``;if(i.content)try{let e=JSON.parse(i.content);s=e.url||e.title||e.preview||e.summary||``}catch{s=i.content.slice(0,80)}let c=r.findIndex(t=>t.role===`tool`&&t.toolName===a&&!t.toolResult&&t.id.includes(`_`+e));c!==-1&&r.splice(c,1),r.push({id:String(i.id),role:`tool`,content:``,timestamp:Math.round(i.timestamp*1e3),toolName:a,toolArgs:o,toolPreview:typeof s==`string`&&s.slice(0,100)||void 0,toolResult:i.content||void 0,toolStatus:`done`});continue}r.push({id:String(i.id),role:i.role,content:i.content||``,timestamp:Math.round(i.timestamp*1e3)})}return r}function h(e){return{id:e.id,title:e.title||`New Chat`,source:e.source||void 0,messages:[],createdAt:Math.round(e.started_at*1e3),updatedAt:Math.round((e.ended_at||e.started_at)*1e3),model:e.model,provider:e.billing_provider||``,messageCount:e.message_count,inputTokens:e.input_tokens,outputTokens:e.output_tokens}}var g=a(`chat`,()=>{let t=e([]),r=e(null),i=e(!1),a=e(null),g=e(!1),_=e(!1),v=e(null),y=e([]);async function b(){g.value=!0;try{t.value=(await c()).map(h),!r.value&&t.value.length>0&&await S(t.value[0].id)}catch(e){console.error(`Failed to load sessions:`,e)}finally{g.value=!1}}function x(){let e={id:f(),title:`New Chat`,source:`api_server`,messages:[],createdAt:Date.now(),updatedAt:Date.now()};return t.value.unshift(e),e}async function S(e){if(r.value=e,v.value=t.value.find(t=>t.id===e)||null,v.value&&v.value.messages.length===0){_.value=!0;try{let t=await s(e);if(t&&t.messages){let e=m(t.messages);if(v.value.messages=e,v.value.inputTokens=t.input_tokens,v.value.outputTokens=t.output_tokens,t.title)v.value.title=t.title;else{let t=e.find(e=>e.role===`user`);if(t){let e=t.content.slice(0,40);v.value.title=e+(t.content.length>40?`...`:``)}}}}catch(e){console.error(`Failed to load session messages:`,e)}finally{_.value=!1}}y.value=v.value?[...v.value.messages]:[]}function C(){if(i.value)return;let e=x();e.model=o().selectedModel||void 0,S(e.id)}async function w(e,t){if(v.value&&(v.value.model=e,v.value.provider=t||``,t)){let{useAppStore:r}=await n(async()=>{let{useAppStore:e}=await import(`./app-DqRfMAIZ.js`);return{useAppStore:e}},__vite__mapDeps([0,1,2,3]));await r().switchModel(e,t)}}async function T(e){await l(e),t.value=t.value.filter(t=>t.id!==e),r.value===e&&(t.value.length>0?await S(t.value[0].id):S(x().id))}function E(e){y.value.push(e)}function D(e,t){let n=y.value.findIndex(t=>t.id===e);n!==-1&&(y.value[n]={...y.value[n],...t})}function O(){if(v.value){if(v.value.title===`New Chat`){let e=y.value.find(e=>e.role===`user`);if(e){let t=e.attachments?.length?e.attachments.map(e=>e.name).join(`, `):e.content;v.value.title=t.slice(0,40)+(t.length>40?`...`:``)}}v.value.updatedAt=Date.now()}}async function k(e,t){if(!(!e.trim()&&!(t&&t.length>0)||i.value)){v.value||S(x().id),E({id:f(),role:`user`,content:e.trim(),timestamp:Date.now(),attachments:t&&t.length>0?t:void 0}),O(),i.value=!0;try{let n=y.value.filter(e=>(e.role===`user`||e.role===`assistant`)&&e.content.trim()).map(e=>({role:e.role,content:e.content})),r=e.trim();if(t&&t.length>0){let e=(await p(t)).map(e=>`[File: ${e.name}](${e.path})`);r=r?r+`
3
+
4
+ `+e.join(`
5
+ `):e.join(`
6
+ `)}let s=o(),c=v.value?.model||s.selectedModel,l=await u({input:r,conversation_history:n,session_id:v.value?.id,model:c||void 0}),m=l.run_id||l.id;if(!m){E({id:f(),role:`system`,content:`Error: startRun returned no run ID. Response: ${JSON.stringify(l)}`,timestamp:Date.now()}),i.value=!1;return}a.value=d(m,e=>{switch(e.event){case`run.started`:break;case`message.delta`:{let t=y.value[y.value.length-1];t?.role===`assistant`&&t.isStreaming?t.content+=e.delta||``:E({id:f(),role:`assistant`,content:e.delta||``,timestamp:Date.now(),isStreaming:!0});break}case`tool.started`:{let t=y.value[y.value.length-1];t?.isStreaming&&D(t.id,{isStreaming:!1}),E({id:f(),role:`tool`,content:``,timestamp:Date.now(),toolName:e.tool||e.name,toolPreview:e.preview,toolStatus:`running`});break}case`tool.completed`:{let e=y.value.filter(e=>e.role===`tool`&&e.toolStatus===`running`);if(e.length>0){let t=e[e.length-1];D(t.id,{toolStatus:`done`})}break}case`run.completed`:let t=y.value[y.value.length-1];t?.isStreaming&&D(t.id,{isStreaming:!1}),i.value=!1,a.value=null,O();break;case`run.failed`:let n=y.value[y.value.length-1];n?.isStreaming?D(n.id,{isStreaming:!1,content:e.error?`Error: ${e.error}`:`Run failed`,role:`system`}):E({id:f(),role:`system`,content:e.error?`Error: ${e.error}`:`Run failed`,timestamp:Date.now()}),y.value.forEach((e,t)=>{e.role===`tool`&&e.toolStatus===`running`&&(y.value[t]={...e,toolStatus:`error`})}),i.value=!1,a.value=null;break}},()=>{let e=y.value[y.value.length-1];e?.isStreaming&&D(e.id,{isStreaming:!1}),i.value=!1,a.value=null,O()},e=>{let t=y.value[y.value.length-1];t?.isStreaming?D(t.id,{isStreaming:!1,content:`Error: ${e.message}`,role:`system`}):E({id:f(),role:`system`,content:`Error: ${e.message}`,timestamp:Date.now()}),i.value=!1,a.value=null})}catch(e){E({id:f(),role:`system`,content:`Error: ${e.message}`,timestamp:Date.now()}),i.value=!1,a.value=null}}}function A(){a.value?.abort(),i.value=!1;let e=y.value[y.value.length-1];e?.isStreaming&&D(e.id,{isStreaming:!1}),a.value=null}return b(),{sessions:t,activeSessionId:r,activeSession:v,messages:y,isStreaming:i,isLoadingSessions:g,isLoadingMessages:_,newChat:C,switchSession:S,switchSessionModel:w,deleteSession:T,sendMessage:k,stopStreaming:A,loadSessions:b}});export{g as t};
@@ -0,0 +1 @@
1
+ import{Q as e}from"./browser-Bf2Q3p4g.js";var t=e(`n-message-api`),n=e(`n-message-provider`);export{n,t};
@@ -0,0 +1 @@
1
+ .model-selector[data-v-00830782]{margin-bottom:8px;padding:0 12px}.model-label[data-v-00830782]{color:#999;text-transform:uppercase;letter-spacing:.5px;margin-bottom:6px;font-size:11px;font-weight:600}.sidebar[data-v-afd7c4c4]{background-color:#f5f5f5;border-right:1px solid #e0e0e0;flex-direction:column;flex-shrink:0;width:240px;height:100vh;padding:0 12px 20px;transition:width .25s;display:flex}.logo-img[data-v-afd7c4c4]{border-radius:0;flex-shrink:0;width:28px;height:28px}.sidebar-logo[data-v-afd7c4c4]{color:#1a1a1a;cursor:pointer;background-color:#fff;align-items:center;gap:10px;margin:0 -12px;padding:20px 12px;display:flex;position:relative;overflow:hidden;box-shadow:0 2px 8px #00000014}.sidebar-logo .logo-text[data-v-afd7c4c4]{letter-spacing:.5px;font-size:18px;font-weight:600}.sidebar-logo .logo-dance[data-v-afd7c4c4]{object-fit:contain;border-radius:10px;flex-shrink:0;width:auto;height:100px;position:absolute;top:50%;right:12px;transform:translateY(-50%)}.sidebar-nav[data-v-afd7c4c4]{flex-direction:column;flex:1;gap:4px;padding-top:12px;display:flex}.nav-item[data-v-afd7c4c4]{color:#666;cursor:pointer;text-align:left;background:0 0;border:none;border-radius:6px;align-items:center;gap:10px;width:100%;padding:10px 12px;font-size:14px;transition:all .15s;display:flex}.nav-item[data-v-afd7c4c4]:hover{color:#1a1a1a;background-color:#3333330f}.nav-item.active[data-v-afd7c4c4]{color:#333;background-color:#3333331f}.sidebar-footer[data-v-afd7c4c4]{border-top:1px solid #e0e0e0;padding-top:16px}.status-row[data-v-afd7c4c4]{justify-content:space-between;align-items:center;padding:8px 12px;display:flex}.status-indicator[data-v-afd7c4c4]{align-items:center;gap:8px;font-size:12px;display:flex}.status-indicator .status-dot[data-v-afd7c4c4]{border-radius:50%;flex-shrink:0;width:8px;height:8px}.status-indicator.connected .status-dot[data-v-afd7c4c4]{background-color:#2e7d32;box-shadow:0 0 6px #2e7d3280}.status-indicator.disconnected .status-dot[data-v-afd7c4c4]{background-color:#c62828}.status-indicator .status-text[data-v-afd7c4c4]{color:#666}.version-info[data-v-afd7c4c4]{color:#999;padding:2px 12px 8px;font-size:11px}.app-layout[data-v-ff8c112e]{width:100vw;height:100vh;display:flex;overflow:hidden}.app-layout.no-sidebar[data-v-ff8c112e]{display:block}.app-main[data-v-ff8c112e]{background-color:#fafafa;flex:1;overflow-y:auto}.no-sidebar .app-main[data-v-ff8c112e]{height:100vh}*,:before,:after{box-sizing:border-box;margin:0;padding:0}html,body,#app{width:100%;height:100%;overflow:hidden}body{color:#1a1a1a;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:#fafafa;font-family:Inter,system-ui,-apple-system,sans-serif;font-size:14px;line-height:1.6}code,pre,.mono{font-family:JetBrains Mono,Fira Code,Consolas,monospace}a{color:#333;text-decoration:none}a:hover{color:#1a1a1a}::-webkit-scrollbar{width:6px;height:6px}::-webkit-scrollbar-track{background:0 0}::-webkit-scrollbar-thumb{background:#e0e0e0;border-radius:3px}::-webkit-scrollbar-thumb:hover{background:#999}::selection{background:#3333334d}.page-header{border-bottom:1px solid #e0e0e0;flex-shrink:0;justify-content:space-between;align-items:center;padding:21px 20px;display:flex}.header-title{color:#1a1a1a;font-size:16px;font-weight:600}
@@ -0,0 +1,306 @@
1
+ import{A as e,C as t,D as n,E as r,F as i,G as a,K as o,N as s,O as c,Q as l,R as u,T as d,U as f,W as p,Y as m,Z as h,b as g,c as _,ct as v,d as y,gt as b,it as x,j as S,l as C,mt as w,ot as T,p as E,pt as D,t as O,w as k,y as A}from"./router-Ddepf70Q.js";import{t as j}from"./pinia-bZ6_VpBU.js";import{n as M,r as N,t as P}from"./_plugin-vue_export-helper-DQGaK6t5.js";import{B as F,Q as ee,V as te,Y as ne,a as re,at as I,c as L,ct as R,d as ie,dt as z,et as ae,f as oe,ht as se,lt as B,n as V,o as ce,ot as H,r as le,s as ue,u as de,z as U}from"./browser-Bf2Q3p4g.js";import{I as W,l as G,u as fe}from"./Popover-pOQtxFC1.js";import{b as pe,c as me,i as he,n as ge}from"./Suffix-C1X_jn5E.js";import{a as _e,c as ve,d as ye,f as be,i as xe,l as K,m as Se,n as Ce,o as we,p as Te,r as Ee,s as De,t as Oe,u as ke}from"./Modal-D421R1s7.js";import{t as Ae}from"./Close-2w73mIOt.js";import{t as je}from"./Select-rOqAn7Lj.js";import{i as Me}from"./Button-sJ2BpaPl.js";import{t as q}from"./omit-QZj0aLfU.js";import{n as Ne,t as Pe}from"./context-Bm7UPqDk.js";import"./logo-CiQBpLPw.js";import{t as J}from"./app-DHhjDueA.js";import{t as Fe}from"./chat-B0V07VGa.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var Ie={login:{title:`Login`,description:`Enter your access token to continue. Find it in the server startup logs.`,placeholder:`Access token`,submit:`Login`,tokenRequired:`Please enter your access token`,invalidToken:`Invalid token`,connectionFailed:`Cannot connect to server`},common:{loading:`Loading...`,cancel:`Cancel`,delete:`Delete`,edit:`Edit`,save:`Save`,saved:`Saved`,update:`Update`,create:`Create`,saveFailed:`Save failed`,ok:`OK`,copied:`Copied`,copy:`Copy`,noData:`No data`,fetch:`Fetch`,add:`Add`,enable:`Enable`,disable:`Disable`,configured:`Configured`,notConfigured:`Not configured`},sidebar:{chat:`Chat`,jobs:`Jobs`,models:`Models`,skills:`Skills`,memory:`Memory`,logs:`Logs`,usage:`Usage`,channels:`Channels`,settings:`Settings`,connected:`Connected`,disconnected:`Disconnected`},chat:{emptyState:`Start a conversation with Hermes Agent`,inputPlaceholder:`Type a message... (Enter to send, Shift+Enter for new line)`,attachFiles:`Attach files`,stop:`Stop`,send:`Send`,contextUsed:`Context used:`,sessions:`Sessions`,noSessions:`No sessions`,newChat:`New Chat`,deleteSession:`Delete this session?`,sessionDeleted:`Session deleted`,rename:`Rename`,copySessionId:`Copy Session ID`,renamed:`Renamed`,renameFailed:`Rename failed`,renameSession:`Rename Session`,enterNewTitle:`Enter new title`,other:`Other`,runFailed:`Run failed`,tool:`Tool`,error:`error`,arguments:`Arguments`,result:`Result`,truncated:`... (truncated)`},jobs:{title:`Scheduled Jobs`,createJob:`Create Job`,editJob:`Edit Job`,noJobs:`No scheduled jobs yet. Create one to get started.`,name:`Name`,namePlaceholder:`Job name`,schedule:`Schedule (Cron Expression)`,schedulePlaceholder:`e.g. 0 9 * * *`,quickPresets:`Quick Presets`,selectPreset:`Select a preset...`,presetEveryMinute:`Every minute`,presetEvery5Min:`Every 5 minutes`,presetEveryHour:`Every hour`,presetEveryDay:`Every day at 00:00`,presetEveryDay9:`Every day at 09:00`,presetEveryMonday:`Every Monday at 09:00`,presetEveryMonth:`Every month 1st at 09:00`,prompt:`Prompt`,promptPlaceholder:`The prompt to execute`,deliverTarget:`Deliver Target`,origin:`Origin`,local:`Local`,repeatCount:`Repeat Count (optional)`,repeatPlaceholder:`Leave empty for infinite`,jobCreated:`Job created`,jobUpdated:`Job updated`,nameRequired:`Name is required`,scheduleRequired:`Schedule is required`,loadFailed:`Failed to load job`,jobPaused:`Job paused`,jobResumed:`Job resumed`,jobTriggered:`Job triggered`,jobDeleted:`Job deleted`,status:{running:`Running`,paused:`Paused`,disabled:`Disabled`,scheduled:`Scheduled`},info:{schedule:`Schedule`,lastRun:`Last Run`,nextRun:`Next Run`,deliver:`Deliver`,repeat:`Repeat`},action:{pause:`Pause`,pauseJob:`Pause job`,resume:`Resume`,resumeJob:`Resume job`,runNow:`Run Now`,triggerImmediately:`Trigger immediately`}},skills:{title:`Skills`,searchPlaceholder:`Search skills...`,noMatch:`No skills match your search`,noSkills:`No skills found`,backTo:`Back to`,attachedFiles:`Attached Files`,loadFailed:`Failed to load skill`,fileLoadFailed:`Failed to load file`,toggleFailed:`Failed to toggle skill`},memory:{title:`Memory`,refresh:`Refresh`,loadFailed:`Failed to load memory`,myNotes:`My Notes`,noNotes:`No notes yet.`,notesPlaceholder:`Write your notes...`,userProfile:`User Profile`,noProfile:`No profile yet.`,profilePlaceholder:`Write your profile...`},models:{title:`Models`,addProvider:`Add Provider`,providerType:`Provider Type`,preset:`Preset`,custom:`Custom`,selectProvider:`Select Provider`,chooseProvider:`Choose a provider...`,name:`Name`,autoGeneratedName:`Auto-generated from Base URL`,baseUrl:`Base URL`,baseUrlPlaceholder:`e.g. https://api.example.com/v1`,apiKey:`API Key`,apiKeyPlaceholder:`sk-...`,defaultModel:`Default Model`,selectModel:`Select a model...`,providerAdded:`Provider added`,providerDeleted:`Provider deleted`,deleteProvider:`Delete Provider`,deleteConfirm:`Are you sure you want to delete "{name}"?`,noProviders:`No providers found. Add a custom provider to get started.`,builtIn:`Built-in`,customType:`Custom`,provider:`Provider`,local:`Local ({host})`,selectProviderRequired:`Please select a provider`,baseUrlRequired:`Base URL is required`,apiKeyRequired:`API Key is required`,modelRequired:`Default Model is required`,enterBaseUrl:`Please enter Base URL first`,unexpectedFormat:`Unexpected response format`,foundModels:`Found {count} models`,fetchFailed:`Failed to fetch models`},logs:{title:`Logs`,all:`All`,searchPlaceholder:`Search...`,refresh:`Refresh`,noEntries:`No log entries`},settings:{title:`Settings`,saved:`Saved`,saveFailed:`Save failed`,tabs:{display:`Display`,agent:`Agent`,memory:`Memory`,session:`Session`,privacy:`Privacy`,apiServer:`API Server`},display:{streaming:`Stream Responses`,streamingHint:`Show AI replies in real-time`,compact:`Compact Mode`,compactHint:`Reduce message spacing`,showReasoning:`Show Reasoning`,showReasoningHint:`Show model thinking process`,showCost:`Show Cost`,showCostHint:`Show token usage in replies`,inlineDiffs:`Inline Diffs`,inlineDiffsHint:`Show code changes inline`,bellOnComplete:`Completion Sound`,bellOnCompleteHint:`Play sound when AI finishes`,busyInputMode:`Busy Input Mode`,busyInputModeHint:`Allow input while AI is processing`},agent:{maxTurns:`Max Turns`,maxTurnsHint:`Maximum interaction rounds per conversation`,gatewayTimeout:`Gateway Timeout`,gatewayTimeoutHint:`Request timeout in seconds`,restartDrainTimeout:`Restart Drain Timeout`,restartDrainTimeoutHint:`Drain timeout before restart in seconds`,toolEnforcement:`Tool Enforcement`,toolEnforcementHint:`Control tool call execution mode`,auto:`Auto`,always:`Always`,never:`Never`},memory:{enabled:`Enable Memory`,enabledHint:`Allow AI to remember conversation context`,userProfile:`User Profile`,userProfileHint:`Allow AI to remember user preferences`,charLimit:`Memory Char Limit`,charLimitHint:`Max characters for MEMORY.md`,userCharLimit:`User Profile Char Limit`,userCharLimitHint:`Max characters for USER.md`},session:{mode:`Reset Mode`,modeHint:`Trigger condition for session reset`,modeBoth:`Idle + Scheduled`,modeIdle:`Idle Only`,modeHourly:`Scheduled Only`,idleMinutes:`Idle Timeout`,idleMinutesHint:`Wait time before auto-reset (minutes)`,atHour:`Scheduled Reset Time`,atHourHint:`Reset session at this hour daily`},privacy:{redactPii:`Redact PII`,redactPiiHint:`Auto-detect and hide sensitive info (passwords, keys, etc.)`},apiServer:{enable:`Enable`,enableHint:`Enable API server`,host:`Host`,hostHint:`Listen address`,port:`Port`,portHint:`Listen port`,key:`Key`,keyHint:`API access key`,cors:`CORS Origins`,corsHint:`Allowed cross-origin sources`}},platform:{requireMention:`Require {'@'}Mention`,requireMentionGroup:`Require {'@'}mention in groups to respond`,requireMentionChannel:`Require {'@'}mention in channels to respond`,requireMentionRoom:`Require {'@'}mention in rooms to respond`,reactions:`Reactions`,reactionsHint:`React to messages with emoji`,freeResponseChats:`Free Response Chats`,freeResponseChatsHint:`Chat IDs that respond without {'@'}mention (comma-separated)`,freeResponseChannels:`Free Response Channels`,freeResponseChannelsHint:`Channel IDs that respond without {'@'}mention (comma-separated)`,freeResponseRooms:`Free Response Rooms`,freeResponseRoomsHint:`Room IDs that respond without {'@'}mention (comma-separated)`,mentionPatterns:`Custom Mention Patterns`,mentionPatternsHint:`Additional trigger patterns`,autoThread:`Auto Thread`,autoThreadHint:`Auto-create reply threads after {'@'}mention`,autoThreadHintRoom:`Auto-create reply threads in rooms`,dmMentionThreads:`DM Mention Threads`,dmMentionThreadsHint:`Use thread replies for mentions in DMs`,allowBots:`Allow Bot Messages`,allowBotsHint:`Respond to messages from other bots`,allowedChannels:`Allowed Channels`,allowedChannelsHint:`Whitelist channel IDs (comma-separated)`,ignoredChannels:`Ignored Channels`,ignoredChannelsHint:`Channels where bot never responds (comma-separated)`,noThreadChannels:`No-Thread Channels`,noThreadChannelsHint:`Channels where bot responds without threads (comma-separated)`,botToken:`Bot Token`,botTokenHint:`Bot token from developer portal`,accessToken:`Access Token`,accessTokenHint:`Matrix access token`,homeserver:`Homeserver URL`,homeserverHint:`Matrix homeserver URL`,appId:`App ID`,appIdHint:`Feishu App ID`,appSecret:`App Secret`,appSecretHint:`Feishu App Secret`,clientId:`Client ID`,clientIdHint:`DingTalk Client ID`,clientSecret:`Client Secret`,clientSecretHint:`DingTalk Client Secret`,botId:`Bot ID`,botIdHint:`WeCom Bot ID`,wecomSecretHint:`WeCom Bot Secret`,waEnabled:`Enable WhatsApp`,waEnabledHint:`Enable WhatsApp via QR code pairing`,weixinToken:`Weixin Token`,weixinTokenHint:`From weixin CLI QR login (hermes weixin)`,accountId:`Account ID`,accountIdHint:`Weixin account ID`,qrLogin:`QR Login`,qrRelogin:`Re-login`,qrFetching:`Fetching QR code...`,qrScanHint:`Scan with WeChat to login`,qrScanedHint:`Scaned, please confirm on phone...`},language:{label:`Language`,zh:`中文`,en:`English`},usage:{title:`Usage Statistics`,refresh:`Refresh`,totalTokens:`Total Tokens`,inputTokens:`Input`,outputTokens:`Output`,totalSessions:`Total Sessions`,avgPerDay:`~{n}/day avg`,estimatedCost:`Est. Cost`,cacheHitRate:`Cache Hit Rate`,modelBreakdown:`Model Breakdown`,dailyTrend:`Daily Usage (Last 30 Days)`,date:`Date`,tokens:`Tokens`,cache:`Cache`,sessions:`Sessions`,cost:`Cost`,noData:`No usage data`}},Le={login:{title:`登录`,description:`输入访问令牌以继续。令牌在服务端启动日志中查看。`,placeholder:`访问令牌`,submit:`登录`,tokenRequired:`请输入访问令牌`,invalidToken:`令牌无效`,connectionFailed:`无法连接到服务器`},common:{loading:`加载中...`,cancel:`取消`,delete:`删除`,edit:`编辑`,save:`保存`,saved:`已保存`,saveFailed:`保存失败`,ok:`确定`,copied:`已复制`,copy:`复制`,update:`更新`,create:`创建`,noData:`暂无数据`,fetch:`获取`,add:`添加`,enable:`启用`,disable:`禁用`,configured:`已配置`,notConfigured:`未配置`},sidebar:{chat:`对话`,jobs:`任务`,models:`模型`,skills:`技能`,memory:`记忆`,logs:`日志`,usage:`用量`,channels:`频道`,settings:`设置`,connected:`已连接`,disconnected:`未连接`},chat:{emptyState:`开始与 Hermes Agent 对话`,inputPlaceholder:`输入消息... (Enter 发送,Shift+Enter 换行)`,attachFiles:`添加附件`,stop:`停止`,send:`发送`,contextUsed:`上下文已用:`,sessions:`会话`,noSessions:`暂无会话`,newChat:`新建对话`,deleteSession:`确定删除此会话?`,sessionDeleted:`会话已删除`,rename:`重命名`,copySessionId:`复制会话 ID`,renamed:`已重命名`,renameFailed:`重命名失败`,renameSession:`重命名会话`,enterNewTitle:`输入新标题`,other:`其他`,runFailed:`运行失败`,tool:`工具`,error:`错误`,arguments:`参数`,result:`结果`,truncated:`... (已截断)`},jobs:{title:`定时任务`,createJob:`创建任务`,editJob:`编辑任务`,noJobs:`暂无定时任务,创建一个开始吧。`,name:`名称`,namePlaceholder:`任务名称`,schedule:`调度表达式 (Cron)`,schedulePlaceholder:`例如 0 9 * * *`,quickPresets:`快速预设`,selectPreset:`选择预设...`,presetEveryMinute:`每分钟`,presetEvery5Min:`每 5 分钟`,presetEveryHour:`每小时`,presetEveryDay:`每天 00:00`,presetEveryDay9:`每天 09:00`,presetEveryMonday:`每周一 09:00`,presetEveryMonth:`每月 1 日 09:00`,prompt:`提示词`,promptPlaceholder:`要执行的内容`,deliverTarget:`投递目标`,origin:`来源`,local:`本地`,repeatCount:`重复次数(可选)`,repeatPlaceholder:`留空表示无限重复`,jobCreated:`任务已创建`,jobUpdated:`任务已更新`,nameRequired:`名称为必填项`,scheduleRequired:`调度表达式为必填项`,loadFailed:`加载任务失败`,jobPaused:`任务已暂停`,jobResumed:`任务已恢复`,jobTriggered:`任务已触发`,jobDeleted:`任务已删除`,status:{running:`运行中`,paused:`已暂停`,disabled:`已禁用`,scheduled:`已调度`},info:{schedule:`调度`,lastRun:`上次运行`,nextRun:`下次运行`,deliver:`投递`,repeat:`重复`},action:{pause:`暂停`,pauseJob:`暂停任务`,resume:`恢复`,resumeJob:`恢复任务`,runNow:`立即运行`,triggerImmediately:`立即触发`}},skills:{title:`技能`,searchPlaceholder:`搜索技能...`,noMatch:`没有匹配的技能`,noSkills:`暂无技能`,backTo:`返回`,attachedFiles:`附件文件`,loadFailed:`加载技能失败`,fileLoadFailed:`加载文件失败`,toggleFailed:`切换技能状态失败`},memory:{title:`记忆`,refresh:`刷新`,loadFailed:`加载记忆失败`,myNotes:`我的笔记`,noNotes:`暂无笔记。`,notesPlaceholder:`输入笔记内容...`,userProfile:`用户画像`,noProfile:`暂无画像。`,profilePlaceholder:`输入用户画像...`},models:{title:`模型`,addProvider:`添加 Provider`,providerType:`Provider 类型`,preset:`预设`,custom:`自定义`,selectProvider:`选择 Provider`,chooseProvider:`选择一个 provider...`,name:`名称`,autoGeneratedName:`根据 Base URL 自动生成`,baseUrl:`Base URL`,baseUrlPlaceholder:`例如 https://api.example.com/v1`,apiKey:`API Key`,apiKeyPlaceholder:`sk-...`,defaultModel:`默认模型`,selectModel:`选择模型...`,providerAdded:`Provider 已添加`,providerDeleted:`Provider 已删除`,deleteProvider:`删除 Provider`,deleteConfirm:`确定删除 "{name}" 吗?`,noProviders:`暂无 Provider,添加一个开始吧。`,builtIn:`内置`,customType:`自定义`,provider:`Provider`,local:`本地 ({host})`,selectProviderRequired:`请选择 Provider`,baseUrlRequired:`Base URL 为必填项`,apiKeyRequired:`API Key 为必填项`,modelRequired:`默认模型为必填项`,enterBaseUrl:`请先输入 Base URL`,unexpectedFormat:`响应格式异常`,foundModels:`找到 {count} 个模型`,fetchFailed:`获取模型失败`},logs:{title:`日志`,all:`全部`,searchPlaceholder:`搜索...`,refresh:`刷新`,noEntries:`暂无日志`},settings:{title:`设置`,saved:`已保存`,saveFailed:`保存失败`,tabs:{display:`显示`,agent:`代理`,memory:`记忆`,session:`会话`,privacy:`隐私`,apiServer:`API 服务器`},display:{streaming:`流式响应`,streamingHint:`实时显示 AI 回复`,compact:`紧凑模式`,compactHint:`减少消息间距`,showReasoning:`显示推理过程`,showReasoningHint:`展示模型思考过程`,showCost:`显示费用`,showCostHint:`在回复中显示 token 使用量`,inlineDiffs:`内联差异`,inlineDiffsHint:`代码变更以内联方式显示`,bellOnComplete:`完成提示音`,bellOnCompleteHint:`AI 回复完成时播放提示音`,busyInputMode:`忙碌输入模式`,busyInputModeHint:`AI 处理中仍可输入`},agent:{maxTurns:`最大轮次`,maxTurnsHint:`单次对话最大交互轮数`,gatewayTimeout:`网关超时`,gatewayTimeoutHint:`单次请求超时时间(秒)`,restartDrainTimeout:`重启排空超时`,restartDrainTimeoutHint:`重启前排空请求的超时时间(秒)`,toolEnforcement:`工具执行策略`,toolEnforcementHint:`控制工具调用的执行模式`,auto:`自动`,always:`始终`,never:`从不`},memory:{enabled:`启用记忆`,enabledHint:`允许 AI 记住对话上下文`,userProfile:`用户画像`,userProfileHint:`允许 AI 记住用户偏好信息`,charLimit:`记忆字符上限`,charLimitHint:`MEMORY.md 最大字符数`,userCharLimit:`用户画像字符上限`,userCharLimitHint:`USER.md 最大字符数`},session:{mode:`重置模式`,modeHint:`会话重置的触发条件`,modeBoth:`空闲 + 定时`,modeIdle:`仅空闲`,modeHourly:`仅定时`,idleMinutes:`空闲超时`,idleMinutesHint:`无操作后自动重置的等待时间(分钟)`,atHour:`定时重置时间`,atHourHint:`每天在指定小时重置会话`},privacy:{redactPii:`脱敏 PII`,redactPiiHint:`自动检测并隐藏敏感信息(密码、密钥等)`},apiServer:{enable:`启用`,enableHint:`启用 API 服务器`,host:`主机`,hostHint:`监听地址`,port:`端口`,portHint:`监听端口`,key:`密钥`,keyHint:`API 访问密钥`,cors:`CORS 来源`,corsHint:`允许的跨域来源`}},platform:{requireMention:`需要 {'@'}提及`,requireMentionGroup:`群组中需要 {'@'}机器人 才会响应`,requireMentionChannel:`频道中需要 {'@'}机器人 才会响应`,requireMentionRoom:`房间中需要 {'@'}机器人 才会响应`,reactions:`表情回应`,reactionsHint:`对消息添加表情回应`,freeResponseChats:`自由响应聊天`,freeResponseChatsHint:`不需要 {'@'}提及即响应的聊天 ID(逗号分隔)`,freeResponseChannels:`自由响应频道`,freeResponseChannelsHint:`不需要 {'@'}提及即响应的频道 ID(逗号分隔)`,freeResponseRooms:`自由响应房间`,freeResponseRoomsHint:`不需要 {'@'}提及即响应的房间 ID(逗号分隔)`,mentionPatterns:`自定义提及模式`,mentionPatternsHint:`额外的触发模式列表`,autoThread:`自动创建线程`,autoThreadHint:`{'@'}提及 后自动创建回复线程`,autoThreadHintRoom:`在房间中自动创建回复线程`,dmMentionThreads:`DM 提及线程`,dmMentionThreadsHint:`在私聊中也使用线程回复提及`,allowBots:`允许机器人消息`,allowBotsHint:`响应其他机器人发送的消息`,allowedChannels:`允许的频道`,allowedChannelsHint:`白名单频道 ID(逗号分隔)`,ignoredChannels:`忽略的频道`,ignoredChannelsHint:`不响应的频道 ID(逗号分隔)`,noThreadChannels:`无线程频道`,noThreadChannelsHint:`不创建线程的频道 ID(逗号分隔)`,botToken:`Bot Token`,botTokenHint:`开发者门户获取的 Bot Token`,accessToken:`Access Token`,accessTokenHint:`Matrix Access Token`,homeserver:`Homeserver URL`,homeserverHint:`Matrix 服务器地址`,appId:`App ID`,appIdHint:`飞书 App ID`,appSecret:`App Secret`,appSecretHint:`飞书 App Secret`,clientId:`Client ID`,clientIdHint:`钉钉 Client ID`,clientSecret:`Client Secret`,clientSecretHint:`钉钉 Client Secret`,botId:`Bot ID`,botIdHint:`企业微信 Bot ID`,wecomSecretHint:`企业微信 Bot Secret`,waEnabled:`启用 WhatsApp`,waEnabledHint:`通过二维码配对启用 WhatsApp`,weixinToken:`微信 Token`,weixinTokenHint:`通过 weixin CLI 扫码登录获取 (hermes weixin)`,accountId:`Account ID`,accountIdHint:`微信 Account ID`,qrLogin:`扫码登录`,qrRelogin:`重新登录`,qrFetching:`正在获取二维码...`,qrScanHint:`使用微信扫描二维码登录`,qrScanedHint:`已扫描,请在手机上确认...`},language:{label:`语言`,zh:`中文`,en:`English`},usage:{title:`用量统计`,refresh:`刷新`,totalTokens:`总 Token 数`,inputTokens:`输入`,outputTokens:`输出`,totalSessions:`总会话数`,avgPerDay:`日均 ~{n}`,estimatedCost:`预估费用`,cacheHitRate:`缓存命中率`,modelBreakdown:`模型分布`,dailyTrend:`每日用量(近 30 天)`,date:`日期`,tokens:`Token`,cache:`缓存`,sessions:`会话`,cost:`费用`,noData:`暂无用量数据`}},Re=localStorage.getItem(`hermes_locale`),ze=navigator.language.slice(0,2),Be=M({legacy:!1,locale:Re||(ze===`zh`?`zh`:`en`),fallbackLocale:`en`,messages:{en:Ie,zh:Le}}),{cubicBezierEaseInOut:Y,cubicBezierEaseOut:Ve,cubicBezierEaseIn:He}=de;function Ue({overflow:e=`hidden`,duration:t=`.3s`,originalTransition:n=``,leavingDelay:r=`0s`,foldPadding:i=!1,enterToProps:a=void 0,leaveToProps:o=void 0,reverse:s=!1}={}){let c=s?`leave`:`enter`,l=s?`enter`:`leave`;return[I(`&.fade-in-height-expand-transition-${l}-from,
2
+ &.fade-in-height-expand-transition-${c}-to`,Object.assign(Object.assign({},a),{opacity:1})),I(`&.fade-in-height-expand-transition-${l}-to,
3
+ &.fade-in-height-expand-transition-${c}-from`,Object.assign(Object.assign({},o),{opacity:0,marginTop:`0 !important`,marginBottom:`0 !important`,paddingTop:i?`0 !important`:void 0,paddingBottom:i?`0 !important`:void 0})),I(`&.fade-in-height-expand-transition-${l}-active`,`
4
+ overflow: ${e};
5
+ transition:
6
+ max-height ${t} ${Y} ${r},
7
+ opacity ${t} ${Ve} ${r},
8
+ margin-top ${t} ${Y} ${r},
9
+ margin-bottom ${t} ${Y} ${r},
10
+ padding-top ${t} ${Y} ${r},
11
+ padding-bottom ${t} ${Y} ${r}
12
+ ${n?`,${n}`:``}
13
+ `),I(`&.fade-in-height-expand-transition-${c}-active`,`
14
+ overflow: ${e};
15
+ transition:
16
+ max-height ${t} ${Y},
17
+ opacity ${t} ${He},
18
+ margin-top ${t} ${Y},
19
+ margin-bottom ${t} ${Y},
20
+ padding-top ${t} ${Y},
21
+ padding-bottom ${t} ${Y}
22
+ ${n?`,${n}`:``}
23
+ `)]}var We=S({name:`ConfigProvider`,alias:[`App`],props:{abstract:Boolean,bordered:{type:Boolean,default:void 0},clsPrefix:String,locale:Object,dateLocale:Object,namespace:String,rtl:Array,tag:{type:String,default:`div`},hljs:Object,katex:Object,theme:Object,themeOverrides:Object,componentOptions:Object,icons:Object,breakpoints:Object,preflightStyleDisabled:Boolean,styleMountTarget:Object,inlineThemeDisabled:{type:Boolean,default:void 0},as:{type:String,validator:()=>(ne(`config-provider`,"`as` is deprecated, please use `tag` instead."),!0),default:void 0}},setup(e){let n=i(te,null),r=t(()=>{let{theme:t}=e;if(t===null)return;let r=n?.mergedThemeRef.value;return t===void 0?r:r===void 0?t:Object.assign({},r,t)}),a=t(()=>{let{themeOverrides:t}=e;if(t!==null){if(t===void 0)return n?.mergedThemeOverridesRef.value;{let e=n?.mergedThemeOverridesRef.value;return e===void 0?t:oe({},e,t)}}}),s=ae(()=>{let{namespace:t}=e;return t===void 0?n?.mergedNamespaceRef.value:t}),c=ae(()=>{let{bordered:t}=e;return t===void 0?n?.mergedBorderedRef.value:t}),l=t(()=>{let{icons:t}=e;return t===void 0?n?.mergedIconsRef.value:t}),u=t(()=>{let{componentOptions:t}=e;return t===void 0?n?.mergedComponentPropsRef.value:t}),d=t(()=>{let{clsPrefix:t}=e;return t===void 0?n?n.mergedClsPrefixRef.value:`n`:t}),f=t(()=>{var t;let{rtl:r}=e;if(r===void 0)return n?.mergedRtlRef.value;let i={};for(let e of r)i[e.name]=x(e),(t=e.peers)==null||t.forEach(e=>{e.name in i||(i[e.name]=x(e))});return i}),p=t(()=>e.breakpoints||n?.mergedBreakpointsRef.value),m=e.inlineThemeDisabled||n?.inlineThemeDisabled,h=e.preflightStyleDisabled||n?.preflightStyleDisabled,g=e.styleMountTarget||n?.styleMountTarget;return o(te,{mergedThemeHashRef:t(()=>{let{value:e}=r,{value:t}=a,n=t&&Object.keys(t).length!==0,i=e?.name;return i?n?`${i}-${se(JSON.stringify(a.value))}`:i:n?se(JSON.stringify(a.value)):``}),mergedBreakpointsRef:p,mergedRtlRef:f,mergedIconsRef:l,mergedComponentPropsRef:u,mergedBorderedRef:c,mergedNamespaceRef:s,mergedClsPrefixRef:d,mergedLocaleRef:t(()=>{let{locale:t}=e;if(t!==null)return t===void 0?n?.mergedLocaleRef.value:t}),mergedDateLocaleRef:t(()=>{let{dateLocale:t}=e;if(t!==null)return t===void 0?n?.mergedDateLocaleRef.value:t}),mergedHljsRef:t(()=>{let{hljs:t}=e;return t===void 0?n?.mergedHljsRef.value:t}),mergedKatexRef:t(()=>{let{katex:t}=e;return t===void 0?n?.mergedKatexRef.value:t}),mergedThemeRef:r,mergedThemeOverridesRef:a,inlineThemeDisabled:m||!1,preflightStyleDisabled:h||!1,styleMountTarget:g}),{mergedClsPrefix:d,mergedBordered:c,mergedNamespace:s,mergedTheme:r,mergedThemeOverrides:a}},render(){var e,t;return this.abstract?(t=this.$slots).default?.call(t):s(this.as||this.tag,{class:`${this.mergedClsPrefix||`n`}-config-provider`},(e=this.$slots).default?.call(e))}}),Ge=Object.assign(Object.assign({},xe),{onAfterEnter:Function,onAfterLeave:Function,transformOrigin:String,blockScroll:{type:Boolean,default:!0},closeOnEsc:{type:Boolean,default:!0},onEsc:Function,autoFocus:{type:Boolean,default:!0},internalStyle:[String,Object],maskClosable:{type:Boolean,default:!0},zIndex:Number,onPositiveClick:Function,onNegativeClick:Function,onClose:Function,onMaskClick:Function,draggable:[Boolean,Object]}),Ke=S({name:`DialogEnvironment`,props:Object.assign(Object.assign({},Ge),{internalKey:{type:String,required:!0},to:[String,Object],onInternalAfterLeave:{type:Function,required:!0}}),setup(e){let t=v(!0);function n(){let{onInternalAfterLeave:t,internalKey:n,onAfterLeave:r}=e;t&&t(n),r&&r()}function r(t){let{onPositiveClick:n}=e;n?Promise.resolve(n(t)).then(e=>{e!==!1&&c()}):c()}function i(t){let{onNegativeClick:n}=e;n?Promise.resolve(n(t)).then(e=>{e!==!1&&c()}):c()}function a(){let{onClose:t}=e;t?Promise.resolve(t()).then(e=>{e!==!1&&c()}):c()}function o(t){let{onMaskClick:n,maskClosable:r}=e;n&&(n(t),r&&c())}function s(){let{onEsc:t}=e;t&&t()}function c(){t.value=!1}function l(e){t.value=e}return{show:t,hide:c,handleUpdateShow:l,handleAfterLeave:n,handleCloseClick:a,handleNegativeClick:i,handlePositiveClick:r,handleMaskClick:o,handleEsc:s}},render(){let{handlePositiveClick:e,handleUpdateShow:t,handleNegativeClick:n,handleCloseClick:r,handleAfterLeave:i,handleMaskClick:a,handleEsc:o,to:c,zIndex:l,maskClosable:u,show:d}=this;return s(Oe,{show:d,onUpdateShow:t,onMaskClick:a,onEsc:o,to:c,zIndex:l,maskClosable:u,onAfterEnter:this.onAfterEnter,onAfterLeave:i,closeOnEsc:this.closeOnEsc,blockScroll:this.blockScroll,autoFocus:this.autoFocus,transformOrigin:this.transformOrigin,draggable:this.draggable,internalAppear:!0,internalDialog:!0},{default:({draggableClass:t})=>s(Ce,Object.assign({},fe(this.$props,Ee),{titleClass:w([this.titleClass,t]),style:this.internalStyle,onClose:r,onNegativeClick:n,onPositiveClick:e}))})}}),qe=S({name:`DialogProvider`,props:{injectionKey:String,to:[String,Object]},setup(){let e=v([]),t={};function n(n={}){let r=W(),i=T(Object.assign(Object.assign({},n),{key:r,destroy:()=>{var e;(e=t[`n-dialog-${r}`])==null||e.hide()}}));return e.value.push(i),i}let r=[`info`,`success`,`warning`,`error`].map(e=>t=>n(Object.assign(Object.assign({},t),{type:e})));function i(t){let{value:n}=e;n.splice(n.findIndex(e=>e.key===t),1)}function a(){Object.values(t).forEach(e=>{e?.hide()})}let s={create:n,destroyAll:a,info:r[0],success:r[1],warning:r[2],error:r[3]};return o(_e,s),o(we,{clickedRef:Te(64),clickedPositionRef:Se()}),o(De,e),Object.assign(Object.assign({},s),{dialogList:e,dialogInstRefs:t,handleAfterLeave:i})},render(){var e;return s(A,null,[this.dialogList.map(e=>s(Ke,q(e,[`destroy`,`style`],{internalStyle:e.style,to:this.to,ref:t=>{t===null?delete this.dialogInstRefs[`n-dialog-${e.key}`]:this.dialogInstRefs[`n-dialog-${e.key}`]=t},internalKey:e.key,onInternalAfterLeave:this.handleAfterLeave}))),(e=this.$slots).default?.call(e)])}}),Je={margin:`0 0 8px 0`,padding:`10px 20px`,maxWidth:`720px`,minWidth:`420px`,iconMargin:`0 10px 0 0`,closeMargin:`0 0 0 10px`,closeSize:`20px`,closeIconSize:`16px`,iconSize:`20px`,fontSize:`14px`};function Ye(e){let{textColor2:t,closeIconColor:n,closeIconColorHover:r,closeIconColorPressed:i,infoColor:a,successColor:o,errorColor:s,warningColor:c,popoverColor:l,boxShadow2:u,primaryColor:d,lineHeight:f,borderRadius:p,closeColorHover:m,closeColorPressed:h}=e;return Object.assign(Object.assign({},Je),{closeBorderRadius:p,textColor:t,textColorInfo:t,textColorSuccess:t,textColorError:t,textColorWarning:t,textColorLoading:t,color:l,colorInfo:l,colorSuccess:l,colorError:l,colorWarning:l,colorLoading:l,boxShadow:u,boxShadowInfo:u,boxShadowSuccess:u,boxShadowError:u,boxShadowWarning:u,boxShadowLoading:u,iconColor:t,iconColorInfo:a,iconColorSuccess:o,iconColorWarning:c,iconColorError:s,iconColorLoading:d,closeColorHover:m,closeColorPressed:h,closeIconColor:n,closeIconColorHover:r,closeIconColorPressed:i,closeColorHoverInfo:m,closeColorPressedInfo:h,closeIconColorInfo:n,closeIconColorHoverInfo:r,closeIconColorPressedInfo:i,closeColorHoverSuccess:m,closeColorPressedSuccess:h,closeIconColorSuccess:n,closeIconColorHoverSuccess:r,closeIconColorPressedSuccess:i,closeColorHoverError:m,closeColorPressedError:h,closeIconColorError:n,closeIconColorHoverError:r,closeIconColorPressedError:i,closeColorHoverWarning:m,closeColorPressedWarning:h,closeIconColorWarning:n,closeIconColorHoverWarning:r,closeIconColorPressedWarning:i,closeColorHoverLoading:m,closeColorPressedLoading:h,closeIconColorLoading:n,closeIconColorHoverLoading:r,closeIconColorPressedLoading:i,loadingColor:d,lineHeight:f,borderRadius:p,border:`0`})}var Xe={name:`Message`,common:V,self:Ye},Ze={icon:Function,type:{type:String,default:`info`},content:[String,Number,Function],showIcon:{type:Boolean,default:!0},closable:Boolean,keepAliveOnHover:Boolean,spinProps:Object,onClose:Function,onMouseenter:Function,onMouseleave:Function},Qe=I([H(`message-wrapper`,`
24
+ margin: var(--n-margin);
25
+ z-index: 0;
26
+ transform-origin: top center;
27
+ display: flex;
28
+ `,[Ue({overflow:`visible`,originalTransition:`transform .3s var(--n-bezier)`,enterToProps:{transform:`scale(1)`},leaveToProps:{transform:`scale(0.85)`}})]),H(`message`,`
29
+ box-sizing: border-box;
30
+ display: flex;
31
+ align-items: center;
32
+ transition:
33
+ color .3s var(--n-bezier),
34
+ box-shadow .3s var(--n-bezier),
35
+ background-color .3s var(--n-bezier),
36
+ opacity .3s var(--n-bezier),
37
+ transform .3s var(--n-bezier),
38
+ margin-bottom .3s var(--n-bezier);
39
+ padding: var(--n-padding);
40
+ border-radius: var(--n-border-radius);
41
+ border: var(--n-border);
42
+ flex-wrap: nowrap;
43
+ overflow: hidden;
44
+ max-width: var(--n-max-width);
45
+ color: var(--n-text-color);
46
+ background-color: var(--n-color);
47
+ box-shadow: var(--n-box-shadow);
48
+ `,[R(`content`,`
49
+ display: inline-block;
50
+ line-height: var(--n-line-height);
51
+ font-size: var(--n-font-size);
52
+ `),R(`icon`,`
53
+ position: relative;
54
+ margin: var(--n-icon-margin);
55
+ height: var(--n-icon-size);
56
+ width: var(--n-icon-size);
57
+ font-size: var(--n-icon-size);
58
+ flex-shrink: 0;
59
+ `,[[`default`,`info`,`success`,`warning`,`error`,`loading`].map(e=>B(`${e}-type`,[I(`> *`,`
60
+ color: var(--n-icon-color-${e});
61
+ transition: color .3s var(--n-bezier);
62
+ `)])),I(`> *`,`
63
+ position: absolute;
64
+ left: 0;
65
+ top: 0;
66
+ right: 0;
67
+ bottom: 0;
68
+ `,[re()])]),R(`close`,`
69
+ margin: var(--n-close-margin);
70
+ transition:
71
+ background-color .3s var(--n-bezier),
72
+ color .3s var(--n-bezier);
73
+ flex-shrink: 0;
74
+ `,[I(`&:hover`,`
75
+ color: var(--n-close-icon-color-hover);
76
+ `),I(`&:active`,`
77
+ color: var(--n-close-icon-color-pressed);
78
+ `)])]),H(`message-container`,`
79
+ z-index: 6000;
80
+ position: fixed;
81
+ height: 0;
82
+ overflow: visible;
83
+ display: flex;
84
+ flex-direction: column;
85
+ align-items: center;
86
+ `,[B(`top`,`
87
+ top: 12px;
88
+ left: 0;
89
+ right: 0;
90
+ `),B(`top-left`,`
91
+ top: 12px;
92
+ left: 12px;
93
+ right: 0;
94
+ align-items: flex-start;
95
+ `),B(`top-right`,`
96
+ top: 12px;
97
+ left: 0;
98
+ right: 12px;
99
+ align-items: flex-end;
100
+ `),B(`bottom`,`
101
+ bottom: 4px;
102
+ left: 0;
103
+ right: 0;
104
+ justify-content: flex-end;
105
+ `),B(`bottom-left`,`
106
+ bottom: 4px;
107
+ left: 12px;
108
+ right: 0;
109
+ justify-content: flex-end;
110
+ align-items: flex-start;
111
+ `),B(`bottom-right`,`
112
+ bottom: 4px;
113
+ left: 0;
114
+ right: 12px;
115
+ justify-content: flex-end;
116
+ align-items: flex-end;
117
+ `)])]),$e={info:()=>s(ke,null),success:()=>s(K,null),warning:()=>s(ve,null),error:()=>s(ye,null),default:()=>null},et=S({name:`Message`,props:Object.assign(Object.assign({},Ze),{render:Function}),setup(e){let{inlineThemeDisabled:n,mergedRtlRef:r}=F(e),{props:a,mergedClsPrefixRef:o}=i(Ne),s=ie(`Message`,r,o),c=L(`Message`,`-message`,Qe,Xe,a,o),l=t(()=>{let{type:t}=e,{common:{cubicBezierEaseInOut:n},self:{padding:r,margin:i,maxWidth:a,iconMargin:o,closeMargin:s,closeSize:l,iconSize:u,fontSize:d,lineHeight:f,borderRadius:p,border:m,iconColorInfo:h,iconColorSuccess:g,iconColorWarning:_,iconColorError:v,iconColorLoading:y,closeIconSize:b,closeBorderRadius:x,[z(`textColor`,t)]:S,[z(`boxShadow`,t)]:C,[z(`color`,t)]:w,[z(`closeColorHover`,t)]:T,[z(`closeColorPressed`,t)]:E,[z(`closeIconColor`,t)]:D,[z(`closeIconColorPressed`,t)]:O,[z(`closeIconColorHover`,t)]:k}}=c.value;return{"--n-bezier":n,"--n-margin":i,"--n-padding":r,"--n-max-width":a,"--n-font-size":d,"--n-icon-margin":o,"--n-icon-size":u,"--n-close-icon-size":b,"--n-close-border-radius":x,"--n-close-size":l,"--n-close-margin":s,"--n-text-color":S,"--n-color":w,"--n-box-shadow":C,"--n-icon-color-info":h,"--n-icon-color-success":g,"--n-icon-color-warning":_,"--n-icon-color-error":v,"--n-icon-color-loading":y,"--n-close-color-hover":T,"--n-close-color-pressed":E,"--n-close-icon-color":D,"--n-close-icon-color-pressed":O,"--n-close-icon-color-hover":k,"--n-line-height":f,"--n-border-radius":p,"--n-border":m}}),u=n?U(`message`,t(()=>e.type[0]),l,{}):void 0;return{mergedClsPrefix:o,rtlEnabled:s,messageProviderProps:a,handleClose(){var t;(t=e.onClose)==null||t.call(e)},cssVars:n?void 0:l,themeClass:u?.themeClass,onRender:u?.onRender,placement:a.placement}},render(){let{render:e,type:t,closable:n,content:r,mergedClsPrefix:i,cssVars:a,themeClass:o,onRender:c,icon:l,handleClose:u,showIcon:d}=this;c?.();let f;return s(`div`,{class:[`${i}-message-wrapper`,o],onMouseenter:this.onMouseenter,onMouseleave:this.onMouseleave,style:[{alignItems:this.placement.startsWith(`top`)?`flex-start`:`flex-end`},a]},e?e(this.$props):s(`div`,{class:[`${i}-message ${i}-message--${t}-type`,this.rtlEnabled&&`${i}-message--rtl`]},(f=tt(l,t,i,this.spinProps))&&d?s(`div`,{class:`${i}-message__icon ${i}-message__icon--${t}-type`},s(ce,null,{default:()=>f})):null,s(`div`,{class:`${i}-message__content`},G(r)),n?s(Ae,{clsPrefix:i,class:`${i}-message__close`,onClick:u,absolute:!0}):null))}});function tt(e,t,n,r){if(typeof e==`function`)return e();{let e=t===`loading`?s(le,Object.assign({clsPrefix:n,strokeWidth:24,scale:.85},r)):$e[t]();return e?s(me,{clsPrefix:n,key:t},{default:()=>e}):null}}var nt=S({name:`MessageEnvironment`,props:Object.assign(Object.assign({},Ze),{duration:{type:Number,default:3e3},onAfterLeave:Function,onLeave:Function,internalKey:{type:String,required:!0},onInternalAfterLeave:Function,onHide:Function,onAfterHide:Function}),setup(e){let t=null,n=v(!0);f(()=>{r()});function r(){let{duration:n}=e;n&&(t=window.setTimeout(o,n))}function i(e){e.currentTarget===e.target&&t!==null&&(window.clearTimeout(t),t=null)}function a(e){e.currentTarget===e.target&&r()}function o(){let{onHide:r}=e;n.value=!1,t&&=(window.clearTimeout(t),null),r&&r()}function s(){let{onClose:t}=e;t&&t(),o()}function c(){let{onAfterLeave:t,onInternalAfterLeave:n,onAfterHide:r,internalKey:i}=e;t&&t(),n&&n(i),r&&r()}function l(){o()}return{show:n,hide:o,handleClose:s,handleAfterLeave:c,handleMouseleave:a,handleMouseenter:i,deactivate:l}},render(){return s(Me,{appear:!0,onAfterLeave:this.handleAfterLeave,onLeave:this.onLeave},{default:()=>[this.show?s(et,{content:this.content,type:this.type,icon:this.icon,showIcon:this.showIcon,closable:this.closable,spinProps:this.spinProps,onClose:this.handleClose,onMouseenter:this.keepAliveOnHover?this.handleMouseenter:void 0,onMouseleave:this.keepAliveOnHover?this.handleMouseleave:void 0}):null]})}}),rt=S({name:`MessageProvider`,props:Object.assign(Object.assign({},L.props),{to:[String,Object],duration:{type:Number,default:3e3},keepAliveOnHover:Boolean,max:Number,placement:{type:String,default:`top`},closable:Boolean,containerClass:String,containerStyle:[String,Object]}),setup(e){let{mergedClsPrefixRef:t}=F(e),n=v([]),r=v({}),i={create(e,t){return a(e,Object.assign({type:`default`},t))},info(e,t){return a(e,Object.assign(Object.assign({},t),{type:`info`}))},success(e,t){return a(e,Object.assign(Object.assign({},t),{type:`success`}))},warning(e,t){return a(e,Object.assign(Object.assign({},t),{type:`warning`}))},error(e,t){return a(e,Object.assign(Object.assign({},t),{type:`error`}))},loading(e,t){return a(e,Object.assign(Object.assign({},t),{type:`loading`}))},destroyAll:c};o(Ne,{props:e,mergedClsPrefixRef:t}),o(Pe,i);function a(t,i){let a=W(),o=T(Object.assign(Object.assign({},i),{content:t,key:a,destroy:()=>{var e;(e=r.value[a])==null||e.hide()}})),{max:s}=e;return s&&n.value.length>=s&&n.value.shift(),n.value.push(o),o}function s(e){n.value.splice(n.value.findIndex(t=>t.key===e),1),delete r.value[e]}function c(){Object.values(r.value).forEach(e=>{e.hide()})}return Object.assign({mergedClsPrefix:t,messageRefs:r,messageList:n,handleAfterLeave:s},i)},render(){var e;return s(A,null,(e=this.$slots).default?.call(e),this.messageList.length?s(g,{to:this.to??`body`},s(`div`,{class:[`${this.mergedClsPrefix}-message-container`,`${this.mergedClsPrefix}-message-container--${this.placement}`,this.containerClass],key:`message-container`,style:this.containerStyle},this.messageList.map(e=>s(nt,Object.assign({ref:t=>{t&&(this.messageRefs[e.key]=t)},internalKey:e.key,onInternalAfterLeave:this.handleAfterLeave},q(e,[`destroy`],void 0),{duration:e.duration===void 0?this.duration:e.duration,keepAliveOnHover:e.keepAliveOnHover===void 0?this.keepAliveOnHover:e.keepAliveOnHover,closable:e.closable===void 0?this.closable:e.closable}))))):null)}}),it={closeMargin:`16px 12px`,closeSize:`20px`,closeIconSize:`16px`,width:`365px`,padding:`16px`,titleFontSize:`16px`,metaFontSize:`12px`,descriptionFontSize:`12px`};function at(e){let{textColor2:t,successColor:n,infoColor:r,warningColor:i,errorColor:a,popoverColor:o,closeIconColor:s,closeIconColorHover:c,closeIconColorPressed:l,closeColorHover:u,closeColorPressed:d,textColor1:f,textColor3:p,borderRadius:m,fontWeightStrong:h,boxShadow2:g,lineHeight:_,fontSize:v}=e;return Object.assign(Object.assign({},it),{borderRadius:m,lineHeight:_,fontSize:v,headerFontWeight:h,iconColor:t,iconColorSuccess:n,iconColorInfo:r,iconColorWarning:i,iconColorError:a,color:o,textColor:t,closeIconColor:s,closeIconColorHover:c,closeIconColorPressed:l,closeBorderRadius:m,closeColorHover:u,closeColorPressed:d,headerTextColor:f,descriptionTextColor:p,actionTextColor:t,boxShadow:g})}var ot=ue({name:`Notification`,common:V,peers:{Scrollbar:he},self:at}),X=ee(`n-notification-provider`),st=S({name:`NotificationContainer`,props:{scrollable:{type:Boolean,required:!0},placement:{type:String,required:!0}},setup(){let{mergedThemeRef:e,mergedClsPrefixRef:t,wipTransitionCountRef:n}=i(X),r=v(null);return h(()=>{var e,t;n.value>0?(e=r?.value)==null||e.classList.add(`transitioning`):(t=r?.value)==null||t.classList.remove(`transitioning`)}),{selfRef:r,mergedTheme:e,mergedClsPrefix:t,transitioning:n}},render(){let{$slots:e,scrollable:t,mergedClsPrefix:n,mergedTheme:r,placement:i}=this;return s(`div`,{ref:`selfRef`,class:[`${n}-notification-container`,t&&`${n}-notification-container--scrollable`,`${n}-notification-container--${i}`]},t?s(ge,{theme:r.peers.Scrollbar,themeOverrides:r.peerOverrides.Scrollbar,contentStyle:{overflow:`hidden`}},e):e)}}),ct={info:()=>s(ke,null),success:()=>s(K,null),warning:()=>s(ve,null),error:()=>s(ye,null),default:()=>null},Z={closable:{type:Boolean,default:!0},type:{type:String,default:`default`},avatar:Function,title:[String,Function],description:[String,Function],content:[String,Function],meta:[String,Function],action:[String,Function],onClose:{type:Function,required:!0},keepAliveOnHover:Boolean,onMouseenter:Function,onMouseleave:Function},lt=be(Z),ut=S({name:`Notification`,props:Z,setup(e){let{mergedClsPrefixRef:n,mergedThemeRef:r,props:a}=i(X),{inlineThemeDisabled:o,mergedRtlRef:s}=F(),c=ie(`Notification`,s,n),l=t(()=>{let{type:t}=e,{self:{color:n,textColor:i,closeIconColor:a,closeIconColorHover:o,closeIconColorPressed:s,headerTextColor:c,descriptionTextColor:l,actionTextColor:u,borderRadius:d,headerFontWeight:f,boxShadow:p,lineHeight:m,fontSize:h,closeMargin:g,closeSize:_,width:v,padding:y,closeIconSize:b,closeBorderRadius:x,closeColorHover:S,closeColorPressed:C,titleFontSize:w,metaFontSize:T,descriptionFontSize:E,[z(`iconColor`,t)]:D},common:{cubicBezierEaseOut:O,cubicBezierEaseIn:k,cubicBezierEaseInOut:A}}=r.value,{left:j,right:M,top:N,bottom:P}=pe(y);return{"--n-color":n,"--n-font-size":h,"--n-text-color":i,"--n-description-text-color":l,"--n-action-text-color":u,"--n-title-text-color":c,"--n-title-font-weight":f,"--n-bezier":A,"--n-bezier-ease-out":O,"--n-bezier-ease-in":k,"--n-border-radius":d,"--n-box-shadow":p,"--n-close-border-radius":x,"--n-close-color-hover":S,"--n-close-color-pressed":C,"--n-close-icon-color":a,"--n-close-icon-color-hover":o,"--n-close-icon-color-pressed":s,"--n-line-height":m,"--n-icon-color":D,"--n-close-margin":g,"--n-close-size":_,"--n-close-icon-size":b,"--n-width":v,"--n-padding-left":j,"--n-padding-right":M,"--n-padding-top":N,"--n-padding-bottom":P,"--n-title-font-size":w,"--n-meta-font-size":T,"--n-description-font-size":E}}),u=o?U(`notification`,t(()=>e.type[0]),l,a):void 0;return{mergedClsPrefix:n,showAvatar:t(()=>e.avatar||e.type!==`default`),handleCloseClick(){e.onClose()},rtlEnabled:c,cssVars:o?void 0:l,themeClass:u?.themeClass,onRender:u?.onRender}},render(){var e;let{mergedClsPrefix:t}=this;return(e=this.onRender)==null||e.call(this),s(`div`,{class:[`${t}-notification-wrapper`,this.themeClass],onMouseenter:this.onMouseenter,onMouseleave:this.onMouseleave,style:this.cssVars},s(`div`,{class:[`${t}-notification`,this.rtlEnabled&&`${t}-notification--rtl`,this.themeClass,{[`${t}-notification--closable`]:this.closable,[`${t}-notification--show-avatar`]:this.showAvatar}],style:this.cssVars},this.showAvatar?s(`div`,{class:`${t}-notification__avatar`},this.avatar?G(this.avatar):this.type===`default`?null:s(me,{clsPrefix:t},{default:()=>ct[this.type]()})):null,this.closable?s(Ae,{clsPrefix:t,class:`${t}-notification__close`,onClick:this.handleCloseClick}):null,s(`div`,{ref:`bodyRef`,class:`${t}-notification-main`},this.title?s(`div`,{class:`${t}-notification-main__header`},G(this.title)):null,this.description?s(`div`,{class:`${t}-notification-main__description`},G(this.description)):null,this.content?s(`pre`,{class:`${t}-notification-main__content`},G(this.content)):null,this.meta||this.action?s(`div`,{class:`${t}-notification-main-footer`},this.meta?s(`div`,{class:`${t}-notification-main-footer__meta`},G(this.meta)):null,this.action?s(`div`,{class:`${t}-notification-main-footer__action`},G(this.action)):null):null)))}}),dt=Object.assign(Object.assign({},Z),{duration:Number,onClose:Function,onLeave:Function,onAfterEnter:Function,onAfterLeave:Function,onHide:Function,onAfterShow:Function,onAfterHide:Function}),ft=S({name:`NotificationEnvironment`,props:Object.assign(Object.assign({},dt),{internalKey:{type:String,required:!0},onInternalAfterLeave:{type:Function,required:!0}}),setup(e){let{wipTransitionCountRef:t}=i(X),n=v(!0),r=null;function a(){n.value=!1,r&&window.clearTimeout(r)}function o(e){t.value++,u(()=>{e.style.height=`${e.offsetHeight}px`,e.style.maxHeight=`0`,e.style.transition=`none`,e.offsetHeight,e.style.transition=``,e.style.maxHeight=e.style.height})}function s(n){t.value--,n.style.height=``,n.style.maxHeight=``;let{onAfterEnter:r,onAfterShow:i}=e;r&&r(),i&&i()}function c(e){t.value++,e.style.maxHeight=`${e.offsetHeight}px`,e.style.height=`${e.offsetHeight}px`,e.offsetHeight}function l(t){let{onHide:n}=e;n&&n(),t.style.maxHeight=`0`,t.offsetHeight}function d(){t.value--;let{onAfterLeave:n,onInternalAfterLeave:r,onAfterHide:i,internalKey:a}=e;n&&n(),r(a),i&&i()}function p(){let{duration:t}=e;t&&(r=window.setTimeout(a,t))}function m(e){e.currentTarget===e.target&&r!==null&&(window.clearTimeout(r),r=null)}function h(e){e.currentTarget===e.target&&p()}function g(){let{onClose:t}=e;t?Promise.resolve(t()).then(e=>{e!==!1&&a()}):a()}return f(()=>{e.duration&&(r=window.setTimeout(a,e.duration))}),{show:n,hide:a,handleClose:g,handleAfterLeave:d,handleLeave:l,handleBeforeLeave:c,handleAfterEnter:s,handleBeforeEnter:o,handleMouseenter:m,handleMouseleave:h}},render(){return s(y,{name:`notification-transition`,appear:!0,onBeforeEnter:this.handleBeforeEnter,onAfterEnter:this.handleAfterEnter,onBeforeLeave:this.handleBeforeLeave,onLeave:this.handleLeave,onAfterLeave:this.handleAfterLeave},{default:()=>this.show?s(ut,Object.assign({},fe(this.$props,lt),{onClose:this.handleClose,onMouseenter:this.duration&&this.keepAliveOnHover?this.handleMouseenter:void 0,onMouseleave:this.duration&&this.keepAliveOnHover?this.handleMouseleave:void 0})):null})}}),pt=I([H(`notification-container`,`
118
+ z-index: 4000;
119
+ position: fixed;
120
+ overflow: visible;
121
+ display: flex;
122
+ flex-direction: column;
123
+ align-items: flex-end;
124
+ `,[I(`>`,[H(`scrollbar`,`
125
+ width: initial;
126
+ overflow: visible;
127
+ height: -moz-fit-content !important;
128
+ height: fit-content !important;
129
+ max-height: 100vh !important;
130
+ `,[I(`>`,[H(`scrollbar-container`,`
131
+ height: -moz-fit-content !important;
132
+ height: fit-content !important;
133
+ max-height: 100vh !important;
134
+ `,[H(`scrollbar-content`,`
135
+ padding-top: 12px;
136
+ padding-bottom: 33px;
137
+ `)])])])]),B(`top, top-right, top-left`,`
138
+ top: 12px;
139
+ `,[I(`&.transitioning >`,[H(`scrollbar`,[I(`>`,[H(`scrollbar-container`,`
140
+ min-height: 100vh !important;
141
+ `)])])])]),B(`bottom, bottom-right, bottom-left`,`
142
+ bottom: 12px;
143
+ `,[I(`>`,[H(`scrollbar`,[I(`>`,[H(`scrollbar-container`,[H(`scrollbar-content`,`
144
+ padding-bottom: 12px;
145
+ `)])])])]),H(`notification-wrapper`,`
146
+ display: flex;
147
+ align-items: flex-end;
148
+ margin-bottom: 0;
149
+ margin-top: 12px;
150
+ `)]),B(`top, bottom`,`
151
+ left: 50%;
152
+ transform: translateX(-50%);
153
+ `,[H(`notification-wrapper`,[I(`&.notification-transition-enter-from, &.notification-transition-leave-to`,`
154
+ transform: scale(0.85);
155
+ `),I(`&.notification-transition-leave-from, &.notification-transition-enter-to`,`
156
+ transform: scale(1);
157
+ `)])]),B(`top`,[H(`notification-wrapper`,`
158
+ transform-origin: top center;
159
+ `)]),B(`bottom`,[H(`notification-wrapper`,`
160
+ transform-origin: bottom center;
161
+ `)]),B(`top-right, bottom-right`,[H(`notification`,`
162
+ margin-left: 28px;
163
+ margin-right: 16px;
164
+ `)]),B(`top-left, bottom-left`,[H(`notification`,`
165
+ margin-left: 16px;
166
+ margin-right: 28px;
167
+ `)]),B(`top-right`,`
168
+ right: 0;
169
+ `,[Q(`top-right`)]),B(`top-left`,`
170
+ left: 0;
171
+ `,[Q(`top-left`)]),B(`bottom-right`,`
172
+ right: 0;
173
+ `,[Q(`bottom-right`)]),B(`bottom-left`,`
174
+ left: 0;
175
+ `,[Q(`bottom-left`)]),B(`scrollable`,[B(`top-right`,`
176
+ top: 0;
177
+ `),B(`top-left`,`
178
+ top: 0;
179
+ `),B(`bottom-right`,`
180
+ bottom: 0;
181
+ `),B(`bottom-left`,`
182
+ bottom: 0;
183
+ `)]),H(`notification-wrapper`,`
184
+ margin-bottom: 12px;
185
+ `,[I(`&.notification-transition-enter-from, &.notification-transition-leave-to`,`
186
+ opacity: 0;
187
+ margin-top: 0 !important;
188
+ margin-bottom: 0 !important;
189
+ `),I(`&.notification-transition-leave-from, &.notification-transition-enter-to`,`
190
+ opacity: 1;
191
+ `),I(`&.notification-transition-leave-active`,`
192
+ transition:
193
+ background-color .3s var(--n-bezier),
194
+ color .3s var(--n-bezier),
195
+ opacity .3s var(--n-bezier),
196
+ transform .3s var(--n-bezier-ease-in),
197
+ max-height .3s var(--n-bezier),
198
+ margin-top .3s linear,
199
+ margin-bottom .3s linear,
200
+ box-shadow .3s var(--n-bezier);
201
+ `),I(`&.notification-transition-enter-active`,`
202
+ transition:
203
+ background-color .3s var(--n-bezier),
204
+ color .3s var(--n-bezier),
205
+ opacity .3s var(--n-bezier),
206
+ transform .3s var(--n-bezier-ease-out),
207
+ max-height .3s var(--n-bezier),
208
+ margin-top .3s linear,
209
+ margin-bottom .3s linear,
210
+ box-shadow .3s var(--n-bezier);
211
+ `)]),H(`notification`,`
212
+ background-color: var(--n-color);
213
+ color: var(--n-text-color);
214
+ transition:
215
+ background-color .3s var(--n-bezier),
216
+ color .3s var(--n-bezier),
217
+ opacity .3s var(--n-bezier),
218
+ box-shadow .3s var(--n-bezier);
219
+ font-family: inherit;
220
+ font-size: var(--n-font-size);
221
+ font-weight: 400;
222
+ position: relative;
223
+ display: flex;
224
+ overflow: hidden;
225
+ flex-shrink: 0;
226
+ padding-left: var(--n-padding-left);
227
+ padding-right: var(--n-padding-right);
228
+ width: var(--n-width);
229
+ max-width: calc(100vw - 16px - 16px);
230
+ border-radius: var(--n-border-radius);
231
+ box-shadow: var(--n-box-shadow);
232
+ box-sizing: border-box;
233
+ opacity: 1;
234
+ `,[R(`avatar`,[H(`icon`,`
235
+ color: var(--n-icon-color);
236
+ `),H(`base-icon`,`
237
+ color: var(--n-icon-color);
238
+ `)]),B(`show-avatar`,[H(`notification-main`,`
239
+ margin-left: 40px;
240
+ width: calc(100% - 40px);
241
+ `)]),B(`closable`,[H(`notification-main`,[I(`> *:first-child`,`
242
+ padding-right: 20px;
243
+ `)]),R(`close`,`
244
+ position: absolute;
245
+ top: 0;
246
+ right: 0;
247
+ margin: var(--n-close-margin);
248
+ transition:
249
+ background-color .3s var(--n-bezier),
250
+ color .3s var(--n-bezier);
251
+ `)]),R(`avatar`,`
252
+ position: absolute;
253
+ top: var(--n-padding-top);
254
+ left: var(--n-padding-left);
255
+ width: 28px;
256
+ height: 28px;
257
+ font-size: 28px;
258
+ display: flex;
259
+ align-items: center;
260
+ justify-content: center;
261
+ `,[H(`icon`,`transition: color .3s var(--n-bezier);`)]),H(`notification-main`,`
262
+ padding-top: var(--n-padding-top);
263
+ padding-bottom: var(--n-padding-bottom);
264
+ box-sizing: border-box;
265
+ display: flex;
266
+ flex-direction: column;
267
+ margin-left: 8px;
268
+ width: calc(100% - 8px);
269
+ `,[H(`notification-main-footer`,`
270
+ display: flex;
271
+ align-items: center;
272
+ justify-content: space-between;
273
+ margin-top: 12px;
274
+ `,[R(`meta`,`
275
+ font-size: var(--n-meta-font-size);
276
+ transition: color .3s var(--n-bezier-ease-out);
277
+ color: var(--n-description-text-color);
278
+ `),R(`action`,`
279
+ cursor: pointer;
280
+ transition: color .3s var(--n-bezier-ease-out);
281
+ color: var(--n-action-text-color);
282
+ `)]),R(`header`,`
283
+ font-weight: var(--n-title-font-weight);
284
+ font-size: var(--n-title-font-size);
285
+ transition: color .3s var(--n-bezier-ease-out);
286
+ color: var(--n-title-text-color);
287
+ `),R(`description`,`
288
+ margin-top: 8px;
289
+ font-size: var(--n-description-font-size);
290
+ white-space: pre-wrap;
291
+ word-wrap: break-word;
292
+ transition: color .3s var(--n-bezier-ease-out);
293
+ color: var(--n-description-text-color);
294
+ `),R(`content`,`
295
+ line-height: var(--n-line-height);
296
+ margin: 12px 0 0 0;
297
+ font-family: inherit;
298
+ white-space: pre-wrap;
299
+ word-wrap: break-word;
300
+ transition: color .3s var(--n-bezier-ease-out);
301
+ color: var(--n-text-color);
302
+ `,[I(`&:first-child`,`margin: 0;`)])])])])]);function Q(e){return H(`notification-wrapper`,[I(`&.notification-transition-enter-from, &.notification-transition-leave-to`,`
303
+ transform: translate(${e.split(`-`)[1]===`left`?`calc(-100%)`:`calc(100%)`}, 0);
304
+ `),I(`&.notification-transition-leave-from, &.notification-transition-enter-to`,`
305
+ transform: translate(0, 0);
306
+ `)])}var mt=ee(`n-notification-api`),ht=S({name:`NotificationProvider`,props:Object.assign(Object.assign({},L.props),{containerClass:String,containerStyle:[String,Object],to:[String,Object],scrollable:{type:Boolean,default:!0},max:Number,placement:{type:String,default:`top-right`},keepAliveOnHover:Boolean}),setup(e){let{mergedClsPrefixRef:t}=F(e),n=v([]),r={},i=new Set;function a(t){let a=W(),o=()=>{i.add(a),r[a]&&r[a].hide()},s=T(Object.assign(Object.assign({},t),{key:a,destroy:o,hide:o,deactivate:o})),{max:c}=e;if(c&&n.value.length-i.size>=c){let e=!1,t=0;for(let a of n.value){if(!i.has(a.key)){r[a.key]&&(a.destroy(),e=!0);break}t++}e||n.value.splice(t,1)}return n.value.push(s),s}let s=[`info`,`success`,`warning`,`error`].map(e=>t=>a(Object.assign(Object.assign({},t),{type:e})));function c(e){i.delete(e),n.value.splice(n.value.findIndex(t=>t.key===e),1)}let l=L(`Notification`,`-notification`,pt,ot,e,t),u={create:a,info:s[0],success:s[1],warning:s[2],error:s[3],open:f,destroyAll:p},d=v(0);o(mt,u),o(X,{props:e,mergedClsPrefixRef:t,mergedThemeRef:l,wipTransitionCountRef:d});function f(e){return a(e)}function p(){Object.values(n.value).forEach(e=>{e.hide()})}return Object.assign({mergedClsPrefix:t,notificationList:n,notificationRefs:r,handleAfterLeave:c},u)},render(){var e;let{placement:t}=this;return s(A,null,(e=this.$slots).default?.call(e),this.notificationList.length?s(g,{to:this.to??`body`},s(st,{class:this.containerClass,style:this.containerStyle,scrollable:this.scrollable&&t!==`top`&&t!==`bottom`,placement:t},{default:()=>this.notificationList.map(e=>s(ft,Object.assign({ref:t=>{let n=e.key;t===null?delete this.notificationRefs[n]:this.notificationRefs[n]=t}},q(e,[`destroy`,`hide`,`deactivate`]),{internalKey:e.key,onInternalAfterLeave:this.handleAfterLeave,keepAliveOnHover:e.keepAliveOnHover===void 0?this.keepAliveOnHover:e.keepAliveOnHover})))})):null)}}),gt={common:{primaryColor:`#333333`,primaryColorHover:`#1a1a1a`,primaryColorPressed:`#000000`,primaryColorSuppl:`#333333`,bodyColor:`#fafafa`,cardColor:`#ffffff`,modalColor:`#ffffff`,popoverColor:`#ffffff`,tableColor:`#ffffff`,inputColor:`#ffffff`,actionColor:`#f0f0f0`,textColorBase:`#1a1a1a`,textColor1:`#1a1a1a`,textColor2:`#666666`,textColor3:`#999999`,dividerColor:`#e0e0e0`,borderColor:`#e0e0e0`,hoverColor:`rgba(0, 0, 0, 0.04)`,borderRadius:`8px`,borderRadiusSmall:`6px`,fontSize:`14px`,fontSizeMedium:`14px`,heightMedium:`36px`,fontFamily:`Inter, system-ui, -apple-system, sans-serif`,fontFamilyMono:`JetBrains Mono, Fira Code, Consolas, monospace`},Layout:{color:`#fafafa`,siderColor:`#f5f5f5`,headerColor:`#fafafa`},Menu:{itemTextColorActive:`#1a1a1a`,itemTextColorActiveHover:`#1a1a1a`,itemTextColorChildActive:`#1a1a1a`,itemIconColorActive:`#1a1a1a`,itemIconColorActiveHover:`#000000`,itemColorActive:`rgba(0, 0, 0, 0.06)`,itemColorActiveHover:`rgba(0, 0, 0, 0.1)`,arrowColorActive:`#1a1a1a`},Button:{textColorPrimary:`#ffffff`,colorPrimary:`#333333`,colorHoverPrimary:`#1a1a1a`,colorPressedPrimary:`#000000`},Input:{color:`#ffffff`,colorFocus:`#ffffff`,border:`1px solid #e0e0e0`,borderHover:`1px solid #999999`,borderFocus:`1px solid #333333`,placeholderColor:`#999999`,caretColor:`#1a1a1a`},Card:{color:`#ffffff`,borderColor:`#e0e0e0`},Modal:{color:`#ffffff`},Tag:{borderRadius:`6px`}},_t={class:`model-selector`},vt=P(S({__name:`ModelSelector`,setup(r){let i=J(),o=t(()=>i.modelGroups.map(e=>({label:e.label,type:`group`,key:e.provider,children:e.models.map(e=>({label:e,value:e}))})));function s(e){typeof e==`string`&&i.switchModel(e)}return(t,r)=>(a(),n(`div`,_t,[r[0]||=k(`div`,{class:`model-label`},`Model`,-1),e(D(je),{value:D(i).selectedModel,options:o.value,size:`small`,"onUpdate:value":s},null,8,[`value`,`options`])]))}}),[[`__scopeId`,`data-v-00830782`]]),yt=S({__name:`LanguageSwitch`,setup(e){let{locale:n,availableLocales:r}=N(),i=t(()=>r.map(e=>({label:e===`zh`?`中文`:`English`,value:e})));function o(e){n.value=e,localStorage.setItem(`hermes_locale`,e)}return(e,t)=>(a(),d(D(je),{value:D(n),options:i.value,size:`tiny`,"consistent-menu-width":!1,style:{width:`90px`},"onUpdate:value":o},null,8,[`value`,`options`]))}}),bt=`/assets/dance-gGRu7JHG.mp4`,xt={class:`sidebar`},St={class:`sidebar-nav`},Ct={class:`sidebar-footer`},wt={class:`status-row`},Tt={class:`status-text`},Et={class:`version-info`},Dt=P(S({__name:`AppSidebar`,setup(r){let{t:i}=N(),o=_(),s=C(),l=J(),u=v(),d=t(()=>o.name);f(()=>{let e=u.value;if(!e)return;let t=e.getContext(`2d`);if(!t)return;let n=document.createElement(`video`);n.src=bt,n.muted=!0,n.playsInline=!0,n.autoplay=!0,n.addEventListener(`loadeddata`,()=>{e.width=n.videoWidth,e.height=n.videoHeight});function r(){n.readyState>=2&&t&&e&&t.drawImage(n,0,0,e.width,e.height),n.currentTime>=n.duration-.05&&(n.currentTime=0),requestAnimationFrame(r)}n.addEventListener(`canplay`,()=>{r()}),n.play();let i=()=>{document.visibilityState===`visible`&&n.paused&&n.play()};document.addEventListener(`visibilitychange`,i),p(()=>{document.removeEventListener(`visibilitychange`,i)})});function m(e){s.push({name:e})}return(t,r)=>(a(),n(`aside`,xt,[k(`div`,{class:`sidebar-logo`,onClick:r[0]||=e=>D(s).push(`/chat`)},[r[10]||=k(`img`,{src:`/logo.png`,alt:`Hermes`,class:`logo-img`},null,-1),r[11]||=k(`span`,{class:`logo-text`},`Hermes`,-1),k(`canvas`,{ref_key:`canvasRef`,ref:u,class:`logo-dance`},null,512)]),k(`nav`,St,[k(`button`,{class:w([`nav-item`,{active:d.value===`chat`}]),onClick:r[1]||=e=>m(`chat`)},[r[12]||=k(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`1.5`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[k(`path`,{d:`M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z`})],-1),k(`span`,null,b(D(i)(`sidebar.chat`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`jobs`}]),onClick:r[2]||=e=>m(`jobs`)},[r[13]||=c(`<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" data-v-afd7c4c4><rect x="3" y="4" width="18" height="18" rx="2" ry="2" data-v-afd7c4c4></rect><line x1="16" y1="2" x2="16" y2="6" data-v-afd7c4c4></line><line x1="8" y1="2" x2="8" y2="6" data-v-afd7c4c4></line><line x1="3" y1="10" x2="21" y2="10" data-v-afd7c4c4></line></svg>`,1),k(`span`,null,b(D(i)(`sidebar.jobs`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`models`}]),onClick:r[3]||=e=>m(`models`)},[r[14]||=c(`<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" data-v-afd7c4c4><circle cx="12" cy="12" r="3" data-v-afd7c4c4></circle><path d="M12 1v4" data-v-afd7c4c4></path><path d="M12 19v4" data-v-afd7c4c4></path><path d="M1 12h4" data-v-afd7c4c4></path><path d="M19 12h4" data-v-afd7c4c4></path><path d="M4.22 4.22l2.83 2.83" data-v-afd7c4c4></path><path d="M16.95 16.95l2.83 2.83" data-v-afd7c4c4></path><path d="M4.22 19.78l2.83-2.83" data-v-afd7c4c4></path><path d="M16.95 7.05l2.83-2.83" data-v-afd7c4c4></path></svg>`,1),k(`span`,null,b(D(i)(`sidebar.models`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`channels`}]),onClick:r[4]||=e=>m(`channels`)},[r[15]||=k(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`1.5`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[k(`path`,{d:`M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z`})],-1),k(`span`,null,b(D(i)(`sidebar.channels`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`skills`}]),onClick:r[5]||=e=>m(`skills`)},[r[16]||=k(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`1.5`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[k(`polygon`,{points:`12 2 2 7 12 12 22 7 12 2`}),k(`polyline`,{points:`2 17 12 22 22 17`}),k(`polyline`,{points:`2 12 12 17 22 12`})],-1),k(`span`,null,b(D(i)(`sidebar.skills`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`memory`}]),onClick:r[6]||=e=>m(`memory`)},[r[17]||=k(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`1.5`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[k(`path`,{d:`M9 18h6`}),k(`path`,{d:`M10 22h4`}),k(`path`,{d:`M12 2a7 7 0 0 0-4 12.7V17h8v-2.3A7 7 0 0 0 12 2z`})],-1),k(`span`,null,b(D(i)(`sidebar.memory`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`logs`}]),onClick:r[7]||=e=>m(`logs`)},[r[18]||=c(`<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" data-v-afd7c4c4><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z" data-v-afd7c4c4></path><polyline points="14 2 14 8 20 8" data-v-afd7c4c4></polyline><line x1="16" y1="13" x2="8" y2="13" data-v-afd7c4c4></line><line x1="16" y1="17" x2="8" y2="17" data-v-afd7c4c4></line><polyline points="10 9 9 9 8 9" data-v-afd7c4c4></polyline></svg>`,1),k(`span`,null,b(D(i)(`sidebar.logs`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`usage`}]),onClick:r[8]||=e=>m(`usage`)},[r[19]||=k(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`1.5`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[k(`rect`,{x:`3`,y:`12`,width:`4`,height:`9`,rx:`1`}),k(`rect`,{x:`10`,y:`7`,width:`4`,height:`14`,rx:`1`}),k(`rect`,{x:`17`,y:`3`,width:`4`,height:`18`,rx:`1`})],-1),k(`span`,null,b(D(i)(`sidebar.usage`)),1)],2),k(`button`,{class:w([`nav-item`,{active:d.value===`settings`}]),onClick:r[9]||=e=>m(`settings`)},[r[20]||=k(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`1.5`,"stroke-linecap":`round`,"stroke-linejoin":`round`},[k(`circle`,{cx:`12`,cy:`12`,r:`3`}),k(`path`,{d:`M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-4 0v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83-2.83l.06-.06A1.65 1.65 0 0 0 4.68 15a1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1 0-4h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 2.83-2.83l.06.06A1.65 1.65 0 0 0 9 4.68a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 4 0v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 2.83l-.06.06A1.65 1.65 0 0 0 19.4 9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1z`})],-1),k(`span`,null,b(D(i)(`sidebar.settings`)),1)],2)]),e(vt),k(`div`,Ct,[k(`div`,wt,[k(`div`,{class:w([`status-indicator`,{connected:D(l).connected,disconnected:!D(l).connected}])},[r[21]||=k(`span`,{class:`status-dot`},null,-1),k(`span`,Tt,b(D(l).connected?D(i)(`sidebar.connected`):D(i)(`sidebar.disconnected`)),1)],2),e(yt)]),k(`div`,Et,` Hermes `+b(D(l).serverVersion||`v0.1.0`),1)])]))}}),[[`__scopeId`,`data-v-afd7c4c4`]]);function Ot(){let e=C(),t=Fe();function n(n){let r=n.ctrlKey||n.metaKey;if(r&&n.key===`n`&&(n.preventDefault(),t.newChat()),r&&n.key===`j`&&(n.preventDefault(),e.push({name:`jobs`})),n.key===`Escape`){let e=document.querySelector(`.n-modal-mask`);e&&e.querySelector(`.n-base-close`)?.click()}}f(()=>{window.addEventListener(`keydown`,n)}),p(()=>{window.removeEventListener(`keydown`,n)})}var kt={class:`app-main`},At=P(S({__name:`App`,setup(i){let o=J(),s=_(),c=C(),u=v(!1),h=t(()=>s.name===`login`);return c.isReady().then(()=>{u.value=!0}),f(()=>{h.value||(o.loadModels(),o.startHealthPolling())}),p(()=>{o.stopHealthPolling()}),Ot(),(t,i)=>{let o=m(`router-view`);return a(),d(D(We),{"theme-overrides":D(gt)},{default:l(()=>[e(D(rt),null,{default:l(()=>[e(D(qe),null,{default:l(()=>[e(D(ht),null,{default:l(()=>[u.value?(a(),n(`div`,{key:0,class:w([`app-layout`,{"no-sidebar":h.value}])},[h.value?r(``,!0):(a(),d(Dt,{key:0})),k(`main`,kt,[e(o)])],2)):r(``,!0)]),_:1})]),_:1})]),_:1})]),_:1},8,[`theme-overrides`])}}}),[[`__scopeId`,`data-v-ff8c112e`]]),jt=new URLSearchParams(window.location.search),Mt=window.location.hash.split(`?`)[1],Nt=jt.get(`token`)||(Mt?new URLSearchParams(Mt).get(`token`):null);Nt&&(window.__LOGIN_TOKEN__=Nt);var $=E(At);$.use(j()),$.use(Be),$.use(O),$.mount(`#app`);
@@ -0,0 +1 @@
1
+ import{o as e,vt as t}from"./router-Ddepf70Q.js";var n=t({createJob:()=>o,deleteJob:()=>c,getJob:()=>a,listJobs:()=>i,pauseJob:()=>l,resumeJob:()=>u,runJob:()=>d,updateJob:()=>s});function r(e){return e.job}async function i(){return(await e(`/api/jobs?include_disabled=true`)).jobs}async function a(t){return r(await e(`/api/jobs/${t}`))}async function o(t){return r(await e(`/api/jobs`,{method:`POST`,body:JSON.stringify(t)}))}async function s(t,n){return r(await e(`/api/jobs/${t}`,{method:`PATCH`,body:JSON.stringify(n)}))}async function c(t){return e(`/api/jobs/${t}`,{method:`DELETE`})}async function l(t){return r(await e(`/api/jobs/${t}/pause`,{method:`POST`}))}async function u(t){return r(await e(`/api/jobs/${t}/resume`,{method:`POST`}))}async function d(t){return r(await e(`/api/jobs/${t}/run`,{method:`POST`}))}export{l as a,s as c,i,c as n,u as o,n as r,d as s,o as t};
@@ -0,0 +1 @@
1
+ var e=`/logo.png`;export{e as t};
@@ -0,0 +1 @@
1
+ import{C as e,F as t,P as n,R as r,X as i,at as a,ct as o,et as s,ft as c,it as l,nt as u,ot as d,rt as f,tt as p,ut as m}from"./router-Ddepf70Q.js";var h=typeof window<`u`,g,_=e=>g=e,v=Symbol();function y(e){return e&&typeof e==`object`&&Object.prototype.toString.call(e)===`[object Object]`&&typeof e.toJSON!=`function`}var b;(function(e){e.direct=`direct`,e.patchObject=`patch object`,e.patchFunction=`patch function`})(b||={});var x=typeof window==`object`&&window.window===window?window:typeof self==`object`&&self.self===self?self:typeof global==`object`&&global.global===global?global:typeof globalThis==`object`?globalThis:{HTMLElement:null};function S(e,{autoBom:t=!1}={}){return t&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob([``,e],{type:e.type}):e}function C(e,t,n){let r=new XMLHttpRequest;r.open(`GET`,e),r.responseType=`blob`,r.onload=function(){O(r.response,t,n)},r.onerror=function(){console.error(`could not download file`)},r.send()}function w(e){let t=new XMLHttpRequest;t.open(`HEAD`,e,!1);try{t.send()}catch{}return t.status>=200&&t.status<=299}function T(e){try{e.dispatchEvent(new MouseEvent(`click`))}catch{let t=new MouseEvent(`click`,{bubbles:!0,cancelable:!0,view:window,detail:0,screenX:80,screenY:20,clientX:80,clientY:20,ctrlKey:!1,altKey:!1,shiftKey:!1,metaKey:!1,button:0,relatedTarget:null});e.dispatchEvent(t)}}var E=typeof navigator==`object`?navigator:{userAgent:``},D=/Macintosh/.test(E.userAgent)&&/AppleWebKit/.test(E.userAgent)&&!/Safari/.test(E.userAgent),O=h?typeof HTMLAnchorElement<`u`&&`download`in HTMLAnchorElement.prototype&&!D?k:`msSaveOrOpenBlob`in E?A:j:()=>{};function k(e,t=`download`,n){let r=document.createElement(`a`);r.download=t,r.rel=`noopener`,typeof e==`string`?(r.href=e,r.origin===location.origin?T(r):w(r.href)?C(e,t,n):(r.target=`_blank`,T(r))):(r.href=URL.createObjectURL(e),setTimeout(function(){URL.revokeObjectURL(r.href)},4e4),setTimeout(function(){T(r)},0))}function A(e,t=`download`,n){if(typeof e==`string`)if(w(e))C(e,t,n);else{let t=document.createElement(`a`);t.href=e,t.target=`_blank`,setTimeout(function(){T(t)})}else navigator.msSaveOrOpenBlob(S(e,n),t)}function j(e,t,n,r){if(r||=open(``,`_blank`),r&&(r.document.title=r.document.body.innerText=`downloading...`),typeof e==`string`)return C(e,t,n);let i=e.type===`application/octet-stream`,a=/constructor/i.test(String(x.HTMLElement))||`safari`in x,o=/CriOS\/[\d]+/.test(navigator.userAgent);if((o||i&&a||D)&&typeof FileReader<`u`){let t=new FileReader;t.onloadend=function(){let e=t.result;if(typeof e!=`string`)throw r=null,Error(`Wrong reader.result type`);e=o?e:e.replace(/^data:[^;]*;/,`data:attachment/file;`),r?r.location.href=e:location.assign(e),r=null},t.readAsDataURL(e)}else{let t=URL.createObjectURL(e);r?r.location.assign(t):location.href=t,r=null,setTimeout(function(){URL.revokeObjectURL(t)},4e4)}}var{assign:M}=Object;function N(){let e=s(!0),t=e.run(()=>o({})),n=[],r=[],i=l({install(e){_(i),i._a=e,e.provide(v,i),e.config.globalProperties.$pinia=i,r.forEach(e=>n.push(e)),r=[]},use(e){return this._a?n.push(e):r.push(e),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return i}var P=()=>{};function F(e,t,n,r=P){e.add(t);let i=()=>{e.delete(t)&&r()};return!n&&p()&&a(i),i}function I(e,...t){e.forEach(e=>{e(...t)})}var L=e=>e(),R=Symbol(),z=Symbol();function B(e,t){e instanceof Map&&t instanceof Map?t.forEach((t,n)=>e.set(n,t)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(let n in t){if(!t.hasOwnProperty(n))continue;let r=t[n],i=e[n];y(i)&&y(r)&&e.hasOwnProperty(n)&&!f(r)&&!u(r)?e[n]=B(i,r):e[n]=r}return e}var V=Symbol();function H(e){return!y(e)||!Object.prototype.hasOwnProperty.call(e,V)}var{assign:U}=Object;function W(e){return!!(f(e)&&e.effect)}function G(t,n,r,i){let{state:a,actions:o,getters:s}=n,u=r.state.value[t],d;function f(){return u||(r.state.value[t]=a?a():{}),U(c(r.state.value[t]),o,Object.keys(s||{}).reduce((n,i)=>(n[i]=l(e(()=>{_(r);let e=r._s.get(t);return s[i].call(e,e)})),n),{}))}return d=K(t,f,n,r,i,!0),d}function K(e,t,n={},a,c,l){let p,h=U({actions:{}},n),g={deep:!0},v,y,x=new Set,S=new Set,C=a.state.value[e];!l&&!C&&(a.state.value[e]={}),o({});let w;function T(t){let n;v=y=!1,typeof t==`function`?(t(a.state.value[e]),n={type:b.patchFunction,storeId:e,events:void 0}):(B(a.state.value[e],t),n={type:b.patchObject,payload:t,storeId:e,events:void 0});let i=w=Symbol();r().then(()=>{w===i&&(v=!0)}),y=!0,I(x,n,a.state.value[e])}let E=l?function(){let{state:e}=n,t=e?e():{};this.$patch(e=>{U(e,t)})}:P;function D(){p.stop(),x.clear(),S.clear(),a._s.delete(e)}let O=(t,n=``)=>{if(R in t)return t[z]=n,t;let r=function(){_(a);let n=Array.from(arguments),i=new Set,o=new Set;function s(e){i.add(e)}function c(e){o.add(e)}I(S,{args:n,name:r[z],store:k,after:s,onError:c});let l;try{l=t.apply(this&&this.$id===e?this:k,n)}catch(e){throw I(o,e),e}return l instanceof Promise?l.then(e=>(I(i,e),e)).catch(e=>(I(o,e),Promise.reject(e))):(I(i,l),l)};return r[R]=!0,r[z]=n,r},k=d({_p:a,$id:e,$onAction:F.bind(null,S),$patch:T,$reset:E,$subscribe(t,n={}){let r=F(x,t,n.detached,()=>o()),o=p.run(()=>i(()=>a.state.value[e],r=>{(n.flush===`sync`?y:v)&&t({storeId:e,type:b.direct,events:void 0},r)},U({},g,n)));return r},$dispose:D});a._s.set(e,k);let A=(a._a&&a._a.runWithContext||L)(()=>a._e.run(()=>(p=s()).run(()=>t({action:O}))));for(let t in A){let n=A[t];f(n)&&!W(n)||u(n)?l||(C&&H(n)&&(f(n)?n.value=C[t]:B(n,C[t])),a.state.value[e][t]=n):typeof n==`function`&&(A[t]=O(n,t),h.actions[t]=n)}return U(k,A),U(m(k),A),Object.defineProperty(k,`$state`,{get:()=>a.state.value[e],set:e=>{T(t=>{U(t,e)})}}),a._p.forEach(e=>{U(k,p.run(()=>e({store:k,app:a._a,pinia:a,options:h})))}),C&&l&&n.hydrate&&n.hydrate(k.$state,C),v=!0,y=!0,k}function q(e,r,i){let a,o=typeof r==`function`;a=o?i:r;function s(i,s){let c=n();return i||=c?t(v,null):null,i&&_(i),i=g,i._s.has(e)||(o?K(e,r,a,i):G(e,a,i)),i._s.get(e)}return s.$id=e,s}export{q as n,N as t};