diff --git a/VERSION b/VERSION index cf6931b0..36a0393f 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.1.52 +1.1.53 diff --git a/web/admin-spa/dist/assets/AccountsView-DQqe0yLL.js b/web/admin-spa/dist/assets/AccountsView-DQqe0yLL.js new file mode 100644 index 00000000..ace631f7 --- /dev/null +++ b/web/admin-spa/dist/assets/AccountsView-DQqe0yLL.js @@ -0,0 +1,15 @@ +import{r as T,aR as Te,o as O,V as Ae,x as u,y as i,z as e,L as $,K as w,al as xe,aY as te,aX as we,aq as j,aZ as Ue,C as G,O as h,c as se,P as U,I as le,a5 as ke,R as ne,an as H,u as W,q as Ve,Y as Ie,Q as je,ac as Se,B as ve}from"./vue-vendor-CKToUHZx.js";import{s as V}from"./toast-BvwA7Mwb.js";import{a as K,_ as Me}from"./index-HsvoyPKA.js";import"./element-plus-B8Fs_0jW.js";import"./vendor-BDiMbLwQ.js";const oe=T(!1),ye=T({title:"",message:"",confirmText:"继续",cancelText:"取消"}),J=T(null);function he(){return{showConfirmModal:oe,confirmOptions:ye,showConfirm:(g,d,S="继续",I="取消")=>new Promise(C=>{ye.value={title:g,message:d,confirmText:S,cancelText:I},J.value=C,oe.value=!0}),handleConfirm:()=>{oe.value=!1,J.value&&(J.value(!0),J.value=null)},handleCancel:()=>{oe.value=!1,J.value&&(J.value(!1),J.value=null)}}}const $e=Te("accounts",()=>{const L=T([]),E=T([]),m=T([]),g=T(!1),d=T(null),S=T(""),I=T("asc"),C=async()=>{g.value=!0,d.value=null;try{const x=await K.get("/admin/claude-accounts");if(x.success)L.value=x.data||[];else throw new Error(x.message||"获取Claude账户失败")}catch(x){throw d.value=x.message,x}finally{g.value=!1}},A=async()=>{g.value=!0,d.value=null;try{const x=await K.get("/admin/claude-console-accounts");if(x.success)E.value=x.data||[];else throw new Error(x.message||"获取Claude Console账户失败")}catch(x){throw d.value=x.message,x}finally{g.value=!1}},y=async()=>{g.value=!0,d.value=null;try{const x=await K.get("/admin/gemini-accounts");if(x.success)m.value=x.data||[];else throw new Error(x.message||"获取Gemini账户失败")}catch(x){throw d.value=x.message,x}finally{g.value=!1}};return{claudeAccounts:L,claudeConsoleAccounts:E,geminiAccounts:m,loading:g,error:d,sortBy:S,sortOrder:I,fetchClaudeAccounts:C,fetchClaudeConsoleAccounts:A,fetchGeminiAccounts:y,fetchAllAccounts:async()=>{g.value=!0,d.value=null;try{await Promise.all([C(),A(),y()])}catch(x){throw d.value=x.message,x}finally{g.value=!1}},createClaudeAccount:async x=>{g.value=!0,d.value=null;try{const c=await K.post("/admin/claude-accounts",x);if(c.success)return await C(),c.data;throw new Error(c.message||"创建Claude账户失败")}catch(c){throw d.value=c.message,c}finally{g.value=!1}},createClaudeConsoleAccount:async x=>{g.value=!0,d.value=null;try{const c=await K.post("/admin/claude-console-accounts",x);if(c.success)return await A(),c.data;throw new Error(c.message||"创建Claude Console账户失败")}catch(c){throw d.value=c.message,c}finally{g.value=!1}},createGeminiAccount:async x=>{g.value=!0,d.value=null;try{const c=await K.post("/admin/gemini-accounts",x);if(c.success)return await y(),c.data;throw new Error(c.message||"创建Gemini账户失败")}catch(c){throw d.value=c.message,c}finally{g.value=!1}},updateClaudeAccount:async(x,c)=>{g.value=!0,d.value=null;try{const b=await K.put(`/admin/claude-accounts/${x}`,c);if(b.success)return await C(),b;throw new Error(b.message||"更新Claude账户失败")}catch(b){throw d.value=b.message,b}finally{g.value=!1}},updateClaudeConsoleAccount:async(x,c)=>{g.value=!0,d.value=null;try{const b=await K.put(`/admin/claude-console-accounts/${x}`,c);if(b.success)return await A(),b;throw new Error(b.message||"更新Claude Console账户失败")}catch(b){throw d.value=b.message,b}finally{g.value=!1}},updateGeminiAccount:async(x,c)=>{g.value=!0,d.value=null;try{const b=await K.put(`/admin/gemini-accounts/${x}`,c);if(b.success)return await y(),b;throw new Error(b.message||"更新Gemini账户失败")}catch(b){throw d.value=b.message,b}finally{g.value=!1}},toggleAccount:async(x,c)=>{g.value=!0,d.value=null;try{let b;x==="claude"?b=`/admin/claude-accounts/${c}/toggle`:x==="claude-console"?b=`/admin/claude-console-accounts/${c}/toggle`:b=`/admin/gemini-accounts/${c}/toggle`;const q=await K.put(b);if(q.success)return x==="claude"?await C():x==="claude-console"?await A():await y(),q;throw new Error(q.message||"切换状态失败")}catch(b){throw d.value=b.message,b}finally{g.value=!1}},deleteAccount:async(x,c)=>{g.value=!0,d.value=null;try{let b;x==="claude"?b=`/admin/claude-accounts/${c}`:x==="claude-console"?b=`/admin/claude-console-accounts/${c}`:b=`/admin/gemini-accounts/${c}`;const q=await K.delete(b);if(q.success)return x==="claude"?await C():x==="claude-console"?await A():await y(),q;throw new Error(q.message||"删除失败")}catch(b){throw d.value=b.message,b}finally{g.value=!1}},refreshClaudeToken:async x=>{g.value=!0,d.value=null;try{const c=await K.post(`/admin/claude-accounts/${x}/refresh`);if(c.success)return await C(),c;throw new Error(c.message||"Token刷新失败")}catch(c){throw d.value=c.message,c}finally{g.value=!1}},generateClaudeAuthUrl:async x=>{try{const c=await K.post("/admin/claude-accounts/generate-auth-url",x);if(c.success)return c.data;throw new Error(c.message||"生成授权URL失败")}catch(c){throw d.value=c.message,c}},exchangeClaudeCode:async x=>{try{const c=await K.post("/admin/claude-accounts/exchange-code",x);if(c.success)return c.data;throw new Error(c.message||"交换授权码失败")}catch(c){throw d.value=c.message,c}},generateGeminiAuthUrl:async x=>{try{const c=await K.post("/admin/gemini-accounts/generate-auth-url",x);if(c.success)return c.data;throw new Error(c.message||"生成授权URL失败")}catch(c){throw d.value=c.message,c}},exchangeGeminiCode:async x=>{try{const c=await K.post("/admin/gemini-accounts/exchange-code",x);if(c.success)return c.data;throw new Error(c.message||"交换授权码失败")}catch(c){throw d.value=c.message,c}},sortAccounts:x=>{S.value===x?I.value=I.value==="asc"?"desc":"asc":(S.value=x,I.value="asc")},reset:()=>{L.value=[],E.value=[],m.value=[],g.value=!1,d.value=null,S.value="",I.value="asc"}}}),Ke={class:"space-y-4"},Pe={class:"flex items-center justify-between"},Re={class:"flex items-center cursor-pointer"},Ge={key:0,class:"bg-gray-50 p-4 rounded-lg border border-gray-200 space-y-4"},Le={class:"grid grid-cols-2 gap-4"},De={class:"space-y-4"},Oe={class:"flex items-center"},Ee={key:0,class:"grid grid-cols-2 gap-4"},ze={class:"relative"},We=["type"],ge={__name:"ProxyConfig",props:{modelValue:{type:Object,default:()=>({enabled:!1,type:"socks5",host:"",port:"",username:"",password:""})}},emits:["update:modelValue"],setup(L,{emit:E}){const m=L,g=E,d=T({...m.modelValue}),S=T(!!(d.value.username||d.value.password)),I=T(!1);O(()=>m.modelValue,y=>{JSON.stringify(y)!==JSON.stringify(d.value)&&(d.value={...y},S.value=!!(y.username||y.password))},{deep:!0}),O(()=>d.value.enabled,y=>{A()}),O(()=>d.value.type,y=>{A()}),O(()=>d.value.host,y=>{A()}),O(()=>d.value.port,y=>{A()}),O(()=>d.value.username,y=>{A()}),O(()=>d.value.password,y=>{A()}),O(S,y=>{y||(d.value.username="",d.value.password="",A())});let C=null;function A(){C&&clearTimeout(C),C=setTimeout(()=>{const y={...d.value};S.value||(y.username="",y.password=""),g("update:modelValue",y)},100)}return Ae(()=>{C&&clearTimeout(C)}),(y,f)=>(i(),u("div",Ke,[e("div",Pe,[f[9]||(f[9]=e("h4",{class:"text-sm font-semibold text-gray-700"},"代理设置 (可选)",-1)),e("label",Re,[w(e("input",{type:"checkbox","onUpdate:modelValue":f[0]||(f[0]=M=>d.value.enabled=M),class:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500"},null,512),[[xe,d.value.enabled]]),f[8]||(f[8]=e("span",{class:"ml-2 text-sm text-gray-700"},"启用代理",-1))])]),d.value.enabled?(i(),u("div",Ge,[f[17]||(f[17]=te('
配置代理以访问受限的网络资源。支持 SOCKS5 和 HTTP 代理。
请确保代理服务器稳定可用,否则会影响账户的正常使用。
在浏览器中打开链接并完成授权
请在新标签页中打开授权链接,登录您的 Claude 账户并授权。
注意:如果您设置了代理,请确保浏览器也使用相同的代理访问授权页面。
在浏览器中打开链接并完成授权
提示:如果页面一直无法跳转,可以打开浏览器开发者工具(F12),F5刷新一下授权页再点击页面的登录按钮,在“网络”标签中找到以 localhost:45462 开头的请求,复制其完整URL。
支持粘贴完整链接,系统会自动提取授权码
也可以直接粘贴授权码(code参数的值)
P?k.value==="asc"?1:-1:0}):r}),w=async()=>{try{const[r,s]=await Promise.all([U.get("/admin/claude-accounts"),U.get("/admin/gemini-accounts")]);r.success&&(e.value.claude=r.data||[]),s.success&&(e.value.gemini=s.data||[])}catch(r){console.error("加载账户列表失败:",r)}},n=async()=>{_.value=!0;try{const r=await U.get(`/admin/api-keys?timeRange=${R.value}`);if(r.success){g.value=r.data||[];const s=new Set;g.value.forEach(c=>{c.tags&&Array.isArray(c.tags)&&c.tags.forEach(l=>s.add(l))}),j.value=Array.from(s).sort()}}catch{S("加载 API Keys 失败","error")}finally{_.value=!1}},d=r=>{x.value===r?k.value=k.value==="asc"?"desc":"asc":(x.value=r,k.value="asc")},D=r=>!r&&r!==0?"0":r.toLocaleString("zh-CN"),G=r=>!r||!r.total?"$0.0000":`$${(r.total.cost||0).toFixed(4)}`,X=r=>{if(!r)return"未知账户";const s=e.value.claude.find(l=>l.id===r);if(s)return s.name;const c=e.value.gemini.find(l=>l.id===r);return c?c.name:`账户-${r.substring(0,8)}`},it=r=>r?new Date(r) Claude Code 需要 Node.js 环境才能运行。 方法一:官网下载(推荐) 方法二:使用包管理器 如果你安装了 Chocolatey 或 Scoop,可以使用命令行安装: 安装完成后,打开 PowerShell 或 CMD,输入以下命令: 如果显示版本号,说明安装成功了! Windows 环境下需要使用 Git Bash 安装Claude code。安装完成后,环境变量设置和使用 Claude Code 仍然在普通的 PowerShell 或 CMD 中进行。 打开 Git Bash,输入以下命令验证: 如果显示 Git 版本号,说明安装成功! 打开 Git Bash(重要:不要使用 PowerShell),运行以下命令: 这个命令会从 npm 官方仓库下载并安装最新版本的 Claude Code。 安装完成后,输入以下命令检查是否安装成功: 如果显示版本号,恭喜你!Claude Code 已经成功安装了。 设置完环境变量后,可以通过以下命令验证是否设置成功: 现在你可以开始使用 Claude Code 了! 这通常是权限问题,尝试以下解决方法: 如果遇到执行策略限制,运行: 设置永久环境变量后需要: Claude Code 需要 Node.js 环境才能运行。 方法一:使用 Homebrew(推荐) 如果你已经安装了 Homebrew,使用它安装 Node.js 会更方便: 方法二:官网下载 安装完成后,打开 Terminal,输入以下命令: 如果显示版本号,说明安装成功了! 打开 Terminal,运行以下命令: 如果遇到权限问题,可以使用 sudo: 安装完成后,输入以下命令检查是否安装成功: 如果显示版本号,恭喜你!Claude Code 已经成功安装了。 现在你可以开始使用 Claude Code 了! 尝试以下解决方法: 如果系统阻止运行 Claude Code: 检查以下几点: Claude Code 需要 Node.js 环境才能运行。 方法一:使用官方仓库(推荐) 方法二:使用系统包管理器 虽然版本可能不是最新的,但对于基本使用已经足够: 安装完成后,打开终端,输入以下命令: 如果显示版本号,说明安装成功了! 打开终端,运行以下命令: 如果遇到权限问题,可以使用 sudo: 安装完成后,输入以下命令检查是否安装成功: 如果显示版本号,恭喜你!Claude Code 已经成功安装了。 现在你可以开始使用 Claude Code 了! 尝试以下解决方法: 某些 Linux 发行版需要安装额外依赖: 检查以下几点: =0;--u)if(!g()){this.updateRangeFromParsed(c,t,f,l);break}}return c}getAllParsedValues(t){const e=this._cachedMeta._parsed,s=[];let n,o,a;for(n=0,o=e.length;n m&&(m=_),h=(d*h+y)/++d):(v(),i.lineTo(y,_),g=k,d=0,p=m=_),b=_}v()}function pi(i){const t=i.options,e=t.borderDash&&t.borderDash.length;return!i._decimated&&!i._loop&&!t.tension&&t.cubicInterpolationMode!=="monotone"&&!t.stepped&&!e?cl:ll}function hl(i){return i.stepped?la:i.tension||i.cubicInterpolationMode==="monotone"?ca:At}function dl(i,t,e,s){let n=t._path;n||(n=t._path=new Path2D,t.path(n,e,s)&&n.closePath()),Wn(i,t.options),i.stroke(n)}function ul(i,t,e,s){const{segments:n,options:o}=t,a=pi(t);for(const r of n)Wn(i,o,r.style),i.beginPath(),a(i,t,r,{start:e,end:e+s-1})&&i.closePath(),i.stroke()}const fl=typeof Path2D=="function";function gl(i,t,e,s){fl&&!t.options.segment?dl(i,t,e,s):ul(i,t,e,s)}class bt extends ot{constructor(t){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,t&&Object.assign(this,t)}updateControlPoints(t,e){const s=this.options;if((s.tension||s.cubicInterpolationMode==="monotone")&&!s.stepped&&!this._pointsUpdated){const n=s.spanGaps?this._loop:this._fullLoop;ta(this._points,s,t,n,e),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=pa(this,this.options.segment))}first(){const t=this.segments,e=this.points;return t.length&&e[t[0].start]}last(){const t=this.segments,e=this.points,s=t.length;return s&&e[t[s-1].end]}interpolate(t,e){const s=this.options,n=t[e],o=this.points,a=Pn(this,{property:e,start:n,end:n});if(!a.length)return;const r=[],l=hl(s);let c,h;for(c=0,h=a.length;c ${n}1 安装 Node.js 环境
Windows 安装方法
https://nodejs.org/.msi 文件Windows 注意事项
验证安装是否成功
2 安装 Git Bash
下载并安装 Git for Windows
https://git-scm.com/downloads/win.exe 安装文件安装完成后
验证 Git Bash 安装
3 安装 Claude Code
安装 Claude Code
重要提醒
验证 Claude Code 安装
验证环境变量设置
在 PowerShell 中验证:
在 CMD 中验证:
5 开始使用 Claude Code
启动 Claude Code
在特定项目中使用
Windows 常见问题解决
安装时提示 "permission denied" 错误
npm config set prefix %APPDATA%\\npm PowerShell 执行策略错误
环境变量设置后不生效
echo $env:ANTHROPIC_BASE_URL1 安装 Node.js 环境
macOS 安装方法
https://nodejs.org/.pkg 文件macOS 注意事项
sudo验证安装是否成功
2 安装 Claude Code
安装 Claude Code
验证 Claude Code 安装
4 开始使用 Claude Code
启动 Claude Code
在特定项目中使用
macOS 常见问题解决
安装时提示权限错误
sudo npm install -g @anthropic-ai/claude-codenpm config set prefix ~/.npm-global macOS 安全设置阻止运行
sudo spctl --master-disable 环境变量不生效
echo $ANTHROPIC_BASE_URL1 安装 Node.js 环境
Linux 安装方法
Linux 注意事项
sudo验证安装是否成功
2 安装 Claude Code
安装 Claude Code
验证 Claude Code 安装
4 开始使用 Claude Code
启动 Claude Code
在特定项目中使用
Linux 常见问题解决
安装时提示权限错误
sudo npm install -g @anthropic-ai/claude-codenpm config set prefix ~/.npm-globalexport PATH=~/.npm-global/bin:$PATH 缺少依赖库
环境变量不生效
source ~/.bashrcecho $ANTHROPIC_BASE_URL1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[n]=this._fn(o,r,l)}wait(){const t=this._promises||(this._promises=[]);return new Promise((e,s)=>{t.push({res:e,rej:s})})}_notify(t){const e=t?"res":"rej",s=this._promises||[];for(let n=0;nc.box.fullSize),!0),s=Xt(Ut(t,"left"),!0),n=Xt(Ut(t,"right")),o=Xt(Ut(t,"top"),!0),a=Xt(Ut(t,"bottom")),r=ds(t,"x"),l=ds(t,"y");return{fullSize:e,leftAndTop:s.concat(o),rightAndBottom:n.concat(l).concat(a).concat(r),chartArea:Ut(t,"chartArea"),vertical:s.concat(n).concat(l),horizontal:o.concat(a).concat(r)}}function us(i,t,e,s){return Math.max(i[e],t[e])+Math.max(i[s],t[s])}function Ln(i,t){i.top=Math.max(i.top,t.top),i.left=Math.max(i.left,t.left),i.bottom=Math.max(i.bottom,t.bottom),i.right=Math.max(i.right,t.right)}function er(i,t,e,s){const{pos:n,box:o}=e,a=i.maxPadding;if(!T(n)){e.size&&(i[n]-=e.size);const d=s[e.stack]||{size:0,count:1};d.size=Math.max(d.size,e.horizontal?o.height:o.width),e.size=d.size/d.count,i[n]+=e.size}o.getPadding&&Ln(a,o.getPadding());const r=Math.max(0,t.outerWidth-us(a,i,"left","right")),l=Math.max(0,t.outerHeight-us(a,i,"top","bottom")),c=r!==i.w,h=l!==i.h;return i.w=r,i.h=l,e.horizontal?{same:c,other:h}:{same:h,other:c}}function ir(i){const t=i.maxPadding;function e(s){const n=Math.max(t[s]-i[s],0);return i[s]+=n,n}i.y+=e("top"),i.x+=e("left"),e("right"),e("bottom")}function sr(i,t){const e=t.maxPadding;function s(n){const o={left:0,top:0,right:0,bottom:0};return n.forEach(a=>{o[a]=Math.max(t[a],e[a])}),o}return s(i?["left","right"]:["top","bottom"])}function Jt(i,t,e,s){const n=[];let o,a,r,l,c,h;for(o=0,a=i.length,c=0;o{typeof p.beforeLayout=="function"&&p.beforeLayout()});const h=l.reduce((p,m)=>m.box.options&&m.box.options.display===!1?p:p+1,0)||1,d=Object.freeze({outerWidth:t,outerHeight:e,padding:n,availableWidth:o,availableHeight:a,vBoxMaxWidth:o/2/h,hBoxMaxHeight:a/2}),u=Object.assign({},n);Ln(u,J(s));const f=Object.assign({maxPadding:u,w:o,h:a,x:n.left,y:n.top},n),g=Za(l.concat(c),d);Jt(r.fullSize,f,d,g),Jt(l,f,d,g),Jt(c,f,d,g)&&Jt(l,f,d,g),ir(f),fs(r.leftAndTop,f,d,g),f.x+=f.w,f.y+=f.h,fs(r.rightAndBottom,f,d,g),i.chartArea={left:f.left,top:f.top,right:f.left+f.w,bottom:f.top+f.h,height:f.h,width:f.w},I(r.chartArea,p=>{const m=p.box;Object.assign(m,i.chartArea),m.update(f.w,f.h,{left:0,top:0,right:0,bottom:0})})}};class Rn{acquireContext(t,e){}releaseContext(t){return!1}addEventListener(t,e,s){}removeEventListener(t,e,s){}getDevicePixelRatio(){return 1}getMaximumSize(t,e,s,n){return e=Math.max(0,e||t.width),s=s||t.height,{width:e,height:Math.max(0,n?Math.floor(e/n):s)}}isAttached(t){return!0}updateConfig(t){}}class nr extends Rn{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const Te="$chartjs",or={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},gs=i=>i===null||i==="";function ar(i,t){const e=i.style,s=i.getAttribute("height"),n=i.getAttribute("width");if(i[Te]={initial:{height:s,width:n,style:{display:e.display,height:e.height,width:e.width}}},e.display=e.display||"block",e.boxSizing=e.boxSizing||"border-box",gs(n)){const o=Ji(i,"width");o!==void 0&&(i.width=o)}if(gs(s))if(i.style.height==="")i.height=i.width/(t||2);else{const o=Ji(i,"height");o!==void 0&&(i.height=o)}return i}const In=ra?{passive:!0}:!1;function rr(i,t,e){i&&i.addEventListener(t,e,In)}function lr(i,t,e){i&&i.canvas&&i.canvas.removeEventListener(t,e,In)}function cr(i,t){const e=or[i.type]||i.type,{x:s,y:n}=Ct(i,t);return{type:e,chart:t,native:i,x:s!==void 0?s:null,y:n!==void 0?n:null}}function We(i,t){for(const e of i)if(e===t||e.contains(t))return!0}function hr(i,t,e){const s=i.canvas,n=new MutationObserver(o=>{let a=!1;for(const r of o)a=a||We(r.addedNodes,s),a=a&&!We(r.removedNodes,s);a&&e()});return n.observe(document,{childList:!0,subtree:!0}),n}function dr(i,t,e){const s=i.canvas,n=new MutationObserver(o=>{let a=!1;for(const r of o)a=a||We(r.removedNodes,s),a=a&&!We(r.addedNodes,s);a&&e()});return n.observe(document,{childList:!0,subtree:!0}),n}const he=new Map;let ps=0;function En(){const i=window.devicePixelRatio;i!==ps&&(ps=i,he.forEach((t,e)=>{e.currentDevicePixelRatio!==i&&t()}))}function ur(i,t){he.size||window.addEventListener("resize",En),he.set(i,t)}function fr(i){he.delete(i),he.size||window.removeEventListener("resize",En)}function gr(i,t,e){const s=i.canvas,n=s&&Ii(s);if(!n)return;const o=hn((r,l)=>{const c=n.clientWidth;e(r,l),ci==="left"?"right":i==="right"?"left":i,ms=(i,t,e)=>t==="top"||t==="left"?i[t]+e:i[t]-e,bs=(i,t)=>Math.min(t||i,i);function xs(i,t){const e=[],s=i.length/t,n=i.length;let o=0;for(;o({width:a[P]||0,height:r[P]||0});return{first:w(0),last:w(e-1),widest:w(k),highest:w(S),widths:a,heights:r}}getLabelForValue(t){return t}getPixelForValue(t,e){return NaN}getValueForPixel(t){}getPixelForTick(t){const e=this.ticks;return t<0||t>e.length-1?null:this.getPixelForValue(e[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const e=this._startPixel+t*this._length;return fo(this._alignToPixels?wt(this.chart,e,0):e)}getDecimalForPixel(t){const e=(t-this._startPixel)/this._length;return this._reversePixels?1-e:e}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:e}=this;return t<0&&e<0?e:t>0&&e>0?t:0}getContext(t){const e=this.ticks||[];if(t>=0&&te.length&&delete this._stacks,t.forEach((s,n)=>{e.filter(o=>o===s._dataset).length===0&&this._destroyDatasetMeta(n)})}buildOrUpdateControllers(){const t=[],e=this.data.datasets;let s,n;for(this._removeUnreferencedMetasets(),s=0,n=e.length;s=0;--e)this._drawDataset(t[e]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const e=this.ctx,s={meta:t,index:t.index,cancelable:!0},n=Dn(this,t);this.notifyPlugins("beforeDatasetDraw",s)!==!1&&(n&&$e(e,n),t.controller.draw(),n&&Ye(e),s.cancelable=!1,this.notifyPlugins("afterDatasetDraw",s))}isPointInArea(t){return gt(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,e,s,n){const o=qa.modes[e];return typeof o=="function"?o(this,t,s,n):[]}getDatasetMeta(t){const e=this.data.datasets[t],s=this._metasets;let n=s.filter(o=>o&&o._dataset===e).pop();return n||(n={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:e&&e.order||0,index:t,_dataset:e,_parsed:[],_sorted:!1},s.push(n)),n}getContext(){return this.$context||(this.$context=vt(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const e=this.data.datasets[t];if(!e)return!1;const s=this.getDatasetMeta(t);return typeof s.hidden=="boolean"?!s.hidden:!e.hidden}setDatasetVisibility(t,e){const s=this.getDatasetMeta(t);s.hidden=!e}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,e,s){const n=s?"show":"hide",o=this.getDatasetMeta(t),a=o.controller._resolveAnimations(void 0,n);re(e)?(o.data[e].hidden=!s,this.update()):(this.setDatasetVisibility(t,s),a.update(o,{visible:s}),this.update(r=>r.datasetIndex===t?n:void 0))}hide(t,e){this._updateVisibility(t,e,!1)}show(t,e){this._updateVisibility(t,e,!0)}_destroyDatasetMeta(t){const e=this._metasets[t];e&&e.controller&&e.controller._destroy(),delete this._metasets[t]}_stop(){let t,e;for(this.stop(),ht.remove(this),t=0,e=this.data.datasets.length;ti.height-s/2?"bottom":"center"}function cc(i,t,e,s){const{x:n,width:o}=s,a=e.caretSize+e.caretPadding;if(i==="left"&&n+o+a>t.width||i==="right"&&n-o-a<0)return!0}function hc(i,t,e,s){const{x:n,width:o}=e,{width:a,chartArea:{left:r,right:l}}=i;let c="center";return s==="center"?c=n<=(r+l)/2?"left":"right":n<=o/2?c="left":n>=a-o/2&&(c="right"),cc(c,i,t,e)&&(c="center"),c}function Ns(i,t,e){const s=e.yAlign||t.yAlign||lc(i,e);return{xAlign:e.xAlign||t.xAlign||hc(i,t,e,s),yAlign:s}}function dc(i,t){let{x:e,width:s}=i;return t==="right"?e-=s:t==="center"&&(e-=s/2),e}function uc(i,t,e){let{y:s,height:n}=i;return t==="top"?s+=e:t==="bottom"?s-=n+e:s-=n/2,s}function Hs(i,t,e,s){const{caretSize:n,caretPadding:o,cornerRadius:a}=i,{xAlign:r,yAlign:l}=e,c=n+o,{topLeft:h,topRight:d,bottomLeft:u,bottomRight:f}=Tt(a);let g=dc(t,r);const p=uc(t,l,c);return l==="center"?r==="left"?g+=c:r==="right"&&(g-=c):r==="left"?g-=Math.max(h,u)+n:r==="right"&&(g+=Math.max(d,f)+n),{x:Y(g,0,s.width-t.width),y:Y(p,0,s.height-t.height)}}function Se(i,t,e){const s=J(e.padding);return t==="center"?i.x+i.width/2:t==="right"?i.x+i.width-s.right:i.x+s.left}function js(i){return at([],dt(i))}function fc(i,t,e){return vt(i,{tooltip:t,tooltipItems:e,type:"tooltip"})}function $s(i,t){const e=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return e?i.override(e):i}const Gn={beforeTitle:ct,title(i){if(i.length>0){const t=i[0],e=t.chart.data.labels,s=e?e.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(s>0&&t.dataIndex"u"?Gn[t].call(e,s):n}class xi extends ot{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const e=this.chart,s=this.options.setContext(this.getContext()),n=s.enabled&&e.options.animation&&s.animations,o=new Cn(this.chart,n);return n._cacheable&&(this._cachedAnimations=Object.freeze(o)),o}getContext(){return this.$context||(this.$context=fc(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,e){const{callbacks:s}=e,n=Q(s,"beforeTitle",this,t),o=Q(s,"title",this,t),a=Q(s,"afterTitle",this,t);let r=[];return r=at(r,dt(n)),r=at(r,dt(o)),r=at(r,dt(a)),r}getBeforeBody(t,e){return js(Q(e.callbacks,"beforeBody",this,t))}getBody(t,e){const{callbacks:s}=e,n=[];return I(t,o=>{const a={before:[],lines:[],after:[]},r=$s(s,o);at(a.before,dt(Q(r,"beforeLabel",this,o))),at(a.lines,Q(r,"label",this,o)),at(a.after,dt(Q(r,"afterLabel",this,o))),n.push(a)}),n}getAfterBody(t,e){return js(Q(e.callbacks,"afterBody",this,t))}getFooter(t,e){const{callbacks:s}=e,n=Q(s,"beforeFooter",this,t),o=Q(s,"footer",this,t),a=Q(s,"afterFooter",this,t);let r=[];return r=at(r,dt(n)),r=at(r,dt(o)),r=at(r,dt(a)),r}_createItems(t){const e=this._active,s=this.chart.data,n=[],o=[],a=[];let r=[],l,c;for(l=0,c=e.length;ln?{start:t-e,end:t}:{start:t,end:t+e}}function kc(i){const t={l:i.left+i._padding.left,r:i.right-i._padding.right,t:i.top+i._padding.top,b:i.bottom-i._padding.bottom},e=Object.assign({},t),s=[],n=[],o=i._pointLabels.length,a=i.options.pointLabels,r=a.centerPointLabels?R/o:0;for(let l=0;l{const n=z(this.options.pointLabels.callback,[e,s],this);return n||n===0?n:""}).filter((e,s)=>this.chart.getDataVisibility(s))}fit(){const t=this.options;t.display&&t.pointLabels.display?kc(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,e,s,n){this.xCenter+=Math.floor((t-e)/2),this.yCenter+=Math.floor((s-n)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,e,s,n))}getIndexAngle(t){const e=F/(this._pointLabels.length||1),s=this.options.startAngle||0;return G(t*e+st(s))}getDistanceFromCenterForValue(t){if(O(t))return NaN;const e=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*e:(t-this.min)*e}getValueForDistanceFromCenter(t){if(O(t))return NaN;const e=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-e:this.min+e}getPointLabelContext(t){const e=this._pointLabels||[];if(t>=0&&t+p)}getLabelForValue(t){const e=this._adapter,s=this.options.time;return s.tooltipFormat?e.format(t,s.tooltipFormat):e.format(t,s.displayFormats.datetime)}format(t,e){const n=this.options.time.displayFormats,o=this._unit,a=e||n[o];return this._adapter.format(t,a)}_tickFormatFunction(t,e,s,n){const o=this.options,a=o.ticks.callback;if(a)return z(a,[t,e,s],this);const r=o.time.displayFormats,l=this._unit,c=this._majorUnit,h=l&&r[l],d=c&&r[c],u=s[e],f=c&&d&&u&&u.major;return this._adapter.format(t,n||(f?d:h))}generateTickLabels(t){let e,s,n;for(e=0,s=t.length;e0?r:1}getDataTimestamps(){let t=this._cache.data||[],e,s;if(t.length)return t;const n=this.getMatchingVisibleMetas();if(this._normalized&&n.length)return this._cache.data=n[0].controller.getAllParsedValues(this);for(e=0,s=n.length;e=i[s].pos&&t<=i[n].pos&&({lo:s,hi:n}=ft(i,"pos",t)),{pos:o,time:r}=i[s],{pos:a,time:l}=i[n]):(t>=i[s].time&&t<=i[n].time&&({lo:s,hi:n}=ft(i,"time",t)),{time:o,pos:r}=i[s],{time:a,pos:l}=i[n]);const c=a-o;return c?r+(l-r)*(t-o)/c:r}class ki extends ue{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),e=this._table=this.buildLookupTable(t);this._minPos=we(e,this.min),this._tableRange=we(e,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:e,max:s}=this,n=[],o=[];let a,r,l,c,h;for(a=0,r=t.length;a{const[a,s]=[t[l],t[$r[l]]];return(s>0?a[s].offset:0)>=n?Ov(e,t,0,s,n,l):sN(e,t,rs(0,s),n,l)},Lv=({totalRow:e},{estimatedRowHeight:t,lastVisitedRowIndex:n,row:l})=>{let a=0;if(n>=e&&(n=e-1),n>=0){const i=l[n];a=i.offset+i.size}const r=(e-n-1)*t;return a+r},Bv=({totalColumn:e},{column:t,estimatedColumnWidth:n,lastVisitedColumnIndex:l})=>{let a=0;if(l>e&&(l=e-1),l>=0){const i=t[l];a=i.offset+i.size}const r=(e-l-1)*n;return a+r},rN={column:Bv,row:Lv},uc=(e,t,n,l,a,s,r)=>{const[i,u]=[s==="row"?e.height:e.width,rN[s]],c=sl(e,t,a,s),d=u(e,a),f=rs(0,Rv(d-i,c.offset)),m=rs(0,c.offset-i+r+c.size);switch(n===Ns&&(l>=m-i&&l<=f+i?n=xn:n=Jn),n){case ta:return f;case na:return m;case Jn:return Math.round(m+(f-m)/2);case xn:default:return l>=m&&l<=f?l:m>f||l0&&n.lazy&&n.defaultExpandAll&&!this.isLeafByUser&&this.expand(),ke(this.data)||gc(this,this.data),!this.data)return;const a=n.defaultExpandedKeys,s=n.key;s&&!qt(this.key)&&a&&a.includes(this.key)&&this.expand(null,n.autoExpandParent),s&&n.currentNodeKey!==void 0&&this.key===n.currentNodeKey&&(n.currentNode=this,n.currentNode.isCurrent=!0),n.lazy&&n._initDefaultCheckedNode(this),this.updateLeafState(),(this.level===1||((t=this.parent)==null?void 0:t.expanded)===!0)&&(this.canFocus=!0)}setData(t){ke(t)||gc(this,t),this.data=t,this.childNodes=[];let n;this.level===0&&ke(this.data)?n=this.data:n=Ma(this,"children")||[];for(let l=0,a=n.length;l-1)return t.childNodes[n+1]}return null}get previousSibling(){const t=this.parent;if(t){const n=t.childNodes.indexOf(this);if(n>-1)return n>0?t.childNodes[n-1]:null}return null}contains(t,n=!0){return(this.childNodes||[]).some(l=>l===t||n&&l.contains(t))}remove(){const t=this.parent;t&&t.removeChild(this)}insertChild(t,n,l){if(!t)throw new Error("InsertChild error: child is required.");if(!(t instanceof Wl)){if(!l){const a=this.getChildren(!0);a!=null&&a.includes(t.data)||(vt(n)||n<0?a==null||a.push(t.data):a==null||a.splice(n,0,t.data))}Object.assign(t,{parent:this,store:this.store}),t=kt(new Wl(t)),t instanceof Wl&&t.initialize()}t.level=this.level+1,vt(n)||n<0?this.childNodes.push(t):this.childNodes.splice(n,0,t),this.updateLeafState()}insertBefore(t,n){let l;n&&(l=this.childNodes.indexOf(n)),this.insertChild(t,l)}insertAfter(t,n){let l;n&&(l=this.childNodes.indexOf(n),l!==-1&&(l+=1)),this.insertChild(t,l)}removeChild(t){const n=this.getChildren()||[],l=n.indexOf(t.data);l>-1&&n.splice(l,1);const a=this.childNodes.indexOf(t);a>-1&&(this.store&&this.store.deregisterNode(t),t.parent=null,this.childNodes.splice(a,1)),this.updateLeafState()}removeChildByData(t){let n=null;for(let l=0;l${a}
`:""}
+ =e||E<0||c&&P>=a}function d(){var S=Dn();if(h(S))return w(S);s=setTimeout(d,g(S))}function w(S){return s=void 0,p&&r?m(S):(r=i=void 0,o)}function v(){s!==void 0&&clearTimeout(s),u=0,r=f=i=s=void 0}function x(){return s===void 0?o:w(Dn())}function A(){var S=Dn(),E=h(S);if(r=arguments,i=this,f=S,E){if(s===void 0)return y(f);if(c)return clearTimeout(s),s=setTimeout(d,e),m(f)}return s===void 0&&(s=setTimeout(d,e)),o}return A.cancel=v,A.flush=x,A}function Bn(t,e,n){(n!==void 0&&!He(t[e],n)||n===void 0&&!(e in t))&&pr(t,e,n)}function Ya(t){return At(t)&&me(t)}function Wn(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}function Nl(t){return ge(t,ke(t))}function Il(t,e,n,r,i,a,o){var s=Wn(t,n),f=Wn(e,n),u=o.get(f);if(u){Bn(t,n,u);return}var l=a?a(s,f,n+"",t,e,o):void 0,c=l===void 0;if(c){var p=Z(f),m=!p&&Pe(f),y=!p&&!m&&br(f);l=f,p||m||y?Z(s)?l=s:Ya(s)?l=ua(s):m?(c=!1,l=Aa(f,!0)):y?(c=!1,l=_a(f,!0)):l=[]:xa(f)||Fe(f)?(l=s,Fe(s)?l=Nl(s):(!K(s)||hr(s))&&(l=Ea(f))):c=!1}c&&(o.set(f,l),i(l,f,r,a,o),o.delete(f)),Bn(t,n,l)}function ka(t,e,n,r,i){t!==e&&Ha(e,function(a,o){if(i||(i=new mt),K(a))Il(t,e,o,n,ka,r,i);else{var s=r?r(Wn(t,o),a,o+"",t,e,i):void 0;s===void 0&&(s=a),Bn(t,o,s)}},ke)}function Hl(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}function Og(t,e,n){var r=t==null?0:t.length;if(!r)return-1;var i=r-1;return la(t,Ia(e),i,!0)}function Yl(t,e){var n=-1,r=me(t)?Array(t.length):[];return Dl(t,function(i,a,o){r[++n]=e(i,a,o)}),r}function kl(t,e){var n=Z(t)?lr:Yl;return n(t,Ia(e))}function Ag(t,e){return qe(kl(t,e),1)}var ql=1/0;function $g(t){var e=t==null?0:t.length;return e?qe(t,ql):[]}function Sg(t){for(var e=-1,n=t==null?0:t.length,r={};++e0)return;if(hn){let t=hn;for(hn=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;dn;){let t=dn;for(dn=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(s){e||(e=s)}t=n}}if(e)throw e}function gi(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function mi(e){let t,n=e.depsTail,s=n;for(;s;){const r=s.prevDep;s.version===-1?(s===n&&(n=r),mr(s),cc(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=r}e.deps=t,e.depsTail=n}function Bs(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(vi(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function vi(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Sn)||(e.globalVersion=Sn,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Bs(e))))return;e.flags|=2;const t=e.dep,n=ce,s=Ke;ce=e,Ke=!0;try{gi(e);const r=e.fn(e._value);(t.version===0||Et(r,e._value))&&(e.flags|=128,e._value=r,t.version++)}catch(r){throw t.version++,r}finally{ce=n,Ke=s,mi(e),e.flags&=-3}}function mr(e,t=!1){const{dep:n,prevSub:s,nextSub:r}=e;if(s&&(s.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=s,e.nextSub=void 0),n.subs===e&&(n.subs=s,!s&&n.computed)){n.computed.flags&=-5;for(let o=n.computed.deps;o;o=o.nextDep)mr(o,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function cc(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Ke=!0;const yi=[];function ct(){yi.push(Ke),Ke=!1}function ut(){const e=yi.pop();Ke=e===void 0?!0:e}function kr(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=ce;ce=void 0;try{t()}finally{ce=n}}}let Sn=0;class uc{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class fs{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!ce||!Ke||ce===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==ce)n=this.activeLink=new uc(ce,this),ce.deps?(n.prevDep=ce.depsTail,ce.depsTail.nextDep=n,ce.depsTail=n):ce.deps=ce.depsTail=n,_i(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const s=n.nextDep;s.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=s),n.prevDep=ce.depsTail,n.nextDep=void 0,ce.depsTail.nextDep=n,ce.depsTail=n,ce.deps===n&&(ce.deps=s)}return n}trigger(t){this.version++,Sn++,this.notify(t)}notify(t){pr();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{gr()}}}function _i(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let s=t.deps;s;s=s.nextDep)_i(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const zn=new WeakMap,Ft=Symbol(""),Ks=Symbol(""),wn=Symbol("");function be(e,t,n){if(Ke&&ce){let s=zn.get(e);s||zn.set(e,s=new Map);let r=s.get(n);r||(s.set(n,r=new fs),r.map=s,r.key=n),r.track()}}function rt(e,t,n,s,r,o){const i=zn.get(e);if(!i){Sn++;return}const l=c=>{c&&c.trigger()};if(pr(),t==="clear")i.forEach(l);else{const c=V(e),a=c&&fr(n);if(c&&n==="length"){const u=Number(s);i.forEach((f,h)=>{(h==="length"||h===wn||!Ue(h)&&h>=u)&&l(f)})}else switch((n!==void 0||i.has(void 0))&&l(i.get(n)),a&&l(i.get(wn)),t){case"add":c?a&&l(i.get("length")):(l(i.get(Ft)),Gt(e)&&l(i.get(Ks)));break;case"delete":c||(l(i.get(Ft)),Gt(e)&&l(i.get(Ks)));break;case"set":Gt(e)&&l(i.get(Ft));break}}gr()}function ac(e,t){const n=zn.get(e);return n&&n.get(t)}function kt(e){const t=J(e);return t===e?t:(be(t,"iterate",wn),De(e)?t:t.map(ge))}function ds(e){return be(e=J(e),"iterate",wn),e}const fc={__proto__:null,[Symbol.iterator](){return Os(this,Symbol.iterator,ge)},concat(...e){return kt(this).concat(...e.map(t=>V(t)?kt(t):t))},entries(){return Os(this,"entries",e=>(e[1]=ge(e[1]),e))},every(e,t){return tt(this,"every",e,t,void 0,arguments)},filter(e,t){return tt(this,"filter",e,t,n=>n.map(ge),arguments)},find(e,t){return tt(this,"find",e,t,ge,arguments)},findIndex(e,t){return tt(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return tt(this,"findLast",e,t,ge,arguments)},findLastIndex(e,t){return tt(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return tt(this,"forEach",e,t,void 0,arguments)},includes(...e){return Ps(this,"includes",e)},indexOf(...e){return Ps(this,"indexOf",e)},join(e){return kt(this).join(e)},lastIndexOf(...e){return Ps(this,"lastIndexOf",e)},map(e,t){return tt(this,"map",e,t,void 0,arguments)},pop(){return rn(this,"pop")},push(...e){return rn(this,"push",e)},reduce(e,...t){return Br(this,"reduce",e,t)},reduceRight(e,...t){return Br(this,"reduceRight",e,t)},shift(){return rn(this,"shift")},some(e,t){return tt(this,"some",e,t,void 0,arguments)},splice(...e){return rn(this,"splice",e)},toReversed(){return kt(this).toReversed()},toSorted(e){return kt(this).toSorted(e)},toSpliced(...e){return kt(this).toSpliced(...e)},unshift(...e){return rn(this,"unshift",e)},values(){return Os(this,"values",ge)}};function Os(e,t,n){const s=ds(e),r=s[t]();return s!==e&&!De(e)&&(r._next=r.next,r.next=()=>{const o=r._next();return o.value&&(o.value=n(o.value)),o}),r}const dc=Array.prototype;function tt(e,t,n,s,r,o){const i=ds(e),l=i!==e&&!De(e),c=i[t];if(c!==dc[t]){const f=c.apply(e,o);return l?ge(f):f}let a=n;i!==e&&(l?a=function(f,h){return n.call(this,ge(f),h,e)}:n.length>2&&(a=function(f,h){return n.call(this,f,h,e)}));const u=c.call(i,a,s);return l&&r?r(u):u}function Br(e,t,n,s){const r=ds(e);let o=n;return r!==e&&(De(e)?n.length>3&&(o=function(i,l,c){return n.call(this,i,l,c,e)}):o=function(i,l,c){return n.call(this,i,ge(l),c,e)}),r[t](o,...s)}function Ps(e,t,n){const s=J(e);be(s,"iterate",wn);const r=s[t](...n);return(r===-1||r===!1)&&_r(n[0])?(n[0]=J(n[0]),s[t](...n)):r}function rn(e,t,n=[]){ct(),pr();const s=J(e)[t].apply(e,n);return gr(),ut(),s}const hc=cr("__proto__,__v_isRef,__isVue"),bi=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ue));function pc(e){Ue(e)||(e=String(e));const t=J(this);return be(t,"has",e),t.hasOwnProperty(e)}class Si{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){if(n==="__v_skip")return t.__v_skip;const r=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return o;if(n==="__v_raw")return s===(r?o?xc:Ci:o?xi:Ei).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=V(t);if(!r){let c;if(i&&(c=fc[n]))return c;if(n==="hasOwnProperty")return pc}const l=Reflect.get(t,n,fe(t)?t:s);return(Ue(n)?bi.has(n):hc(n))||(r||be(t,"get",n),o)?l:fe(l)?i&&fr(n)?l:l.value:se(l)?r?hs(l):Pn(l):l}}class wi extends Si{constructor(t=!1){super(!1,t)}set(t,n,s,r){let o=t[n];if(!this._isShallow){const c=xt(o);if(!De(s)&&!xt(s)&&(o=J(o),s=J(s)),!V(t)&&fe(o)&&!fe(s))return c?!1:(o.value=s,!0)}const i=V(t)&&fr(n)?Number(n)