@gientech/modual 2.2.28 → 2.2.30

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.
@@ -0,0 +1,332 @@
1
+ import{jsx as N,jsxs as re,Fragment as Vn}from"react/jsx-runtime";import*as L from"react";import ve,{createElement as wi,PureComponent as ef,useState as le,useMemo as Ke,createContext as Un,Children as tf,cloneElement as rf,Component as nf,useRef as Ve,useEffect as De,useContext as lr,version as af,isValidElement as of,useLayoutEffect as sf,useCallback as Jn}from"react";import Mt from"axios";import{AiChat as cf,validateFileUpload as uf,showValidationErrors as lf}from"@mxmweb/aichat";import{mergeLiveChunkToNodes as ff,ChatMessageAdapter as Ss}from"@mxmweb/rtext";import{Dropdown as df,Input as jc,Popover as pf,message as St,Skeleton as ea,Button as vn,ConfigProvider as di,Modal as Vc,Form as Bs,Table as hf,Pagination as vf,Empty as xf,Tooltip as On,Drawer as Uc}from"antd";import{u as yr}from"./index-CpW6Dhpp.js";import{Icon as gf,defaultTheme as Jo,useTheme as mf,deepMergeTheme as _s}from"@mxmweb/zui";import{d as Ds,g as es,a as yf,c as Si}from"./dayjs.min-9C0uSO6x.js";import{c as bn,X as Wc}from"./x-CX-iE6EL.js";import{P as Cf}from"./plus-Cok3acFd.js";import{S as Qi}from"./search-BfgWf2Me.js";import*as bf from"react-dom";import ks,{createPortal as Ff}from"react-dom";import{f as Ef,r as Af,a as wf,c as Sf,B as Bf,z as _f,d as Gc,g as Kc,b as Xc,e as Zi,h as ts,i as Ji,D as Df,j as kf,T as eo,k as Bi,l as Pf,m as If,N as Tf,n as Rf,G as Of,o as Nf,W as Mf,p as Yc,q as Lf,s as $f,u as zf,F as Hf,t as Ps,v as _i,w as qf,x as jf,y as Vf,A as Uf,E as Wf}from"./index-C3NkyTp6.js";import{a as Gf,C as Kf,G as Qc}from"./GientechStreamReader-Bmx4xCIT.js";/* empty css *//* empty css */import"@mxmweb/fviewer";import"../database.js";import"../databaseId.js";import"../databaseTable.js";import"../modelManage.js";import"../sensitive.js";import"../oprecords.js";import"./index-DCoRawSB.js";/**
2
+ * @license lucide-react v0.456.0 - ISC
3
+ *
4
+ * This source code is licensed under the ISC license.
5
+ * See the LICENSE file in the root directory of this source tree.
6
+ */const Xf=bn("Ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);/**
7
+ * @license lucide-react v0.456.0 - ISC
8
+ *
9
+ * This source code is licensed under the ISC license.
10
+ * See the LICENSE file in the root directory of this source tree.
11
+ */const Yf=bn("History",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/**
12
+ * @license lucide-react v0.456.0 - ISC
13
+ *
14
+ * This source code is licensed under the ISC license.
15
+ * See the LICENSE file in the root directory of this source tree.
16
+ */const Qf=bn("OctagonX",[["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"M2.586 16.726A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2h6.624a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586z",key:"2d38gg"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
17
+ * @license lucide-react v0.456.0 - ISC
18
+ *
19
+ * This source code is licensed under the ISC license.
20
+ * See the LICENSE file in the root directory of this source tree.
21
+ */const Zf=bn("Pen",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]]);/**
22
+ * @license lucide-react v0.456.0 - ISC
23
+ *
24
+ * This source code is licensed under the ISC license.
25
+ * See the LICENSE file in the root directory of this source tree.
26
+ */const Zc=bn("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
27
+ * @license lucide-react v0.456.0 - ISC
28
+ *
29
+ * This source code is licensed under the ISC license.
30
+ * See the LICENSE file in the root directory of this source tree.
31
+ */const Jf=bn("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]),ed=r=>L.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",...r},L.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 14.6666C11.6819 14.6666 14.6667 11.6819 14.6667 7.99998C14.6667 4.31808 11.6819 1.33331 8 1.33331C4.3181 1.33331 1.33334 4.31808 1.33334 7.99998C1.33334 11.6819 4.3181 14.6666 8 14.6666Z",stroke:"currentColor",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{d:"M1.33334 8H14.6667",stroke:"currentColor",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 14.6666C9.47277 14.6666 10.6667 11.6819 10.6667 7.99998C10.6667 4.31808 9.47277 1.33331 8 1.33331C6.52724 1.33331 5.33334 4.31808 5.33334 7.99998C5.33334 11.6819 6.52724 14.6666 8 14.6666Z",stroke:"currentColor",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{d:"M3.28597 3.38068C4.4924 4.58711 6.15907 5.33331 8 5.33331C9.84097 5.33331 11.5076 4.58711 12.7141 3.38068",stroke:"currentColor",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{d:"M12.7141 12.6193C11.5076 11.4129 9.84097 10.6667 8 10.6667C6.15907 10.6667 4.4924 11.4129 3.28597 12.6193",stroke:"currentColor",strokeWidth:1.33333,strokeLinecap:"round",strokeLinejoin:"round"})),td=r=>L.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",...r},L.createElement("path",{d:"M1.73633 1.57642C2.53848 0.774265 3.74473 0.714862 4.87207 1.03052C6.02182 1.35245 7.24885 2.09683 8.3125 3.1604C9.37624 4.22414 10.1204 5.45195 10.4424 6.60181C10.758 7.72909 10.6986 8.93446 9.89648 9.73657C9.09439 10.5387 7.88901 10.5981 6.76172 10.2825C5.61186 9.96051 4.38405 9.21632 3.32031 8.15259C2.25674 7.08894 1.51236 5.86191 1.19043 4.71216C0.874775 3.58481 0.934176 2.37857 1.73633 1.57642Z",stroke:"#4E6EF2",strokeWidth:1.3,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{d:"M6.76172 5.41479C7.88883 5.09929 9.09442 5.15888 9.89648 5.96069C10.6986 6.76284 10.758 7.96909 10.4424 9.09644C10.1204 10.2462 9.37617 11.4732 8.3125 12.5369C7.24882 13.6005 6.02187 14.3448 4.87207 14.6667C3.74472 14.9824 2.53848 14.923 1.73633 14.1208C0.934528 13.3188 0.874922 12.1132 1.19043 10.9861C1.51239 9.83623 2.25659 8.60841 3.32031 7.54468C4.38405 6.48096 5.61186 5.73675 6.76172 5.41479Z",stroke:"#4E6EF2",strokeWidth:1.3,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{d:"M11.1282 1.03052C12.2553 0.715012 13.4609 0.774612 14.263 1.57642C15.0651 2.37857 15.1246 3.58481 14.8089 4.71216C14.4869 5.86196 13.7427 7.08892 12.679 8.15259C11.6153 9.21627 10.3884 9.96048 9.23859 10.2825C8.11124 10.5981 6.90499 10.5387 6.10284 9.73657C5.30106 8.9345 5.24144 7.72892 5.55695 6.60181C5.8789 5.45195 6.62311 4.22414 7.68683 3.1604C8.75056 2.09668 9.97838 1.35248 11.1282 1.03052Z",stroke:"#4E6EF2",strokeWidth:1.3,strokeLinecap:"round",strokeLinejoin:"round"}),L.createElement("path",{d:"M6.10284 5.96069C6.90499 5.15855 8.11124 5.09914 9.23859 5.41479C10.3883 5.73673 11.6154 6.48111 12.679 7.54468C13.7427 8.60841 14.4869 9.83623 14.8089 10.9861C15.1245 12.1134 15.0651 13.3188 14.263 14.1208C13.4609 14.9229 12.2555 14.9823 11.1282 14.6667C9.97838 14.3448 8.75055 13.6006 7.68683 12.5369C6.62325 11.4732 5.87888 10.2462 5.55695 9.09644C5.24129 7.96909 5.3007 6.76284 6.10284 5.96069Z",stroke:"#4E6EF2",strokeWidth:1.3,strokeLinecap:"round",strokeLinejoin:"round"})),en={actions:[{name:"upload",icon:N(gf,{type:"wenda/shangchuanwenjian",color:"#000",size:20}),tip:"\u6587\u4EF6\u4E0A\u4F20"}],switchs:[{label:"\u8054\u7F51\u641C\u7D22",name:"netSearch",type:"switch",defaultValue:!1,enabled:!0,icon:N(ed,{width:16,height:16,className:"aichat-netsearch-icon",style:{color:"#4B8CF7"}})},{label:"\u6DF1\u5EA6\u601D\u8003",name:"reasoning",type:"switch",defaultValue:!0,enabled:!0,icon:N(td,{width:16,height:16})}]},rs={sidebar:{newChat:"\u65B0\u5EFA\u5BF9\u8BDD",newConversation:"\u65B0\u5EFA\u4F1A\u8BDD",unnamedSession:"\u672A\u547D\u540D\u4F1A\u8BDD",noAssistant:"\u672A\u9009\u62E9\u52A9\u624B",searchPlaceholder:"\u641C\u7D22\u5386\u53F2\u8BB0\u5F55",search:"\u641C\u7D22",rename:"\u91CD\u547D\u540D",delete:"\u5220\u9664"},welcome:{defaultPrologue:"\u60A8\u597D\uFF0C\u6B22\u8FCE\u4F7F\u7528\u5C0F\u9CB8\u667A\u80FD\u95EE\u7B54",selectAssistant:"\u8BF7\u9009\u62E9\u4E00\u4E2A\u667A\u80FD\u52A9\u624B",searchAssistant:"\u641C\u7D22\u52A9\u624B\u540D\u79F0"},sender:{netSearch:"\u8054\u7F51\u641C\u7D22",deepThinking:"\u6DF1\u5EA6\u601D\u8003",fileUpload:"\u6587\u4EF6\u4E0A\u4F20"},chatHeader:{newConversation:"\u65B0\u5BF9\u8BDD"},disclaimer:"\u5185\u5BB9\u7531AI\u751F\u6210\uFF0C\u4EC5\u4F9B\u53C2\u8003\uFF0C\u4E0D\u4EE3\u8868\u672C\u516C\u53F8\u89C2\u70B9\u3002"},rd={sidebar:{newChat:"New chat",newConversation:"New conversation",unnamedSession:"Unnamed",noAssistant:"No assistant",searchPlaceholder:"Search history",search:"Search",rename:"Rename",delete:"Delete"},welcome:{defaultPrologue:"Hello, welcome to Smart Q&A",selectAssistant:"Please select an assistant",searchAssistant:"Search assistants"},sender:{netSearch:"Web search",deepThinking:"Deep thinking",fileUpload:"Upload file"},chatHeader:{newConversation:"New conversation"},disclaimer:"Content is AI-generated and for reference only."},nd={sidebar:{newChat:"\u65B0\u898F\u4F1A\u8A71",newConversation:"\u65B0\u898F\u4F1A\u8A71",unnamedSession:"\u540D\u524D\u306A\u3057",noAssistant:"\u30A2\u30B7\u30B9\u30BF\u30F3\u30C8\u672A\u9078\u629E",searchPlaceholder:"\u5C65\u6B74\u3092\u691C\u7D22",search:"\u691C\u7D22",rename:"\u540D\u524D\u3092\u5909\u66F4",delete:"\u524A\u9664"},welcome:{defaultPrologue:"\u3053\u3093\u306B\u3061\u306F\u3001\u30B9\u30DE\u30FC\u30C8Q&A\u3078\u3088\u3046\u3053\u305D",selectAssistant:"\u30A2\u30B7\u30B9\u30BF\u30F3\u30C8\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044",searchAssistant:"\u30A2\u30B7\u30B9\u30BF\u30F3\u30C8\u3092\u691C\u7D22"},sender:{netSearch:"\u30CD\u30C3\u30C8\u691C\u7D22",deepThinking:"\u6DF1\u304F\u8003\u3048\u308B",fileUpload:"\u30D5\u30A1\u30A4\u30EB\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9"},chatHeader:{newConversation:"\u65B0\u898F\u4F1A\u8A71"},disclaimer:"AI\u306B\u3088\u308A\u751F\u6210\u3055\u308C\u305F\u5185\u5BB9\u3067\u3059\u3002\u53C2\u8003\u3068\u3057\u3066\u3054\u5229\u7528\u304F\u3060\u3055\u3044\u3002"},ad={zh:rs,en:rd,ja:nd};function Jc(r){return ad[r]??rs}const eu=ve.createContext({locale:"zh",messages:rs});function pi(){return ve.useContext(eu)}function id({locale:r,children:t}){const e=ve.useMemo(()=>({locale:r,messages:Jc(r)}),[r]);return ve.createElement(eu.Provider,{value:e},t)}function bt(){return bt=Object.assign?Object.assign.bind():function(r){for(var t=1;t<arguments.length;t++){var e=arguments[t];for(var n in e)({}).hasOwnProperty.call(e,n)&&(r[n]=e[n])}return r},bt.apply(null,arguments)}function we(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function xn(r,t){return xn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,n){return e.__proto__=n,e},xn(r,t)}function od(r,t){r.prototype=Object.create(t.prototype),r.prototype.constructor=r,xn(r,t)}var Is=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function sd(r,t){return!!(r===t||Is(r)&&Is(t))}function cd(r,t){if(r.length!==t.length)return!1;for(var e=0;e<r.length;e++)if(!sd(r[e],t[e]))return!1;return!0}function Di(r,t){t===void 0&&(t=cd);var e,n=[],a,i=!1;function o(){for(var s=[],l=0;l<arguments.length;l++)s[l]=arguments[l];return i&&e===this&&t(s,n)||(a=r.apply(this,s),i=!0,e=this,n=s),a}return o}function ud(r,t){if(r==null)return{};var e={};for(var n in r)if({}.hasOwnProperty.call(r,n)){if(t.indexOf(n)!==-1)continue;e[n]=r[n]}return e}var ld=typeof performance=="object"&&typeof performance.now=="function",Ts=ld?function(){return performance.now()}:function(){return Date.now()};function Rs(r){cancelAnimationFrame(r.id)}function fd(r,t){var e=Ts();function n(){Ts()-e>=t?r.call(null):a.id=requestAnimationFrame(n)}var a={id:requestAnimationFrame(n)};return a}var ki=-1;function Os(r){if(r===void 0&&(r=!1),ki===-1||r){var t=document.createElement("div"),e=t.style;e.width="50px",e.height="50px",e.overflow="scroll",document.body.appendChild(t),ki=t.offsetWidth-t.clientWidth,document.body.removeChild(t)}return ki}var tn=null;function Ns(r){if(r===void 0&&(r=!1),tn===null||r){var t=document.createElement("div"),e=t.style;e.width="50px",e.height="50px",e.overflow="scroll",e.direction="rtl";var n=document.createElement("div"),a=n.style;return a.width="100px",a.height="100px",t.appendChild(n),document.body.appendChild(t),t.scrollLeft>0?tn="positive-descending":(t.scrollLeft=1,t.scrollLeft===0?tn="negative":tn="positive-ascending"),document.body.removeChild(t),tn}return tn}var dd=150,pd=function(t,e){return t};function hd(r){var t,e=r.getItemOffset,n=r.getEstimatedTotalSize,a=r.getItemSize,i=r.getOffsetForIndexAndAlignment,o=r.getStartIndexForOffset,s=r.getStopIndexForStartIndex,l=r.initInstanceProps,c=r.shouldResetStyleCacheOnItemSizeChange,u=r.validateProps;return t=(function(h){od(d,h);function d(x){var p;return p=h.call(this,x)||this,p._instanceProps=l(p.props,we(p)),p._outerRef=void 0,p._resetIsScrollingTimeoutId=null,p.state={instance:we(p),isScrolling:!1,scrollDirection:"forward",scrollOffset:typeof p.props.initialScrollOffset=="number"?p.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},p._callOnItemsRendered=void 0,p._callOnItemsRendered=Di(function(f,y,v,C){return p.props.onItemsRendered({overscanStartIndex:f,overscanStopIndex:y,visibleStartIndex:v,visibleStopIndex:C})}),p._callOnScroll=void 0,p._callOnScroll=Di(function(f,y,v){return p.props.onScroll({scrollDirection:f,scrollOffset:y,scrollUpdateWasRequested:v})}),p._getItemStyle=void 0,p._getItemStyle=function(f){var y=p.props,v=y.direction,C=y.itemSize,b=y.layout,F=p._getItemStyleCache(c&&C,c&&b,c&&v),E;if(F.hasOwnProperty(f))E=F[f];else{var w=e(p.props,f,p._instanceProps),A=a(p.props,f,p._instanceProps),S=v==="horizontal"||b==="horizontal",m=v==="rtl",B=S?w:0;F[f]=E={position:"absolute",left:m?void 0:B,right:m?B:void 0,top:S?0:w,height:S?"100%":A,width:S?A:"100%"}}return E},p._getItemStyleCache=void 0,p._getItemStyleCache=Di(function(f,y,v){return{}}),p._onScrollHorizontal=function(f){var y=f.currentTarget,v=y.clientWidth,C=y.scrollLeft,b=y.scrollWidth;p.setState(function(F){if(F.scrollOffset===C)return null;var E=p.props.direction,w=C;if(E==="rtl")switch(Ns()){case"negative":w=-C;break;case"positive-descending":w=b-v-C;break}return w=Math.max(0,Math.min(w,b-v)),{isScrolling:!0,scrollDirection:F.scrollOffset<w?"forward":"backward",scrollOffset:w,scrollUpdateWasRequested:!1}},p._resetIsScrollingDebounced)},p._onScrollVertical=function(f){var y=f.currentTarget,v=y.clientHeight,C=y.scrollHeight,b=y.scrollTop;p.setState(function(F){if(F.scrollOffset===b)return null;var E=Math.max(0,Math.min(b,C-v));return{isScrolling:!0,scrollDirection:F.scrollOffset<E?"forward":"backward",scrollOffset:E,scrollUpdateWasRequested:!1}},p._resetIsScrollingDebounced)},p._outerRefSetter=function(f){var y=p.props.outerRef;p._outerRef=f,typeof y=="function"?y(f):y!=null&&typeof y=="object"&&y.hasOwnProperty("current")&&(y.current=f)},p._resetIsScrollingDebounced=function(){p._resetIsScrollingTimeoutId!==null&&Rs(p._resetIsScrollingTimeoutId),p._resetIsScrollingTimeoutId=fd(p._resetIsScrolling,dd)},p._resetIsScrolling=function(){p._resetIsScrollingTimeoutId=null,p.setState({isScrolling:!1},function(){p._getItemStyleCache(-1,null)})},p}d.getDerivedStateFromProps=function(p,f){return vd(p,f),u(p),null};var g=d.prototype;return g.scrollTo=function(p){p=Math.max(0,p),this.setState(function(f){return f.scrollOffset===p?null:{scrollDirection:f.scrollOffset<p?"forward":"backward",scrollOffset:p,scrollUpdateWasRequested:!0}},this._resetIsScrollingDebounced)},g.scrollToItem=function(p,f){f===void 0&&(f="auto");var y=this.props,v=y.itemCount,C=y.layout,b=this.state.scrollOffset;p=Math.max(0,Math.min(p,v-1));var F=0;if(this._outerRef){var E=this._outerRef;C==="vertical"?F=E.scrollWidth>E.clientWidth?Os():0:F=E.scrollHeight>E.clientHeight?Os():0}this.scrollTo(i(this.props,p,f,b,this._instanceProps,F))},g.componentDidMount=function(){var p=this.props,f=p.direction,y=p.initialScrollOffset,v=p.layout;if(typeof y=="number"&&this._outerRef!=null){var C=this._outerRef;f==="horizontal"||v==="horizontal"?C.scrollLeft=y:C.scrollTop=y}this._callPropsCallbacks()},g.componentDidUpdate=function(){var p=this.props,f=p.direction,y=p.layout,v=this.state,C=v.scrollOffset,b=v.scrollUpdateWasRequested;if(b&&this._outerRef!=null){var F=this._outerRef;if(f==="horizontal"||y==="horizontal")if(f==="rtl")switch(Ns()){case"negative":F.scrollLeft=-C;break;case"positive-ascending":F.scrollLeft=C;break;default:var E=F.clientWidth,w=F.scrollWidth;F.scrollLeft=w-E-C;break}else F.scrollLeft=C;else F.scrollTop=C}this._callPropsCallbacks()},g.componentWillUnmount=function(){this._resetIsScrollingTimeoutId!==null&&Rs(this._resetIsScrollingTimeoutId)},g.render=function(){var p=this.props,f=p.children,y=p.className,v=p.direction,C=p.height,b=p.innerRef,F=p.innerElementType,E=p.innerTagName,w=p.itemCount,A=p.itemData,S=p.itemKey,m=S===void 0?pd:S,B=p.layout,_=p.outerElementType,P=p.outerTagName,T=p.style,$=p.useIsScrolling,H=p.width,j=this.state.isScrolling,q=v==="horizontal"||B==="horizontal",G=q?this._onScrollHorizontal:this._onScrollVertical,X=this._getRangeToRender(),O=X[0],M=X[1],R=[];if(w>0)for(var I=O;I<=M;I++)R.push(wi(f,{data:A,key:m(I,A),index:I,isScrolling:$?j:void 0,style:this._getItemStyle(I)}));var U=n(this.props,this._instanceProps);return wi(_||P||"div",{className:y,onScroll:G,ref:this._outerRefSetter,style:bt({position:"relative",height:C,width:H,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:v},T)},wi(F||E||"div",{children:R,ref:b,style:{height:q?"100%":U,pointerEvents:j?"none":void 0,width:q?U:"100%"}}))},g._callPropsCallbacks=function(){if(typeof this.props.onItemsRendered=="function"){var p=this.props.itemCount;if(p>0){var f=this._getRangeToRender(),y=f[0],v=f[1],C=f[2],b=f[3];this._callOnItemsRendered(y,v,C,b)}}if(typeof this.props.onScroll=="function"){var F=this.state,E=F.scrollDirection,w=F.scrollOffset,A=F.scrollUpdateWasRequested;this._callOnScroll(E,w,A)}},g._getRangeToRender=function(){var p=this.props,f=p.itemCount,y=p.overscanCount,v=this.state,C=v.isScrolling,b=v.scrollDirection,F=v.scrollOffset;if(f===0)return[0,0,0,0];var E=o(this.props,F,this._instanceProps),w=s(this.props,E,F,this._instanceProps),A=!C||b==="backward"?Math.max(1,y):1,S=!C||b==="forward"?Math.max(1,y):1;return[Math.max(0,E-A),Math.max(0,Math.min(f-1,w+S)),E,w]},d})(ef),t.defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},t}var vd=function(t,e){t.children,t.direction,t.height,t.layout,t.innerTagName,t.outerTagName,t.width,e.instance},xd=50,cn=function(t,e,n){var a=t,i=a.itemSize,o=n.itemMetadataMap,s=n.lastMeasuredIndex;if(e>s){var l=0;if(s>=0){var c=o[s];l=c.offset+c.size}for(var u=s+1;u<=e;u++){var h=i(u);o[u]={offset:l,size:h},l+=h}n.lastMeasuredIndex=e}return o[e]},gd=function(t,e,n){var a=e.itemMetadataMap,i=e.lastMeasuredIndex,o=i>0?a[i].offset:0;return o>=n?tu(t,e,i,0,n):md(t,e,Math.max(0,i),n)},tu=function(t,e,n,a,i){for(;a<=n;){var o=a+Math.floor((n-a)/2),s=cn(t,o,e).offset;if(s===i)return o;s<i?a=o+1:s>i&&(n=o-1)}return a>0?a-1:0},md=function(t,e,n,a){for(var i=t.itemCount,o=1;n<i&&cn(t,n,e).offset<a;)n+=o,o*=2;return tu(t,e,Math.min(n,i-1),Math.floor(n/2),a)},Ms=function(t,e){var n=t.itemCount,a=e.itemMetadataMap,i=e.estimatedItemSize,o=e.lastMeasuredIndex,s=0;if(o>=n&&(o=n-1),o>=0){var l=a[o];s=l.offset+l.size}var c=n-o-1,u=c*i;return s+u},yd=hd({getItemOffset:function(t,e,n){return cn(t,e,n).offset},getItemSize:function(t,e,n){return n.itemMetadataMap[e].size},getEstimatedTotalSize:Ms,getOffsetForIndexAndAlignment:function(t,e,n,a,i,o){var s=t.direction,l=t.height,c=t.layout,u=t.width,h=s==="horizontal"||c==="horizontal",d=h?u:l,g=cn(t,e,i),x=Ms(t,i),p=Math.max(0,Math.min(x-d,g.offset)),f=Math.max(0,g.offset-d+g.size+o);switch(n==="smart"&&(a>=f-d&&a<=p+d?n="auto":n="center"),n){case"start":return p;case"end":return f;case"center":return Math.round(f+(p-f)/2);case"auto":default:return a>=f&&a<=p?a:a<f?f:p}},getStartIndexForOffset:function(t,e,n){return gd(t,n,e)},getStopIndexForStartIndex:function(t,e,n,a){for(var i=t.direction,o=t.height,s=t.itemCount,l=t.layout,c=t.width,u=i==="horizontal"||l==="horizontal",h=u?c:o,d=cn(t,e,a),g=n+h,x=d.offset+d.size,p=e;p<s-1&&x<g;)p++,x+=cn(t,p,a).size;return p},initInstanceProps:function(t,e){var n=t,a=n.estimatedItemSize,i={itemMetadataMap:{},estimatedItemSize:a||xd,lastMeasuredIndex:-1};return e.resetAfterIndex=function(o,s){s===void 0&&(s=!0),i.lastMeasuredIndex=Math.min(i.lastMeasuredIndex,o-1),e._getItemStyleCache(-1),s&&e.forceUpdate()},i},shouldResetStyleCacheOnItemSizeChange:!1,validateProps:function(t){t.itemSize}});function Cd({isActive:r,isNew:t,isDisabled:e,data:n,eventsEmit:a,styles:i={},assistantList:o=[]}){const{messages:s}=pi(),[l,c]=le(!1),u=(i==null?void 0:i.colors)||{},h=Ke(()=>{const y=n==null?void 0:n.configId;if(!y||!o||o.length===0)return s.sidebar.noAssistant;const v=o.find(C=>String(C==null?void 0:C.id)===String(y));if(!v)return s.sidebar.noAssistant;if(v!=null&&v.name)return v.name;try{const C=typeof v.configJson=="string"?JSON.parse(v.configJson):v.configJson;return(C==null?void 0:C.config_name)||s.sidebar.noAssistant}catch{return s.sidebar.noAssistant}},[o,n==null?void 0:n.configId,s.sidebar.noAssistant]),d=[{key:"rename",icon:N(Zf,{size:12}),label:s.sidebar.rename,onClick:y=>{y.domEvent.stopPropagation(),a&&a("conversations:rename_icon_clicked",n)}},{key:"delete",icon:N(Jf,{size:12}),label:s.sidebar.delete,danger:!0,onClick:y=>{y.domEvent.stopPropagation(),a&&a("conversations:delete_icon_clicked",n)}}],g=r?u.activeItemBg||"#f0f4ff":l?u.itemHoverBg||"#f5f7fa":u.itemBg||"transparent",x=r?u.activeItemText||u.primary||"#0122ff":u.itemText||"#333",p=r?u.activeItemBorder||u.primary||"#0122ff":"transparent",f=y=>{const v=Ds(),C=Ds(y);return v.isSame(C,"day")?C.format("HH:mm"):C.format("MM-DD HH:mm")};return re("div",{className:"flex relative items-center justify-between mb-2 px-4 py-3 rounded-md transition-colors cursor-pointer select-none",onClick:()=>!e&&a&&a("conversation:item_click",n),onMouseEnter:()=>c(!0),onMouseLeave:()=>c(!1),style:{minHeight:48,background:g,color:x,border:`1px solid ${p}`,...i.item,opacity:e?.5:1},children:[re("div",{className:"flex flex-col gap-y-2 flex-1 min-w-0",children:[N("span",{className:"truncate text-sm max-w-[160px] font-medium",title:n.label||s.sidebar.unnamedSession,style:{color:x,fontSize:"14px",lineHeight:"1.4"},children:n.label||s.sidebar.unnamedSession}),re("div",{className:"flex items-center justify-between gap-2",children:[N("span",{className:"text-xs truncate flex-1",style:{color:r?u.activeItemTextSecondary||"#666":u.itemTextSecondary||"#666",fontSize:"12px",lineHeight:"1.3"},children:h}),n.gmtModified&&N("span",{className:"text-xs flex-shrink-0",style:{color:r?u.activeItemTextSecondary||"#999":u.itemTextSecondary||"#999",fontSize:"12px",lineHeight:"1.3"},children:f(n.gmtModified)})]})]}),!e&&l&&!t&&N("div",{className:"absolute top-2 right-3",children:N(df,{menu:{items:d},trigger:["click"],placement:"bottomRight",children:N(Xf,{size:16,className:"text-gray-600 hover:text-gray-800",style:{cursor:"pointer",color:r?u.activeItemTextSecondary||"#999":u.itemTextSecondary||"#999"},onClick:y=>y.stopPropagation()})})})]})}function bd(r,t=[{label:"\u5F53\u5929",dayPeriod:1}]){const e=new Date,n={other:[]};return r.forEach(a=>{const i=new Date(a.gmtModified),o=Math.floor((+e-+i)/(1e3*60*60*24));let s=!1;for(const l of t)if(o<=l.dayPeriod){n[l.label]||(n[l.label]=[]),n[l.label].push(a),s=!0;break}s||n.other.push(a)}),n}/*! @license Rematrix v0.2.2
32
+
33
+ Copyright 2018 Fisssion LLC.
34
+
35
+ Permission is hereby granted, free of charge, to any person obtaining a copy
36
+ of this software and associated documentation files (the "Software"), to deal
37
+ in the Software without restriction, including without limitation the rights
38
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
39
+ copies of the Software, and to permit persons to whom the Software is
40
+ furnished to do so, subject to the following conditions:
41
+
42
+ The above copyright notice and this permission notice shall be included in
43
+ all copies or substantial portions of the Software.
44
+
45
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
46
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
47
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
48
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
49
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
50
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
51
+ THE SOFTWARE.
52
+ */function to(r){if(r.constructor!==Array)throw new TypeError("Expected array.");if(r.length===16)return r;if(r.length===6){var t=Fn();return t[0]=r[0],t[1]=r[1],t[4]=r[2],t[5]=r[3],t[12]=r[4],t[13]=r[5],t}throw new RangeError("Expected array with either 6 or 16 values.")}function Fn(){for(var r=[],t=0;t<16;t++)t%5==0?r.push(1):r.push(0);return r}function Fd(r,t){for(var e=to(r),n=to(t),a=[],i=0;i<4;i++)for(var o=[e[i],e[i+4],e[i+8],e[i+12]],s=0;s<4;s++){var l=s*4,c=[n[l],n[l+1],n[l+2],n[l+3]],u=o[0]*c[0]+o[1]*c[1]+o[2]*c[2]+o[3]*c[3];a[i+l]=u}return a}function Ed(r){if(typeof r=="string"){var t=r.match(/matrix(3d)?\(([^)]+)\)/);if(t){var e=t[2].split(", ").map(parseFloat);return to(e)}}return Fn()}function Ad(r){var t=Fn();return t[0]=r,t}function wd(r){var t=Fn();return t[5]=r,t}function Sd(r){var t=Fn();return t[12]=r,t}function Bd(r){var t=Fn();return t[13]=r,t}var da=function(r){return typeof r=="number"},ru=function(r){return typeof r=="function"},nu=function(r){return Object.prototype.toString.call(r)==="[object Object]"},dn=function(r){return Array.prototype.slice.apply(r)},au=function(r){var t=r.reduce(function(e,n){return e[n]=(e[n]||0)+1,e},{});return Object.keys(t).filter(function(e){return t[e]>1})};function Or(r){return[].slice.call(arguments,1).forEach(function(t){if(t)for(var e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=t[e])}),r}var ro,no=function(r,t,e){return r+(t-r)*e},iu={__proto__:null,isNumber:da,isFunction:ru,isObject:nu,toArray:dn,getDuplicateValsAsStrings:au,assign:Or,tweenProp:no},ns="data-flip-id",as="data-inverse-flip-id",is="data-portal-key",_d="data-exit-container",ta={__proto__:null,DATA_FLIP_ID:ns,DATA_INVERSE_FLIP_ID:as,DATA_FLIP_CONFIG:"data-flip-config",DATA_PORTAL_KEY:is},ao={noWobble:{stiffness:200,damping:26},gentle:{stiffness:120,damping:14},veryGentle:{stiffness:130,damping:17},wobbly:{stiffness:180,damping:12},stiff:{stiffness:260,damping:26}},Ls=function(r){return nu(r)?r:Object.keys(ao).indexOf(r)>-1?ao[r]:{}};typeof window<"u"&&(ro=window.requestAnimationFrame);var Dd=ro=ro||function(r){window.setTimeout(r,1e3/60)},kd=Date.now(),Pd=typeof performance=="object"&&typeof performance.now=="function"?function(){return performance.now()}:function(){return Date.now()-kd};function ou(r,t){var e=r.indexOf(t);e!==-1&&r.splice(e,1)}var Id=(function(){function r(){}return r.prototype.run=function(){var t=this;Dd(function(){t.springSystem.loop(Pd())})},r})(),Pi=function(){this.position=0,this.velocity=0},Td=0,Xt=.001,Rd=(function(){function r(e){this._id="s"+Td++,this._springSystem=e,this.listeners=[],this._startValue=0,this._currentState=new Pi,this._displacementFromRestThreshold=.001,this._endValue=0,this._overshootClampingEnabled=!1,this._previousState=new Pi,this._restSpeedThreshold=.001,this._tempState=new Pi,this._timeAccumulator=0,this._wasAtRest=!0,this._cachedSpringConfig={}}var t=r.prototype;return t.getId=function(){return this._id},t.destroy=function(){this.listeners=[],this._springSystem.deregisterSpring(this)},t.setSpringConfig=function(e){return this._springConfig=e,this},t.getCurrentValue=function(){return this._currentState.position},t.getDisplacementDistanceForState=function(e){return Math.abs(this._endValue-e.position)},t.setEndValue=function(e){if(e===this._endValue)return this;if(this.prevEndValue=e,this._endValue===e&&this.isAtRest())return this;this._startValue=this.getCurrentValue(),this._endValue=e,this._springSystem.activateSpring(this.getId());for(var n=0,a=this.listeners.length;n<a;n++){var i=this.listeners[n].onSpringEndStateChange;i&&i(this)}return this},t.setVelocity=function(e){return e===this._currentState.velocity||(this._currentState.velocity=e,this._springSystem.activateSpring(this.getId())),this},t.setCurrentValue=function(e){this._startValue=e,this._currentState.position=e;for(var n=0,a=this.listeners.length;n<a;n++){var i=this.listeners[n];i.onSpringUpdate&&i.onSpringUpdate(this)}return this},t.setAtRest=function(){return this._endValue=this._currentState.position,this._tempState.position=this._currentState.position,this._currentState.velocity=0,this},t.setOvershootClampingEnabled=function(e){return this._overshootClampingEnabled=e,this},t.isOvershooting=function(){var e=this._startValue,n=this._endValue;return this._springConfig.tension>0&&(e<n&&this.getCurrentValue()>n||e>n&&this.getCurrentValue()<n)},t.advance=function(e,n){var a=this.isAtRest();if(!a||!this._wasAtRest){var i=n;n>.064&&(i=.064),this._timeAccumulator+=i;for(var o,s,l,c,u,h,d=this._springConfig.tension,g=this._springConfig.friction,x=this._currentState.position,p=this._currentState.velocity,f=this._tempState.position,y=this._tempState.velocity;this._timeAccumulator>=Xt;)this._timeAccumulator-=Xt,this._timeAccumulator<Xt&&(this._previousState.position=x,this._previousState.velocity=p),s=d*(this._endValue-f)-g*p,c=d*(this._endValue-(f=x+(o=p)*Xt*.5))-g*(y=p+s*Xt*.5),h=d*(this._endValue-(f=x+(l=y)*Xt*.5))-g*(y=p+c*Xt*.5),f=x+(u=y)*Xt,x+=1/6*(o+2*(l+u)+(y=p+h*Xt))*Xt,p+=1/6*(s+2*(c+h)+(d*(this._endValue-f)-g*y))*Xt;this._tempState.position=f,this._tempState.velocity=y,this._currentState.position=x,this._currentState.velocity=p,this._timeAccumulator>0&&this._interpolate(this._timeAccumulator/Xt),(this.isAtRest()||this._overshootClampingEnabled&&this.isOvershooting())&&(this._springConfig.tension>0?(this._startValue=this._endValue,this._currentState.position=this._endValue):(this._endValue=this._currentState.position,this._startValue=this._endValue),this.setVelocity(0),a=!0);var v=!1;this._wasAtRest&&(this._wasAtRest=!1,v=!0);var C=!1;a&&(this._wasAtRest=!0,C=!0),this.notifyPositionUpdated(v,C)}},t.notifyPositionUpdated=function(e,n){var a=this;this.listeners.filter(Boolean).forEach(function(i){e&&i.onSpringActivate&&!a._onActivateCalled&&(i.onSpringActivate(a),a._onActivateCalled=!0),i.onSpringUpdate&&i.onSpringUpdate(a),n&&i.onSpringAtRest&&i.onSpringAtRest(a)})},t.systemShouldAdvance=function(){return!this.isAtRest()||!this.wasAtRest()},t.wasAtRest=function(){return this._wasAtRest},t.isAtRest=function(){return Math.abs(this._currentState.velocity)<this._restSpeedThreshold&&(this.getDisplacementDistanceForState(this._currentState)<=this._displacementFromRestThreshold||this._springConfig.tension===0)},t._interpolate=function(e){this._currentState.position=this._currentState.position*e+this._previousState.position*(1-e),this._currentState.velocity=this._currentState.velocity*e+this._previousState.velocity*(1-e)},t.addListener=function(e){return this.listeners.push(e),this},t.addOneTimeListener=function(e){var n=this;return Object.keys(e).forEach(function(a){var i;e[a]=(i=e[a],function(){i.apply(void 0,[].slice.call(arguments)),n.removeListener(e)})}),this.listeners.push(e),this},t.removeListener=function(e){return ou(this.listeners,e),this},r})(),su=(function(){function r(e){this.looper=e||new Id,this.looper.springSystem=this,this.listeners=[],this._activeSprings=[],this._idleSpringIndices=[],this._isIdle=!0,this._lastTimeMillis=-1,this._springRegistry={}}var t=r.prototype;return t.createSpring=function(e,n){return this.createSpringWithConfig({tension:e,friction:n})},t.createSpringWithConfig=function(e){var n=new Rd(this);return this.registerSpring(n),n.setSpringConfig(e),n},t.getIsIdle=function(){return this._isIdle},t.registerSpring=function(e){this._springRegistry[e.getId()]=e},t.deregisterSpring=function(e){ou(this._activeSprings,e),delete this._springRegistry[e.getId()]},t.advance=function(e,n){for(var a=this;this._idleSpringIndices.length>0;)this._idleSpringIndices.pop();for(this._activeSprings.filter(Boolean).forEach(function(o){o.systemShouldAdvance()?o.advance(e/1e3,n/1e3):a._idleSpringIndices.push(a._activeSprings.indexOf(o))});this._idleSpringIndices.length>0;){var i=this._idleSpringIndices.pop();i>=0&&this._activeSprings.splice(i,1)}},t.loop=function(e){var n;this._lastTimeMillis===-1&&(this._lastTimeMillis=e-1);var a=e-this._lastTimeMillis;this._lastTimeMillis=e;var i=0,o=this.listeners.length;for(i=0;i<o;i++)(n=this.listeners[i]).onBeforeIntegrate&&n.onBeforeIntegrate(this);for(this.advance(e,a),this._activeSprings.length===0&&(this._isIdle=!0,this._lastTimeMillis=-1),i=0;i<o;i++)(n=this.listeners[i]).onAfterIntegrate&&n.onAfterIntegrate(this);this._isIdle||this.looper.run()},t.activateSpring=function(e){var n=this._springRegistry[e];this._activeSprings.indexOf(n)===-1&&this._activeSprings.push(n),this.getIsIdle()&&(this._isIdle=!1,this.looper.run())},r})(),Od=new su,cu=function(r){var t=r.springConfig,e=t.overshootClamping,n=r.getOnUpdateFunc,a=r.onAnimationEnd,i=r.onSpringActivate,o=Od.createSpring(t.stiffness,t.damping);o.setOvershootClampingEnabled(!!e);var s={onSpringActivate:i,onSpringAtRest:function(){o.destroy(),a()},onSpringUpdate:n({spring:o,onAnimationEnd:a})};return o.addListener(s),o},$s=function(r){var t=cu(r);return t.setEndValue(1),t},zs=function(r,t){if(t===void 0&&(t={}),r&&r.length){t.reverse&&r.reverse();var e,n=typeof(e=t.speed)!="number"?1.1:1+Math.min(Math.max(5*e,0),5),a=1/Math.max(Math.min(r.length,100),10),i=r.map(function(o,s){var l=o.getOnUpdateFunc;return o.getOnUpdateFunc=function(c){var u=l(c);return function(h){var d=h.getCurrentValue();(d=d<.01?0:d>.99?1:d)>=a&&i[s+1]&&i[s+1](Math.max(Math.min(d*n,1),0)),u(h)}},o}).map(function(o){var s=cu(o);if(s)return s.setEndValue.bind(s)}).filter(Boolean);i[0]&&i[0](1)}},Hs=function(r){return[0,1,4,5,12,13].map(function(t){return r[t]})},qs=function(r){return r.top<window.innerHeight&&r.bottom>0&&r.left<window.innerWidth&&r.right>0};function js(r){return JSON.parse(r.dataset.flipConfig||"{}")}var uu=function(r,t){var e;return Or(r,((e={})[t[0]]=t[1],e))},lu=function(r,t){return dn(t?document.querySelectorAll("["+is+'="'+t+'"]'):r.querySelectorAll("["+ns+"]"))},fu=function(r){return r.map(function(t){return[t,t.getBoundingClientRect()]})},Nd=function(r){var t=r.cachedOrderedFlipIds,e=t===void 0?[]:t,n=r.inProgressAnimations,a=n===void 0?{}:n,i=r.flippedElementPositionsBeforeUpdate,o=i===void 0?{}:i,s=r.flipCallbacks,l=s===void 0?{}:s,c=r.containerEl,u=r.applyTransformOrigin,h=r.spring,d=r.debug,g=r.portalKey,x=r.staggerConfig,p=x===void 0?{}:x,f=r.decisionData,y=f===void 0?{}:f,v=r.handleEnterUpdateDelete,C=r.onComplete,b=r.onStart;if(!window.matchMedia("(prefers-reduced-motion: reduce)").matches){var F,E=fu(lu((F={element:c,portalKey:g}).element,F.portalKey)).map(function(q){var G=q[0],X=q[1],O=window.getComputedStyle(G);return[G.dataset.flipId,{element:G,rect:X,opacity:parseFloat(O.opacity),transform:O.transform}]}).reduce(uu,{}),w=(function(q){var G=q.containerEl,X=q.portalKey;return X?(function(O){return function(M){return dn(document.querySelectorAll("["+is+'="'+O+'"]'+M))}})(X):G?(function(O){var M=Math.random().toFixed(5);return O.dataset.flipperId=M,function(R){return dn(O.querySelectorAll('[data-flipper-id="'+M+'"] '+R))}})(G):function(){return[]}})({containerEl:c,portalKey:g}),A=(function(q){return function(G){return q("["+ns+'="'+G+'"]')[0]}})(w),S=function(q){return o[q]&&E[q]},m=Object.keys(o).concat(Object.keys(E)).filter(function(q){return!S(q)}),B={flipCallbacks:l,getElement:A,flippedElementPositionsBeforeUpdate:o,flippedElementPositionsAfterUpdate:E,inProgressAnimations:a,decisionData:y},_=(function(q){var G,X=q.unflippedIds,O=q.flipCallbacks,M=q.getElement,R=q.flippedElementPositionsBeforeUpdate,I=q.flippedElementPositionsAfterUpdate,U=q.inProgressAnimations,K=q.decisionData,Z=X.filter(function(ie){return I[ie]}).filter(function(ie){return O[ie]&&O[ie].onAppear}),Q=X.filter(function(ie){return R[ie]&&O[ie]&&O[ie].onExit}),J=new Promise(function(ie){G=ie}),pe=[],Ie=0,Se=Q.map(function(ie,Ae){var Ne=R[ie].domDataForExitAnimations,he=Ne.element,it=Ne.parent,et=Ne.childPosition,tt=et.top,st=et.left,Fe=et.width,ye=et.height;getComputedStyle(it).position==="static"&&(it.style.position="relative"),he.style.transform="matrix(1, 0, 0, 1, 0, 0)",he.style.position="absolute",he.style.top=tt+"px",he.style.left=st+"px",he.style.height=ye+"px",he.style.width=Fe+"px";var ke=pe.filter(function(ze){return ze[0]===it})[0];ke||(ke=[it,document.createDocumentFragment()],pe.push(ke)),ke[1].appendChild(he),Ie+=1;var Me=function(){try{it.removeChild(he)}catch{}finally{(Ie-=1)==0&&G()}};return U[ie]={stop:Me},function(){return O[ie].onExit(he,Ae,Me,K)}});return pe.forEach(function(ie){ie[0].appendChild(ie[1])}),Se.length||G(),{hideEnteringElements:function(){Z.forEach(function(ie){var Ae=M(ie);Ae&&(Ae.style.opacity="0")})},animateEnteringElements:function(){Z.forEach(function(ie,Ae){var Ne=M(ie);Ne&&O[ie].onAppear(Ne,Ae,K)})},animateExitingElements:function(){return Se.forEach(function(ie){return ie()}),J}}})(Or({},B,{unflippedIds:m})),P=_.hideEnteringElements,T=_.animateEnteringElements,$=_.animateExitingElements,H=Or({},B,{containerEl:c,flippedIds:e.filter(S),applyTransformOrigin:u,spring:h,debug:d,staggerConfig:p,scopedSelector:w,onComplete:C});b&&b(c,y);var j=(function(q){var G,X=q.flippedIds,O=q.flipCallbacks,M=q.inProgressAnimations,R=q.flippedElementPositionsBeforeUpdate,I=q.flippedElementPositionsAfterUpdate,U=q.applyTransformOrigin,K=q.spring,Z=q.getElement,Q=q.debug,J=q.staggerConfig,pe=J===void 0?{}:J,Ie=q.decisionData,Se=Ie===void 0?{}:Ie,ie=q.onComplete,Ae=q.containerEl,Ne=new Promise(function(ee){G=ee});if(ie&&Ne.then(function(){return ie(Ae,Se)}),!X.length)return function(){return G([]),Ne};var he=[],it=Z(X[0]),et=it?it.ownerDocument.querySelector("body"):document.querySelector("body");au(X);var tt=X.map(function(ee){var Ce=R[ee].rect,ot=I[ee].rect,Dt=R[ee].opacity,kt=I[ee].opacity,Lt=ot.width<1||ot.height<1,Re=I[ee].element;if(!qs(Ce)&&!qs(ot)||!Re)return!1;var $t,fr,Br,Pt=js(Re),br=(Br=(fr=($t={flipperSpring:K,flippedSpring:Pt.spring})===void 0?{}:$t).flippedSpring,Or({},ao.noWobble,Ls(fr.flipperSpring),Ls(Br))),dr=Pt.stagger===!0?"default":Pt.stagger,$r={element:Re,id:ee,stagger:dr,springConfig:br};if(O[ee]&&O[ee].shouldFlip&&!O[ee].shouldFlip(Se.previous,Se.current))return!1;var pr=Math.abs(Ce.left-ot.left)+Math.abs(Ce.top-ot.top),zr=Math.abs(Ce.width-ot.width)+Math.abs(Ce.height-ot.height),_r=Math.abs(kt-Dt);if(Ce.height===0&&ot.height===0||Ce.width===0&&ot.width===0||pr<.5&&zr<.5&&_r<.01)return!1;var Hr=Ed(I[ee].transform),zt={matrix:Hr},Et={matrix:[]},It=[Hr];Pt.translate&&(It.push(Sd(Ce.left-ot.left)),It.push(Bd(Ce.top-ot.top))),Pt.scale&&(It.push(Ad(Math.max(Ce.width,1)/Math.max(ot.width,1))),It.push(wd(Math.max(Ce.height,1)/Math.max(ot.height,1)))),Pt.opacity&&(Et.opacity=Dt,zt.opacity=kt);var Ht=[];if(!O[ee]||!O[ee].shouldInvert||O[ee].shouldInvert(Se.previous,Se.current)){var er=(function(be,nt){return dn(be.querySelectorAll("["+as+'="'+nt+'"]'))})(Re,ee);Ht=er.map(function(be){return[be,js(be)]})}Et.matrix=Hs(It.reduce(Fd)),zt.matrix=Hs(zt.matrix);var Gt,Qe=(function(be){var nt=be.element,tr=be.invertedChildren,Oe=be.body;return function(He){var dt=He.matrix,vt=He.opacity,rr=He.forceMinVals;if(da(vt)&&(nt.style.opacity=vt+""),rr&&(nt.style.minHeight="1px",nt.style.minWidth="1px"),dt){var Yr=(function(qt){return"matrix("+qt.join(", ")+")"})(dt);nt.style.transform=Yr,tr&&(function(qt){var hr=qt.matrix,Qr=qt.body;qt.invertedChildren.forEach(function(Zr){var Jr=Zr[0],Nt=Zr[1];if(Qr.contains(Jr)){var Yn=hr[0],Qn=hr[3],Ai=hr[5],vr={translateX:0,translateY:0,scaleX:1,scaleY:1},Dr="";Nt.translate&&(vr.translateX=-hr[4]/Yn,vr.translateY=-Ai/Qn,Dr+="translate("+vr.translateX+"px, "+vr.translateY+"px)"),Nt.scale&&(vr.scaleX=1/Yn,vr.scaleY=1/Qn,Dr+=" scale("+vr.scaleX+", "+vr.scaleY+")"),Jr.style.transform=Dr}})})({invertedChildren:tr,matrix:dt,body:Oe})}}})({element:Re,invertedChildren:Ht,body:et});if(O[ee]&&O[ee].onComplete){var se=O[ee].onComplete;Gt=function(){return se(Re,Se)}}var rt=da(Et.opacity)&&da(zt.opacity)&&Et.opacity!==zt.opacity,At=!1;return Or({},$r,{stagger:dr,springConfig:br,getOnUpdateFunc:function(be){var nt=be.spring,tr=be.onAnimationEnd;return M[ee]={destroy:nt.destroy.bind(nt),onAnimationEnd:tr},function(Oe){O[ee]&&O[ee].onSpringUpdate&&O[ee].onSpringUpdate(Oe.getCurrentValue()),At||(At=!0,O[ee]&&O[ee].onStart&&O[ee].onStart(Re,Se));var He=Oe.getCurrentValue();if(et.contains(Re)){var dt={matrix:[]};dt.matrix=Et.matrix.map(function(vt,rr){return no(vt,zt.matrix[rr],He)}),rt&&(dt.opacity=no(Et.opacity,zt.opacity,He)),Qe(dt)}else Oe.destroy()}},initializeFlip:function(){Qe({matrix:Et.matrix,opacity:rt?Et.opacity:void 0,forceMinVals:Lt}),O[ee]&&O[ee].onStartImmediate&&O[ee].onStartImmediate(Re,Se),Pt.transformOrigin?Re.style.transformOrigin=Pt.transformOrigin:U&&(Re.style.transformOrigin="0 0"),Ht.forEach(function(be){var nt=be[0],tr=be[1];tr.transformOrigin?nt.style.transformOrigin=tr.transformOrigin:U&&(nt.style.transformOrigin="0 0")})},onAnimationEnd:function(be){delete M[ee],ru(Gt)&&Gt(),Re.style.transform="",Ht.forEach(function(nt){nt[0].style.transform=""}),Lt&&Re&&(Re.style.minHeight="",Re.style.minWidth=""),be||(he.push(ee),he.length>=tt.length&&G(he))},delayUntil:Pt.delayUntil})}).filter(Boolean);if(tt.forEach(function(ee){return(0,ee.initializeFlip)()}),Q)return function(){};var st=tt.filter(function(ee){return ee.delayUntil&&(Ce=ee.delayUntil,tt.filter(function(ot){return ot.id===Ce}).length);var Ce}),Fe={},ye={},ke={};st.forEach(function(ee){ee.stagger?(ke[ee.stagger]=!0,ye[ee.delayUntil]?ye[ee.delayUntil].push(ee.stagger):ye[ee.delayUntil]=[ee.stagger]):Fe[ee.delayUntil]?Fe[ee.delayUntil].push(ee):Fe[ee.delayUntil]=[ee]});var Me=tt.filter(function(ee){return ee.stagger}).reduce(function(ee,Ce){return ee[Ce.stagger]?ee[Ce.stagger].push(Ce):ee[Ce.stagger]=[Ce],ee},{}),ze=tt.filter(function(ee){return st.indexOf(ee)===-1});return ze.forEach(function(ee){ee.onSpringActivate=function(){Fe[ee.id]&&Fe[ee.id].forEach($s),ye[ee.id]&&Object.keys(ye[ee.id].reduce(function(Ce,ot){var Dt;return Or(Ce,((Dt={})[ot]=!0,Dt))},{})).forEach(function(Ce){zs(Me[Ce],pe[Ce])})}}),function(){return tt.length||G([]),ze.filter(function(ee){return!ee.stagger}).forEach($s),Object.keys(Me).forEach(function(ee){ke[ee]||zs(Me[ee],pe[ee])}),Ne}})(H);v?v({hideEnteringElements:P,animateEnteringElements:T,animateExitingElements:$,animateFlippedElements:j}):(P(),$().then(T),j())}},Md=function(r){var t=r.element,e=r.flipCallbacks,n=e===void 0?{}:e,a=r.inProgressAnimations,i=a===void 0?{}:a,o=lu(t,r.portalKey),s=dn(t.querySelectorAll("["+as+"]")),l={},c=[],u={};o.filter(function(g){return n&&n[g.dataset.flipId]&&n[g.dataset.flipId].onExit}).forEach(function(g){var x=g.parentNode;if(g.closest){var p=g.closest("["+_d+"]");p&&(x=p)}var f=c.findIndex(function(y){return y[0]===x});f===-1&&(c.push([x,x.getBoundingClientRect()]),f=c.length-1),l[g.dataset.flipId]=c[f][1],u[g.dataset.flipId]=x});var h=fu(o),d=h.map(function(g){var x=g[0],p=g[1],f={};if(n&&n[x.dataset.flipId]&&n[x.dataset.flipId].onExit){var y=l[x.dataset.flipId];Or(f,{element:x,parent:u[x.dataset.flipId],childPosition:{top:p.top-y.top,left:p.left-y.left,width:p.width,height:p.height}})}return[x.dataset.flipId,{rect:p,opacity:parseFloat(window.getComputedStyle(x).opacity||"1"),domDataForExitAnimations:f}]}).reduce(uu,{});return(function(g,x){Object.keys(g).forEach(function(p){g[p].destroy&&g[p].destroy(),g[p].onAnimationEnd&&g[p].onAnimationEnd(!0),delete g[p]}),x.forEach(function(p){p.style.transform="",p.style.opacity=""})})(i,o.concat(s)),{flippedElementPositions:d,cachedOrderedFlipIds:h.map(function(g){return g[0].dataset.flipId})}};new su;function ai(){return ai=Object.assign?Object.assign.bind():function(r){for(var t=1;t<arguments.length;t++){var e=arguments[t];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n])}return r},ai.apply(this,arguments)}function io(r,t){return io=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,n){return e.__proto__=n,e},io(r,t)}function du(r,t){if(r==null)return{};var e,n,a={},i=Object.keys(r);for(n=0;n<i.length;n++)t.indexOf(e=i[n])>=0||(a[e]=r[e]);return a}var pu=Un({}),hu=Un("portal"),vu=(function(r){var t,e;function n(){for(var i,o=arguments.length,s=new Array(o),l=0;l<o;l++)s[l]=arguments[l];return(i=r.call.apply(r,[this].concat(s))||this).inProgressAnimations={},i.flipCallbacks={},i.el=void 0,i}e=r,(t=n).prototype=Object.create(e.prototype),t.prototype.constructor=t,io(t,e);var a=n.prototype;return a.getSnapshotBeforeUpdate=function(i){return i.flipKey!==this.props.flipKey&&this.el?Md({element:this.el,flipCallbacks:this.flipCallbacks,inProgressAnimations:this.inProgressAnimations,portalKey:this.props.portalKey}):null},a.componentDidUpdate=function(i,o,s){this.props.flipKey!==i.flipKey&&this.el&&Nd({flippedElementPositionsBeforeUpdate:s.flippedElementPositions,cachedOrderedFlipIds:s.cachedOrderedFlipIds,containerEl:this.el,inProgressAnimations:this.inProgressAnimations,flipCallbacks:this.flipCallbacks,applyTransformOrigin:this.props.applyTransformOrigin,spring:this.props.spring,debug:this.props.debug,portalKey:this.props.portalKey,staggerConfig:this.props.staggerConfig,handleEnterUpdateDelete:this.props.handleEnterUpdateDelete,decisionData:{previous:i.decisionData,current:this.props.decisionData},onComplete:this.props.onComplete,onStart:this.props.onStart})},a.render=function(){var i=this,o=this.props,s=o.portalKey,l=ve.createElement(pu.Provider,{value:this.flipCallbacks},ve.createElement(o.element,{className:o.className,ref:function(c){return i.el=c}},this.props.children));return s&&(l=ve.createElement(hu.Provider,{value:s},l)),l},n})(nf);vu.defaultProps={applyTransformOrigin:!0,element:"div"};var Ld=["children","flipId","inverseFlipId","portalKey"],$d=["children","flipId","shouldFlip","shouldInvert","onAppear","onStart","onStartImmediate","onComplete","onExit","onSpringUpdate"],Vs=function(r){var t,e=r.children,n=r.flipId,a=r.inverseFlipId,i=r.portalKey,o=du(r,Ld),s=e,l=(function(u){return typeof u=="function"})(s);if(!l)try{s=tf.only(e)}catch{throw new Error("Each Flipped component must wrap a single child")}o.scale||o.translate||o.opacity||iu.assign(o,{translate:!0,scale:!0,opacity:!0});var c=((t={})[ta.DATA_FLIP_CONFIG]=JSON.stringify(o),t);return n!==void 0?c[ta.DATA_FLIP_ID]=String(n):a&&(c[ta.DATA_INVERSE_FLIP_ID]=String(a)),i!==void 0&&(c[ta.DATA_PORTAL_KEY]=i),l?s(c):rf(s,c)},xu=function(r){var t=r.children,e=r.flipId,n=r.shouldFlip,a=r.shouldInvert,i=r.onAppear,o=r.onStart,s=r.onStartImmediate,l=r.onComplete,c=r.onExit,u=r.onSpringUpdate,h=du(r,$d);return t?h.inverseFlipId?ve.createElement(Vs,ai({},h),t):ve.createElement(hu.Consumer,null,function(d){return ve.createElement(pu.Consumer,null,function(g){return iu.isObject(g)&&e&&(g[e]={shouldFlip:n,shouldInvert:a,onAppear:i,onStart:o,onStartImmediate:s,onComplete:l,onExit:c,onSpringUpdate:u}),ve.createElement(Vs,ai({flipId:e},h,{portalKey:d}),t)})}):null};xu.displayName="Flipped";function zd(r){const{data:t,activedItem:e,onChange:n,onDelete:a,sortRules:i=[{label:"\u5F53\u5929",dayPeriod:1}],eventsEmit:o,assistantList:s,height:l=400,styles:c={},hasMore:u=!1,loadingMore:h=!1}=r,d=t.map(S=>S.sessionId+"-"+S.gmtModified).join(","),g=Ke(()=>{const S=i.length>0?i:[{label:"\u5F53\u5929",dayPeriod:1}],m=bd(t,S),B=S.every(P=>!m[P.label]||m[P.label].length===0),_=[];return S.forEach(P=>{m[P.label]&&m[P.label].length>0&&(_.push({type:"group",label:P.label}),m[P.label].forEach(T=>_.push({type:"item",data:T})))}),m.other.length>0&&!B&&(_.push({type:"group",label:"\u5176\u4ED6"}),m.other.forEach(P=>_.push({type:"item",data:P}))),B&&m.other.length>0&&m.other.forEach(P=>_.push({type:"item",data:P})),_},[t,i,d]),x=Ke(()=>g.map(S=>S.type==="group"?`g:${S.label}`:`i:${S.data.sessionId}`).join("|"),[g]),p=56,f=14,y=36,v=S=>S===g.length?y:g[S].type==="group"?32:p+f,C=Ve(null),b=Ke(()=>g.findIndex(S=>{var m;return S.type==="item"&&((m=S.data)==null?void 0:m.sessionId)===e}),[g,e]),F=Ke(()=>g.findIndex(S=>S.type==="item"),[g]),E=Ve(void 0);De(()=>{const S=E.current;e!==S&&b>-1&&b===F&&C.current&&C.current.scrollToItem(b,"start"),E.current=e},[e,b,F]);const w=Ve(0);if(De(()=>{if(C.current){const S=w.current,m=g.length;if(w.current=m,m!==S){const _=(S>0?Math.abs(m-S)/S:1)>.5||S<10&&m>20;C.current.resetAfterIndex(0,_)}}},[g.length]),De(()=>{C.current&&C.current.resetAfterIndex(0,!0)},[x]),g.length===0)return N("div",{className:"text-center text-zinc-400 py-8",children:"\u6682\u65E0\u4F1A\u8BDD"});const A=(c==null?void 0:c.colors)||{};return N(vu,{flipKey:d,spring:{stiffness:180,damping:18},children:N(yd,{ref:C,height:l,width:"100%",itemCount:g.length+1,itemSize:v,itemKey:S=>{if(S===g.length)return"footer";const m=g[S];return m.type==="item"?m.data.sessionId:`group-${m.label}`},onItemsRendered:({visibleStopIndex:S})=>{u&&!h&&S>=g.length-1-3&&typeof o=="function"&&o("conversations:load_more")},style:{overflowX:"hidden"},children:({index:S,style:m})=>{if(S===g.length){const _=(c==null?void 0:c.colors)||{};return N("div",{style:{...m,height:y,lineHeight:`${y}px`,textAlign:"center",fontSize:"10px",color:_.textMuted||"#9ca3af",background:_.groupBg||"white"},children:h?"\u52A0\u8F7D\u4E2D...":u?"":"\u6CA1\u6709\u66F4\u591A\u4E86"})}const B=g[S];return B.type==="group"?N("div",{style:{...m,background:A.groupBg||"white",zIndex:1},className:"pt-2 pb-1 px-[28px] py-[2px] text-xs text-gray-400",children:B.label}):N(xu,{flipId:B.data.sessionId,children:N("div",{style:m,className:"px-[12px] py-[2px]",children:N(Cd,{isActive:e===B.data.sessionId,isDisabled:!1,isNew:B.data.isNew,data:B.data,eventsEmit:o,assistantList:s,styles:c})})},B.data.sessionId)}})})}const Hd=({value:r,eventsEmit:t,setSearch:e,style:n,styles:a={}})=>{const{messages:i}=pi(),o=a.colors||{},s=a.radius||"12px",l=o.border||"#e5e7eb",c=o.primary||"#2563eb",u=a.headerBg||o.sidebarBg||o.background||"#fff",[h,d]=ve.useState(!1),g=ve.useRef(null);ve.useEffect(()=>{h&&g.current&&g.current.focus()},[h]);const x=()=>{d(!1),e("")};return re("div",{className:"flex items-center gap-2 px-4 py-3 sticky top-0 z-10 min-w-0",style:{...n,background:u,borderTopLeftRadius:s,borderTopRightRadius:s},children:[N("button",{className:"border-none flex items-center justify-center",onClick:()=>{d(!1),t&&t("conversation:create")},title:i.sidebar.newConversation,style:{height:42,borderRadius:"90px",background:c,color:o.buttonText||"#fff",fontWeight:600,boxShadow:a.shadow||"0 2px 8px 0 rgba(0,0,0,0.04)",padding:h?"0 0":"0 14px",minWidth:h?0:180,width:h?0:void 0,opacity:h?0:1,overflow:"hidden",flexShrink:0,transition:"width .22s ease, min-width .22s ease, padding .22s ease, opacity .18s ease",pointerEvents:h?"none":"auto"},children:re("div",{className:"flex items-center gap-2",children:[N(Cf,{size:18}),N("span",{className:"text-sm",children:i.sidebar.newChat})]})}),h?re("div",{className:"flex-1 min-w-0 relative",children:[N("input",{ref:g,className:"w-full px-3 py-2 pr-10 text-sm transition-all",placeholder:i.sidebar.searchPlaceholder,value:r,onChange:p=>e(p.target.value),onKeyDown:p=>{p.key==="Escape"&&x()},style:{minWidth:0,width:"100%",borderRadius:s,background:o.inputBg||"#f4f4f5",border:`1px solid ${l}`,color:o.text||"#222",outline:"none",paddingRight:40}}),N("button",{className:"absolute right-3 flex items-center justify-center transition-colors hover:bg-gray-200 rounded-full",style:{width:20,height:20,color:o.text||"#666",flexShrink:0,position:"absolute",right:"12px",top:"9px"},onClick:x,title:"\u5173\u95ED\u641C\u7D22",onMouseDown:p=>p.preventDefault(),children:N(Wc,{size:16})})]}):N("button",{className:"ml-auto flex items-center justify-center transition-colors hover:bg-gray-50",style:{width:36,height:36,borderRadius:"90px",border:`1px solid ${l}`,color:c,flexShrink:0},onClick:()=>d(!0),title:i.sidebar.search,children:N(Qi,{size:18})})]})};function qd(r){const{data:t,sortRules:e,activedItem:n,eventsEmit:a,assistantList:i,styles:o={},hasMore:s=!1,loadingMore:l=!1}=r,{messages:c}=pi(),[u,h]=le(""),d=Ke(()=>u?t.filter(E=>(E.label||c.sidebar.unnamedSession).toLowerCase().includes(u.toLowerCase())):t,[t,u,c.sidebar.unnamedSession]),g=Ke(()=>[...d].sort((E,w)=>new Date(w.gmtModified).getTime()-new Date(E.gmtModified).getTime()),[d]),x=Ve(null),[p,f]=le(400);De(()=>{function E(){x.current&&f(x.current.clientHeight)}return E(),window.addEventListener("resize",E),()=>window.removeEventListener("resize",E)},[]);const y=(o==null?void 0:o.colors)||{};o!=null&&o.radius;const v=(o==null?void 0:o.shadow)||"0 4px 24px 0 rgba(0,0,0,0.06)",C=y.border||"#e5e7eb",b=y.sidebarBg||y.background||"#EAEEFF",F=y.text||"#222";return re("div",{className:"h-full flex flex-col overflow-y-hidden",style:{background:b,color:F,boxShadow:v,border:`1px solid ${C}`,...o.container},children:[N(Hd,{value:u,setSearch:h,eventsEmit:a,style:o.header,styles:o}),re("div",{className:"flex-1 min-h-0 relative",ref:x,style:o.list,children:[N(zd,{eventsEmit:a,data:g,assistantList:i,activedItem:n,sortRules:e,height:p,styles:o,hasMore:s,loadingMore:l}),N("div",{className:"pointer-events-none absolute left-0 right-0 top-0 h-3 z-20",style:{background:`linear-gradient(to bottom, ${b}cc, transparent)`}})]})]})}function oo(r,t){(t==null||t>r.length)&&(t=r.length);for(var e=0,n=Array(t);e<t;e++)n[e]=r[e];return n}function jd(r){if(Array.isArray(r))return oo(r)}function gu(r){if(typeof Symbol<"u"&&r[Symbol.iterator]!=null||r["@@iterator"]!=null)return Array.from(r)}function os(r,t){if(r){if(typeof r=="string")return oo(r,t);var e={}.toString.call(r).slice(8,-1);return e==="Object"&&r.constructor&&(e=r.constructor.name),e==="Map"||e==="Set"?Array.from(r):e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?oo(r,t):void 0}}function Vd(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
53
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fe(r){return jd(r)||gu(r)||os(r)||Vd()}const Ud=ve.createContext({});function mu(r){if(Array.isArray(r))return r}function Wd(r,t){var e=r==null?null:typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(e!=null){var n,a,i,o,s=[],l=!0,c=!1;try{if(i=(e=e.call(r)).next,t===0){if(Object(e)!==e)return;l=!1}else for(;!(l=(n=i.call(e)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(u){c=!0,a=u}finally{try{if(!l&&e.return!=null&&(o=e.return(),Object(o)!==o))return}finally{if(c)throw a}}return s}}function yu(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
54
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ce(r,t){return mu(r)||Wd(r,t)||os(r,t)||yu()}function ge(r){"@babel/helpers - typeof";return ge=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ge(r)}function Gd(r,t){if(ge(r)!="object"||!r)return r;var e=r[Symbol.toPrimitive];if(e!==void 0){var n=e.call(r,t);if(ge(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(r)}function Cu(r){var t=Gd(r,"string");return ge(t)=="symbol"?t:t+""}function z(r,t,e){return(t=Cu(t))in r?Object.defineProperty(r,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):r[t]=e,r}function Us(r,t){var e=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),e.push.apply(e,n)}return e}function Y(r){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?arguments[t]:{};t%2?Us(Object(e),!0).forEach(function(n){z(r,n,e[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(e)):Us(Object(e)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(e,n))})}return r}function Nn(r){for(var t=0,e,n=0,a=r.length;a>=4;++n,a-=4)e=r.charCodeAt(n)&255|(r.charCodeAt(++n)&255)<<8|(r.charCodeAt(++n)&255)<<16|(r.charCodeAt(++n)&255)<<24,e=(e&65535)*1540483477+((e>>>16)*59797<<16),e^=e>>>24,t=(e&65535)*1540483477+((e>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(a){case 3:t^=(r.charCodeAt(n+2)&255)<<16;case 2:t^=(r.charCodeAt(n+1)&255)<<8;case 1:t^=r.charCodeAt(n)&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)}function wr(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function Kd(r,t){if(!r)return!1;if(r.contains)return r.contains(t);for(var e=t;e;){if(e===r)return!0;e=e.parentNode}return!1}var Ws="data-rc-order",Gs="data-rc-priority",Xd="rc-util-key",so=new Map;function bu(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=r.mark;return t?t.startsWith("data-")?t:"data-".concat(t):Xd}function hi(r){if(r.attachTo)return r.attachTo;var t=document.querySelector("head");return t||document.body}function Yd(r){return r==="queue"?"prependQueue":r?"prepend":"append"}function ss(r){return Array.from((so.get(r)||r).children).filter(function(t){return t.tagName==="STYLE"})}function Fu(r){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!wr())return null;var e=t.csp,n=t.prepend,a=t.priority,i=a===void 0?0:a,o=Yd(n),s=o==="prependQueue",l=document.createElement("style");l.setAttribute(Ws,o),s&&i&&l.setAttribute(Gs,"".concat(i)),e!=null&&e.nonce&&(l.nonce=e==null?void 0:e.nonce),l.innerHTML=r;var c=hi(t),u=c.firstChild;if(n){if(s){var h=(t.styles||ss(c)).filter(function(d){if(!["prepend","prependQueue"].includes(d.getAttribute(Ws)))return!1;var g=Number(d.getAttribute(Gs)||0);return i>=g});if(h.length)return c.insertBefore(l,h[h.length-1].nextSibling),l}c.insertBefore(l,u)}else c.appendChild(l);return l}function Eu(r){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=hi(t);return(t.styles||ss(e)).find(function(n){return n.getAttribute(bu(t))===r})}function Au(r){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=Eu(r,t);if(e){var n=hi(t);n.removeChild(e)}}function Qd(r,t){var e=so.get(r);if(!e||!Kd(document,e)){var n=Fu("",t),a=n.parentNode;so.set(r,a),r.removeChild(n)}}function Ur(r,t){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=hi(e),a=ss(n),i=Y(Y({},e),{},{styles:a});Qd(n,i);var o=Eu(t,i);if(o){var s,l;if((s=i.csp)!==null&&s!==void 0&&s.nonce&&o.nonce!==((l=i.csp)===null||l===void 0?void 0:l.nonce)){var c;o.nonce=(c=i.csp)===null||c===void 0?void 0:c.nonce}return o.innerHTML!==r&&(o.innerHTML=r),o}var u=Fu(r,i);return u.setAttribute(bu(i),t),u}function Cr(r,t){if(r==null)return{};var e,n,a=ud(r,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(r);for(n=0;n<i.length;n++)e=i[n],t.indexOf(e)===-1&&{}.propertyIsEnumerable.call(r,e)&&(a[e]=r[e])}return a}function wu(r,t,e){var n=L.useRef({});return(!("value"in n.current)||e(n.current.condition,t))&&(n.current.value=r(),n.current.condition=t),n.current.value}var co={},Zd=function(t){};function Jd(r,t){}function ep(r,t){}function tp(){co={}}function Su(r,t,e){!t&&!co[e]&&(r(!1,e),co[e]=!0)}function Wt(r,t){Su(Jd,r,t)}function rp(r,t){Su(ep,r,t)}Wt.preMessage=Zd;Wt.resetWarned=tp;Wt.noteOnce=rp;function uo(r,t){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=new Set;function a(i,o){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,l=n.has(i);if(Wt(!l,"Warning: There may be circular references"),l)return!1;if(i===o)return!0;if(e&&s>1)return!1;n.add(i);var c=s+1;if(Array.isArray(i)){if(!Array.isArray(o)||i.length!==o.length)return!1;for(var u=0;u<i.length;u++)if(!a(i[u],o[u],c))return!1;return!0}if(i&&o&&ge(i)==="object"&&ge(o)==="object"){var h=Object.keys(i);return h.length!==Object.keys(o).length?!1:h.every(function(d){return a(i[d],o[d],c)})}return!1}return a(r,t)}function Rt(r,t){if(!(r instanceof t))throw new TypeError("Cannot call a class as a function")}function Ks(r,t){for(var e=0;e<t.length;e++){var n=t[e];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,Cu(n.key),n)}}function Ot(r,t,e){return t&&Ks(r.prototype,t),e&&Ks(r,e),Object.defineProperty(r,"prototype",{writable:!1}),r}var np="%";function lo(r){return r.join(np)}var ap=(function(){function r(t){Rt(this,r),z(this,"instanceId",void 0),z(this,"cache",new Map),z(this,"extracted",new Set),this.instanceId=t}return Ot(r,[{key:"get",value:function(e){return this.opGet(lo(e))}},{key:"opGet",value:function(e){return this.cache.get(e)||null}},{key:"update",value:function(e,n){return this.opUpdate(lo(e),n)}},{key:"opUpdate",value:function(e,n){var a=this.cache.get(e),i=n(a);i===null?this.cache.delete(e):this.cache.set(e,i)}}]),r})(),gn="data-token-hash",sr="data-css-hash",Nr="__cssinjs_instance__";function ip(){var r=Math.random().toString(12).slice(2);if(typeof document<"u"&&document.head&&document.body){var t=document.body.querySelectorAll("style[".concat(sr,"]"))||[],e=document.head.firstChild;Array.from(t).forEach(function(a){a[Nr]=a[Nr]||r,a[Nr]===r&&document.head.insertBefore(a,e)});var n={};Array.from(document.querySelectorAll("style[".concat(sr,"]"))).forEach(function(a){var i=a.getAttribute(sr);if(n[i]){if(a[Nr]===r){var o;(o=a.parentNode)===null||o===void 0||o.removeChild(a)}}else n[i]=!0})}return new ap(r)}var Wn=L.createContext({hashPriority:"low",cache:ip(),defaultCache:!0});function En(r,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(t&&t.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),t&&xn(r,t)}function Mn(r){return Mn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Mn(r)}function cs(){try{var r=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(cs=function(){return!!r})()}function op(r,t){if(t&&(ge(t)=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return we(r)}function An(r){var t=cs();return function(){var e,n=Mn(r);if(t){var a=Mn(this).constructor;e=Reflect.construct(n,arguments,a)}else e=n.apply(this,arguments);return op(this,e)}}function sp(r,t){if(r.length!==t.length)return!1;for(var e=0;e<r.length;e++)if(r[e]!==t[e])return!1;return!0}var us=(function(){function r(){Rt(this,r),z(this,"cache",void 0),z(this,"keys",void 0),z(this,"cacheCallTimes",void 0),this.cache=new Map,this.keys=[],this.cacheCallTimes=0}return Ot(r,[{key:"size",value:function(){return this.keys.length}},{key:"internalGet",value:function(e){var n,a,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,o={map:this.cache};return e.forEach(function(s){if(!o)o=void 0;else{var l;o=(l=o)===null||l===void 0||(l=l.map)===null||l===void 0?void 0:l.get(s)}}),(n=o)!==null&&n!==void 0&&n.value&&i&&(o.value[1]=this.cacheCallTimes++),(a=o)===null||a===void 0?void 0:a.value}},{key:"get",value:function(e){var n;return(n=this.internalGet(e,!0))===null||n===void 0?void 0:n[0]}},{key:"has",value:function(e){return!!this.internalGet(e)}},{key:"set",value:function(e,n){var a=this;if(!this.has(e)){if(this.size()+1>r.MAX_CACHE_SIZE+r.MAX_CACHE_OFFSET){var i=this.keys.reduce(function(c,u){var h=ce(c,2),d=h[1];return a.internalGet(u)[1]<d?[u,a.internalGet(u)[1]]:c},[this.keys[0],this.cacheCallTimes]),o=ce(i,1),s=o[0];this.delete(s)}this.keys.push(e)}var l=this.cache;e.forEach(function(c,u){if(u===e.length-1)l.set(c,{value:[n,a.cacheCallTimes++]});else{var h=l.get(c);h?h.map||(h.map=new Map):l.set(c,{map:new Map}),l=l.get(c).map}})}},{key:"deleteByPath",value:function(e,n){var a=e.get(n[0]);if(n.length===1){var i;return a.map?e.set(n[0],{map:a.map}):e.delete(n[0]),(i=a.value)===null||i===void 0?void 0:i[0]}var o=this.deleteByPath(a.map,n.slice(1));return(!a.map||a.map.size===0)&&!a.value&&e.delete(n[0]),o}},{key:"delete",value:function(e){if(this.has(e))return this.keys=this.keys.filter(function(n){return!sp(n,e)}),this.deleteByPath(this.cache,e)}}]),r})();z(us,"MAX_CACHE_SIZE",20);z(us,"MAX_CACHE_OFFSET",5);var Xs=0,Bu=(function(){function r(t){Rt(this,r),z(this,"derivatives",void 0),z(this,"id",void 0),this.derivatives=Array.isArray(t)?t:[t],this.id=Xs,t.length===0&&(t.length>0,void 0),Xs+=1}return Ot(r,[{key:"getDerivativeToken",value:function(e){return this.derivatives.reduce(function(n,a){return a(e,n)},void 0)}}]),r})(),Ii=new us;function fo(r){var t=Array.isArray(r)?r:[r];return Ii.has(t)||Ii.set(t,new Bu(t)),Ii.get(t)}var cp=new WeakMap,Ti={};function up(r,t){for(var e=cp,n=0;n<t.length;n+=1){var a=t[n];e.has(a)||e.set(a,new WeakMap),e=e.get(a)}return e.has(Ti)||e.set(Ti,r()),e.get(Ti)}var Ys=new WeakMap;function In(r){var t=Ys.get(r)||"";return t||(Object.keys(r).forEach(function(e){var n=r[e];t+=e,n instanceof Bu?t+=n.id:n&&ge(n)==="object"?t+=In(n):t+=n}),t=Nn(t),Ys.set(r,t)),t}function Qs(r,t){return Nn("".concat(t,"_").concat(In(r)))}var po=wr();function Zs(r){return typeof r=="number"?"".concat(r,"px"):r}function ii(r,t,e){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(a)return r;var i=Y(Y({},n),{},z(z({},gn,t),sr,e)),o=Object.keys(i).map(function(s){var l=i[s];return l?"".concat(s,'="').concat(l,'"'):null}).filter(function(s){return s}).join(" ");return"<style ".concat(o,">").concat(r,"</style>")}var pa=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return"--".concat(e?"".concat(e,"-"):"").concat(t).replace(/([a-z0-9])([A-Z])/g,"$1-$2").replace(/([A-Z]+)([A-Z][a-z0-9]+)/g,"$1-$2").replace(/([a-z])([A-Z0-9])/g,"$1-$2").toLowerCase()},lp=function(t,e,n){return Object.keys(t).length?".".concat(e).concat(n!=null&&n.scope?".".concat(n.scope):"","{").concat(Object.entries(t).map(function(a){var i=ce(a,2),o=i[0],s=i[1];return"".concat(o,":").concat(s,";")}).join(""),"}"):""},_u=function(t,e,n){var a={},i={};return Object.entries(t).forEach(function(o){var s,l,c=ce(o,2),u=c[0],h=c[1];if(n!=null&&(s=n.preserve)!==null&&s!==void 0&&s[u])i[u]=h;else if((typeof h=="string"||typeof h=="number")&&!(n!=null&&(l=n.ignore)!==null&&l!==void 0&&l[u])){var d,g=pa(u,n==null?void 0:n.prefix);a[g]=typeof h=="number"&&!(n!=null&&(d=n.unitless)!==null&&d!==void 0&&d[u])?"".concat(h,"px"):String(h),i[u]="var(".concat(g,")")}}),[i,lp(a,e,{scope:n==null?void 0:n.scope})]},Js=wr()?L.useLayoutEffect:L.useEffect,fp=function(t,e){var n=L.useRef(!0);Js(function(){return t(n.current)},e),Js(function(){return n.current=!1,function(){n.current=!0}},[])},dp=Y({},L),e0=dp.useInsertionEffect,pp=function(t,e,n){L.useMemo(t,n),fp(function(){return e(!0)},n)},hp=e0?function(r,t,e){return e0(function(){return r(),t()},e)}:pp,vp=Y({},L),xp=vp.useInsertionEffect,gp=function(t){var e=[],n=!1;function a(i){n||e.push(i)}return L.useEffect(function(){return n=!1,function(){n=!0,e.length&&e.forEach(function(i){return i()})}},t),a},mp=function(){return function(t){t()}},yp=typeof xp<"u"?gp:mp;function ls(r,t,e,n,a){var i=L.useContext(Wn),o=i.cache,s=[r].concat(fe(t)),l=lo(s),c=yp([l]),u=function(x){o.opUpdate(l,function(p){var f=p||[void 0,void 0],y=ce(f,2),v=y[0],C=v===void 0?0:v,b=y[1],F=b,E=F||e(),w=[C,E];return x?x(w):w})};L.useMemo(function(){u()},[l]);var h=o.opGet(l),d=h[1];return hp(function(){a==null||a(d)},function(g){return u(function(x){var p=ce(x,2),f=p[0],y=p[1];return g&&f===0&&(a==null||a(d)),[f+1,y]}),function(){o.opUpdate(l,function(x){var p=x||[],f=ce(p,2),y=f[0],v=y===void 0?0:y,C=f[1],b=v-1;return b===0?(c(function(){(g||!o.opGet(l))&&(n==null||n(C,!1))}),null):[v-1,C]})}},[l]),d}var Cp={},bp="css",qr=new Map;function Fp(r){qr.set(r,(qr.get(r)||0)+1)}function Ep(r,t){if(typeof document<"u"){var e=document.querySelectorAll("style[".concat(gn,'="').concat(r,'"]'));e.forEach(function(n){if(n[Nr]===t){var a;(a=n.parentNode)===null||a===void 0||a.removeChild(n)}})}}var Ap=0;function wp(r,t){qr.set(r,(qr.get(r)||0)-1);var e=new Set;qr.forEach(function(n,a){n<=0&&e.add(a)}),qr.size-e.size>Ap&&e.forEach(function(n){Ep(n,t),qr.delete(n)})}var Sp=function(t,e,n,a){var i=n.getDerivativeToken(t),o=Y(Y({},i),e);return a&&(o=a(o)),o},Du="token";function Bp(r,t){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=lr(Wn),a=n.cache.instanceId,i=n.container,o=e.salt,s=o===void 0?"":o,l=e.override,c=l===void 0?Cp:l,u=e.formatToken,h=e.getComputedToken,d=e.cssVar,g=up(function(){return Object.assign.apply(Object,[{}].concat(fe(t)))},t),x=In(g),p=In(c),f=d?In(d):"",y=ls(Du,[s,r.id,x,p,f],function(){var v,C=h?h(g,c,r):Sp(g,c,r,u),b=Y({},C),F="";if(d){var E=_u(C,d.key,{prefix:d.prefix,ignore:d.ignore,unitless:d.unitless,preserve:d.preserve}),w=ce(E,2);C=w[0],F=w[1]}var A=Qs(C,s);C._tokenKey=A,b._tokenKey=Qs(b,s);var S=(v=d==null?void 0:d.key)!==null&&v!==void 0?v:A;C._themeKey=S,Fp(S);var m="".concat(bp,"-").concat(Nn(A));return C._hashId=m,[C,m,b,F,(d==null?void 0:d.key)||""]},function(v){wp(v[0]._themeKey,a)},function(v){var C=ce(v,4),b=C[0],F=C[3];if(d&&F){var E=Ur(F,Nn("css-variables-".concat(b._themeKey)),{mark:sr,prepend:"queue",attachTo:i,priority:-999});E[Nr]=a,E.setAttribute(gn,b._themeKey)}});return y}var _p=function(t,e,n){var a=ce(t,5),i=a[2],o=a[3],s=a[4],l=n||{},c=l.plain;if(!o)return null;var u=i._tokenKey,h=-999,d={"data-rc-order":"prependQueue","data-rc-priority":"".concat(h)},g=ii(o,s,u,d,c);return[h,u,g]},Dp={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},ku="comm",Pu="rule",Iu="decl",kp="@import",Pp="@namespace",Ip="@keyframes",Tp="@layer",Tu=Math.abs,fs=String.fromCharCode;function Ru(r){return r.trim()}function ha(r,t,e){return r.replace(t,e)}function Rp(r,t,e){return r.indexOf(t,e)}function pn(r,t){return r.charCodeAt(t)|0}function mn(r,t,e){return r.slice(t,e)}function gr(r){return r.length}function Op(r){return r.length}function ra(r,t){return t.push(r),r}var vi=1,yn=1,Ou=0,Jt=0,ht=0,wn="";function ds(r,t,e,n,a,i,o,s){return{value:r,root:t,parent:e,type:n,props:a,children:i,line:vi,column:yn,length:o,return:"",siblings:s}}function Np(){return ht}function Mp(){return ht=Jt>0?pn(wn,--Jt):0,yn--,ht===10&&(yn=1,vi--),ht}function cr(){return ht=Jt<Ou?pn(wn,Jt++):0,yn++,ht===10&&(yn=1,vi++),ht}function Mr(){return pn(wn,Jt)}function va(){return Jt}function xi(r,t){return mn(wn,r,t)}function Ln(r){switch(r){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Lp(r){return vi=yn=1,Ou=gr(wn=r),Jt=0,[]}function $p(r){return wn="",r}function Ri(r){return Ru(xi(Jt-1,ho(r===91?r+2:r===40?r+1:r)))}function zp(r){for(;(ht=Mr())&&ht<33;)cr();return Ln(r)>2||Ln(ht)>3?"":" "}function Hp(r,t){for(;--t&&cr()&&!(ht<48||ht>102||ht>57&&ht<65||ht>70&&ht<97););return xi(r,va()+(t<6&&Mr()==32&&cr()==32))}function ho(r){for(;cr();)switch(ht){case r:return Jt;case 34:case 39:r!==34&&r!==39&&ho(ht);break;case 40:r===41&&ho(r);break;case 92:cr();break}return Jt}function qp(r,t){for(;cr()&&r+ht!==57;)if(r+ht===84&&Mr()===47)break;return"/*"+xi(t,Jt-1)+"*"+fs(r===47?r:cr())}function jp(r){for(;!Ln(Mr());)cr();return xi(r,Jt)}function Vp(r){return $p(xa("",null,null,null,[""],r=Lp(r),0,[0],r))}function xa(r,t,e,n,a,i,o,s,l){for(var c=0,u=0,h=o,d=0,g=0,x=0,p=1,f=1,y=1,v=0,C="",b=a,F=i,E=n,w=C;f;)switch(x=v,v=cr()){case 40:if(x!=108&&pn(w,h-1)==58){Rp(w+=ha(Ri(v),"&","&\f"),"&\f",Tu(c?s[c-1]:0))!=-1&&(y=-1);break}case 34:case 39:case 91:w+=Ri(v);break;case 9:case 10:case 13:case 32:w+=zp(x);break;case 92:w+=Hp(va()-1,7);continue;case 47:switch(Mr()){case 42:case 47:ra(Up(qp(cr(),va()),t,e,l),l),(Ln(x||1)==5||Ln(Mr()||1)==5)&&gr(w)&&mn(w,-1,void 0)!==" "&&(w+=" ");break;default:w+="/"}break;case 123*p:s[c++]=gr(w)*y;case 125*p:case 59:case 0:switch(v){case 0:case 125:f=0;case 59+u:y==-1&&(w=ha(w,/\f/g,"")),g>0&&(gr(w)-h||p===0&&x===47)&&ra(g>32?r0(w+";",n,e,h-1,l):r0(ha(w," ","")+";",n,e,h-2,l),l);break;case 59:w+=";";default:if(ra(E=t0(w,t,e,c,u,a,s,C,b=[],F=[],h,i),i),v===123)if(u===0)xa(w,t,E,E,b,i,h,s,F);else{switch(d){case 99:if(pn(w,3)===110)break;case 108:if(pn(w,2)===97)break;default:u=0;case 100:case 109:case 115:}u?xa(r,E,E,n&&ra(t0(r,E,E,0,0,a,s,C,a,b=[],h,F),F),a,F,h,s,n?b:F):xa(w,E,E,E,[""],F,0,s,F)}}c=u=g=0,p=y=1,C=w="",h=o;break;case 58:h=1+gr(w),g=x;default:if(p<1){if(v==123)--p;else if(v==125&&p++==0&&Mp()==125)continue}switch(w+=fs(v),v*p){case 38:y=u>0?1:(w+="\f",-1);break;case 44:s[c++]=(gr(w)-1)*y,y=1;break;case 64:Mr()===45&&(w+=Ri(cr())),d=Mr(),u=h=gr(C=w+=jp(va())),v++;break;case 45:x===45&&gr(w)==2&&(p=0)}}return i}function t0(r,t,e,n,a,i,o,s,l,c,u,h){for(var d=a-1,g=a===0?i:[""],x=Op(g),p=0,f=0,y=0;p<n;++p)for(var v=0,C=mn(r,d+1,d=Tu(f=o[p])),b=r;v<x;++v)(b=Ru(f>0?g[v]+" "+C:ha(C,/&\f/g,g[v])))&&(l[y++]=b);return ds(r,t,e,a===0?Pu:s,l,c,u,h)}function Up(r,t,e,n){return ds(r,t,e,ku,fs(Np()),mn(r,2,-2),0,n)}function r0(r,t,e,n,a){return ds(r,t,e,Iu,mn(r,0,n),mn(r,n+1,-1),n,a)}function vo(r,t){for(var e="",n=0;n<r.length;n++)e+=t(r[n],n,r,t)||"";return e}function Wp(r,t,e,n){switch(r.type){case Tp:if(r.children.length)break;case kp:case Pp:case Iu:return r.return=r.return||r.value;case ku:return"";case Ip:return r.return=r.value+"{"+vo(r.children,n)+"}";case Pu:if(!gr(r.value=r.props.join(",")))return""}return gr(e=vo(r.children,n))?r.return=r.value+"{"+e+"}":""}var n0="data-ant-cssinjs-cache-path",Nu="_FILE_STYLE__",Wr,Mu=!0;function Gp(){if(!Wr&&(Wr={},wr())){var r=document.createElement("div");r.className=n0,r.style.position="fixed",r.style.visibility="hidden",r.style.top="-9999px",document.body.appendChild(r);var t=getComputedStyle(r).content||"";t=t.replace(/^"/,"").replace(/"$/,""),t.split(";").forEach(function(a){var i=a.split(":"),o=ce(i,2),s=o[0],l=o[1];Wr[s]=l});var e=document.querySelector("style[".concat(n0,"]"));if(e){var n;Mu=!1,(n=e.parentNode)===null||n===void 0||n.removeChild(e)}document.body.removeChild(r)}}function Kp(r){return Gp(),!!Wr[r]}function Xp(r){var t=Wr[r],e=null;if(t&&wr())if(Mu)e=Nu;else{var n=document.querySelector("style[".concat(sr,'="').concat(Wr[r],'"]'));n?e=n.innerHTML:delete Wr[r]}return[e,t]}var Yp="_skip_check_",Lu="_multi_value_";function ga(r){var t=vo(Vp(r),Wp);return t.replace(/\{%%%\:[^;];}/g,";")}function Qp(r){return ge(r)==="object"&&r&&(Yp in r||Lu in r)}function a0(r,t,e){if(!t)return r;var n=".".concat(t),a=e==="low"?":where(".concat(n,")"):n,i=r.split(",").map(function(o){var s,l=o.trim().split(/\s+/),c=l[0]||"",u=((s=c.match(/^\w+/))===null||s===void 0?void 0:s[0])||"";return c="".concat(u).concat(a).concat(c.slice(u.length)),[c].concat(fe(l.slice(1))).join(" ")});return i.join(",")}var Zp=function r(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{root:!0,parentSelectors:[]},a=n.root,i=n.injectHash,o=n.parentSelectors,s=e.hashId,l=e.layer;e.path;var c=e.hashPriority,u=e.transformers,h=u===void 0?[]:u;e.linters;var d="",g={};function x(y){var v=y.getName(s);if(!g[v]){var C=r(y.style,e,{root:!1,parentSelectors:o}),b=ce(C,1),F=b[0];g[v]="@keyframes ".concat(y.getName(s)).concat(F)}}function p(y){var v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return y.forEach(function(C){Array.isArray(C)?p(C,v):C&&v.push(C)}),v}var f=p(Array.isArray(t)?t:[t]);return f.forEach(function(y){var v=typeof y=="string"&&!a?{}:y;if(typeof v=="string")d+="".concat(v,`
55
+ `);else if(v._keyframe)x(v);else{var C=h.reduce(function(b,F){var E;return(F==null||(E=F.visit)===null||E===void 0?void 0:E.call(F,b))||b},v);Object.keys(C).forEach(function(b){var F=C[b];if(ge(F)==="object"&&F&&(b!=="animationName"||!F._keyframe)&&!Qp(F)){var E=!1,w=b.trim(),A=!1;(a||i)&&s?w.startsWith("@")?E=!0:w==="&"?w=a0("",s,c):w=a0(b,s,c):a&&!s&&(w==="&"||w==="")&&(w="",A=!0);var S=r(F,e,{root:A,injectHash:E,parentSelectors:[].concat(fe(o),[w])}),m=ce(S,2),B=m[0],_=m[1];g=Y(Y({},g),_),d+="".concat(w).concat(B)}else{let $=function(H,j){var q=H.replace(/[A-Z]/g,function(X){return"-".concat(X.toLowerCase())}),G=j;!Dp[H]&&typeof G=="number"&&G!==0&&(G="".concat(G,"px")),H==="animationName"&&j!==null&&j!==void 0&&j._keyframe&&(x(j),G=j.getName(s)),d+="".concat(q,":").concat(G,";")};var P,T=(P=F==null?void 0:F.value)!==null&&P!==void 0?P:F;ge(F)==="object"&&F!==null&&F!==void 0&&F[Lu]&&Array.isArray(T)?T.forEach(function(H){$(b,H)}):$(b,T)}})}}),a?l&&(d&&(d="@layer ".concat(l.name," {").concat(d,"}")),l.dependencies&&(g["@layer ".concat(l.name)]=l.dependencies.map(function(y){return"@layer ".concat(y,", ").concat(l.name,";")}).join(`
56
+ `))):d="{".concat(d,"}"),[d,g]};function $u(r,t){return Nn("".concat(r.join("%")).concat(t))}function Jp(){return null}var zu="style";function xo(r,t){var e=r.token,n=r.path,a=r.hashId,i=r.layer,o=r.nonce,s=r.clientOnly,l=r.order,c=l===void 0?0:l,u=L.useContext(Wn),h=u.autoClear;u.mock;var d=u.defaultCache,g=u.hashPriority,x=u.container,p=u.ssrInline,f=u.transformers,y=u.linters,v=u.cache,C=u.layer,b=e._tokenKey,F=[b];C&&F.push("layer"),F.push.apply(F,fe(n));var E=po,w=ls(zu,F,function(){var _=F.join("|");if(Kp(_)){var P=Xp(_),T=ce(P,2),$=T[0],H=T[1];if($)return[$,b,H,{},s,c]}var j=t(),q=Zp(j,{hashId:a,hashPriority:g,layer:C?i:void 0,path:n.join("-"),transformers:f,linters:y}),G=ce(q,2),X=G[0],O=G[1],M=ga(X),R=$u(F,M);return[M,b,R,O,s,c]},function(_,P){var T=ce(_,3),$=T[2];(P||h)&&po&&Au($,{mark:sr,attachTo:x})},function(_){var P=ce(_,4),T=P[0];P[1];var $=P[2],H=P[3];if(E&&T!==Nu){var j={mark:sr,prepend:C?!1:"queue",attachTo:x,priority:c},q=typeof o=="function"?o():o;q&&(j.csp={nonce:q});var G=[],X=[];Object.keys(H).forEach(function(M){M.startsWith("@layer")?G.push(M):X.push(M)}),G.forEach(function(M){Ur(ga(H[M]),"_layer-".concat(M),Y(Y({},j),{},{prepend:!0}))});var O=Ur(T,$,j);O[Nr]=v.instanceId,O.setAttribute(gn,b),X.forEach(function(M){Ur(ga(H[M]),"_effect-".concat(M),j)})}}),A=ce(w,3),S=A[0],m=A[1],B=A[2];return function(_){var P;return!p||E||!d?P=L.createElement(Jp,null):P=L.createElement("style",bt({},z(z({},gn,m),sr,B),{dangerouslySetInnerHTML:{__html:S}})),L.createElement(L.Fragment,null,P,_)}}var eh=function(t,e,n){var a=ce(t,6),i=a[0],o=a[1],s=a[2],l=a[3],c=a[4],u=a[5],h=n||{},d=h.plain;if(c)return null;var g=i,x={"data-rc-order":"prependQueue","data-rc-priority":"".concat(u)};return g=ii(i,o,s,x,d),l&&Object.keys(l).forEach(function(p){if(!e[p]){e[p]=!0;var f=ga(l[p]),y=ii(f,o,"_effect-".concat(p),x,d);p.startsWith("@layer")?g=y+g:g+=y}}),[u,s,g]},Hu="cssVar",th=function(t,e){var n=t.key,a=t.prefix,i=t.unitless,o=t.ignore,s=t.token,l=t.scope,c=l===void 0?"":l,u=lr(Wn),h=u.cache.instanceId,d=u.container,g=s._tokenKey,x=[].concat(fe(t.path),[n,c,g]),p=ls(Hu,x,function(){var f=e(),y=_u(f,n,{prefix:a,unitless:i,ignore:o,scope:c}),v=ce(y,2),C=v[0],b=v[1],F=$u(x,b);return[C,b,F,n]},function(f){var y=ce(f,3),v=y[2];po&&Au(v,{mark:sr,attachTo:d})},function(f){var y=ce(f,3),v=y[1],C=y[2];if(v){var b=Ur(v,C,{mark:sr,prepend:"queue",attachTo:d,priority:-999});b[Nr]=h,b.setAttribute(gn,n)}});return p},rh=function(t,e,n){var a=ce(t,4),i=a[1],o=a[2],s=a[3],l=n||{},c=l.plain;if(!i)return null;var u=-999,h={"data-rc-order":"prependQueue","data-rc-priority":"".concat(u)},d=ii(i,s,o,h,c);return[u,o,d]};z(z(z({},zu,eh),Du,_p),Hu,rh);var i0=(function(){function r(t,e){Rt(this,r),z(this,"name",void 0),z(this,"style",void 0),z(this,"_keyframe",!0),this.name=t,this.style=e}return Ot(r,[{key:"getName",value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return e?"".concat(e,"-").concat(this.name):this.name}}]),r})();function rn(r){return r.notSplit=!0,r}rn(["borderTop","borderBottom"]),rn(["borderTop"]),rn(["borderBottom"]),rn(["borderLeft","borderRight"]),rn(["borderLeft"]),rn(["borderRight"]);var ps=Un({});function nh(r){return mu(r)||gu(r)||os(r)||yu()}function mr(r,t){for(var e=r,n=0;n<t.length;n+=1){if(e==null)return;e=e[t[n]]}return e}function qu(r,t,e,n){if(!t.length)return e;var a=nh(t),i=a[0],o=a.slice(1),s;return!r&&typeof i=="number"?s=[]:Array.isArray(r)?s=fe(r):s=Y({},r),n&&e===void 0&&o.length===1?delete s[i][o[0]]:s[i]=qu(s[i],o,e,n),s}function ir(r,t,e){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return t.length&&n&&e===void 0&&!mr(r,t.slice(0,-1))?r:qu(r,t,e,n)}function ah(r){return ge(r)==="object"&&r!==null&&Object.getPrototypeOf(r)===Object.prototype}function o0(r){return Array.isArray(r)?[]:{}}var ih=typeof Reflect>"u"?Object.keys:Reflect.ownKeys;function un(){for(var r=arguments.length,t=new Array(r),e=0;e<r;e++)t[e]=arguments[e];var n=o0(t[0]);return t.forEach(function(a){function i(o,s){var l=new Set(s),c=mr(a,o),u=Array.isArray(c);if(u||ah(c)){if(!l.has(c)){l.add(c);var h=mr(n,o);u?n=ir(n,o,[]):(!h||ge(h)!=="object")&&(n=ir(n,o,o0(c))),ih(c).forEach(function(d){i([].concat(fe(o),[d]),l)})}}else n=ir(n,o,c)}i([])}),n}const oh=L.createContext({}),sh=Un(void 0),jt="${label} is not a valid ${type}",gi={Modal:{okText:"OK",cancelText:"Cancel",justOkText:"OK"},Form:{optional:"(optional)",defaultValidateMessages:{default:"Field validation error for ${label}",required:"Please enter ${label}",enum:"${label} must be one of [${enum}]",whitespace:"${label} cannot be a blank character",date:{format:"${label} date format is invalid",parse:"${label} cannot be converted to a date",invalid:"${label} is an invalid date"},types:{string:jt,method:jt,array:jt,object:jt,number:jt,date:jt,boolean:jt,integer:jt,float:jt,regexp:jt,email:jt,url:jt,hex:jt},string:{len:"${label} must be ${len} characters",min:"${label} must be at least ${min} characters",max:"${label} must be up to ${max} characters",range:"${label} must be between ${min}-${max} characters"},number:{len:"${label} must be equal to ${len}",min:"${label} must be minimum ${min}",max:"${label} must be maximum ${max}",range:"${label} must be between ${min}-${max}"},array:{len:"Must be ${len} ${label}",min:"At least ${min} ${label}",max:"At most ${max} ${label}",range:"The amount of ${label} must be between ${min}-${max}"},pattern:{mismatch:"${label} does not match the pattern ${pattern}"}}}};Object.assign({},gi.Modal);let ma=[];const s0=()=>ma.reduce((r,t)=>Object.assign(Object.assign({},r),t),gi.Modal);function ch(r){if(r){const t=Object.assign({},r);return ma.push(t),s0(),()=>{ma=ma.filter(e=>e!==t),s0()}}Object.assign({},gi.Modal)}const ju=Un(void 0),uh="internalMark",lh=r=>{const{locale:t={},children:e,_ANT_MARK__:n}=r;L.useEffect(()=>ch(t==null?void 0:t.Modal),[t]);const a=L.useMemo(()=>Object.assign(Object.assign({},t),{exist:!0}),[t]);return L.createElement(ju.Provider,{value:a},e)},Vu={blue:"#1677FF",purple:"#722ED1",cyan:"#13C2C2",green:"#52C41A",magenta:"#EB2F96",pink:"#EB2F96",red:"#F5222D",orange:"#FA8C16",yellow:"#FADB14",volcano:"#FA541C",geekblue:"#2F54EB",gold:"#FAAD14",lime:"#A0D911"},$n=Object.assign(Object.assign({},Vu),{colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorLink:"",colorTextBase:"",colorBgBase:"",fontFamily:`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
57
+ 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
58
+ 'Noto Color Emoji'`,fontFamilyCode:"'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace",fontSize:14,lineWidth:1,lineType:"solid",motionUnit:.1,motionBase:0,motionEaseOutCirc:"cubic-bezier(0.08, 0.82, 0.17, 1)",motionEaseInOutCirc:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",motionEaseOut:"cubic-bezier(0.215, 0.61, 0.355, 1)",motionEaseInOut:"cubic-bezier(0.645, 0.045, 0.355, 1)",motionEaseOutBack:"cubic-bezier(0.12, 0.4, 0.29, 1.46)",motionEaseInBack:"cubic-bezier(0.71, -0.46, 0.88, 0.6)",motionEaseInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",motionEaseOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",borderRadius:6,sizeUnit:4,sizeStep:4,sizePopupArrow:16,controlHeight:32,zIndexBase:0,zIndexPopupBase:1e3,opacityImage:1,wireframe:!1,motion:!0}),Ct=Math.round;function Oi(r,t){const e=r.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],n=e.map(a=>parseFloat(a));for(let a=0;a<3;a+=1)n[a]=t(n[a]||0,e[a]||"",a);return e[3]?n[3]=e[3].includes("%")?n[3]/100:n[3]:n[3]=1,n}const c0=(r,t,e)=>e===0?r:r/100;function Dn(r,t){const e=t||255;return r>e?e:r<0?0:r}class ft{constructor(t){z(this,"isValid",!0),z(this,"r",0),z(this,"g",0),z(this,"b",0),z(this,"a",1),z(this,"_h",void 0),z(this,"_s",void 0),z(this,"_l",void 0),z(this,"_v",void 0),z(this,"_max",void 0),z(this,"_min",void 0),z(this,"_brightness",void 0);function e(n){return n[0]in t&&n[1]in t&&n[2]in t}if(t)if(typeof t=="string"){let a=function(i){return n.startsWith(i)};const n=t.trim();/^#?[A-F\d]{3,8}$/i.test(n)?this.fromHexString(n):a("rgb")?this.fromRgbString(n):a("hsl")?this.fromHslString(n):(a("hsv")||a("hsb"))&&this.fromHsvString(n)}else if(t instanceof ft)this.r=t.r,this.g=t.g,this.b=t.b,this.a=t.a,this._h=t._h,this._s=t._s,this._l=t._l,this._v=t._v;else if(e("rgb"))this.r=Dn(t.r),this.g=Dn(t.g),this.b=Dn(t.b),this.a=typeof t.a=="number"?Dn(t.a,1):1;else if(e("hsl"))this.fromHsl(t);else if(e("hsv"))this.fromHsv(t);else throw new Error("@ant-design/fast-color: unsupported input "+JSON.stringify(t))}setR(t){return this._sc("r",t)}setG(t){return this._sc("g",t)}setB(t){return this._sc("b",t)}setA(t){return this._sc("a",t,1)}setHue(t){const e=this.toHsv();return e.h=t,this._c(e)}getLuminance(){function t(i){const o=i/255;return o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4)}const e=t(this.r),n=t(this.g),a=t(this.b);return .2126*e+.7152*n+.0722*a}getHue(){if(typeof this._h>"u"){const t=this.getMax()-this.getMin();t===0?this._h=0:this._h=Ct(60*(this.r===this.getMax()?(this.g-this.b)/t+(this.g<this.b?6:0):this.g===this.getMax()?(this.b-this.r)/t+2:(this.r-this.g)/t+4))}return this._h}getSaturation(){if(typeof this._s>"u"){const t=this.getMax()-this.getMin();t===0?this._s=0:this._s=t/this.getMax()}return this._s}getLightness(){return typeof this._l>"u"&&(this._l=(this.getMax()+this.getMin())/510),this._l}getValue(){return typeof this._v>"u"&&(this._v=this.getMax()/255),this._v}getBrightness(){return typeof this._brightness>"u"&&(this._brightness=(this.r*299+this.g*587+this.b*114)/1e3),this._brightness}darken(t=10){const e=this.getHue(),n=this.getSaturation();let a=this.getLightness()-t/100;return a<0&&(a=0),this._c({h:e,s:n,l:a,a:this.a})}lighten(t=10){const e=this.getHue(),n=this.getSaturation();let a=this.getLightness()+t/100;return a>1&&(a=1),this._c({h:e,s:n,l:a,a:this.a})}mix(t,e=50){const n=this._c(t),a=e/100,i=s=>(n[s]-this[s])*a+this[s],o={r:Ct(i("r")),g:Ct(i("g")),b:Ct(i("b")),a:Ct(i("a")*100)/100};return this._c(o)}tint(t=10){return this.mix({r:255,g:255,b:255,a:1},t)}shade(t=10){return this.mix({r:0,g:0,b:0,a:1},t)}onBackground(t){const e=this._c(t),n=this.a+e.a*(1-this.a),a=i=>Ct((this[i]*this.a+e[i]*e.a*(1-this.a))/n);return this._c({r:a("r"),g:a("g"),b:a("b"),a:n})}isDark(){return this.getBrightness()<128}isLight(){return this.getBrightness()>=128}equals(t){return this.r===t.r&&this.g===t.g&&this.b===t.b&&this.a===t.a}clone(){return this._c(this)}toHexString(){let t="#";const e=(this.r||0).toString(16);t+=e.length===2?e:"0"+e;const n=(this.g||0).toString(16);t+=n.length===2?n:"0"+n;const a=(this.b||0).toString(16);if(t+=a.length===2?a:"0"+a,typeof this.a=="number"&&this.a>=0&&this.a<1){const i=Ct(this.a*255).toString(16);t+=i.length===2?i:"0"+i}return t}toHsl(){return{h:this.getHue(),s:this.getSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const t=this.getHue(),e=Ct(this.getSaturation()*100),n=Ct(this.getLightness()*100);return this.a!==1?`hsla(${t},${e}%,${n}%,${this.a})`:`hsl(${t},${e}%,${n}%)`}toHsv(){return{h:this.getHue(),s:this.getSaturation(),v:this.getValue(),a:this.a}}toRgb(){return{r:this.r,g:this.g,b:this.b,a:this.a}}toRgbString(){return this.a!==1?`rgba(${this.r},${this.g},${this.b},${this.a})`:`rgb(${this.r},${this.g},${this.b})`}toString(){return this.toRgbString()}_sc(t,e,n){const a=this.clone();return a[t]=Dn(e,n),a}_c(t){return new this.constructor(t)}getMax(){return typeof this._max>"u"&&(this._max=Math.max(this.r,this.g,this.b)),this._max}getMin(){return typeof this._min>"u"&&(this._min=Math.min(this.r,this.g,this.b)),this._min}fromHexString(t){const e=t.replace("#","");function n(a,i){return parseInt(e[a]+e[i||a],16)}e.length<6?(this.r=n(0),this.g=n(1),this.b=n(2),this.a=e[3]?n(3)/255:1):(this.r=n(0,1),this.g=n(2,3),this.b=n(4,5),this.a=e[6]?n(6,7)/255:1)}fromHsl({h:t,s:e,l:n,a}){if(this._h=t%360,this._s=e,this._l=n,this.a=typeof a=="number"?a:1,e<=0){const d=Ct(n*255);this.r=d,this.g=d,this.b=d}let i=0,o=0,s=0;const l=t/60,c=(1-Math.abs(2*n-1))*e,u=c*(1-Math.abs(l%2-1));l>=0&&l<1?(i=c,o=u):l>=1&&l<2?(i=u,o=c):l>=2&&l<3?(o=c,s=u):l>=3&&l<4?(o=u,s=c):l>=4&&l<5?(i=u,s=c):l>=5&&l<6&&(i=c,s=u);const h=n-c/2;this.r=Ct((i+h)*255),this.g=Ct((o+h)*255),this.b=Ct((s+h)*255)}fromHsv({h:t,s:e,v:n,a}){this._h=t%360,this._s=e,this._v=n,this.a=typeof a=="number"?a:1;const i=Ct(n*255);if(this.r=i,this.g=i,this.b=i,e<=0)return;const o=t/60,s=Math.floor(o),l=o-s,c=Ct(n*(1-e)*255),u=Ct(n*(1-e*l)*255),h=Ct(n*(1-e*(1-l))*255);switch(s){case 0:this.g=h,this.b=c;break;case 1:this.r=u,this.b=c;break;case 2:this.r=c,this.b=h;break;case 3:this.r=c,this.g=u;break;case 4:this.r=h,this.g=c;break;case 5:default:this.g=c,this.b=u;break}}fromHsvString(t){const e=Oi(t,c0);this.fromHsv({h:e[0],s:e[1],v:e[2],a:e[3]})}fromHslString(t){const e=Oi(t,c0);this.fromHsl({h:e[0],s:e[1],l:e[2],a:e[3]})}fromRgbString(t){const e=Oi(t,(n,a)=>a.includes("%")?Ct(n/100*255):n);this.r=e[0],this.g=e[1],this.b=e[2],this.a=e[3]}}var na=2,u0=.16,fh=.05,dh=.05,ph=.15,Uu=5,Wu=4,hh=[{index:7,amount:15},{index:6,amount:25},{index:5,amount:30},{index:5,amount:45},{index:5,amount:65},{index:5,amount:85},{index:4,amount:90},{index:3,amount:95},{index:2,amount:97},{index:1,amount:98}];function l0(r,t,e){var n;return Math.round(r.h)>=60&&Math.round(r.h)<=240?n=e?Math.round(r.h)-na*t:Math.round(r.h)+na*t:n=e?Math.round(r.h)+na*t:Math.round(r.h)-na*t,n<0?n+=360:n>=360&&(n-=360),n}function f0(r,t,e){if(r.h===0&&r.s===0)return r.s;var n;return e?n=r.s-u0*t:t===Wu?n=r.s+u0:n=r.s+fh*t,n>1&&(n=1),e&&t===Uu&&n>.1&&(n=.1),n<.06&&(n=.06),Math.round(n*100)/100}function d0(r,t,e){var n;return e?n=r.v+dh*t:n=r.v-ph*t,n=Math.max(0,Math.min(1,n)),Math.round(n*100)/100}function zn(r){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=[],n=new ft(r),a=n.toHsv(),i=Uu;i>0;i-=1){var o=new ft({h:l0(a,i,!0),s:f0(a,i,!0),v:d0(a,i,!0)});e.push(o)}e.push(n);for(var s=1;s<=Wu;s+=1){var l=new ft({h:l0(a,s),s:f0(a,s),v:d0(a,s)});e.push(l)}return t.theme==="dark"?hh.map(function(c){var u=c.index,h=c.amount;return new ft(t.backgroundColor||"#141414").mix(e[u],h).toHexString()}):e.map(function(c){return c.toHexString()})}var Ni={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1677FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},go=["#fff1f0","#ffccc7","#ffa39e","#ff7875","#ff4d4f","#f5222d","#cf1322","#a8071a","#820014","#5c0011"];go.primary=go[5];var mo=["#fff2e8","#ffd8bf","#ffbb96","#ff9c6e","#ff7a45","#fa541c","#d4380d","#ad2102","#871400","#610b00"];mo.primary=mo[5];var yo=["#fff7e6","#ffe7ba","#ffd591","#ffc069","#ffa940","#fa8c16","#d46b08","#ad4e00","#873800","#612500"];yo.primary=yo[5];var Co=["#fffbe6","#fff1b8","#ffe58f","#ffd666","#ffc53d","#faad14","#d48806","#ad6800","#874d00","#613400"];Co.primary=Co[5];var bo=["#feffe6","#ffffb8","#fffb8f","#fff566","#ffec3d","#fadb14","#d4b106","#ad8b00","#876800","#614700"];bo.primary=bo[5];var Fo=["#fcffe6","#f4ffb8","#eaff8f","#d3f261","#bae637","#a0d911","#7cb305","#5b8c00","#3f6600","#254000"];Fo.primary=Fo[5];var Eo=["#f6ffed","#d9f7be","#b7eb8f","#95de64","#73d13d","#52c41a","#389e0d","#237804","#135200","#092b00"];Eo.primary=Eo[5];var Ao=["#e6fffb","#b5f5ec","#87e8de","#5cdbd3","#36cfc9","#13c2c2","#08979c","#006d75","#00474f","#002329"];Ao.primary=Ao[5];var oi=["#e6f4ff","#bae0ff","#91caff","#69b1ff","#4096ff","#1677ff","#0958d9","#003eb3","#002c8c","#001d66"];oi.primary=oi[5];var wo=["#f0f5ff","#d6e4ff","#adc6ff","#85a5ff","#597ef7","#2f54eb","#1d39c4","#10239e","#061178","#030852"];wo.primary=wo[5];var So=["#f9f0ff","#efdbff","#d3adf7","#b37feb","#9254de","#722ed1","#531dab","#391085","#22075e","#120338"];So.primary=So[5];var Bo=["#fff0f6","#ffd6e7","#ffadd2","#ff85c0","#f759ab","#eb2f96","#c41d7f","#9e1068","#780650","#520339"];Bo.primary=Bo[5];var _o=["#a6a6a6","#999999","#8c8c8c","#808080","#737373","#666666","#404040","#1a1a1a","#000000","#000000"];_o.primary=_o[5];var Mi={red:go,volcano:mo,orange:yo,gold:Co,yellow:bo,lime:Fo,green:Eo,cyan:Ao,blue:oi,geekblue:wo,purple:So,magenta:Bo,grey:_o};function vh(r,{generateColorPalettes:t,generateNeutralColorPalettes:e}){const{colorSuccess:n,colorWarning:a,colorError:i,colorInfo:o,colorPrimary:s,colorBgBase:l,colorTextBase:c}=r,u=t(s),h=t(n),d=t(a),g=t(i),x=t(o),p=e(l,c),f=r.colorLink||r.colorInfo,y=t(f),v=new ft(g[1]).mix(new ft(g[3]),50).toHexString();return Object.assign(Object.assign({},p),{colorPrimaryBg:u[1],colorPrimaryBgHover:u[2],colorPrimaryBorder:u[3],colorPrimaryBorderHover:u[4],colorPrimaryHover:u[5],colorPrimary:u[6],colorPrimaryActive:u[7],colorPrimaryTextHover:u[8],colorPrimaryText:u[9],colorPrimaryTextActive:u[10],colorSuccessBg:h[1],colorSuccessBgHover:h[2],colorSuccessBorder:h[3],colorSuccessBorderHover:h[4],colorSuccessHover:h[4],colorSuccess:h[6],colorSuccessActive:h[7],colorSuccessTextHover:h[8],colorSuccessText:h[9],colorSuccessTextActive:h[10],colorErrorBg:g[1],colorErrorBgHover:g[2],colorErrorBgFilledHover:v,colorErrorBgActive:g[3],colorErrorBorder:g[3],colorErrorBorderHover:g[4],colorErrorHover:g[5],colorError:g[6],colorErrorActive:g[7],colorErrorTextHover:g[8],colorErrorText:g[9],colorErrorTextActive:g[10],colorWarningBg:d[1],colorWarningBgHover:d[2],colorWarningBorder:d[3],colorWarningBorderHover:d[4],colorWarningHover:d[4],colorWarning:d[6],colorWarningActive:d[7],colorWarningTextHover:d[8],colorWarningText:d[9],colorWarningTextActive:d[10],colorInfoBg:x[1],colorInfoBgHover:x[2],colorInfoBorder:x[3],colorInfoBorderHover:x[4],colorInfoHover:x[4],colorInfo:x[6],colorInfoActive:x[7],colorInfoTextHover:x[8],colorInfoText:x[9],colorInfoTextActive:x[10],colorLinkHover:y[4],colorLink:y[6],colorLinkActive:y[7],colorBgMask:new ft("#000").setA(.45).toRgbString(),colorWhite:"#fff"})}const xh=r=>{let t=r,e=r,n=r,a=r;return r<6&&r>=5?t=r+1:r<16&&r>=6?t=r+2:r>=16&&(t=16),r<7&&r>=5?e=4:r<8&&r>=7?e=5:r<14&&r>=8?e=6:r<16&&r>=14?e=7:r>=16&&(e=8),r<6&&r>=2?n=1:r>=6&&(n=2),r>4&&r<8?a=4:r>=8&&(a=6),{borderRadius:r,borderRadiusXS:n,borderRadiusSM:e,borderRadiusLG:t,borderRadiusOuter:a}};function gh(r){const{motionUnit:t,motionBase:e,borderRadius:n,lineWidth:a}=r;return Object.assign({motionDurationFast:`${(e+t).toFixed(1)}s`,motionDurationMid:`${(e+t*2).toFixed(1)}s`,motionDurationSlow:`${(e+t*3).toFixed(1)}s`,lineWidthBold:a+1},xh(n))}const mh=r=>{const{controlHeight:t}=r;return{controlHeightSM:t*.75,controlHeightXS:t*.5,controlHeightLG:t*1.25}};function yh(r){return(r+8)/r}function Ch(r){const t=Array.from({length:10}).map((e,n)=>{const a=n-1,i=r*Math.pow(Math.E,a/5),o=n>1?Math.floor(i):Math.ceil(i);return Math.floor(o/2)*2});return t[1]=r,t.map(e=>({size:e,lineHeight:yh(e)}))}const bh=r=>{const t=Ch(r),e=t.map(u=>u.size),n=t.map(u=>u.lineHeight),a=e[1],i=e[0],o=e[2],s=n[1],l=n[0],c=n[2];return{fontSizeSM:i,fontSize:a,fontSizeLG:o,fontSizeXL:e[3],fontSizeHeading1:e[6],fontSizeHeading2:e[5],fontSizeHeading3:e[4],fontSizeHeading4:e[3],fontSizeHeading5:e[2],lineHeight:s,lineHeightLG:c,lineHeightSM:l,fontHeight:Math.round(s*a),fontHeightLG:Math.round(c*o),fontHeightSM:Math.round(l*i),lineHeightHeading1:n[6],lineHeightHeading2:n[5],lineHeightHeading3:n[4],lineHeightHeading4:n[3],lineHeightHeading5:n[2]}};function Fh(r){const{sizeUnit:t,sizeStep:e}=r;return{sizeXXL:t*(e+8),sizeXL:t*(e+4),sizeLG:t*(e+2),sizeMD:t*(e+1),sizeMS:t*e,size:t*e,sizeSM:t*(e-1),sizeXS:t*(e-2),sizeXXS:t*(e-3)}}const Yt=(r,t)=>new ft(r).setA(t).toRgbString(),kn=(r,t)=>new ft(r).darken(t).toHexString(),Eh=r=>{const t=zn(r);return{1:t[0],2:t[1],3:t[2],4:t[3],5:t[4],6:t[5],7:t[6],8:t[4],9:t[5],10:t[6]}},Ah=(r,t)=>{const e=r||"#fff",n=t||"#000";return{colorBgBase:e,colorTextBase:n,colorText:Yt(n,.88),colorTextSecondary:Yt(n,.65),colorTextTertiary:Yt(n,.45),colorTextQuaternary:Yt(n,.25),colorFill:Yt(n,.15),colorFillSecondary:Yt(n,.06),colorFillTertiary:Yt(n,.04),colorFillQuaternary:Yt(n,.02),colorBgSolid:Yt(n,1),colorBgSolidHover:Yt(n,.75),colorBgSolidActive:Yt(n,.95),colorBgLayout:kn(e,4),colorBgContainer:kn(e,0),colorBgElevated:kn(e,0),colorBgSpotlight:Yt(n,.85),colorBgBlur:"transparent",colorBorder:kn(e,15),colorBorderSecondary:kn(e,6)}};function wh(r){Ni.pink=Ni.magenta,Mi.pink=Mi.magenta;const t=Object.keys(Vu).map(e=>{const n=r[e]===Ni[e]?Mi[e]:zn(r[e]);return Array.from({length:10},()=>1).reduce((a,i,o)=>(a[`${e}-${o+1}`]=n[o],a[`${e}${o+1}`]=n[o],a),{})}).reduce((e,n)=>(e=Object.assign(Object.assign({},e),n),e),{});return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},r),t),vh(r,{generateColorPalettes:Eh,generateNeutralColorPalettes:Ah})),bh(r.fontSize)),Fh(r)),mh(r)),gh(r))}const Gu=fo(wh),Do={token:$n,override:{override:$n},hashed:!0},Ku=ve.createContext(Do),ko="ant",mi="anticon",Sh=(r,t)=>t||(r?`${ko}-${r}`:ko),Ar=L.createContext({getPrefixCls:Sh,iconPrefixCls:mi}),{Consumer:Wy}=Ar,Bh=`-ant-${Date.now()}-${Math.random()}`;function _h(r,t){const e={},n=(o,s)=>{let l=o.clone();return l=(s==null?void 0:s(l))||l,l.toRgbString()},a=(o,s)=>{const l=new ft(o),c=zn(l.toRgbString());e[`${s}-color`]=n(l),e[`${s}-color-disabled`]=c[1],e[`${s}-color-hover`]=c[4],e[`${s}-color-active`]=c[6],e[`${s}-color-outline`]=l.clone().setA(.2).toRgbString(),e[`${s}-color-deprecated-bg`]=c[0],e[`${s}-color-deprecated-border`]=c[2]};if(t.primaryColor){a(t.primaryColor,"primary");const o=new ft(t.primaryColor),s=zn(o.toRgbString());s.forEach((c,u)=>{e[`primary-${u+1}`]=c}),e["primary-color-deprecated-l-35"]=n(o,c=>c.lighten(35)),e["primary-color-deprecated-l-20"]=n(o,c=>c.lighten(20)),e["primary-color-deprecated-t-20"]=n(o,c=>c.tint(20)),e["primary-color-deprecated-t-50"]=n(o,c=>c.tint(50)),e["primary-color-deprecated-f-12"]=n(o,c=>c.setA(c.a*.12));const l=new ft(s[0]);e["primary-color-active-deprecated-f-30"]=n(l,c=>c.setA(c.a*.3)),e["primary-color-active-deprecated-d-02"]=n(l,c=>c.darken(2))}return t.successColor&&a(t.successColor,"success"),t.warningColor&&a(t.warningColor,"warning"),t.errorColor&&a(t.errorColor,"error"),t.infoColor&&a(t.infoColor,"info"),`
59
+ :root {
60
+ ${Object.keys(e).map(o=>`--${r}-${o}: ${e[o]};`).join(`
61
+ `)}
62
+ }
63
+ `.trim()}function Dh(r,t){const e=_h(r,t);wr()&&Ur(e,`${Bh}-dynamic-theme`)}const Po=L.createContext(!1),kh=({children:r,disabled:t})=>{const e=L.useContext(Po);return L.createElement(Po.Provider,{value:t??e},r)},Hn=L.createContext(void 0),Ph=({children:r,size:t})=>{const e=L.useContext(Hn);return L.createElement(Hn.Provider,{value:t||e},r)};function Ih(){const r=lr(Po),t=lr(Hn);return{componentDisabled:r,componentSize:t}}var Xu=Ot(function r(){Rt(this,r)}),Yu="CALC_UNIT",Th=new RegExp(Yu,"g");function Li(r){return typeof r=="number"?"".concat(r).concat(Yu):r}var Rh=(function(r){En(e,r);var t=An(e);function e(n,a){var i;Rt(this,e),i=t.call(this),z(we(i),"result",""),z(we(i),"unitlessCssVar",void 0),z(we(i),"lowPriority",void 0);var o=ge(n);return i.unitlessCssVar=a,n instanceof e?i.result="(".concat(n.result,")"):o==="number"?i.result=Li(n):o==="string"&&(i.result=n),i}return Ot(e,[{key:"add",value:function(a){return a instanceof e?this.result="".concat(this.result," + ").concat(a.getResult()):(typeof a=="number"||typeof a=="string")&&(this.result="".concat(this.result," + ").concat(Li(a))),this.lowPriority=!0,this}},{key:"sub",value:function(a){return a instanceof e?this.result="".concat(this.result," - ").concat(a.getResult()):(typeof a=="number"||typeof a=="string")&&(this.result="".concat(this.result," - ").concat(Li(a))),this.lowPriority=!0,this}},{key:"mul",value:function(a){return this.lowPriority&&(this.result="(".concat(this.result,")")),a instanceof e?this.result="".concat(this.result," * ").concat(a.getResult(!0)):(typeof a=="number"||typeof a=="string")&&(this.result="".concat(this.result," * ").concat(a)),this.lowPriority=!1,this}},{key:"div",value:function(a){return this.lowPriority&&(this.result="(".concat(this.result,")")),a instanceof e?this.result="".concat(this.result," / ").concat(a.getResult(!0)):(typeof a=="number"||typeof a=="string")&&(this.result="".concat(this.result," / ").concat(a)),this.lowPriority=!1,this}},{key:"getResult",value:function(a){return this.lowPriority||a?"(".concat(this.result,")"):this.result}},{key:"equal",value:function(a){var i=this,o=a||{},s=o.unit,l=!0;return typeof s=="boolean"?l=s:Array.from(this.unitlessCssVar).some(function(c){return i.result.includes(c)})&&(l=!1),this.result=this.result.replace(Th,l?"px":""),typeof this.lowPriority<"u"?"calc(".concat(this.result,")"):this.result}}]),e})(Xu),Oh=(function(r){En(e,r);var t=An(e);function e(n){var a;return Rt(this,e),a=t.call(this),z(we(a),"result",0),n instanceof e?a.result=n.result:typeof n=="number"&&(a.result=n),a}return Ot(e,[{key:"add",value:function(a){return a instanceof e?this.result+=a.result:typeof a=="number"&&(this.result+=a),this}},{key:"sub",value:function(a){return a instanceof e?this.result-=a.result:typeof a=="number"&&(this.result-=a),this}},{key:"mul",value:function(a){return a instanceof e?this.result*=a.result:typeof a=="number"&&(this.result*=a),this}},{key:"div",value:function(a){return a instanceof e?this.result/=a.result:typeof a=="number"&&(this.result/=a),this}},{key:"equal",value:function(){return this.result}}]),e})(Xu),Nh=function(t,e){var n=t==="css"?Rh:Oh;return function(a){return new n(a,e)}},p0=function(t,e){return"".concat([e,t.replace(/([A-Z]+)([A-Z][a-z]+)/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2")].filter(Boolean).join("-"))};function si(r){var t=L.useRef();t.current=r;var e=L.useCallback(function(){for(var n,a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return(n=t.current)===null||n===void 0?void 0:n.call.apply(n,[t].concat(i))},[]);return e}function Io(r){var t=L.useRef(!1),e=L.useState(r),n=ce(e,2),a=n[0],i=n[1];L.useEffect(function(){return t.current=!1,function(){t.current=!0}},[]);function o(s,l){l&&t.current||i(s)}return[a,o]}var $i={exports:{}},Le={};/**
64
+ * @license React
65
+ * react-is.production.min.js
66
+ *
67
+ * Copyright (c) Facebook, Inc. and its affiliates.
68
+ *
69
+ * This source code is licensed under the MIT license found in the
70
+ * LICENSE file in the root directory of this source tree.
71
+ */var h0;function Mh(){if(h0)return Le;h0=1;var r=Symbol.for("react.element"),t=Symbol.for("react.portal"),e=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),o=Symbol.for("react.context"),s=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),x;x=Symbol.for("react.module.reference");function p(f){if(typeof f=="object"&&f!==null){var y=f.$$typeof;switch(y){case r:switch(f=f.type,f){case e:case a:case n:case c:case u:return f;default:switch(f=f&&f.$$typeof,f){case s:case o:case l:case d:case h:case i:return f;default:return y}}case t:return y}}}return Le.ContextConsumer=o,Le.ContextProvider=i,Le.Element=r,Le.ForwardRef=l,Le.Fragment=e,Le.Lazy=d,Le.Memo=h,Le.Portal=t,Le.Profiler=a,Le.StrictMode=n,Le.Suspense=c,Le.SuspenseList=u,Le.isAsyncMode=function(){return!1},Le.isConcurrentMode=function(){return!1},Le.isContextConsumer=function(f){return p(f)===o},Le.isContextProvider=function(f){return p(f)===i},Le.isElement=function(f){return typeof f=="object"&&f!==null&&f.$$typeof===r},Le.isForwardRef=function(f){return p(f)===l},Le.isFragment=function(f){return p(f)===e},Le.isLazy=function(f){return p(f)===d},Le.isMemo=function(f){return p(f)===h},Le.isPortal=function(f){return p(f)===t},Le.isProfiler=function(f){return p(f)===a},Le.isStrictMode=function(f){return p(f)===n},Le.isSuspense=function(f){return p(f)===c},Le.isSuspenseList=function(f){return p(f)===u},Le.isValidElementType=function(f){return typeof f=="string"||typeof f=="function"||f===e||f===a||f===n||f===c||f===u||f===g||typeof f=="object"&&f!==null&&(f.$$typeof===d||f.$$typeof===h||f.$$typeof===i||f.$$typeof===o||f.$$typeof===l||f.$$typeof===x||f.getModuleId!==void 0)},Le.typeOf=p,Le}var v0;function Lh(){return v0||(v0=1,$i.exports=Mh()),$i.exports}var zi=Lh(),$h=Symbol.for("react.element"),zh=Symbol.for("react.transitional.element"),Hh=Symbol.for("react.fragment");function Qu(r){return r&&ge(r)==="object"&&(r.$$typeof===$h||r.$$typeof===zh)&&r.type===Hh}var qh=Number(af.split(".")[0]),jh=function(t,e){typeof t=="function"?t(e):ge(t)==="object"&&t&&"current"in t&&(t.current=e)},Vh=function(t){var e,n;if(!t)return!1;if(Zu(t)&&qh>=19)return!0;var a=zi.isMemo(t)?t.type.type:t.type;return!(typeof a=="function"&&!((e=a.prototype)!==null&&e!==void 0&&e.render)&&a.$$typeof!==zi.ForwardRef||typeof t=="function"&&!((n=t.prototype)!==null&&n!==void 0&&n.render)&&t.$$typeof!==zi.ForwardRef)};function Zu(r){return of(r)&&!Qu(r)}var Uh=function(t){if(t&&Zu(t)){var e=t;return e.props.propertyIsEnumerable("ref")?e.props.ref:e.ref}return null};function x0(r,t,e,n){var a=Y({},t[r]);if(n!=null&&n.deprecatedTokens){var i=n.deprecatedTokens;i.forEach(function(s){var l=ce(s,2),c=l[0],u=l[1];if(a!=null&&a[c]||a!=null&&a[u]){var h;(h=a[u])!==null&&h!==void 0||(a[u]=a==null?void 0:a[c])}})}var o=Y(Y({},e),a);return Object.keys(o).forEach(function(s){o[s]===t[s]&&delete o[s]}),o}var Ju=typeof CSSINJS_STATISTIC<"u",To=!0;function hs(){for(var r=arguments.length,t=new Array(r),e=0;e<r;e++)t[e]=arguments[e];if(!Ju)return Object.assign.apply(Object,[{}].concat(t));To=!1;var n={};return t.forEach(function(a){if(ge(a)==="object"){var i=Object.keys(a);i.forEach(function(o){Object.defineProperty(n,o,{configurable:!0,enumerable:!0,get:function(){return a[o]}})})}}),To=!0,n}var g0={};function Wh(){}var Gh=function(t){var e,n=t,a=Wh;return Ju&&typeof Proxy<"u"&&(e=new Set,n=new Proxy(t,{get:function(o,s){if(To){var l;(l=e)===null||l===void 0||l.add(s)}return o[s]}}),a=function(o,s){var l;g0[o]={global:Array.from(e),component:Y(Y({},(l=g0[o])===null||l===void 0?void 0:l.component),s)}}),{token:n,keys:e,flush:a}};function m0(r,t,e){if(typeof e=="function"){var n;return e(hs(t,(n=t[r])!==null&&n!==void 0?n:{}))}return e??{}}function Kh(r){return r==="js"?{max:Math.max,min:Math.min}:{max:function(){for(var e=arguments.length,n=new Array(e),a=0;a<e;a++)n[a]=arguments[a];return"max(".concat(n.map(function(i){return Zs(i)}).join(","),")")},min:function(){for(var e=arguments.length,n=new Array(e),a=0;a<e;a++)n[a]=arguments[a];return"min(".concat(n.map(function(i){return Zs(i)}).join(","),")")}}}var Xh=1e3*60*10,Yh=(function(){function r(){Rt(this,r),z(this,"map",new Map),z(this,"objectIDMap",new WeakMap),z(this,"nextID",0),z(this,"lastAccessBeat",new Map),z(this,"accessBeat",0)}return Ot(r,[{key:"set",value:function(e,n){this.clear();var a=this.getCompositeKey(e);this.map.set(a,n),this.lastAccessBeat.set(a,Date.now())}},{key:"get",value:function(e){var n=this.getCompositeKey(e),a=this.map.get(n);return this.lastAccessBeat.set(n,Date.now()),this.accessBeat+=1,a}},{key:"getCompositeKey",value:function(e){var n=this,a=e.map(function(i){return i&&ge(i)==="object"?"obj_".concat(n.getObjectID(i)):"".concat(ge(i),"_").concat(i)});return a.join("|")}},{key:"getObjectID",value:function(e){if(this.objectIDMap.has(e))return this.objectIDMap.get(e);var n=this.nextID;return this.objectIDMap.set(e,n),this.nextID+=1,n}},{key:"clear",value:function(){var e=this;if(this.accessBeat>1e4){var n=Date.now();this.lastAccessBeat.forEach(function(a,i){n-a>Xh&&(e.map.delete(i),e.lastAccessBeat.delete(i))}),this.accessBeat=0}}}]),r})(),y0=new Yh;function Qh(r,t){return ve.useMemo(function(){var e=y0.get(t);if(e)return e;var n=r();return y0.set(t,n),n},t)}var Zh=function(){return{}};function Jh(r){var t=r.useCSP,e=t===void 0?Zh:t,n=r.useToken,a=r.usePrefix,i=r.getResetStyles,o=r.getCommonStyle,s=r.getCompUnitless;function l(d,g,x,p){var f=Array.isArray(d)?d[0]:d;function y(A){return"".concat(String(f)).concat(A.slice(0,1).toUpperCase()).concat(A.slice(1))}var v=(p==null?void 0:p.unitless)||{},C=typeof s=="function"?s(d):{},b=Y(Y({},C),{},z({},y("zIndexPopup"),!0));Object.keys(v).forEach(function(A){b[y(A)]=v[A]});var F=Y(Y({},p),{},{unitless:b,prefixToken:y}),E=u(d,g,x,F),w=c(f,x,F);return function(A){var S=arguments.length>1&&arguments[1]!==void 0?arguments[1]:A,m=E(A,S),B=ce(m,2),_=B[1],P=w(S),T=ce(P,2),$=T[0],H=T[1];return[$,_,H]}}function c(d,g,x){var p=x.unitless,f=x.injectStyle,y=f===void 0?!0:f,v=x.prefixToken,C=x.ignore,b=function(w){var A=w.rootCls,S=w.cssVar,m=S===void 0?{}:S,B=n(),_=B.realToken;return th({path:[d],prefix:m.prefix,key:m.key,unitless:p,ignore:C,token:_,scope:A},function(){var P=m0(d,_,g),T=x0(d,_,P,{deprecatedTokens:x==null?void 0:x.deprecatedTokens});return Object.keys(P).forEach(function($){T[v($)]=T[$],delete T[$]}),T}),null},F=function(w){var A=n(),S=A.cssVar;return[function(m){return y&&S?ve.createElement(ve.Fragment,null,ve.createElement(b,{rootCls:w,cssVar:S,component:d}),m):m},S==null?void 0:S.key]};return F}function u(d,g,x){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},f=Array.isArray(d)?d:[d,d],y=ce(f,1),v=y[0],C=f.join("-"),b=r.layer||{name:"antd"};return function(F){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:F,w=n(),A=w.theme,S=w.realToken,m=w.hashId,B=w.token,_=w.cssVar,P=a(),T=P.rootPrefixCls,$=P.iconPrefixCls,H=e(),j=_?"css":"js",q=Qh(function(){var I=new Set;return _&&Object.keys(p.unitless||{}).forEach(function(U){I.add(pa(U,_.prefix)),I.add(pa(U,p0(v,_.prefix)))}),Nh(j,I)},[j,v,_==null?void 0:_.prefix]),G=Kh(j),X=G.max,O=G.min,M={theme:A,token:B,hashId:m,nonce:function(){return H.nonce},clientOnly:p.clientOnly,layer:b,order:p.order||-999};typeof i=="function"&&xo(Y(Y({},M),{},{clientOnly:!1,path:["Shared",T]}),function(){return i(B,{prefix:{rootPrefixCls:T,iconPrefixCls:$},csp:H})});var R=xo(Y(Y({},M),{},{path:[C,F,$]}),function(){if(p.injectStyle===!1)return[];var I=Gh(B),U=I.token,K=I.flush,Z=m0(v,S,x),Q=".".concat(F),J=x0(v,S,Z,{deprecatedTokens:p.deprecatedTokens});_&&Z&&ge(Z)==="object"&&Object.keys(Z).forEach(function(ie){Z[ie]="var(".concat(pa(ie,p0(v,_.prefix)),")")});var pe=hs(U,{componentCls:Q,prefixCls:F,iconCls:".".concat($),antCls:".".concat(T),calc:q,max:X,min:O},_?Z:J),Ie=g(pe,{hashId:m,prefixCls:F,rootPrefixCls:T,iconPrefixCls:$});K(v,J);var Se=typeof o=="function"?o(pe,F,E,p.resetFont):null;return[p.resetStyle===!1?null:Se,Ie]});return[R,m]}}function h(d,g,x){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},f=u(d,g,x,Y({resetStyle:!1,order:-998},p)),y=function(C){var b=C.prefixCls,F=C.rootCls,E=F===void 0?b:F;return f(b,E),null};return y}return{genStyleHooks:l,genSubStyleComponent:h,genComponentStyleHook:u}}const ev="5.28.0";function Hi(r){return r>=0&&r<=255}function aa(r,t){const{r:e,g:n,b:a,a:i}=new ft(r).toRgb();if(i<1)return r;const{r:o,g:s,b:l}=new ft(t).toRgb();for(let c=.01;c<=1;c+=.01){const u=Math.round((e-o*(1-c))/c),h=Math.round((n-s*(1-c))/c),d=Math.round((a-l*(1-c))/c);if(Hi(u)&&Hi(h)&&Hi(d))return new ft({r:u,g:h,b:d,a:Math.round(c*100)/100}).toRgbString()}return new ft({r:e,g:n,b:a,a:1}).toRgbString()}var tv=function(r,t){var e={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.indexOf(n)<0&&(e[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(e[n[a]]=r[n[a]]);return e};function el(r){const{override:t}=r,e=tv(r,["override"]),n=Object.assign({},t);Object.keys($n).forEach(d=>{delete n[d]});const a=Object.assign(Object.assign({},e),n),i=480,o=576,s=768,l=992,c=1200,u=1600;return a.motion===!1&&(a.motionDurationFast="0s",a.motionDurationMid="0s",a.motionDurationSlow="0s"),Object.assign(Object.assign(Object.assign({},a),{colorFillContent:a.colorFillSecondary,colorFillContentHover:a.colorFill,colorFillAlter:a.colorFillQuaternary,colorBgContainerDisabled:a.colorFillTertiary,colorBorderBg:a.colorBgContainer,colorSplit:aa(a.colorBorderSecondary,a.colorBgContainer),colorTextPlaceholder:a.colorTextQuaternary,colorTextDisabled:a.colorTextQuaternary,colorTextHeading:a.colorText,colorTextLabel:a.colorTextSecondary,colorTextDescription:a.colorTextTertiary,colorTextLightSolid:a.colorWhite,colorHighlight:a.colorError,colorBgTextHover:a.colorFillSecondary,colorBgTextActive:a.colorFill,colorIcon:a.colorTextTertiary,colorIconHover:a.colorText,colorErrorOutline:aa(a.colorErrorBg,a.colorBgContainer),colorWarningOutline:aa(a.colorWarningBg,a.colorBgContainer),fontSizeIcon:a.fontSizeSM,lineWidthFocus:a.lineWidth*3,lineWidth:a.lineWidth,controlOutlineWidth:a.lineWidth*2,controlInteractiveSize:a.controlHeight/2,controlItemBgHover:a.colorFillTertiary,controlItemBgActive:a.colorPrimaryBg,controlItemBgActiveHover:a.colorPrimaryBgHover,controlItemBgActiveDisabled:a.colorFill,controlTmpOutline:a.colorFillQuaternary,controlOutline:aa(a.colorPrimaryBg,a.colorBgContainer),lineType:a.lineType,borderRadius:a.borderRadius,borderRadiusXS:a.borderRadiusXS,borderRadiusSM:a.borderRadiusSM,borderRadiusLG:a.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:a.sizeXXS,paddingXS:a.sizeXS,paddingSM:a.sizeSM,padding:a.size,paddingMD:a.sizeMD,paddingLG:a.sizeLG,paddingXL:a.sizeXL,paddingContentHorizontalLG:a.sizeLG,paddingContentVerticalLG:a.sizeMS,paddingContentHorizontal:a.sizeMS,paddingContentVertical:a.sizeSM,paddingContentHorizontalSM:a.size,paddingContentVerticalSM:a.sizeXS,marginXXS:a.sizeXXS,marginXS:a.sizeXS,marginSM:a.sizeSM,margin:a.size,marginMD:a.sizeMD,marginLG:a.sizeLG,marginXL:a.sizeXL,marginXXL:a.sizeXXL,boxShadow:`
72
+ 0 6px 16px 0 rgba(0, 0, 0, 0.08),
73
+ 0 3px 6px -4px rgba(0, 0, 0, 0.12),
74
+ 0 9px 28px 8px rgba(0, 0, 0, 0.05)
75
+ `,boxShadowSecondary:`
76
+ 0 6px 16px 0 rgba(0, 0, 0, 0.08),
77
+ 0 3px 6px -4px rgba(0, 0, 0, 0.12),
78
+ 0 9px 28px 8px rgba(0, 0, 0, 0.05)
79
+ `,boxShadowTertiary:`
80
+ 0 1px 2px 0 rgba(0, 0, 0, 0.03),
81
+ 0 1px 6px -1px rgba(0, 0, 0, 0.02),
82
+ 0 2px 4px 0 rgba(0, 0, 0, 0.02)
83
+ `,screenXS:i,screenXSMin:i,screenXSMax:o-1,screenSM:o,screenSMMin:o,screenSMMax:s-1,screenMD:s,screenMDMin:s,screenMDMax:l-1,screenLG:l,screenLGMin:l,screenLGMax:c-1,screenXL:c,screenXLMin:c,screenXLMax:u-1,screenXXL:u,screenXXLMin:u,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:`
84
+ 0 1px 2px -2px ${new ft("rgba(0, 0, 0, 0.16)").toRgbString()},
85
+ 0 3px 6px 0 ${new ft("rgba(0, 0, 0, 0.12)").toRgbString()},
86
+ 0 5px 12px 4px ${new ft("rgba(0, 0, 0, 0.09)").toRgbString()}
87
+ `,boxShadowDrawerRight:`
88
+ -6px 0 16px 0 rgba(0, 0, 0, 0.08),
89
+ -3px 0 6px -4px rgba(0, 0, 0, 0.12),
90
+ -9px 0 28px 8px rgba(0, 0, 0, 0.05)
91
+ `,boxShadowDrawerLeft:`
92
+ 6px 0 16px 0 rgba(0, 0, 0, 0.08),
93
+ 3px 0 6px -4px rgba(0, 0, 0, 0.12),
94
+ 9px 0 28px 8px rgba(0, 0, 0, 0.05)
95
+ `,boxShadowDrawerUp:`
96
+ 0 6px 16px 0 rgba(0, 0, 0, 0.08),
97
+ 0 3px 6px -4px rgba(0, 0, 0, 0.12),
98
+ 0 9px 28px 8px rgba(0, 0, 0, 0.05)
99
+ `,boxShadowDrawerDown:`
100
+ 0 -6px 16px 0 rgba(0, 0, 0, 0.08),
101
+ 0 -3px 6px -4px rgba(0, 0, 0, 0.12),
102
+ 0 -9px 28px 8px rgba(0, 0, 0, 0.05)
103
+ `,boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)"}),n)}var C0=function(r,t){var e={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.indexOf(n)<0&&(e[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(e[n[a]]=r[n[a]]);return e};const tl={lineHeight:!0,lineHeightSM:!0,lineHeightLG:!0,lineHeightHeading1:!0,lineHeightHeading2:!0,lineHeightHeading3:!0,lineHeightHeading4:!0,lineHeightHeading5:!0,opacityLoading:!0,fontWeightStrong:!0,zIndexPopupBase:!0,zIndexBase:!0,opacityImage:!0},rv={motionBase:!0,motionUnit:!0},nv={screenXS:!0,screenXSMin:!0,screenXSMax:!0,screenSM:!0,screenSMMin:!0,screenSMMax:!0,screenMD:!0,screenMDMin:!0,screenMDMax:!0,screenLG:!0,screenLGMin:!0,screenLGMax:!0,screenXL:!0,screenXLMin:!0,screenXLMax:!0,screenXXL:!0,screenXXLMin:!0},rl=(r,t,e)=>{const n=e.getDerivativeToken(r),{override:a}=t,i=C0(t,["override"]);let o=Object.assign(Object.assign({},n),{override:a});return o=el(o),i&&Object.entries(i).forEach(([s,l])=>{const{theme:c}=l,u=C0(l,["theme"]);let h=u;c&&(h=rl(Object.assign(Object.assign({},o),u),{override:u},c)),o[s]=h}),o};function yi(){const{token:r,hashed:t,theme:e,override:n,cssVar:a}=ve.useContext(Ku),i=`${ev}-${t||""}`,o=e||Gu,[s,l,c]=Bp(o,[$n,r],{salt:i,override:n,getComputedToken:rl,formatToken:el,cssVar:a&&{prefix:a.prefix,key:a.key,unitless:tl,ignore:rv,preserve:nv}});return[o,c,t?l:"",s,a]}const av=(r,t=!1)=>({boxSizing:"border-box",margin:0,padding:0,color:r.colorText,fontSize:r.fontSize,lineHeight:r.lineHeight,listStyle:"none",fontFamily:t?"inherit":r.fontFamily}),iv=()=>({display:"inline-flex",alignItems:"center",color:"inherit",fontStyle:"normal",lineHeight:0,textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizeLegibility","-webkit-font-smoothing":"antialiased","-moz-osx-font-smoothing":"grayscale","> *":{lineHeight:1},svg:{display:"inline-block"}}),ov=r=>({a:{color:r.colorLink,textDecoration:r.linkDecoration,backgroundColor:"transparent",outline:"none",cursor:"pointer",transition:`color ${r.motionDurationSlow}`,"-webkit-text-decoration-skip":"objects","&:hover":{color:r.colorLinkHover},"&:active":{color:r.colorLinkActive},"&:active, &:hover":{textDecoration:r.linkHoverDecoration,outline:0},"&:focus":{textDecoration:r.linkFocusDecoration,outline:0},"&[disabled]":{color:r.colorTextDisabled,cursor:"not-allowed"}}}),sv=(r,t,e,n)=>{const a=`[class^="${t}"], [class*=" ${t}"]`,i=e?`.${e}`:a,o={boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}};let s={};return n!==!1&&(s={fontFamily:r.fontFamily,fontSize:r.fontSize}),{[i]:Object.assign(Object.assign(Object.assign({},s),o),{[a]:o})}},nl=r=>({[`.${r}`]:Object.assign(Object.assign({},iv()),{[`.${r} .${r}-icon`]:{display:"block"}})}),{genStyleHooks:cv}=Jh({usePrefix:()=>{const{getPrefixCls:r,iconPrefixCls:t}=lr(Ar);return{rootPrefixCls:r(),iconPrefixCls:t}},useToken:()=>{const[r,t,e,n,a]=yi();return{theme:r,realToken:t,hashId:e,token:n,cssVar:a}},useCSP:()=>{const{csp:r}=lr(Ar);return r??{}},getResetStyles:(r,t)=>{var e;const n=ov(r);return[n,{"&":n},nl((e=t==null?void 0:t.prefix.iconPrefixCls)!==null&&e!==void 0?e:mi)]},getCommonStyle:sv,getCompUnitless:()=>tl}),uv=(r,t)=>{const[e,n]=yi();return xo({token:n,hashId:"",path:["ant-design-icons",r],nonce:()=>t==null?void 0:t.nonce,layer:{name:"antd"}},()=>nl(r))},lv=Object.assign({},L),{useId:b0}=lv,fv=()=>"",dv=typeof b0>"u"?fv:b0;function pv(r,t,e){var n;const a=r||{},i=a.inherit===!1||!t?Object.assign(Object.assign({},Do),{hashed:(n=t==null?void 0:t.hashed)!==null&&n!==void 0?n:Do.hashed,cssVar:t==null?void 0:t.cssVar}):t,o=dv();return wu(()=>{var s,l;if(!r)return t;const c=Object.assign({},i.components);Object.keys(r.components||{}).forEach(d=>{c[d]=Object.assign(Object.assign({},c[d]),r.components[d])});const u=`css-var-${o.replace(/:/g,"")}`,h=((s=a.cssVar)!==null&&s!==void 0?s:i.cssVar)&&Object.assign(Object.assign(Object.assign({prefix:e==null?void 0:e.prefixCls},typeof i.cssVar=="object"?i.cssVar:{}),typeof a.cssVar=="object"?a.cssVar:{}),{key:typeof a.cssVar=="object"&&((l=a.cssVar)===null||l===void 0?void 0:l.key)||u});return Object.assign(Object.assign(Object.assign({},i),a),{token:Object.assign(Object.assign({},i.token),a.token),components:c,cssVar:h})},[a,i],(s,l)=>s.some((c,u)=>{const h=l[u];return!uo(c,h,!0)}))}var qi={exports:{}};/*!
104
+ Copyright (c) 2018 Jed Watson.
105
+ Licensed under the MIT License (MIT), see
106
+ http://jedwatson.github.io/classnames
107
+ */var F0;function hv(){return F0||(F0=1,(function(r){(function(){var t={}.hasOwnProperty;function e(){for(var i="",o=0;o<arguments.length;o++){var s=arguments[o];s&&(i=a(i,n(s)))}return i}function n(i){if(typeof i=="string"||typeof i=="number")return i;if(typeof i!="object")return"";if(Array.isArray(i))return e.apply(null,i);if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]"))return i.toString();var o="";for(var s in i)t.call(i,s)&&i[s]&&(o=a(o,s));return o}function a(i,o){return o?i?i+" "+o:i+o:i}r.exports?(e.default=e,r.exports=e):window.classNames=e})()})(qi)),qi.exports}var vv=hv();const ur=es(vv);function E0(r){return r instanceof HTMLElement||r instanceof SVGElement}function al(r){return r&&ge(r)==="object"&&E0(r.nativeElement)?r.nativeElement:E0(r)?r:null}function xv(r){var t=al(r);if(t)return t;if(r instanceof ve.Component){var e;return(e=ks.findDOMNode)===null||e===void 0?void 0:e.call(ks,r)}return null}var gv=["children"],il=L.createContext({});function mv(r){var t=r.children,e=Cr(r,gv);return L.createElement(il.Provider,{value:e},t)}var yv=(function(r){En(e,r);var t=An(e);function e(){return Rt(this,e),t.apply(this,arguments)}return Ot(e,[{key:"render",value:function(){return this.props.children}}]),e})(L.Component);function Cv(r){var t=L.useReducer(function(s){return s+1},0),e=ce(t,2),n=e[1],a=L.useRef(r),i=si(function(){return a.current}),o=si(function(s){a.current=typeof s=="function"?s(a.current):s,n()});return[i,o]}var Rr="none",ia="appear",oa="enter",sa="leave",A0="none",or="prepare",ln="start",fn="active",vs="end",ol="prepared";function w0(r,t){var e={};return e[r.toLowerCase()]=t.toLowerCase(),e["Webkit".concat(r)]="webkit".concat(t),e["Moz".concat(r)]="moz".concat(t),e["ms".concat(r)]="MS".concat(t),e["O".concat(r)]="o".concat(t.toLowerCase()),e}function bv(r,t){var e={animationend:w0("Animation","AnimationEnd"),transitionend:w0("Transition","TransitionEnd")};return r&&("AnimationEvent"in t||delete e.animationend.animation,"TransitionEvent"in t||delete e.transitionend.transition),e}var Fv=bv(wr(),typeof window<"u"?window:{}),sl={};if(wr()){var Ev=document.createElement("div");sl=Ev.style}var ca={};function cl(r){if(ca[r])return ca[r];var t=Fv[r];if(t)for(var e=Object.keys(t),n=e.length,a=0;a<n;a+=1){var i=e[a];if(Object.prototype.hasOwnProperty.call(t,i)&&i in sl)return ca[r]=t[i],ca[r]}return""}var ul=cl("animationend"),ll=cl("transitionend"),fl=!!(ul&&ll),S0=ul||"animationend",B0=ll||"transitionend";function _0(r,t){if(!r)return null;if(ge(r)==="object"){var e=t.replace(/-\w/g,function(n){return n[1].toUpperCase()});return r[e]}return"".concat(r,"-").concat(t)}const Av=(function(r){var t=Ve();function e(a){a&&(a.removeEventListener(B0,r),a.removeEventListener(S0,r))}function n(a){t.current&&t.current!==a&&e(t.current),a&&a!==t.current&&(a.addEventListener(B0,r),a.addEventListener(S0,r),t.current=a)}return L.useEffect(function(){return function(){e(t.current)}},[]),[n,e]});var dl=wr()?sf:De,pl=function(t){return+setTimeout(t,16)},hl=function(t){return clearTimeout(t)};typeof window<"u"&&"requestAnimationFrame"in window&&(pl=function(t){return window.requestAnimationFrame(t)},hl=function(t){return window.cancelAnimationFrame(t)});var D0=0,xs=new Map;function vl(r){xs.delete(r)}var Ro=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;D0+=1;var n=D0;function a(i){if(i===0)vl(n),t();else{var o=pl(function(){a(i-1)});xs.set(n,o)}}return a(e),n};Ro.cancel=function(r){var t=xs.get(r);return vl(r),hl(t)};const wv=(function(){var r=L.useRef(null);function t(){Ro.cancel(r.current)}function e(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;t();var i=Ro(function(){a<=1?n({isCanceled:function(){return i!==r.current}}):e(n,a-1)});r.current=i}return L.useEffect(function(){return function(){t()}},[]),[e,t]});var Sv=[or,ln,fn,vs],Bv=[or,ol],xl=!1,_v=!0;function gl(r){return r===fn||r===vs}const Dv=(function(r,t,e){var n=Io(A0),a=ce(n,2),i=a[0],o=a[1],s=wv(),l=ce(s,2),c=l[0],u=l[1];function h(){o(or,!0)}var d=t?Bv:Sv;return dl(function(){if(i!==A0&&i!==vs){var g=d.indexOf(i),x=d[g+1],p=e(i);p===xl?o(x,!0):x&&c(function(f){function y(){f.isCanceled()||o(x,!0)}p===!0?y():Promise.resolve(p).then(y)})}},[r,i]),L.useEffect(function(){return function(){u()}},[]),[h,i]});function kv(r,t,e,n){var a=n.motionEnter,i=a===void 0?!0:a,o=n.motionAppear,s=o===void 0?!0:o,l=n.motionLeave,c=l===void 0?!0:l,u=n.motionDeadline,h=n.motionLeaveImmediately,d=n.onAppearPrepare,g=n.onEnterPrepare,x=n.onLeavePrepare,p=n.onAppearStart,f=n.onEnterStart,y=n.onLeaveStart,v=n.onAppearActive,C=n.onEnterActive,b=n.onLeaveActive,F=n.onAppearEnd,E=n.onEnterEnd,w=n.onLeaveEnd,A=n.onVisibleChanged,S=Io(),m=ce(S,2),B=m[0],_=m[1],P=Cv(Rr),T=ce(P,2),$=T[0],H=T[1],j=Io(null),q=ce(j,2),G=q[0],X=q[1],O=$(),M=Ve(!1),R=Ve(null);function I(){return e()}var U=Ve(!1);function K(){H(Rr),X(null,!0)}var Z=si(function(Fe){var ye=$();if(ye!==Rr){var ke=I();if(!(Fe&&!Fe.deadline&&Fe.target!==ke)){var Me=U.current,ze;ye===ia&&Me?ze=F==null?void 0:F(ke,Fe):ye===oa&&Me?ze=E==null?void 0:E(ke,Fe):ye===sa&&Me&&(ze=w==null?void 0:w(ke,Fe)),Me&&ze!==!1&&K()}}}),Q=Av(Z),J=ce(Q,1),pe=J[0],Ie=function(ye){switch(ye){case ia:return z(z(z({},or,d),ln,p),fn,v);case oa:return z(z(z({},or,g),ln,f),fn,C);case sa:return z(z(z({},or,x),ln,y),fn,b);default:return{}}},Se=L.useMemo(function(){return Ie(O)},[O]),ie=Dv(O,!r,function(Fe){if(Fe===or){var ye=Se[or];return ye?ye(I()):xl}if(he in Se){var ke;X(((ke=Se[he])===null||ke===void 0?void 0:ke.call(Se,I(),null))||null)}return he===fn&&O!==Rr&&(pe(I()),u>0&&(clearTimeout(R.current),R.current=setTimeout(function(){Z({deadline:!0})},u))),he===ol&&K(),_v}),Ae=ce(ie,2),Ne=Ae[0],he=Ae[1],it=gl(he);U.current=it;var et=Ve(null);dl(function(){if(!(M.current&&et.current===t)){_(t);var Fe=M.current;M.current=!0;var ye;!Fe&&t&&s&&(ye=ia),Fe&&t&&i&&(ye=oa),(Fe&&!t&&c||!Fe&&h&&!t&&c)&&(ye=sa);var ke=Ie(ye);ye&&(r||ke[or])?(H(ye),Ne()):H(Rr),et.current=t}},[t]),De(function(){(O===ia&&!s||O===oa&&!i||O===sa&&!c)&&H(Rr)},[s,i,c]),De(function(){return function(){M.current=!1,clearTimeout(R.current)}},[]);var tt=L.useRef(!1);De(function(){B&&(tt.current=!0),B!==void 0&&O===Rr&&((tt.current||B)&&(A==null||A(B)),tt.current=!0)},[B,O]);var st=G;return Se[or]&&he===ln&&(st=Y({transition:"none"},st)),[O,he,st,B??t]}function Pv(r){var t=r;ge(r)==="object"&&(t=r.transitionSupport);function e(a,i){return!!(a.motionName&&t&&i!==!1)}var n=L.forwardRef(function(a,i){var o=a.visible,s=o===void 0?!0:o,l=a.removeOnLeave,c=l===void 0?!0:l,u=a.forceRender,h=a.children,d=a.motionName,g=a.leavedClassName,x=a.eventProps,p=L.useContext(il),f=p.motion,y=e(a,f),v=Ve(),C=Ve();function b(){try{return v.current instanceof HTMLElement?v.current:xv(C.current)}catch{return null}}var F=kv(y,s,b,a),E=ce(F,4),w=E[0],A=E[1],S=E[2],m=E[3],B=L.useRef(m);m&&(B.current=!0);var _=L.useCallback(function(q){v.current=q,jh(i,q)},[i]),P,T=Y(Y({},x),{},{visible:s});if(!h)P=null;else if(w===Rr)m?P=h(Y({},T),_):!c&&B.current&&g?P=h(Y(Y({},T),{},{className:g}),_):u||!c&&!g?P=h(Y(Y({},T),{},{style:{display:"none"}}),_):P=null;else{var $;A===or?$="prepare":gl(A)?$="active":A===ln&&($="start");var H=_0(d,"".concat(w,"-").concat($));P=h(Y(Y({},T),{},{className:ur(_0(d,w),z(z({},H,H&&$),d,typeof d=="string")),style:S}),_)}if(L.isValidElement(P)&&Vh(P)){var j=Uh(P);j||(P=L.cloneElement(P,{ref:_}))}return L.createElement(yv,{ref:C},P)});return n.displayName="CSSMotion",n}const Iv=Pv(fl);var Oo="add",No="keep",Mo="remove",ji="removed";function Tv(r){var t;return r&&ge(r)==="object"&&"key"in r?t=r:t={key:r},Y(Y({},t),{},{key:String(t.key)})}function Lo(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return r.map(Tv)}function Rv(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],e=[],n=0,a=t.length,i=Lo(r),o=Lo(t);i.forEach(function(c){for(var u=!1,h=n;h<a;h+=1){var d=o[h];if(d.key===c.key){n<h&&(e=e.concat(o.slice(n,h).map(function(g){return Y(Y({},g),{},{status:Oo})})),n=h),e.push(Y(Y({},d),{},{status:No})),n+=1,u=!0;break}}u||e.push(Y(Y({},c),{},{status:Mo}))}),n<a&&(e=e.concat(o.slice(n).map(function(c){return Y(Y({},c),{},{status:Oo})})));var s={};e.forEach(function(c){var u=c.key;s[u]=(s[u]||0)+1});var l=Object.keys(s).filter(function(c){return s[c]>1});return l.forEach(function(c){e=e.filter(function(u){var h=u.key,d=u.status;return h!==c||d!==Mo}),e.forEach(function(u){u.key===c&&(u.status=No)})}),e}var Ov=["component","children","onVisibleChanged","onAllRemoved"],Nv=["status"],Mv=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function Lv(r){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Iv,e=(function(n){En(i,n);var a=An(i);function i(){var o;Rt(this,i);for(var s=arguments.length,l=new Array(s),c=0;c<s;c++)l[c]=arguments[c];return o=a.call.apply(a,[this].concat(l)),z(we(o),"state",{keyEntities:[]}),z(we(o),"removeKey",function(u){o.setState(function(h){var d=h.keyEntities.map(function(g){return g.key!==u?g:Y(Y({},g),{},{status:ji})});return{keyEntities:d}},function(){var h=o.state.keyEntities,d=h.filter(function(g){var x=g.status;return x!==ji}).length;d===0&&o.props.onAllRemoved&&o.props.onAllRemoved()})}),o}return Ot(i,[{key:"render",value:function(){var s=this,l=this.state.keyEntities,c=this.props,u=c.component,h=c.children,d=c.onVisibleChanged;c.onAllRemoved;var g=Cr(c,Ov),x=u||L.Fragment,p={};return Mv.forEach(function(f){p[f]=g[f],delete g[f]}),delete g.keys,L.createElement(x,g,l.map(function(f,y){var v=f.status,C=Cr(f,Nv),b=v===Oo||v===No;return L.createElement(t,bt({},p,{key:C.key,visible:b,eventProps:C,onVisibleChanged:function(E){d==null||d(E,{key:C.key}),E||s.removeKey(C.key)}}),function(F,E){return h(Y(Y({},F),{},{index:y}),E)})}))}}],[{key:"getDerivedStateFromProps",value:function(s,l){var c=s.keys,u=l.keyEntities,h=Lo(c),d=Rv(u,h);return{keyEntities:d.filter(function(g){var x=u.find(function(p){var f=p.key;return g.key===f});return!(x&&x.status===ji&&g.status===Mo)})}}}]),i})(L.Component);return z(e,"defaultProps",{component:"div"}),e}const $v=Lv(fl),k0=L.createContext(!0);function zv(r){const t=L.useContext(k0),{children:e}=r,[,n]=yi(),{motion:a}=n,i=L.useRef(!1);return i.current||(i.current=t!==a),i.current?L.createElement(k0.Provider,{value:a},L.createElement(mv,{motion:a},e)):e}const Hv=()=>null;var qv=function(r,t){var e={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.indexOf(n)<0&&(e[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(e[n[a]]=r[n[a]]);return e};const jv=["getTargetContainer","getPopupContainer","renderEmpty","input","pagination","form","select","button"];let ci,ml,yl,Cl;function ya(){return ci||ko}function Vv(){return ml||mi}function Uv(r){return Object.keys(r).some(t=>t.endsWith("Color"))}const Wv=r=>{const{prefixCls:t,iconPrefixCls:e,theme:n,holderRender:a}=r;t!==void 0&&(ci=t),e!==void 0&&(ml=e),"holderRender"in r&&(Cl=a),n&&(Uv(n)?Dh(ya(),n):yl=n)},Gv=()=>({getPrefixCls:(r,t)=>t||(r?`${ya()}-${r}`:ya()),getIconPrefixCls:Vv,getRootPrefixCls:()=>ci||ya(),getTheme:()=>yl,holderRender:Cl}),Kv=r=>{const{children:t,csp:e,autoInsertSpaceInButton:n,alert:a,anchor:i,form:o,locale:s,componentSize:l,direction:c,space:u,splitter:h,virtual:d,dropdownMatchSelectWidth:g,popupMatchSelectWidth:x,popupOverflow:p,legacyLocale:f,parentContext:y,iconPrefixCls:v,theme:C,componentDisabled:b,segmented:F,statistic:E,spin:w,calendar:A,carousel:S,cascader:m,collapse:B,typography:_,checkbox:P,descriptions:T,divider:$,drawer:H,skeleton:j,steps:q,image:G,layout:X,list:O,mentions:M,modal:R,progress:I,result:U,slider:K,breadcrumb:Z,menu:Q,pagination:J,input:pe,textArea:Ie,empty:Se,badge:ie,radio:Ae,rate:Ne,switch:he,transfer:it,avatar:et,message:tt,tag:st,table:Fe,card:ye,tabs:ke,timeline:Me,timePicker:ze,upload:ee,notification:Ce,tree:ot,colorPicker:Dt,datePicker:kt,rangePicker:Lt,flex:Re,wave:$t,dropdown:fr,warning:Br,tour:Pt,tooltip:br,popover:dr,popconfirm:$r,floatButton:pr,floatButtonGroup:zr,variant:_r,inputNumber:Hr,treeSelect:zt}=r,Et=L.useCallback((Oe,He)=>{const{prefixCls:dt}=r;if(He)return He;const vt=dt||y.getPrefixCls("");return Oe?`${vt}-${Oe}`:vt},[y.getPrefixCls,r.prefixCls]),It=v||y.iconPrefixCls||mi,Ht=e||y.csp;uv(It,Ht);const er=pv(C,y.theme,{prefixCls:Et("")}),Gt={csp:Ht,autoInsertSpaceInButton:n,alert:a,anchor:i,locale:s||f,direction:c,space:u,splitter:h,virtual:d,popupMatchSelectWidth:x??g,popupOverflow:p,getPrefixCls:Et,iconPrefixCls:It,theme:er,segmented:F,statistic:E,spin:w,calendar:A,carousel:S,cascader:m,collapse:B,typography:_,checkbox:P,descriptions:T,divider:$,drawer:H,skeleton:j,steps:q,image:G,input:pe,textArea:Ie,layout:X,list:O,mentions:M,modal:R,progress:I,result:U,slider:K,breadcrumb:Z,menu:Q,pagination:J,empty:Se,badge:ie,radio:Ae,rate:Ne,switch:he,transfer:it,avatar:et,message:tt,tag:st,table:Fe,card:ye,tabs:ke,timeline:Me,timePicker:ze,upload:ee,notification:Ce,tree:ot,colorPicker:Dt,datePicker:kt,rangePicker:Lt,flex:Re,wave:$t,dropdown:fr,warning:Br,tour:Pt,tooltip:br,popover:dr,popconfirm:$r,floatButton:pr,floatButtonGroup:zr,variant:_r,inputNumber:Hr,treeSelect:zt},Qe=Object.assign({},y);Object.keys(Gt).forEach(Oe=>{Gt[Oe]!==void 0&&(Qe[Oe]=Gt[Oe])}),jv.forEach(Oe=>{const He=r[Oe];He&&(Qe[Oe]=He)}),typeof n<"u"&&(Qe.button=Object.assign({autoInsertSpace:n},Qe.button));const se=wu(()=>Qe,Qe,(Oe,He)=>{const dt=Object.keys(Oe),vt=Object.keys(He);return dt.length!==vt.length||dt.some(rr=>Oe[rr]!==He[rr])}),{layer:rt}=L.useContext(Wn),At=L.useMemo(()=>({prefixCls:It,csp:Ht,layer:rt?"antd":void 0}),[It,Ht,rt]);let be=L.createElement(L.Fragment,null,L.createElement(Hv,{dropdownMatchSelectWidth:g}),t);const nt=L.useMemo(()=>{var Oe,He,dt,vt;return un(((Oe=gi.Form)===null||Oe===void 0?void 0:Oe.defaultValidateMessages)||{},((dt=(He=se.locale)===null||He===void 0?void 0:He.Form)===null||dt===void 0?void 0:dt.defaultValidateMessages)||{},((vt=se.form)===null||vt===void 0?void 0:vt.validateMessages)||{},(o==null?void 0:o.validateMessages)||{})},[se,o==null?void 0:o.validateMessages]);Object.keys(nt).length>0&&(be=L.createElement(sh.Provider,{value:nt},be)),s&&(be=L.createElement(lh,{locale:s,_ANT_MARK__:uh},be)),be=L.createElement(ps.Provider,{value:At},be),l&&(be=L.createElement(Ph,{size:l},be)),be=L.createElement(zv,null,be);const tr=L.useMemo(()=>{const Oe=er||{},{algorithm:He,token:dt,components:vt,cssVar:rr}=Oe,Yr=qv(Oe,["algorithm","token","components","cssVar"]),qt=He&&(!Array.isArray(He)||He.length>0)?fo(He):Gu,hr={};Object.entries(vt||{}).forEach(([Zr,Jr])=>{const Nt=Object.assign({},Jr);"algorithm"in Nt&&(Nt.algorithm===!0?Nt.theme=qt:(Array.isArray(Nt.algorithm)||typeof Nt.algorithm=="function")&&(Nt.theme=fo(Nt.algorithm)),delete Nt.algorithm),hr[Zr]=Nt});const Qr=Object.assign(Object.assign({},$n),dt);return Object.assign(Object.assign({},Yr),{theme:qt,token:Qr,components:hr,override:Object.assign({override:Qr},hr),cssVar:rr})},[er]);return C&&(be=L.createElement(Ku.Provider,{value:tr},be)),se.warning&&(be=L.createElement(oh.Provider,{value:se.warning},be)),b!==void 0&&(be=L.createElement(kh,{disabled:b},be)),L.createElement(Ar.Provider,{value:se},be)},Sn=r=>{const t=L.useContext(Ar),e=L.useContext(ju);return L.createElement(Kv,Object.assign({parentContext:t,legacyLocale:e},r))};Sn.ConfigContext=Ar;Sn.SizeContext=Hn;Sn.config=Wv;Sn.useConfig=Ih;Object.defineProperty(Sn,"SizeContext",{get:()=>Hn});function bl(r,t){this.v=r,this.k=t}function Bt(r,t,e,n){var a=Object.defineProperty;try{a({},"",{})}catch{a=0}Bt=function(o,s,l,c){function u(h,d){Bt(o,h,function(g){return this._invoke(h,d,g)})}s?a?a(o,s,{value:l,enumerable:!c,configurable:!c,writable:!c}):o[s]=l:(u("next",0),u("throw",1),u("return",2))},Bt(r,t,e,n)}function gs(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */var r,t,e=typeof Symbol=="function"?Symbol:{},n=e.iterator||"@@iterator",a=e.toStringTag||"@@toStringTag";function i(g,x,p,f){var y=x&&x.prototype instanceof s?x:s,v=Object.create(y.prototype);return Bt(v,"_invoke",(function(C,b,F){var E,w,A,S=0,m=F||[],B=!1,_={p:0,n:0,v:r,a:P,f:P.bind(r,4),d:function($,H){return E=$,w=0,A=r,_.n=H,o}};function P(T,$){for(w=T,A=$,t=0;!B&&S&&!H&&t<m.length;t++){var H,j=m[t],q=_.p,G=j[2];T>3?(H=G===$)&&(A=j[(w=j[4])?5:(w=3,3)],j[4]=j[5]=r):j[0]<=q&&((H=T<2&&q<j[1])?(w=0,_.v=$,_.n=j[1]):q<G&&(H=T<3||j[0]>$||$>G)&&(j[4]=T,j[5]=$,_.n=G,w=0))}if(H||T>1)return o;throw B=!0,$}return function(T,$,H){if(S>1)throw TypeError("Generator is already running");for(B&&$===1&&P($,H),w=$,A=H;(t=w<2?r:A)||!B;){E||(w?w<3?(w>1&&(_.n=-1),P(w,A)):_.n=A:_.v=A);try{if(S=2,E){if(w||(T="next"),t=E[T]){if(!(t=t.call(E,A)))throw TypeError("iterator result is not an object");if(!t.done)return t;A=t.value,w<2&&(w=0)}else w===1&&(t=E.return)&&t.call(E),w<2&&(A=TypeError("The iterator does not provide a '"+T+"' method"),w=1);E=r}else if((t=(B=_.n<0)?A:C.call(b,_))!==o)break}catch(j){E=r,w=1,A=j}finally{S=1}}return{value:t,done:B}}})(g,p,f),!0),v}var o={};function s(){}function l(){}function c(){}t=Object.getPrototypeOf;var u=[][n]?t(t([][n]())):(Bt(t={},n,function(){return this}),t),h=c.prototype=s.prototype=Object.create(u);function d(g){return Object.setPrototypeOf?Object.setPrototypeOf(g,c):(g.__proto__=c,Bt(g,a,"GeneratorFunction")),g.prototype=Object.create(h),g}return l.prototype=c,Bt(h,"constructor",c),Bt(c,"constructor",l),l.displayName="GeneratorFunction",Bt(c,a,"GeneratorFunction"),Bt(h),Bt(h,a,"Generator"),Bt(h,n,function(){return this}),Bt(h,"toString",function(){return"[object Generator]"}),(gs=function(){return{w:i,m:d}})()}function ui(r,t){function e(a,i,o,s){try{var l=r[a](i),c=l.value;return c instanceof bl?t.resolve(c.v).then(function(u){e("next",u,o,s)},function(u){e("throw",u,o,s)}):t.resolve(c).then(function(u){l.value=u,o(l)},function(u){return e("throw",u,o,s)})}catch(u){s(u)}}var n;this.next||(Bt(ui.prototype),Bt(ui.prototype,typeof Symbol=="function"&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),Bt(this,"_invoke",function(a,i,o){function s(){return new t(function(l,c){e(a,o,l,c)})}return n=n?n.then(s,s):s()},!0)}function Fl(r,t,e,n,a){return new ui(gs().w(r,t,e,n),a||Promise)}function Xv(r,t,e,n,a){var i=Fl(r,t,e,n,a);return i.next().then(function(o){return o.done?o.value:i.next()})}function Yv(r){var t=Object(r),e=[];for(var n in t)e.unshift(n);return function a(){for(;e.length;)if((n=e.pop())in t)return a.value=n,a.done=!1,a;return a.done=!0,a}}function P0(r){if(r!=null){var t=r[typeof Symbol=="function"&&Symbol.iterator||"@@iterator"],e=0;if(t)return t.call(r);if(typeof r.next=="function")return r;if(!isNaN(r.length))return{next:function(){return r&&e>=r.length&&(r=void 0),{value:r&&r[e++],done:!r}}}}throw new TypeError(ge(r)+" is not iterable")}function _t(){var r=gs(),t=r.m(_t),e=(Object.getPrototypeOf?Object.getPrototypeOf(t):t.__proto__).constructor;function n(o){var s=typeof o=="function"&&o.constructor;return!!s&&(s===e||(s.displayName||s.name)==="GeneratorFunction")}var a={throw:1,return:2,break:3,continue:3};function i(o){var s,l;return function(c){s||(s={stop:function(){return l(c.a,2)},catch:function(){return c.v},abrupt:function(h,d){return l(c.a,a[h],d)},delegateYield:function(h,d,g){return s.resultName=d,l(c.d,P0(h),g)},finish:function(h){return l(c.f,h)}},l=function(h,d,g){c.p=s.prev,c.n=s.next;try{return h(d,g)}finally{s.next=c.n}}),s.resultName&&(s[s.resultName]=c.v,s.resultName=void 0),s.sent=c.v,s.next=c.n;try{return o.call(this,s)}finally{c.p=s.prev,c.n=s.next}}}return(_t=function(){return{wrap:function(l,c,u,h){return r.w(i(l),c,u,h&&h.reverse())},isGeneratorFunction:n,mark:r.m,awrap:function(l,c){return new bl(l,c)},AsyncIterator:ui,async:function(l,c,u,h,d){return(n(c)?Fl:Xv)(i(l),c,u,h,d)},keys:Yv,values:P0}})()}function I0(r,t,e,n,a,i,o){try{var s=r[i](o),l=s.value}catch(c){return void e(c)}s.done?t(l):Promise.resolve(l).then(n,a)}function Gr(r){return function(){var t=this,e=arguments;return new Promise(function(n,a){var i=r.apply(t,e);function o(l){I0(i,n,a,o,s,"next",l)}function s(l){I0(i,n,a,o,s,"throw",l)}o(void 0)})}}var Gn=Y({},bf),Qv=Gn.version,Vi=Gn.render,Zv=Gn.unmountComponentAtNode,Ci;try{var Jv=Number((Qv||"").split(".")[0]);Jv>=18&&(Ci=Gn.createRoot)}catch{}function T0(r){var t=Gn.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&ge(t)==="object"&&(t.usingClientEntryPoint=r)}var li="__rc_react_root__";function ex(r,t){T0(!0);var e=t[li]||Ci(t);T0(!1),e.render(r),t[li]=e}function tx(r,t){Vi==null||Vi(r,t)}function rx(r,t){if(Ci){ex(r,t);return}tx(r,t)}function nx(r){return $o.apply(this,arguments)}function $o(){return $o=Gr(_t().mark(function r(t){return _t().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",Promise.resolve().then(function(){var a;(a=t[li])===null||a===void 0||a.unmount(),delete t[li]}));case 1:case"end":return n.stop()}},r)})),$o.apply(this,arguments)}function ax(r){Zv(r)}function ix(r){return zo.apply(this,arguments)}function zo(){return zo=Gr(_t().mark(function r(t){return _t().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(Ci===void 0){n.next=2;break}return n.abrupt("return",nx(t));case 2:ax(t);case 3:case"end":return n.stop()}},r)})),zo.apply(this,arguments)}const ox=(r,t)=>(rx(r,t),()=>ix(t));let sx=ox;function cx(r){return sx}var ux={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"};function El(r){var t;return r==null||(t=r.getRootNode)===null||t===void 0?void 0:t.call(r)}function lx(r){return El(r)instanceof ShadowRoot}function fx(r){return lx(r)?El(r):null}function dx(r){return r.replace(/-(.)/g,function(t,e){return e.toUpperCase()})}function px(r,t){Wt(r,"[@ant-design/icons] ".concat(t))}function R0(r){return ge(r)==="object"&&typeof r.name=="string"&&typeof r.theme=="string"&&(ge(r.icon)==="object"||typeof r.icon=="function")}function O0(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(r).reduce(function(t,e){var n=r[e];switch(e){case"class":t.className=n,delete t.class;break;default:delete t[e],t[dx(e)]=n}return t},{})}function Ho(r,t,e){return e?ve.createElement(r.tag,Y(Y({key:t},O0(r.attrs)),e),(r.children||[]).map(function(n,a){return Ho(n,"".concat(t,"-").concat(r.tag,"-").concat(a))})):ve.createElement(r.tag,Y({key:t},O0(r.attrs)),(r.children||[]).map(function(n,a){return Ho(n,"".concat(t,"-").concat(r.tag,"-").concat(a))}))}function Al(r){return zn(r)[0]}function wl(r){return r?Array.isArray(r)?r:[r]:[]}var hx=`
108
+ .anticon {
109
+ display: inline-flex;
110
+ align-items: center;
111
+ color: inherit;
112
+ font-style: normal;
113
+ line-height: 0;
114
+ text-align: center;
115
+ text-transform: none;
116
+ vertical-align: -0.125em;
117
+ text-rendering: optimizeLegibility;
118
+ -webkit-font-smoothing: antialiased;
119
+ -moz-osx-font-smoothing: grayscale;
120
+ }
121
+
122
+ .anticon > * {
123
+ line-height: 1;
124
+ }
125
+
126
+ .anticon svg {
127
+ display: inline-block;
128
+ }
129
+
130
+ .anticon::before {
131
+ display: none;
132
+ }
133
+
134
+ .anticon .anticon-icon {
135
+ display: block;
136
+ }
137
+
138
+ .anticon[tabindex] {
139
+ cursor: pointer;
140
+ }
141
+
142
+ .anticon-spin::before,
143
+ .anticon-spin {
144
+ display: inline-block;
145
+ -webkit-animation: loadingCircle 1s infinite linear;
146
+ animation: loadingCircle 1s infinite linear;
147
+ }
148
+
149
+ @-webkit-keyframes loadingCircle {
150
+ 100% {
151
+ -webkit-transform: rotate(360deg);
152
+ transform: rotate(360deg);
153
+ }
154
+ }
155
+
156
+ @keyframes loadingCircle {
157
+ 100% {
158
+ -webkit-transform: rotate(360deg);
159
+ transform: rotate(360deg);
160
+ }
161
+ }
162
+ `,vx=function(t){var e=lr(ps),n=e.csp,a=e.prefixCls,i=e.layer,o=hx;a&&(o=o.replace(/anticon/g,a)),i&&(o="@layer ".concat(i,` {
163
+ `).concat(o,`
164
+ }`)),De(function(){var s=t.current,l=fx(s);Ur(o,"@ant-design-icons",{prepend:!i,csp:n,attachTo:l})},[])},xx=["icon","className","onClick","style","primaryColor","secondaryColor"],Tn={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function gx(r){var t=r.primaryColor,e=r.secondaryColor;Tn.primaryColor=t,Tn.secondaryColor=e||Al(t),Tn.calculated=!!e}function mx(){return Y({},Tn)}var Bn=function(t){var e=t.icon,n=t.className,a=t.onClick,i=t.style,o=t.primaryColor,s=t.secondaryColor,l=Cr(t,xx),c=L.useRef(),u=Tn;if(o&&(u={primaryColor:o,secondaryColor:s||Al(o)}),vx(c),px(R0(e),"icon should be icon definiton, but got ".concat(e)),!R0(e))return null;var h=e;return h&&typeof h.icon=="function"&&(h=Y(Y({},h),{},{icon:h.icon(u.primaryColor,u.secondaryColor)})),Ho(h.icon,"svg-".concat(h.name),Y(Y({className:n,onClick:a,style:i,"data-icon":h.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},l),{},{ref:c}))};Bn.displayName="IconReact";Bn.getTwoToneColors=mx;Bn.setTwoToneColors=gx;function Sl(r){var t=wl(r),e=ce(t,2),n=e[0],a=e[1];return Bn.setTwoToneColors({primaryColor:n,secondaryColor:a})}function yx(){var r=Bn.getTwoToneColors();return r.calculated?[r.primaryColor,r.secondaryColor]:r.primaryColor}var Cx=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];Sl(oi.primary);var Sr=L.forwardRef(function(r,t){var e=r.className,n=r.icon,a=r.spin,i=r.rotate,o=r.tabIndex,s=r.onClick,l=r.twoToneColor,c=Cr(r,Cx),u=L.useContext(ps),h=u.prefixCls,d=h===void 0?"anticon":h,g=u.rootClassName,x=ur(g,d,z(z({},"".concat(d,"-").concat(n.name),!!n.name),"".concat(d,"-spin"),!!a||n.name==="loading"),e),p=o;p===void 0&&s&&(p=-1);var f=i?{msTransform:"rotate(".concat(i,"deg)"),transform:"rotate(".concat(i,"deg)")}:void 0,y=wl(l),v=ce(y,2),C=v[0],b=v[1];return L.createElement("span",bt({role:"img","aria-label":n.name},c,{ref:t,tabIndex:p,onClick:s,className:x}),L.createElement(Bn,{icon:n,primaryColor:C,secondaryColor:b,style:f}))});Sr.displayName="AntdIcon";Sr.getTwoToneColor=yx;Sr.setTwoToneColor=Sl;var bx=function(t,e){return L.createElement(Sr,bt({},t,{ref:e,icon:ux}))},Fx=L.forwardRef(bx),Ex={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"}}]},name:"close-circle",theme:"filled"},Ax=function(t,e){return L.createElement(Sr,bt({},t,{ref:e,icon:Ex}))},wx=L.forwardRef(Ax),Sx={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"},Bx=function(t,e){return L.createElement(Sr,bt({},t,{ref:e,icon:Sx}))},_x=L.forwardRef(Bx),Dx={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"},kx=function(t,e){return L.createElement(Sr,bt({},t,{ref:e,icon:Dx}))},Px=L.forwardRef(kx),Ix={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"},Tx=function(t,e){return L.createElement(Sr,bt({},t,{ref:e,icon:Ix}))},Rx=L.forwardRef(Tx),Ox={ENTER:13},Nx=`accept acceptCharset accessKey action allowFullScreen allowTransparency
165
+ alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
166
+ charSet checked classID className colSpan cols content contentEditable contextMenu
167
+ controls coords crossOrigin data dateTime default defer dir disabled download draggable
168
+ encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
169
+ headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
170
+ is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
171
+ mediaGroup method min minLength multiple muted name noValidate nonce open
172
+ optimum pattern placeholder poster preload radioGroup readOnly rel required
173
+ reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
174
+ shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
175
+ summary tabIndex target title type useMap value width wmode wrap`,Mx=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
176
+ onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
177
+ onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
178
+ onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
179
+ onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
180
+ onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
181
+ onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,Lx="".concat(Nx," ").concat(Mx).split(/[\s\n]+/),$x="aria-",zx="data-";function N0(r,t){return r.indexOf(t)===0}function Hx(r){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,e;t===!1?e={aria:!0,data:!0,attr:!0}:t===!0?e={aria:!0}:e=Y({},t);var n={};return Object.keys(r).forEach(function(a){(e.aria&&(a==="role"||N0(a,$x))||e.data&&N0(a,zx)||e.attr&&Lx.includes(a))&&(n[a]=r[a])}),n}var Bl=L.forwardRef(function(r,t){var e=r.prefixCls,n=r.style,a=r.className,i=r.duration,o=i===void 0?4.5:i,s=r.showProgress,l=r.pauseOnHover,c=l===void 0?!0:l,u=r.eventKey,h=r.content,d=r.closable,g=r.closeIcon,x=g===void 0?"x":g,p=r.props,f=r.onClick,y=r.onNoticeClose,v=r.times,C=r.hovering,b=L.useState(!1),F=ce(b,2),E=F[0],w=F[1],A=L.useState(0),S=ce(A,2),m=S[0],B=S[1],_=L.useState(0),P=ce(_,2),T=P[0],$=P[1],H=C||E,j=o>0&&s,q=function(){y(u)},G=function(U){(U.key==="Enter"||U.code==="Enter"||U.keyCode===Ox.ENTER)&&q()};L.useEffect(function(){if(!H&&o>0){var I=Date.now()-T,U=setTimeout(function(){q()},o*1e3-T);return function(){c&&clearTimeout(U),$(Date.now()-I)}}},[o,H,v]),L.useEffect(function(){if(!H&&j&&(c||T===0)){var I=performance.now(),U,K=function Z(){cancelAnimationFrame(U),U=requestAnimationFrame(function(Q){var J=Q+T-I,pe=Math.min(J/(o*1e3),1);B(pe*100),pe<1&&Z()})};return K(),function(){c&&cancelAnimationFrame(U)}}},[o,T,H,j,v]);var X=L.useMemo(function(){return ge(d)==="object"&&d!==null?d:d?{closeIcon:x}:{}},[d,x]),O=Hx(X,!0),M=100-(!m||m<0?0:m>100?100:m),R="".concat(e,"-notice");return L.createElement("div",bt({},p,{ref:t,className:ur(R,a,z({},"".concat(R,"-closable"),d)),style:n,onMouseEnter:function(U){var K;w(!0),p==null||(K=p.onMouseEnter)===null||K===void 0||K.call(p,U)},onMouseLeave:function(U){var K;w(!1),p==null||(K=p.onMouseLeave)===null||K===void 0||K.call(p,U)},onClick:f}),L.createElement("div",{className:"".concat(R,"-content")},h),d&&L.createElement("a",bt({tabIndex:0,className:"".concat(R,"-close"),onKeyDown:G,"aria-label":"Close"},O,{onClick:function(U){U.preventDefault(),U.stopPropagation(),q()}}),X.closeIcon),j&&L.createElement("progress",{className:"".concat(R,"-progress"),max:"100",value:M},M+"%"))}),_l=ve.createContext({}),qx=function(t){var e=t.children,n=t.classNames;return ve.createElement(_l.Provider,{value:{classNames:n}},e)},M0=8,L0=3,$0=16,jx=function(t){var e={offset:M0,threshold:L0,gap:$0};if(t&&ge(t)==="object"){var n,a,i;e.offset=(n=t.offset)!==null&&n!==void 0?n:M0,e.threshold=(a=t.threshold)!==null&&a!==void 0?a:L0,e.gap=(i=t.gap)!==null&&i!==void 0?i:$0}return[!!t,e]},Vx=["className","style","classNames","styles"],Ux=function(t){var e=t.configList,n=t.placement,a=t.prefixCls,i=t.className,o=t.style,s=t.motion,l=t.onAllNoticeRemoved,c=t.onNoticeClose,u=t.stack,h=lr(_l),d=h.classNames,g=Ve({}),x=le(null),p=ce(x,2),f=p[0],y=p[1],v=le([]),C=ce(v,2),b=C[0],F=C[1],E=e.map(function(H){return{config:H,key:String(H.key)}}),w=jx(u),A=ce(w,2),S=A[0],m=A[1],B=m.offset,_=m.threshold,P=m.gap,T=S&&(b.length>0||E.length<=_),$=typeof s=="function"?s(n):s;return De(function(){S&&b.length>1&&F(function(H){return H.filter(function(j){return E.some(function(q){var G=q.key;return j===G})})})},[b,E,S]),De(function(){var H;if(S&&g.current[(H=E[E.length-1])===null||H===void 0?void 0:H.key]){var j;y(g.current[(j=E[E.length-1])===null||j===void 0?void 0:j.key])}},[E,S]),ve.createElement($v,bt({key:n,className:ur(a,"".concat(a,"-").concat(n),d==null?void 0:d.list,i,z(z({},"".concat(a,"-stack"),!!S),"".concat(a,"-stack-expanded"),T)),style:o,keys:E,motionAppear:!0},$,{onAllRemoved:function(){l(n)}}),function(H,j){var q=H.config,G=H.className,X=H.style,O=H.index,M=q,R=M.key,I=M.times,U=String(R),K=q,Z=K.className,Q=K.style,J=K.classNames,pe=K.styles,Ie=Cr(K,Vx),Se=E.findIndex(function(Me){return Me.key===U}),ie={};if(S){var Ae=E.length-1-(Se>-1?Se:O-1),Ne=n==="top"||n==="bottom"?"-50%":"0";if(Ae>0){var he,it,et;ie.height=T?(he=g.current[U])===null||he===void 0?void 0:he.offsetHeight:f==null?void 0:f.offsetHeight;for(var tt=0,st=0;st<Ae;st++){var Fe;tt+=((Fe=g.current[E[E.length-1-st].key])===null||Fe===void 0?void 0:Fe.offsetHeight)+P}var ye=(T?tt:Ae*B)*(n.startsWith("top")?1:-1),ke=!T&&f!==null&&f!==void 0&&f.offsetWidth&&(it=g.current[U])!==null&&it!==void 0&&it.offsetWidth?((f==null?void 0:f.offsetWidth)-B*2*(Ae<3?Ae:3))/((et=g.current[U])===null||et===void 0?void 0:et.offsetWidth):1;ie.transform="translate3d(".concat(Ne,", ").concat(ye,"px, 0) scaleX(").concat(ke,")")}else ie.transform="translate3d(".concat(Ne,", 0, 0)")}return ve.createElement("div",{ref:j,className:ur("".concat(a,"-notice-wrapper"),G,J==null?void 0:J.wrapper),style:Y(Y(Y({},X),ie),pe==null?void 0:pe.wrapper),onMouseEnter:function(){return F(function(ze){return ze.includes(U)?ze:[].concat(fe(ze),[U])})},onMouseLeave:function(){return F(function(ze){return ze.filter(function(ee){return ee!==U})})}},ve.createElement(Bl,bt({},Ie,{ref:function(ze){Se>-1?g.current[U]=ze:delete g.current[U]},prefixCls:a,classNames:J,styles:pe,className:ur(Z,d==null?void 0:d.notice),style:Q,times:I,key:R,eventKey:R,onNoticeClose:c,hovering:S&&b.length>0})))})},Wx=L.forwardRef(function(r,t){var e=r.prefixCls,n=e===void 0?"rc-notification":e,a=r.container,i=r.motion,o=r.maxCount,s=r.className,l=r.style,c=r.onAllRemoved,u=r.stack,h=r.renderNotifications,d=L.useState([]),g=ce(d,2),x=g[0],p=g[1],f=function(S){var m,B=x.find(function(_){return _.key===S});B==null||(m=B.onClose)===null||m===void 0||m.call(B),p(function(_){return _.filter(function(P){return P.key!==S})})};L.useImperativeHandle(t,function(){return{open:function(S){p(function(m){var B=fe(m),_=B.findIndex(function($){return $.key===S.key}),P=Y({},S);if(_>=0){var T;P.times=(((T=m[_])===null||T===void 0?void 0:T.times)||0)+1,B[_]=P}else P.times=0,B.push(P);return o>0&&B.length>o&&(B=B.slice(-o)),B})},close:function(S){f(S)},destroy:function(){p([])}}});var y=L.useState({}),v=ce(y,2),C=v[0],b=v[1];L.useEffect(function(){var A={};x.forEach(function(S){var m=S.placement,B=m===void 0?"topRight":m;B&&(A[B]=A[B]||[],A[B].push(S))}),Object.keys(C).forEach(function(S){A[S]=A[S]||[]}),b(A)},[x]);var F=function(S){b(function(m){var B=Y({},m),_=B[S]||[];return _.length||delete B[S],B})},E=L.useRef(!1);if(L.useEffect(function(){Object.keys(C).length>0?E.current=!0:E.current&&(c==null||c(),E.current=!1)},[C]),!a)return null;var w=Object.keys(C);return Ff(L.createElement(L.Fragment,null,w.map(function(A){var S=C[A],m=L.createElement(Ux,{key:A,configList:S,placement:A,prefixCls:n,className:s==null?void 0:s(A),style:l==null?void 0:l(A),motion:i,onNoticeClose:f,onAllNoticeRemoved:F,stack:u});return h?h(m,{prefixCls:n,key:A}):m})),a)}),Gx=["getContainer","motion","prefixCls","maxCount","className","style","onAllRemoved","stack","renderNotifications"],Kx=function(){return document.body},z0=0;function Xx(){for(var r={},t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return e.forEach(function(a){a&&Object.keys(a).forEach(function(i){var o=a[i];o!==void 0&&(r[i]=o)})}),r}function Yx(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=r.getContainer,e=t===void 0?Kx:t,n=r.motion,a=r.prefixCls,i=r.maxCount,o=r.className,s=r.style,l=r.onAllRemoved,c=r.stack,u=r.renderNotifications,h=Cr(r,Gx),d=L.useState(),g=ce(d,2),x=g[0],p=g[1],f=L.useRef(),y=L.createElement(Wx,{container:x,ref:f,prefixCls:a,motion:n,maxCount:i,className:o,style:s,onAllRemoved:l,stack:c,renderNotifications:u}),v=L.useState([]),C=ce(v,2),b=C[0],F=C[1],E=si(function(A){var S=Xx(h,A);(S.key===null||S.key===void 0)&&(S.key="rc-notification-".concat(z0),z0+=1),F(function(m){return[].concat(fe(m),[{type:"open",config:S}])})}),w=L.useMemo(function(){return{open:E,close:function(S){F(function(m){return[].concat(fe(m),[{type:"close",key:S}])})},destroy:function(){F(function(S){return[].concat(fe(S),[{type:"destroy"}])})}}},[]);return L.useEffect(function(){p(e())}),L.useEffect(function(){if(f.current&&b.length){b.forEach(function(m){switch(m.type){case"open":f.current.open(m.config);break;case"close":f.current.close(m.key);break;case"destroy":f.current.destroy();break}});var A,S;F(function(m){return(A!==m||!S)&&(A=m,S=m.filter(function(B){return!b.includes(B)})),S})}},[b]),[w,y]}const Dl=r=>{const[,,,,t]=yi();return t?`${r}-css-var`:""};var Qx={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"},Zx=function(t,e){return L.createElement(Sr,bt({},t,{ref:e,icon:Qx}))},Jx=L.forwardRef(Zx);const e1=100,t1=10,r1=e1*t1,n1=r=>{const{componentCls:t,iconCls:e,boxShadow:n,colorText:a,colorSuccess:i,colorError:o,colorWarning:s,colorInfo:l,fontSizeLG:c,motionEaseInOutCirc:u,motionDurationSlow:h,marginXS:d,paddingXS:g,borderRadiusLG:x,zIndexPopup:p,contentPadding:f,contentBg:y}=r,v=`${t}-notice`,C=new i0("MessageMoveIn",{"0%":{padding:0,transform:"translateY(-100%)",opacity:0},"100%":{padding:g,transform:"translateY(0)",opacity:1}}),b=new i0("MessageMoveOut",{"0%":{maxHeight:r.height,padding:g,opacity:1},"100%":{maxHeight:0,padding:0,opacity:0}}),F={padding:g,textAlign:"center",[`${t}-custom-content`]:{display:"flex",alignItems:"center"},[`${t}-custom-content > ${e}`]:{marginInlineEnd:d,fontSize:c},[`${v}-content`]:{display:"inline-block",padding:f,background:y,borderRadius:x,boxShadow:n,pointerEvents:"all"},[`${t}-success > ${e}`]:{color:i},[`${t}-error > ${e}`]:{color:o},[`${t}-warning > ${e}`]:{color:s},[`${t}-info > ${e},
182
+ ${t}-loading > ${e}`]:{color:l}};return[{[t]:Object.assign(Object.assign({},av(r)),{color:a,position:"fixed",top:d,width:"100%",pointerEvents:"none",zIndex:p,[`${t}-move-up`]:{animationFillMode:"forwards"},[`
183
+ ${t}-move-up-appear,
184
+ ${t}-move-up-enter
185
+ `]:{animationName:C,animationDuration:h,animationPlayState:"paused",animationTimingFunction:u},[`
186
+ ${t}-move-up-appear${t}-move-up-appear-active,
187
+ ${t}-move-up-enter${t}-move-up-enter-active
188
+ `]:{animationPlayState:"running"},[`${t}-move-up-leave`]:{animationName:b,animationDuration:h,animationPlayState:"paused",animationTimingFunction:u},[`${t}-move-up-leave${t}-move-up-leave-active`]:{animationPlayState:"running"},"&-rtl":{direction:"rtl",span:{direction:"rtl"}}})},{[t]:{[`${v}-wrapper`]:Object.assign({},F)}},{[`${t}-notice-pure-panel`]:Object.assign(Object.assign({},F),{padding:0,textAlign:"start"})}]},a1=r=>({zIndexPopup:r.zIndexPopupBase+r1+10,contentBg:r.colorBgElevated,contentPadding:`${(r.controlHeightLG-r.fontSize*r.lineHeight)/2}px ${r.paddingSM}px`}),kl=cv("Message",r=>{const t=hs(r,{height:150});return n1(t)},a1);var i1=function(r,t){var e={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.indexOf(n)<0&&(e[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(e[n[a]]=r[n[a]]);return e};const o1={info:L.createElement(Px,null),success:L.createElement(Fx,null),error:L.createElement(wx,null),warning:L.createElement(_x,null),loading:L.createElement(Rx,null)},Pl=({prefixCls:r,type:t,icon:e,children:n})=>L.createElement("div",{className:ur(`${r}-custom-content`,`${r}-${t}`)},e||o1[t],L.createElement("span",null,n)),s1=r=>{const{prefixCls:t,className:e,type:n,icon:a,content:i}=r,o=i1(r,["prefixCls","className","type","icon","content"]),{getPrefixCls:s}=L.useContext(Ar),l=t||s("message"),c=Dl(l),[u,h,d]=kl(l,c);return u(L.createElement(Bl,Object.assign({},o,{prefixCls:l,className:ur(e,h,`${l}-notice-pure-panel`,d,c),eventKey:"pure",duration:null,content:L.createElement(Pl,{prefixCls:l,type:n,icon:a},i)})))};function c1(r,t){return{motionName:t??`${r}-move-up`}}function ms(r){let t;const e=new Promise(a=>{t=r(()=>{a(!0)})}),n=()=>{t==null||t()};return n.then=(a,i)=>e.then(a,i),n.promise=e,n}var u1=function(r,t){var e={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.indexOf(n)<0&&(e[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(e[n[a]]=r[n[a]]);return e};const l1=8,f1=3,d1=({children:r,prefixCls:t})=>{const e=Dl(t),[n,a,i]=kl(t,e);return n(L.createElement(qx,{classNames:{list:ur(a,i,e)}},r))},p1=(r,{prefixCls:t,key:e})=>L.createElement(d1,{prefixCls:t,key:e},r),h1=L.forwardRef((r,t)=>{const{top:e,prefixCls:n,getContainer:a,maxCount:i,duration:o=f1,rtl:s,transitionName:l,onAllRemoved:c}=r,{getPrefixCls:u,getPopupContainer:h,message:d,direction:g}=L.useContext(Ar),x=n||u("message"),p=()=>({left:"50%",transform:"translateX(-50%)",top:e??l1}),f=()=>ur({[`${x}-rtl`]:s??g==="rtl"}),y=()=>c1(x,l),v=L.createElement("span",{className:`${x}-close-x`},L.createElement(Jx,{className:`${x}-close-icon`})),[C,b]=Yx({prefixCls:x,style:p,className:f,motion:y,closable:!1,closeIcon:v,duration:o,getContainer:()=>(a==null?void 0:a())||(h==null?void 0:h())||document.body,maxCount:i,onAllRemoved:c,renderNotifications:p1});return L.useImperativeHandle(t,()=>Object.assign(Object.assign({},C),{prefixCls:x,message:d})),b});let H0=0;function Il(r){const t=L.useRef(null);return[L.useMemo(()=>{const n=l=>{var c;(c=t.current)===null||c===void 0||c.close(l)},a=l=>{if(!t.current){const E=()=>{};return E.then=()=>{},E}const{open:c,prefixCls:u,message:h}=t.current,d=`${u}-notice`,{content:g,icon:x,type:p,key:f,className:y,style:v,onClose:C}=l,b=u1(l,["content","icon","type","key","className","style","onClose"]);let F=f;return F==null&&(H0+=1,F=`antd-message-${H0}`),ms(E=>(c(Object.assign(Object.assign({},b),{key:F,content:L.createElement(Pl,{prefixCls:u,type:p,icon:x},g),placement:"top",className:ur(p&&`${d}-${p}`,y,h==null?void 0:h.className),style:Object.assign(Object.assign({},h==null?void 0:h.style),v),onClose:()=>{C==null||C(),E()}})),()=>{n(F)}))},o={open:a,destroy:l=>{var c;l!==void 0?n(l):(c=t.current)===null||c===void 0||c.destroy()}};return["info","success","warning","error","loading"].forEach(l=>{const c=(u,h,d)=>{let g;u&&typeof u=="object"&&"content"in u?g=u:g={content:u};let x,p;typeof h=="function"?p=h:(x=h,p=d);const f=Object.assign(Object.assign({onClose:p,duration:x},g),{type:l});return a(f)};o[l]=c}),o},[]),L.createElement(h1,Object.assign({key:"message-holder"},r,{ref:t}))]}function v1(r){return Il(r)}let Zt=null,jr=r=>r(),qn=[],jn={};function q0(){const{getContainer:r,duration:t,rtl:e,maxCount:n,top:a}=jn,i=(r==null?void 0:r())||document.body;return{getContainer:()=>i,duration:t,rtl:e,maxCount:n,top:a}}const x1=ve.forwardRef((r,t)=>{const{messageConfig:e,sync:n}=r,{getPrefixCls:a}=lr(Ar),i=jn.prefixCls||a("message"),o=lr(Ud),[s,l]=Il(Object.assign(Object.assign(Object.assign({},e),{prefixCls:i}),o.message));return ve.useImperativeHandle(t,()=>{const c=Object.assign({},s);return Object.keys(c).forEach(u=>{c[u]=(...h)=>(n(),s[u].apply(s,h))}),{instance:c,sync:n}}),l}),g1=ve.forwardRef((r,t)=>{const[e,n]=ve.useState(q0),a=()=>{n(q0)};ve.useEffect(a,[]);const i=Gv(),o=i.getRootPrefixCls(),s=i.getIconPrefixCls(),l=i.getTheme(),c=ve.createElement(x1,{ref:t,sync:a,messageConfig:e});return ve.createElement(Sn,{prefixCls:o,iconPrefixCls:s,theme:l},i.holderRender?i.holderRender(c):c)}),bi=()=>{if(!Zt){const r=document.createDocumentFragment(),t={fragment:r};Zt=t,jr(()=>{cx()(ve.createElement(g1,{ref:n=>{const{instance:a,sync:i}=n||{};Promise.resolve().then(()=>{!t.instance&&a&&(t.instance=a,t.sync=i,bi())})}}),r)});return}Zt.instance&&(qn.forEach(r=>{const{type:t,skipped:e}=r;if(!e)switch(t){case"open":{jr(()=>{const n=Zt.instance.open(Object.assign(Object.assign({},jn),r.config));n==null||n.then(r.resolve),r.setCloseFn(n)});break}case"destroy":jr(()=>{Zt==null||Zt.instance.destroy(r.key)});break;default:jr(()=>{var n;const a=(n=Zt.instance)[t].apply(n,fe(r.args));a==null||a.then(r.resolve),r.setCloseFn(a)})}}),qn=[])};function m1(r){jn=Object.assign(Object.assign({},jn),r),jr(()=>{var t;(t=Zt==null?void 0:Zt.sync)===null||t===void 0||t.call(Zt)})}function y1(r){const t=ms(e=>{let n;const a={type:"open",config:r,resolve:e,setCloseFn:i=>{n=i}};return qn.push(a),()=>{n?jr(()=>{n()}):a.skipped=!0}});return bi(),t}function C1(r,t){const e=ms(n=>{let a;const i={type:r,args:t,resolve:n,setCloseFn:o=>{a=o}};return qn.push(i),()=>{a?jr(()=>{a()}):i.skipped=!0}});return bi(),e}const b1=r=>{qn.push({type:"destroy",key:r}),bi()},F1=["success","info","warning","error","loading"],E1={open:y1,destroy:b1,config:m1,useMessage:v1,_InternalPanelDoNotUseOrYouWillBeFired:s1},Ca=E1;F1.forEach(r=>{Ca[r]=(...t)=>C1(r,t)});var ba={exports:{}};/*!
189
+ * clipboard.js v2.0.11
190
+ * https://clipboardjs.com/
191
+ *
192
+ * Licensed MIT © Zeno Rocha
193
+ */var A1=ba.exports,j0;function w1(){return j0||(j0=1,(function(r,t){(function(n,a){r.exports=a()})(A1,function(){return(function(){var e={686:(function(i,o,s){s.d(o,{default:function(){return O}});var l=s(279),c=s.n(l),u=s(370),h=s.n(u),d=s(817),g=s.n(d);function x(M){try{return document.execCommand(M)}catch{return!1}}var p=function(R){var I=g()(R);return x("cut"),I},f=p;function y(M){var R=document.documentElement.getAttribute("dir")==="rtl",I=document.createElement("textarea");I.style.fontSize="12pt",I.style.border="0",I.style.padding="0",I.style.margin="0",I.style.position="absolute",I.style[R?"right":"left"]="-9999px";var U=window.pageYOffset||document.documentElement.scrollTop;return I.style.top="".concat(U,"px"),I.setAttribute("readonly",""),I.value=M,I}var v=function(R,I){var U=y(R);I.container.appendChild(U);var K=g()(U);return x("copy"),U.remove(),K},C=function(R){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body},U="";return typeof R=="string"?U=v(R,I):R instanceof HTMLInputElement&&!["text","search","url","tel","password"].includes(R==null?void 0:R.type)?U=v(R.value,I):(U=g()(R),x("copy")),U},b=C;function F(M){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?F=function(I){return typeof I}:F=function(I){return I&&typeof Symbol=="function"&&I.constructor===Symbol&&I!==Symbol.prototype?"symbol":typeof I},F(M)}var E=function(){var R=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},I=R.action,U=I===void 0?"copy":I,K=R.container,Z=R.target,Q=R.text;if(U!=="copy"&&U!=="cut")throw new Error('Invalid "action" value, use either "copy" or "cut"');if(Z!==void 0)if(Z&&F(Z)==="object"&&Z.nodeType===1){if(U==="copy"&&Z.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if(U==="cut"&&(Z.hasAttribute("readonly")||Z.hasAttribute("disabled")))throw new Error(`Invalid "target" attribute. You can't cut text from elements with "readonly" or "disabled" attributes`)}else throw new Error('Invalid "target" value, use a valid Element');if(Q)return b(Q,{container:K});if(Z)return U==="cut"?f(Z):b(Z,{container:K})},w=E;function A(M){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?A=function(I){return typeof I}:A=function(I){return I&&typeof Symbol=="function"&&I.constructor===Symbol&&I!==Symbol.prototype?"symbol":typeof I},A(M)}function S(M,R){if(!(M instanceof R))throw new TypeError("Cannot call a class as a function")}function m(M,R){for(var I=0;I<R.length;I++){var U=R[I];U.enumerable=U.enumerable||!1,U.configurable=!0,"value"in U&&(U.writable=!0),Object.defineProperty(M,U.key,U)}}function B(M,R,I){return R&&m(M.prototype,R),I&&m(M,I),M}function _(M,R){if(typeof R!="function"&&R!==null)throw new TypeError("Super expression must either be null or a function");M.prototype=Object.create(R&&R.prototype,{constructor:{value:M,writable:!0,configurable:!0}}),R&&P(M,R)}function P(M,R){return P=Object.setPrototypeOf||function(U,K){return U.__proto__=K,U},P(M,R)}function T(M){var R=j();return function(){var U=q(M),K;if(R){var Z=q(this).constructor;K=Reflect.construct(U,arguments,Z)}else K=U.apply(this,arguments);return $(this,K)}}function $(M,R){return R&&(A(R)==="object"||typeof R=="function")?R:H(M)}function H(M){if(M===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return M}function j(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function q(M){return q=Object.setPrototypeOf?Object.getPrototypeOf:function(I){return I.__proto__||Object.getPrototypeOf(I)},q(M)}function G(M,R){var I="data-clipboard-".concat(M);if(R.hasAttribute(I))return R.getAttribute(I)}var X=(function(M){_(I,M);var R=T(I);function I(U,K){var Z;return S(this,I),Z=R.call(this),Z.resolveOptions(K),Z.listenClick(U),Z}return B(I,[{key:"resolveOptions",value:function(){var K=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.action=typeof K.action=="function"?K.action:this.defaultAction,this.target=typeof K.target=="function"?K.target:this.defaultTarget,this.text=typeof K.text=="function"?K.text:this.defaultText,this.container=A(K.container)==="object"?K.container:document.body}},{key:"listenClick",value:function(K){var Z=this;this.listener=h()(K,"click",function(Q){return Z.onClick(Q)})}},{key:"onClick",value:function(K){var Z=K.delegateTarget||K.currentTarget,Q=this.action(Z)||"copy",J=w({action:Q,container:this.container,target:this.target(Z),text:this.text(Z)});this.emit(J?"success":"error",{action:Q,text:J,trigger:Z,clearSelection:function(){Z&&Z.focus(),window.getSelection().removeAllRanges()}})}},{key:"defaultAction",value:function(K){return G("action",K)}},{key:"defaultTarget",value:function(K){var Z=G("target",K);if(Z)return document.querySelector(Z)}},{key:"defaultText",value:function(K){return G("text",K)}},{key:"destroy",value:function(){this.listener.destroy()}}],[{key:"copy",value:function(K){var Z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body};return b(K,Z)}},{key:"cut",value:function(K){return f(K)}},{key:"isSupported",value:function(){var K=arguments.length>0&&arguments[0]!==void 0?arguments[0]:["copy","cut"],Z=typeof K=="string"?[K]:K,Q=!!document.queryCommandSupported;return Z.forEach(function(J){Q=Q&&!!document.queryCommandSupported(J)}),Q}}]),I})(c()),O=X}),828:(function(i){var o=9;if(typeof Element<"u"&&!Element.prototype.matches){var s=Element.prototype;s.matches=s.matchesSelector||s.mozMatchesSelector||s.msMatchesSelector||s.oMatchesSelector||s.webkitMatchesSelector}function l(c,u){for(;c&&c.nodeType!==o;){if(typeof c.matches=="function"&&c.matches(u))return c;c=c.parentNode}}i.exports=l}),438:(function(i,o,s){var l=s(828);function c(d,g,x,p,f){var y=h.apply(this,arguments);return d.addEventListener(x,y,f),{destroy:function(){d.removeEventListener(x,y,f)}}}function u(d,g,x,p,f){return typeof d.addEventListener=="function"?c.apply(null,arguments):typeof x=="function"?c.bind(null,document).apply(null,arguments):(typeof d=="string"&&(d=document.querySelectorAll(d)),Array.prototype.map.call(d,function(y){return c(y,g,x,p,f)}))}function h(d,g,x,p){return function(f){f.delegateTarget=l(f.target,g),f.delegateTarget&&p.call(d,f)}}i.exports=u}),879:(function(i,o){o.node=function(s){return s!==void 0&&s instanceof HTMLElement&&s.nodeType===1},o.nodeList=function(s){var l=Object.prototype.toString.call(s);return s!==void 0&&(l==="[object NodeList]"||l==="[object HTMLCollection]")&&"length"in s&&(s.length===0||o.node(s[0]))},o.string=function(s){return typeof s=="string"||s instanceof String},o.fn=function(s){var l=Object.prototype.toString.call(s);return l==="[object Function]"}}),370:(function(i,o,s){var l=s(879),c=s(438);function u(x,p,f){if(!x&&!p&&!f)throw new Error("Missing required arguments");if(!l.string(p))throw new TypeError("Second argument must be a String");if(!l.fn(f))throw new TypeError("Third argument must be a Function");if(l.node(x))return h(x,p,f);if(l.nodeList(x))return d(x,p,f);if(l.string(x))return g(x,p,f);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function h(x,p,f){return x.addEventListener(p,f),{destroy:function(){x.removeEventListener(p,f)}}}function d(x,p,f){return Array.prototype.forEach.call(x,function(y){y.addEventListener(p,f)}),{destroy:function(){Array.prototype.forEach.call(x,function(y){y.removeEventListener(p,f)})}}}function g(x,p,f){return c(document.body,x,p,f)}i.exports=u}),817:(function(i){function o(s){var l;if(s.nodeName==="SELECT")s.focus(),l=s.value;else if(s.nodeName==="INPUT"||s.nodeName==="TEXTAREA"){var c=s.hasAttribute("readonly");c||s.setAttribute("readonly",""),s.select(),s.setSelectionRange(0,s.value.length),c||s.removeAttribute("readonly"),l=s.value}else{s.hasAttribute("contenteditable")&&s.focus();var u=window.getSelection(),h=document.createRange();h.selectNodeContents(s),u.removeAllRanges(),u.addRange(h),l=u.toString()}return l}i.exports=o}),279:(function(i){function o(){}o.prototype={on:function(s,l,c){var u=this.e||(this.e={});return(u[s]||(u[s]=[])).push({fn:l,ctx:c}),this},once:function(s,l,c){var u=this;function h(){u.off(s,h),l.apply(c,arguments)}return h._=l,this.on(s,h,c)},emit:function(s){var l=[].slice.call(arguments,1),c=((this.e||(this.e={}))[s]||[]).slice(),u=0,h=c.length;for(u;u<h;u++)c[u].fn.apply(c[u].ctx,l);return this},off:function(s,l){var c=this.e||(this.e={}),u=c[s],h=[];if(u&&l)for(var d=0,g=u.length;d<g;d++)u[d].fn!==l&&u[d].fn._!==l&&h.push(u[d]);return h.length?c[s]=h:delete c[s],this}},i.exports=o,i.exports.TinyEmitter=o})},n={};function a(i){if(n[i])return n[i].exports;var o=n[i]={exports:{}};return e[i](o,o.exports,a),o.exports}return(function(){a.n=function(i){var o=i&&i.__esModule?function(){return i.default}:function(){return i};return a.d(o,{a:o}),o}})(),(function(){a.d=function(i,o){for(var s in o)a.o(o,s)&&!a.o(i,s)&&Object.defineProperty(i,s,{enumerable:!0,get:o[s]})}})(),(function(){a.o=function(i,o){return Object.prototype.hasOwnProperty.call(i,o)}})(),a(686)})().default})})(ba)),ba.exports}var S1=w1();const B1=es(S1),_1=(r,t)=>{let e=r&&r.replace(/<think>[\s\S]*?<\/think>/g,"");e=e.replace(/\[retrive-tag[^\]]*\][\s\S]*?\[\/retrive-tag\]/g,""),e=e.replace(/<a\s+[^>]*>(.*?)<\/a>/g,""),console.log("_content",e);const n=new B1(t.currentTarget||t.target,{text:()=>e});try{n.on("success",()=>{Ca.success("\u6587\u672C\u590D\u5236\u6210\u529F",2),n.destroy()}),n.on("error",a=>{Ca.error("\u590D\u5236\u5931\u8D25",2),n.destroy()}),n.onClick(t)}catch(a){n.destroy(),Ca.error("\u590D\u5236\u5931\u8D25: "+a,2)}};function D1(r){const t=[];for(const e of r){if(e.query){const n=e.query.queryId||e.query.id||e.queryId||e.id||yr(32);t.push({istype:"user",content:e.query.content,time:e.query.gmtCreate,queryId:n,clientSideId:n+"-user",...e.query})}if(e.reply){const n=e.reply.queryId||e.reply.id||e.queryId||e.id||yr(32);t.push({istype:"ai",content:e.reply.content,isDefault:e.reply.isDefault,time:e.time||e.gmtCreate||Date.now(),queryId:n,clientSideId:n+"-ai",...e.reply})}}return t}const k1=""+new URL("defaultWeLogo.svg",import.meta.url).href,P1="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAOkSURBVHgBxZRbTBxlFMd/c2EvXBbZLbsCVhcKaAyh2BKTWrX12RhNmxa1IVp98FEJVGNMY2KItSZtqGjaROMlaDSVxiZeqiRa0FBpIlSkhgK15WoLu7AL3V1md25+7CpUojzYB7/km5OZc+Z35pzz/wb+l3X7PotNL9tvd1yIc8OrYp9pWXZ6JXXdfLOtbdNa4fJazoZdu9xVNUE5petIVS9h/npRfkDKefg/A+OaJuUGvIz3DzD14R6uHv/WCmzbcuNlj7S+3z7+5Xepno7TLeJWWiv2n5zyTcEaT/TJlrfwljxCTm42lgHRmIHDqaIqIsTE43NS7FHCBXKkIzw4eGKkYcdnwmGvBspSy+DpxlrffXtqC6WeqM3+CZ3wnAZLOyXAlsXfOjU7D6EYHLw7zVKvgykcG+r98YmKjdG5BK3nw7w7YQuATdAJWR4IJ2UiswKoiC39+S0+4QjNL0NWgDU7y57ZVlLd2n+FO/Kd7BxxcPOpMKGrCSxNTNm2kVUZ2e1g+5YCxh4q4IW+cAactYTZLi6dxgqw4dUjj+UgfXpSJRAaY9Lt4dZAkoW5YWSXyKwo6ZYbhsFCciPe9hgHtDiB+kqe6huF6jknv2As9/Dj3mv2se4Yh5RhEr4SbD2FpMjomkZ0eoaunl5yxXwqKsspKwsiOVzYqST143k8Xe7gvaN17tHOTi0D/D6U3DqhO7oNNxOlU6heD0cOH2frg/dSU1ywMgRhRmMpvvjoG55t3I0RWWDvuST9iy5q64qtr2/LV9Ill/aNOsb9fnC48a+zGYzF6R/opefsGU59sl88d6V5tpagqekNFg2LgeHN3F/pJS9rET2l4v15Ruav1PHLEdsUJYpXcNjXKA54iCd11gf9ONUkLqeVtu4ciQUjwcCF3wjc4sUlJbhouyjOVek6O2kvT3kGV3e9P/uetlmhi4VpCsU0Wz5o5i6/kIehY8UjyHlLpVt8daKZc1d0qt3zaV2ex09LjYvnhsx3rj8pEq90N1QU+Q+9WJVgbzBPpFIzIrZNsYWVlYyVhJXVtFys6UHWf76O36NDu3nt0fbVJ0Wm6Sedomx5hzPCwYpJygvdkOMVQhbKFjrEFG2JRQjPTHH4Uh4HoptFfy2T5+9clt/qo6fS9MMYilqEL1dCyCQtQsnKhC51yUyCkBLz4qeT77Np3KCme/EvwJVndUcfl0qr6uzKwAb8biemqTCjmYS0RUKhM1zuep2TzZfIpFlefwDISXe8s31UTQAAAABJRU5ErkJggg==",I1=(r,t)=>{const e={...Jo.colors,...r};return`
194
+ .g-welcome-${t} .g-welcome-title {
195
+ background-image: linear-gradient(90deg, #3262FA 0%, #6C18FF 100%);
196
+ -webkit-background-clip: text;
197
+ background-clip: text;
198
+ color: transparent;
199
+ -webkit-text-fill-color: transparent;
200
+ }
201
+ .g-welcome-${t} .g-welcome-subtitle {
202
+ color: ${e.disabled};
203
+ }
204
+ .g-welcome-${t} .g-welcome-btn {
205
+ background-color: #ffffff;
206
+ border-color: ${e.border};
207
+ color: ${e.text};
208
+ height: 36px;
209
+ border-width: 1px;
210
+ box-shadow: 0 1px 2px rgba(31,35,41,0.04);
211
+ }
212
+ .g-welcome-${t} .g-welcome-btn:hover {
213
+ border-color: ${e.primary};
214
+ color: ${e.primary};
215
+ background-color: #ffffff;
216
+ box-shadow: 0 2px 6px rgba(31,35,41,0.08);
217
+ }
218
+ .g-welcome-${t} .g-welcome-btn.active {
219
+ background-image: linear-gradient(90deg, #F1F8FF 0%, #F9F4FF 100%);
220
+ border-color: ${e.primary};
221
+ box-shadow: 0 4px 10px rgba(24, 144, 255, 0.25);
222
+ }
223
+ .g-welcome-${t} .g-welcome-btn .icon-badge {
224
+ width: 24px;
225
+ height: 24px;
226
+ border-radius: 9999px;
227
+ display: inline-flex;
228
+ align-items: center;
229
+ justify-content: center;
230
+ background: radial-gradient(100% 100% at 50% 0%, #F2F3F5 0%, #FFFFFF 100%);
231
+ box-shadow: inset 0 0 0 1px ${e.border};
232
+ }
233
+ .g-welcome-${t} .g-welcome-pagination-btn {
234
+ background: transparent;
235
+ border: none;
236
+ color: ${e.disabled};
237
+ padding: 6px 10px;
238
+ border-radius: 9999px;
239
+ transition: all 0.2s;
240
+ font-size: 14px;
241
+ line-height: 1;
242
+ min-width: 32px;
243
+ height: 32px;
244
+ display: inline-flex;
245
+ align-items: center;
246
+ justify-content: center;
247
+ }
248
+ .g-welcome-${t} .g-welcome-pagination-btn:hover:not(:disabled) {
249
+ color: ${e.text};
250
+ background-color: ${e.border}33;
251
+ }
252
+ .g-welcome-${t} .g-welcome-pagination-btn.active {
253
+ color: ${e.primary};
254
+ background: radial-gradient(100% 100% at 50% 50%, ${e.primary}10 0%, ${e.primary}08 100%);
255
+ box-shadow: 0 2px 10px ${e.primary}12, inset 0 0 0 1px ${e.primary}1A;
256
+ }
257
+ .g-welcome-${t} .g-welcome-pagination-btn:disabled {
258
+ color: ${e.disabled};
259
+ cursor: not-allowed;
260
+ background: transparent;
261
+ }
262
+ .g-welcome-${t} .g-welcome-pagination-text {
263
+ color: ${e.disabled};
264
+ font-size: 14px;
265
+ padding: 0 8px;
266
+ }
267
+ .g-welcome-${t} .g-welcome-pagination-dot {
268
+ width: 6px;
269
+ height: 6px;
270
+ border-radius: 50%;
271
+ background-color: ${e.border};
272
+ transition: all 0.2s;
273
+ }
274
+ .g-welcome-${t} .g-welcome-pagination-dot.active {
275
+ background-color: ${e.primary};
276
+ width: 20px;
277
+ border-radius: 3px;
278
+ }
279
+ .g-welcome-${t} .g-welcome-search-btn {
280
+ background-color: #ffffff;
281
+ border: 1px solid ${e.border};
282
+ color: ${e.text};
283
+ padding: 8px 8px;
284
+ border-radius: 100%;
285
+ cursor: pointer;
286
+ transition: all 0.2s;
287
+ display: flex;
288
+ align-items: center;
289
+ gap: 6px;
290
+ font-size: 14px;
291
+ box-shadow: 0 1px 2px rgba(31,35,41,0.04);
292
+ }
293
+ .g-welcome-${t} .g-welcome-search-btn:hover {
294
+ border-color: ${e.primary};
295
+ color: ${e.primary};
296
+ box-shadow: 0 2px 6px rgba(31,35,41,0.08);
297
+ }
298
+ .g-welcome-${t} .g-welcome-search-input {
299
+ border: 1px solid ${e.border};
300
+ border-radius: 9999px;
301
+ transition: all 0.2s;
302
+ height: 40px;
303
+ padding: 0 14px;
304
+ }
305
+ .g-welcome-${t} .g-welcome-search-input:focus,
306
+ .g-welcome-${t} .g-welcome-search-input:hover {
307
+ border-color: ${e.primary};
308
+ box-shadow: 0 0 0 2px ${e.primary}1A;
309
+ }
310
+ `};function T1({config:r,styles:t}){if(!r)return null;const e=JSON.parse(r.configJson),n=Ke(()=>{var a;return{...Jo.colors,...(a=t==null?void 0:t.theme)==null?void 0:a.colors}},[t]);return re("div",{className:"w-[340px] rounded-xl p-4 animate-fade-in bg-white",children:[re("div",{className:"flex items-center mb-2",children:[N("span",{className:"text-md font-bold truncate mr-2",style:{color:n.primary},children:e.config_name||"\u52A9\u624B\u914D\u7F6E"}),N("span",{className:"text-xs truncate rounded px-2 py-0.5",style:{backgroundColor:`${n.primary}1A`,color:n.disabled},children:e.model_name})]}),N("div",{className:"border-b my-2",style:{borderColor:n.border}}),re("div",{className:"flex flex-wrap gap-x-4 gap-y-1 text-xs text-gray-700 mb-2",style:{color:n.text},children:[re("div",{children:["\u4E0A\u4E0B\u6587\u6700\u5927\u8F6E\u6570\uFF1A",N("span",{className:"font-semibold",children:e.max_round})]}),re("div",{children:["\u6700\u5927\u4EE4\u724C\u6570\uFF1A",N("span",{className:"font-semibold",children:e.max_tokens})]}),re("div",{children:["\u6E29\u5EA6\uFF1A",N("span",{className:"font-semibold",children:e.temperature})]}),re("div",{children:["\u53EC\u56DE\u6570\uFF1A",N("span",{className:"font-semibold",children:e.top_k})]}),re("div",{children:["\u591A\u6837\u6027\uFF1A",N("span",{className:"font-semibold",children:e.top_p})]}),re("div",{children:["\u76F8\u4F3C\u5EA6\u9608\u503C\uFF1A",N("span",{className:"font-semibold",children:e.score_threshold})]})]}),re("div",{className:"mb-2",children:[N("div",{className:"text-xs text-gray-400 mb-1",style:{color:n.disabled},children:"\u5173\u8054\u77E5\u8BC6\u5E93\uFF1A"}),N("div",{className:"flex flex-wrap gap-1",children:e.knowledge_base_name?e.knowledge_base_name.split(";").map((a,i)=>N("span",{className:"px-2 py-0.5 rounded-full text-xs",style:{backgroundColor:`${n.primary}1A`,color:n.primary},children:a},i)):N("span",{className:"text-gray-300",style:{color:n.disabled},children:"\u65E0"})})]}),re("div",{className:"mb-2",children:[N("div",{className:"text-xs text-gray-400 mb-1",style:{color:n.disabled},children:"\u5F00\u542F\u529F\u80FD:"}),re("div",{className:"flex flex-wrap gap-2 text-xs mt-2",children:[!!e.enabled_faq&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"FAQ"}),!!e.enabled_graph&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"\u56FE\u8C31"}),!!e.dependOnKb&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"\u5F3A\u77E5\u8BC6\u4F9D\u8D56"}),!!e.enabled_table_select&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"\u8868\u683C\u7B5B\u9009"}),!!e.enabled_rerank&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"\u7CBE\u6392\u6A21\u5F0F"}),!!e.need_trace_source&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"\u6EAF\u6E90"}),!!e.is_download&&N("span",{className:"px-2 py-0.5 rounded",style:{backgroundColor:`${n.success}1A`,color:n.success},children:"\u4E0B\u8F7D\u6EAF\u6E90"})]})]})]})}function R1(r,t=[],e=60){const[n,a]=le("");return De(()=>{if(a(""),!r)return;let i=0;const o=setInterval(()=>{a(s=>i>=r.length?(clearInterval(o),s):(i++,r.slice(0,i)))},e);return()=>clearInterval(o)},[r,...t]),n}function O1(r){const{assistantList:t,eventsEmit:e,styles:n,selectedId:a,onSelectAssistant:i,productLogo:o}=r,{messages:s}=pi(),[l,c]=le(1),[u,h]=le(!1),[d,g]=le(""),x=u||d.trim()?6:12,p=Ve(),f=Ve(!1),y=Ve(null),v=Ve(null),C=Ve("");De(()=>{a&&p.current!==a&&(e==null||e("conversation:new_assistant_change",{assistantId:a}),p.current=a)},[a,e]);const b=Ke(()=>yr(),[]);De(()=>{var _;if((_=n==null?void 0:n.theme)!=null&&_.colors){const P=document.createElement("style");return P.innerHTML=I1(n.theme.colors,b),P.id=`g-welcome-styles-${b}`,document.head.appendChild(P),()=>{const T=document.getElementById(P.id);T&&T.remove()}}},[n,b]);const F=Ke(()=>t.find(_=>_.id===a),[t,a]),E=Ke(()=>JSON.parse((F==null?void 0:F.configJson)||"{}"),[F]),w=Ke(()=>{if(!d.trim())return t||[];const _=d.toLowerCase().trim();return(t||[]).filter(P=>{var $,H;const T=(($=P.name)==null?void 0:$.toLowerCase())||"";try{const q=((H=JSON.parse(P.configJson||"{}").config_name)==null?void 0:H.toLowerCase())||"";return T.includes(_)||q.includes(_)}catch{return T.includes(_)}})},[t,d]),A=Math.ceil(((w==null?void 0:w.length)||0)/x),S=(w==null?void 0:w.slice((l-1)*x,l*x))||[];De(()=>{if(a&&a!==v.current){if(f.current&&y.current!==null){v.current=a;return}const _=d.trim()?w:t;if(_&&_.length>0){const P=_.findIndex(T=>T.id===a);if(P!==-1){const T=Math.floor(P/x)+1;c(T),v.current=a}}}},[a,t,w,x,d]),De(()=>{if(d!==C.current){if(f.current&&y.current!==null){c(y.current),f.current=!1,y.current=null,C.current=d;return}if(v.current===a){C.current=d;return}f.current||(d.trim()&&(v.current=null),c(1)),C.current=d}},[d,a]),De(()=>{A>0&&l>A&&c(A)},[A,l]);const m=E.prologue||s.welcome.defaultPrologue,B=R1(m,[a],30);return re("div",{className:`flex flex-col relative items-center justify-center h-full w-full g-welcome-${b}`,children:[N("img",{src:o||k1,alt:"logo",className:"mb-4",style:{width:68,height:68}}),N("div",{className:"text-3xl font-bold mb-2 g-welcome-title",children:B}),!a&&N("div",{className:"flex mb-2 g-welcome-subtitle",children:s.welcome.selectAssistant}),re("div",{style:{maxWidth:"1200px"},className:`flex mt-8 flex-wrap gap-3\r
311
+ max-w-[1200px] px-8 w-full mx-auto justify-center mb-4`,children:[u?N("div",{className:"flex items-center gap-2 px-5 w-full",style:{flexBasis:"100%"},children:N(jc,{className:"g-welcome-search-input w-full",placeholder:s.welcome.searchAssistant,prefix:N(Qi,{size:16}),suffix:N("button",{type:"button",onClick:()=>{h(!1),g("")},style:{background:"transparent",border:"none",cursor:"pointer"},children:N(Wc,{size:14})}),value:d,onChange:_=>g(_.target.value),autoFocus:!0})}):N("button",{type:"button",className:"g-welcome-search-btn",onClick:()=>h(!0),children:N(Qi,{size:16})}),S&&S.length>0?N(Vn,{children:S.map(_=>{const P=a===_.id;let T=_.icon;try{const $=JSON.parse(_.configJson||"{}");T=T||$.icon||$.avatar||$.logo}catch{}return T=T||P1,N(pf,{content:()=>N(T1,{config:t.find($=>$.id===_.id),styles:n}),trigger:"hover",placement:"bottom",children:re("button",{type:"button",className:`g-welcome-btn px-3 cursor-pointer rounded-full border font-medium min-w-[160px] text-sm transition-all flex items-center gap-2 ${P?"active":""}`,onClick:()=>{i==null||i(_.id);const $=u||d.trim(),j=($?t:d.trim()?w:t).findIndex(q=>q.id===_.id);if(j!==-1){const G=Math.floor(j/($?12:x))+1;c(G),v.current=_.id,$&&(y.current=G,f.current=!0,setTimeout(()=>{g(""),h(!1)},100))}},title:_.name,children:[N("span",{className:"icon-badge",children:N("img",{src:T,alt:"icon",style:{width:16,height:16,borderRadius:4}})}),N("span",{className:"truncate max-w-[180px]",children:_.name})]})},_.id)})}):N("div",{className:"g-welcome-subtitle",children:"\u6682\u65E0\u53EF\u7528\u52A9\u624B"})]}),A>1&&re("div",{className:"flex items-center gap-2",children:[N("button",{type:"button",className:"g-welcome-pagination-btn",onClick:()=>c(_=>Math.max(1,_-1)),disabled:l===1,children:N(Gf,{size:16})}),N("div",{className:"flex items-center gap-1",children:(()=>{const _=[];if(A<=7)for(let T=1;T<=A;T++)_.push(T);else if(_.push(1),l<=4){for(let T=2;T<=5;T++)_.push(T);_.push("..."),_.push(A)}else if(l>=A-3){_.push("...");for(let T=A-4;T<=A;T++)_.push(T)}else{_.push("...");for(let T=l-1;T<=l+1;T++)_.push(T);_.push("..."),_.push(A)}return _.map((T,$)=>{if(T==="...")return N("span",{className:"g-welcome-pagination-text px-1",children:"..."},`ellipsis-${$}`);const H=T;return N("button",{type:"button",className:`g-welcome-pagination-btn ${l===H?"active":""}`,onClick:()=>c(H),children:H},H)})})()}),N("button",{type:"button",className:"g-welcome-pagination-btn",onClick:()=>c(_=>Math.min(A,_+1)),disabled:l===A,children:N(Kf,{size:16})})]})]})}class Ui extends Error{}let xr=null,Er=null,ar=null,qe=[],nn,an,Wi=new Map;const N1=({baseUrl:r,token:t,CSRFToken:e,setChatData:n,activeSessionId:a,setAppStatus:i,setConversationList:o})=>{const s=f=>{if(!f)return!1;if(typeof f=="string"){const y=f.trim();return y!==""&&y!=="[]"&&y!=="null"}return!0},l=({content:f,status:y,respTime:v,filePaths:C,reference:b,webReference:F,knowledgeBases:E,graphReference:w,databaseReference:A,llmType:S,resultType:m,queryId:B,tokens:_,chain:P,thoughtChainNodes:T,enableCot:$,chainRespTime:H})=>{n(j=>{var J;if(!j[0])return j;const q=j[0],G=q.messages||[],X=G.length-1;if(X<0)return j;const O=G[X];if(O.istype!=="ai")return j;let M=G.slice();if(C!=null&&C.length){const pe=G.length-2;if(pe>=0&&((J=G[pe])==null?void 0:J.istype)==="user"){const Ie={...G[pe],filePaths:C};M[pe]=Ie}}const R=B&&B!==O.queryId,I=y===1&&O.status===2,U=R||I?s(w)?w:null:w!==void 0&&s(w)?w:O.graphReference;y===2&&w!==void 0&&console.log("[AichatUseController] reset_chat status=2 \u65F6\u7684 graphReference:",{graphReference:w,isValid:s(w),lastMessageGraphReference:O.graphReference,finalGraphReference:U,isNewQuery:R,isRestart:I});let K;R?K=f:I?K="":y===4||y===2&&!f?K=O.content||"":K=(O.content||"")+f;const Z={...O,content:K,status:y,respTime:v,filePaths:C,reference:R||I?b||"[]":b,webReference:R||I?F||"[]":F,knowledgeBases:R||I?E||"[]":E,graphReference:U,databaseReference:R||I?A!==void 0?A:null:A!==void 0?A:O.databaseReference,resultType:m,llmType:S,tokens:_,queryId:B||O.queryId||yr(32),chain:R||I?P!==void 0?P:void 0:P!==void 0?P:O.chain,thoughtChainNodes:R||I?T!==void 0?T:void 0:T!==void 0?T:O.thoughtChainNodes,enableCot:$!==void 0?$:O.enableCot,chainRespTime:H!==void 0?H:O.chainRespTime};return Z.clientSideId=Z.clientSideId||Z.queryId+"-ai",M[X]=Z,[{...q,isNew:!1,messages:M},...j.slice(1)]})},c=f=>{if(f instanceof Ui)throw i(y=>({...y,display:"error",sender:"ready"})),xr&&(xr.abort(),xr=null),Er=null,ar=null,f};return{updateUserFilesMessage:({currentFiles:f})=>{n(y=>{if(!y[0])return y;const v=y[0],C=v.messages||[];if(!C.length)return y;const b=C.length-2;if(b<0||C[b].istype!=="user")return y;const E=C.slice();return E[b]={...C[b],currentFiles:f},[{...v,messages:E},...y.slice(1)]})},api_startChat_re:(f,y)=>{xr&&xr.abort(),xr=new AbortController,Er=f.sessionId,ar=f.queryId,qe=[],nn=void 0,an=void 0,Wi=new Map;const v=`${r}/qa/ai/question_re`;console.log("data",f);const C={...f};Ef(v,{method:"post",signal:xr.signal,headers:{"Content-Type":"application/json",Accept:"text/event-stream",Authorization:t||"","X-CSRF-TOKEN-IN":e||""},openWhenHidden:!0,body:JSON.stringify(C),onopen:async b=>{if(b.status===500)throw new Ui("Internal Server Error");if(!b.ok)throw new Ui(`HTTP error: ${b.status}`)},onmessage:b=>{var I,U,K,Z;const F=JSON.parse(b.data);if(Er!==F.sessionId){console.log("[AichatUseController] \u6D41\u5F0F\u8BF7\u6C42\u7684 sessionId \u5DF2\u4E0D\u5339\u914D\uFF0C\u5FFD\u7565\u6570\u636E",{currentStreamSessionId:Er,receivedSessionId:F.sessionId,activeSessionId:a});return}if(a!==F.sessionId)return;const{reply:E,resultType:w,respTime:A,reference:S,webReference:m,graphReference:B,knowledgeBases:_,filePaths:P,status:T,docs:$,llmType:H,databaseReference:j,businessType:q,nodeStatus:G,enableCot:X,chainRespTime:O}=F;if(T===4&&q){G===2&&typeof O=="number"&&O>0&&Wi.set(q,O);const Q=G===2&&typeof O=="number"&&O>0?O:void 0;qe=ff(qe,{businessType:q,nodeStatus:G,reply:E,respTime:Q,chainRespTime:Q}),console.log("[AichatUseController] status=4 \u805A\u5408\u601D\u7EF4\u94FE\u6570\u636E:",{businessType:q,nodeStatus:G,content:(I=E==null?void 0:E.content)==null?void 0:I.substring(0,50),currentThoughtNodesCount:qe.length,chainRespTime:G===2?O:void 0})}else T===1&&q&&console.log("[AichatUseController] status=1 \u8DF3\u8FC7\u601D\u7EF4\u94FE\u805A\u5408:",{businessType:q,content:(U=E==null?void 0:E.content)==null?void 0:U.substring(0,50),note:"status=1 \u7684\u5185\u5BB9\u5E94\u8BE5\u53BB\u6B63\u6587\uFF0C\u4E0D\u662F\u601D\u7EF4\u94FE"});if(typeof X=="number"&&(nn=X),T===1||T===2){const Q=Array.from(Wi.values()).reduce((J,pe)=>J+pe,0);Q>0&&(an=Q)}const M=P?JSON.parse(P):[];T===2&&E&&E.content&&(E.content.includes("\u6A21\u578B\u6682\u65E0\u6CD5\u8FD4\u56DE")||E.content.includes("\u5931\u8D25")||E.content.includes("\u9519\u8BEF")||E.content.includes("\u8BF7\u7A0D\u540E\u518D\u8BD5"))&&i(Q=>({...Q,display:"ready",sender:"ready"}));const R=s(B)?B:void 0;if(T===2&&console.log("[AichatUseController] status=2 \u65F6\u7684 graphReference:",{graphReference:B,type:typeof B,isValid:s(B),finalGraphReference:R}),T===4){const Q=qe.length>0?qe.map(J=>({businessType:J.businessType,nodeStatus:J.nodeStatus,content:J.content})):void 0;console.log("[AichatUseController] status=4 \u66F4\u65B0\u601D\u7EF4\u94FE:",{businessType:q,chainLength:(Q==null?void 0:Q.length)||0,replyContentLength:((K=E==null?void 0:E.content)==null?void 0:K.length)||0,note:"status=4 \u65F6\uFF0Creply.content \u5E94\u8BE5\u805A\u5408\u5230\u601D\u7EF4\u94FE\uFF0C\u4E0D\u66F4\u65B0\u6B63\u6587"}),l({content:"",status:T,respTime:A,filePaths:M,reference:S||$||"",webReference:m||"",knowledgeBases:_||"",graphReference:R,databaseReference:j,llmType:H,resultType:w,queryId:F.queryId,tokens:F.tokens,chain:Q,thoughtChainNodes:qe.length>0?[...qe]:void 0,enableCot:nn,chainRespTime:an})}else if(T===1){qe.length>0&&(qe=qe.map(J=>({...J,nodeStatus:2}))),console.log("[AichatUseController] status=1 \u66F4\u65B0\u6B63\u6587:",{businessType:q,content:(Z=E==null?void 0:E.content)==null?void 0:Z.substring(0,50),thoughtNodesCount:qe.length,note:"status=1 \u65F6\uFF0Creply.content \u5E94\u8BE5\u53BB\u6B63\u6587\uFF0C\u601D\u7EF4\u94FE\u8282\u70B9\u72B6\u6001\u66F4\u65B0\u4E3A\u5B8C\u6210"});const Q=qe.length>0?qe.map(J=>({businessType:J.businessType,nodeStatus:J.nodeStatus,content:J.content})):void 0;l({content:E.content||"",status:T,respTime:A,filePaths:M,reference:S||$||"",webReference:m||"",graphReference:R,knowledgeBases:_||"",databaseReference:j??null,llmType:H,resultType:w,queryId:F.queryId,tokens:F.tokens,chain:Q??void 0,thoughtChainNodes:qe.length>0?[...qe]:void 0,enableCot:nn,chainRespTime:an})}else if(T===2){qe.length>0&&(qe=qe.map(J=>({...J,nodeStatus:2})));const Q=qe.length>0?qe.map(J=>({businessType:J.businessType,nodeStatus:J.nodeStatus,content:J.content})):void 0;if(l({content:E.content||"",status:2,respTime:A,filePaths:M,reference:S||$||"",webReference:m||"",knowledgeBases:_||"",graphReference:R,databaseReference:j,llmType:H,resultType:w,queryId:F.queryId,tokens:F.tokens,chain:Q,thoughtChainNodes:qe.length>0?[...qe]:void 0,enableCot:nn,chainRespTime:an}),qe=[],i(J=>({...J,display:"ready",sender:"ready"})),y){const J=A||Date.now();console.log("[AichatUseController] \u6D88\u606F\u53D1\u9001\u6210\u529F\uFF0CgmtModified:",J),y(J)}}else{const Q=qe.length>0?qe.map(J=>({businessType:J.businessType,nodeStatus:J.nodeStatus,content:J.content,respTime:J.respTime,chainRespTime:J.respTime})):void 0;l({content:E.content||"",status:T,respTime:A,filePaths:M,reference:S||$||"",knowledgeBases:_||"",webReference:m||"",graphReference:R,databaseReference:j,llmType:H,resultType:w,queryId:F.queryId,tokens:F.tokens,chain:Q,thoughtChainNodes:qe.length>0?[...qe]:void 0,enableCot:nn,chainRespTime:an})}},onerror:c,onclose:()=>{Er===f.sessionId&&(Er=null,ar=null)}})},addEmptyMessage:({queryId:f,content:y,filePaths:v,currentFiles:C})=>{n(b=>{const F=new Date().toISOString(),E=f||yr(32),w={istype:"user",content:y,time:F,queryId:E,clientSideId:E+"-user",filePaths:v||"",currentFiles:C||[]},A={istype:"ai",content:"",time:new Date(Date.now()+1).toISOString(),streaming:!0,status:0,queryId:E,clientSideId:E+"-ai"},S=b.find(m=>m.id===a);return S?S.messages.push(w,A):console.warn("addEmptyMessage called without an active session."),[...b]})},setLastEmptyMessage:({now:f})=>{n(y=>{if(!y[0])return y;const v=y[0],C=v.messages||[];if(!C.length)return y;const b=C.length-1;if(b<0)return y;const F=C[b];if(F.istype!=="ai")return y;const E=C.slice();return E[b]={...F,istype:"ai",content:"",time:f,streaming:!0,status:0},[{...v,messages:E},...y.slice(1)]})},stopStream:async()=>{if(ar)try{await Mt.delete(`${r}/qa/ai/abortStream?queryId=${ar}`,{headers:{Authorization:t||"","X-CSRF-TOKEN-IN":e||""}}),console.log("[AichatUseController] \u5DF2\u8C03\u7528\u540E\u7AEF\u63A5\u53E3\u505C\u6B62\u6D41\u5F0F\u8BF7\u6C42",ar)}catch(f){console.error("[AichatUseController] \u8C03\u7528\u505C\u6B62\u63A5\u53E3\u5931\u8D25",f)}else console.warn("[AichatUseController] \u505C\u6B62\u6D41\u5F0F\u8BF7\u6C42\u65F6\u672A\u627E\u5230 queryId");xr=null,Er=null,ar=null,i(f=>({...f,display:"ready",sender:"ready"}))},cancelStreamBySessionId:async f=>{if(xr&&Er===f){if(console.log("[AichatUseController] \u5207\u6362\u4F1A\u8BDD\uFF0C\u53D6\u6D88\u6B63\u5728\u8FDB\u884C\u7684\u6D41\u5F0F\u8BF7\u6C42",f),ar)try{await Mt.delete(`${r}/qa/ai/abortStream?queryId=${ar}`,{headers:{Authorization:t||"","X-CSRF-TOKEN-IN":e||""}}),console.log("[AichatUseController] \u5207\u6362\u4F1A\u8BDD\u65F6\u5DF2\u8C03\u7528\u540E\u7AEF\u63A5\u53E3\u505C\u6B62\u6D41\u5F0F\u8BF7\u6C42",ar)}catch(y){console.error("[AichatUseController] \u5207\u6362\u4F1A\u8BDD\u65F6\u8C03\u7528\u505C\u6B62\u63A5\u53E3\u5931\u8D25",y)}else console.warn("[AichatUseController] \u5207\u6362\u4F1A\u8BDD\u65F6\u672A\u627E\u5230 queryId");return xr=null,Er=null,ar=null,i(y=>({...y,display:"ready",sender:"ready"})),!0}return!1}}},M1=1e3,L1=3e3;function $1({url:r,token:t,CSRFToken:e,onError:n,activeSessionId:a}){const[i,o]=le([]),[s,l]=le(()=>({uploadedFiles:[]})),c=Ve(!1),u=async p=>{var f,y;if(!p)return null;try{const v=await Mt.get(`${r}/index/knowledgeBase/file/getFilesBysessionId?sessionId=${p}`,{headers:{Authorization:t}});console.log("[DEBUG] \u83B7\u53D6\u4E34\u65F6\u6587\u4EF6\u5217\u8868 res:",(f=v==null?void 0:v.data)==null?void 0:f.data),l({uploadedFiles:((y=v==null?void 0:v.data)==null?void 0:y.data)||[]})}catch(v){throw console.error("\u83B7\u53D6\u4E34\u65F6\u6587\u4EF6\u5217\u8868\u5931\u8D25:",v),v}},h=Jn((p,f)=>{const y=p.join(",");let v=0,C=null;C=()=>{c.current=!0};const b=async()=>{if(!c.current){if(v>=M1){c.current||f.onFail("\u6587\u4EF6\u89E3\u6790\u8D85\u65F6\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5");return}v++;try{const F=await Mt.get(`${r}/index/knowledgeBase/file/getFileStatusByUids?uids=${y}`,{headers:{Authorization:t}});if(c.current)return;if(F.data.success){const E=F.data.data;c.current||f.onStatusUpdate(E),E.every(A=>{const S=A.fileParseStatus??A.status;return S===3||S===4})?c.current||f.onComplete():c.current||setTimeout(b,L1)}else c.current||f.onFail(F.data.errorMsg||"\u67E5\u8BE2\u6587\u4EF6\u72B6\u6001\u5931\u8D25")}catch(F){if(n==null||n(F),c.current)return;f.onFail("\u67E5\u8BE2\u6587\u4EF6\u72B6\u6001\u65F6\u53D1\u751F\u7F51\u7EDC\u9519\u8BEF")}}};return b(),C},[r,t,n]),d=Jn(async(p,f)=>{if(!p){console.warn("[DEBUG] \u7F3A\u5C11uid\uFF0C\u65E0\u6CD5\u5220\u9664\u4E34\u65F6\u6587\u4EF6");return}Af({url:r,token:t,CSRFToken:e},{uid:p,queryId:f},(y,v)=>{y?(St.success("\u6587\u4EF6\u5DF2\u4ECE\u4E34\u65F6\u77E5\u8BC6\u5E93\u79FB\u9664"),u(a)):(console.log("[DEBUG] removeFilefromTempUpload \u56DE\u8C03 false\uFF0Cres:",v),St.error("\u6587\u4EF6\u79FB\u9664\u5931\u8D25"))})},[r,t,e,a]),g=Jn(()=>{c.current=!1},[]),x=Jn(()=>{c.current=!0},[]);return{fileManagerData:s,fileStatuses:i,setFileManagerData:l,setFileStatuses:o,pollFileStatus:h,handleRemoveFromTemp:d,resetStopFlag:g,setStopFlag:x,stoppedRef:c,getTempFileList:u}}function z1({title:r,subtitle:t}){const[e,n]=le(0);return De(()=>{let a;return e<98?a=setTimeout(()=>{n(i=>i+Math.random()*6+1)},80):e<100&&(a=setTimeout(()=>n(100),400)),()=>clearTimeout(a)},[e]),re("div",{className:"flex flex-col justify-center items-center min-h-screen bg-gradient-to-br from-[#EEF4FF] via-white to-[#F5F8FF]",children:[re("div",{className:"mb-8 flex flex-col items-center",children:[N("div",{className:"mt-6 text-2xl font-semibold text-[#222222] tracking-wide",children:r||"\u5C0F\u9CB8\u667A\u80FD\u4F1A\u8BDD\u52A9\u624B"}),N("div",{className:"mt-2 text-sm text-[#555555]",children:t||"\u8BA9\u667A\u80FD\u5BF9\u8BDD\u66F4\u7B80\u5355"})]}),re("div",{className:"relative w-80 max-w-sm",children:[N("div",{className:"w-full h-2 bg-[#EEF4FF] rounded-full overflow-hidden shadow-inner",children:N("div",{className:"h-full bg-gradient-to-r from-[#2B69FF] to-[#8F91FF] transition-all duration-300 ease-out",style:{width:`${Math.min(e,100)}%`}})}),re("div",{className:"absolute -right-2 top-5 text-sm text-[#555555]",children:[Math.min(Math.round(e),100),"%"]})]}),re("div",{className:"mt-8 flex flex-col items-center gap-2",children:[N("div",{className:"text-sm text-[#555555] animate-pulse",children:"\u6B63\u5728\u521D\u59CB\u5316\u5E94\u7528"}),N("div",{className:"text-xs text-[#888888]",children:"\u9996\u6B21\u52A0\u8F7D\u53EF\u80FD\u9700\u8981\u4E00\u4E9B\u65F6\u95F4\uFF0C\u8BF7\u8010\u5FC3\u7B49\u5F85"})]})]})}const Tl=document.createElement("style");Tl.textContent=`
312
+ .animate-bounce-slow {
313
+ animation: bounce 2.2s cubic-bezier(0.4, 0, 0.2, 1) infinite;
314
+ }
315
+ @keyframes bounce {
316
+ 0%, 100% { transform: translateY(0); }
317
+ 50% { transform: translateY(-12px); }
318
+ }
319
+ `;document.head.appendChild(Tl);function H1(){return re("div",{className:"flex flex-col gap-8 p-4 w-full mx-auto",children:[re("div",{className:"flex items-start gap-4",children:[N("div",{className:"w-10 h-10 rounded-full bg-muted/80 animate-pulse"}),N("div",{className:"flex-1",children:N(ea,{active:!0,paragraph:{rows:1}})})]}),re("div",{className:"flex items-start gap-4",children:[N("div",{className:"w-10 h-10 rounded-full bg-muted/80 animate-pulse"}),N("div",{className:"flex-1",children:N(ea,{active:!0,paragraph:{rows:3}})})]}),re("div",{className:"flex items-start gap-4",children:[N("div",{className:"w-10 h-10 rounded-full bg-muted/80 animate-pulse"}),N("div",{className:"flex-1",children:N(ea,{active:!0,paragraph:{rows:1}})})]}),re("div",{className:"flex items-start gap-4",children:[N("div",{className:"w-10 h-10 rounded-full bg-muted/80 animate-pulse"}),N("div",{className:"flex-1",children:N(ea,{active:!0,paragraph:{rows:2}})})]})]})}function q1({msg:r,subMsg:t}){return re("div",{className:"flex flex-col items-center justify-center h-full p-8 text-center bg-white/80 backdrop-blur-sm",children:[N("div",{className:"mb-6 animate-bounce",children:N(Qf,{size:64,className:"text-[#d70016]"})}),N("h2",{className:"text-[20px] font-medium text-[#222222] mb-3",children:r||"\u5E94\u7528\u521D\u59CB\u5316\u5931\u8D25"}),N("p",{className:"text-[14px] text-[#555555] mb-8 max-w-[400px]",children:t||"\u65E0\u6CD5\u5B8C\u6210\u5E94\u7528\u521D\u59CB\u5316\uFF0C\u8FD9\u53EF\u80FD\u662F\u7531\u4E8E\u7F51\u7EDC\u8FDE\u63A5\u95EE\u9898\u6216\u670D\u52A1\u914D\u7F6E\u9519\u8BEF\u5BFC\u81F4\u7684\u3002\u8BF7\u68C0\u67E5\u60A8\u7684\u7F51\u7EDC\u8FDE\u63A5\u5E76\u91CD\u8BD5\u3002"}),N(vn,{type:"primary",icon:N(Zc,{className:"w-4 h-4"}),onClick:()=>window.location.reload(),className:"flex items-center gap-2 bg-gradient-to-r from-[#2B69FF] to-[#8F91FF] border-none hover:opacity-90",children:"\u91CD\u65B0\u52A0\u8F7D"})]})}function j1(){return re("div",{className:"flex flex-col items-center justify-center h-full p-8 text-center bg-transparent! backdrop-blur-sm",children:[N("div",{className:"mb-6 animate-bounce",children:N(wf,{size:64,className:"text-[#d70016]"})}),N("h2",{className:"text-[20px] font-medium text-[#222222] mb-3",children:"\u62B1\u6B49\uFF0C\u9047\u5230\u4E86\u4E00\u4E9B\u95EE\u9898"}),N("p",{className:"text-[14px] text-[#555555] mb-8 max-w-[400px]",children:"\u8BF7\u6C42\u5931\u8D25\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5"}),N(vn,{type:"primary",icon:N(Zc,{className:"w-4 h-4"}),onClick:()=>window.location.reload(),className:"flex items-center gap-2 bg-gradient-to-r from-[#2B69FF] to-[#8F91FF] border-none hover:opacity-90",children:"\u91CD\u65B0\u52A0\u8F7D"})]})}function qo(r){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=[];return ve.Children.forEach(r,function(n){n==null&&!t.keepEmpty||(Array.isArray(n)?e=e.concat(qo(n)):Qu(n)&&n.props?e=e.concat(qo(n.props.children,t)):e.push(n))}),e}var Vr="RC_FORM_INTERNAL_HOOKS",je=function(){Wt(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},Cn=L.createContext({getFieldValue:je,getFieldsValue:je,getFieldError:je,getFieldWarning:je,getFieldsError:je,isFieldsTouched:je,isFieldTouched:je,isFieldValidating:je,isFieldsValidating:je,resetFields:je,setFields:je,setFieldValue:je,setFieldsValue:je,validateFields:je,submit:je,getInternalHooks:function(){return je(),{dispatch:je,initEntityValue:je,registerField:je,useSubscribe:je,setInitialValues:je,destroyForm:je,setCallbacks:je,registerWatch:je,getFields:je,setValidateMessages:je,setPreserve:je,getInitialValue:je}}}),fi=L.createContext(null);function jo(r){return r==null?[]:Array.isArray(r)?r:[r]}function V1(r){return r&&!!r._init}function Vo(){return{default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var t=JSON.parse(JSON.stringify(this));return t.clone=this.clone,t}}}var Uo=Vo();function U1(r){try{return Function.toString.call(r).indexOf("[native code]")!==-1}catch{return typeof r=="function"}}function W1(r,t,e){if(cs())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var a=new(r.bind.apply(r,n));return e&&xn(a,e.prototype),a}function Wo(r){var t=typeof Map=="function"?new Map:void 0;return Wo=function(n){if(n===null||!U1(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(t!==void 0){if(t.has(n))return t.get(n);t.set(n,a)}function a(){return W1(n,arguments,Mn(this).constructor)}return a.prototype=Object.create(n.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),xn(a,n)},Wo(r)}var G1=/%[sdj%]/g,K1=function(){};function Go(r){if(!r||!r.length)return null;var t={};return r.forEach(function(e){var n=e.field;t[n]=t[n]||[],t[n].push(e)}),t}function Ut(r){for(var t=arguments.length,e=new Array(t>1?t-1:0),n=1;n<t;n++)e[n-1]=arguments[n];var a=0,i=e.length;if(typeof r=="function")return r.apply(null,e);if(typeof r=="string"){var o=r.replace(G1,function(s){if(s==="%%")return"%";if(a>=i)return s;switch(s){case"%s":return String(e[a++]);case"%d":return Number(e[a++]);case"%j":try{return JSON.stringify(e[a++])}catch{return"[Circular]"}break;default:return s}});return o}return r}function X1(r){return r==="string"||r==="url"||r==="hex"||r==="email"||r==="date"||r==="pattern"}function gt(r,t){return!!(r==null||t==="array"&&Array.isArray(r)&&!r.length||X1(t)&&typeof r=="string"&&!r)}function Y1(r,t,e){var n=[],a=0,i=r.length;function o(s){n.push.apply(n,fe(s||[])),a++,a===i&&e(n)}r.forEach(function(s){t(s,o)})}function V0(r,t,e){var n=0,a=r.length;function i(o){if(o&&o.length){e(o);return}var s=n;n=n+1,s<a?t(r[s],i):e([])}i([])}function Q1(r){var t=[];return Object.keys(r).forEach(function(e){t.push.apply(t,fe(r[e]||[]))}),t}var U0=(function(r){En(e,r);var t=An(e);function e(n,a){var i;return Rt(this,e),i=t.call(this,"Async Validation Error"),z(we(i),"errors",void 0),z(we(i),"fields",void 0),i.errors=n,i.fields=a,i}return Ot(e)})(Wo(Error));function Z1(r,t,e,n,a){if(t.first){var i=new Promise(function(d,g){var x=function(y){return n(y),y.length?g(new U0(y,Go(y))):d(a)},p=Q1(r);V0(p,e,x)});return i.catch(function(d){return d}),i}var o=t.firstFields===!0?Object.keys(r):t.firstFields||[],s=Object.keys(r),l=s.length,c=0,u=[],h=new Promise(function(d,g){var x=function(f){if(u.push.apply(u,f),c++,c===l)return n(u),u.length?g(new U0(u,Go(u))):d(a)};s.length||(n(u),d(a)),s.forEach(function(p){var f=r[p];o.indexOf(p)!==-1?V0(f,e,x):Y1(f,e,x)})});return h.catch(function(d){return d}),h}function J1(r){return!!(r&&r.message!==void 0)}function eg(r,t){for(var e=r,n=0;n<t.length;n++){if(e==null)return e;e=e[t[n]]}return e}function W0(r,t){return function(e){var n;return r.fullFields?n=eg(t,r.fullFields):n=t[e.field||r.fullField],J1(e)?(e.field=e.field||r.fullField,e.fieldValue=n,e):{message:typeof e=="function"?e():e,fieldValue:n,field:e.field||r.fullField}}}function G0(r,t){if(t){for(var e in t)if(t.hasOwnProperty(e)){var n=t[e];ge(n)==="object"&&ge(r[e])==="object"?r[e]=Y(Y({},r[e]),n):r[e]=n}}return r}var on="enum",tg=function(t,e,n,a,i){t[on]=Array.isArray(t[on])?t[on]:[],t[on].indexOf(e)===-1&&a.push(Ut(i.messages[on],t.fullField,t[on].join(", ")))},rg=function(t,e,n,a,i){if(t.pattern){if(t.pattern instanceof RegExp)t.pattern.lastIndex=0,t.pattern.test(e)||a.push(Ut(i.messages.pattern.mismatch,t.fullField,e,t.pattern));else if(typeof t.pattern=="string"){var o=new RegExp(t.pattern);o.test(e)||a.push(Ut(i.messages.pattern.mismatch,t.fullField,e,t.pattern))}}},ng=function(t,e,n,a,i){var o=typeof t.len=="number",s=typeof t.min=="number",l=typeof t.max=="number",c=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,u=e,h=null,d=typeof e=="number",g=typeof e=="string",x=Array.isArray(e);if(d?h="number":g?h="string":x&&(h="array"),!h)return!1;x&&(u=e.length),g&&(u=e.replace(c,"_").length),o?u!==t.len&&a.push(Ut(i.messages[h].len,t.fullField,t.len)):s&&!l&&u<t.min?a.push(Ut(i.messages[h].min,t.fullField,t.min)):l&&!s&&u>t.max?a.push(Ut(i.messages[h].max,t.fullField,t.max)):s&&l&&(u<t.min||u>t.max)&&a.push(Ut(i.messages[h].range,t.fullField,t.min,t.max))},Rl=function(t,e,n,a,i,o){t.required&&(!n.hasOwnProperty(t.field)||gt(e,o||t.type))&&a.push(Ut(i.messages.required,t.fullField))},ua;const ag=(function(){if(ua)return ua;var r="[a-fA-F\\d:]",t=function(E){return E&&E.includeBoundaries?"(?:(?<=\\s|^)(?=".concat(r,")|(?<=").concat(r,")(?=\\s|$))"):""},e="(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}",n="[a-fA-F\\d]{1,4}",a=["(?:".concat(n,":){7}(?:").concat(n,"|:)"),"(?:".concat(n,":){6}(?:").concat(e,"|:").concat(n,"|:)"),"(?:".concat(n,":){5}(?::").concat(e,"|(?::").concat(n,"){1,2}|:)"),"(?:".concat(n,":){4}(?:(?::").concat(n,"){0,1}:").concat(e,"|(?::").concat(n,"){1,3}|:)"),"(?:".concat(n,":){3}(?:(?::").concat(n,"){0,2}:").concat(e,"|(?::").concat(n,"){1,4}|:)"),"(?:".concat(n,":){2}(?:(?::").concat(n,"){0,3}:").concat(e,"|(?::").concat(n,"){1,5}|:)"),"(?:".concat(n,":){1}(?:(?::").concat(n,"){0,4}:").concat(e,"|(?::").concat(n,"){1,6}|:)"),"(?::(?:(?::".concat(n,"){0,5}:").concat(e,"|(?::").concat(n,"){1,7}|:))")],i="(?:%[0-9a-zA-Z]{1,})?",o="(?:".concat(a.join("|"),")").concat(i),s=new RegExp("(?:^".concat(e,"$)|(?:^").concat(o,"$)")),l=new RegExp("^".concat(e,"$")),c=new RegExp("^".concat(o,"$")),u=function(E){return E&&E.exact?s:new RegExp("(?:".concat(t(E)).concat(e).concat(t(E),")|(?:").concat(t(E)).concat(o).concat(t(E),")"),"g")};u.v4=function(F){return F&&F.exact?l:new RegExp("".concat(t(F)).concat(e).concat(t(F)),"g")},u.v6=function(F){return F&&F.exact?c:new RegExp("".concat(t(F)).concat(o).concat(t(F)),"g")};var h="(?:(?:[a-z]+:)?//)",d="(?:\\S+(?::\\S*)?@)?",g=u.v4().source,x=u.v6().source,p="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",f="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",y="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",v="(?::\\d{2,5})?",C='(?:[/?#][^\\s"]*)?',b="(?:".concat(h,"|www\\.)").concat(d,"(?:localhost|").concat(g,"|").concat(x,"|").concat(p).concat(f).concat(y,")").concat(v).concat(C);return ua=new RegExp("(?:^".concat(b,"$)"),"i"),ua});var K0={email:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},Pn={integer:function(t){return Pn.number(t)&&parseInt(t,10)===t},float:function(t){return Pn.number(t)&&!Pn.integer(t)},array:function(t){return Array.isArray(t)},regexp:function(t){if(t instanceof RegExp)return!0;try{return!!new RegExp(t)}catch{return!1}},date:function(t){return typeof t.getTime=="function"&&typeof t.getMonth=="function"&&typeof t.getYear=="function"&&!isNaN(t.getTime())},number:function(t){return isNaN(t)?!1:typeof t=="number"},object:function(t){return ge(t)==="object"&&!Pn.array(t)},method:function(t){return typeof t=="function"},email:function(t){return typeof t=="string"&&t.length<=320&&!!t.match(K0.email)},url:function(t){return typeof t=="string"&&t.length<=2048&&!!t.match(ag())},hex:function(t){return typeof t=="string"&&!!t.match(K0.hex)}},ig=function(t,e,n,a,i){if(t.required&&e===void 0){Rl(t,e,n,a,i);return}var o=["integer","float","array","regexp","object","method","email","number","date","url","hex"],s=t.type;o.indexOf(s)>-1?Pn[s](e)||a.push(Ut(i.messages.types[s],t.fullField,t.type)):s&&ge(e)!==t.type&&a.push(Ut(i.messages.types[s],t.fullField,t.type))},og=function(t,e,n,a,i){(/^\s+$/.test(e)||e==="")&&a.push(Ut(i.messages.whitespace,t.fullField))};const Be={required:Rl,whitespace:og,type:ig,range:ng,enum:tg,pattern:rg};var sg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i)}n(o)},cg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(e==null&&!t.required)return n();Be.required(t,e,a,o,i,"array"),e!=null&&(Be.type(t,e,a,o,i),Be.range(t,e,a,o,i))}n(o)},ug=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&Be.type(t,e,a,o,i)}n(o)},lg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e,"date")&&!t.required)return n();if(Be.required(t,e,a,o,i),!gt(e,"date")){var l;e instanceof Date?l=e:l=new Date(e),Be.type(t,l,a,o,i),l&&Be.range(t,l.getTime(),a,o,i)}}n(o)},fg="enum",dg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&Be[fg](t,e,a,o,i)}n(o)},pg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&(Be.type(t,e,a,o,i),Be.range(t,e,a,o,i))}n(o)},hg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&(Be.type(t,e,a,o,i),Be.range(t,e,a,o,i))}n(o)},vg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&Be.type(t,e,a,o,i)}n(o)},xg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(e===""&&(e=void 0),gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&(Be.type(t,e,a,o,i),Be.range(t,e,a,o,i))}n(o)},gg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),e!==void 0&&Be.type(t,e,a,o,i)}n(o)},mg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e,"string")&&!t.required)return n();Be.required(t,e,a,o,i),gt(e,"string")||Be.pattern(t,e,a,o,i)}n(o)},yg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e)&&!t.required)return n();Be.required(t,e,a,o,i),gt(e)||Be.type(t,e,a,o,i)}n(o)},Cg=function(t,e,n,a,i){var o=[],s=Array.isArray(e)?"array":ge(e);Be.required(t,e,a,o,i,s),n(o)},bg=function(t,e,n,a,i){var o=[],s=t.required||!t.required&&a.hasOwnProperty(t.field);if(s){if(gt(e,"string")&&!t.required)return n();Be.required(t,e,a,o,i,"string"),gt(e,"string")||(Be.type(t,e,a,o,i),Be.range(t,e,a,o,i),Be.pattern(t,e,a,o,i),t.whitespace===!0&&Be.whitespace(t,e,a,o,i))}n(o)},Gi=function(t,e,n,a,i){var o=t.type,s=[],l=t.required||!t.required&&a.hasOwnProperty(t.field);if(l){if(gt(e,o)&&!t.required)return n();Be.required(t,e,a,s,i,o),gt(e,o)||Be.type(t,e,a,s,i)}n(s)};const Rn={string:bg,method:vg,number:xg,boolean:ug,regexp:yg,integer:hg,float:pg,array:cg,object:gg,enum:dg,pattern:mg,date:lg,url:Gi,hex:Gi,email:Gi,required:Cg,any:sg};var Kn=(function(){function r(t){Rt(this,r),z(this,"rules",null),z(this,"_messages",Uo),this.define(t)}return Ot(r,[{key:"define",value:function(e){var n=this;if(!e)throw new Error("Cannot configure a schema with no rules");if(ge(e)!=="object"||Array.isArray(e))throw new Error("Rules must be an object");this.rules={},Object.keys(e).forEach(function(a){var i=e[a];n.rules[a]=Array.isArray(i)?i:[i]})}},{key:"messages",value:function(e){return e&&(this._messages=G0(Vo(),e)),this._messages}},{key:"validate",value:function(e){var n=this,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},o=e,s=a,l=i;if(typeof s=="function"&&(l=s,s={}),!this.rules||Object.keys(this.rules).length===0)return l&&l(null,o),Promise.resolve(o);function c(x){var p=[],f={};function y(C){if(Array.isArray(C)){var b;p=(b=p).concat.apply(b,fe(C))}else p.push(C)}for(var v=0;v<x.length;v++)y(x[v]);p.length?(f=Go(p),l(p,f)):l(null,o)}if(s.messages){var u=this.messages();u===Uo&&(u=Vo()),G0(u,s.messages),s.messages=u}else s.messages=this.messages();var h={},d=s.keys||Object.keys(this.rules);d.forEach(function(x){var p=n.rules[x],f=o[x];p.forEach(function(y){var v=y;typeof v.transform=="function"&&(o===e&&(o=Y({},o)),f=o[x]=v.transform(f),f!=null&&(v.type=v.type||(Array.isArray(f)?"array":ge(f)))),typeof v=="function"?v={validator:v}:v=Y({},v),v.validator=n.getValidationMethod(v),v.validator&&(v.field=x,v.fullField=v.fullField||x,v.type=n.getType(v),h[x]=h[x]||[],h[x].push({rule:v,value:f,source:o,field:x}))})});var g={};return Z1(h,s,function(x,p){var f=x.rule,y=(f.type==="object"||f.type==="array")&&(ge(f.fields)==="object"||ge(f.defaultField)==="object");y=y&&(f.required||!f.required&&x.value),f.field=x.field;function v(w,A){return Y(Y({},A),{},{fullField:"".concat(f.fullField,".").concat(w),fullFields:f.fullFields?[].concat(fe(f.fullFields),[w]):[w]})}function C(){var w=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],A=Array.isArray(w)?w:[w];!s.suppressWarning&&A.length&&r.warning("async-validator:",A),A.length&&f.message!==void 0&&(A=[].concat(f.message));var S=A.map(W0(f,o));if(s.first&&S.length)return g[f.field]=1,p(S);if(!y)p(S);else{if(f.required&&!x.value)return f.message!==void 0?S=[].concat(f.message).map(W0(f,o)):s.error&&(S=[s.error(f,Ut(s.messages.required,f.field))]),p(S);var m={};f.defaultField&&Object.keys(x.value).map(function(P){m[P]=f.defaultField}),m=Y(Y({},m),x.rule.fields);var B={};Object.keys(m).forEach(function(P){var T=m[P],$=Array.isArray(T)?T:[T];B[P]=$.map(v.bind(null,P))});var _=new r(B);_.messages(s.messages),x.rule.options&&(x.rule.options.messages=s.messages,x.rule.options.error=s.error),_.validate(x.value,x.rule.options||s,function(P){var T=[];S&&S.length&&T.push.apply(T,fe(S)),P&&P.length&&T.push.apply(T,fe(P)),p(T.length?T:null)})}}var b;if(f.asyncValidator)b=f.asyncValidator(f,x.value,C,x.source,s);else if(f.validator){try{b=f.validator(f,x.value,C,x.source,s)}catch(w){var F,E;(F=(E=console).error)===null||F===void 0||F.call(E,w),s.suppressValidatorError||setTimeout(function(){throw w},0),C(w.message)}b===!0?C():b===!1?C(typeof f.message=="function"?f.message(f.fullField||f.field):f.message||"".concat(f.fullField||f.field," fails")):b instanceof Array?C(b):b instanceof Error&&C(b.message)}b&&b.then&&b.then(function(){return C()},function(w){return C(w)})},function(x){c(x)},o)}},{key:"getType",value:function(e){if(e.type===void 0&&e.pattern instanceof RegExp&&(e.type="pattern"),typeof e.validator!="function"&&e.type&&!Rn.hasOwnProperty(e.type))throw new Error(Ut("Unknown rule type %s",e.type));return e.type||"string"}},{key:"getValidationMethod",value:function(e){if(typeof e.validator=="function")return e.validator;var n=Object.keys(e),a=n.indexOf("message");return a!==-1&&n.splice(a,1),n.length===1&&n[0]==="required"?Rn.required:Rn[this.getType(e)]||void 0}}]),r})();z(Kn,"register",function(t,e){if(typeof e!="function")throw new Error("Cannot register a validator by type, validator is not a function");Rn[t]=e});z(Kn,"warning",K1);z(Kn,"messages",Uo);z(Kn,"validators",Rn);var Vt="'${name}' is not a valid ${type}",Ol={default:"Validation error on field '${name}'",required:"'${name}' is required",enum:"'${name}' must be one of [${enum}]",whitespace:"'${name}' cannot be empty",date:{format:"'${name}' is invalid for format date",parse:"'${name}' could not be parsed as date",invalid:"'${name}' is invalid date"},types:{string:Vt,method:Vt,array:Vt,object:Vt,number:Vt,date:Vt,boolean:Vt,integer:Vt,float:Vt,regexp:Vt,email:Vt,url:Vt,hex:Vt},string:{len:"'${name}' must be exactly ${len} characters",min:"'${name}' must be at least ${min} characters",max:"'${name}' cannot be longer than ${max} characters",range:"'${name}' must be between ${min} and ${max} characters"},number:{len:"'${name}' must equal ${len}",min:"'${name}' cannot be less than ${min}",max:"'${name}' cannot be greater than ${max}",range:"'${name}' must be between ${min} and ${max}"},array:{len:"'${name}' must be exactly ${len} in length",min:"'${name}' cannot be less than ${min} in length",max:"'${name}' cannot be greater than ${max} in length",range:"'${name}' must be between ${min} and ${max} in length"},pattern:{mismatch:"'${name}' does not match pattern ${pattern}"}},X0=Kn;function Fg(r,t){return r.replace(/\\?\$\{\w+\}/g,function(e){if(e.startsWith("\\"))return e.slice(1);var n=e.slice(2,-1);return t[n]})}var Y0="CODE_LOGIC_ERROR";function Ko(r,t,e,n,a){return Xo.apply(this,arguments)}function Xo(){return Xo=Gr(_t().mark(function r(t,e,n,a,i){var o,s,l,c,u,h,d,g,x;return _t().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return o=Y({},n),delete o.ruleIndex,X0.warning=function(){},o.validator&&(s=o.validator,o.validator=function(){try{return s.apply(void 0,arguments)}catch(y){return console.error(y),Promise.reject(Y0)}}),l=null,o&&o.type==="array"&&o.defaultField&&(l=o.defaultField,delete o.defaultField),c=new X0(z({},t,[o])),u=un(Ol,a.validateMessages),c.messages(u),h=[],f.prev=10,f.next=13,Promise.resolve(c.validate(z({},t,e),Y({},a)));case 13:f.next=18;break;case 15:f.prev=15,f.t0=f.catch(10),f.t0.errors&&(h=f.t0.errors.map(function(y,v){var C=y.message,b=C===Y0?u.default:C;return L.isValidElement(b)?L.cloneElement(b,{key:"error_".concat(v)}):b}));case 18:if(!(!h.length&&l&&Array.isArray(e)&&e.length>0)){f.next=23;break}return f.next=21,Promise.all(e.map(function(y,v){return Ko("".concat(t,".").concat(v),y,l,a,i)}));case 21:return d=f.sent,f.abrupt("return",d.reduce(function(y,v){return[].concat(fe(y),fe(v))},[]));case 23:return g=Y(Y({},n),{},{name:t,enum:(n.enum||[]).join(", ")},i),x=h.map(function(y){return typeof y=="string"?Fg(y,g):y}),f.abrupt("return",x);case 26:case"end":return f.stop()}},r,null,[[10,15]])})),Xo.apply(this,arguments)}function Eg(r,t,e,n,a,i){var o=r.join("."),s=e.map(function(u,h){var d=u.validator,g=Y(Y({},u),{},{ruleIndex:h});return d&&(g.validator=function(x,p,f){var y=!1,v=function(){for(var F=arguments.length,E=new Array(F),w=0;w<F;w++)E[w]=arguments[w];Promise.resolve().then(function(){Wt(!y,"Your validator function has already return a promise. `callback` will be ignored."),y||f.apply(void 0,E)})},C=d(x,p,v);y=C&&typeof C.then=="function"&&typeof C.catch=="function",Wt(y,"`callback` is deprecated. Please return a promise instead."),y&&C.then(function(){f()}).catch(function(b){f(b||" ")})}),g}).sort(function(u,h){var d=u.warningOnly,g=u.ruleIndex,x=h.warningOnly,p=h.ruleIndex;return!!d==!!x?g-p:d?1:-1}),l;if(a===!0)l=new Promise((function(){var u=Gr(_t().mark(function h(d,g){var x,p,f;return _t().wrap(function(v){for(;;)switch(v.prev=v.next){case 0:x=0;case 1:if(!(x<s.length)){v.next=12;break}return p=s[x],v.next=5,Ko(o,t,p,n,i);case 5:if(f=v.sent,!f.length){v.next=9;break}return g([{errors:f,rule:p}]),v.abrupt("return");case 9:x+=1,v.next=1;break;case 12:d([]);case 13:case"end":return v.stop()}},h)}));return function(h,d){return u.apply(this,arguments)}})());else{var c=s.map(function(u){return Ko(o,t,u,n,i).then(function(h){return{errors:h,rule:u}})});l=(a?wg(c):Ag(c)).then(function(u){return Promise.reject(u)})}return l.catch(function(u){return u}),l}function Ag(r){return Yo.apply(this,arguments)}function Yo(){return Yo=Gr(_t().mark(function r(t){return _t().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",Promise.all(t).then(function(a){var i,o=(i=[]).concat.apply(i,fe(a));return o}));case 1:case"end":return n.stop()}},r)})),Yo.apply(this,arguments)}function wg(r){return Qo.apply(this,arguments)}function Qo(){return Qo=Gr(_t().mark(function r(t){var e;return _t().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return e=0,a.abrupt("return",new Promise(function(i){t.forEach(function(o){o.then(function(s){s.errors.length&&i([s]),e+=1,e===t.length&&i([])})})}));case 2:case"end":return a.stop()}},r)})),Qo.apply(this,arguments)}function lt(r){return jo(r)}function Q0(r,t){var e={};return t.forEach(function(n){var a=mr(r,n);e=ir(e,n,a)}),e}function hn(r,t){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return r&&r.some(function(n){return Nl(t,n,e)})}function Nl(r,t){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return!r||!t||!e&&r.length!==t.length?!1:t.every(function(n,a){return r[a]===n})}function Sg(r,t){if(r===t)return!0;if(!r&&t||r&&!t||!r||!t||ge(r)!=="object"||ge(t)!=="object")return!1;var e=Object.keys(r),n=Object.keys(t),a=new Set([].concat(e,n));return fe(a).every(function(i){var o=r[i],s=t[i];return typeof o=="function"&&typeof s=="function"?!0:o===s})}function Bg(r){var t=arguments.length<=1?void 0:arguments[1];return t&&t.target&&ge(t.target)==="object"&&r in t.target?t.target[r]:t}function Z0(r,t,e){var n=r.length;if(t<0||t>=n||e<0||e>=n)return r;var a=r[t],i=t-e;return i>0?[].concat(fe(r.slice(0,e)),[a],fe(r.slice(e,t)),fe(r.slice(t+1,n))):i<0?[].concat(fe(r.slice(0,t)),fe(r.slice(t+1,e+1)),[a],fe(r.slice(e+1,n))):r}var _g=["name"],Qt=[];function Ki(r,t,e,n,a,i){return typeof r=="function"?r(t,e,"source"in i?{source:i.source}:{}):n!==a}var ys=(function(r){En(e,r);var t=An(e);function e(n){var a;if(Rt(this,e),a=t.call(this,n),z(we(a),"state",{resetCount:0}),z(we(a),"cancelRegisterFunc",null),z(we(a),"mounted",!1),z(we(a),"touched",!1),z(we(a),"dirty",!1),z(we(a),"validatePromise",void 0),z(we(a),"prevValidating",void 0),z(we(a),"errors",Qt),z(we(a),"warnings",Qt),z(we(a),"cancelRegister",function(){var l=a.props,c=l.preserve,u=l.isListField,h=l.name;a.cancelRegisterFunc&&a.cancelRegisterFunc(u,c,lt(h)),a.cancelRegisterFunc=null}),z(we(a),"getNamePath",function(){var l=a.props,c=l.name,u=l.fieldContext,h=u.prefixName,d=h===void 0?[]:h;return c!==void 0?[].concat(fe(d),fe(c)):[]}),z(we(a),"getRules",function(){var l=a.props,c=l.rules,u=c===void 0?[]:c,h=l.fieldContext;return u.map(function(d){return typeof d=="function"?d(h):d})}),z(we(a),"refresh",function(){a.mounted&&a.setState(function(l){var c=l.resetCount;return{resetCount:c+1}})}),z(we(a),"metaCache",null),z(we(a),"triggerMetaEvent",function(l){var c=a.props.onMetaChange;if(c){var u=Y(Y({},a.getMeta()),{},{destroy:l});uo(a.metaCache,u)||c(u),a.metaCache=u}else a.metaCache=null}),z(we(a),"onStoreChange",function(l,c,u){var h=a.props,d=h.shouldUpdate,g=h.dependencies,x=g===void 0?[]:g,p=h.onReset,f=u.store,y=a.getNamePath(),v=a.getValue(l),C=a.getValue(f),b=c&&hn(c,y);switch(u.type==="valueUpdate"&&u.source==="external"&&!uo(v,C)&&(a.touched=!0,a.dirty=!0,a.validatePromise=null,a.errors=Qt,a.warnings=Qt,a.triggerMetaEvent()),u.type){case"reset":if(!c||b){a.touched=!1,a.dirty=!1,a.validatePromise=void 0,a.errors=Qt,a.warnings=Qt,a.triggerMetaEvent(),p==null||p(),a.refresh();return}break;case"remove":{if(d&&Ki(d,l,f,v,C,u)){a.reRender();return}break}case"setField":{var F=u.data;if(b){"touched"in F&&(a.touched=F.touched),"validating"in F&&!("originRCField"in F)&&(a.validatePromise=F.validating?Promise.resolve([]):null),"errors"in F&&(a.errors=F.errors||Qt),"warnings"in F&&(a.warnings=F.warnings||Qt),a.dirty=!0,a.triggerMetaEvent(),a.reRender();return}else if("value"in F&&hn(c,y,!0)){a.reRender();return}if(d&&!y.length&&Ki(d,l,f,v,C,u)){a.reRender();return}break}case"dependenciesUpdate":{var E=x.map(lt);if(E.some(function(w){return hn(u.relatedFields,w)})){a.reRender();return}break}default:if(b||(!x.length||y.length||d)&&Ki(d,l,f,v,C,u)){a.reRender();return}break}d===!0&&a.reRender()}),z(we(a),"validateRules",function(l){var c=a.getNamePath(),u=a.getValue(),h=l||{},d=h.triggerName,g=h.validateOnly,x=g===void 0?!1:g,p=Promise.resolve().then(Gr(_t().mark(function f(){var y,v,C,b,F,E,w;return _t().wrap(function(S){for(;;)switch(S.prev=S.next){case 0:if(a.mounted){S.next=2;break}return S.abrupt("return",[]);case 2:if(y=a.props,v=y.validateFirst,C=v===void 0?!1:v,b=y.messageVariables,F=y.validateDebounce,E=a.getRules(),d&&(E=E.filter(function(m){return m}).filter(function(m){var B=m.validateTrigger;if(!B)return!0;var _=jo(B);return _.includes(d)})),!(F&&d)){S.next=10;break}return S.next=8,new Promise(function(m){setTimeout(m,F)});case 8:if(a.validatePromise===p){S.next=10;break}return S.abrupt("return",[]);case 10:return w=Eg(c,u,E,l,C,b),w.catch(function(m){return m}).then(function(){var m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Qt;if(a.validatePromise===p){var B;a.validatePromise=null;var _=[],P=[];(B=m.forEach)===null||B===void 0||B.call(m,function(T){var $=T.rule.warningOnly,H=T.errors,j=H===void 0?Qt:H;$?P.push.apply(P,fe(j)):_.push.apply(_,fe(j))}),a.errors=_,a.warnings=P,a.triggerMetaEvent(),a.reRender()}}),S.abrupt("return",w);case 13:case"end":return S.stop()}},f)})));return x||(a.validatePromise=p,a.dirty=!0,a.errors=Qt,a.warnings=Qt,a.triggerMetaEvent(),a.reRender()),p}),z(we(a),"isFieldValidating",function(){return!!a.validatePromise}),z(we(a),"isFieldTouched",function(){return a.touched}),z(we(a),"isFieldDirty",function(){if(a.dirty||a.props.initialValue!==void 0)return!0;var l=a.props.fieldContext,c=l.getInternalHooks(Vr),u=c.getInitialValue;return u(a.getNamePath())!==void 0}),z(we(a),"getErrors",function(){return a.errors}),z(we(a),"getWarnings",function(){return a.warnings}),z(we(a),"isListField",function(){return a.props.isListField}),z(we(a),"isList",function(){return a.props.isList}),z(we(a),"isPreserve",function(){return a.props.preserve}),z(we(a),"getMeta",function(){a.prevValidating=a.isFieldValidating();var l={touched:a.isFieldTouched(),validating:a.prevValidating,errors:a.errors,warnings:a.warnings,name:a.getNamePath(),validated:a.validatePromise===null};return l}),z(we(a),"getOnlyChild",function(l){if(typeof l=="function"){var c=a.getMeta();return Y(Y({},a.getOnlyChild(l(a.getControlled(),c,a.props.fieldContext))),{},{isFunction:!0})}var u=qo(l);return u.length!==1||!L.isValidElement(u[0])?{child:u,isFunction:!1}:{child:u[0],isFunction:!1}}),z(we(a),"getValue",function(l){var c=a.props.fieldContext.getFieldsValue,u=a.getNamePath();return mr(l||c(!0),u)}),z(we(a),"getControlled",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=a.props,u=c.name,h=c.trigger,d=c.validateTrigger,g=c.getValueFromEvent,x=c.normalize,p=c.valuePropName,f=c.getValueProps,y=c.fieldContext,v=d!==void 0?d:y.validateTrigger,C=a.getNamePath(),b=y.getInternalHooks,F=y.getFieldsValue,E=b(Vr),w=E.dispatch,A=a.getValue(),S=f||function(T){return z({},p,T)},m=l[h],B=u!==void 0?S(A):{},_=Y(Y({},l),B);_[h]=function(){a.touched=!0,a.dirty=!0,a.triggerMetaEvent();for(var T,$=arguments.length,H=new Array($),j=0;j<$;j++)H[j]=arguments[j];g?T=g.apply(void 0,H):T=Bg.apply(void 0,[p].concat(H)),x&&(T=x(T,A,F(!0))),T!==A&&w({type:"updateValue",namePath:C,value:T}),m&&m.apply(void 0,H)};var P=jo(v||[]);return P.forEach(function(T){var $=_[T];_[T]=function(){$&&$.apply(void 0,arguments);var H=a.props.rules;H&&H.length&&w({type:"validateField",namePath:C,triggerName:T})}}),_}),n.fieldContext){var i=n.fieldContext.getInternalHooks,o=i(Vr),s=o.initEntityValue;s(we(a))}return a}return Ot(e,[{key:"componentDidMount",value:function(){var a=this.props,i=a.shouldUpdate,o=a.fieldContext;if(this.mounted=!0,o){var s=o.getInternalHooks,l=s(Vr),c=l.registerField;this.cancelRegisterFunc=c(this)}i===!0&&this.reRender()}},{key:"componentWillUnmount",value:function(){this.cancelRegister(),this.triggerMetaEvent(!0),this.mounted=!1}},{key:"reRender",value:function(){this.mounted&&this.forceUpdate()}},{key:"render",value:function(){var a=this.state.resetCount,i=this.props.children,o=this.getOnlyChild(i),s=o.child,l=o.isFunction,c;return l?c=s:L.isValidElement(s)?c=L.cloneElement(s,this.getControlled(s.props)):(Wt(!s,"`children` of Field is not validate ReactElement."),c=s),L.createElement(L.Fragment,{key:a},c)}}]),e})(L.Component);z(ys,"contextType",Cn);z(ys,"defaultProps",{trigger:"onChange",valuePropName:"value"});function Ml(r){var t,e=r.name,n=Cr(r,_g),a=L.useContext(Cn),i=L.useContext(fi),o=e!==void 0?lt(e):void 0,s=(t=n.isListField)!==null&&t!==void 0?t:!!i,l="keep";return s||(l="_".concat((o||[]).join("_"))),L.createElement(ys,bt({key:l,name:o,isListField:s},n,{fieldContext:a}))}function Dg(r){var t=r.name,e=r.initialValue,n=r.children,a=r.rules,i=r.validateTrigger,o=r.isListField,s=L.useContext(Cn),l=L.useContext(fi),c=L.useRef({keys:[],id:0}),u=c.current,h=L.useMemo(function(){var p=lt(s.prefixName)||[];return[].concat(fe(p),fe(lt(t)))},[s.prefixName,t]),d=L.useMemo(function(){return Y(Y({},s),{},{prefixName:h})},[s,h]),g=L.useMemo(function(){return{getKey:function(f){var y=h.length,v=f[y];return[u.keys[v],f.slice(y+1)]}}},[h]);if(typeof n!="function")return Wt(!1,"Form.List only accepts function as children."),null;var x=function(f,y,v){var C=v.source;return C==="internal"?!1:f!==y};return L.createElement(fi.Provider,{value:g},L.createElement(Cn.Provider,{value:d},L.createElement(Ml,{name:[],shouldUpdate:x,rules:a,validateTrigger:i,initialValue:e,isList:!0,isListField:o??!!l},function(p,f){var y=p.value,v=y===void 0?[]:y,C=p.onChange,b=s.getFieldValue,F=function(){var S=b(h||[]);return S||[]},E={add:function(S,m){var B=F();m>=0&&m<=B.length?(u.keys=[].concat(fe(u.keys.slice(0,m)),[u.id],fe(u.keys.slice(m))),C([].concat(fe(B.slice(0,m)),[S],fe(B.slice(m))))):(u.keys=[].concat(fe(u.keys),[u.id]),C([].concat(fe(B),[S]))),u.id+=1},remove:function(S){var m=F(),B=new Set(Array.isArray(S)?S:[S]);B.size<=0||(u.keys=u.keys.filter(function(_,P){return!B.has(P)}),C(m.filter(function(_,P){return!B.has(P)})))},move:function(S,m){if(S!==m){var B=F();S<0||S>=B.length||m<0||m>=B.length||(u.keys=Z0(u.keys,S,m),C(Z0(B,S,m)))}}},w=v||[];return Array.isArray(w)||(w=[]),n(w.map(function(A,S){var m=u.keys[S];return m===void 0&&(u.keys[S]=u.id,m=u.keys[S],u.id+=1),{name:S,key:m,isListField:!0}}),E,f)})))}function kg(r){var t=!1,e=r.length,n=[];return r.length?new Promise(function(a,i){r.forEach(function(o,s){o.catch(function(l){return t=!0,l}).then(function(l){e-=1,n[s]=l,!(e>0)&&(t&&i(n),a(n))})})}):Promise.resolve([])}var Ll="__@field_split__";function Xi(r){return r.map(function(t){return"".concat(ge(t),":").concat(t)}).join(Ll)}var sn=(function(){function r(){Rt(this,r),z(this,"kvs",new Map)}return Ot(r,[{key:"set",value:function(e,n){this.kvs.set(Xi(e),n)}},{key:"get",value:function(e){return this.kvs.get(Xi(e))}},{key:"update",value:function(e,n){var a=this.get(e),i=n(a);i?this.set(e,i):this.delete(e)}},{key:"delete",value:function(e){this.kvs.delete(Xi(e))}},{key:"map",value:function(e){return fe(this.kvs.entries()).map(function(n){var a=ce(n,2),i=a[0],o=a[1],s=i.split(Ll);return e({key:s.map(function(l){var c=l.match(/^([^:]*):(.*)$/),u=ce(c,3),h=u[1],d=u[2];return h==="number"?Number(d):d}),value:o})})}},{key:"toJSON",value:function(){var e={};return this.map(function(n){var a=n.key,i=n.value;return e[a.join(".")]=i,null}),e}}]),r})(),Pg=["name"],Ig=Ot(function r(t){var e=this;Rt(this,r),z(this,"formHooked",!1),z(this,"forceRootUpdate",void 0),z(this,"subscribable",!0),z(this,"store",{}),z(this,"fieldEntities",[]),z(this,"initialValues",{}),z(this,"callbacks",{}),z(this,"validateMessages",null),z(this,"preserve",null),z(this,"lastValidatePromise",null),z(this,"getForm",function(){return{getFieldValue:e.getFieldValue,getFieldsValue:e.getFieldsValue,getFieldError:e.getFieldError,getFieldWarning:e.getFieldWarning,getFieldsError:e.getFieldsError,isFieldsTouched:e.isFieldsTouched,isFieldTouched:e.isFieldTouched,isFieldValidating:e.isFieldValidating,isFieldsValidating:e.isFieldsValidating,resetFields:e.resetFields,setFields:e.setFields,setFieldValue:e.setFieldValue,setFieldsValue:e.setFieldsValue,validateFields:e.validateFields,submit:e.submit,_init:!0,getInternalHooks:e.getInternalHooks}}),z(this,"getInternalHooks",function(n){return n===Vr?(e.formHooked=!0,{dispatch:e.dispatch,initEntityValue:e.initEntityValue,registerField:e.registerField,useSubscribe:e.useSubscribe,setInitialValues:e.setInitialValues,destroyForm:e.destroyForm,setCallbacks:e.setCallbacks,setValidateMessages:e.setValidateMessages,getFields:e.getFields,setPreserve:e.setPreserve,getInitialValue:e.getInitialValue,registerWatch:e.registerWatch}):(Wt(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)}),z(this,"useSubscribe",function(n){e.subscribable=n}),z(this,"prevWithoutPreserves",null),z(this,"setInitialValues",function(n,a){if(e.initialValues=n||{},a){var i,o=un(n,e.store);(i=e.prevWithoutPreserves)===null||i===void 0||i.map(function(s){var l=s.key;o=ir(o,l,mr(n,l))}),e.prevWithoutPreserves=null,e.updateStore(o)}}),z(this,"destroyForm",function(n){if(n)e.updateStore({});else{var a=new sn;e.getFieldEntities(!0).forEach(function(i){e.isMergedPreserve(i.isPreserve())||a.set(i.getNamePath(),!0)}),e.prevWithoutPreserves=a}}),z(this,"getInitialValue",function(n){var a=mr(e.initialValues,n);return n.length?un(a):a}),z(this,"setCallbacks",function(n){e.callbacks=n}),z(this,"setValidateMessages",function(n){e.validateMessages=n}),z(this,"setPreserve",function(n){e.preserve=n}),z(this,"watchList",[]),z(this,"registerWatch",function(n){return e.watchList.push(n),function(){e.watchList=e.watchList.filter(function(a){return a!==n})}}),z(this,"notifyWatch",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(e.watchList.length){var a=e.getFieldsValue(),i=e.getFieldsValue(!0);e.watchList.forEach(function(o){o(a,i,n)})}}),z(this,"timeoutId",null),z(this,"warningUnhooked",function(){}),z(this,"updateStore",function(n){e.store=n}),z(this,"getFieldEntities",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return n?e.fieldEntities.filter(function(a){return a.getNamePath().length}):e.fieldEntities}),z(this,"getFieldsMap",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,a=new sn;return e.getFieldEntities(n).forEach(function(i){var o=i.getNamePath();a.set(o,i)}),a}),z(this,"getFieldEntitiesForNamePathList",function(n){if(!n)return e.getFieldEntities(!0);var a=e.getFieldsMap(!0);return n.map(function(i){var o=lt(i);return a.get(o)||{INVALIDATE_NAME_PATH:lt(i)}})}),z(this,"getFieldsValue",function(n,a){e.warningUnhooked();var i,o,s;if(n===!0||Array.isArray(n)?(i=n,o=a):n&&ge(n)==="object"&&(s=n.strict,o=n.filter),i===!0&&!o)return e.store;var l=e.getFieldEntitiesForNamePathList(Array.isArray(i)?i:null),c=[];return l.forEach(function(u){var h,d,g="INVALIDATE_NAME_PATH"in u?u.INVALIDATE_NAME_PATH:u.getNamePath();if(s){var x,p;if((x=(p=u).isList)!==null&&x!==void 0&&x.call(p))return}else if(!i&&(h=(d=u).isListField)!==null&&h!==void 0&&h.call(d))return;if(!o)c.push(g);else{var f="getMeta"in u?u.getMeta():null;o(f)&&c.push(g)}}),Q0(e.store,c.map(lt))}),z(this,"getFieldValue",function(n){e.warningUnhooked();var a=lt(n);return mr(e.store,a)}),z(this,"getFieldsError",function(n){e.warningUnhooked();var a=e.getFieldEntitiesForNamePathList(n);return a.map(function(i,o){return i&&!("INVALIDATE_NAME_PATH"in i)?{name:i.getNamePath(),errors:i.getErrors(),warnings:i.getWarnings()}:{name:lt(n[o]),errors:[],warnings:[]}})}),z(this,"getFieldError",function(n){e.warningUnhooked();var a=lt(n),i=e.getFieldsError([a])[0];return i.errors}),z(this,"getFieldWarning",function(n){e.warningUnhooked();var a=lt(n),i=e.getFieldsError([a])[0];return i.warnings}),z(this,"isFieldsTouched",function(){e.warningUnhooked();for(var n=arguments.length,a=new Array(n),i=0;i<n;i++)a[i]=arguments[i];var o=a[0],s=a[1],l,c=!1;a.length===0?l=null:a.length===1?Array.isArray(o)?(l=o.map(lt),c=!1):(l=null,c=o):(l=o.map(lt),c=s);var u=e.getFieldEntities(!0),h=function(f){return f.isFieldTouched()};if(!l)return c?u.every(function(p){return h(p)||p.isList()}):u.some(h);var d=new sn;l.forEach(function(p){d.set(p,[])}),u.forEach(function(p){var f=p.getNamePath();l.forEach(function(y){y.every(function(v,C){return f[C]===v})&&d.update(y,function(v){return[].concat(fe(v),[p])})})});var g=function(f){return f.some(h)},x=d.map(function(p){var f=p.value;return f});return c?x.every(g):x.some(g)}),z(this,"isFieldTouched",function(n){return e.warningUnhooked(),e.isFieldsTouched([n])}),z(this,"isFieldsValidating",function(n){e.warningUnhooked();var a=e.getFieldEntities();if(!n)return a.some(function(o){return o.isFieldValidating()});var i=n.map(lt);return a.some(function(o){var s=o.getNamePath();return hn(i,s)&&o.isFieldValidating()})}),z(this,"isFieldValidating",function(n){return e.warningUnhooked(),e.isFieldsValidating([n])}),z(this,"resetWithFieldInitialValue",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=new sn,i=e.getFieldEntities(!0);i.forEach(function(l){var c=l.props.initialValue,u=l.getNamePath();if(c!==void 0){var h=a.get(u)||new Set;h.add({entity:l,value:c}),a.set(u,h)}});var o=function(c){c.forEach(function(u){var h=u.props.initialValue;if(h!==void 0){var d=u.getNamePath(),g=e.getInitialValue(d);if(g!==void 0)Wt(!1,"Form already set 'initialValues' with path '".concat(d.join("."),"'. Field can not overwrite it."));else{var x=a.get(d);if(x&&x.size>1)Wt(!1,"Multiple Field with path '".concat(d.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(x){var p=e.getFieldValue(d),f=u.isListField();!f&&(!n.skipExist||p===void 0)&&e.updateStore(ir(e.store,d,fe(x)[0].value))}}}})},s;n.entities?s=n.entities:n.namePathList?(s=[],n.namePathList.forEach(function(l){var c=a.get(l);if(c){var u;(u=s).push.apply(u,fe(fe(c).map(function(h){return h.entity})))}})):s=i,o(s)}),z(this,"resetFields",function(n){e.warningUnhooked();var a=e.store;if(!n){e.updateStore(un(e.initialValues)),e.resetWithFieldInitialValue(),e.notifyObservers(a,null,{type:"reset"}),e.notifyWatch();return}var i=n.map(lt);i.forEach(function(o){var s=e.getInitialValue(o);e.updateStore(ir(e.store,o,s))}),e.resetWithFieldInitialValue({namePathList:i}),e.notifyObservers(a,i,{type:"reset"}),e.notifyWatch(i)}),z(this,"setFields",function(n){e.warningUnhooked();var a=e.store,i=[];n.forEach(function(o){var s=o.name,l=Cr(o,Pg),c=lt(s);i.push(c),"value"in l&&e.updateStore(ir(e.store,c,l.value)),e.notifyObservers(a,[c],{type:"setField",data:o})}),e.notifyWatch(i)}),z(this,"getFields",function(){var n=e.getFieldEntities(!0),a=n.map(function(i){var o=i.getNamePath(),s=i.getMeta(),l=Y(Y({},s),{},{name:o,value:e.getFieldValue(o)});return Object.defineProperty(l,"originRCField",{value:!0}),l});return a}),z(this,"initEntityValue",function(n){var a=n.props.initialValue;if(a!==void 0){var i=n.getNamePath(),o=mr(e.store,i);o===void 0&&e.updateStore(ir(e.store,i,a))}}),z(this,"isMergedPreserve",function(n){var a=n!==void 0?n:e.preserve;return a??!0}),z(this,"registerField",function(n){e.fieldEntities.push(n);var a=n.getNamePath();if(e.notifyWatch([a]),n.props.initialValue!==void 0){var i=e.store;e.resetWithFieldInitialValue({entities:[n],skipExist:!0}),e.notifyObservers(i,[n.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(o,s){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(e.fieldEntities=e.fieldEntities.filter(function(h){return h!==n}),!e.isMergedPreserve(s)&&(!o||l.length>1)){var c=o?void 0:e.getInitialValue(a);if(a.length&&e.getFieldValue(a)!==c&&e.fieldEntities.every(function(h){return!Nl(h.getNamePath(),a)})){var u=e.store;e.updateStore(ir(u,a,c,!0)),e.notifyObservers(u,[a],{type:"remove"}),e.triggerDependenciesUpdate(u,a)}}e.notifyWatch([a])}}),z(this,"dispatch",function(n){switch(n.type){case"updateValue":{var a=n.namePath,i=n.value;e.updateValue(a,i);break}case"validateField":{var o=n.namePath,s=n.triggerName;e.validateFields([o],{triggerName:s});break}}}),z(this,"notifyObservers",function(n,a,i){if(e.subscribable){var o=Y(Y({},i),{},{store:e.getFieldsValue(!0)});e.getFieldEntities().forEach(function(s){var l=s.onStoreChange;l(n,a,o)})}else e.forceRootUpdate()}),z(this,"triggerDependenciesUpdate",function(n,a){var i=e.getDependencyChildrenFields(a);return i.length&&e.validateFields(i),e.notifyObservers(n,i,{type:"dependenciesUpdate",relatedFields:[a].concat(fe(i))}),i}),z(this,"updateValue",function(n,a){var i=lt(n),o=e.store;e.updateStore(ir(e.store,i,a)),e.notifyObservers(o,[i],{type:"valueUpdate",source:"internal"}),e.notifyWatch([i]);var s=e.triggerDependenciesUpdate(o,i),l=e.callbacks.onValuesChange;if(l){var c=Q0(e.store,[i]);l(c,e.getFieldsValue())}e.triggerOnFieldsChange([i].concat(fe(s)))}),z(this,"setFieldsValue",function(n){e.warningUnhooked();var a=e.store;if(n){var i=un(e.store,n);e.updateStore(i)}e.notifyObservers(a,null,{type:"valueUpdate",source:"external"}),e.notifyWatch()}),z(this,"setFieldValue",function(n,a){e.setFields([{name:n,value:a,errors:[],warnings:[]}])}),z(this,"getDependencyChildrenFields",function(n){var a=new Set,i=[],o=new sn;e.getFieldEntities().forEach(function(l){var c=l.props.dependencies;(c||[]).forEach(function(u){var h=lt(u);o.update(h,function(){var d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return d.add(l),d})})});var s=function l(c){var u=o.get(c)||new Set;u.forEach(function(h){if(!a.has(h)){a.add(h);var d=h.getNamePath();h.isFieldDirty()&&d.length&&(i.push(d),l(d))}})};return s(n),i}),z(this,"triggerOnFieldsChange",function(n,a){var i=e.callbacks.onFieldsChange;if(i){var o=e.getFields();if(a){var s=new sn;a.forEach(function(c){var u=c.name,h=c.errors;s.set(u,h)}),o.forEach(function(c){c.errors=s.get(c.name)||c.errors})}var l=o.filter(function(c){var u=c.name;return hn(n,u)});l.length&&i(l,o)}}),z(this,"validateFields",function(n,a){e.warningUnhooked();var i,o;Array.isArray(n)||typeof n=="string"||typeof a=="string"?(i=n,o=a):o=n;var s=!!i,l=s?i.map(lt):[],c=[],u=String(Date.now()),h=new Set,d=o||{},g=d.recursive,x=d.dirty;e.getFieldEntities(!0).forEach(function(v){if(s||l.push(v.getNamePath()),!(!v.props.rules||!v.props.rules.length)&&!(x&&!v.isFieldDirty())){var C=v.getNamePath();if(h.add(C.join(u)),!s||hn(l,C,g)){var b=v.validateRules(Y({validateMessages:Y(Y({},Ol),e.validateMessages)},o));c.push(b.then(function(){return{name:C,errors:[],warnings:[]}}).catch(function(F){var E,w=[],A=[];return(E=F.forEach)===null||E===void 0||E.call(F,function(S){var m=S.rule.warningOnly,B=S.errors;m?A.push.apply(A,fe(B)):w.push.apply(w,fe(B))}),w.length?Promise.reject({name:C,errors:w,warnings:A}):{name:C,errors:w,warnings:A}}))}}});var p=kg(c);e.lastValidatePromise=p,p.catch(function(v){return v}).then(function(v){var C=v.map(function(b){var F=b.name;return F});e.notifyObservers(e.store,C,{type:"validateFinish"}),e.triggerOnFieldsChange(C,v)});var f=p.then(function(){return e.lastValidatePromise===p?Promise.resolve(e.getFieldsValue(l)):Promise.reject([])}).catch(function(v){var C=v.filter(function(b){return b&&b.errors.length});return Promise.reject({values:e.getFieldsValue(l),errorFields:C,outOfDate:e.lastValidatePromise!==p})});f.catch(function(v){return v});var y=l.filter(function(v){return h.has(v.join(u))});return e.triggerOnFieldsChange(y),f}),z(this,"submit",function(){e.warningUnhooked(),e.validateFields().then(function(n){var a=e.callbacks.onFinish;if(a)try{a(n)}catch(i){console.error(i)}}).catch(function(n){var a=e.callbacks.onFinishFailed;a&&a(n)})}),this.forceRootUpdate=t});function Cs(r){var t=L.useRef(),e=L.useState({}),n=ce(e,2),a=n[1];if(!t.current)if(r)t.current=r;else{var i=function(){a({})},o=new Ig(i);t.current=o.getForm()}return[t.current]}var Zo=L.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),Tg=function(t){var e=t.validateMessages,n=t.onFormChange,a=t.onFormFinish,i=t.children,o=L.useContext(Zo),s=L.useRef({});return L.createElement(Zo.Provider,{value:Y(Y({},o),{},{validateMessages:Y(Y({},o.validateMessages),e),triggerFormChange:function(c,u){n&&n(c,{changedFields:u,forms:s.current}),o.triggerFormChange(c,u)},triggerFormFinish:function(c,u){a&&a(c,{values:u,forms:s.current}),o.triggerFormFinish(c,u)},registerForm:function(c,u){c&&(s.current=Y(Y({},s.current),{},z({},c,u))),o.registerForm(c,u)},unregisterForm:function(c){var u=Y({},s.current);delete u[c],s.current=u,o.unregisterForm(c)}})},i)},Rg=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed","clearOnDestroy"],Og=function(t,e){var n=t.name,a=t.initialValues,i=t.fields,o=t.form,s=t.preserve,l=t.children,c=t.component,u=c===void 0?"form":c,h=t.validateMessages,d=t.validateTrigger,g=d===void 0?"onChange":d,x=t.onValuesChange,p=t.onFieldsChange,f=t.onFinish,y=t.onFinishFailed,v=t.clearOnDestroy,C=Cr(t,Rg),b=L.useRef(null),F=L.useContext(Zo),E=Cs(o),w=ce(E,1),A=w[0],S=A.getInternalHooks(Vr),m=S.useSubscribe,B=S.setInitialValues,_=S.setCallbacks,P=S.setValidateMessages,T=S.setPreserve,$=S.destroyForm;L.useImperativeHandle(e,function(){return Y(Y({},A),{},{nativeElement:b.current})}),L.useEffect(function(){return F.registerForm(n,A),function(){F.unregisterForm(n)}},[F,A,n]),P(Y(Y({},F.validateMessages),h)),_({onValuesChange:x,onFieldsChange:function(I){if(F.triggerFormChange(n,I),p){for(var U=arguments.length,K=new Array(U>1?U-1:0),Z=1;Z<U;Z++)K[Z-1]=arguments[Z];p.apply(void 0,[I].concat(K))}},onFinish:function(I){F.triggerFormFinish(n,I),f&&f(I)},onFinishFailed:y}),T(s);var H=L.useRef(null);B(a,!H.current),H.current||(H.current=!0),L.useEffect(function(){return function(){return $(v)}},[]);var j,q=typeof l=="function";if(q){var G=A.getFieldsValue(!0);j=l(G,A)}else j=l;m(!q);var X=L.useRef();L.useEffect(function(){Sg(X.current||[],i||[])||A.setFields(i||[]),X.current=i},[i,A]);var O=L.useMemo(function(){return Y(Y({},A),{},{validateTrigger:g})},[A,g]),M=L.createElement(fi.Provider,{value:null},L.createElement(Cn.Provider,{value:O},j));return u===!1?M:L.createElement(u,bt({},C,{ref:b,onSubmit:function(I){I.preventDefault(),I.stopPropagation(),A.submit()},onReset:function(I){var U;I.preventDefault(),A.resetFields(),(U=C.onReset)===null||U===void 0||U.call(C,I)}}),M)};function J0(r){try{return JSON.stringify(r)}catch{return Math.random()}}function Ng(){for(var r=arguments.length,t=new Array(r),e=0;e<r;e++)t[e]=arguments[e];var n=t[0],a=t[1],i=a===void 0?{}:a,o=V1(i)?{form:i}:i,s=o.form,l=le(),c=ce(l,2),u=c[0],h=c[1],d=Ke(function(){return J0(u)},[u]),g=Ve(d);g.current=d;var x=lr(Cn),p=s||x,f=p&&p._init,y=lt(n),v=Ve(y);return v.current=y,De(function(){if(f){var C=p.getFieldsValue,b=p.getInternalHooks,F=b(Vr),E=F.registerWatch,w=function(B,_){var P=o.preserve?_:B;return typeof n=="function"?n(P):mr(P,v.current)},A=E(function(m,B){var _=w(m,B),P=J0(_);g.current!==P&&(g.current=P,h(_))}),S=w(C(),C(!0));return u!==S&&h(S),A}},[f]),u}var Mg=L.forwardRef(Og),Xn=Mg;Xn.FormProvider=Tg;Xn.Field=Ml;Xn.List=Dg;Xn.useForm=Cs;Xn.useWatch=Ng;const ec=r=>typeof r=="object"&&r!=null&&r.nodeType===1,tc=(r,t)=>(!t||r!=="hidden")&&r!=="visible"&&r!=="clip",la=(r,t)=>{if(r.clientHeight<r.scrollHeight||r.clientWidth<r.scrollWidth){const e=getComputedStyle(r,null);return tc(e.overflowY,t)||tc(e.overflowX,t)||(n=>{const a=(i=>{if(!i.ownerDocument||!i.ownerDocument.defaultView)return null;try{return i.ownerDocument.defaultView.frameElement}catch{return null}})(n);return!!a&&(a.clientHeight<n.scrollHeight||a.clientWidth<n.scrollWidth)})(r)}return!1},fa=(r,t,e,n,a,i,o,s)=>i<r&&o>t||i>r&&o<t?0:i<=r&&s<=e||o>=t&&s>=e?i-r-n:o>t&&s<e||i<r&&s>e?o-t+a:0,Lg=r=>{const t=r.parentElement;return t??(r.getRootNode().host||null)},rc=(r,t)=>{var e,n,a,i;if(typeof document>"u")return[];const{scrollMode:o,block:s,inline:l,boundary:c,skipOverflowHiddenElements:u}=t,h=typeof c=="function"?c:H=>H!==c;if(!ec(r))throw new TypeError("Invalid target");const d=document.scrollingElement||document.documentElement,g=[];let x=r;for(;ec(x)&&h(x);){if(x=Lg(x),x===d){g.push(x);break}x!=null&&x===document.body&&la(x)&&!la(document.documentElement)||x!=null&&la(x,u)&&g.push(x)}const p=(n=(e=window.visualViewport)==null?void 0:e.width)!=null?n:innerWidth,f=(i=(a=window.visualViewport)==null?void 0:a.height)!=null?i:innerHeight,{scrollX:y,scrollY:v}=window,{height:C,width:b,top:F,right:E,bottom:w,left:A}=r.getBoundingClientRect(),{top:S,right:m,bottom:B,left:_}=(H=>{const j=window.getComputedStyle(H);return{top:parseFloat(j.scrollMarginTop)||0,right:parseFloat(j.scrollMarginRight)||0,bottom:parseFloat(j.scrollMarginBottom)||0,left:parseFloat(j.scrollMarginLeft)||0}})(r);let P=s==="start"||s==="nearest"?F-S:s==="end"?w+B:F+C/2-S+B,T=l==="center"?A+b/2-_+m:l==="end"?E+m:A-_;const $=[];for(let H=0;H<g.length;H++){const j=g[H],{height:q,width:G,top:X,right:O,bottom:M,left:R}=j.getBoundingClientRect();if(o==="if-needed"&&F>=0&&A>=0&&w<=f&&E<=p&&(j===d&&!la(j)||F>=X&&w<=M&&A>=R&&E<=O))return $;const I=getComputedStyle(j),U=parseInt(I.borderLeftWidth,10),K=parseInt(I.borderTopWidth,10),Z=parseInt(I.borderRightWidth,10),Q=parseInt(I.borderBottomWidth,10);let J=0,pe=0;const Ie="offsetWidth"in j?j.offsetWidth-j.clientWidth-U-Z:0,Se="offsetHeight"in j?j.offsetHeight-j.clientHeight-K-Q:0,ie="offsetWidth"in j?j.offsetWidth===0?0:G/j.offsetWidth:0,Ae="offsetHeight"in j?j.offsetHeight===0?0:q/j.offsetHeight:0;if(d===j)J=s==="start"?P:s==="end"?P-f:s==="nearest"?fa(v,v+f,f,K,Q,v+P,v+P+C,C):P-f/2,pe=l==="start"?T:l==="center"?T-p/2:l==="end"?T-p:fa(y,y+p,p,U,Z,y+T,y+T+b,b),J=Math.max(0,J+v),pe=Math.max(0,pe+y);else{J=s==="start"?P-X-K:s==="end"?P-M+Q+Se:s==="nearest"?fa(X,M,q,K,Q+Se,P,P+C,C):P-(X+q/2)+Se/2,pe=l==="start"?T-R-U:l==="center"?T-(R+G/2)+Ie/2:l==="end"?T-O+Z+Ie:fa(R,O,G,U,Z+Ie,T,T+b,b);const{scrollLeft:Ne,scrollTop:he}=j;J=Ae===0?0:Math.max(0,Math.min(he+J/Ae,j.scrollHeight-q/Ae+Se)),pe=ie===0?0:Math.max(0,Math.min(Ne+pe/ie,j.scrollWidth-G/ie+Ie)),P+=he-J,T+=Ne-pe}$.push({el:j,top:J,left:pe})}return $},$g=r=>r===!1?{block:"end",inline:"nearest"}:(t=>t===Object(t)&&Object.keys(t).length!==0)(r)?r:{block:"start",inline:"nearest"};function zg(r,t){if(!r.isConnected||!(a=>{let i=a;for(;i&&i.parentNode;){if(i.parentNode===document)return!0;i=i.parentNode instanceof ShadowRoot?i.parentNode.host:i.parentNode}return!1})(r))return;const e=(a=>{const i=window.getComputedStyle(a);return{top:parseFloat(i.scrollMarginTop)||0,right:parseFloat(i.scrollMarginRight)||0,bottom:parseFloat(i.scrollMarginBottom)||0,left:parseFloat(i.scrollMarginLeft)||0}})(r);if((a=>typeof a=="object"&&typeof a.behavior=="function")(t))return t.behavior(rc(r,t));const n=typeof t=="boolean"||t==null?void 0:t.behavior;for(const{el:a,top:i,left:o}of rc(r,$g(t))){const s=i-e.top+e.bottom,l=o-e.left+e.right;a.scroll({top:s,left:l,behavior:n})}}const Hg=["parentNode"],qg="form_item";function $l(r){return r===void 0||r===!1?[]:Array.isArray(r)?r:[r]}function jg(r,t){if(!r.length)return;const e=r.join("_");return t?`${t}_${e}`:Hg.includes(e)?`${qg}_${e}`:e}var Vg=function(r,t){var e={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&t.indexOf(n)<0&&(e[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(e[n[a]]=r[n[a]]);return e};function nc(r){return $l(r).join("_")}function ac(r,t){const e=t.getFieldInstance(r),n=al(e);if(n)return n;const a=jg($l(r),t.__INTERNAL__.name);if(a)return document.getElementById(a)}function zl(r){const[t]=Cs(),e=L.useRef({}),n=L.useMemo(()=>Object.assign(Object.assign({},t),{__INTERNAL__:{itemRef:a=>i=>{const o=nc(a);i?e.current[o]=i:delete e.current[o]}},scrollToField:(a,i={})=>{const{focus:o}=i,s=Vg(i,["focus"]),l=ac(a,n);l&&(zg(l,Object.assign({scrollMode:"if-needed",block:"nearest"},s)),o&&n.focusField(a))},focusField:a=>{var i,o;const s=n.getFieldInstance(a);typeof(s==null?void 0:s.focus)=="function"?s.focus():(o=(i=ac(a,n))===null||i===void 0?void 0:i.focus)===null||o===void 0||o.call(i)},getFieldInstance:a=>{const i=nc(a);return e.current[i]}}),[r,t]);return[n]}const Ug=({isModalOpen:r,handleOk:t,handleCancel:e,data:n})=>{const a={header:{height:"60px",borderBottom:"1px solid #F0F0F0",display:"flex",paddingLeft:"24px",alignItems:"center",marginBottom:"16px"},title:{fontSize:"16px"},body:{padding:"0 24px"},mask:{},footer:{marginTop:"0px",padding:"0 24px 16px 24px"},content:{padding:0}},[i]=zl();return De(()=>{if(!r){i.resetFields();return}i.setFieldValue("new_name",n==null?void 0:n.label)},[n,r]),N(di,{modal:{styles:a},children:N(Vc,{title:N("div",{className:"text-[16px]",children:"\u7F16\u8F91\u4F1A\u8BDD\u540D\u79F0"}),closeIcon:null,open:r,width:520,centered:!0,className:"[&:[.ant-modal-content]]:bg-red",footer:re("div",{className:"mt-[16px] flex justify-end",children:[N(vn,{children:"\u53D6\u6D88",onClick:e,className:"mr-[8px]"}),N(vn,{children:"\u786E\u8BA4",onClick:async()=>{try{const o=await i.validateFields();t("ok_rename",o)}catch(o){console.log(o);return}},type:"primary",className:"border-none"})]}),children:N(Bs,{form:i,children:N(Bs.Item,{name:"new_name",rules:[{required:!0,message:"\u8BF7\u8F93\u5165"},{max:100,message:"\u6700\u5927\u5B57\u6570\u9650\u5236100"}],children:N(jc,{})})})})})},Wg=({isModalOpen:r,handleOk:t,handleCancel:e,data:n})=>{const a={header:{height:"60px",borderBottom:"1px solid #F0F0F0",display:"flex",paddingLeft:"24px",alignItems:"center",marginBottom:"16px"},title:{fontSize:"16px"},body:{padding:"0 24px"},mask:{},footer:{marginTop:"0px",padding:"0 24px 16px 24px"},content:{padding:0}},[i]=zl();return De(()=>{if(!r){i.resetFields();return}i.setFieldValue("new_name",n==null?void 0:n.label)},[n,r]),N(di,{modal:{styles:a},children:N(Vc,{title:N("div",{className:"text-[16px]",children:"\u5220\u9664\u4F1A\u8BDD"}),closeIcon:null,open:r,width:520,centered:!0,className:"[&:[.ant-modal-content]]:bg-red",footer:re("div",{className:"mt-[16px] flex justify-end",children:[N(vn,{children:"\u53D6\u6D88",onClick:e,className:"mr-[8px]"}),N(vn,{children:"\u786E\u8BA4",onClick:async()=>{try{const o=await i.validateFields();t("ok_remove",o)}catch(o){console.log(o);return}},type:"primary",className:"border-none"})]}),children:N("div",{children:`\u786E\u5B9A\u8981\u5220\u9664\u4F1A\u8BDD\u300C${n.label}\u300D\u5417\uFF1F\u5220\u9664\u540E\u65E0\u6CD5\u6062\u590D\u3002`})})})},Gg="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAFQSURBVHgBpVMxTsNQDLWTiIYBFG7Q3iCcgLIxQJWxZSpbOxFO0HICOhE2shGxEFCGbvQGcAPCCahgIJHoN/5RaEOUBAJPsmTZ3/aT/T4Co23ZxoYeWVACEjj/UOhx6l2E+RzudQfNNcR79ptQjfD1vbE98yfzbFDTEE1ZrBC1/IIJEhYPEYhPKUs3m1OQyJBOWfFPOQX+CQ1qQu6sATBaCLwNrh2/NgOdjQC2FBVu5PW+MTjoDvrccSdfJNILqQCzdB9WpzckudQlg87hYISIl7I7G2YNAZ75SrtFy1wxIBwLwtPAc8ZQA5qq676II5MAw8A7n+z3hpLW2d2V0/pVA99NlGV/BRJdIDbltqcV91++zwesvm2IOH6AEmkTkfsW6Seb6/EL+0dY9EhKl1mYi1Slq3HCQFCP2WHWZJY2qEL6L5LPJ/gy8BfIJmxt6X8C+32HILvaN+0AAAAASUVORK5CYII=",Fi=({title:r,setOpen:t})=>re("div",{style:{width:"100%",height:"60px",borderBottom:"1px solid #EBEBEB",padding:"20px",display:"flex",justifyContent:"space-between",alignItems:"center",fontSize:"16px",fontWeight:600},children:[N("div",{children:r}),N("img",{src:Sf,style:{width:"16px",height:"16px",cursor:"pointer"},onClick:()=>t(!1)})]});Bf();const Kg=({curFileInfo:r,onClose:t,token:e})=>{var s;const n={title:"",subtitle:"",backgroundColor:"#f8f9fa",showGrid:!1,showLegend:!1,showTooltip:!1,showFullscreen:!1,showMinimap:!1},[a,i]=le({nodeList:[],edgeList:[]});De(()=>{console.log("curFileInfo",r)},[r]);const o=async l=>{if(!(!(l!=null&&l.id)||!(l!=null&&l.cyphers)||!(l!=null&&l.fetchUrl)))try{const{cyphers:c,fetchUrl:u,id:h}=l||{};console.log("getGraphData params",c,u,h);const d=await Mt.post(u,{cyphers:c,ontologyId:h},{headers:{Authorization:e}});console.log("getGraphData res",d),i((d==null?void 0:d.data)||{})}catch(c){console.log("error",c)}};return De(()=>{o(r)},[r]),re("div",{children:[N(Fi,{title:r==null?void 0:r.graphName,setOpen:t}),N("div",{style:{width:"100%",height:"calc(100vh - 60px)"},children:N(_f,{centerNode:{vid:(s=r==null?void 0:r.traceNode)==null?void 0:s.vid},data:a,layout:{type:"force",linkDistance:190},title:n.title,subtitle:n.subtitle,backgroundColor:n.backgroundColor,showGrid:n.showGrid,showLegend:n.showLegend,showTooltip:n.showTooltip,showFullscreen:n.showFullscreen,showMinimap:n.showMinimap,customPlugins:{},onReady:l=>{console.log("KnowledgeGraphPreview ready:",l)}})})]})},Xg=({content:r,onClose:t,token:e})=>{const n=o=>{if(!(o!=null&&o.metadata))return;const s=Zi(o,""),{page_number:l,page_size:c,position:u,offset:h,chunk_type:d}=o.metadata;if(s==="markdown_table")return h!=null&&h.length?{annotations:[{id:yr(),offsets:h}],initialPage:1}:{};{if(!c||!u)return console.log("%c\u7F3A\u5C11\u6587\u4EF6size\u6216\u8005\u6587\u4EF6\u5750\u6807","color: red"),{};const g=Array.isArray(c)?c:JSON.parse(c);if(!g.length)return console.log("%c\u7F3A\u5C11\u6587\u4EF6size","color: red"),{};const x=Array.isArray(u)?u:JSON.parse(u);return!x.length||!l?(console.log("%c\u7F3A\u5C11\u6587\u4EF6\u5750\u6807\u6216\u8005\u6587\u4EF6\u9875\u6570","color: red"),{}):{annotations:x.map((f,y)=>({id:yr(),pageNumber:l[y],x:+(f[0][0]/g[0][0]).toFixed(4),y:+(f[0][1]/g[0][1]).toFixed(4),width:+((f[1][0]-f[0][0])/g[0][0]).toFixed(4),height:+((f[2][1]-f[0][1])/g[0][1]).toFixed(4),content:"",color:d==="image"?"#60f74f":"#4FC3F7"})),initialPage:l[0]}}},a=Ke(()=>{var o,s;if(console.log("content88888888888",r),r&&e){console.log("content999",r);const{annotations:l,initialPage:c}=n(r),u={...r,metadata:{source:((o=r==null?void 0:r.metadata)==null?void 0:o.source)||r.parse_url||r.url,page_size:(s=r==null?void 0:r.metadata)==null?void 0:s.page_size}},h=Gc(Kc(u));return{filePath:h,fileName:ts(u),fileType:Zi(u,h),totalPages:u.pdfPages||0,token:e,annotations:l,initialPage:c,initialZoom:Xc(598,u)}}else return{}},[r]),i=Ke(()=>a.filePath?(console.log("curData",a),N(Qc,{initialZoom:a.initialZoom||100,convertedFilePath:a.filePath,fileName:a.fileName,fileType:a.fileType,initialPage:a.initialPage,totalPages:a.totalPages,authorization:a.token,annotations:a.annotations,streamApiUrl:"/proxy/index/knowledgeBase/file/stream",eventsEmit:o=>{switch(o){case"viewer:close":t();break}},tools:{close:!0}})):N(Vn,{}),[a]);return N("div",{style:{fontFamily:"Source Han Sans CN",fontSize:"12px"},className:"h-full w-full",children:i})},Hl=({curFileInfo:r,onClose:t,token:e})=>{const n=Ke(()=>{var i,o,s;if(r&&e){console.log("content999",r);const l={file_source:r.parse_url||r.parsedFilePath||r.url,file_type:r.file_type,metadata:{source:r.filePath||r.url||((i=r==null?void 0:r.metadata)==null?void 0:i.source)||"",page_size:(o=r==null?void 0:r.metadata)==null?void 0:o.page_size},pdfPages:r.pdfPages},c=Gc(Kc(l));return{filePath:c,fileName:ts(l),fileType:Zi(l,c),totalPages:l.pdfPages||0,token:e,initialZoom:Xc(((s=document.getElementById("pdfBox"))==null?void 0:s.clientWidth)||0,l)}}else return{}},[r]),a=Ke(()=>(console.log("curData",n),n.filePath?N(Qc,{initialZoom:n.initialZoom||100,convertedFilePath:n.filePath,fileName:n.fileName,fileType:n.fileType,initialPage:1,totalPages:n.totalPages,authorization:n.token,streamApiUrl:"/proxy/index/knowledgeBase/file/stream",eventsEmit:i=>{switch(i){case"viewer:close":t();break}},tools:{close:!0}}):N(Vn,{})),[n]);return N("div",{id:"pdfBox",className:"h-full overflow-y-auto",children:a})},Yg=({curFileInfo:r,token:t,onClose:e})=>{const[n,a]=le(1),[i,o]=le(10),[s,l]=le([]),[c,u]=le([]),[h,d]=le(0);De(()=>{var y;const f=((y=r==null?void 0:r.metadata)==null?void 0:y.fetchUrl)||(r==null?void 0:r.fetchUrl);f&&x(f)},[r,n,i]);const g=async({url:f,params:y})=>{var v;try{const C=await Mt.get(`${Ji()}${f}?${new URLSearchParams(y).toString()}`,{headers:{Authorization:t}}),b=(v=C==null?void 0:C.data)==null?void 0:v.data;if(b){const{columns:F,dataList:E,totalData:w}=b;l(((F==null?void 0:F.slice(1))||[]).map(A=>({title:A.businessName,dataIndex:A.physicalName,key:A.physicalName}))),u(E||[]),d(w||[])}}catch(C){console.log("error",C)}},x=async f=>{g({url:`${f}`,params:{pageNo:n,pageSize:i}})},p=Ke(()=>{const{databaseName:f,businessTableName:y,tableName:v}=r;return`${f} - ${v||y}`},[r]);return re("div",{children:[N(Fi,{title:p,setOpen:e}),(s==null?void 0:s.length)>0?re("div",{children:[N("div",{className:"p-4 overflow-auto h-[calc(100vh-120px)]",children:N(hf,{columns:s,dataSource:c,pagination:!1,scroll:{x:"max-content"},rowKey:"id"})}),N("div",{className:"flex justify-end px-[18px]",children:N(vf,{current:n,pageSize:i,responsive:!0,simple:!0,total:h,showSizeChanger:!0,showQuickJumper:!0,onChange:(f,y)=>{a(f),o(y||10)},onShowSizeChange:(f,y)=>{a(1),o(y)}})})]}):N(xf,{})]})},Yi=({i:r,item:t,j:e,clickTag:n})=>{const a=(e==null?void 0:e.name)!=null&&e.name!==""?String(e.name):(e==null?void 0:e.label)!=null&&e.label!==""?String(e.label):(e==null?void 0:e.content)!=null&&e.content!==""?String(e.content):(e==null?void 0:e.index)!=null?String(e.index):"";return N("div",{style:{minWidth:"16px",maxWidth:"80px",height:"16px",padding:"0 4px",backgroundColor:Zg[t.key],margin:"0 4px",color:Jg[t.key],display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"2px",fontSize:"12px",cursor:"pointer",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},onClick:()=>n&&n(r,e,t),title:a,children:a},e.id)};function Qg(r){if(typeof r=="string"){const t=r.trim();if(!t)return"";const e=t.match(/\d{4}-\d{2}-\d{2}/);if(e!=null&&e[0])return e[0];const n=new Date(t);return Number.isNaN(n.getTime())?"":n.toISOString().slice(0,10)}if(r instanceof Date&&!Number.isNaN(r.getTime()))return r.toISOString().slice(0,10);if(typeof r=="number"&&Number.isFinite(r)){const t=new Date(r);if(!Number.isNaN(t.getTime()))return t.toISOString().slice(0,10)}return""}const Zg={knowledgeList:"#EAF4FD",searchList:"#E8F7F0",databaseList:"#FFF4E5",graphList:"#E7F8FB"},Jg={knowledgeList:"#2072F0",searchList:"#39B83F",databaseList:"#F48C14",graphList:"#10BBD9"},ic=[{key:"knowledgeList",name:"\u77E5\u8BC6\u5E93\u6587\u6863"},{key:"searchList",name:"\u8054\u7F51\u641C\u7D22",hideBtns:!0},{key:"databaseList",name:"\u6570\u636E\u5E93",hideBtns:!0},{key:"graphList",name:"\u77E5\u8BC6\u56FE\u8C31",hideBtns:!0}],oc=({type:r,data:t,token:e,eventsEmit:n,is_download:a})=>{const[i,o]=le(ic),[s,l]=le("mark"),[c,u]=le(!1),[h,d]=le({}),[g,x]=le("knowledgeList"),[p,f]=le({knowledgeList:[],searchList:[],databaseList:[],graphList:[]}),y=Ke(()=>{const A=4-i.length,S=Array(A).fill(null).map((B,_)=>({name:"",key:100+_})),m=[...i,...S];return console.log("rrrrrr",m),m},[i]),v=A=>isNaN(A)?"":(+A).toFixed(2),C=A=>{switch(A){case"searchList":return Mf;case"databaseList":return Nf;case"graphList":return Of;default:return""}},b=A=>{const S=(A||"").toLowerCase();return["pdf"].includes(S)?"rag/pdf":["doc","docx"].includes(S)?"rag/word":["csv"].includes(S)?"rag/csv":["xls","xlsx"].includes(S)?"rag/excel":["ppt","pptx","pub"].includes(S)?"rag/ppt":["png","jpg","jpeg","jpge"].includes(S)?"rag/pic":(["txt"].includes(S),"rag/txt")},F=(A,S)=>{if(A==="knowledgeList"){let B=((S==null?void 0:S.file_type)||"").toLowerCase();if(!B||B==="faq"){const _=(S==null?void 0:S.metadata)||{},P=_.folder_path||(S==null?void 0:S.folder_path)||_.file_path||_.source||(S==null?void 0:S.source)||(S==null?void 0:S.file_name)||"",T=String(P).match(/\.([a-z0-9]+)$/i);T&&(B=T[1].toLowerCase())}return N(Tf,{type:b(B),size:22,style:{flexShrink:0}})}const m=C(A);return m?N("img",{src:m,style:{width:"22px",height:"22px",flexShrink:0}}):null},E=(A,S)=>A==="graphList"?S.map(m=>({...m,name:m.graphName})).sort((m,B)=>(B.score||0)-(m.score||0)):A==="knowledgeList"?S.map(m=>{const B=m.metadata||{},_=typeof m.score=="number"?m.score:typeof m.rrf_score=="number"?m.rrf_score:typeof B.score=="number"?B.score:0;if(m.type==="faq"){const T=B.folder_path||m.folder_path||B.knowledge_base_name||m.file_name||B.source||m.source||"",$=String(T).match(/\.([a-z0-9]+)$/i),H=$?$[1].toLowerCase():"faq";return{...m,file_type:H,name:T,score:_}}const P=m.sourceFileName||Pf(m.source)||m.file_name;return{...m,file_type:If(m.source)||m.file_type,name:P,score:_}}).sort((m,B)=>(B.score||0)-(m.score||0)):A==="searchList"?S.map(m=>({...m,name:m.sourceFileName||m.file_name})).sort((m,B)=>(B.score||0)-(m.score||0)):A==="databaseList"?S.map(m=>{const B=m.tableName?`${m.databaseName||"\u6570\u636E\u5E93"} - ${m.tableName}`:m.databaseName||m.name||"\u6570\u636E\u5E93";return{...m,name:B,file_name:B,file_type:"database"}}).sort((m,B)=>(B.score||0)-(m.score||0)):S,w=(A,S,m)=>{var B;switch(m.key){case"knowledgeList":const{pdfPages:_,parsedFilePath:P,order_num:T,tags:$}=A||{},H=S.id||T||"Unknown ID",j=($||[]).find(I=>I.id===H);if(A.type==="faq"){d(A),l("faq"),u(!0),n==null||n("retrive_tag:click",{tagInfo:{id:S.id,index:S.index,image_urls:S.image_urls||[]},fromtype:"10",leaf:{id:S.id,fromtype:"10"},referenceDoc:A});return}if(A.type==="video")return console.log("sdgasdgag",{file:{...A,...j}}),n==null?void 0:n("retrive_tag:click",{file:{...A,...j}});if(console.log("click knowledge tag",A,S),!A||!j)return;const{metadata:q}=j,G=q.source.split("/"),X=G[G.length-1]||"",O=X.split("."),M=O.slice(0,-1).join(".")||"Unknown Label",R=O[O.length-1]||"Unknown Type";d({id:H,title:M,file_name:X,file_type:R,file_source:Rf(R)?`${eo}${q.source}`:P,metadata:q,pdfPages:_}),l("mark"),u(!0);break;case"searchList":console.log("click search tag",A,S);break;case"databaseList":console.log("click database tag",A,S),l("database"),d({...A,metadata:A.metadata||{},fetchUrl:A.fetchUrl||((B=A.metadata)==null?void 0:B.fetchUrl)||""}),u(!0);break;case"graphList":console.log("click graph tag",A,S),l("graphPreview"),d({...A,traceNode:((t==null?void 0:t.traceNode)||[]).find(I=>I.id===S.id)}),u(!0);break}};return De(()=>{if(r!==ql.REFERENCELIST||(console.log("data in reference drawer",t),!t))return;const{graphRefs:A,knowledgeRefs:S,webRefs:m,databaseRefs:B}=t;A!=null&&A.length&&(p.graphList=E("graphList",A)),S!=null&&S.length&&(p.knowledgeList=E("knowledgeList",S)),m!=null&&m.length&&(p.searchList=E("searchList",m)),B!=null&&B.length&&(p.databaseList=E("databaseList",B));const _=ic.filter(P=>{var T;return(T=p[P.key])==null?void 0:T.length}).sort((P,T)=>{var $,H;return((($=p[T.key])==null?void 0:$.length)||0)-(((H=p[P.key])==null?void 0:H.length)||0)});o(_),_!=null&&_.length&&x(_[0].key),f({...p})},[t]),re(Vn,{children:[re("div",{className:"listWrap w-full h-full",children:[N(Fi,{title:"\u77E5\u8BC6\u6EAF\u6E90",setOpen:()=>{const A=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(A)}}),re("div",{style:{height:"calc(100% - 60px)"},children:[N("div",{className:"tabs",style:{display:"flex",justifyContent:"space-between",padding:"12px 20px"},children:y.map(A=>N("div",{className:"tab-item",style:{padding:"5.5px 12px",backgroundColor:A.name?g===A.key?"#4E6EF2":"#F5F6F9":"transparent",cursor:"pointer",borderRadius:"4px",color:g===A.key?"#FFFFFF":"#4E5969",fontSize:"14px",minWidth:"80px",display:"flex",justifyContent:"center"},onClick:()=>{A.name&&x(A.key)},children:A.name},A.key))}),N("div",{className:"listBox",style:{height:"calc(100% - 66px)",overflowY:"auto",display:"flex",flexDirection:"column",alignItems:"center",willChange:"scroll-position",transform:"translateZ(0)"},children:i.map(A=>{let S=p[A.key]||[];return g!==A.key?null:N("div",{children:S.map(m=>{var B,_,P,T,$,H,j;return re("div",{style:{width:"360px",padding:"4px 8px",borderRadius:"4px",margin:"6px 0",cursor:"pointer"},className:"listItemBox",onClick:()=>{A.key==="searchList"&&window.open(m.link,"_blank")},children:[re("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:"8px"},children:[re("div",{style:{flex:1,minWidth:0,fontSize:"14px",color:"#1D2129",fontWeight:"700",display:"flex",alignItems:"center"},children:[N("div",{style:{width:22,height:22,marginRight:2,flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center"},children:F(A.key,m)}),N(On,{placement:"topLeft",title:((B=m==null?void 0:m.name)==null?void 0:B.length)>17?m.name:"",children:N("div",{style:{minWidth:0,overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:2,WebkitBoxOrient:"vertical",lineHeight:1.4,wordBreak:"break-all"},onClick:()=>{var q,G;if(A.key==="knowledgeList"){if(m.type==="faq"){d(m),l("faq"),u(!0),n==null||n("retrive_tag:click",{tagInfo:{id:m.pk,index:(q=(m.tags||[])[0])==null?void 0:q.index,image_urls:[]},fromtype:"10",leaf:{id:m.pk,fromtype:"10"},referenceDoc:m});return}n==null||n("knowledge_referenceFile_title:click",{data:{...m,file_type:m.file_type,file_name:m.file_name,metadata:m.metadata,parsedFilePath:m.parsedFilePath}})}else A.key==="databaseList"&&(l("database"),d({...m,metadata:m.metadata||{},fetchUrl:m.fetchUrl||((G=m.metadata)==null?void 0:G.fetchUrl)||""}),u(!0))},children:m.name})})]}),((_=m==null?void 0:m.tags)==null?void 0:_.length)&&m.tags.length>0&&m.tags.length<=10&&m.type!=="faq"&&N("div",{style:{display:"flex",alignItems:"center",flexShrink:0,gap:"2px"},children:(m.tags||[]).map(q=>N(Yi,{i:m,item:A,j:q,clickTag:w},q.id))}),re("div",{style:{width:"52px",justifyContent:"space-between",alignItems:"center",marginRight:"8px",display:A.hideBtns||m.type==="video"||m.type==="faq"||m.faq_question||m.faq_answer?"none":"flex"},children:[N("img",{src:Gg,style:{width:"16px",height:"16px",cursor:"pointer"},onClick:()=>{n==null||n("referenceFile_filechat",{data:{...m,file_type:m.file_type,file_name:m.file_name,metadata:m.metadata,parsedFilePath:m.parsedFilePath}})}}),N("div",{style:{borderRight:"1px solid #E5E6EB",height:"14px"}}),N("img",{src:Df,style:{width:"16px",height:"16px",cursor:a?"pointer":"not-allowed"},onClick:()=>{var G,X,O;if(!((G=m==null?void 0:m.tags)!=null&&G.length)&&!((X=m==null?void 0:m.metadata)!=null&&X.source)||!a)return;const q=((O=((m==null?void 0:m.tags)||[])[0])==null?void 0:O.metadata)||(m==null?void 0:m.metadata);kf({filePath:`${eo}${q.source}`,fileName:ts({metadata:q}),token:e})}})]})]}),A.key==="knowledgeList"&&m.type==="faq"&&((P=m.metadata)==null?void 0:P.update_time)&&re("div",{style:{marginTop:"4px",display:"flex",alignItems:"center",justifyContent:"space-between",gap:"8px",fontSize:"12px",color:"#4E5969"},children:[N("span",{style:{flexShrink:0},children:Qg(m.metadata.update_time)}),((T=m==null?void 0:m.tags)==null?void 0:T.length)&&m.tags.length>0&&m.tags.length<=10&&N("span",{style:{display:"flex",alignItems:"center",flexShrink:0,gap:"2px"},children:(m.tags||[]).map(q=>N(Yi,{i:m,item:A,j:q,clickTag:w},q.id))})]}),(typeof m.score=="string"||typeof m.score=="number")&&!(m.type==="faq"||m.faq_question||m.faq_answer)&&N("div",{style:{display:"flex",alignItems:"center",height:"18px",marginTop:"4px"},children:re("div",{style:{backgroundColor:"#F2F2FB",borderRadius:"4px",padding:"2px 3px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px"},children:[N("span",{style:{color:"#4E5969",marginRight:"6px"},children:"\u5206\u6570:"}),N("span",{style:{color:"#1D2129"},children:v(m.score)})]})}),A.key==="knowledgeList"&&m.type==="faq"&&(typeof m.score=="string"||typeof m.score=="number")&&re("div",{style:{marginTop:"4px",fontSize:"12px",color:"#4E5969"},children:["\u5206\u6570: ",v(m.score)]}),N("div",{style:{flex:1,display:"flex",justifyContent:"flex-start",marginTop:"4px"},children:(($=m==null?void 0:m.tags)!=null&&$.length&&m.tags.length>10?m.tags:[]).map(q=>N(Yi,{i:m,item:A,j:q,clickTag:w},q.id))}),m.type==="faq"&&(m.faq_question||m.faq_answer)&&re("div",{style:{marginTop:"8px",padding:"8px 10px",background:"#EAF4FD",borderRadius:"4px",fontSize:"12px",color:"#1D2129",lineHeight:1.5},children:[m.faq_question!=null&&String(m.faq_question).trim()!==""&&re("div",{style:{marginBottom:"4px",display:"flex"},children:[N("span",{style:{color:"#4E5969",flexShrink:0},children:"Q: "}),N("span",{style:{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:2,WebkitBoxOrient:"vertical"},children:String(m.faq_question).trim()})]}),m.faq_answer!=null&&String(m.faq_answer).trim()!==""&&re("div",{style:{display:"flex"},children:[N("span",{style:{color:"#4E5969",flexShrink:0},children:"A: "}),N("span",{style:{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:2,WebkitBoxOrient:"vertical"},children:String(m.faq_answer).replace(/\s*--+[A-Za-z0-9]*\s*$/,"").trim()||String(m.faq_answer).trim()})]})]}),!!((H=m==null?void 0:m.main_source)!=null&&H.length)&&re("div",{style:{flex:1,display:"flex",alignItems:"flex-start",marginTop:"4px"},children:[N("div",{style:{fontSize:"12px",color:"#4E5969",width:"60px"},children:"\u5173\u8054\u6587\u6863:"}),N(On,{placement:"topLeft",title:((j=Bi(m.main_source[0]))==null?void 0:j.length)>22?Bi(m.main_source[0]):"",children:N("div",{style:{fontSize:"12px",color:"#4E5969",width:"289px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:Bi(m.main_source[0])})})]})]},m.id)})},A.key)})})]})]}),N(di,{drawer:{styles:{body:{padding:0},header:{display:"none"}}},children:re(Uc,{autoFocus:!1,onClose:()=>u(!1),open:c,width:g==="graphList"?"100%":720,className:"overflow-x-hidden",destroyOnClose:!0,afterOpenChange:A=>{A||d(null)},children:[s==="graphPreview"&&N(Kg,{curFileInfo:h,onClose:u,token:e}),s==="mark"&&N(Xg,{content:h,onClose:u,token:e}),s==="preview"&&N(Hl,{curFileInfo:h,onClose:u,token:e}),s==="database"&&N(Yg,{curFileInfo:h,onClose:u,token:e}),s==="faq"&&h&&re("div",{className:"p-4",style:{fontSize:"14px",color:"#1D2129",lineHeight:1.6},children:[h.faq_question!=null&&String(h.faq_question).trim()!==""&&re("div",{style:{marginBottom:"12px"},children:[N("span",{style:{color:"#4E5969",marginRight:"4px"},children:"Q:"}),N("span",{children:String(h.faq_question).trim()})]}),h.faq_answer!=null&&String(h.faq_answer).trim()!==""&&re("div",{children:[N("span",{style:{color:"#4E5969",marginRight:"4px"},children:"A:"}),N("span",{children:String(h.faq_answer).replace(/\s*--+[A-Za-z0-9]*\s*$/,"").trim()||String(h.faq_answer).trim()})]})]})]})})]})},em=({fileData:r,token:t})=>{const[e,n]=le([]);De(()=>{var l;const o=r==null?void 0:r.knowledgeBases;if(!(o!=null&&o.length))return;const s=((l=o[0])==null?void 0:l.treeData)||[];s!=null&&s.length&&n(s)},[r]);const a=Ve(new Map),i=async(o,s)=>{var l,c;if(!a.current.get(o==null?void 0:o.fetchUrl))try{const u=e[s];u.loading=!0;const h=[...e];n(h);const d=await Mt.get(`${Lf()}/${o.fetchUrl}`,{headers:{Authorization:t}}),g=(c=(l=d==null?void 0:d.data)==null?void 0:l.data)==null?void 0:c.records;if(g){const x=e[s];x.loading=!1,x.children=g;const p=[...e];p[s]=x,n(p),a.current.set(o==null?void 0:o.fetchUrl,!0)}else{const x=e[s];x.loading=!1;const p=[...e];n(p)}}catch{const h=e[s];h.loading=!1;const d=[...e];n(d)}};return re(Vn,{children:[N(Fi,{title:"\u77E5\u8BC6\u5E93\u6587\u6863\u76EE\u5F55",setOpen:()=>{const o=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(o)}}),N("div",{style:{height:"calc(100% - 60px)",overflowY:"auto",padding:"16px"},children:e.map((o,s)=>{var l;return o.type==="file"?re("div",{className:"flex",style:{marginTop:"8px"},children:[Yc(o),N(On,{placement:"top",title:((l=o.name)==null?void 0:l.length)>23?o.name:"",children:N("div",{style:{paddingLeft:"6px",width:"346px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",cursor:"default",fontSize:"14px"},children:o.name})})]}):N(tm,{item:o,index:s,clickFileItem:i},s)})})]})},tm=({item:r,index:t,clickFileItem:e})=>{var i;const[n,a]=le(!1);return re("div",{style:{marginTop:"8px"},children:[re("div",{className:"flex cursor-pointer",onClick:()=>{a(!n),!n&&e(r,t)},children:[Yc(r),N(On,{placement:"top",title:((i=r.name)==null?void 0:i.length)>23?r.name:"",children:re("div",{style:{paddingLeft:"6px",width:"346px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"14px"},children:[r.name," (",r.fileCount||0,")"]})})]},t),N("div",{style:{padding:"2px 0 2px 14px",margin:"8px 0 0 7px",borderLeft:"2px solid #E5E6EB",display:n?"block":"none"},children:(r.children||[]).map((o,s)=>{var l;return re("div",{className:"flex items-center",children:[N("div",{style:{width:"4px",height:"4px",borderRadius:"2px",background:"black"}}),N(On,{placement:"top",title:((l=o.name)==null?void 0:l.length)>26?o.name:"",children:N("div",{style:{paddingLeft:"6px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"12px",width:"336px"},children:o.fileName})})]},s)})})]})};var ql=(r=>(r.REFERENCELIST="referencelist",r.ALLFILELIST="allFileList",r))(ql||{});function Gy(r=cf){return function({token:e,url:n="http://localhost:8888",styles:a,CSRFToken:i,eventsEmit:o,scrollOld:s,locale:l="zh",messages:c,...u}){const h=mf(),d=Ke(()=>{const D=_s({theme:Jo,mode:"light"},h||{});return _s(D,a||{})},[h,a]),[g,x]=le(!1),[p,f]=le(!1),[y,v]=le(null),[C,b]=le(!1),[F,E]=le("mark"),[w,A]=le({url:"",parse_url:"",file_type:"",file_name:""}),[S,m]=le([]),[B,_]=le(1),[P]=le(16),[T,$]=le(0),[H,j]=le(!1),[q,G]=le([]),[X,O]=le(void 0),[M,R]=le([]),[I,U]=le([]),[K,Z]=le(void 0),[Q,J]=le({display:"ready",sender:"ready",app:"initializing"});function pe(k,D){if(!D)return k;const V=Array.isArray(k)?[...k]:{...k};for(const W in D)if(D[W]!==void 0&&D[W]!==null&&Object.prototype.hasOwnProperty.call(D,W))if(W==="actions"&&Array.isArray(k[W])&&Array.isArray(D[W])){const te=new Map;k[W].forEach(ne=>{ne.name&&te.set(ne.name,ne)}),D[W].forEach(ne=>{ne.name&&te.set(ne.name,ne)}),V[W]=Array.from(te.values())}else typeof k[W]=="object"&&k[W]!==null&&!Array.isArray(k[W])&&typeof D[W]=="object"&&D[W]!==null&&!Array.isArray(D[W])?V[W]=pe(k[W],D[W]):V[W]=D[W];return V}const Ie=Ke(()=>Jc(l),[l]),Se=Ke(()=>{const k=Ie;return{...en,placeholder:k.sender.placeholder,switchs:(en.switchs??[]).map(V=>({...V,label:V.name==="netSearch"?k.sender.netSearch:k.sender.deepThinking})),actions:(en.actions??[]).map(V=>({...V,tip:V.name==="upload"?k.sender.fileUpload:V.tip}))}},[l,Ie]),[ie,Ae]=le(()=>pe(Se,u.senderConfig));De(()=>{const k=Ie,D={...en,placeholder:k.sender.placeholder,switchs:(en.switchs??[]).map(V=>({...V,label:V.name==="netSearch"?k.sender.netSearch:k.sender.deepThinking})),actions:(en.actions??[]).map(V=>({...V,tip:V.name==="upload"?k.sender.fileUpload:V.tip}))};Ae(V=>{const W=pe(D,u.senderConfig);return Array.isArray(V.actions)&&Array.isArray(W.actions)&&(W.actions=W.actions.map((te,ne)=>{var oe;const ue=(oe=V.actions)==null?void 0:oe[ne];return ue&&ue.name===te.name&&ue.badgeCount!==void 0?{...te,badgeCount:ue.badgeCount}:te})),W})},[l,u.senderConfig,Ie]);const{fileStatuses:Ne,setFileStatuses:he,pollFileStatus:it,handleRemoveFromTemp:et,resetStopFlag:tt,setStopFlag:st,stoppedRef:Fe,getTempFileList:ye,setFileManagerData:ke,fileManagerData:Me}=$1({url:n,token:e,CSRFToken:i,activeSessionId:X}),[ze,ee]=ve.useState(()=>{var D;if(!I||I.length===0)return;const k=I.find(V=>V.isDefault);return k?k.id:(D=I[0])==null?void 0:D.id});ve.useEffect(()=>{if(!I||I.length===0)return;const k=I.some(D=>D.id===ze);if(!ze||!k){const D=I.find(V=>V.isDefault);ee(D?D.id:I[0].id)}},[I]);const[Ce,ot]=le({}),Dt=Ve(void 0),kt=Ve(void 0),Lt=Ve(void 0),Re=Ve(null),$t=Ve(void 0),fr=Ve([]),[Br,Pt]=le([]),[br,dr]=le({}),[$r,pr]=le(!1),[zr,_r]=le([]),[Hr,zt]=le(!1),{api_startChat_re:Et,addEmptyMessage:It,setLastEmptyMessage:Ht,stopStream:er,cancelStreamBySessionId:Gt}=N1({baseUrl:n,CSRFToken:i,token:e,setChatData:G,activeSessionId:X,setAppStatus:J,setConversationList:m}),Qe=Ke(()=>{const k={};return(I||[]).forEach(D=>{k[D.id]=D}),k},[I]),se=Ke(()=>{const k=q.find(V=>V.id===X)||{id:X,messages:[]},D=k.configId?Qe[k.configId]:null;return{...k,assistantInfo:D}},[q,X,Qe]);De(()=>{console.log("currentChatData",se)},[se]);const rt=Ke(()=>{if(se.configId&&Qe){const k=Qe[se.configId];return k!=null&&k.configJson?JSON.parse(k.configJson).is_download:!1}else return!1},[se.configId,Qe]);Ke(()=>{if((se.configId||K)&&Qe){const k=Qe[se.configId];if(k!=null&&k.configJson){const D=JSON.parse(k.configJson);return console.log("is_enableThinking",se.configId,Qe,K),!!D.thinking}else if(K){const D=Qe[K];if(D!=null&&D.configJson)return!!JSON.parse(D.configJson).thinking}}return!1},[se.configId,Qe,K]),De(()=>{if(Dt.current&&Dt.current!==X){const D=Dt.current,V=S.find(ne=>ne.sessionId===D&&ne.isNew),W=q.find(ne=>ne.id===D&&ne.isNew),te=W&&W.messages&&W.messages.length>0;V&&!te&&(m(ne=>ne.filter(ue=>ue.sessionId!==D)),G(ne=>ne.filter(ue=>ue.id!==D)))}Dt.current=X;const k=se.messages&&se.messages.length>0?se.messages[se.messages.length-1].recommendQuestion:[];R(k)},[X,S,q,se.messages]);const At=async k=>{var D,V,W,te;if(!H){j(!0);try{const ne=await Mt.get(`${n}/qa/dialogue/list?pageNo=${k}&pageSize=${P}&sysType=INT_SESSION`,{headers:{Authorization:e}}),ue=((V=(D=ne==null?void 0:ne.data)==null?void 0:D.data)==null?void 0:V.records)||[],oe=((te=(W=ne==null?void 0:ne.data)==null?void 0:W.data)==null?void 0:te.total)||0;$(oe),m(Xe=>{const Ue=new Map;return[...Xe,...ue].forEach(ut=>{Ue.set(ut.sessionId,ut)}),Array.from(Ue.values())}),_(k)}catch{}finally{j(!1)}}};De(()=>{J(k=>({...k,app:"initializing"})),Mt.get(`${n}/qa/search/config/helper/list?pageNo=1&pageSize=3000`,{headers:{Authorization:e}}).then(k=>{U(k.data.data||[])}).catch(()=>{}),At(1).then(()=>{X||qt(),J(k=>({...k,app:"ready"}))}).catch(()=>{J(k=>({...k,app:"error"}))})},[]),De(()=>{X&&(J(k=>({...k,display:"loading"})),ye(X),Mt.get(`${n}/qa/dialogue/getDialogBySessionId?sessionId=${X}`,{headers:{Authorization:e}}).then(k=>{var wt;if(!k.data.data){J(ae=>({...ae,display:"ready"}));return}const D=((wt=k.data.data)==null?void 0:wt.queryReplyPairList)||[],V=D1(D),{sessionId:W,searchConfigDTO:te,filePath:ne,configId:ue,reference:oe,webReference:Xe,uploadedFiles:Ue,fileList:ut,currentFiles:ct}=k.data.data;if(V.length>0){const ae=V.length-1-[...V].reverse().findIndex(Te=>Te.istype==="ai");ae>=0&&ae<V.length&&V[ae].istype==="ai"&&(oe&&(V[ae].reference=oe),Xe&&(V[ae].webReference=Xe))}const Pe=ct||ut||Ue;if(Pe&&V.length>0){const ae=[...V].reverse().findIndex(Te=>Te.istype==="user");ae!==-1&&(console.log(V[V.length-1-ae].currentFiles,"filesData"),V[V.length-1-ae].currentFiles=Pe)}S.find(ae=>ae.sessionId===W)&&m(ae=>ae.map(Te=>Te.sessionId===W?{...Te,searchConfigDTO:te,filePath:ne,configId:ue}:Te));const xe={configId:k.data.data.configId,filePath:k.data.data.filePath,searchConfigDTO:k.data.data.searchConfigDTO||{},sessionId:k.data.data.sessionId,label:k.data.data.label,kbId:k.data.data.kbId};G(ae=>{const Te=ae.filter(Ye=>Ye.id!==X);return[{id:X,messages:V,...xe},...Te]}),J(ae=>({...ae,display:"ready"}))}).catch(k=>{console.error("\u83B7\u53D6\u804A\u5929\u6570\u636E\u5931\u8D25:",k),k.response&&k.response.status===404&&qt(),J(D=>({...D,display:"error"}))}))},[X,n,e]),De(()=>{const k=Me.uploadedFiles.length;Ae(D=>{const V=Array.isArray(D.actions)?D.actions:[];return{...D,actions:V.map(te=>te.name==="history"?{...te,badgeCount:k}:te)}})},[Me.uploadedFiles]),De(()=>{$f({url:n,token:e},k=>{_r(k)})},[]),ve.useEffect(()=>{Ne.length&&G(k=>{if(!k[0])return k;const{messages:D}=k[0];for(let V=D.length-1;V>=0;V--)if(D[V].istype==="user"){const W=D[V].currentFiles||[];D[V].currentFiles=Ne.map(te=>{var ue,oe,Xe;const ne=W.find(Ue=>Ue.uid===te.uid);return{name:((ue=te.file)==null?void 0:ue.name)||te.name,size:((oe=te.file)==null?void 0:oe.size)||te.size,type:((Xe=te.file)==null?void 0:Xe.type)||te.type,status:te.status,uid:te.uid,url:te.url||(ne==null?void 0:ne.url)||""}});break}return[...k]})},[Ne]);let be=null,nt=null;const tr=(k,D,V,W)=>{nt=it(k,{onStatusUpdate:D,onComplete:V,onFail:W})},Oe=(k,D)=>{G(V=>{const W=[...V];return W[0]&&(W[0]={...W[0],messages:W[0].messages.map(te=>te.queryId===k?{...te,feedbackResult:D}:te)}),W})},He=async k=>{var D,V;if(k)try{const W=(se==null?void 0:se.configId)||((D=Qe==null?void 0:Qe[(se==null?void 0:se.configId)||""])==null?void 0:D.id)||"",te=await Mt.get(`${n}/qa/ai/recommendQuestion?queryId=${k}&configId=${W||""}`.replace(/\?&/,"?"),{headers:{Authorization:e}});R(((V=te.data)==null?void 0:V.data)||[])}catch{R([])}};function dt(k){const{content:D,audioUrl:V,filePaths:W,queryId:te}=k;if(!X||!te)return;const ne=(se==null?void 0:se.messages)||[],ue=ne.findIndex(de=>(de==null?void 0:de.queryId)===te&&((de==null?void 0:de.istype)==="ai"||(de==null?void 0:de.isUser)===!1));let oe;if(ue>0)for(let de=ue-1;de>=0;de-=1){const xe=ne[de];if((xe==null?void 0:xe.istype)==="user"||(xe==null?void 0:xe.isUser)===!0){oe=xe;break}}const Xe=(oe==null?void 0:oe.content)??D;if(!Xe)return;const Ue=(oe==null?void 0:oe.filePaths)??W,ut=(typeof Ue=="string"&&Ue?JSON.parse(Ue):Ue||[]).map(de=>de.uid),ct=Date.now();Ht({now:ct}),J(de=>({...de,display:"processing",sender:"processing"}));const Pe="query-"+yr(32);ue>=0&&ne[ue]&&G(de=>{if(!de[0])return de;const xe=de[0],wt=xe.messages||[];if(ue>=wt.length)return de;const ae=wt.slice();return ae[ue]={...ae[ue],queryId:Pe,content:ae[ue].content,reference:"[]",webReference:"[]",graphReference:null,databaseReference:null,status:2,chain:void 0},[{...xe,messages:ae},...de.slice(1)]}),k.clearFn&&k.clearFn(),m(de=>de.map(xe=>xe.sessionId===X?{...xe,gmtModified:ct}:xe)),Et({configId:se.configId,content:Xe,fileUids:ut,lastDate:ct,name:se.label||"",queryId:Pe,sessionId:String(X||""),type:(oe==null?void 0:oe.audioUrl)??V?"audioUrl":"text",audioUrl:((oe==null?void 0:oe.audioUrl)??V)||"",enableThinking:!!Ce.reasoning,enableWebsearch:!!Ce.netSearch,qaChannel:Ce.qaChannel,tempKnowledgeBaseCheck:Zn.current},de=>{He(Pe)})}async function vt(k,D){if(Q.sender!=="ready"){St.warning("\u5F53\u524D\u5BF9\u8BDD\u6B63\u5728\u5904\u7406\u4E2D\uFF0C\u8BF7\u7A0D\u5019\u518D\u53D1\u9001\u65B0\u7684\u95EE\u9898");return}if(!X)return;const V=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(V);const W=S.find(te=>te.sessionId===X);if(W&&W.isNew){let te=!1;const ne=K||W.configId,ue=k&&k.content?k.content.slice(0,20):W.label||"\u672A\u547D\u540D\u4F1A\u8BDD";if(await new Promise((oe,Xe)=>{qf({url:n,token:e,CSRFToken:i},{label:ue,sessionId:W.sessionId,sysType:"INT_SESSION",configId:ne},Ue=>{Ue&&Ue.data&&Ue.data.sessionId?(m(ut=>ut.map(ct=>ct.sessionId===W.sessionId?{...ct,isNew:!1,configId:ne,label:ue}:ct)),G(ut=>ut.map(ct=>ct.id===W.sessionId?{...ct,isNew:!1,configId:ne,label:ue}:ct)),te=!0,oe()):(St.error("\u521B\u5EFA\u4F1A\u8BDD\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5"),Xe())})}),!te)return;rr(X,k,D,ne);return}rr(X,k,D)}function rr(k,D,V,W){const te="query-"+yr(32),ne=S.find(Pe=>Pe.sessionId===k),ue=W||(ne==null?void 0:ne.configId)||se.configId;console.log("\u52A9\u624B\u914D\u7F6E\u8BE6\u60C5",ue);const oe=D.content||D.text||"",Xe=typeof oe=="string"?oe:String(oe),Ue=Xe?Xe.slice(0,20):"\u672A\u547D\u540D\u4F1A\u8BDD";let ut;if(D.files&&D.files.length>0&&(ut=D.files.map(Pe=>({name:Pe.file.name,size:Pe.file.size,type:Pe.file.type,filePath:Pe.filePath||"",convertedFilePath:Pe.convertedFilePath||"",uid:Pe.uid||""}))),console.log("\u672C\u5730\u6587\u4EF6\u4E0A\u4F20",D.files),It({content:Xe,queryId:te,currentFiles:ut,filePaths:ut?JSON.stringify(ut):void 0}),m(Pe=>Pe.map(de=>de.sessionId===k&&de.label==="\u672A\u547D\u540D\u4F1A\u8BDD"&&de.isNew?{...de,label:Ue,gmtModified:Date.now(),isNew:!1}:de)),G(Pe=>Pe.map(de=>de.id===k&&de.label==="\u672A\u547D\u540D\u4F1A\u8BDD"&&de.isNew?{...de,label:Ue,isNew:!1}:de)),D.files&&D.files.length>0){J(ae=>({...ae,sender:"uploading",display:"uploading"})),be=new AbortController,tt();const Pe=D.files.map(()=>`rc-upload-${Date.now()}-${Math.random().toString(36).slice(2)}`),de=D.files.map((ae,Te)=>({...ae,uid:Pe[Te],status:"uploading"}));he(de);const xe=new FormData;D.files.forEach(ae=>{xe.append("files",ae.file)});const wt=String(k||"");xe.append("sessionId",wt),xe.append("uids",Pe.join(",")),Mt.post(`${n}/index/knowledgeBase/file/uploadFiles`,xe,{headers:{Authorization:e,"Content-Type":"multipart/form-data"},signal:be.signal}).then(ae=>{var Ze,me,pt,xt,Fr,nr,mt,Pr,yt,Ir;if(console.log("\u6587\u4EF6\u4E0A\u4F20\u7684\u6253\u5370\u7ED3\u679C",ae),console.log("\u6587\u4EF6\u4E0A\u4F20\u54CD\u5E94\u8BE6\u60C5:",{status:ae.status,success:(Ze=ae.data)==null?void 0:Ze.success,dataType:Array.isArray((me=ae.data)==null?void 0:me.data)?"array":typeof((pt=ae.data)==null?void 0:pt.data),dataLength:Array.isArray((xt=ae.data)==null?void 0:xt.data)?ae.data.data.length:"N/A",errorMsg:(Fr=ae.data)==null?void 0:Fr.errorMsg,errorCode:(nr=ae.data)==null?void 0:nr.errorCode,fullResponse:ae.data}),Fe.current)return;const Te=(mt=ae.data)==null?void 0:mt.data,Ee=((Pr=ae.data)==null?void 0:Pr.success)===!0,Ye=Array.isArray(Te)&&Te.length>0;if(Ee&&Ye){const Tt=Te,Tr=Tt.map(at=>at.uid);he(at=>at.map(Je=>{const We=Te.find($e=>$e.uid===Je.uid);return We?{...Je,...We}:Je})),J(at=>({...at,sender:"processing",display:"analyzing"})),he(at=>at.map(Je=>({...Je,status:"parsing"}))),tr(Tr,at=>{if(!at||!Array.isArray(at)){console.warn("pollFileStatus \u56DE\u8C03\u8FD4\u56DE\u7684 serverStatuses \u65E0\u6548:",at);return}if(he(We=>We.map($e=>{const Ge=at.find(Kt=>Kt&&Kt.uid===$e.uid);if(Ge)switch(Ge.fileParseStatus??Ge.status){case 3:return{...$e,status:"done"};case 4:return{...$e,status:"error"};case 1:case 2:default:return{...$e,status:"parsing"}}return $e})),Array.isArray(at)&&at.length>0&&at.every(We=>{if(!We)return!1;const $e=We.fileParseStatus??We.status;return $e===3||$e===4})){he([]);const We=new Map;(at||[]).forEach($e=>{We.set($e.id,$e)}),ke($e=>({uploadedFiles:Wf($e.uploadedFiles,Tt).map(Kt=>{var _n;return{...Kt,pdfPages:((_n=We.get(Kt.id))==null?void 0:_n.pdfPages)||0}})}))}},()=>{V==null||V(),J(Je=>({...Je,sender:"processing",display:"processing"})),he(Je=>Je.map(We=>{const $e=Tt.find(Ge=>Ge.uid===We.uid);return $e?{...We,...$e,url:$e.filePath,filePath:$e.filePath,name:$e.fileName||We.name,convertedFilePath:$e.convertedFilePath||We.convertedFilePath}:We})),G(Je=>{if(!Je[0])return Je;const{messages:We}=Je[0];for(let $e=We.length-1;$e>=0;$e--)if(We[$e].istype==="user"){const Ge=We[$e].currentFiles||[];We[$e].currentFiles=Ge.map(Kt=>{const _n=Tt.find(Jl=>Jl.uid===Kt.uid);return _n?{...Kt,..._n}:Kt});break}return[...Je]});const at=Date.now();Et({configId:ue,content:Xe,fileUids:Tr,lastDate:at,name:Ue,queryId:te,sessionId:String(k||""),type:"text",audioUrl:"",enableThinking:!!Ce.reasoning,enableWebsearch:!!Ce.netSearch,qaChannel:Ce.qaChannel,tempKnowledgeBaseCheck:Zn.current},Je=>{He(te)})},at=>{J(Je=>({...Je,display:"ready",sender:"ready"})),he(Je=>Je.map(We=>({...We,status:"error",message:at})))})}else{let Tt="\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25";(yt=ae.data)!=null&&yt.errorMsg?Tt=ae.data.errorMsg:Ee?Ye||(Array.isArray(Te)?Te.length===0&&(Tt="\u4E0A\u4F20\u5931\u8D25: \u8FD4\u56DE\u6570\u636E\u4E3A\u7A7A"):Tt=`\u4E0A\u4F20\u5931\u8D25: \u8FD4\u56DE\u6570\u636E\u683C\u5F0F\u9519\u8BEF\uFF0C\u671F\u671B\u6570\u7EC4\uFF0C\u5B9E\u9645\u4E3A ${typeof Te}`):Tt=`\u4E0A\u4F20\u5931\u8D25: success=${(Ir=ae.data)==null?void 0:Ir.success}`,console.error("\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25\u8BE6\u60C5:",{errorMsg:Tt,response:ae.data,isSuccess:Ee,isValidData:Ye}),St.error(Tt),J(Tr=>({...Tr,display:"error",sender:"ready"})),he(Tr=>Tr.map(at=>({...at,status:"error",message:Tt})))}}).catch(ae=>{var Te,Ee;((Te=ae==null?void 0:ae.response)==null?void 0:Te.status)===413?(Ee=ae==null?void 0:ae.response)!=null&&Ee.statusText.includes("Request Entity Too Large")&&St.error("\u6587\u4EF6\u8D85\u8FC7\u6700\u5927\u53EF\u4E0A\u4F20\u9650\u5236"):St.error("\u7F51\u7EDC\u9519\u8BEF"),J(Ye=>({...Ye,display:"error",sender:"ready"})),he(Ye=>Ye.map(Ze=>({...Ze,status:"error",message:"\u7F51\u7EDC\u9519\u8BEF"})))});return}J(Pe=>({...Pe,display:"processing",sender:"processing"}));const ct=Date.now();m(Pe=>Pe.map(de=>de.sessionId===k?{...de,gmtModified:ct}:de)),V==null||V(),Et({configId:ue,content:Xe,fileUids:[],lastDate:ct,name:Ue,queryId:te,sessionId:String(k||""),type:"text",audioUrl:"",enableThinking:!!Ce.reasoning,enableWebsearch:!!Ce.netSearch,qaChannel:Ce.qaChannel,tempKnowledgeBaseCheck:Zn.current},Pe=>{He(te)})}function Yr(k){k.restult==1?_i({url:n,token:e,CSRFToken:i},{queryId:k.queryId},()=>{Oe(k.queryId,null)}):Ps({url:n,token:e,CSRFToken:i},{restult:1,queryId:k.queryId},()=>{Oe(k.queryId,1)})}function qt(k){const D=yr(32),V={sessionId:D,label:"\u672A\u547D\u540D\u4F1A\u8BDD",gmtModified:Date.now(),searchConfigDTO:{},filePath:"",configId:"",isNew:!0};m(W=>[{...V,messages:[]},...W]),G(W=>[{id:D,messages:[],...V},...W]),O(D)}function hr(k){if(k!=null&&k.sessionId&&k.sessionId!==X){X&&Gt(X),O(k.sessionId),J(V=>({...V,sender:"ready"}));const D=q.find(V=>V.id===k.sessionId);if(D&&D.messages&&D.messages.length>0){const V=[...D.messages].reverse().find(W=>W.istype==="ai");V&&V.recommendQuestion?R(V.recommendQuestion):R([])}else R([])}}const Qr=async k=>new Promise((D,V)=>{jf({url:n,token:e,CSRFToken:i},{sessionId:k},W=>{W?(St.success("\u5220\u9664\u6210\u529F!"),D(W)):(St.error("\u5220\u9664\u5931\u8D25!"),V(W))})}),Zr=async()=>{try{return m([]),$(0),await At(1),[]}catch(k){throw St.error("\u5237\u65B0\u4F1A\u8BDD\u5217\u8868\u5931\u8D25"),k}},Jr=async(k,D)=>new Promise((V,W)=>{Vf({url:n,token:e,CSRFToken:i},{label:D,sessionId:k},te=>{if(te){const ne=Date.now();m(ue=>ue.map(oe=>oe.sessionId===k?{...oe,label:D,gmtModified:ne}:oe)),G(ue=>ue.map(oe=>oe.id===k?{...oe,label:D}:oe)),St.success("\u91CD\u547D\u540D\u6210\u529F!"),V(te)}else St.error("\u91CD\u547D\u540D\u5931\u8D25"),W(te)})}),Nt=k=>{m(D=>{const V=D.filter(W=>W.sessionId!==k);return X===k&&(V.length>0?O(V[0].sessionId):qt()),V})},Yn=(k,D)=>{const V=Date.now();m(W=>W.map(te=>te.sessionId===k?{...te,label:D,gmtModified:V}:te)),G(W=>W.map(te=>te.id===k?{...te,label:D}:te))},Qn=k=>{Ps({url:n,token:e,CSRFToken:i},{...k,...br,restult:0},()=>{Oe(br.queryId,0)})},Ai=k=>{const D=k.new_name,V=y.data.label;D&&D!==V?y.async_renameConversation(D).then(()=>{y.fn_renameItemInList(D),x(!1)}).catch(()=>{}):x(!1)},vr=k=>{y.async_deleteConversation().then(()=>{y.fn_removeItemFromList(),f(!1)}).catch(()=>{})},Dr=(k,D)=>{switch(console.log(k,D),k){case"close_remove":f(!1);break;case"close_rename":x(!1);break;case"ok_rename":Ai(D);break;case"ok_remove":vr();break}},Gl=async({url:k,params:D,replacePredataFunction:V})=>{var W,te;try{const ne=await Mt.post(k,D,{headers:{Authorization:e}}),ue=(te=(W=ne==null?void 0:ne.data)==null?void 0:W.data)==null?void 0:te.data;ue&&V(ue)}catch(ne){console.log("error",ne)}},Kl=async k=>{var D;try{const V=await Mt.get(`${Ji()}/index/knowledgeBase/file/getFileStatusByUids?uids=${k.data.uids}`,{headers:{Authorization:e}});return console.log("resslkdjgalsg",V),(D=V==null?void 0:V.data)==null?void 0:D.data}catch{}},As=async k=>{var D;if(Uf.includes(k.file_type)){const V=(D=k.metadata)!=null&&D.source?`${eo}${k.metadata.source}`:k.url||k.convertedFilePath||k.filePath;A({...k,parse_url:V}),E("preview"),b(!0);return}try{const V=await Kl({data:{uids:k.uid},config:{url:Ji(),token:e,enableMock:!1}});if(V!=null&&V.length){const W=V[0];A({...k,parse_url:W.convertedFilePath}),E("preview"),b(!0)}}catch{}},Zn=Ve(!1),kr=(k,D)=>{var V,W,te,ne,ue,oe,Xe,Ue,ut,ct,Pe;switch(console.log(`[Event] ${k}`,D),k){case"TempKnowledgeBase":Zn.current=D;break;case"reference_file:click":if(D.file_type==="image")return;if(!D.parse_url){if(!D.uid)return D.references?void 0:St.warning("\u6587\u4EF6\u8FD8\u672A\u89E3\u6790\u5B8C\u6210,\u8BF7\u7A0D\u540E\u9884\u89C8");As(D);return}A({...D,file_type:D.type,file_name:D.file}),E("preview"),b(!0);break;case"conversations:load_more":{S.length<T&&!H&&At(B+1);break}case"retrieve-sql-data:pagingation_click":const{page:de,pageSize:xe,fetchUrl:wt,source:ae,replacePredataFunction:Te}=D;Gl({url:`${n}${wt}`,replacePredataFunction:Te,params:{pageNo:de,pageSize:xe,convertedFilePath:ae,stream:!1}});break;case"web_referenceFile_title:click":if(!((V=D==null?void 0:D.data)!=null&&V.link))return console.error("\u6CA1\u6709\u7F51\u9875\u5730\u5740");window.open(D.data.link,"_blank");break;case"conversation:item_click":hr(D);break;case"files:finished_animation_complete":he([]);break;case"conversation:create":qt();break;case"conversation:new_assistant_change":Z(D.assistantId);break;case"conversations:rename_icon_clicked":v({data:D,async_renameConversation:Ee=>Jr(D.sessionId,Ee),fn_renameItemInList:Ee=>Yn(D.sessionId,Ee)}),x(!0);break;case"conversations:delete_icon_clicked":v({data:D,async_deleteConversation:()=>Qr(D.sessionId),async_refreshConversationList:Zr,fn_removeItemFromList:()=>Nt(D.sessionId)}),f(!0);break;case"sender:send":vt(D,D.clearFn);break;case"sender:send_recommandQuestion":{const Ee=((D==null?void 0:D.content)??"").toString();if(!Ee)break;vt({content:Ee},()=>{});break}case"chatbox:follow_up_question_click":{const Ee=((D==null?void 0:D.question)??(D==null?void 0:D.content)??"").toString();if(!Ee)break;vt({content:Ee},()=>{});break}case"sender:stop":st(),be&&(be.abort(),be=null),nt&&(nt(),nt=null),J(Ee=>({...Ee,display:"ready",sender:"ready"})),he([]),er==null||er();break;case"sender:clear":(W=D.clearFn)==null||W.call(D);break;case"sender:configChange":D&&D.all&&ot(D.all);break;case"sender:action_upload":Re.current&&Re.current.click();break;case"sender:action_history":zt(!0);break;case"uploaded_file:item_click":break;case"action_copy:click":D&&_1(D.content,D.event);break;case"chatbox:copy":{let Ee=(D==null?void 0:D.content)||"";if(!Ee)break;Ee=Ee.replace(/\[retrive-tag[^\]]*\][\s\S]*?\[\/retrive-tag\]/g,"");const Ye=async me=>{try{return await navigator.clipboard.writeText(me),St.success("\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F"),!0}catch{return!1}},Ze=me=>{const pt=document.createElement("textarea");pt.value=me,pt.style.position="fixed",pt.style.opacity="0",document.body.appendChild(pt),pt.focus(),pt.select();try{document.execCommand("copy"),St.success("\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F")}catch{St.error("\u590D\u5236\u5931\u8D25")}document.body.removeChild(pt)};Ye(Ee).then(me=>{me||Ze(Ee)});break}case"chatbox:repeat":console.log(D,"sdkflskdjflksdjfklsdjlfkjsdklfjsdklfjlks"),dt(D);break;case"action_thumbsup":Yr(D);break;case"chatbox:like":Yr({queryId:D==null?void 0:D.queryId,restult:D==null?void 0:D.result});break;case"action_thumbsdown":D.restult===0?_i({url:n,token:e,CSRFToken:i},{queryId:D.queryId},()=>{Oe(D.queryId,null)}):(dr(D),pr(!0));break;case"chatbox:dislike":(D==null?void 0:D.result)===0?_i({url:n,token:e,CSRFToken:i},{queryId:D.queryId},()=>{Oe(D.queryId,null)}):(dr({queryId:D==null?void 0:D.queryId}),pr(!0));break;case"action_retrive_tag":o==null||o("action_retrive_tag",D);break;case"referenceFile_view":o==null||o("referenceFile_view",D);break;case"referenceFile_question":console.log(D,"zhezhhzhzh"),As(D.data||D),o==null||o("referenceFile_question",D);break;case"referenceFile_download":o==null||o("referenceFile_download",D);break;case"references:click":case"knowledge_base_view_all:click":{const Ee=()=>k==="references:click"?N(oc,{type:"referencelist",data:D,token:e,eventsEmit:o,is_download:rt}):N(em,{fileData:D,token:e}),Ye=new CustomEvent("aichat:right_set_content",{detail:{content:N(Ee,{})}});window.dispatchEvent(Ye);const Ze=new CustomEvent("aichat:right_set",{detail:{collapsed:!1}});window.dispatchEvent(Ze);break}case"retrive_tag:click":{let Ee=(D==null?void 0:D.referencesPayloadSingle)||((D==null?void 0:D.fromtype)==="10"&&(D!=null&&D.referenceDoc)?{knowledgeRefs:[D.referenceDoc],webRefs:[],graphRefs:[],databaseRefs:[],images:[],raw:{}}:null);if((D==null?void 0:D.fromtype)==="10"&&!Ee&&((te=D==null?void 0:D.leaf)==null?void 0:te.id)!=null&&((ne=se==null?void 0:se.messages)!=null&&ne.length)){const Ye=se.messages;for(let Ze=Ye.length-1;Ze>=0;Ze--){const me=Ye[Ze];if((me==null?void 0:me.istype)!=="ai")continue;const pt=(me==null?void 0:me.faqReference)??((ue=me==null?void 0:me.reply)==null?void 0:ue.faqReference)??(me==null?void 0:me.reference);if(!pt)continue;let xt=[];try{const Ge=typeof pt=="string"?(()=>{const Kt=pt.replace(/"pk":\s*(\d+)/g,'"pk":"$1"').replace(/"order_num":\s*(\d+)/g,'"order_num":"$1"').replace(/"related_pk":\s*(\d+)/g,'"related_pk":"$1"');return JSON.parse(Kt)})():pt;xt=Array.isArray(Ge)?Ge:[Ge]}catch{continue}if(xt.length===0)continue;const Fr=String(D.leaf.id);let nr=xt.findIndex(Ge=>String((Ge==null?void 0:Ge.pk)??(Ge==null?void 0:Ge.order_num)??(Ge==null?void 0:Ge.id))===Fr);if(nr<0){const Ge=Number(Fr);Number.isInteger(Ge)&&Ge>=1&&Ge<=xt.length&&(nr=Ge-1)}if(nr<0)continue;const mt=xt[nr],Pr=nr+1,yt=mt.metadata||{},Ir=mt.faq_question||yt.sourceFileName||yt.source&&String(yt.source).split("/").pop()||"FAQ",Tt=mt.folder_path||yt.folder_path||yt.knowledge_base_name||"",Tr=Tt?`${Tt} - ${Ir}`:Ir,at=`\u77E5\u8BC6\u5E93${Pr}\u540D\uFF1A${Tr}`,Je=String(mt.pk??mt.order_num??mt.id??""),We=typeof mt.score=="number"?mt.score:typeof yt.score=="number"?yt.score:0;Ee={knowledgeRefs:[{id:Je,file_id:Je,file_name:at,file_type:"faq",type:"faq",path:"",score:We,rrf_score:We,tags:[{id:Fr,index:Pr,image_urls:((oe=D==null?void 0:D.tagInfo)==null?void 0:oe.image_urls)||[],metadata:yt}],source:mt.folder_path||"",order_num:Je,pk:Je,faq_question:mt.faq_question,faq_answer:mt.faq_answer,folder_path:mt.folder_path,metadata:yt,faqIndex:Pr,...mt}],webRefs:[],graphRefs:[],databaseRefs:[],images:[],raw:{}};break}}if((D==null?void 0:D.fromtype)==="10"&&Ee){const Ye=new CustomEvent("aichat:right_set_content",{detail:{content:N(oc,{type:"referencelist",data:Ee,token:e,eventsEmit:o,is_download:rt})}});window.dispatchEvent(Ye);const Ze=new CustomEvent("aichat:right_set",{detail:{collapsed:!1}});window.dispatchEvent(Ze)}o==null||o("retrive_tag:click",D);break}case"fileManager:change":{typeof(D==null?void 0:D.setUploadedFiles)=="function"&&(kt.current=D.setUploadedFiles,Lt.current=D.removeFile,$t.current=D==null?void 0:D.senderConfig,fr.current=Array.isArray(D==null?void 0:D.uploadedFiles)?D.uploadedFiles:[],Array.isArray(D==null?void 0:D.uploadedFiles)&&Pt(D.uploadedFiles),console.log("[DEBUG] fileManager:change \u4E8B\u4EF6\u89E6\u53D1\uFF0CsetUploadedFilesRef \u5DF2\u8BBE\u7F6E",{hasSetUploadedFiles:!!kt.current,uploadedFilesCount:((Xe=D==null?void 0:D.uploadedFiles)==null?void 0:Xe.length)||0,pendingFilesCount:((Ue=D==null?void 0:D.uploadedFiles)==null?void 0:Ue.length)||0,hasSenderConfig:!!(D!=null&&D.senderConfig),senderConfig:D==null?void 0:D.senderConfig,upload_number_limit:(ut=D==null?void 0:D.senderConfig)==null?void 0:ut.upload_number_limit,upload_size_limit:(ct=D==null?void 0:D.senderConfig)==null?void 0:ct.upload_size_limit}));break}case"uploaded_file:removeFromTemp":{console.log("[DEBUG] mergedEventsEmit uploaded_file:removeFromTemp \u4E8B\u4EF6",D);const Ee=(Pe=D==null?void 0:D.file)==null?void 0:Pe.uid;if(!Ee){console.warn("[DEBUG] \u7F3A\u5C11uid\uFF0C\u65E0\u6CD5\u5220\u9664\u4E34\u65F6\u6587\u4EF6",D);break}const Ye=[...(se==null?void 0:se.messages)||[]].reverse().find(me=>me.istype==="user"),Ze=Ye==null?void 0:Ye.queryId;et(Ee,Ze);break}case"uploaded_file:remove_batch":break;default:o==null||o(k,D)}},Xl=[{key:"conversations",type:"custom",label:"\u5BF9\u8BDD\u5386\u53F2",icon:N(Yf,{size:16}),enabled:!0,component:N(qd,{data:S,assistantList:I,activedItem:X||"",hasMore:S.length<T,loadingMore:H,sortRules:[{label:"\u5F53\u5929",dayPeriod:1},{label:"3\u5929",dayPeriod:3},{label:"7\u5929",dayPeriod:7},{label:"30\u5929",dayPeriod:30}],eventsEmit:kr,styles:d.theme})}],ws=ve.useCallback(()=>N(O1,{eventsEmit:kr,assistantList:I,styles:d,selectedId:ze,onSelectAssistant:ee,productLogo:u==null?void 0:u.productLogo}),[kr,I,d,ze,u==null?void 0:u.productLogo]),Yl={...ve.useMemo(()=>({AiChatBox:(k,D)=>{var ut,ct,Pe,de;const V=D===(((ut=se==null?void 0:se.messages)==null?void 0:ut.length)||0)-1;let W="ready";if(V)if(k.status!==void 0)switch(k.status){case 0:W="thinking";break;case 1:W="processing";break;case 2:W="ready";break;case 3:W="error";break;case 4:W="thinking";break;default:W=Q.display}else W=Q.display;let te=[];if(Array.isArray(M))te=M;else if(typeof M=="string")try{te=JSON.parse(M)||[]}catch{te=[]}const ne=(()=>{var ae;const xe=k==null?void 0:k.reference;if(xe){if(typeof xe=="string")try{return JSON.parse(xe),xe}catch{return"[]"}try{return JSON.stringify(xe)}catch{return"[]"}}const wt=(k==null?void 0:k.faqReference)??((ae=k==null?void 0:k.reply)==null?void 0:ae.faqReference)??void 0;if(!wt)return"[]";try{const Te=typeof wt=="string"?(()=>{const me=wt.replace(/"pk":\s*(\d+)/g,'"pk":"$1"').replace(/"order_num":\s*(\d+)/g,'"order_num":"$1"').replace(/"related_pk":\s*(\d+)/g,'"related_pk":"$1"');return JSON.parse(me)})():wt,Ee=Array.isArray(Te)?Te:[Te];if(!Ee.length)return"[]";const Ze={knowledgeRefs:Ee.map((me,pt)=>{const xt=me.metadata||{},Fr=me.faq_question||xt.sourceFileName||xt.source&&String(xt.source).split("/").pop()||"FAQ",nr=me.folder_path||xt.folder_path||xt.knowledge_base_name||"",mt=nr?`${nr} - ${Fr}`:Fr,Pr=`\u77E5\u8BC6\u5E93${pt+1}\u540D\uFF1A${mt}`,yt=String(me.pk??me.order_num??me.id??""),Ir=typeof me.score=="number"?me.score:typeof xt.score=="number"?xt.score:0;return{id:yt,file_id:yt,file_name:Pr,file_type:"faq",type:"faq",path:"",score:Ir,rrf_score:Ir,tags:[{id:yt,index:pt+1,image_urls:[],metadata:xt}],source:me.folder_path||"",order_num:yt,pk:yt,faq_question:me.faq_question,faq_answer:me.faq_answer,folder_path:me.folder_path,metadata:xt,faqIndex:pt+1,...me}}),webRefs:[],graphRefs:[],databaseRefs:[],images:[],raw:{}};return JSON.stringify(Ze)}catch{return"[]"}})(),ue=(()=>{const xe=k==null?void 0:k.webReference;if(!xe)return"[]";if(typeof xe=="string")try{return JSON.parse(xe),xe}catch{return"[]"}try{return JSON.stringify(xe)}catch{return"[]"}})(),oe=(()=>{const xe=k==null?void 0:k.graphReference;if(!xe)return"[]";if(typeof xe=="string")try{return JSON.parse(xe),xe}catch{return"[]"}try{return JSON.stringify(xe)}catch{return"[]"}})(),Xe=k==null?void 0:k.databaseReference,Ue=(()=>{var wt,ae,Te;if(k!=null&&k.chainRespTime||(wt=k==null?void 0:k.reply)!=null&&wt.chainRespTime)return(k==null?void 0:k.chainRespTime)??((ae=k==null?void 0:k.reply)==null?void 0:ae.chainRespTime);const xe=(k==null?void 0:k.chain)||((Te=k==null?void 0:k.reply)==null?void 0:Te.chain);if(Array.isArray(xe)&&xe.length>0){const Ee=xe.reduce((Ye,Ze)=>{const me=(Ze==null?void 0:Ze.chainRespTime)??(Ze==null?void 0:Ze.respTime);return me!=null&&me>0?Ye+me:Ye},0);return Ee>0?Ee:void 0}})();return N(Ss,{...k,enablePrism:!1,token:e,streamUrl:"/proxy/index/knowledgeBase/file/stream",referenceMode:"button",reference:ne,webReference:ue,graphReference:oe,faqReference:(k==null?void 0:k.faqReference)??((ct=k==null?void 0:k.reply)==null?void 0:ct.faqReference),databaseReference:Xe,contentType:"stream",displayStatus:W,eventsEmit:kr,isLast:V&&(k==null?void 0:k.istype)==="ai",followUpQuestions:V&&(k==null?void 0:k.istype)==="ai"?te:[],defaultAnswer:((Pe=se==null?void 0:se.searchConfigDTO)==null?void 0:Pe.defaultAnswer)||"\u4E0D\u77E5\u9053\u4EC0\u4E48\u539F\u56E0\u6211\u4EEC\u6CA1\u80FD\u67E5\u5230\u4F60\u8981\u7684\u95EE\u9898*-*",is_download:rt,styles:d,enableThoughtChain:!0,chain:k==null?void 0:k.chain,thoughtChainNodes:k==null?void 0:k.thoughtChainNodes,thoughtChainStatus:k==null?void 0:k.status,enableCot:(k==null?void 0:k.enableCot)??((de=k==null?void 0:k.reply)==null?void 0:de.enableCot),chainRespTime:Ue},`${(k==null?void 0:k.queryId)||(k==null?void 0:k.id)||D}-${(k==null?void 0:k.istype)||"unknown"}`)},LogoBox:k=>k&&k.LogoBox===null?null:k&&typeof k.LogoBox=="function"?N(k.LogoBox,{}):N("div",{className:"text-2xl w-full text-center font-bold",children:"\u5C0F\u9CB8\u667A\u80FD\u52A9\u624B"}),DisplayLoading:()=>N(H1,{}),DisplayError:()=>N(j1,{}),AppError:()=>N(q1,{msg:"\u5E94\u7528\u521D\u59CB\u5316\u5931\u8D25",subMsg:"\u65E0\u6CD5\u5B8C\u6210\u5E94\u7528\u521D\u59CB\u5316\uFF0C\u8FD9\u53EF\u80FD\u662F\u7531\u4E8E\u7F51\u7EDC\u8FDE\u63A5\u95EE\u9898\u6216\u670D\u52A1\u914D\u7F6E\u9519\u8BEF\u5BFC\u81F4\u7684\u3002\u8BF7\u68C0\u67E5\u60A8\u7684\u7F51\u7EDC\u8FDE\u63A5\u5E76\u91CD\u8BD5\u3002"}),AppLoading:()=>{var k,D;return N(z1,{title:(k=u==null?void 0:u.appLoadingConfig)==null?void 0:k.title,subtitle:((D=u==null?void 0:u.appLoadingConfig)==null?void 0:D.subtitle)||""})},UserChatBox:(k,D)=>N(Ss,{enablePrism:!1,token:e,streamUrl:"/proxy/index/knowledgeBase/file/stream",...k,referenceMode:"button",contentType:"plainText",isUser:!0,displayStatus:"ready",eventsEmit:kr,styles:d,fileManagerData:Me,currentFiles:k==null?void 0:k.currentFiles},`${(k==null?void 0:k.queryId)||(k==null?void 0:k.id)||D}-user`),WelcomeComponent:ws}),[ws,se,Q.display,kr,d,rt,Me]),...u.CustomComponents||{}};De(()=>{Ae(k=>{const D=Array.isArray(k.switchs)?k.switchs.map(V=>V.name==="reasoning"?{...V,enabled:!0}:V):[];return{...k,switchs:D}})},[]);const Ql=Ke(()=>Me.uploadedFiles||[],[Me]),{FileDisplayTools:Zl}=zf({fileManagerData:{uploadedFiles:Ql},styles:d,eventsEmit:kr});return N(id,{locale:l,children:re("div",{style:{height:"100%",minWidth:"1116px",overflow:"hidden"},children:[N("input",{ref:Re,type:"file",multiple:!0,accept:"image/*,.pdf,.doc,.docx,.ppt,.pptx,.xls,.xlsx,.txt,.md,.json,.csv,.zip,.rar,.7z",style:{display:"none"},onChange:k=>{const D=k.target.files;if(D&&D.length>0){console.log("[DEBUG] handleFileSelect \u89E6\u53D1",{filesCount:D.length,hasSetUploadedFilesRef:!!kt.current,hasSenderConfig:!!$t.current,dynamicSenderConfig:ie,dynamicSenderConfigKeys:ie?Object.keys(ie):[],senderConfigRef:$t.current,senderConfigRefKeys:$t.current?Object.keys($t.current):[]});const V=Array.from(D);let W=$t.current;(!W||W.upload_size_limit===void 0&&W.upload_number_limit===void 0&&(!W.upload_file_type_limit||W.upload_file_type_limit.length===0))&&(W=ie);const te=fr.current||[];console.log("[DEBUG] \u9A8C\u8BC1\u914D\u7F6E\u68C0\u67E5",{configSource:W,upload_number_limit:W==null?void 0:W.upload_number_limit,upload_size_limit:W==null?void 0:W.upload_size_limit,existingFilesCount:te.length,newFilesCount:V.length});const ne=W&&(W.upload_size_limit!==void 0||W.upload_number_limit!==void 0&&W.upload_number_limit>0||W.upload_file_type_limit&&W.upload_file_type_limit.length>0);if(console.log("[DEBUG] \u914D\u7F6E\u68C0\u67E5\u7ED3\u679C",{hasUploadLimitConfig:ne,upload_number_limit:W==null?void 0:W.upload_number_limit,upload_size_limit:W==null?void 0:W.upload_size_limit,upload_file_type_limit:W==null?void 0:W.upload_file_type_limit}),ne){const ue={upload_size_limit:W.upload_size_limit,upload_number_limit:W.upload_number_limit,upload_file_type_limit:W.upload_file_type_limit,upload_limit_message:W.upload_limit_message};console.log("[DEBUG] \u6267\u884C\u6587\u4EF6\u9A8C\u8BC1",{uploadConfig:ue,existingFilesCount:te.length,newFilesCount:V.length,totalCount:te.length+V.length});const oe=uf(V,te,ue);if(console.log("[DEBUG] \u9A8C\u8BC1\u7ED3\u679C",{valid:oe.valid,errors:oe.errors,rejectedFilesCount:oe.rejectedFiles.length}),!oe.valid){lf(oe);const Xe=V.filter(Ue=>!oe.rejectedFiles.includes(Ue));if(Xe.length===0){Re.current&&(Re.current.value="");return}V.splice(0,V.length,...Xe)}}if(kt.current){const ue=V.map(oe=>({file:oe,type:oe.type.startsWith("image/")?"image":"document",status:"pending",name:oe.name}));console.log("[DEBUG] \u901A\u8FC7 setUploadedFilesRef \u8BBE\u7F6E\u6587\u4EF6",ue),kt.current(ue)}else console.warn("[DEBUG] setUploadedFilesRef \u672A\u8BBE\u7F6E\uFF0C\u5EF6\u8FDF\u91CD\u8BD5"),setTimeout(()=>{if(kt.current){const ue=V.map(oe=>({file:oe,type:oe.type.startsWith("image/")?"image":"document",status:"pending",name:oe.name}));console.log("[DEBUG] \u5EF6\u8FDF\u540E\u901A\u8FC7 setUploadedFilesRef \u8BBE\u7F6E\u6587\u4EF6",ue),kt.current(ue)}else console.error("[DEBUG] \u5EF6\u8FDF\u540E setUploadedFilesRef \u4ECD\u672A\u8BBE\u7F6E")},100)}Re.current&&(Re.current.value="")}}),N(r,{...u,status:Q,chatData:se,sidebar:Xl,recommandQuestions:[],eventsEmit:kr,styles:d,senderConfig:ie,fileUploadStatus:Ne,CustomComponents:Yl,activeSessionId:X,scrollOld:s,rightbarWidth:"400px",locale:l,messages:c,disclaimer:u.disclaimer??Ie.disclaimer,chatHeader:{title:(se==null?void 0:se.label)||Ie.chatHeader.newConversation,tools:Zl}}),N(Hf,{open:$r,feedBackList:zr,setOpen:pr,handleConfirm:Qn}),N(Ug,{isModalOpen:g,handleOk:Dr,handleCancel:()=>Dr("close_rename"),data:(y==null?void 0:y.data)||{}}),N(Wg,{isModalOpen:p,handleOk:Dr,handleCancel:()=>Dr("close_remove"),data:(y==null?void 0:y.data)||{}}),N(di,{drawer:{styles:{body:{padding:0},header:{display:"none"}}},children:N(Uc,{autoFocus:!1,onClose:()=>b(!1),open:C,width:F==="graphPreview"?"100%":720,className:"overflow-x-hidden",destroyOnClose:!0,children:F==="preview"&&N(Hl,{curFileInfo:w,onClose:b,token:e})})})]})})}}var Fa={exports:{}};function rm(r){throw new Error('Could not dynamically require "'+r+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Ea={exports:{}};const nm={},am=Object.freeze(Object.defineProperty({__proto__:null,default:nm},Symbol.toStringTag,{value:"Module"})),im=yf(am);var om=Ea.exports,sc;function _e(){return sc||(sc=1,(function(r,t){(function(e,n){r.exports=n()})(om,function(){var e=e||(function(n,a){var i;if(typeof window<"u"&&window.crypto&&(i=window.crypto),typeof self<"u"&&self.crypto&&(i=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(i=globalThis.crypto),!i&&typeof window<"u"&&window.msCrypto&&(i=window.msCrypto),!i&&typeof Si<"u"&&Si.crypto&&(i=Si.crypto),!i&&typeof rm=="function")try{i=im}catch{}var o=function(){if(i){if(typeof i.getRandomValues=="function")try{return i.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof i.randomBytes=="function")try{return i.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},s=Object.create||(function(){function v(){}return function(C){var b;return v.prototype=C,b=new v,v.prototype=null,b}})(),l={},c=l.lib={},u=c.Base=(function(){return{extend:function(v){var C=s(this);return v&&C.mixIn(v),(!C.hasOwnProperty("init")||this.init===C.init)&&(C.init=function(){C.$super.init.apply(this,arguments)}),C.init.prototype=C,C.$super=this,C},create:function(){var v=this.extend();return v.init.apply(v,arguments),v},init:function(){},mixIn:function(v){for(var C in v)v.hasOwnProperty(C)&&(this[C]=v[C]);v.hasOwnProperty("toString")&&(this.toString=v.toString)},clone:function(){return this.init.prototype.extend(this)}}})(),h=c.WordArray=u.extend({init:function(v,C){v=this.words=v||[],C!=a?this.sigBytes=C:this.sigBytes=v.length*4},toString:function(v){return(v||g).stringify(this)},concat:function(v){var C=this.words,b=v.words,F=this.sigBytes,E=v.sigBytes;if(this.clamp(),F%4)for(var w=0;w<E;w++){var A=b[w>>>2]>>>24-w%4*8&255;C[F+w>>>2]|=A<<24-(F+w)%4*8}else for(var S=0;S<E;S+=4)C[F+S>>>2]=b[S>>>2];return this.sigBytes+=E,this},clamp:function(){var v=this.words,C=this.sigBytes;v[C>>>2]&=4294967295<<32-C%4*8,v.length=n.ceil(C/4)},clone:function(){var v=u.clone.call(this);return v.words=this.words.slice(0),v},random:function(v){for(var C=[],b=0;b<v;b+=4)C.push(o());return new h.init(C,v)}}),d=l.enc={},g=d.Hex={stringify:function(v){for(var C=v.words,b=v.sigBytes,F=[],E=0;E<b;E++){var w=C[E>>>2]>>>24-E%4*8&255;F.push((w>>>4).toString(16)),F.push((w&15).toString(16))}return F.join("")},parse:function(v){for(var C=v.length,b=[],F=0;F<C;F+=2)b[F>>>3]|=parseInt(v.substr(F,2),16)<<24-F%8*4;return new h.init(b,C/2)}},x=d.Latin1={stringify:function(v){for(var C=v.words,b=v.sigBytes,F=[],E=0;E<b;E++){var w=C[E>>>2]>>>24-E%4*8&255;F.push(String.fromCharCode(w))}return F.join("")},parse:function(v){for(var C=v.length,b=[],F=0;F<C;F++)b[F>>>2]|=(v.charCodeAt(F)&255)<<24-F%4*8;return new h.init(b,C)}},p=d.Utf8={stringify:function(v){try{return decodeURIComponent(escape(x.stringify(v)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(v){return x.parse(unescape(encodeURIComponent(v)))}},f=c.BufferedBlockAlgorithm=u.extend({reset:function(){this._data=new h.init,this._nDataBytes=0},_append:function(v){typeof v=="string"&&(v=p.parse(v)),this._data.concat(v),this._nDataBytes+=v.sigBytes},_process:function(v){var C,b=this._data,F=b.words,E=b.sigBytes,w=this.blockSize,A=w*4,S=E/A;v?S=n.ceil(S):S=n.max((S|0)-this._minBufferSize,0);var m=S*w,B=n.min(m*4,E);if(m){for(var _=0;_<m;_+=w)this._doProcessBlock(F,_);C=F.splice(0,m),b.sigBytes-=B}return new h.init(C,B)},clone:function(){var v=u.clone.call(this);return v._data=this._data.clone(),v},_minBufferSize:0});c.Hasher=f.extend({cfg:u.extend(),init:function(v){this.cfg=this.cfg.extend(v),this.reset()},reset:function(){f.reset.call(this),this._doReset()},update:function(v){return this._append(v),this._process(),this},finalize:function(v){v&&this._append(v);var C=this._doFinalize();return C},blockSize:16,_createHelper:function(v){return function(C,b){return new v.init(b).finalize(C)}},_createHmacHelper:function(v){return function(C,b){return new y.HMAC.init(v,b).finalize(C)}}});var y=l.algo={};return l})(Math);return e})})(Ea)),Ea.exports}var Aa={exports:{}},sm=Aa.exports,cc;function Ei(){return cc||(cc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(sm,function(e){return(function(n){var a=e,i=a.lib,o=i.Base,s=i.WordArray,l=a.x64={};l.Word=o.extend({init:function(c,u){this.high=c,this.low=u}}),l.WordArray=o.extend({init:function(c,u){c=this.words=c||[],u!=n?this.sigBytes=u:this.sigBytes=c.length*8},toX32:function(){for(var c=this.words,u=c.length,h=[],d=0;d<u;d++){var g=c[d];h.push(g.high),h.push(g.low)}return s.create(h,this.sigBytes)},clone:function(){for(var c=o.clone.call(this),u=c.words=this.words.slice(0),h=u.length,d=0;d<h;d++)u[d]=u[d].clone();return c}})})(),e})})(Aa)),Aa.exports}var wa={exports:{}},cm=wa.exports,uc;function um(){return uc||(uc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(cm,function(e){return(function(){if(typeof ArrayBuffer=="function"){var n=e,a=n.lib,i=a.WordArray,o=i.init,s=i.init=function(l){if(l instanceof ArrayBuffer&&(l=new Uint8Array(l)),(l instanceof Int8Array||typeof Uint8ClampedArray<"u"&&l instanceof Uint8ClampedArray||l instanceof Int16Array||l instanceof Uint16Array||l instanceof Int32Array||l instanceof Uint32Array||l instanceof Float32Array||l instanceof Float64Array)&&(l=new Uint8Array(l.buffer,l.byteOffset,l.byteLength)),l instanceof Uint8Array){for(var c=l.byteLength,u=[],h=0;h<c;h++)u[h>>>2]|=l[h]<<24-h%4*8;o.call(this,u,c)}else o.apply(this,arguments)};s.prototype=i}})(),e.lib.WordArray})})(wa)),wa.exports}var Sa={exports:{}},lm=Sa.exports,lc;function fm(){return lc||(lc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(lm,function(e){return(function(){var n=e,a=n.lib,i=a.WordArray,o=n.enc;o.Utf16=o.Utf16BE={stringify:function(l){for(var c=l.words,u=l.sigBytes,h=[],d=0;d<u;d+=2){var g=c[d>>>2]>>>16-d%4*8&65535;h.push(String.fromCharCode(g))}return h.join("")},parse:function(l){for(var c=l.length,u=[],h=0;h<c;h++)u[h>>>1]|=l.charCodeAt(h)<<16-h%2*16;return i.create(u,c*2)}},o.Utf16LE={stringify:function(l){for(var c=l.words,u=l.sigBytes,h=[],d=0;d<u;d+=2){var g=s(c[d>>>2]>>>16-d%4*8&65535);h.push(String.fromCharCode(g))}return h.join("")},parse:function(l){for(var c=l.length,u=[],h=0;h<c;h++)u[h>>>1]|=s(l.charCodeAt(h)<<16-h%2*16);return i.create(u,c*2)}};function s(l){return l<<8&4278255360|l>>>8&16711935}})(),e.enc.Utf16})})(Sa)),Sa.exports}var Ba={exports:{}},dm=Ba.exports,fc;function Kr(){return fc||(fc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(dm,function(e){return(function(){var n=e,a=n.lib,i=a.WordArray,o=n.enc;o.Base64={stringify:function(l){var c=l.words,u=l.sigBytes,h=this._map;l.clamp();for(var d=[],g=0;g<u;g+=3)for(var x=c[g>>>2]>>>24-g%4*8&255,p=c[g+1>>>2]>>>24-(g+1)%4*8&255,f=c[g+2>>>2]>>>24-(g+2)%4*8&255,y=x<<16|p<<8|f,v=0;v<4&&g+v*.75<u;v++)d.push(h.charAt(y>>>6*(3-v)&63));var C=h.charAt(64);if(C)for(;d.length%4;)d.push(C);return d.join("")},parse:function(l){var c=l.length,u=this._map,h=this._reverseMap;if(!h){h=this._reverseMap=[];for(var d=0;d<u.length;d++)h[u.charCodeAt(d)]=d}var g=u.charAt(64);if(g){var x=l.indexOf(g);x!==-1&&(c=x)}return s(l,c,h)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function s(l,c,u){for(var h=[],d=0,g=0;g<c;g++)if(g%4){var x=u[l.charCodeAt(g-1)]<<g%4*2,p=u[l.charCodeAt(g)]>>>6-g%4*2,f=x|p;h[d>>>2]|=f<<24-d%4*8,d++}return i.create(h,d)}})(),e.enc.Base64})})(Ba)),Ba.exports}var _a={exports:{}},pm=_a.exports,dc;function hm(){return dc||(dc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(pm,function(e){return(function(){var n=e,a=n.lib,i=a.WordArray,o=n.enc;o.Base64url={stringify:function(l,c){c===void 0&&(c=!0);var u=l.words,h=l.sigBytes,d=c?this._safe_map:this._map;l.clamp();for(var g=[],x=0;x<h;x+=3)for(var p=u[x>>>2]>>>24-x%4*8&255,f=u[x+1>>>2]>>>24-(x+1)%4*8&255,y=u[x+2>>>2]>>>24-(x+2)%4*8&255,v=p<<16|f<<8|y,C=0;C<4&&x+C*.75<h;C++)g.push(d.charAt(v>>>6*(3-C)&63));var b=d.charAt(64);if(b)for(;g.length%4;)g.push(b);return g.join("")},parse:function(l,c){c===void 0&&(c=!0);var u=l.length,h=c?this._safe_map:this._map,d=this._reverseMap;if(!d){d=this._reverseMap=[];for(var g=0;g<h.length;g++)d[h.charCodeAt(g)]=g}var x=h.charAt(64);if(x){var p=l.indexOf(x);p!==-1&&(u=p)}return s(l,u,d)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function s(l,c,u){for(var h=[],d=0,g=0;g<c;g++)if(g%4){var x=u[l.charCodeAt(g-1)]<<g%4*2,p=u[l.charCodeAt(g)]>>>6-g%4*2,f=x|p;h[d>>>2]|=f<<24-d%4*8,d++}return i.create(h,d)}})(),e.enc.Base64url})})(_a)),_a.exports}var Da={exports:{}},vm=Da.exports,pc;function Xr(){return pc||(pc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(vm,function(e){return(function(n){var a=e,i=a.lib,o=i.WordArray,s=i.Hasher,l=a.algo,c=[];(function(){for(var p=0;p<64;p++)c[p]=n.abs(n.sin(p+1))*4294967296|0})();var u=l.MD5=s.extend({_doReset:function(){this._hash=new o.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(p,f){for(var y=0;y<16;y++){var v=f+y,C=p[v];p[v]=(C<<8|C>>>24)&16711935|(C<<24|C>>>8)&4278255360}var b=this._hash.words,F=p[f+0],E=p[f+1],w=p[f+2],A=p[f+3],S=p[f+4],m=p[f+5],B=p[f+6],_=p[f+7],P=p[f+8],T=p[f+9],$=p[f+10],H=p[f+11],j=p[f+12],q=p[f+13],G=p[f+14],X=p[f+15],O=b[0],M=b[1],R=b[2],I=b[3];O=h(O,M,R,I,F,7,c[0]),I=h(I,O,M,R,E,12,c[1]),R=h(R,I,O,M,w,17,c[2]),M=h(M,R,I,O,A,22,c[3]),O=h(O,M,R,I,S,7,c[4]),I=h(I,O,M,R,m,12,c[5]),R=h(R,I,O,M,B,17,c[6]),M=h(M,R,I,O,_,22,c[7]),O=h(O,M,R,I,P,7,c[8]),I=h(I,O,M,R,T,12,c[9]),R=h(R,I,O,M,$,17,c[10]),M=h(M,R,I,O,H,22,c[11]),O=h(O,M,R,I,j,7,c[12]),I=h(I,O,M,R,q,12,c[13]),R=h(R,I,O,M,G,17,c[14]),M=h(M,R,I,O,X,22,c[15]),O=d(O,M,R,I,E,5,c[16]),I=d(I,O,M,R,B,9,c[17]),R=d(R,I,O,M,H,14,c[18]),M=d(M,R,I,O,F,20,c[19]),O=d(O,M,R,I,m,5,c[20]),I=d(I,O,M,R,$,9,c[21]),R=d(R,I,O,M,X,14,c[22]),M=d(M,R,I,O,S,20,c[23]),O=d(O,M,R,I,T,5,c[24]),I=d(I,O,M,R,G,9,c[25]),R=d(R,I,O,M,A,14,c[26]),M=d(M,R,I,O,P,20,c[27]),O=d(O,M,R,I,q,5,c[28]),I=d(I,O,M,R,w,9,c[29]),R=d(R,I,O,M,_,14,c[30]),M=d(M,R,I,O,j,20,c[31]),O=g(O,M,R,I,m,4,c[32]),I=g(I,O,M,R,P,11,c[33]),R=g(R,I,O,M,H,16,c[34]),M=g(M,R,I,O,G,23,c[35]),O=g(O,M,R,I,E,4,c[36]),I=g(I,O,M,R,S,11,c[37]),R=g(R,I,O,M,_,16,c[38]),M=g(M,R,I,O,$,23,c[39]),O=g(O,M,R,I,q,4,c[40]),I=g(I,O,M,R,F,11,c[41]),R=g(R,I,O,M,A,16,c[42]),M=g(M,R,I,O,B,23,c[43]),O=g(O,M,R,I,T,4,c[44]),I=g(I,O,M,R,j,11,c[45]),R=g(R,I,O,M,X,16,c[46]),M=g(M,R,I,O,w,23,c[47]),O=x(O,M,R,I,F,6,c[48]),I=x(I,O,M,R,_,10,c[49]),R=x(R,I,O,M,G,15,c[50]),M=x(M,R,I,O,m,21,c[51]),O=x(O,M,R,I,j,6,c[52]),I=x(I,O,M,R,A,10,c[53]),R=x(R,I,O,M,$,15,c[54]),M=x(M,R,I,O,E,21,c[55]),O=x(O,M,R,I,P,6,c[56]),I=x(I,O,M,R,X,10,c[57]),R=x(R,I,O,M,B,15,c[58]),M=x(M,R,I,O,q,21,c[59]),O=x(O,M,R,I,S,6,c[60]),I=x(I,O,M,R,H,10,c[61]),R=x(R,I,O,M,w,15,c[62]),M=x(M,R,I,O,T,21,c[63]),b[0]=b[0]+O|0,b[1]=b[1]+M|0,b[2]=b[2]+R|0,b[3]=b[3]+I|0},_doFinalize:function(){var p=this._data,f=p.words,y=this._nDataBytes*8,v=p.sigBytes*8;f[v>>>5]|=128<<24-v%32;var C=n.floor(y/4294967296),b=y;f[(v+64>>>9<<4)+15]=(C<<8|C>>>24)&16711935|(C<<24|C>>>8)&4278255360,f[(v+64>>>9<<4)+14]=(b<<8|b>>>24)&16711935|(b<<24|b>>>8)&4278255360,p.sigBytes=(f.length+1)*4,this._process();for(var F=this._hash,E=F.words,w=0;w<4;w++){var A=E[w];E[w]=(A<<8|A>>>24)&16711935|(A<<24|A>>>8)&4278255360}return F},clone:function(){var p=s.clone.call(this);return p._hash=this._hash.clone(),p}});function h(p,f,y,v,C,b,F){var E=p+(f&y|~f&v)+C+F;return(E<<b|E>>>32-b)+f}function d(p,f,y,v,C,b,F){var E=p+(f&v|y&~v)+C+F;return(E<<b|E>>>32-b)+f}function g(p,f,y,v,C,b,F){var E=p+(f^y^v)+C+F;return(E<<b|E>>>32-b)+f}function x(p,f,y,v,C,b,F){var E=p+(y^(f|~v))+C+F;return(E<<b|E>>>32-b)+f}a.MD5=s._createHelper(u),a.HmacMD5=s._createHmacHelper(u)})(Math),e.MD5})})(Da)),Da.exports}var ka={exports:{}},xm=ka.exports,hc;function jl(){return hc||(hc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(xm,function(e){return(function(){var n=e,a=n.lib,i=a.WordArray,o=a.Hasher,s=n.algo,l=[],c=s.SHA1=o.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(u,h){for(var d=this._hash.words,g=d[0],x=d[1],p=d[2],f=d[3],y=d[4],v=0;v<80;v++){if(v<16)l[v]=u[h+v]|0;else{var C=l[v-3]^l[v-8]^l[v-14]^l[v-16];l[v]=C<<1|C>>>31}var b=(g<<5|g>>>27)+y+l[v];v<20?b+=(x&p|~x&f)+1518500249:v<40?b+=(x^p^f)+1859775393:v<60?b+=(x&p|x&f|p&f)-1894007588:b+=(x^p^f)-899497514,y=f,f=p,p=x<<30|x>>>2,x=g,g=b}d[0]=d[0]+g|0,d[1]=d[1]+x|0,d[2]=d[2]+p|0,d[3]=d[3]+f|0,d[4]=d[4]+y|0},_doFinalize:function(){var u=this._data,h=u.words,d=this._nDataBytes*8,g=u.sigBytes*8;return h[g>>>5]|=128<<24-g%32,h[(g+64>>>9<<4)+14]=Math.floor(d/4294967296),h[(g+64>>>9<<4)+15]=d,u.sigBytes=h.length*4,this._process(),this._hash},clone:function(){var u=o.clone.call(this);return u._hash=this._hash.clone(),u}});n.SHA1=o._createHelper(c),n.HmacSHA1=o._createHmacHelper(c)})(),e.SHA1})})(ka)),ka.exports}var Pa={exports:{}},gm=Pa.exports,vc;function bs(){return vc||(vc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(gm,function(e){return(function(n){var a=e,i=a.lib,o=i.WordArray,s=i.Hasher,l=a.algo,c=[],u=[];(function(){function g(y){for(var v=n.sqrt(y),C=2;C<=v;C++)if(!(y%C))return!1;return!0}function x(y){return(y-(y|0))*4294967296|0}for(var p=2,f=0;f<64;)g(p)&&(f<8&&(c[f]=x(n.pow(p,1/2))),u[f]=x(n.pow(p,1/3)),f++),p++})();var h=[],d=l.SHA256=s.extend({_doReset:function(){this._hash=new o.init(c.slice(0))},_doProcessBlock:function(g,x){for(var p=this._hash.words,f=p[0],y=p[1],v=p[2],C=p[3],b=p[4],F=p[5],E=p[6],w=p[7],A=0;A<64;A++){if(A<16)h[A]=g[x+A]|0;else{var S=h[A-15],m=(S<<25|S>>>7)^(S<<14|S>>>18)^S>>>3,B=h[A-2],_=(B<<15|B>>>17)^(B<<13|B>>>19)^B>>>10;h[A]=m+h[A-7]+_+h[A-16]}var P=b&F^~b&E,T=f&y^f&v^y&v,$=(f<<30|f>>>2)^(f<<19|f>>>13)^(f<<10|f>>>22),H=(b<<26|b>>>6)^(b<<21|b>>>11)^(b<<7|b>>>25),j=w+H+P+u[A]+h[A],q=$+T;w=E,E=F,F=b,b=C+j|0,C=v,v=y,y=f,f=j+q|0}p[0]=p[0]+f|0,p[1]=p[1]+y|0,p[2]=p[2]+v|0,p[3]=p[3]+C|0,p[4]=p[4]+b|0,p[5]=p[5]+F|0,p[6]=p[6]+E|0,p[7]=p[7]+w|0},_doFinalize:function(){var g=this._data,x=g.words,p=this._nDataBytes*8,f=g.sigBytes*8;return x[f>>>5]|=128<<24-f%32,x[(f+64>>>9<<4)+14]=n.floor(p/4294967296),x[(f+64>>>9<<4)+15]=p,g.sigBytes=x.length*4,this._process(),this._hash},clone:function(){var g=s.clone.call(this);return g._hash=this._hash.clone(),g}});a.SHA256=s._createHelper(d),a.HmacSHA256=s._createHmacHelper(d)})(Math),e.SHA256})})(Pa)),Pa.exports}var Ia={exports:{}},mm=Ia.exports,xc;function ym(){return xc||(xc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),bs())})(mm,function(e){return(function(){var n=e,a=n.lib,i=a.WordArray,o=n.algo,s=o.SHA256,l=o.SHA224=s.extend({_doReset:function(){this._hash=new i.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var c=s._doFinalize.call(this);return c.sigBytes-=4,c}});n.SHA224=s._createHelper(l),n.HmacSHA224=s._createHmacHelper(l)})(),e.SHA224})})(Ia)),Ia.exports}var Ta={exports:{}},Cm=Ta.exports,gc;function Vl(){return gc||(gc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ei())})(Cm,function(e){return(function(){var n=e,a=n.lib,i=a.Hasher,o=n.x64,s=o.Word,l=o.WordArray,c=n.algo;function u(){return s.create.apply(s,arguments)}var h=[u(1116352408,3609767458),u(1899447441,602891725),u(3049323471,3964484399),u(3921009573,2173295548),u(961987163,4081628472),u(1508970993,3053834265),u(2453635748,2937671579),u(2870763221,3664609560),u(3624381080,2734883394),u(310598401,1164996542),u(607225278,1323610764),u(1426881987,3590304994),u(1925078388,4068182383),u(2162078206,991336113),u(2614888103,633803317),u(3248222580,3479774868),u(3835390401,2666613458),u(4022224774,944711139),u(264347078,2341262773),u(604807628,2007800933),u(770255983,1495990901),u(1249150122,1856431235),u(1555081692,3175218132),u(1996064986,2198950837),u(2554220882,3999719339),u(2821834349,766784016),u(2952996808,2566594879),u(3210313671,3203337956),u(3336571891,1034457026),u(3584528711,2466948901),u(113926993,3758326383),u(338241895,168717936),u(666307205,1188179964),u(773529912,1546045734),u(1294757372,1522805485),u(1396182291,2643833823),u(1695183700,2343527390),u(1986661051,1014477480),u(2177026350,1206759142),u(2456956037,344077627),u(2730485921,1290863460),u(2820302411,3158454273),u(3259730800,3505952657),u(3345764771,106217008),u(3516065817,3606008344),u(3600352804,1432725776),u(4094571909,1467031594),u(275423344,851169720),u(430227734,3100823752),u(506948616,1363258195),u(659060556,3750685593),u(883997877,3785050280),u(958139571,3318307427),u(1322822218,3812723403),u(1537002063,2003034995),u(1747873779,3602036899),u(1955562222,1575990012),u(2024104815,1125592928),u(2227730452,2716904306),u(2361852424,442776044),u(2428436474,593698344),u(2756734187,3733110249),u(3204031479,2999351573),u(3329325298,3815920427),u(3391569614,3928383900),u(3515267271,566280711),u(3940187606,3454069534),u(4118630271,4000239992),u(116418474,1914138554),u(174292421,2731055270),u(289380356,3203993006),u(460393269,320620315),u(685471733,587496836),u(852142971,1086792851),u(1017036298,365543100),u(1126000580,2618297676),u(1288033470,3409855158),u(1501505948,4234509866),u(1607167915,987167468),u(1816402316,1246189591)],d=[];(function(){for(var x=0;x<80;x++)d[x]=u()})();var g=c.SHA512=i.extend({_doReset:function(){this._hash=new l.init([new s.init(1779033703,4089235720),new s.init(3144134277,2227873595),new s.init(1013904242,4271175723),new s.init(2773480762,1595750129),new s.init(1359893119,2917565137),new s.init(2600822924,725511199),new s.init(528734635,4215389547),new s.init(1541459225,327033209)])},_doProcessBlock:function(x,p){for(var f=this._hash.words,y=f[0],v=f[1],C=f[2],b=f[3],F=f[4],E=f[5],w=f[6],A=f[7],S=y.high,m=y.low,B=v.high,_=v.low,P=C.high,T=C.low,$=b.high,H=b.low,j=F.high,q=F.low,G=E.high,X=E.low,O=w.high,M=w.low,R=A.high,I=A.low,U=S,K=m,Z=B,Q=_,J=P,pe=T,Ie=$,Se=H,ie=j,Ae=q,Ne=G,he=X,it=O,et=M,tt=R,st=I,Fe=0;Fe<80;Fe++){var ye,ke,Me=d[Fe];if(Fe<16)ke=Me.high=x[p+Fe*2]|0,ye=Me.low=x[p+Fe*2+1]|0;else{var ze=d[Fe-15],ee=ze.high,Ce=ze.low,ot=(ee>>>1|Ce<<31)^(ee>>>8|Ce<<24)^ee>>>7,Dt=(Ce>>>1|ee<<31)^(Ce>>>8|ee<<24)^(Ce>>>7|ee<<25),kt=d[Fe-2],Lt=kt.high,Re=kt.low,$t=(Lt>>>19|Re<<13)^(Lt<<3|Re>>>29)^Lt>>>6,fr=(Re>>>19|Lt<<13)^(Re<<3|Lt>>>29)^(Re>>>6|Lt<<26),Br=d[Fe-7],Pt=Br.high,br=Br.low,dr=d[Fe-16],$r=dr.high,pr=dr.low;ye=Dt+br,ke=ot+Pt+(ye>>>0<Dt>>>0?1:0),ye=ye+fr,ke=ke+$t+(ye>>>0<fr>>>0?1:0),ye=ye+pr,ke=ke+$r+(ye>>>0<pr>>>0?1:0),Me.high=ke,Me.low=ye}var zr=ie&Ne^~ie&it,_r=Ae&he^~Ae&et,Hr=U&Z^U&J^Z&J,zt=K&Q^K&pe^Q&pe,Et=(U>>>28|K<<4)^(U<<30|K>>>2)^(U<<25|K>>>7),It=(K>>>28|U<<4)^(K<<30|U>>>2)^(K<<25|U>>>7),Ht=(ie>>>14|Ae<<18)^(ie>>>18|Ae<<14)^(ie<<23|Ae>>>9),er=(Ae>>>14|ie<<18)^(Ae>>>18|ie<<14)^(Ae<<23|ie>>>9),Gt=h[Fe],Qe=Gt.high,se=Gt.low,rt=st+er,At=tt+Ht+(rt>>>0<st>>>0?1:0),rt=rt+_r,At=At+zr+(rt>>>0<_r>>>0?1:0),rt=rt+se,At=At+Qe+(rt>>>0<se>>>0?1:0),rt=rt+ye,At=At+ke+(rt>>>0<ye>>>0?1:0),be=It+zt,nt=Et+Hr+(be>>>0<It>>>0?1:0);tt=it,st=et,it=Ne,et=he,Ne=ie,he=Ae,Ae=Se+rt|0,ie=Ie+At+(Ae>>>0<Se>>>0?1:0)|0,Ie=J,Se=pe,J=Z,pe=Q,Z=U,Q=K,K=rt+be|0,U=At+nt+(K>>>0<rt>>>0?1:0)|0}m=y.low=m+K,y.high=S+U+(m>>>0<K>>>0?1:0),_=v.low=_+Q,v.high=B+Z+(_>>>0<Q>>>0?1:0),T=C.low=T+pe,C.high=P+J+(T>>>0<pe>>>0?1:0),H=b.low=H+Se,b.high=$+Ie+(H>>>0<Se>>>0?1:0),q=F.low=q+Ae,F.high=j+ie+(q>>>0<Ae>>>0?1:0),X=E.low=X+he,E.high=G+Ne+(X>>>0<he>>>0?1:0),M=w.low=M+et,w.high=O+it+(M>>>0<et>>>0?1:0),I=A.low=I+st,A.high=R+tt+(I>>>0<st>>>0?1:0)},_doFinalize:function(){var x=this._data,p=x.words,f=this._nDataBytes*8,y=x.sigBytes*8;p[y>>>5]|=128<<24-y%32,p[(y+128>>>10<<5)+30]=Math.floor(f/4294967296),p[(y+128>>>10<<5)+31]=f,x.sigBytes=p.length*4,this._process();var v=this._hash.toX32();return v},clone:function(){var x=i.clone.call(this);return x._hash=this._hash.clone(),x},blockSize:1024/32});n.SHA512=i._createHelper(g),n.HmacSHA512=i._createHmacHelper(g)})(),e.SHA512})})(Ta)),Ta.exports}var Ra={exports:{}},bm=Ra.exports,mc;function Fm(){return mc||(mc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ei(),Vl())})(bm,function(e){return(function(){var n=e,a=n.x64,i=a.Word,o=a.WordArray,s=n.algo,l=s.SHA512,c=s.SHA384=l.extend({_doReset:function(){this._hash=new o.init([new i.init(3418070365,3238371032),new i.init(1654270250,914150663),new i.init(2438529370,812702999),new i.init(355462360,4144912697),new i.init(1731405415,4290775857),new i.init(2394180231,1750603025),new i.init(3675008525,1694076839),new i.init(1203062813,3204075428)])},_doFinalize:function(){var u=l._doFinalize.call(this);return u.sigBytes-=16,u}});n.SHA384=l._createHelper(c),n.HmacSHA384=l._createHmacHelper(c)})(),e.SHA384})})(Ra)),Ra.exports}var Oa={exports:{}},Em=Oa.exports,yc;function Am(){return yc||(yc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ei())})(Em,function(e){return(function(n){var a=e,i=a.lib,o=i.WordArray,s=i.Hasher,l=a.x64,c=l.Word,u=a.algo,h=[],d=[],g=[];(function(){for(var f=1,y=0,v=0;v<24;v++){h[f+5*y]=(v+1)*(v+2)/2%64;var C=y%5,b=(2*f+3*y)%5;f=C,y=b}for(var f=0;f<5;f++)for(var y=0;y<5;y++)d[f+5*y]=y+(2*f+3*y)%5*5;for(var F=1,E=0;E<24;E++){for(var w=0,A=0,S=0;S<7;S++){if(F&1){var m=(1<<S)-1;m<32?A^=1<<m:w^=1<<m-32}F&128?F=F<<1^113:F<<=1}g[E]=c.create(w,A)}})();var x=[];(function(){for(var f=0;f<25;f++)x[f]=c.create()})();var p=u.SHA3=s.extend({cfg:s.cfg.extend({outputLength:512}),_doReset:function(){for(var f=this._state=[],y=0;y<25;y++)f[y]=new c.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(f,y){for(var v=this._state,C=this.blockSize/2,b=0;b<C;b++){var F=f[y+2*b],E=f[y+2*b+1];F=(F<<8|F>>>24)&16711935|(F<<24|F>>>8)&4278255360,E=(E<<8|E>>>24)&16711935|(E<<24|E>>>8)&4278255360;var w=v[b];w.high^=E,w.low^=F}for(var A=0;A<24;A++){for(var S=0;S<5;S++){for(var m=0,B=0,_=0;_<5;_++){var w=v[S+5*_];m^=w.high,B^=w.low}var P=x[S];P.high=m,P.low=B}for(var S=0;S<5;S++)for(var T=x[(S+4)%5],$=x[(S+1)%5],H=$.high,j=$.low,m=T.high^(H<<1|j>>>31),B=T.low^(j<<1|H>>>31),_=0;_<5;_++){var w=v[S+5*_];w.high^=m,w.low^=B}for(var q=1;q<25;q++){var m,B,w=v[q],G=w.high,X=w.low,O=h[q];O<32?(m=G<<O|X>>>32-O,B=X<<O|G>>>32-O):(m=X<<O-32|G>>>64-O,B=G<<O-32|X>>>64-O);var M=x[d[q]];M.high=m,M.low=B}var R=x[0],I=v[0];R.high=I.high,R.low=I.low;for(var S=0;S<5;S++)for(var _=0;_<5;_++){var q=S+5*_,w=v[q],U=x[q],K=x[(S+1)%5+5*_],Z=x[(S+2)%5+5*_];w.high=U.high^~K.high&Z.high,w.low=U.low^~K.low&Z.low}var w=v[0],Q=g[A];w.high^=Q.high,w.low^=Q.low}},_doFinalize:function(){var f=this._data,y=f.words;this._nDataBytes*8;var v=f.sigBytes*8,C=this.blockSize*32;y[v>>>5]|=1<<24-v%32,y[(n.ceil((v+1)/C)*C>>>5)-1]|=128,f.sigBytes=y.length*4,this._process();for(var b=this._state,F=this.cfg.outputLength/8,E=F/8,w=[],A=0;A<E;A++){var S=b[A],m=S.high,B=S.low;m=(m<<8|m>>>24)&16711935|(m<<24|m>>>8)&4278255360,B=(B<<8|B>>>24)&16711935|(B<<24|B>>>8)&4278255360,w.push(B),w.push(m)}return new o.init(w,F)},clone:function(){for(var f=s.clone.call(this),y=f._state=this._state.slice(0),v=0;v<25;v++)y[v]=y[v].clone();return f}});a.SHA3=s._createHelper(p),a.HmacSHA3=s._createHmacHelper(p)})(Math),e.SHA3})})(Oa)),Oa.exports}var Na={exports:{}},wm=Na.exports,Cc;function Sm(){return Cc||(Cc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(wm,function(e){/** @preserve
320
+ (c) 2012 by Cédric Mesnil. All rights reserved.
321
+
322
+ Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
323
+
324
+ - Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
325
+ - Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
326
+
327
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
328
+ */return(function(n){var a=e,i=a.lib,o=i.WordArray,s=i.Hasher,l=a.algo,c=o.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),u=o.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),h=o.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),d=o.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),g=o.create([0,1518500249,1859775393,2400959708,2840853838]),x=o.create([1352829926,1548603684,1836072691,2053994217,0]),p=l.RIPEMD160=s.extend({_doReset:function(){this._hash=o.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(E,w){for(var A=0;A<16;A++){var S=w+A,m=E[S];E[S]=(m<<8|m>>>24)&16711935|(m<<24|m>>>8)&4278255360}var B=this._hash.words,_=g.words,P=x.words,T=c.words,$=u.words,H=h.words,j=d.words,q,G,X,O,M,R,I,U,K,Z;R=q=B[0],I=G=B[1],U=X=B[2],K=O=B[3],Z=M=B[4];for(var Q,A=0;A<80;A+=1)Q=q+E[w+T[A]]|0,A<16?Q+=f(G,X,O)+_[0]:A<32?Q+=y(G,X,O)+_[1]:A<48?Q+=v(G,X,O)+_[2]:A<64?Q+=C(G,X,O)+_[3]:Q+=b(G,X,O)+_[4],Q=Q|0,Q=F(Q,H[A]),Q=Q+M|0,q=M,M=O,O=F(X,10),X=G,G=Q,Q=R+E[w+$[A]]|0,A<16?Q+=b(I,U,K)+P[0]:A<32?Q+=C(I,U,K)+P[1]:A<48?Q+=v(I,U,K)+P[2]:A<64?Q+=y(I,U,K)+P[3]:Q+=f(I,U,K)+P[4],Q=Q|0,Q=F(Q,j[A]),Q=Q+Z|0,R=Z,Z=K,K=F(U,10),U=I,I=Q;Q=B[1]+X+K|0,B[1]=B[2]+O+Z|0,B[2]=B[3]+M+R|0,B[3]=B[4]+q+I|0,B[4]=B[0]+G+U|0,B[0]=Q},_doFinalize:function(){var E=this._data,w=E.words,A=this._nDataBytes*8,S=E.sigBytes*8;w[S>>>5]|=128<<24-S%32,w[(S+64>>>9<<4)+14]=(A<<8|A>>>24)&16711935|(A<<24|A>>>8)&4278255360,E.sigBytes=(w.length+1)*4,this._process();for(var m=this._hash,B=m.words,_=0;_<5;_++){var P=B[_];B[_]=(P<<8|P>>>24)&16711935|(P<<24|P>>>8)&4278255360}return m},clone:function(){var E=s.clone.call(this);return E._hash=this._hash.clone(),E}});function f(E,w,A){return E^w^A}function y(E,w,A){return E&w|~E&A}function v(E,w,A){return(E|~w)^A}function C(E,w,A){return E&A|w&~A}function b(E,w,A){return E^(w|~A)}function F(E,w){return E<<w|E>>>32-w}a.RIPEMD160=s._createHelper(p),a.HmacRIPEMD160=s._createHmacHelper(p)})(),e.RIPEMD160})})(Na)),Na.exports}var Ma={exports:{}},Bm=Ma.exports,bc;function Fs(){return bc||(bc=1,(function(r,t){(function(e,n){r.exports=n(_e())})(Bm,function(e){(function(){var n=e,a=n.lib,i=a.Base,o=n.enc,s=o.Utf8,l=n.algo;l.HMAC=i.extend({init:function(c,u){c=this._hasher=new c.init,typeof u=="string"&&(u=s.parse(u));var h=c.blockSize,d=h*4;u.sigBytes>d&&(u=c.finalize(u)),u.clamp();for(var g=this._oKey=u.clone(),x=this._iKey=u.clone(),p=g.words,f=x.words,y=0;y<h;y++)p[y]^=1549556828,f[y]^=909522486;g.sigBytes=x.sigBytes=d,this.reset()},reset:function(){var c=this._hasher;c.reset(),c.update(this._iKey)},update:function(c){return this._hasher.update(c),this},finalize:function(c){var u=this._hasher,h=u.finalize(c);u.reset();var d=u.finalize(this._oKey.clone().concat(h));return d}})})()})})(Ma)),Ma.exports}var La={exports:{}},_m=La.exports,Fc;function Dm(){return Fc||(Fc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),bs(),Fs())})(_m,function(e){return(function(){var n=e,a=n.lib,i=a.Base,o=a.WordArray,s=n.algo,l=s.SHA256,c=s.HMAC,u=s.PBKDF2=i.extend({cfg:i.extend({keySize:128/32,hasher:l,iterations:25e4}),init:function(h){this.cfg=this.cfg.extend(h)},compute:function(h,d){for(var g=this.cfg,x=c.create(g.hasher,h),p=o.create(),f=o.create([1]),y=p.words,v=f.words,C=g.keySize,b=g.iterations;y.length<C;){var F=x.update(d).finalize(f);x.reset();for(var E=F.words,w=E.length,A=F,S=1;S<b;S++){A=x.finalize(A),x.reset();for(var m=A.words,B=0;B<w;B++)E[B]^=m[B]}p.concat(F),v[0]++}return p.sigBytes=C*4,p}});n.PBKDF2=function(h,d,g){return u.create(g).compute(h,d)}})(),e.PBKDF2})})(La)),La.exports}var $a={exports:{}},km=$a.exports,Ec;function Lr(){return Ec||(Ec=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),jl(),Fs())})(km,function(e){return(function(){var n=e,a=n.lib,i=a.Base,o=a.WordArray,s=n.algo,l=s.MD5,c=s.EvpKDF=i.extend({cfg:i.extend({keySize:128/32,hasher:l,iterations:1}),init:function(u){this.cfg=this.cfg.extend(u)},compute:function(u,h){for(var d,g=this.cfg,x=g.hasher.create(),p=o.create(),f=p.words,y=g.keySize,v=g.iterations;f.length<y;){d&&x.update(d),d=x.update(u).finalize(h),x.reset();for(var C=1;C<v;C++)d=x.finalize(d),x.reset();p.concat(d)}return p.sigBytes=y*4,p}});n.EvpKDF=function(u,h,d){return c.create(d).compute(u,h)}})(),e.EvpKDF})})($a)),$a.exports}var za={exports:{}},Pm=za.exports,Ac;function Ft(){return Ac||(Ac=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Lr())})(Pm,function(e){e.lib.Cipher||(function(n){var a=e,i=a.lib,o=i.Base,s=i.WordArray,l=i.BufferedBlockAlgorithm,c=a.enc;c.Utf8;var u=c.Base64,h=a.algo,d=h.EvpKDF,g=i.Cipher=l.extend({cfg:o.extend(),createEncryptor:function(m,B){return this.create(this._ENC_XFORM_MODE,m,B)},createDecryptor:function(m,B){return this.create(this._DEC_XFORM_MODE,m,B)},init:function(m,B,_){this.cfg=this.cfg.extend(_),this._xformMode=m,this._key=B,this.reset()},reset:function(){l.reset.call(this),this._doReset()},process:function(m){return this._append(m),this._process()},finalize:function(m){m&&this._append(m);var B=this._doFinalize();return B},keySize:128/32,ivSize:128/32,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:(function(){function m(B){return typeof B=="string"?S:E}return function(B){return{encrypt:function(_,P,T){return m(P).encrypt(B,_,P,T)},decrypt:function(_,P,T){return m(P).decrypt(B,_,P,T)}}}})()});i.StreamCipher=g.extend({_doFinalize:function(){var m=this._process(!0);return m},blockSize:1});var x=a.mode={},p=i.BlockCipherMode=o.extend({createEncryptor:function(m,B){return this.Encryptor.create(m,B)},createDecryptor:function(m,B){return this.Decryptor.create(m,B)},init:function(m,B){this._cipher=m,this._iv=B}}),f=x.CBC=(function(){var m=p.extend();m.Encryptor=m.extend({processBlock:function(_,P){var T=this._cipher,$=T.blockSize;B.call(this,_,P,$),T.encryptBlock(_,P),this._prevBlock=_.slice(P,P+$)}}),m.Decryptor=m.extend({processBlock:function(_,P){var T=this._cipher,$=T.blockSize,H=_.slice(P,P+$);T.decryptBlock(_,P),B.call(this,_,P,$),this._prevBlock=H}});function B(_,P,T){var $,H=this._iv;H?($=H,this._iv=n):$=this._prevBlock;for(var j=0;j<T;j++)_[P+j]^=$[j]}return m})(),y=a.pad={},v=y.Pkcs7={pad:function(m,B){for(var _=B*4,P=_-m.sigBytes%_,T=P<<24|P<<16|P<<8|P,$=[],H=0;H<P;H+=4)$.push(T);var j=s.create($,P);m.concat(j)},unpad:function(m){var B=m.words[m.sigBytes-1>>>2]&255;m.sigBytes-=B}};i.BlockCipher=g.extend({cfg:g.cfg.extend({mode:f,padding:v}),reset:function(){var m;g.reset.call(this);var B=this.cfg,_=B.iv,P=B.mode;this._xformMode==this._ENC_XFORM_MODE?m=P.createEncryptor:(m=P.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==m?this._mode.init(this,_&&_.words):(this._mode=m.call(P,this,_&&_.words),this._mode.__creator=m)},_doProcessBlock:function(m,B){this._mode.processBlock(m,B)},_doFinalize:function(){var m,B=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(B.pad(this._data,this.blockSize),m=this._process(!0)):(m=this._process(!0),B.unpad(m)),m},blockSize:128/32});var C=i.CipherParams=o.extend({init:function(m){this.mixIn(m)},toString:function(m){return(m||this.formatter).stringify(this)}}),b=a.format={},F=b.OpenSSL={stringify:function(m){var B,_=m.ciphertext,P=m.salt;return P?B=s.create([1398893684,1701076831]).concat(P).concat(_):B=_,B.toString(u)},parse:function(m){var B,_=u.parse(m),P=_.words;return P[0]==1398893684&&P[1]==1701076831&&(B=s.create(P.slice(2,4)),P.splice(0,4),_.sigBytes-=16),C.create({ciphertext:_,salt:B})}},E=i.SerializableCipher=o.extend({cfg:o.extend({format:F}),encrypt:function(m,B,_,P){P=this.cfg.extend(P);var T=m.createEncryptor(_,P),$=T.finalize(B),H=T.cfg;return C.create({ciphertext:$,key:_,iv:H.iv,algorithm:m,mode:H.mode,padding:H.padding,blockSize:m.blockSize,formatter:P.format})},decrypt:function(m,B,_,P){P=this.cfg.extend(P),B=this._parse(B,P.format);var T=m.createDecryptor(_,P).finalize(B.ciphertext);return T},_parse:function(m,B){return typeof m=="string"?B.parse(m,this):m}}),w=a.kdf={},A=w.OpenSSL={execute:function(m,B,_,P,T){if(P||(P=s.random(64/8)),T)var $=d.create({keySize:B+_,hasher:T}).compute(m,P);else var $=d.create({keySize:B+_}).compute(m,P);var H=s.create($.words.slice(B),_*4);return $.sigBytes=B*4,C.create({key:$,iv:H,salt:P})}},S=i.PasswordBasedCipher=E.extend({cfg:E.cfg.extend({kdf:A}),encrypt:function(m,B,_,P){P=this.cfg.extend(P);var T=P.kdf.execute(_,m.keySize,m.ivSize,P.salt,P.hasher);P.iv=T.iv;var $=E.encrypt.call(this,m,B,T.key,P);return $.mixIn(T),$},decrypt:function(m,B,_,P){P=this.cfg.extend(P),B=this._parse(B,P.format);var T=P.kdf.execute(_,m.keySize,m.ivSize,B.salt,P.hasher);P.iv=T.iv;var $=E.decrypt.call(this,m,B,T.key,P);return $}})})()})})(za)),za.exports}var Ha={exports:{}},Im=Ha.exports,wc;function Tm(){return wc||(wc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Im,function(e){return e.mode.CFB=(function(){var n=e.lib.BlockCipherMode.extend();n.Encryptor=n.extend({processBlock:function(i,o){var s=this._cipher,l=s.blockSize;a.call(this,i,o,l,s),this._prevBlock=i.slice(o,o+l)}}),n.Decryptor=n.extend({processBlock:function(i,o){var s=this._cipher,l=s.blockSize,c=i.slice(o,o+l);a.call(this,i,o,l,s),this._prevBlock=c}});function a(i,o,s,l){var c,u=this._iv;u?(c=u.slice(0),this._iv=void 0):c=this._prevBlock,l.encryptBlock(c,0);for(var h=0;h<s;h++)i[o+h]^=c[h]}return n})(),e.mode.CFB})})(Ha)),Ha.exports}var qa={exports:{}},Rm=qa.exports,Sc;function Om(){return Sc||(Sc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Rm,function(e){return e.mode.CTR=(function(){var n=e.lib.BlockCipherMode.extend(),a=n.Encryptor=n.extend({processBlock:function(i,o){var s=this._cipher,l=s.blockSize,c=this._iv,u=this._counter;c&&(u=this._counter=c.slice(0),this._iv=void 0);var h=u.slice(0);s.encryptBlock(h,0),u[l-1]=u[l-1]+1|0;for(var d=0;d<l;d++)i[o+d]^=h[d]}});return n.Decryptor=a,n})(),e.mode.CTR})})(qa)),qa.exports}var ja={exports:{}},Nm=ja.exports,Bc;function Mm(){return Bc||(Bc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Nm,function(e){/** @preserve
329
+ * Counter block mode compatible with Dr Brian Gladman fileenc.c
330
+ * derived from CryptoJS.mode.CTR
331
+ * Jan Hruby jhruby.web@gmail.com
332
+ */return e.mode.CTRGladman=(function(){var n=e.lib.BlockCipherMode.extend();function a(s){if((s>>24&255)===255){var l=s>>16&255,c=s>>8&255,u=s&255;l===255?(l=0,c===255?(c=0,u===255?u=0:++u):++c):++l,s=0,s+=l<<16,s+=c<<8,s+=u}else s+=1<<24;return s}function i(s){return(s[0]=a(s[0]))===0&&(s[1]=a(s[1])),s}var o=n.Encryptor=n.extend({processBlock:function(s,l){var c=this._cipher,u=c.blockSize,h=this._iv,d=this._counter;h&&(d=this._counter=h.slice(0),this._iv=void 0),i(d);var g=d.slice(0);c.encryptBlock(g,0);for(var x=0;x<u;x++)s[l+x]^=g[x]}});return n.Decryptor=o,n})(),e.mode.CTRGladman})})(ja)),ja.exports}var Va={exports:{}},Lm=Va.exports,_c;function $m(){return _c||(_c=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Lm,function(e){return e.mode.OFB=(function(){var n=e.lib.BlockCipherMode.extend(),a=n.Encryptor=n.extend({processBlock:function(i,o){var s=this._cipher,l=s.blockSize,c=this._iv,u=this._keystream;c&&(u=this._keystream=c.slice(0),this._iv=void 0),s.encryptBlock(u,0);for(var h=0;h<l;h++)i[o+h]^=u[h]}});return n.Decryptor=a,n})(),e.mode.OFB})})(Va)),Va.exports}var Ua={exports:{}},zm=Ua.exports,Dc;function Hm(){return Dc||(Dc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(zm,function(e){return e.mode.ECB=(function(){var n=e.lib.BlockCipherMode.extend();return n.Encryptor=n.extend({processBlock:function(a,i){this._cipher.encryptBlock(a,i)}}),n.Decryptor=n.extend({processBlock:function(a,i){this._cipher.decryptBlock(a,i)}}),n})(),e.mode.ECB})})(Ua)),Ua.exports}var Wa={exports:{}},qm=Wa.exports,kc;function jm(){return kc||(kc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(qm,function(e){return e.pad.AnsiX923={pad:function(n,a){var i=n.sigBytes,o=a*4,s=o-i%o,l=i+s-1;n.clamp(),n.words[l>>>2]|=s<<24-l%4*8,n.sigBytes+=s},unpad:function(n){var a=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=a}},e.pad.Ansix923})})(Wa)),Wa.exports}var Ga={exports:{}},Vm=Ga.exports,Pc;function Um(){return Pc||(Pc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Vm,function(e){return e.pad.Iso10126={pad:function(n,a){var i=a*4,o=i-n.sigBytes%i;n.concat(e.lib.WordArray.random(o-1)).concat(e.lib.WordArray.create([o<<24],1))},unpad:function(n){var a=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=a}},e.pad.Iso10126})})(Ga)),Ga.exports}var Ka={exports:{}},Wm=Ka.exports,Ic;function Gm(){return Ic||(Ic=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Wm,function(e){return e.pad.Iso97971={pad:function(n,a){n.concat(e.lib.WordArray.create([2147483648],1)),e.pad.ZeroPadding.pad(n,a)},unpad:function(n){e.pad.ZeroPadding.unpad(n),n.sigBytes--}},e.pad.Iso97971})})(Ka)),Ka.exports}var Xa={exports:{}},Km=Xa.exports,Tc;function Xm(){return Tc||(Tc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Km,function(e){return e.pad.ZeroPadding={pad:function(n,a){var i=a*4;n.clamp(),n.sigBytes+=i-(n.sigBytes%i||i)},unpad:function(n){for(var a=n.words,i=n.sigBytes-1,i=n.sigBytes-1;i>=0;i--)if(a[i>>>2]>>>24-i%4*8&255){n.sigBytes=i+1;break}}},e.pad.ZeroPadding})})(Xa)),Xa.exports}var Ya={exports:{}},Ym=Ya.exports,Rc;function Qm(){return Rc||(Rc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Ym,function(e){return e.pad.NoPadding={pad:function(){},unpad:function(){}},e.pad.NoPadding})})(Ya)),Ya.exports}var Qa={exports:{}},Zm=Qa.exports,Oc;function Jm(){return Oc||(Oc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ft())})(Zm,function(e){return(function(n){var a=e,i=a.lib,o=i.CipherParams,s=a.enc,l=s.Hex,c=a.format;c.Hex={stringify:function(u){return u.ciphertext.toString(l)},parse:function(u){var h=l.parse(u);return o.create({ciphertext:h})}}})(),e.format.Hex})})(Qa)),Qa.exports}var Za={exports:{}},ey=Za.exports,Nc;function ty(){return Nc||(Nc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Kr(),Xr(),Lr(),Ft())})(ey,function(e){return(function(){var n=e,a=n.lib,i=a.BlockCipher,o=n.algo,s=[],l=[],c=[],u=[],h=[],d=[],g=[],x=[],p=[],f=[];(function(){for(var C=[],b=0;b<256;b++)b<128?C[b]=b<<1:C[b]=b<<1^283;for(var F=0,E=0,b=0;b<256;b++){var w=E^E<<1^E<<2^E<<3^E<<4;w=w>>>8^w&255^99,s[F]=w,l[w]=F;var A=C[F],S=C[A],m=C[S],B=C[w]*257^w*16843008;c[F]=B<<24|B>>>8,u[F]=B<<16|B>>>16,h[F]=B<<8|B>>>24,d[F]=B;var B=m*16843009^S*65537^A*257^F*16843008;g[w]=B<<24|B>>>8,x[w]=B<<16|B>>>16,p[w]=B<<8|B>>>24,f[w]=B,F?(F=A^C[C[C[m^A]]],E^=C[C[E]]):F=E=1}})();var y=[0,1,2,4,8,16,32,64,128,27,54],v=o.AES=i.extend({_doReset:function(){var C;if(!(this._nRounds&&this._keyPriorReset===this._key)){for(var b=this._keyPriorReset=this._key,F=b.words,E=b.sigBytes/4,w=this._nRounds=E+6,A=(w+1)*4,S=this._keySchedule=[],m=0;m<A;m++)m<E?S[m]=F[m]:(C=S[m-1],m%E?E>6&&m%E==4&&(C=s[C>>>24]<<24|s[C>>>16&255]<<16|s[C>>>8&255]<<8|s[C&255]):(C=C<<8|C>>>24,C=s[C>>>24]<<24|s[C>>>16&255]<<16|s[C>>>8&255]<<8|s[C&255],C^=y[m/E|0]<<24),S[m]=S[m-E]^C);for(var B=this._invKeySchedule=[],_=0;_<A;_++){var m=A-_;if(_%4)var C=S[m];else var C=S[m-4];_<4||m<=4?B[_]=C:B[_]=g[s[C>>>24]]^x[s[C>>>16&255]]^p[s[C>>>8&255]]^f[s[C&255]]}}},encryptBlock:function(C,b){this._doCryptBlock(C,b,this._keySchedule,c,u,h,d,s)},decryptBlock:function(C,b){var F=C[b+1];C[b+1]=C[b+3],C[b+3]=F,this._doCryptBlock(C,b,this._invKeySchedule,g,x,p,f,l);var F=C[b+1];C[b+1]=C[b+3],C[b+3]=F},_doCryptBlock:function(C,b,F,E,w,A,S,m){for(var B=this._nRounds,_=C[b]^F[0],P=C[b+1]^F[1],T=C[b+2]^F[2],$=C[b+3]^F[3],H=4,j=1;j<B;j++){var q=E[_>>>24]^w[P>>>16&255]^A[T>>>8&255]^S[$&255]^F[H++],G=E[P>>>24]^w[T>>>16&255]^A[$>>>8&255]^S[_&255]^F[H++],X=E[T>>>24]^w[$>>>16&255]^A[_>>>8&255]^S[P&255]^F[H++],O=E[$>>>24]^w[_>>>16&255]^A[P>>>8&255]^S[T&255]^F[H++];_=q,P=G,T=X,$=O}var q=(m[_>>>24]<<24|m[P>>>16&255]<<16|m[T>>>8&255]<<8|m[$&255])^F[H++],G=(m[P>>>24]<<24|m[T>>>16&255]<<16|m[$>>>8&255]<<8|m[_&255])^F[H++],X=(m[T>>>24]<<24|m[$>>>16&255]<<16|m[_>>>8&255]<<8|m[P&255])^F[H++],O=(m[$>>>24]<<24|m[_>>>16&255]<<16|m[P>>>8&255]<<8|m[T&255])^F[H++];C[b]=q,C[b+1]=G,C[b+2]=X,C[b+3]=O},keySize:256/32});n.AES=i._createHelper(v)})(),e.AES})})(Za)),Za.exports}var Ja={exports:{}},ry=Ja.exports,Mc;function ny(){return Mc||(Mc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Kr(),Xr(),Lr(),Ft())})(ry,function(e){return(function(){var n=e,a=n.lib,i=a.WordArray,o=a.BlockCipher,s=n.algo,l=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],c=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],u=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],h=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],d=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],g=s.DES=o.extend({_doReset:function(){for(var y=this._key,v=y.words,C=[],b=0;b<56;b++){var F=l[b]-1;C[b]=v[F>>>5]>>>31-F%32&1}for(var E=this._subKeys=[],w=0;w<16;w++){for(var A=E[w]=[],S=u[w],b=0;b<24;b++)A[b/6|0]|=C[(c[b]-1+S)%28]<<31-b%6,A[4+(b/6|0)]|=C[28+(c[b+24]-1+S)%28]<<31-b%6;A[0]=A[0]<<1|A[0]>>>31;for(var b=1;b<7;b++)A[b]=A[b]>>>(b-1)*4+3;A[7]=A[7]<<5|A[7]>>>27}for(var m=this._invSubKeys=[],b=0;b<16;b++)m[b]=E[15-b]},encryptBlock:function(y,v){this._doCryptBlock(y,v,this._subKeys)},decryptBlock:function(y,v){this._doCryptBlock(y,v,this._invSubKeys)},_doCryptBlock:function(y,v,C){this._lBlock=y[v],this._rBlock=y[v+1],x.call(this,4,252645135),x.call(this,16,65535),p.call(this,2,858993459),p.call(this,8,16711935),x.call(this,1,1431655765);for(var b=0;b<16;b++){for(var F=C[b],E=this._lBlock,w=this._rBlock,A=0,S=0;S<8;S++)A|=h[S][((w^F[S])&d[S])>>>0];this._lBlock=w,this._rBlock=E^A}var m=this._lBlock;this._lBlock=this._rBlock,this._rBlock=m,x.call(this,1,1431655765),p.call(this,8,16711935),p.call(this,2,858993459),x.call(this,16,65535),x.call(this,4,252645135),y[v]=this._lBlock,y[v+1]=this._rBlock},keySize:64/32,ivSize:64/32,blockSize:64/32});function x(y,v){var C=(this._lBlock>>>y^this._rBlock)&v;this._rBlock^=C,this._lBlock^=C<<y}function p(y,v){var C=(this._rBlock>>>y^this._lBlock)&v;this._lBlock^=C,this._rBlock^=C<<y}n.DES=o._createHelper(g);var f=s.TripleDES=o.extend({_doReset:function(){var y=this._key,v=y.words;if(v.length!==2&&v.length!==4&&v.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var C=v.slice(0,2),b=v.length<4?v.slice(0,2):v.slice(2,4),F=v.length<6?v.slice(0,2):v.slice(4,6);this._des1=g.createEncryptor(i.create(C)),this._des2=g.createEncryptor(i.create(b)),this._des3=g.createEncryptor(i.create(F))},encryptBlock:function(y,v){this._des1.encryptBlock(y,v),this._des2.decryptBlock(y,v),this._des3.encryptBlock(y,v)},decryptBlock:function(y,v){this._des3.decryptBlock(y,v),this._des2.encryptBlock(y,v),this._des1.decryptBlock(y,v)},keySize:192/32,ivSize:64/32,blockSize:64/32});n.TripleDES=o._createHelper(f)})(),e.TripleDES})})(Ja)),Ja.exports}var ei={exports:{}},ay=ei.exports,Lc;function iy(){return Lc||(Lc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Kr(),Xr(),Lr(),Ft())})(ay,function(e){return(function(){var n=e,a=n.lib,i=a.StreamCipher,o=n.algo,s=o.RC4=i.extend({_doReset:function(){for(var u=this._key,h=u.words,d=u.sigBytes,g=this._S=[],x=0;x<256;x++)g[x]=x;for(var x=0,p=0;x<256;x++){var f=x%d,y=h[f>>>2]>>>24-f%4*8&255;p=(p+g[x]+y)%256;var v=g[x];g[x]=g[p],g[p]=v}this._i=this._j=0},_doProcessBlock:function(u,h){u[h]^=l.call(this)},keySize:256/32,ivSize:0});function l(){for(var u=this._S,h=this._i,d=this._j,g=0,x=0;x<4;x++){h=(h+1)%256,d=(d+u[h])%256;var p=u[h];u[h]=u[d],u[d]=p,g|=u[(u[h]+u[d])%256]<<24-x*8}return this._i=h,this._j=d,g}n.RC4=i._createHelper(s);var c=o.RC4Drop=s.extend({cfg:s.cfg.extend({drop:192}),_doReset:function(){s._doReset.call(this);for(var u=this.cfg.drop;u>0;u--)l.call(this)}});n.RC4Drop=i._createHelper(c)})(),e.RC4})})(ei)),ei.exports}var ti={exports:{}},oy=ti.exports,$c;function sy(){return $c||($c=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Kr(),Xr(),Lr(),Ft())})(oy,function(e){return(function(){var n=e,a=n.lib,i=a.StreamCipher,o=n.algo,s=[],l=[],c=[],u=o.Rabbit=i.extend({_doReset:function(){for(var d=this._key.words,g=this.cfg.iv,x=0;x<4;x++)d[x]=(d[x]<<8|d[x]>>>24)&16711935|(d[x]<<24|d[x]>>>8)&4278255360;var p=this._X=[d[0],d[3]<<16|d[2]>>>16,d[1],d[0]<<16|d[3]>>>16,d[2],d[1]<<16|d[0]>>>16,d[3],d[2]<<16|d[1]>>>16],f=this._C=[d[2]<<16|d[2]>>>16,d[0]&4294901760|d[1]&65535,d[3]<<16|d[3]>>>16,d[1]&4294901760|d[2]&65535,d[0]<<16|d[0]>>>16,d[2]&4294901760|d[3]&65535,d[1]<<16|d[1]>>>16,d[3]&4294901760|d[0]&65535];this._b=0;for(var x=0;x<4;x++)h.call(this);for(var x=0;x<8;x++)f[x]^=p[x+4&7];if(g){var y=g.words,v=y[0],C=y[1],b=(v<<8|v>>>24)&16711935|(v<<24|v>>>8)&4278255360,F=(C<<8|C>>>24)&16711935|(C<<24|C>>>8)&4278255360,E=b>>>16|F&4294901760,w=F<<16|b&65535;f[0]^=b,f[1]^=E,f[2]^=F,f[3]^=w,f[4]^=b,f[5]^=E,f[6]^=F,f[7]^=w;for(var x=0;x<4;x++)h.call(this)}},_doProcessBlock:function(d,g){var x=this._X;h.call(this),s[0]=x[0]^x[5]>>>16^x[3]<<16,s[1]=x[2]^x[7]>>>16^x[5]<<16,s[2]=x[4]^x[1]>>>16^x[7]<<16,s[3]=x[6]^x[3]>>>16^x[1]<<16;for(var p=0;p<4;p++)s[p]=(s[p]<<8|s[p]>>>24)&16711935|(s[p]<<24|s[p]>>>8)&4278255360,d[g+p]^=s[p]},blockSize:128/32,ivSize:64/32});function h(){for(var d=this._X,g=this._C,x=0;x<8;x++)l[x]=g[x];g[0]=g[0]+1295307597+this._b|0,g[1]=g[1]+3545052371+(g[0]>>>0<l[0]>>>0?1:0)|0,g[2]=g[2]+886263092+(g[1]>>>0<l[1]>>>0?1:0)|0,g[3]=g[3]+1295307597+(g[2]>>>0<l[2]>>>0?1:0)|0,g[4]=g[4]+3545052371+(g[3]>>>0<l[3]>>>0?1:0)|0,g[5]=g[5]+886263092+(g[4]>>>0<l[4]>>>0?1:0)|0,g[6]=g[6]+1295307597+(g[5]>>>0<l[5]>>>0?1:0)|0,g[7]=g[7]+3545052371+(g[6]>>>0<l[6]>>>0?1:0)|0,this._b=g[7]>>>0<l[7]>>>0?1:0;for(var x=0;x<8;x++){var p=d[x]+g[x],f=p&65535,y=p>>>16,v=((f*f>>>17)+f*y>>>15)+y*y,C=((p&4294901760)*p|0)+((p&65535)*p|0);c[x]=v^C}d[0]=c[0]+(c[7]<<16|c[7]>>>16)+(c[6]<<16|c[6]>>>16)|0,d[1]=c[1]+(c[0]<<8|c[0]>>>24)+c[7]|0,d[2]=c[2]+(c[1]<<16|c[1]>>>16)+(c[0]<<16|c[0]>>>16)|0,d[3]=c[3]+(c[2]<<8|c[2]>>>24)+c[1]|0,d[4]=c[4]+(c[3]<<16|c[3]>>>16)+(c[2]<<16|c[2]>>>16)|0,d[5]=c[5]+(c[4]<<8|c[4]>>>24)+c[3]|0,d[6]=c[6]+(c[5]<<16|c[5]>>>16)+(c[4]<<16|c[4]>>>16)|0,d[7]=c[7]+(c[6]<<8|c[6]>>>24)+c[5]|0}n.Rabbit=i._createHelper(u)})(),e.Rabbit})})(ti)),ti.exports}var ri={exports:{}},cy=ri.exports,zc;function uy(){return zc||(zc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Kr(),Xr(),Lr(),Ft())})(cy,function(e){return(function(){var n=e,a=n.lib,i=a.StreamCipher,o=n.algo,s=[],l=[],c=[],u=o.RabbitLegacy=i.extend({_doReset:function(){var d=this._key.words,g=this.cfg.iv,x=this._X=[d[0],d[3]<<16|d[2]>>>16,d[1],d[0]<<16|d[3]>>>16,d[2],d[1]<<16|d[0]>>>16,d[3],d[2]<<16|d[1]>>>16],p=this._C=[d[2]<<16|d[2]>>>16,d[0]&4294901760|d[1]&65535,d[3]<<16|d[3]>>>16,d[1]&4294901760|d[2]&65535,d[0]<<16|d[0]>>>16,d[2]&4294901760|d[3]&65535,d[1]<<16|d[1]>>>16,d[3]&4294901760|d[0]&65535];this._b=0;for(var f=0;f<4;f++)h.call(this);for(var f=0;f<8;f++)p[f]^=x[f+4&7];if(g){var y=g.words,v=y[0],C=y[1],b=(v<<8|v>>>24)&16711935|(v<<24|v>>>8)&4278255360,F=(C<<8|C>>>24)&16711935|(C<<24|C>>>8)&4278255360,E=b>>>16|F&4294901760,w=F<<16|b&65535;p[0]^=b,p[1]^=E,p[2]^=F,p[3]^=w,p[4]^=b,p[5]^=E,p[6]^=F,p[7]^=w;for(var f=0;f<4;f++)h.call(this)}},_doProcessBlock:function(d,g){var x=this._X;h.call(this),s[0]=x[0]^x[5]>>>16^x[3]<<16,s[1]=x[2]^x[7]>>>16^x[5]<<16,s[2]=x[4]^x[1]>>>16^x[7]<<16,s[3]=x[6]^x[3]>>>16^x[1]<<16;for(var p=0;p<4;p++)s[p]=(s[p]<<8|s[p]>>>24)&16711935|(s[p]<<24|s[p]>>>8)&4278255360,d[g+p]^=s[p]},blockSize:128/32,ivSize:64/32});function h(){for(var d=this._X,g=this._C,x=0;x<8;x++)l[x]=g[x];g[0]=g[0]+1295307597+this._b|0,g[1]=g[1]+3545052371+(g[0]>>>0<l[0]>>>0?1:0)|0,g[2]=g[2]+886263092+(g[1]>>>0<l[1]>>>0?1:0)|0,g[3]=g[3]+1295307597+(g[2]>>>0<l[2]>>>0?1:0)|0,g[4]=g[4]+3545052371+(g[3]>>>0<l[3]>>>0?1:0)|0,g[5]=g[5]+886263092+(g[4]>>>0<l[4]>>>0?1:0)|0,g[6]=g[6]+1295307597+(g[5]>>>0<l[5]>>>0?1:0)|0,g[7]=g[7]+3545052371+(g[6]>>>0<l[6]>>>0?1:0)|0,this._b=g[7]>>>0<l[7]>>>0?1:0;for(var x=0;x<8;x++){var p=d[x]+g[x],f=p&65535,y=p>>>16,v=((f*f>>>17)+f*y>>>15)+y*y,C=((p&4294901760)*p|0)+((p&65535)*p|0);c[x]=v^C}d[0]=c[0]+(c[7]<<16|c[7]>>>16)+(c[6]<<16|c[6]>>>16)|0,d[1]=c[1]+(c[0]<<8|c[0]>>>24)+c[7]|0,d[2]=c[2]+(c[1]<<16|c[1]>>>16)+(c[0]<<16|c[0]>>>16)|0,d[3]=c[3]+(c[2]<<8|c[2]>>>24)+c[1]|0,d[4]=c[4]+(c[3]<<16|c[3]>>>16)+(c[2]<<16|c[2]>>>16)|0,d[5]=c[5]+(c[4]<<8|c[4]>>>24)+c[3]|0,d[6]=c[6]+(c[5]<<16|c[5]>>>16)+(c[4]<<16|c[4]>>>16)|0,d[7]=c[7]+(c[6]<<8|c[6]>>>24)+c[5]|0}n.RabbitLegacy=i._createHelper(u)})(),e.RabbitLegacy})})(ri)),ri.exports}var ni={exports:{}},ly=ni.exports,Hc;function fy(){return Hc||(Hc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Kr(),Xr(),Lr(),Ft())})(ly,function(e){return(function(){var n=e,a=n.lib,i=a.BlockCipher,o=n.algo;const s=16,l=[608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731],c=[[3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,2760122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,4246832056,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946],[1266315497,3048417604,3681880366,3289982499,290971e4,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055],[3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,835421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,2819808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504],[976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,4015350505,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988104,1320477388,886195818,18198404,3786409e3,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462]];var u={pbox:[],sbox:[]};function h(f,y){let v=y>>24&255,C=y>>16&255,b=y>>8&255,F=y&255,E=f.sbox[0][v]+f.sbox[1][C];return E=E^f.sbox[2][b],E=E+f.sbox[3][F],E}function d(f,y,v){let C=y,b=v,F;for(let E=0;E<s;++E)C=C^f.pbox[E],b=h(f,C)^b,F=C,C=b,b=F;return F=C,C=b,b=F,b=b^f.pbox[s],C=C^f.pbox[s+1],{left:C,right:b}}function g(f,y,v){let C=y,b=v,F;for(let E=s+1;E>1;--E)C=C^f.pbox[E],b=h(f,C)^b,F=C,C=b,b=F;return F=C,C=b,b=F,b=b^f.pbox[1],C=C^f.pbox[0],{left:C,right:b}}function x(f,y,v){for(let w=0;w<4;w++){f.sbox[w]=[];for(let A=0;A<256;A++)f.sbox[w][A]=c[w][A]}let C=0;for(let w=0;w<s+2;w++)f.pbox[w]=l[w]^y[C],C++,C>=v&&(C=0);let b=0,F=0,E=0;for(let w=0;w<s+2;w+=2)E=d(f,b,F),b=E.left,F=E.right,f.pbox[w]=b,f.pbox[w+1]=F;for(let w=0;w<4;w++)for(let A=0;A<256;A+=2)E=d(f,b,F),b=E.left,F=E.right,f.sbox[w][A]=b,f.sbox[w][A+1]=F;return!0}var p=o.Blowfish=i.extend({_doReset:function(){if(this._keyPriorReset!==this._key){var f=this._keyPriorReset=this._key,y=f.words,v=f.sigBytes/4;x(u,y,v)}},encryptBlock:function(f,y){var v=d(u,f[y],f[y+1]);f[y]=v.left,f[y+1]=v.right},decryptBlock:function(f,y){var v=g(u,f[y],f[y+1]);f[y]=v.left,f[y+1]=v.right},blockSize:64/32,keySize:128/32,ivSize:64/32});n.Blowfish=i._createHelper(p)})(),e.Blowfish})})(ni)),ni.exports}var dy=Fa.exports,qc;function py(){return qc||(qc=1,(function(r,t){(function(e,n,a){r.exports=n(_e(),Ei(),um(),fm(),Kr(),hm(),Xr(),jl(),bs(),ym(),Vl(),Fm(),Am(),Sm(),Fs(),Dm(),Lr(),Ft(),Tm(),Om(),Mm(),$m(),Hm(),jm(),Um(),Gm(),Xm(),Qm(),Jm(),ty(),ny(),iy(),sy(),uy(),fy())})(dy,function(e){return e})})(Fa)),Fa.exports}var hy=py();const Ul=es(hy);Ul.enc.Utf8.parse("1234567890123456");Ul.enc.Utf8.parse("1234567890123456");const Es={login:{usernamePlaceholder:"\u8F93\u5165\u7528\u6237\u540D\u5B57",passwordPlaceholder:"\u8F93\u5165\u5BC6\u7801",verifyCodePlaceholder:"\u8F93\u5165\u9A8C\u8BC1\u7801",usernameRequired:"\u8BF7\u8F93\u5165\u7528\u6237\u540D\u5B57",passwordRequired:"\u8BF7\u8F93\u5165\u5BC6\u7801",verifyCodeRequired:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801",submit:"\u767B\u5F55",errorFallback:"\u767B\u5F55\u5931\u8D25\uFF0C\u8BF7\u7A0D\u540E\u518D\u8BD5"},register:{labels:{username:"\u7528\u6237\u540D",phone:"\u624B\u673A\u53F7",email:"\u90AE\u7BB1",password:"\u5BC6\u7801",confirmPassword:"\u786E\u8BA4\u5BC6\u7801",verifyCode:"\u9A8C\u8BC1\u7801"},placeholders:{username:"\u8F93\u5165\u7528\u6237\u540D\u5B57",phone:"\u8BF7\u8F93\u5165\u624B\u673A\u53F7",email:"\u8F93\u5165\u90AE\u7BB1",password:"\u8BF7\u8F93\u5165\u5BC6\u7801",confirmPassword:"\u8BF7\u786E\u8BA4\u65B0\u5BC6\u7801",verifyCode:"\u8F93\u5165\u9A8C\u8BC1\u7801"},required:{username:"\u8BF7\u8F93\u5165\u540D\u79F0",phone:"\u8BF7\u8F93\u5165\u624B\u673A\u53F7",email:"\u8BF7\u8F93\u5165\u90AE\u7BB1",password:"\u8BF7\u8F93\u5165\u5BC6\u7801",confirmPassword:"\u8BF7\u786E\u8BA4\u65B0\u5BC6\u7801",verifyCode:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801"},cancel:"\u53D6\u6D88",submit:"\u6CE8\u518C",passwordConfirmMismatch:"\u4E24\u6B21\u5BC6\u7801\u4E0D\u4E00\u81F4!"}},vy={login:{usernamePlaceholder:"Enter username",passwordPlaceholder:"Enter password",verifyCodePlaceholder:"Enter verification code",usernameRequired:"Please enter username",passwordRequired:"Please enter password",verifyCodeRequired:"Please enter verification code",submit:"Sign in",errorFallback:"Login failed, please try again later."},register:{labels:{username:"Username",phone:"Phone",email:"Email",password:"Password",confirmPassword:"Confirm password",verifyCode:"Verification code"},placeholders:{username:"Enter username",phone:"Enter phone number",email:"Enter email",password:"Enter password",confirmPassword:"Confirm password",verifyCode:"Enter verification code"},required:{username:"Please enter username",phone:"Please enter phone number",email:"Please enter email",password:"Please enter password",confirmPassword:"Please confirm password",verifyCode:"Please enter verification code"},cancel:"Cancel",submit:"Register",passwordConfirmMismatch:"Passwords do not match."}},xy={login:{usernamePlaceholder:"\u30E6\u30FC\u30B6\u30FC\u540D\u3092\u5165\u529B",passwordPlaceholder:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B",verifyCodePlaceholder:"\u8A8D\u8A3C\u30B3\u30FC\u30C9\u3092\u5165\u529B",usernameRequired:"\u30E6\u30FC\u30B6\u30FC\u540D\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",passwordRequired:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",verifyCodeRequired:"\u8A8D\u8A3C\u30B3\u30FC\u30C9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",submit:"\u30ED\u30B0\u30A4\u30F3",errorFallback:"\u30ED\u30B0\u30A4\u30F3\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002\u3057\u3070\u3089\u304F\u3057\u3066\u304B\u3089\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002"},register:{labels:{username:"\u30E6\u30FC\u30B6\u30FC\u540D",phone:"\u96FB\u8A71\u756A\u53F7",email:"\u30E1\u30FC\u30EB",password:"\u30D1\u30B9\u30EF\u30FC\u30C9",confirmPassword:"\u30D1\u30B9\u30EF\u30FC\u30C9\u78BA\u8A8D",verifyCode:"\u8A8D\u8A3C\u30B3\u30FC\u30C9"},placeholders:{username:"\u30E6\u30FC\u30B6\u30FC\u540D\u3092\u5165\u529B",phone:"\u96FB\u8A71\u756A\u53F7\u3092\u5165\u529B",email:"\u30E1\u30FC\u30EB\u3092\u5165\u529B",password:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B",confirmPassword:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u78BA\u8A8D",verifyCode:"\u8A8D\u8A3C\u30B3\u30FC\u30C9\u3092\u5165\u529B"},required:{username:"\u30E6\u30FC\u30B6\u30FC\u540D\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",phone:"\u96FB\u8A71\u756A\u53F7\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",email:"\u30E1\u30FC\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",password:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",confirmPassword:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044",verifyCode:"\u8A8D\u8A3C\u30B3\u30FC\u30C9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},cancel:"\u30AD\u30E3\u30F3\u30BB\u30EB",submit:"\u767B\u9332",passwordConfirmMismatch:"\u30D1\u30B9\u30EF\u30FC\u30C9\u304C\u4E00\u81F4\u3057\u307E\u305B\u3093\u3002"}},gy={zh:Es,en:vy,ja:xy};function my(r,t){const e=gy[r]??Es;return t?{...e,...t}:e}const Wl=ve.createContext({locale:"zh",messages:Es});function Ky(){return ve.useContext(Wl)}function Xy({locale:r,messages:t,children:e}){const n=ve.useMemo(()=>({locale:r,messages:my(r,t)}),[r,t]);return ve.createElement(Wl.Provider,{value:n},e)}export{ql as D,Xy as L,Wl as a,my as g,Ky as u,Gy as w};