@gientech/modual 1.2.6 → 1.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/index-CXwV5fAx.js +1230 -0
- package/assets/style.css +1 -1
- package/chat.js +1 -1
- package/databaseId.js +1 -1
- package/package.json +1 -1
- package/streamFilesReader.js +2 -2
- package/assets/index-C2Aqh6m1.js +0 -1230
|
@@ -0,0 +1,1230 @@
|
|
|
1
|
+
import*as d from"react";import ee,{forwardRef as dn,useState as yt,useRef as qe,useCallback as mt,useEffect as Ot,version as _w,createElement as ks,useContext as Rr,createContext as Fn,useMemo as xt,Children as Lw,useImperativeHandle as ei,useLayoutEffect as Fb,isValidElement as Hw,cloneElement as Ww,useReducer as Kw,Component as qw,memo as Vw}from"react";import*as Gw from"react-dom";import Wi,{flushSync as ud,unstable_batchedUpdates as Nb,createPortal as Pb}from"react-dom";import{s as ru,I as Pl}from"./index--DG-fVvc.js";var gn={},Xw=Object.defineProperty,Uw=(e,t,r)=>t in e?Xw(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,rr=(e,t,r)=>Uw(e,typeof t!="symbol"?t+"":t,r),jl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function vl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Pm={exports:{}},mi={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react-jsx-runtime.production.min.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var jm;function Yw(){if(jm)return mi;jm=1;var e=ee,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function i(l,s,u){var c,f={},p=null,h=null;u!==void 0&&(p=""+u),s.key!==void 0&&(p=""+s.key),s.ref!==void 0&&(h=s.ref);for(c in s)n.call(s,c)&&!a.hasOwnProperty(c)&&(f[c]=s[c]);if(l&&l.defaultProps)for(c in s=l.defaultProps,s)f[c]===void 0&&(f[c]=s[c]);return{$$typeof:t,type:l,key:p,ref:h,props:f,_owner:o.current}}return mi.Fragment=r,mi.jsx=i,mi.jsxs=i,mi}var Im;function Zw(){return Im||(Im=1,Pm.exports=Yw()),Pm.exports}var Q=Zw();/*!
|
|
10
|
+
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
11
|
+
*
|
|
12
|
+
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
13
|
+
* Released under the MIT License.
|
|
14
|
+
*/function Rm(e){return Object.prototype.toString.call(e)==="[object Object]"}function Vr(e){var t,r;return Rm(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(Rm(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}var jb=Symbol.for("immer-nothing"),Mm=Symbol.for("immer-draftable"),yn=Symbol.for("immer-state");function Rn(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Ra=Object.getPrototypeOf;function Jo(e){return!!e&&!!e[yn]}function Qo(e){var t;return e?Ib(e)||Array.isArray(e)||!!e[Mm]||!!((t=e.constructor)!=null&&t[Mm])||ou(e)||au(e):!1}var Jw=Object.prototype.constructor.toString();function Ib(e){if(!e||typeof e!="object")return!1;const t=Ra(e);if(t===null)return!0;const r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object?!0:typeof r=="function"&&Function.toString.call(r)===Jw}function Ds(e,t){nu(e)===0?Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)}):e.forEach((r,n)=>t(n,r,e))}function nu(e){const t=e[yn];return t?t.type_:Array.isArray(e)?1:ou(e)?2:au(e)?3:0}function cd(e,t){return nu(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Rb(e,t,r){const n=nu(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function Qw(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function ou(e){return e instanceof Map}function au(e){return e instanceof Set}function _o(e){return e.copy_||e.base_}function dd(e,t){if(ou(e))return new Map(e);if(au(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const r=Ib(e);if(t===!0||t==="class_only"&&!r){const n=Object.getOwnPropertyDescriptors(e);delete n[yn];let o=Reflect.ownKeys(n);for(let a=0;a<o.length;a++){const i=o[a],l=n[i];l.writable===!1&&(l.writable=!0,l.configurable=!0),(l.get||l.set)&&(n[i]={configurable:!0,writable:!0,enumerable:l.enumerable,value:e[i]})}return Object.create(Ra(e),n)}else{const n=Ra(e);if(n!==null&&r)return{...e};const o=Object.create(n);return Object.assign(o,e)}}function ep(e,t=!1){return iu(e)||Jo(e)||!Qo(e)||(nu(e)>1&&(e.set=e.add=e.clear=e.delete=eE),Object.freeze(e),t&&Object.entries(e).forEach(([r,n])=>ep(n,!0))),e}function eE(){Rn(2)}function iu(e){return Object.isFrozen(e)}var tE={};function ea(e){const t=tE[e];return t||Rn(0,e),t}var Ki;function Mb(){return Ki}function rE(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Tm(e,t){t&&(ea("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function fd(e){pd(e),e.drafts_.forEach(nE),e.drafts_=null}function pd(e){e===Ki&&(Ki=e.parent_)}function zm(e){return Ki=rE(Ki,e)}function nE(e){const t=e[yn];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function _m(e,t){t.unfinalizedDrafts_=t.drafts_.length;const r=t.drafts_[0];return e!==void 0&&e!==r?(r[yn].modified_&&(fd(t),Rn(4)),Qo(e)&&(e=Ss(t,e),t.parent_||$s(t,e)),t.patches_&&ea("Patches").generateReplacementPatches_(r[yn].base_,e,t.patches_,t.inversePatches_)):e=Ss(t,r,[]),fd(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==jb?e:void 0}function Ss(e,t,r){if(iu(t))return t;const n=t[yn];if(!n)return Ds(t,(o,a)=>Lm(e,n,t,o,a,r)),t;if(n.scope_!==e)return t;if(!n.modified_)return $s(e,n.base_,!0),n.base_;if(!n.finalized_){n.finalized_=!0,n.scope_.unfinalizedDrafts_--;const o=n.copy_;let a=o,i=!1;n.type_===3&&(a=new Set(o),o.clear(),i=!0),Ds(a,(l,s)=>Lm(e,n,o,l,s,r,i)),$s(e,o,!1),r&&e.patches_&&ea("Patches").generatePatches_(n,r,e.patches_,e.inversePatches_)}return n.copy_}function Lm(e,t,r,n,o,a,i){if(Jo(o)){const l=a&&t&&t.type_!==3&&!cd(t.assigned_,n)?a.concat(n):void 0,s=Ss(e,o,l);if(Rb(r,n,s),Jo(s))e.canAutoFreeze_=!1;else return}else i&&r.add(o);if(Qo(o)&&!iu(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Ss(e,o),(!t||!t.scope_.parent_)&&typeof n!="symbol"&&Object.prototype.propertyIsEnumerable.call(r,n)&&$s(e,o)}}function $s(e,t,r=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&ep(t,r)}function oE(e,t){const r=Array.isArray(e),n={type_:r?1:0,scope_:t?t.scope_:Mb(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=n,a=tp;r&&(o=[n],a=qi);const{revoke:i,proxy:l}=Proxy.revocable(o,a);return n.draft_=l,n.revoke_=i,l}var tp={get(e,t){if(t===yn)return e;const r=_o(e);if(!cd(r,t))return aE(e,r,t);const n=r[t];return e.finalized_||!Qo(n)?n:n===Uu(e.base_,t)?(Yu(e),e.copy_[t]=hd(n,e)):n},has(e,t){return t in _o(e)},ownKeys(e){return Reflect.ownKeys(_o(e))},set(e,t,r){const n=Tb(_o(e),t);if(n!=null&&n.set)return n.set.call(e.draft_,r),!0;if(!e.modified_){const o=Uu(_o(e),t),a=o==null?void 0:o[yn];if(a&&a.base_===r)return e.copy_[t]=r,e.assigned_[t]=!1,!0;if(Qw(r,o)&&(r!==void 0||cd(e.base_,t)))return!0;Yu(e),md(e)}return e.copy_[t]===r&&(r!==void 0||t in e.copy_)||Number.isNaN(r)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=r,e.assigned_[t]=!0),!0},deleteProperty(e,t){return Uu(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Yu(e),md(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const r=_o(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty(){Rn(11)},getPrototypeOf(e){return Ra(e.base_)},setPrototypeOf(){Rn(12)}},qi={};Ds(tp,(e,t)=>{qi[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});qi.deleteProperty=function(e,t){return qi.set.call(this,e,t,void 0)};qi.set=function(e,t,r){return tp.set.call(this,e[0],t,r,e[0])};function Uu(e,t){const r=e[yn];return(r?_o(r):e)[t]}function aE(e,t,r){var o;const n=Tb(t,r);return n?"value"in n?n.value:(o=n.get)==null?void 0:o.call(e.draft_):void 0}function Tb(e,t){if(!(t in e))return;let r=Ra(e);for(;r;){const n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Ra(r)}}function md(e){e.modified_||(e.modified_=!0,e.parent_&&md(e.parent_))}function Yu(e){e.copy_||(e.copy_=dd(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var iE=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,r,n)=>{if(typeof t=="function"&&typeof r!="function"){const a=r;r=t;const i=this;return function(l=a,...s){return i.produce(l,u=>r.call(this,u,...s))}}typeof r!="function"&&Rn(6),n!==void 0&&typeof n!="function"&&Rn(7);let o;if(Qo(t)){const a=zm(this),i=hd(t,void 0);let l=!0;try{o=r(i),l=!1}finally{l?fd(a):pd(a)}return Tm(a,n),_m(o,a)}else if(!t||typeof t!="object"){if(o=r(t),o===void 0&&(o=t),o===jb&&(o=void 0),this.autoFreeze_&&ep(o,!0),n){const a=[],i=[];ea("Patches").generateReplacementPatches_(t,o,a,i),n(a,i)}return o}else Rn(1,t)},this.produceWithPatches=(t,r)=>{if(typeof t=="function")return(a,...i)=>this.produceWithPatches(a,l=>t(l,...i));let n,o;return[this.produce(t,r,(a,i)=>{n=a,o=i}),n,o]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){Qo(e)||Rn(8),Jo(e)&&(e=lE(e));const t=zm(this),r=hd(e,void 0);return r[yn].isManual_=!0,pd(t),r}finishDraft(e,t){const r=e&&e[yn];(!r||!r.isManual_)&&Rn(9);const{scope_:n}=r;return Tm(n,t),_m(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let r;for(r=t.length-1;r>=0;r--){const o=t[r];if(o.path.length===0&&o.op==="replace"){e=o.value;break}}r>-1&&(t=t.slice(r+1));const n=ea("Patches").applyPatches_;return Jo(e)?n(e,t):this.produce(e,o=>n(o,t))}};function hd(e,t){const r=ou(e)?ea("MapSet").proxyMap_(e,t):au(e)?ea("MapSet").proxySet_(e,t):oE(e,t);return(t?t.scope_:Mb()).drafts_.push(r),r}function lE(e){return Jo(e)||Rn(10,e),zb(e)}function zb(e){if(!Qo(e)||iu(e))return e;const t=e[yn];let r;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,r=dd(e,t.scope_.immer_.useStrictShallowCopy_)}else r=dd(e,!0);return Ds(r,(n,o)=>{Rb(r,n,zb(o))}),t&&(t.finalized_=!1),r}var Cn=new iE,rp=Cn.produce;Cn.produceWithPatches.bind(Cn);Cn.setAutoFreeze.bind(Cn);Cn.setUseStrictShallowCopy.bind(Cn);Cn.applyPatches.bind(Cn);var Hm=Cn.createDraft.bind(Cn),Wm=Cn.finishDraft.bind(Cn),sE={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=ne.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},uE={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=Rt.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},cE={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=$e.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},Bs=new WeakMap,Os=new WeakMap,Fi=new WeakMap,_b=new WeakMap,Km=new WeakMap,qm=new WeakMap,Vm=new WeakMap,ne={ancestors(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,n=ne.levels(e,t);return r?n=n.slice(1):n=n.slice(0,-1),n},common(e,t){for(var r=[],n=0;n<e.length&&n<t.length;n++){var o=e[n],a=t[n];if(o!==a)break;r.push(o)}return r},compare(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return 0},endsAfter(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),a=e[r],i=t[r];return ne.equals(n,o)&&a>i},endsAt(e,t){var r=e.length,n=e.slice(0,r),o=t.slice(0,r);return ne.equals(n,o)},endsBefore(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),a=e[r],i=t[r];return ne.equals(n,o)&&a<i},equals(e,t){return e.length===t.length&&e.every((r,n)=>r===t[n])},hasPrevious(e){return e[e.length-1]>0},isAfter(e,t){return ne.compare(e,t)===1},isAncestor(e,t){return e.length<t.length&&ne.compare(e,t)===0},isBefore(e,t){return ne.compare(e,t)===-1},isChild(e,t){return e.length===t.length+1&&ne.compare(e,t)===0},isCommon(e,t){return e.length<=t.length&&ne.compare(e,t)===0},isDescendant(e,t){return e.length>t.length&&ne.compare(e,t)===0},isParent(e,t){return e.length+1===t.length&&ne.compare(e,t)===0},isPath(e){return Array.isArray(e)&&(e.length===0||typeof e[0]=="number")},isSibling(e,t){if(e.length!==t.length)return!1;var r=e.slice(0,-1),n=t.slice(0,-1),o=e[e.length-1],a=t[t.length-1];return o!==a&&ne.equals(r,n)},levels(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,n=[],o=0;o<=e.length;o++)n.push(e.slice(0,o));return r&&n.reverse(),n},next(e){if(e.length===0)throw new Error("Cannot get the next path of a root path [".concat(e,"], because it has no next index."));var t=e[e.length-1];return e.slice(0,-1).concat(t+1)},operationCanTransformPath(e){switch(e.type){case"insert_node":case"remove_node":case"merge_node":case"split_node":case"move_node":return!0;default:return!1}},parent(e){if(e.length===0)throw new Error("Cannot get the parent path of the root path [".concat(e,"]."));return e.slice(0,-1)},previous(e){if(e.length===0)throw new Error("Cannot get the previous path of a root path [".concat(e,"], because it has no previous index."));var t=e[e.length-1];if(t<=0)throw new Error("Cannot get the previous path of a first child path [".concat(e,"] because it would result in a negative index."));return e.slice(0,-1).concat(t-1)},relative(e,t){if(!ne.isAncestor(t,e)&&!ne.equals(e,t))throw new Error("Cannot get the relative path of [".concat(e,"] inside ancestor [").concat(t,"], because it is not above or equal to the path."));return e.slice(t.length)},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!e)return null;var n=[...e],{affinity:o="forward"}=r;if(e.length===0)return n;switch(t.type){case"insert_node":{var{path:a}=t;(ne.equals(a,n)||ne.endsBefore(a,n)||ne.isAncestor(a,n))&&(n[a.length-1]+=1);break}case"remove_node":{var{path:i}=t;if(ne.equals(i,n)||ne.isAncestor(i,n))return null;ne.endsBefore(i,n)&&(n[i.length-1]-=1);break}case"merge_node":{var{path:l,position:s}=t;ne.equals(l,n)||ne.endsBefore(l,n)?n[l.length-1]-=1:ne.isAncestor(l,n)&&(n[l.length-1]-=1,n[l.length]+=s);break}case"split_node":{var{path:u,position:c}=t;if(ne.equals(u,n)){if(o==="forward")n[n.length-1]+=1;else if(o!=="backward")return null}else ne.endsBefore(u,n)?n[u.length-1]+=1:ne.isAncestor(u,n)&&e[u.length]>=c&&(n[u.length-1]+=1,n[u.length]-=c);break}case"move_node":{var{path:f,newPath:p}=t;if(ne.equals(f,p))return n;if(ne.isAncestor(f,n)||ne.equals(f,n)){var h=p.slice();return ne.endsBefore(f,p)&&f.length<p.length&&(h[f.length-1]-=1),h.concat(n.slice(f.length))}else ne.isSibling(f,p)&&(ne.isAncestor(p,n)||ne.equals(p,n))?ne.endsBefore(f,n)?n[f.length-1]-=1:n[f.length-1]+=1:ne.endsBefore(p,n)||ne.equals(p,n)||ne.isAncestor(p,n)?(ne.endsBefore(f,n)&&(n[f.length-1]-=1),n[p.length-1]+=1):ne.endsBefore(f,n)&&(ne.equals(p,n)&&(n[p.length-1]+=1),n[f.length-1]-=1);break}}return n}};function Vi(e){"@babel/helpers - typeof";return Vi=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},Vi(e)}function dE(e,t){if(Vi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Vi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function fE(e){var t=dE(e,"string");return Vi(t)==="symbol"?t:String(t)}function rn(e,t,r){return t=fE(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Gm(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function hi(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Gm(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Gm(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var pE=(e,t,r)=>{switch(r.type){case"insert_node":{var{path:n,node:o}=r,a=Ge.parent(e,n),i=n[n.length-1];if(i>a.children.length)throw new Error('Cannot apply an "insert_node" operation at path ['.concat(n,"] because the destination is past the end of the node."));if(a.children.splice(i,0,o),t)for(var[l,s]of $e.points(t))t[s]=Rt.transform(l,r);break}case"insert_text":{var{path:u,offset:c,text:f}=r;if(f.length===0)break;var p=Ge.leaf(e,u),h=p.text.slice(0,c),v=p.text.slice(c);if(p.text=h+f+v,t)for(var[g,m]of $e.points(t))t[m]=Rt.transform(g,r);break}case"merge_node":{var{path:b}=r,y=Ge.get(e,b),C=ne.previous(b),D=Ge.get(e,C),w=Ge.parent(e,b),k=b[b.length-1];if(ot.isText(y)&&ot.isText(D))D.text+=y.text;else if(!ot.isText(y)&&!ot.isText(D))D.children.push(...y.children);else throw new Error('Cannot apply a "merge_node" operation at path ['.concat(b,"] to nodes of different interfaces: ").concat(Ir.stringify(y)," ").concat(Ir.stringify(D)));if(w.children.splice(k,1),t)for(var[E,x]of $e.points(t))t[x]=Rt.transform(E,r);break}case"move_node":{var{path:O,newPath:j}=r;if(ne.isAncestor(O,j))throw new Error("Cannot move a path [".concat(O,"] to new path [").concat(j,"] because the destination is inside itself."));var $=Ge.get(e,O),P=Ge.parent(e,O),A=O[O.length-1];P.children.splice(A,1);var B=ne.transform(O,r),S=Ge.get(e,ne.parent(B)),I=B[B.length-1];if(S.children.splice(I,0,$),t)for(var[N,F]of $e.points(t))t[F]=Rt.transform(N,r);break}case"remove_node":{var{path:M}=r,_=M[M.length-1],X=Ge.parent(e,M);if(X.children.splice(_,1),t)for(var[H,q]of $e.points(t)){var Z=Rt.transform(H,r);if(t!=null&&Z!=null)t[q]=Z;else{var te=void 0,z=void 0;for(var[Y,V]of Ge.texts(e))if(ne.compare(V,M)===-1)te=[Y,V];else{z=[Y,V];break}var U=!1;te&&z&&(ne.equals(z[1],M)?U=!ne.hasPrevious(z[1]):U=ne.common(te[1],M).length<ne.common(z[1],M).length),te&&!U?(H.path=te[1],H.offset=te[0].text.length):z?(H.path=z[1],H.offset=0):t=null}}break}case"remove_text":{var{path:K,offset:W,text:re}=r;if(re.length===0)break;var G=Ge.leaf(e,K),J=G.text.slice(0,W),oe=G.text.slice(W+re.length);if(G.text=J+oe,t)for(var[se,ge]of $e.points(t))t[ge]=Rt.transform(se,r);break}case"set_node":{var{path:Ee,properties:je,newProperties:ve}=r;if(Ee.length===0)throw new Error("Cannot set properties on the root node!");var ye=Ge.get(e,Ee);for(var ke in ve){if(ke==="children"||ke==="text")throw new Error('Cannot set the "'.concat(ke,'" property of nodes!'));var we=ve[ke];we==null?delete ye[ke]:ye[ke]=we}for(var De in je)ve.hasOwnProperty(De)||delete ye[De];break}case"set_selection":{var{newProperties:Ne}=r;if(Ne==null)t=Ne;else{if(t==null){if(!$e.isRange(Ne))throw new Error('Cannot apply an incomplete "set_selection" operation properties '.concat(Ir.stringify(Ne)," when there is no current selection."));t=hi({},Ne)}for(var Oe in Ne){var Xe=Ne[Oe];if(Xe==null){if(Oe==="anchor"||Oe==="focus")throw new Error('Cannot remove the "'.concat(Oe,'" selection property'));delete t[Oe]}else t[Oe]=Xe}}break}case"split_node":{var{path:Le,position:Fe,properties:fe}=r;if(Le.length===0)throw new Error('Cannot apply a "split_node" operation at path ['.concat(Le,"] because the root node cannot be split."));var Be=Ge.get(e,Le),We=Ge.parent(e,Le),Ye=Le[Le.length-1],Ve;if(ot.isText(Be)){var Te=Be.text.slice(0,Fe),it=Be.text.slice(Fe);Be.text=Te,Ve=hi(hi({},fe),{},{text:it})}else{var Ue=Be.children.slice(0,Fe),nt=Be.children.slice(Fe);Be.children=Ue,Ve=hi(hi({},fe),{},{children:nt})}if(We.children.splice(Ye+1,0,Ve),t)for(var[pt,St]of $e.points(t))t[St]=Rt.transform(pt,r);break}}return t},mE={transform(e,t){e.children=Hm(e.children);var r=e.selection&&Hm(e.selection);try{r=pE(e,r,t)}finally{e.children=Wm(e.children),r?e.selection=Jo(r)?Wm(r):r:e.selection=null}}},hE={insertNodes(e,t,r){e.insertNodes(t,r)},liftNodes(e,t){e.liftNodes(t)},mergeNodes(e,t){e.mergeNodes(t)},moveNodes(e,t){e.moveNodes(t)},removeNodes(e,t){e.removeNodes(t)},setNodes(e,t,r){e.setNodes(t,r)},splitNodes(e,t){e.splitNodes(t)},unsetNodes(e,t,r){e.unsetNodes(t,r)},unwrapNodes(e,t){e.unwrapNodes(t)},wrapNodes(e,t,r){e.wrapNodes(t,r)}},gE={collapse(e,t){e.collapse(t)},deselect(e){e.deselect()},move(e,t){e.move(t)},select(e,t){e.select(t)},setPoint(e,t,r){e.setPoint(t,r)},setSelection(e,t){e.setSelection(t)}},Lb=(e,t)=>{for(var r in e){var n=e[r],o=t[r];if(Vr(n)&&Vr(o)){if(!Lb(n,o))return!1}else if(Array.isArray(n)&&Array.isArray(o)){if(n.length!==o.length)return!1;for(var a=0;a<n.length;a++)if(n[a]!==o[a])return!1}else if(n!==o)return!1}for(var i in t)if(e[i]===void 0&&t[i]!==void 0)return!1;return!0};function vE(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function vo(e,t){if(e==null)return{};var r=vE(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var bE=["anchor","focus"];function Xm(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function yE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Xm(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Xm(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var $e={edges(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,{anchor:n,focus:o}=e;return $e.isBackward(e)===r?[n,o]:[o,n]},end(e){var[,t]=$e.edges(e);return t},equals(e,t){return Rt.equals(e.anchor,t.anchor)&&Rt.equals(e.focus,t.focus)},includes(e,t){if($e.isRange(t)){if($e.includes(e,t.anchor)||$e.includes(e,t.focus))return!0;var[r,n]=$e.edges(e),[o,a]=$e.edges(t);return Rt.isBefore(r,o)&&Rt.isAfter(n,a)}var[i,l]=$e.edges(e),s=!1,u=!1;return Rt.isPoint(t)?(s=Rt.compare(t,i)>=0,u=Rt.compare(t,l)<=0):(s=ne.compare(t,i.path)>=0,u=ne.compare(t,l.path)<=0),s&&u},intersection(e,t){var r=vo(e,bE),[n,o]=$e.edges(e),[a,i]=$e.edges(t),l=Rt.isBefore(n,a)?a:n,s=Rt.isBefore(o,i)?o:i;return Rt.isBefore(s,l)?null:yE({anchor:l,focus:s},r)},isBackward(e){var{anchor:t,focus:r}=e;return Rt.isAfter(t,r)},isCollapsed(e){var{anchor:t,focus:r}=e;return Rt.equals(t,r)},isExpanded(e){return!$e.isCollapsed(e)},isForward(e){return!$e.isBackward(e)},isRange(e){return Vr(e)&&Rt.isPoint(e.anchor)&&Rt.isPoint(e.focus)},*points(e){yield[e.anchor,"anchor"],yield[e.focus,"focus"]},start(e){var[t]=$e.edges(e);return t},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return rp(e,n=>{if(n===null)return null;var{affinity:o="inward"}=r,a,i;if(o==="inward"){var l=$e.isCollapsed(n);$e.isForward(n)?(a="forward",i=l?a:"backward"):(a="backward",i=l?a:"forward")}else o==="outward"?$e.isForward(n)?(a="backward",i="forward"):(a="forward",i="backward"):(a=o,i=o);var s=Rt.transform(n.anchor,t,{affinity:a}),u=Rt.transform(n.focus,t,{affinity:i});if(!s||!u)return null;n.anchor=s,n.focus=u})}},Um=e=>Vr(e)&&Ge.isNodeList(e.children)&&!R.isEditor(e),lt={isAncestor(e){return Vr(e)&&Ge.isNodeList(e.children)},isElement:Um,isElementList(e){return Array.isArray(e)&&e.every(t=>lt.isElement(t))},isElementProps(e){return e.children!==void 0},isElementType:function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"type";return Um(e)&&e[r]===t},matches(e,t){for(var r in t)if(r!=="children"&&e[r]!==t[r])return!1;return!0}},CE=["children"],xE=["text"],Ym=new WeakMap,Ge={ancestor(e,t){var r=Ge.get(e,t);if(ot.isText(r))throw new Error("Cannot get the ancestor node at path [".concat(t,"] because it refers to a text node instead: ").concat(Ir.stringify(r)));return r},ancestors(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return(function*(){for(var n of ne.ancestors(t,r)){var o=Ge.ancestor(e,n),a=[o,n];yield a}})()},child(e,t){if(ot.isText(e))throw new Error("Cannot get the child of a text node: ".concat(Ir.stringify(e)));var r=e.children[t];if(r==null)throw new Error("Cannot get child at index `".concat(t,"` in node: ").concat(Ir.stringify(e)));return r},children(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return(function*(){for(var{reverse:n=!1}=r,o=Ge.ancestor(e,t),{children:a}=o,i=n?a.length-1:0;n?i>=0:i<a.length;){var l=Ge.child(o,i),s=t.concat(i);yield[l,s],i=n?i-1:i+1}})()},common(e,t,r){var n=ne.common(t,r),o=Ge.get(e,n);return[o,n]},descendant(e,t){var r=Ge.get(e,t);if(R.isEditor(r))throw new Error("Cannot get the descendant node at path [".concat(t,"] because it refers to the root editor node instead: ").concat(Ir.stringify(r)));return r},descendants(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){for(var[r,n]of Ge.nodes(e,t))n.length!==0&&(yield[r,n])})()},elements(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){for(var[r,n]of Ge.nodes(e,t))lt.isElement(r)&&(yield[r,n])})()},extractProps(e){if(lt.isAncestor(e)){var t=vo(e,CE);return t}else{var t=vo(e,xE);return t}},first(e,t){for(var r=t.slice(),n=Ge.get(e,r);n&&!(ot.isText(n)||n.children.length===0);)n=n.children[0],r.push(0);return[n,r]},fragment(e,t){if(ot.isText(e))throw new Error("Cannot get a fragment starting from a root text node: ".concat(Ir.stringify(e)));var r=rp({children:e.children},n=>{var[o,a]=$e.edges(t),i=Ge.nodes(n,{reverse:!0,pass:p=>{var[,h]=p;return!$e.includes(t,h)}});for(var[,l]of i){if(!$e.includes(t,l)){var s=Ge.parent(n,l),u=l[l.length-1];s.children.splice(u,1)}if(ne.equals(l,a.path)){var c=Ge.leaf(n,l);c.text=c.text.slice(0,a.offset)}if(ne.equals(l,o.path)){var f=Ge.leaf(n,l);f.text=f.text.slice(o.offset)}}R.isEditor(n)&&(n.selection=null)});return r.children},get(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(ot.isText(r)||!r.children[o])throw new Error("Cannot find a descendant at path [".concat(t,"] in node: ").concat(Ir.stringify(e)));r=r.children[o]}return r},has(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(ot.isText(r)||!r.children[o])return!1;r=r.children[o]}return!0},isNode(e){return ot.isText(e)||lt.isElement(e)||R.isEditor(e)},isNodeList(e){if(!Array.isArray(e))return!1;var t=Ym.get(e);if(t!==void 0)return t;var r=e.every(n=>Ge.isNode(n));return Ym.set(e,r),r},last(e,t){for(var r=t.slice(),n=Ge.get(e,r);n&&!(ot.isText(n)||n.children.length===0);){var o=n.children.length-1;n=n.children[o],r.push(o)}return[n,r]},leaf(e,t){var r=Ge.get(e,t);if(!ot.isText(r))throw new Error("Cannot get the leaf node at path [".concat(t,"] because it refers to a non-leaf node: ").concat(Ir.stringify(r)));return r},levels(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return(function*(){for(var n of ne.levels(t,r)){var o=Ge.get(e,n);yield[o,n]}})()},matches(e,t){return lt.isElement(e)&<.isElementProps(t)&<.matches(e,t)||ot.isText(e)&&ot.isTextProps(t)&&ot.matches(e,t)},nodes(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){for(var{pass:r,reverse:n=!1}=t,{from:o=[],to:a}=t,i=new Set,l=[],s=e;!(a&&(n?ne.isBefore(l,a):ne.isAfter(l,a)));){if(i.has(s)||(yield[s,l]),!i.has(s)&&!ot.isText(s)&&s.children.length!==0&&(r==null||r([s,l])===!1)){i.add(s);var u=n?s.children.length-1:0;ne.isAncestor(l,o)&&(u=o[l.length]),l=l.concat(u),s=Ge.get(e,l);continue}if(l.length===0)break;if(!n){var c=ne.next(l);if(Ge.has(e,c)){l=c,s=Ge.get(e,l);continue}}if(n&&l[l.length-1]!==0){var f=ne.previous(l);l=f,s=Ge.get(e,l);continue}l=ne.parent(l),s=Ge.get(e,l),i.add(s)}})()},parent(e,t){var r=ne.parent(t),n=Ge.get(e,r);if(ot.isText(n))throw new Error("Cannot get the parent of path [".concat(t,"] because it does not exist in the root."));return n},string(e){return ot.isText(e)?e.text:e.children.map(Ge.string).join("")},texts(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){for(var[r,n]of Ge.nodes(e,t))ot.isText(r)&&(yield[r,n])})()}};function Zm(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ar(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Zm(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Zm(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Di={isNodeOperation(e){return Di.isOperation(e)&&e.type.endsWith("_node")},isOperation(e){if(!Vr(e))return!1;switch(e.type){case"insert_node":return ne.isPath(e.path)&&Ge.isNode(e.node);case"insert_text":return typeof e.offset=="number"&&typeof e.text=="string"&&ne.isPath(e.path);case"merge_node":return typeof e.position=="number"&&ne.isPath(e.path)&&Vr(e.properties);case"move_node":return ne.isPath(e.path)&&ne.isPath(e.newPath);case"remove_node":return ne.isPath(e.path)&&Ge.isNode(e.node);case"remove_text":return typeof e.offset=="number"&&typeof e.text=="string"&&ne.isPath(e.path);case"set_node":return ne.isPath(e.path)&&Vr(e.properties)&&Vr(e.newProperties);case"set_selection":return e.properties===null&&$e.isRange(e.newProperties)||e.newProperties===null&&$e.isRange(e.properties)||Vr(e.properties)&&Vr(e.newProperties);case"split_node":return ne.isPath(e.path)&&typeof e.position=="number"&&Vr(e.properties);default:return!1}},isOperationList(e){return Array.isArray(e)&&e.every(t=>Di.isOperation(t))},isSelectionOperation(e){return Di.isOperation(e)&&e.type.endsWith("_selection")},isTextOperation(e){return Di.isOperation(e)&&e.type.endsWith("_text")},inverse(e){switch(e.type){case"insert_node":return ar(ar({},e),{},{type:"remove_node"});case"insert_text":return ar(ar({},e),{},{type:"remove_text"});case"merge_node":return ar(ar({},e),{},{type:"split_node",path:ne.previous(e.path)});case"move_node":{var{newPath:t,path:r}=e;if(ne.equals(t,r))return e;if(ne.isSibling(r,t))return ar(ar({},e),{},{path:t,newPath:r});var n=ne.transform(r,e),o=ne.transform(ne.next(r),e);return ar(ar({},e),{},{path:n,newPath:o})}case"remove_node":return ar(ar({},e),{},{type:"insert_node"});case"remove_text":return ar(ar({},e),{},{type:"insert_text"});case"set_node":{var{properties:a,newProperties:i}=e;return ar(ar({},e),{},{properties:i,newProperties:a})}case"set_selection":{var{properties:l,newProperties:s}=e;return l==null?ar(ar({},e),{},{properties:s,newProperties:null}):s==null?ar(ar({},e),{},{properties:null,newProperties:l}):ar(ar({},e),{},{properties:s,newProperties:l})}case"split_node":return ar(ar({},e),{},{type:"merge_node",path:ne.next(e.path)})}}},Jm=new WeakMap,wE=e=>{var t=Jm.get(e);if(t!==void 0)return t;if(!Vr(e))return!1;var r=typeof e.addMark=="function"&&typeof e.apply=="function"&&typeof e.deleteFragment=="function"&&typeof e.insertBreak=="function"&&typeof e.insertSoftBreak=="function"&&typeof e.insertFragment=="function"&&typeof e.insertNode=="function"&&typeof e.insertText=="function"&&typeof e.isElementReadOnly=="function"&&typeof e.isInline=="function"&&typeof e.isSelectable=="function"&&typeof e.isVoid=="function"&&typeof e.normalizeNode=="function"&&typeof e.onChange=="function"&&typeof e.removeMark=="function"&&typeof e.getDirtyPaths=="function"&&(e.marks===null||Vr(e.marks))&&(e.selection===null||$e.isRange(e.selection))&&Ge.isNodeList(e.children)&&Di.isOperationList(e.operations);return Jm.set(e,r),r},R={above(e,t){return e.above(t)},addMark(e,t,r){e.addMark(t,r)},after(e,t,r){return e.after(t,r)},before(e,t,r){return e.before(t,r)},deleteBackward(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{unit:r="character"}=t;e.deleteBackward(r)},deleteForward(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{unit:r="character"}=t;e.deleteForward(r)},deleteFragment(e,t){e.deleteFragment(t)},edges(e,t){return e.edges(t)},elementReadOnly(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.elementReadOnly(t)},end(e,t){return e.end(t)},first(e,t){return e.first(t)},fragment(e,t){return e.fragment(t)},hasBlocks(e,t){return e.hasBlocks(t)},hasInlines(e,t){return e.hasInlines(t)},hasPath(e,t){return e.hasPath(t)},hasTexts(e,t){return e.hasTexts(t)},insertBreak(e){e.insertBreak()},insertFragment(e,t,r){e.insertFragment(t,r)},insertNode(e,t){e.insertNode(t)},insertSoftBreak(e){e.insertSoftBreak()},insertText(e,t){e.insertText(t)},isBlock(e,t){return e.isBlock(t)},isEdge(e,t,r){return e.isEdge(t,r)},isEditor(e){return wE(e)},isElementReadOnly(e,t){return e.isElementReadOnly(t)},isEmpty(e,t){return e.isEmpty(t)},isEnd(e,t,r){return e.isEnd(t,r)},isInline(e,t){return e.isInline(t)},isNormalizing(e){return e.isNormalizing()},isSelectable(e,t){return e.isSelectable(t)},isStart(e,t,r){return e.isStart(t,r)},isVoid(e,t){return e.isVoid(t)},last(e,t){return e.last(t)},leaf(e,t,r){return e.leaf(t,r)},levels(e,t){return e.levels(t)},marks(e){return e.getMarks()},next(e,t){return e.next(t)},node(e,t,r){return e.node(t,r)},nodes(e,t){return e.nodes(t)},normalize(e,t){e.normalize(t)},parent(e,t,r){return e.parent(t,r)},path(e,t,r){return e.path(t,r)},pathRef(e,t,r){return e.pathRef(t,r)},pathRefs(e){return e.pathRefs()},point(e,t,r){return e.point(t,r)},pointRef(e,t,r){return e.pointRef(t,r)},pointRefs(e){return e.pointRefs()},positions(e,t){return e.positions(t)},previous(e,t){return e.previous(t)},range(e,t,r){return e.range(t,r)},rangeRef(e,t,r){return e.rangeRef(t,r)},rangeRefs(e){return e.rangeRefs()},removeMark(e,t){e.removeMark(t)},setNormalizing(e,t){e.setNormalizing(t)},start(e,t){return e.start(t)},string(e,t,r){return e.string(t,r)},unhangRange(e,t,r){return e.unhangRange(t,r)},void(e,t){return e.void(t)},withoutNormalizing(e,t){e.withoutNormalizing(t)},shouldMergeNodesRemovePrevNode:(e,t,r)=>e.shouldMergeNodesRemovePrevNode(t,r)},EE={isSpan(e){return Array.isArray(e)&&e.length===2&&e.every(ne.isPath)}};function Qm(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function eh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Qm(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Qm(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Rt={compare(e,t){var r=ne.compare(e.path,t.path);return r===0?e.offset<t.offset?-1:e.offset>t.offset?1:0:r},isAfter(e,t){return Rt.compare(e,t)===1},isBefore(e,t){return Rt.compare(e,t)===-1},equals(e,t){return e.offset===t.offset&&ne.equals(e.path,t.path)},isPoint(e){return Vr(e)&&typeof e.offset=="number"&&ne.isPath(e.path)},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return rp(e,n=>{if(n===null)return null;var{affinity:o="forward"}=r,{path:a,offset:i}=n;switch(t.type){case"insert_node":case"move_node":{n.path=ne.transform(a,t,r);break}case"insert_text":{ne.equals(t.path,a)&&(t.offset<i||t.offset===i&&o==="forward")&&(n.offset+=t.text.length);break}case"merge_node":{ne.equals(t.path,a)&&(n.offset+=t.position),n.path=ne.transform(a,t,r);break}case"remove_text":{ne.equals(t.path,a)&&t.offset<=i&&(n.offset-=Math.min(i-t.offset,t.text.length));break}case"remove_node":{if(ne.equals(t.path,a)||ne.isAncestor(t.path,a))return null;n.path=ne.transform(a,t,r);break}case"split_node":{if(ne.equals(t.path,a)){if(t.position===i&&o==null)return null;(t.position<i||t.position===i&&o==="forward")&&(n.offset-=t.position,n.path=ne.transform(a,t,eh(eh({},r),{},{affinity:"forward"})))}else n.path=ne.transform(a,t,r);break}}})}},th=void 0,Ir={setScrubber(e){th=e},stringify(e){return JSON.stringify(e,th)}},kE=["text"],DE=["anchor","focus"];function rh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function lo(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?rh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):rh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ot={equals(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{loose:n=!1}=r;function o(a){var i=vo(a,kE);return i}return Lb(n?o(e):e,n?o(t):t)},isText(e){return Vr(e)&&typeof e.text=="string"},isTextList(e){return Array.isArray(e)&&e.every(t=>ot.isText(t))},isTextProps(e){return e.text!==void 0},matches(e,t){for(var r in t)if(r!=="text"&&(!e.hasOwnProperty(r)||e[r]!==t[r]))return!1;return!0},decorations(e,t){var r=[lo({},e)];for(var n of t){var o=vo(n,DE),[a,i]=$e.edges(n),l=[],s=0,u=a.offset,c=i.offset;for(var f of r){var{length:p}=f.text,h=s;if(s+=p,u<=h&&s<=c){Object.assign(f,o),l.push(f);continue}if(u!==c&&(u===s||c===h)||u>s||c<h||c===h&&h!==0){l.push(f);continue}var v=f,g=void 0,m=void 0;if(c<s){var b=c-h;m=lo(lo({},v),{},{text:v.text.slice(b)}),v=lo(lo({},v),{},{text:v.text.slice(0,b)})}if(u>h){var y=u-h;g=lo(lo({},v),{},{text:v.text.slice(0,y)}),v=lo(lo({},v),{},{text:v.text.slice(y)})}Object.assign(v,o),g&&l.push(g),l.push(v),m&&l.push(m)}r=l}return r}},np=e=>e.selection?e.selection:e.children.length>0?R.end(e,[]):[0],ti=(e,t)=>{var[r]=R.node(e,t);return n=>n===r},op=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=!t,n=t?FE(e):e,o=Dt.None,a=Dt.None,i=0,l=null,s=null;for(var u of n){var c=u.codePointAt(0);if(!c)break;var f=WE(u,c);if([o,a]=r?[a,f]:[f,o],ka(o,Dt.ZWJ)&&ka(a,Dt.ExtPict)&&(r?l=nh(e.substring(0,i)):l=nh(e.substring(0,e.length-i)),!l)||ka(o,Dt.RI)&&ka(a,Dt.RI)&&(s!==null?s=!s:r?s=!0:s=XE(e.substring(0,e.length-i)),!s)||o!==Dt.None&&a!==Dt.None&&qE(o,a))break;i+=u.length}return i||1},SE=/\s/,$E=/[\u002B\u0021-\u0023\u0025-\u002A\u002C-\u002F\u003A\u003B\u003F\u0040\u005B-\u005D\u005F\u007B\u007D\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E3B\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,BE=/['\u2018\u2019]/,OE=function(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=0,n=!1;e.length>0;){var o=op(e,t),[a,i]=ap(e,o,t);if(AE(a,i,t))n=!0,r+=o;else if(!n)r+=o;else break;e=i}return r},ap=(e,t,r)=>{if(r){var n=e.length-t;return[e.slice(n,e.length),e.slice(0,n)]}return[e.slice(0,t),e.slice(t)]},AE=function e(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(SE.test(t))return!1;if(BE.test(t)){var o=op(r,n),[a,i]=ap(r,o,n);if(e(a,i,n))return!0}return!$E.test(t)},FE=function*(e){for(var t=e.length-1,r=0;r<e.length;r++){var n=e.charAt(t-r);if(PE(n.charCodeAt(0))){var o=e.charAt(t-r-1);if(NE(o.charCodeAt(0))){yield o+n,r++;continue}}yield n}},NE=e=>e>=55296&&e<=56319,PE=e=>e>=56320&&e<=57343,Dt;(function(e){e[e.None=0]="None",e[e.Extend=1]="Extend",e[e.ZWJ=2]="ZWJ",e[e.RI=4]="RI",e[e.Prepend=8]="Prepend",e[e.SpacingMark=16]="SpacingMark",e[e.L=32]="L",e[e.V=64]="V",e[e.T=128]="T",e[e.LV=256]="LV",e[e.LVT=512]="LVT",e[e.ExtPict=1024]="ExtPict",e[e.Any=2048]="Any"})(Dt||(Dt={}));var jE=/^(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDEFD-\uDEFF\uDF46-\uDF50\uDF82-\uDF85]|\uD804[\uDC01\uDC38-\uDC46\uDC70\uDC73\uDC74\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDCC2\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDE41\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4\uDF00\uDF01\uDF36-\uDF3A\uDF40\uDF42]|\uD80D[\uDC40\uDC47-\uDC55]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD833[\uDF00-\uDF2D\uDF30-\uDF46]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDC8F\uDD30-\uDD36\uDEAE\uDEEC-\uDEEF]|\uD839[\uDCEC-\uDCEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])$/,IE=/^(?:[\u0600-\u0605\u06DD\u070F\u0890\u0891\u08E2\u0D4E]|\uD804[\uDCBD\uDCCD\uDDC2\uDDC3]|\uD806[\uDD3F\uDD41\uDE3A\uDE84-\uDE89]|\uD807\uDD46)$/,RE=/^(?:[\u0903\u093B\u093E-\u0940\u0949-\u094C\u094E\u094F\u0982\u0983\u09BF\u09C0\u09C7\u09C8\u09CB\u09CC\u0A03\u0A3E-\u0A40\u0A83\u0ABE-\u0AC0\u0AC9\u0ACB\u0ACC\u0B02\u0B03\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0C01-\u0C03\u0C41-\u0C44\u0C82\u0C83\u0CBE\u0CC0\u0CC1\u0CC3\u0CC4\u0CC7\u0CC8\u0CCA\u0CCB\u0D02\u0D03\u0D3F\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D82\u0D83\u0DD0\u0DD1\u0DD8-\u0DDE\u0DF2\u0DF3\u0E33\u0EB3\u0F3E\u0F3F\u0F7F\u1031\u103B\u103C\u1056\u1057\u1084\u1715\u1734\u17B6\u17BE-\u17C5\u17C7\u17C8\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1A19\u1A1A\u1A55\u1A57\u1A6D-\u1A72\u1B04\u1B3B\u1B3D-\u1B41\u1B43\u1B44\u1B82\u1BA1\u1BA6\u1BA7\u1BAA\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1C24-\u1C2B\u1C34\u1C35\u1CE1\u1CF7\uA823\uA824\uA827\uA880\uA881\uA8B4-\uA8C3\uA952\uA953\uA983\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9C0\uAA2F\uAA30\uAA33\uAA34\uAA4D\uAAEB\uAAEE\uAAEF\uAAF5\uABE3\uABE4\uABE6\uABE7\uABE9\uABEA\uABEC]|\uD804[\uDC00\uDC02\uDC82\uDCB0-\uDCB2\uDCB7\uDCB8\uDD2C\uDD45\uDD46\uDD82\uDDB3-\uDDB5\uDDBF\uDDC0\uDDCE\uDE2C-\uDE2E\uDE32\uDE33\uDE35\uDEE0-\uDEE2\uDF02\uDF03\uDF3F\uDF41-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF62\uDF63]|\uD805[\uDC35-\uDC37\uDC40\uDC41\uDC45\uDCB1\uDCB2\uDCB9\uDCBB\uDCBC\uDCBE\uDCC1\uDDB0\uDDB1\uDDB8-\uDDBB\uDDBE\uDE30-\uDE32\uDE3B\uDE3C\uDE3E\uDEAC\uDEAE\uDEAF\uDEB6\uDF26]|\uD806[\uDC2C-\uDC2E\uDC38\uDD31-\uDD35\uDD37\uDD38\uDD3D\uDD40\uDD42\uDDD1-\uDDD3\uDDDC-\uDDDF\uDDE4\uDE39\uDE57\uDE58\uDE97]|\uD807[\uDC2F\uDC3E\uDCA9\uDCB1\uDCB4\uDD8A-\uDD8E\uDD93\uDD94\uDD96\uDEF5\uDEF6]|\uD81B[\uDF51-\uDF87\uDFF0\uDFF1]|\uD834[\uDD66\uDD6D])$/,ME=/^[\u1100-\u115F\uA960-\uA97C]$/,TE=/^[\u1160-\u11A7\uD7B0-\uD7C6]$/,zE=/^[\u11A8-\u11FF\uD7CB-\uD7FB]$/,_E=/^[\uAC00\uAC1C\uAC38\uAC54\uAC70\uAC8C\uACA8\uACC4\uACE0\uACFC\uAD18\uAD34\uAD50\uAD6C\uAD88\uADA4\uADC0\uADDC\uADF8\uAE14\uAE30\uAE4C\uAE68\uAE84\uAEA0\uAEBC\uAED8\uAEF4\uAF10\uAF2C\uAF48\uAF64\uAF80\uAF9C\uAFB8\uAFD4\uAFF0\uB00C\uB028\uB044\uB060\uB07C\uB098\uB0B4\uB0D0\uB0EC\uB108\uB124\uB140\uB15C\uB178\uB194\uB1B0\uB1CC\uB1E8\uB204\uB220\uB23C\uB258\uB274\uB290\uB2AC\uB2C8\uB2E4\uB300\uB31C\uB338\uB354\uB370\uB38C\uB3A8\uB3C4\uB3E0\uB3FC\uB418\uB434\uB450\uB46C\uB488\uB4A4\uB4C0\uB4DC\uB4F8\uB514\uB530\uB54C\uB568\uB584\uB5A0\uB5BC\uB5D8\uB5F4\uB610\uB62C\uB648\uB664\uB680\uB69C\uB6B8\uB6D4\uB6F0\uB70C\uB728\uB744\uB760\uB77C\uB798\uB7B4\uB7D0\uB7EC\uB808\uB824\uB840\uB85C\uB878\uB894\uB8B0\uB8CC\uB8E8\uB904\uB920\uB93C\uB958\uB974\uB990\uB9AC\uB9C8\uB9E4\uBA00\uBA1C\uBA38\uBA54\uBA70\uBA8C\uBAA8\uBAC4\uBAE0\uBAFC\uBB18\uBB34\uBB50\uBB6C\uBB88\uBBA4\uBBC0\uBBDC\uBBF8\uBC14\uBC30\uBC4C\uBC68\uBC84\uBCA0\uBCBC\uBCD8\uBCF4\uBD10\uBD2C\uBD48\uBD64\uBD80\uBD9C\uBDB8\uBDD4\uBDF0\uBE0C\uBE28\uBE44\uBE60\uBE7C\uBE98\uBEB4\uBED0\uBEEC\uBF08\uBF24\uBF40\uBF5C\uBF78\uBF94\uBFB0\uBFCC\uBFE8\uC004\uC020\uC03C\uC058\uC074\uC090\uC0AC\uC0C8\uC0E4\uC100\uC11C\uC138\uC154\uC170\uC18C\uC1A8\uC1C4\uC1E0\uC1FC\uC218\uC234\uC250\uC26C\uC288\uC2A4\uC2C0\uC2DC\uC2F8\uC314\uC330\uC34C\uC368\uC384\uC3A0\uC3BC\uC3D8\uC3F4\uC410\uC42C\uC448\uC464\uC480\uC49C\uC4B8\uC4D4\uC4F0\uC50C\uC528\uC544\uC560\uC57C\uC598\uC5B4\uC5D0\uC5EC\uC608\uC624\uC640\uC65C\uC678\uC694\uC6B0\uC6CC\uC6E8\uC704\uC720\uC73C\uC758\uC774\uC790\uC7AC\uC7C8\uC7E4\uC800\uC81C\uC838\uC854\uC870\uC88C\uC8A8\uC8C4\uC8E0\uC8FC\uC918\uC934\uC950\uC96C\uC988\uC9A4\uC9C0\uC9DC\uC9F8\uCA14\uCA30\uCA4C\uCA68\uCA84\uCAA0\uCABC\uCAD8\uCAF4\uCB10\uCB2C\uCB48\uCB64\uCB80\uCB9C\uCBB8\uCBD4\uCBF0\uCC0C\uCC28\uCC44\uCC60\uCC7C\uCC98\uCCB4\uCCD0\uCCEC\uCD08\uCD24\uCD40\uCD5C\uCD78\uCD94\uCDB0\uCDCC\uCDE8\uCE04\uCE20\uCE3C\uCE58\uCE74\uCE90\uCEAC\uCEC8\uCEE4\uCF00\uCF1C\uCF38\uCF54\uCF70\uCF8C\uCFA8\uCFC4\uCFE0\uCFFC\uD018\uD034\uD050\uD06C\uD088\uD0A4\uD0C0\uD0DC\uD0F8\uD114\uD130\uD14C\uD168\uD184\uD1A0\uD1BC\uD1D8\uD1F4\uD210\uD22C\uD248\uD264\uD280\uD29C\uD2B8\uD2D4\uD2F0\uD30C\uD328\uD344\uD360\uD37C\uD398\uD3B4\uD3D0\uD3EC\uD408\uD424\uD440\uD45C\uD478\uD494\uD4B0\uD4CC\uD4E8\uD504\uD520\uD53C\uD558\uD574\uD590\uD5AC\uD5C8\uD5E4\uD600\uD61C\uD638\uD654\uD670\uD68C\uD6A8\uD6C4\uD6E0\uD6FC\uD718\uD734\uD750\uD76C\uD788]$/,LE=/^[\uAC01-\uAC1B\uAC1D-\uAC37\uAC39-\uAC53\uAC55-\uAC6F\uAC71-\uAC8B\uAC8D-\uACA7\uACA9-\uACC3\uACC5-\uACDF\uACE1-\uACFB\uACFD-\uAD17\uAD19-\uAD33\uAD35-\uAD4F\uAD51-\uAD6B\uAD6D-\uAD87\uAD89-\uADA3\uADA5-\uADBF\uADC1-\uADDB\uADDD-\uADF7\uADF9-\uAE13\uAE15-\uAE2F\uAE31-\uAE4B\uAE4D-\uAE67\uAE69-\uAE83\uAE85-\uAE9F\uAEA1-\uAEBB\uAEBD-\uAED7\uAED9-\uAEF3\uAEF5-\uAF0F\uAF11-\uAF2B\uAF2D-\uAF47\uAF49-\uAF63\uAF65-\uAF7F\uAF81-\uAF9B\uAF9D-\uAFB7\uAFB9-\uAFD3\uAFD5-\uAFEF\uAFF1-\uB00B\uB00D-\uB027\uB029-\uB043\uB045-\uB05F\uB061-\uB07B\uB07D-\uB097\uB099-\uB0B3\uB0B5-\uB0CF\uB0D1-\uB0EB\uB0ED-\uB107\uB109-\uB123\uB125-\uB13F\uB141-\uB15B\uB15D-\uB177\uB179-\uB193\uB195-\uB1AF\uB1B1-\uB1CB\uB1CD-\uB1E7\uB1E9-\uB203\uB205-\uB21F\uB221-\uB23B\uB23D-\uB257\uB259-\uB273\uB275-\uB28F\uB291-\uB2AB\uB2AD-\uB2C7\uB2C9-\uB2E3\uB2E5-\uB2FF\uB301-\uB31B\uB31D-\uB337\uB339-\uB353\uB355-\uB36F\uB371-\uB38B\uB38D-\uB3A7\uB3A9-\uB3C3\uB3C5-\uB3DF\uB3E1-\uB3FB\uB3FD-\uB417\uB419-\uB433\uB435-\uB44F\uB451-\uB46B\uB46D-\uB487\uB489-\uB4A3\uB4A5-\uB4BF\uB4C1-\uB4DB\uB4DD-\uB4F7\uB4F9-\uB513\uB515-\uB52F\uB531-\uB54B\uB54D-\uB567\uB569-\uB583\uB585-\uB59F\uB5A1-\uB5BB\uB5BD-\uB5D7\uB5D9-\uB5F3\uB5F5-\uB60F\uB611-\uB62B\uB62D-\uB647\uB649-\uB663\uB665-\uB67F\uB681-\uB69B\uB69D-\uB6B7\uB6B9-\uB6D3\uB6D5-\uB6EF\uB6F1-\uB70B\uB70D-\uB727\uB729-\uB743\uB745-\uB75F\uB761-\uB77B\uB77D-\uB797\uB799-\uB7B3\uB7B5-\uB7CF\uB7D1-\uB7EB\uB7ED-\uB807\uB809-\uB823\uB825-\uB83F\uB841-\uB85B\uB85D-\uB877\uB879-\uB893\uB895-\uB8AF\uB8B1-\uB8CB\uB8CD-\uB8E7\uB8E9-\uB903\uB905-\uB91F\uB921-\uB93B\uB93D-\uB957\uB959-\uB973\uB975-\uB98F\uB991-\uB9AB\uB9AD-\uB9C7\uB9C9-\uB9E3\uB9E5-\uB9FF\uBA01-\uBA1B\uBA1D-\uBA37\uBA39-\uBA53\uBA55-\uBA6F\uBA71-\uBA8B\uBA8D-\uBAA7\uBAA9-\uBAC3\uBAC5-\uBADF\uBAE1-\uBAFB\uBAFD-\uBB17\uBB19-\uBB33\uBB35-\uBB4F\uBB51-\uBB6B\uBB6D-\uBB87\uBB89-\uBBA3\uBBA5-\uBBBF\uBBC1-\uBBDB\uBBDD-\uBBF7\uBBF9-\uBC13\uBC15-\uBC2F\uBC31-\uBC4B\uBC4D-\uBC67\uBC69-\uBC83\uBC85-\uBC9F\uBCA1-\uBCBB\uBCBD-\uBCD7\uBCD9-\uBCF3\uBCF5-\uBD0F\uBD11-\uBD2B\uBD2D-\uBD47\uBD49-\uBD63\uBD65-\uBD7F\uBD81-\uBD9B\uBD9D-\uBDB7\uBDB9-\uBDD3\uBDD5-\uBDEF\uBDF1-\uBE0B\uBE0D-\uBE27\uBE29-\uBE43\uBE45-\uBE5F\uBE61-\uBE7B\uBE7D-\uBE97\uBE99-\uBEB3\uBEB5-\uBECF\uBED1-\uBEEB\uBEED-\uBF07\uBF09-\uBF23\uBF25-\uBF3F\uBF41-\uBF5B\uBF5D-\uBF77\uBF79-\uBF93\uBF95-\uBFAF\uBFB1-\uBFCB\uBFCD-\uBFE7\uBFE9-\uC003\uC005-\uC01F\uC021-\uC03B\uC03D-\uC057\uC059-\uC073\uC075-\uC08F\uC091-\uC0AB\uC0AD-\uC0C7\uC0C9-\uC0E3\uC0E5-\uC0FF\uC101-\uC11B\uC11D-\uC137\uC139-\uC153\uC155-\uC16F\uC171-\uC18B\uC18D-\uC1A7\uC1A9-\uC1C3\uC1C5-\uC1DF\uC1E1-\uC1FB\uC1FD-\uC217\uC219-\uC233\uC235-\uC24F\uC251-\uC26B\uC26D-\uC287\uC289-\uC2A3\uC2A5-\uC2BF\uC2C1-\uC2DB\uC2DD-\uC2F7\uC2F9-\uC313\uC315-\uC32F\uC331-\uC34B\uC34D-\uC367\uC369-\uC383\uC385-\uC39F\uC3A1-\uC3BB\uC3BD-\uC3D7\uC3D9-\uC3F3\uC3F5-\uC40F\uC411-\uC42B\uC42D-\uC447\uC449-\uC463\uC465-\uC47F\uC481-\uC49B\uC49D-\uC4B7\uC4B9-\uC4D3\uC4D5-\uC4EF\uC4F1-\uC50B\uC50D-\uC527\uC529-\uC543\uC545-\uC55F\uC561-\uC57B\uC57D-\uC597\uC599-\uC5B3\uC5B5-\uC5CF\uC5D1-\uC5EB\uC5ED-\uC607\uC609-\uC623\uC625-\uC63F\uC641-\uC65B\uC65D-\uC677\uC679-\uC693\uC695-\uC6AF\uC6B1-\uC6CB\uC6CD-\uC6E7\uC6E9-\uC703\uC705-\uC71F\uC721-\uC73B\uC73D-\uC757\uC759-\uC773\uC775-\uC78F\uC791-\uC7AB\uC7AD-\uC7C7\uC7C9-\uC7E3\uC7E5-\uC7FF\uC801-\uC81B\uC81D-\uC837\uC839-\uC853\uC855-\uC86F\uC871-\uC88B\uC88D-\uC8A7\uC8A9-\uC8C3\uC8C5-\uC8DF\uC8E1-\uC8FB\uC8FD-\uC917\uC919-\uC933\uC935-\uC94F\uC951-\uC96B\uC96D-\uC987\uC989-\uC9A3\uC9A5-\uC9BF\uC9C1-\uC9DB\uC9DD-\uC9F7\uC9F9-\uCA13\uCA15-\uCA2F\uCA31-\uCA4B\uCA4D-\uCA67\uCA69-\uCA83\uCA85-\uCA9F\uCAA1-\uCABB\uCABD-\uCAD7\uCAD9-\uCAF3\uCAF5-\uCB0F\uCB11-\uCB2B\uCB2D-\uCB47\uCB49-\uCB63\uCB65-\uCB7F\uCB81-\uCB9B\uCB9D-\uCBB7\uCBB9-\uCBD3\uCBD5-\uCBEF\uCBF1-\uCC0B\uCC0D-\uCC27\uCC29-\uCC43\uCC45-\uCC5F\uCC61-\uCC7B\uCC7D-\uCC97\uCC99-\uCCB3\uCCB5-\uCCCF\uCCD1-\uCCEB\uCCED-\uCD07\uCD09-\uCD23\uCD25-\uCD3F\uCD41-\uCD5B\uCD5D-\uCD77\uCD79-\uCD93\uCD95-\uCDAF\uCDB1-\uCDCB\uCDCD-\uCDE7\uCDE9-\uCE03\uCE05-\uCE1F\uCE21-\uCE3B\uCE3D-\uCE57\uCE59-\uCE73\uCE75-\uCE8F\uCE91-\uCEAB\uCEAD-\uCEC7\uCEC9-\uCEE3\uCEE5-\uCEFF\uCF01-\uCF1B\uCF1D-\uCF37\uCF39-\uCF53\uCF55-\uCF6F\uCF71-\uCF8B\uCF8D-\uCFA7\uCFA9-\uCFC3\uCFC5-\uCFDF\uCFE1-\uCFFB\uCFFD-\uD017\uD019-\uD033\uD035-\uD04F\uD051-\uD06B\uD06D-\uD087\uD089-\uD0A3\uD0A5-\uD0BF\uD0C1-\uD0DB\uD0DD-\uD0F7\uD0F9-\uD113\uD115-\uD12F\uD131-\uD14B\uD14D-\uD167\uD169-\uD183\uD185-\uD19F\uD1A1-\uD1BB\uD1BD-\uD1D7\uD1D9-\uD1F3\uD1F5-\uD20F\uD211-\uD22B\uD22D-\uD247\uD249-\uD263\uD265-\uD27F\uD281-\uD29B\uD29D-\uD2B7\uD2B9-\uD2D3\uD2D5-\uD2EF\uD2F1-\uD30B\uD30D-\uD327\uD329-\uD343\uD345-\uD35F\uD361-\uD37B\uD37D-\uD397\uD399-\uD3B3\uD3B5-\uD3CF\uD3D1-\uD3EB\uD3ED-\uD407\uD409-\uD423\uD425-\uD43F\uD441-\uD45B\uD45D-\uD477\uD479-\uD493\uD495-\uD4AF\uD4B1-\uD4CB\uD4CD-\uD4E7\uD4E9-\uD503\uD505-\uD51F\uD521-\uD53B\uD53D-\uD557\uD559-\uD573\uD575-\uD58F\uD591-\uD5AB\uD5AD-\uD5C7\uD5C9-\uD5E3\uD5E5-\uD5FF\uD601-\uD61B\uD61D-\uD637\uD639-\uD653\uD655-\uD66F\uD671-\uD68B\uD68D-\uD6A7\uD6A9-\uD6C3\uD6C5-\uD6DF\uD6E1-\uD6FB\uD6FD-\uD717\uD719-\uD733\uD735-\uD74F\uD751-\uD76B\uD76D-\uD787\uD789-\uD7A3]$/,HE=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])$/,WE=(e,t)=>{var r=Dt.Any;return e.search(jE)!==-1&&(r|=Dt.Extend),t===8205&&(r|=Dt.ZWJ),t>=127462&&t<=127487&&(r|=Dt.RI),e.search(IE)!==-1&&(r|=Dt.Prepend),e.search(RE)!==-1&&(r|=Dt.SpacingMark),e.search(ME)!==-1&&(r|=Dt.L),e.search(TE)!==-1&&(r|=Dt.V),e.search(zE)!==-1&&(r|=Dt.T),e.search(_E)!==-1&&(r|=Dt.LV),e.search(LE)!==-1&&(r|=Dt.LVT),e.search(HE)!==-1&&(r|=Dt.ExtPict),r};function ka(e,t){return(e&t)!==0}var KE=[[Dt.L,Dt.L|Dt.V|Dt.LV|Dt.LVT],[Dt.LV|Dt.V,Dt.V|Dt.T],[Dt.LVT|Dt.T,Dt.T],[Dt.Any,Dt.Extend|Dt.ZWJ],[Dt.Any,Dt.SpacingMark],[Dt.Prepend,Dt.Any],[Dt.ZWJ,Dt.ExtPict],[Dt.RI,Dt.RI]];function qE(e,t){return KE.findIndex(r=>ka(e,r[0])&&ka(t,r[1]))===-1}var VE=/(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDEFD-\uDEFF\uDF46-\uDF50\uDF82-\uDF85]|\uD804[\uDC01\uDC38-\uDC46\uDC70\uDC73\uDC74\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDCC2\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDE41\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4\uDF00\uDF01\uDF36-\uDF3A\uDF40\uDF42]|\uD80D[\uDC40\uDC47-\uDC55]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD833[\uDF00-\uDF2D\uDF30-\uDF46]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDC8F\uDD30-\uDD36\uDEAE\uDEEC-\uDEEF]|\uD839[\uDCEC-\uDCEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])*\u200D$/,nh=e=>e.search(VE)!==-1,GE=/(?:\uD83C[\uDDE6-\uDDFF])+$/g,XE=e=>{var t=e.match(GE);if(t===null)return!1;var r=t[0].length/2;return r%2===1},UE={delete(e,t){e.delete(t)},insertFragment(e,t,r){e.insertFragment(t,r)},insertText(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};R.withoutNormalizing(e,()=>{var{voids:n=!1}=r,{at:o=np(e)}=r;if(ne.isPath(o)&&(o=R.range(e,o)),$e.isRange(o))if($e.isCollapsed(o))o=o.anchor;else{var a=$e.end(o);if(!n&&R.void(e,{at:a}))return;var i=$e.start(o),l=R.pointRef(e,i),s=R.pointRef(e,a);Re.delete(e,{at:o,voids:n});var u=l.unref(),c=s.unref();o=u||c,Re.setSelection(e,{anchor:o,focus:o})}if(!(!n&&R.void(e,{at:o})||R.elementReadOnly(e,{at:o}))){var{path:f,offset:p}=o;t.length>0&&e.apply({type:"insert_text",path:f,offset:p,text:t})}})}};function oh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Il(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?oh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):oh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Re=Il(Il(Il(Il({},mE),hE),gE),UE),ns=new WeakMap,YE=e=>ns.get(e)||!1,ZE=(e,t,r)=>{var n=ns.get(e)||!1;ns.set(e,!0);try{t(),r()}finally{ns.set(e,n)}};function Hb(e,t,r){var n=Bs.get(e)||[],o=Os.get(e)||new Set,a,i,l=f=>{if(f){var p=f.join(",");i.has(p)||(i.add(p),a.push(f))}};if(r){a=[],i=new Set;for(var s of n){var u=r(s);l(u)}}else a=n,i=o;for(var c of t)l(c);Bs.set(e,a),Os.set(e,i)}var JE=(e,t)=>{for(var r of R.pathRefs(e))sE.transform(r,t);for(var n of R.pointRefs(e))uE.transform(n,t);for(var o of R.rangeRefs(e))cE.transform(o,t);if(!YE(e)){var a=ne.operationCanTransformPath(t)?i=>ne.transform(i,t):void 0;Hb(e,e.getDirtyPaths(t),a)}Re.transform(e,t),e.operations.push(t),R.normalize(e,{operation:t}),t.type==="set_selection"&&(e.marks=null),Fi.get(e)||(Fi.set(e,!0),Promise.resolve().then(()=>{Fi.set(e,!1),e.onChange({operation:t}),e.operations=[]}))},QE=(e,t)=>{switch(t.type){case"insert_text":case"remove_text":case"set_node":{var{path:r}=t;return ne.levels(r)}case"insert_node":{var{node:n,path:o}=t,a=ne.levels(o),i=ot.isText(n)?[]:Array.from(Ge.nodes(n),j=>{var[,$]=j;return o.concat($)});return[...a,...i]}case"merge_node":{var{path:l}=t,s=ne.ancestors(l),u=ne.previous(l);return[...s,u]}case"move_node":{var{path:c,newPath:f}=t;if(ne.equals(c,f))return[];var p=[],h=[];for(var v of ne.ancestors(c)){var g=ne.transform(v,t);p.push(g)}for(var m of ne.ancestors(f)){var b=ne.transform(m,t);h.push(b)}var y=h[h.length-1],C=f[f.length-1],D=y.concat(C);return[...p,...h,D]}case"remove_node":{var{path:w}=t,k=ne.ancestors(w);return[...k]}case"split_node":{var{path:E}=t,x=ne.levels(E),O=ne.next(E);return[...x,O]}default:return[]}},ek=e=>{var{selection:t}=e;return t?Ge.fragment(e,t):[]},tk=(e,t)=>{var[r,n]=t;if(!ot.isText(r)){if(lt.isElement(r)&&r.children.length===0){var o={text:""};Re.insertNodes(e,o,{at:n.concat(0),voids:!0});return}for(var a=R.isEditor(r)?!1:lt.isElement(r)&&(e.isInline(r)||r.children.length===0||ot.isText(r.children[0])||e.isInline(r.children[0])),i=0,l=0;l<r.children.length;l++,i++){var s=Ge.get(e,n);if(!ot.isText(s)){var u=s.children[i],c=s.children[i-1],f=l===r.children.length-1,p=ot.isText(u)||lt.isElement(u)&&e.isInline(u);if(p!==a)Re.removeNodes(e,{at:n.concat(i),voids:!0}),i--;else if(lt.isElement(u)){if(e.isInline(u)){if(c==null||!ot.isText(c)){var h={text:""};Re.insertNodes(e,h,{at:n.concat(i),voids:!0}),i++}else if(f){var v={text:""};Re.insertNodes(e,v,{at:n.concat(i+1),voids:!0}),i++}}}else{if(!ot.isText(u)&&!("children"in u)){var g=u;g.children=[]}c!=null&&ot.isText(c)&&(ot.equals(u,c,{loose:!0})?(Re.mergeNodes(e,{at:n.concat(i),voids:!0}),i--):c.text===""?(Re.removeNodes(e,{at:n.concat(i-1),voids:!0}),i--):u.text===""&&(Re.removeNodes(e,{at:n.concat(i),voids:!0}),i--))}}}}},rk=(e,t)=>{var{iteration:r,initialDirtyPathsLength:n}=t,o=n*42;if(r>o)throw new Error("Could not completely normalize the editor after ".concat(o," iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state."));return!0},nk=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{voids:r=!1,mode:n="lowest",at:o=e.selection,match:a}=t;if(o){var i=R.path(e,o),l=n==="lowest";for(var[s,u]of R.levels(e,{at:i,voids:r,match:a,reverse:l}))if(!ot.isText(s)){if($e.isRange(o)){if(ne.isAncestor(u,o.anchor.path)&&ne.isAncestor(u,o.focus.path))return[s,u]}else if(!ne.equals(i,u))return[s,u]}}};function ah(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ih(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ah(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ah(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ok=(e,t,r)=>{var{selection:n}=e;if(n){var o=(f,p)=>{if(!ot.isText(f))return!1;var[h,v]=R.parent(e,p);return!e.isVoid(h)||e.markableVoid(h)},a=$e.isExpanded(n),i=!1;if(!a){var[l,s]=R.node(e,n);if(l&&o(l,s)){var[u]=R.parent(e,s);i=u&&e.markableVoid(u)}}if(a||i)Re.setNodes(e,{[t]:r},{match:o,split:!0,voids:!0});else{var c=ih(ih({},R.marks(e)||{}),{},{[t]:r});e.marks=c,Fi.get(e)||e.onChange()}}};function lh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function sh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ak=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=R.point(e,t,{edge:"end"}),o=R.end(e,[]),a={anchor:n,focus:o},{distance:i=1}=r,l=0,s;for(var u of R.positions(e,sh(sh({},r),{},{at:a}))){if(l>i)break;l!==0&&(s=u),l++}return s};function uh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ch(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?uh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):uh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ik=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=R.start(e,[]),o=R.point(e,t,{edge:"start"}),a={anchor:n,focus:o},{distance:i=1}=r,l=0,s;for(var u of R.positions(e,ch(ch({},r),{},{at:a,reverse:!0}))){if(l>i)break;l!==0&&(s=u),l++}return s},lk=(e,t)=>{var{selection:r}=e;r&&$e.isCollapsed(r)&&Re.delete(e,{unit:t,reverse:!0})},sk=(e,t)=>{var{selection:r}=e;r&&$e.isCollapsed(r)&&Re.delete(e,{unit:t})},uk=function(e){var{direction:t="forward"}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{selection:r}=e;r&&$e.isExpanded(r)&&Re.delete(e,{reverse:t==="backward"})},ck=(e,t)=>[R.start(e,t),R.end(e,t)];function dh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function fh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?dh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var dk=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return R.above(e,fh(fh({},t),{},{match:r=>lt.isElement(r)&&R.isElementReadOnly(e,r)}))},fk=(e,t)=>R.point(e,t,{edge:"end"}),pk=(e,t)=>{var r=R.path(e,t,{edge:"start"});return R.node(e,r)},mk=(e,t)=>{var r=R.range(e,t);return Ge.fragment(e,r)};function ph(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function mh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ph(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ph(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var hk=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return R.above(e,mh(mh({},t),{},{match:r=>lt.isElement(r)&&R.isVoid(e,r)}))},gk=(e,t)=>t.children.some(r=>lt.isElement(r)&&R.isBlock(e,r)),vk=(e,t)=>t.children.some(r=>ot.isText(r)||R.isInline(e,r)),bk=(e,t)=>Ge.has(e,t),yk=(e,t)=>t.children.every(r=>ot.isText(r)),Ck=e=>{Re.splitNodes(e,{always:!0})},xk=(e,t,r)=>{Re.insertNodes(e,t,r)},wk=e=>{Re.splitNodes(e,{always:!0})};function hh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ek(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var kk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{selection:n,marks:o}=e;if(n){if(o){var a=Ek({text:t},o);Re.insertNodes(e,a,{at:r.at,voids:r.voids})}else Re.insertText(e,t,r);e.marks=null}},Dk=(e,t)=>!e.isInline(t),Sk=(e,t,r)=>R.isStart(e,t,r)||R.isEnd(e,t,r),$k=(e,t)=>{var{children:r}=t,[n]=r;return r.length===0||r.length===1&&ot.isText(n)&&n.text===""&&!e.isVoid(t)},Bk=(e,t,r)=>{var n=R.end(e,r);return Rt.equals(t,n)},Ok=e=>{var t=_b.get(e);return t===void 0?!0:t},Ak=(e,t,r)=>{if(t.offset!==0)return!1;var n=R.start(e,r);return Rt.equals(t,n)},Fk=(e,t)=>{var r=R.path(e,t,{edge:"end"});return R.node(e,r)},Nk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=R.path(e,t,r),o=Ge.leaf(e,n);return[o,n]};function Pk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){var{at:r=e.selection,reverse:n=!1,voids:o=!1}=t,{match:a}=t;if(a==null&&(a=()=>!0),!!r){var i=[],l=R.path(e,r);for(var[s,u]of Ge.levels(e,l))if(a(s,u)&&(i.push([s,u]),!o&<.isElement(s)&&R.isVoid(e,s)))break;n&&i.reverse(),yield*i}})()}var jk=["text"],Ik=["text"],Rk=function(e){var{marks:t,selection:r}=e;if(!r)return null;var{anchor:n,focus:o}=r;if(t)return t;if($e.isExpanded(r)){var a=R.isEnd(e,n,n.path);if(a){var i=R.after(e,n);i&&(n=i)}var[l]=R.nodes(e,{match:ot.isText,at:{anchor:n,focus:o}});if(l){var[s]=l,u=vo(s,jk);return u}else return{}}var{path:c}=n,[f]=R.leaf(e,c);if(n.offset===0){var p=R.previous(e,{at:c,match:ot.isText}),h=R.above(e,{match:C=>lt.isElement(C)&&R.isVoid(e,C)&&e.markableVoid(C)});if(!h){var v=R.above(e,{match:C=>lt.isElement(C)&&R.isBlock(e,C)});if(p&&v){var[g,m]=p,[,b]=v;ne.isAncestor(b,m)&&(f=g)}}}var y=vo(f,Ik);return y},Mk=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:r="lowest",voids:n=!1}=t,{match:o,at:a=e.selection}=t;if(a){var i=R.after(e,a,{voids:n});if(i){var[,l]=R.last(e,[]),s=[i.path,l];if(ne.isPath(a)&&a.length===0)throw new Error("Cannot get the next node from the root node!");if(o==null)if(ne.isPath(a)){var[u]=R.parent(e,a);o=f=>u.children.includes(f)}else o=()=>!0;var[c]=R.nodes(e,{at:s,match:o,mode:r,voids:n});return c}}},Tk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=R.path(e,t,r),o=Ge.get(e,n);return[o,n]};function zk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){var{at:r=e.selection,mode:n="all",universal:o=!1,reverse:a=!1,voids:i=!1,ignoreNonSelectable:l=!1}=t,{match:s}=t;if(s||(s=()=>!0),!!r){var u,c;if(EE.isSpan(r))u=r[0],c=r[1];else{var f=R.path(e,r,{edge:"start"}),p=R.path(e,r,{edge:"end"});u=a?p:f,c=a?f:p}var h=Ge.nodes(e,{reverse:a,from:u,to:c,pass:D=>{var[w]=D;return lt.isElement(w)?!!(!i&&(R.isVoid(e,w)||R.isElementReadOnly(e,w))||l&&!R.isSelectable(e,w)):!1}}),v=[],g;for(var[m,b]of h)if(!(l&<.isElement(m)&&!R.isSelectable(e,m))){var y=g&&ne.compare(b,g[1])===0;if(!(n==="highest"&&y)){if(!s(m,b)){if(o&&!y&&ot.isText(m))return;continue}if(n==="lowest"&&y){g=[m,b];continue}var C=n==="lowest"?g:[m,b];C&&(o?v.push(C):yield C),g=[m,b]}}n==="lowest"&&g&&(o?v.push(g):yield g),o&&(yield*v)}})()}var _k=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{force:r=!1,operation:n}=t,o=u=>Bs.get(u)||[],a=u=>Os.get(u)||new Set,i=u=>{var c=o(u).pop(),f=c.join(",");return a(u).delete(f),c};if(R.isNormalizing(e)){if(r){var l=Array.from(Ge.nodes(e),u=>{var[,c]=u;return c}),s=new Set(l.map(u=>u.join(",")));Bs.set(e,l),Os.set(e,s)}o(e).length!==0&&R.withoutNormalizing(e,()=>{for(var u of o(e))if(Ge.has(e,u)){var c=R.node(e,u),[f,p]=c;lt.isElement(f)&&f.children.length===0&&e.normalizeNode(c,{operation:n})}for(var h=o(e),v=h.length,g=0;h.length!==0;){if(!e.shouldNormalize({dirtyPaths:h,iteration:g,initialDirtyPathsLength:v,operation:n}))return;var m=i(e);if(Ge.has(e,m)){var b=R.node(e,m);e.normalizeNode(b,{operation:n})}g++,h=o(e)}})}},Lk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=R.path(e,t,r),o=ne.parent(n),a=R.node(e,o);return a},Hk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:i}=o,l=R.pathRefs(e);return l.delete(o),o.current=null,i}},a=R.pathRefs(e);return a.add(o),o},Wk=e=>{var t=Km.get(e);return t||(t=new Set,Km.set(e,t)),t},Kk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{depth:n,edge:o}=r;if(ne.isPath(t)){if(o==="start"){var[,a]=Ge.first(e,t);t=a}else if(o==="end"){var[,i]=Ge.last(e,t);t=i}}return $e.isRange(t)&&(o==="start"?t=$e.start(t):o==="end"?t=$e.end(t):t=ne.common(t.anchor.path,t.focus.path)),Rt.isPoint(t)&&(t=t.path),n!=null&&(t=t.slice(0,n)),t},qk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:i}=o,l=R.pointRefs(e);return l.delete(o),o.current=null,i}},a=R.pointRefs(e);return a.add(o),o},Vk=e=>{var t=qm.get(e);return t||(t=new Set,qm.set(e,t)),t},Gk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{edge:n="start"}=r;if(ne.isPath(t)){var o;if(n==="end"){var[,a]=Ge.last(e,t);o=a}else{var[,i]=Ge.first(e,t);o=i}var l=Ge.get(e,o);if(!ot.isText(l))throw new Error("Cannot get the ".concat(n," point in the node at path [").concat(t,"] because it has no ").concat(n," text node."));return{path:o,offset:n==="end"?l.text.length:0}}if($e.isRange(t)){var[s,u]=$e.edges(t);return n==="start"?s:u}return t};function Xk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(function*(){var{at:r=e.selection,unit:n="offset",reverse:o=!1,voids:a=!1,ignoreNonSelectable:i=!1}=t;if(!r)return;var l=R.range(e,r),[s,u]=$e.edges(l),c=o?u:s,f=!1,p="",h=0,v=0,g=0;for(var[m,b]of R.nodes(e,{at:r,reverse:o,voids:a,ignoreNonSelectable:i})){if(lt.isElement(m)){if(!a&&(e.isVoid(m)||e.isElementReadOnly(m))){yield R.start(e,b);continue}if(e.isInline(m))continue;if(R.hasInlines(e,m)){var y=ne.isAncestor(b,u.path)?u:R.end(e,b),C=ne.isAncestor(b,s.path)?s:R.start(e,b);p=R.string(e,{anchor:C,focus:y},{voids:a}),f=!0}}if(ot.isText(m)){var D=ne.equals(b,c.path);for(D?(v=o?c.offset:m.text.length-c.offset,g=c.offset):(v=m.text.length,g=o?v:0),(D||f||n==="offset")&&(yield{path:b,offset:g},f=!1);;){if(h===0){if(p==="")break;h=w(p,n,o),p=ap(p,h,o)[1]}if(g=o?g-h:g+h,v=v-h,v<0){h=-v;break}h=0,yield{path:b,offset:g}}}}function w(k,E,x){return E==="character"?op(k,x):E==="word"?OE(k,x):E==="line"||E==="block"?k.length:1}})()}var Uk=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:r="lowest",voids:n=!1}=t,{match:o,at:a=e.selection}=t;if(a){var i=R.before(e,a,{voids:n});if(i){var[,l]=R.first(e,[]),s=[i.path,l];if(ne.isPath(a)&&a.length===0)throw new Error("Cannot get the previous node from the root node!");if(o==null)if(ne.isPath(a)){var[u]=R.parent(e,a);o=f=>u.children.includes(f)}else o=()=>!0;var[c]=R.nodes(e,{reverse:!0,at:s,match:o,mode:r,voids:n});return c}}},Yk=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:i}=o,l=R.rangeRefs(e);return l.delete(o),o.current=null,i}},a=R.rangeRefs(e);return a.add(o),o},Zk=e=>{var t=Vm.get(e);return t||(t=new Set,Vm.set(e,t)),t},Jk=(e,t,r)=>{if($e.isRange(t)&&!r)return t;var n=R.start(e,t),o=R.end(e,r||t);return{anchor:n,focus:o}};function gh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Qk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?gh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):gh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var eD=(e,t)=>{var{selection:r}=e;if(r){var n=(c,f)=>{if(!ot.isText(c))return!1;var[p,h]=R.parent(e,f);return!e.isVoid(p)||e.markableVoid(p)},o=$e.isExpanded(r),a=!1;if(!o){var[i,l]=R.node(e,r);if(i&&n(i,l)){var[s]=R.parent(e,l);a=s&&e.markableVoid(s)}}if(o||a)Re.unsetNodes(e,t,{match:n,split:!0,voids:!0});else{var u=Qk({},R.marks(e)||{});delete u[t],e.marks=u,Fi.get(e)||e.onChange()}}},tD=(e,t)=>{_b.set(e,t)},rD=(e,t)=>R.point(e,t,{edge:"start"}),nD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:n=!1}=r,o=R.range(e,t),[a,i]=$e.edges(o),l="";for(var[s,u]of R.nodes(e,{at:o,match:ot.isText,voids:n})){var c=s.text;ne.equals(u,i.path)&&(c=c.slice(0,i.offset)),ne.equals(u,a.path)&&(c=c.slice(a.offset)),l+=c}return l},oD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:n=!1}=r,[o,a]=$e.edges(t);if(o.offset!==0||a.offset!==0||$e.isCollapsed(t)||ne.hasPrevious(a.path))return t;var i=R.above(e,{at:a,match:h=>lt.isElement(h)&&R.isBlock(e,h),voids:n}),l=i?i[1]:[],s=R.start(e,o),u={anchor:s,focus:a},c=!0;for(var[f,p]of R.nodes(e,{at:u,match:ot.isText,reverse:!0,voids:n})){if(c){c=!1;continue}if(f.text!==""||ne.isBefore(p,l)){a={path:p,offset:f.text.length};break}}return{anchor:o,focus:a}},aD=(e,t)=>{var r=R.isNormalizing(e);R.setNormalizing(e,!1);try{t()}finally{R.setNormalizing(e,r)}R.normalize(e)},iD=(e,t,r)=>{var[n,o]=t;return lt.isElement(n)&&R.isEmpty(e,n)||ot.isText(n)&&n.text===""&&o[o.length-1]!==0},lD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};R.withoutNormalizing(e,()=>{var r,n,{reverse:o=!1,unit:a="character",distance:i=1,voids:l=!1}=t,{at:s=e.selection,hanging:u=!1}=t;if(s){var c=!1;if($e.isRange(s)&&$e.isCollapsed(s)&&(c=!0,s=s.anchor),Rt.isPoint(s)){var f=R.void(e,{at:s,mode:"highest"});if(!l&&f){var[,p]=f;s=p}else{var h={unit:a,distance:i},v=o?R.before(e,s,h)||R.start(e,[]):R.after(e,s,h)||R.end(e,[]);s={anchor:s,focus:v},u=!0}}if(ne.isPath(s)){Re.removeNodes(e,{at:s,voids:l});return}if(!$e.isCollapsed(s)){if(!u){var[,g]=$e.edges(s),m=R.end(e,[]);Rt.equals(g,m)||(s=R.unhangRange(e,s,{voids:l}))}var[b,y]=$e.edges(s),C=R.above(e,{match:G=>lt.isElement(G)&&R.isBlock(e,G),at:b,voids:l}),D=R.above(e,{match:G=>lt.isElement(G)&&R.isBlock(e,G),at:y,voids:l}),w=C&&D&&!ne.equals(C[1],D[1]),k=ne.equals(b.path,y.path),E=l?null:(r=R.void(e,{at:b,mode:"highest"}))!==null&&r!==void 0?r:R.elementReadOnly(e,{at:b,mode:"highest"}),x=l?null:(n=R.void(e,{at:y,mode:"highest"}))!==null&&n!==void 0?n:R.elementReadOnly(e,{at:y,mode:"highest"});if(E){var O=R.before(e,b);O&&C&&ne.isAncestor(C[1],O.path)&&(b=O)}if(x){var j=R.after(e,y);j&&D&&ne.isAncestor(D[1],j.path)&&(y=j)}var $=[],P;for(var A of R.nodes(e,{at:s,voids:l})){var[B,S]=A;P&&ne.compare(S,P)===0||(!l&<.isElement(B)&&(R.isVoid(e,B)||R.isElementReadOnly(e,B))||!ne.isCommon(S,b.path)&&!ne.isCommon(S,y.path))&&($.push(A),P=S)}var I=Array.from($,G=>{var[,J]=G;return R.pathRef(e,J)}),N=R.pointRef(e,b),F=R.pointRef(e,y),M="";if(!k&&!E){var _=N.current,[X]=R.leaf(e,_),{path:H}=_,{offset:q}=b,Z=X.text.slice(q);Z.length>0&&(e.apply({type:"remove_text",path:H,offset:q,text:Z}),M=Z)}if(I.reverse().map(G=>G.unref()).filter(G=>G!==null).forEach(G=>Re.removeNodes(e,{at:G,voids:l})),!x){var te=F.current,[z]=R.leaf(e,te),{path:Y}=te,V=k?b.offset:0,U=z.text.slice(V,y.offset);U.length>0&&(e.apply({type:"remove_text",path:Y,offset:V,text:U}),M=U)}!k&&w&&F.current&&N.current&&Re.mergeNodes(e,{at:F.current,hanging:!0,voids:l}),c&&o&&a==="character"&&M.length>1&&M.match(/[\u0E00-\u0E7F]+/)&&Re.insertText(e,M.slice(0,M.length-i));var K=N.unref(),W=F.unref(),re=o?K||W:W||K;t.at==null&&re&&Re.select(e,re)}}})},sD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};R.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:o=!1}=r,{at:a=np(e),batchDirty:i=!0}=r;if(t.length){if($e.isRange(a))if(n||(a=R.unhangRange(e,a,{voids:o})),$e.isCollapsed(a))a=a.anchor;else{var[,l]=$e.edges(a);if(!o&&R.void(e,{at:l}))return;var s=R.pointRef(e,l);Re.delete(e,{at:a}),a=s.unref()}else ne.isPath(a)&&(a=R.start(e,a));if(!(!o&&R.void(e,{at:a}))){var u=R.above(e,{at:a,match:Z=>lt.isElement(Z)&&R.isInline(e,Z),mode:"highest",voids:o});if(u){var[,c]=u;if(R.isEnd(e,a,c)){var f=R.after(e,c);a=f}else if(R.isStart(e,a,c)){var p=R.before(e,c);a=p}}var h=R.above(e,{match:Z=>lt.isElement(Z)&&R.isBlock(e,Z),at:a,voids:o}),[,v]=h,g=R.isStart(e,a,v),m=R.isEnd(e,a,v),b=g&&m,y=!g||g&&m,C=!m,[,D]=Ge.first({children:t},[]),[,w]=Ge.last({children:t},[]),k=[],E=Z=>{var[te,z]=Z,Y=z.length===0;return Y?!1:b?!0:!(y&&ne.isAncestor(z,D)&<.isElement(te)&&!e.isVoid(te)&&!e.isInline(te)||C&&ne.isAncestor(z,w)&<.isElement(te)&&!e.isVoid(te)&&!e.isInline(te))};for(var x of Ge.nodes({children:t},{pass:E}))E(x)&&k.push(x);var O=[],j=[],$=[],P=!0,A=!1;for(var[B]of k)lt.isElement(B)&&!e.isInline(B)?(P=!1,A=!0,j.push(B)):P?O.push(B):$.push(B);var[S]=R.nodes(e,{at:a,match:Z=>ot.isText(Z)||R.isInline(e,Z),mode:"highest",voids:o}),[,I]=S,N=R.isStart(e,a,I),F=R.isEnd(e,a,I),M=R.pathRef(e,m&&!$.length?ne.next(v):v),_=R.pathRef(e,F?ne.next(I):I);Re.splitNodes(e,{at:a,match:Z=>A?lt.isElement(Z)&&R.isBlock(e,Z):ot.isText(Z)||R.isInline(e,Z),mode:A?"lowest":"highest",always:A&&(!g||O.length>0)&&(!m||$.length>0),voids:o});var X=R.pathRef(e,!N||N&&F?ne.next(I):I);if(Re.insertNodes(e,O,{at:X.current,match:Z=>ot.isText(Z)||R.isInline(e,Z),mode:"highest",voids:o,batchDirty:i}),b&&!O.length&&j.length&&!$.length&&Re.delete(e,{at:v,voids:o}),Re.insertNodes(e,j,{at:M.current,match:Z=>lt.isElement(Z)&&R.isBlock(e,Z),mode:"lowest",voids:o,batchDirty:i}),Re.insertNodes(e,$,{at:_.current,match:Z=>ot.isText(Z)||R.isInline(e,Z),mode:"highest",voids:o,batchDirty:i}),!r.at){var H;if($.length>0&&_.current?H=ne.previous(_.current):j.length>0&&M.current?H=ne.previous(M.current):X.current&&(H=ne.previous(X.current)),H){var q=R.end(e,H);Re.select(e,q)}}X.unref(),M.unref(),_.unref()}}})},uD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{edge:r="anchor"}=t,{selection:n}=e;if(n){if(r==="anchor")Re.select(e,n.anchor);else if(r==="focus")Re.select(e,n.focus);else if(r==="start"){var[o]=$e.edges(n);Re.select(e,o)}else if(r==="end"){var[,a]=$e.edges(n);Re.select(e,a)}}else return},cD=e=>{var{selection:t}=e;t&&e.apply({type:"set_selection",properties:t,newProperties:null})},dD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{selection:r}=e,{distance:n=1,unit:o="character",reverse:a=!1}=t,{edge:i=null}=t;if(r){i==="start"&&(i=$e.isBackward(r)?"focus":"anchor"),i==="end"&&(i=$e.isBackward(r)?"anchor":"focus");var{anchor:l,focus:s}=r,u={distance:n,unit:o,ignoreNonSelectable:!0},c={};if(i==null||i==="anchor"){var f=a?R.before(e,l,u):R.after(e,l,u);f&&(c.anchor=f)}if(i==null||i==="focus"){var p=a?R.before(e,s,u):R.after(e,s,u);p&&(c.focus=p)}Re.setSelection(e,c)}},fD=(e,t)=>{var{selection:r}=e;if(t=R.range(e,t),r){Re.setSelection(e,t);return}if(!$e.isRange(t))throw new Error("When setting the selection and the current selection is `null` you must provide at least an `anchor` and `focus`, but you passed: ".concat(Ir.stringify(t)));e.apply({type:"set_selection",properties:r,newProperties:t})};function vh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function bh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?vh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):vh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var pD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{selection:n}=e,{edge:o="both"}=r;if(n){o==="start"&&(o=$e.isBackward(n)?"focus":"anchor"),o==="end"&&(o=$e.isBackward(n)?"anchor":"focus");var{anchor:a,focus:i}=n,l=o==="anchor"?a:i;Re.setSelection(e,{[o==="anchor"?"anchor":"focus"]:bh(bh({},l),t)})}},mD=(e,t)=>{var{selection:r}=e,n={},o={};if(r){for(var a in t)(a==="anchor"&&t.anchor!=null&&!Rt.equals(t.anchor,r.anchor)||a==="focus"&&t.focus!=null&&!Rt.equals(t.focus,r.focus)||a!=="anchor"&&a!=="focus"&&t[a]!==r[a])&&(n[a]=r[a],o[a]=t[a]);Object.keys(n).length>0&&e.apply({type:"set_selection",properties:n,newProperties:o})}},hD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};R.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:o=!1,mode:a="lowest",batchDirty:i=!0}=r,{at:l,match:s,select:u}=r;if(Ge.isNode(t)&&(t=[t]),t.length!==0){var[c]=t;if(l||(l=np(e),u!==!1&&(u=!0)),u==null&&(u=!1),$e.isRange(l))if(n||(l=R.unhangRange(e,l,{voids:o})),$e.isCollapsed(l))l=l.anchor;else{var[,f]=$e.edges(l),p=R.pointRef(e,f);Re.delete(e,{at:l}),l=p.unref()}if(Rt.isPoint(l)){s==null&&(ot.isText(c)?s=O=>ot.isText(O):e.isInline(c)?s=O=>ot.isText(O)||R.isInline(e,O):s=O=>lt.isElement(O)&&R.isBlock(e,O));var[h]=R.nodes(e,{at:l.path,match:s,mode:a,voids:o});if(h){var[,v]=h,g=R.pathRef(e,v),m=R.isEnd(e,l,v);Re.splitNodes(e,{at:l,match:s,mode:a,voids:o});var b=g.unref();l=m?ne.next(b):b}else return}var y=ne.parent(l),C=l[l.length-1];if(!(!o&&R.void(e,{at:y}))){if(i){var D=[],w=ne.levels(y);ZE(e,()=>{var O=function(){var $=y.concat(C);C++;var P={type:"insert_node",path:$,node:j};e.apply(P),l=ne.next(l),D.push(P),ot.isText?w.push(...Array.from(Ge.nodes(j),A=>{var[,B]=A;return $.concat(B)})):w.push($)};for(var j of t)O()},()=>{Hb(e,w,O=>{var j=O;for(var $ of D)if(ne.operationCanTransformPath($)&&(j=ne.transform(j,$),!j))return null;return j})})}else for(var k of t){var E=y.concat(C);C++,e.apply({type:"insert_node",path:E,node:k}),l=ne.next(l)}if(l=ne.previous(l),u){var x=R.end(e,l);x&&Re.select(e,x)}}}})},gD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};R.withoutNormalizing(e,()=>{var{at:r=e.selection,mode:n="lowest",voids:o=!1}=t,{match:a}=t;if(a==null&&(a=ne.isPath(r)?ti(e,r):C=>lt.isElement(C)&&R.isBlock(e,C)),!!r){var i=R.nodes(e,{at:r,match:a,mode:n,voids:o}),l=Array.from(i,C=>{var[,D]=C;return R.pathRef(e,D)});for(var s of l){var u=s.unref();if(u.length<2)throw new Error("Cannot lift node at a path [".concat(u,"] because it has a depth of less than `2`."));var c=R.node(e,ne.parent(u)),[f,p]=c,h=u[u.length-1],{length:v}=f.children;if(v===1){var g=ne.next(p);Re.moveNodes(e,{at:u,to:g,voids:o}),Re.removeNodes(e,{at:p,voids:o})}else if(h===0)Re.moveNodes(e,{at:u,to:p,voids:o});else if(h===v-1){var m=ne.next(p);Re.moveNodes(e,{at:u,to:m,voids:o})}else{var b=ne.next(u),y=ne.next(p);Re.splitNodes(e,{at:b,voids:o}),Re.moveNodes(e,{at:u,to:y,voids:o})}}}})},vD=["text"],bD=["children"],Wb=(e,t)=>{if(lt.isElement(t)){var r=t;return R.isVoid(e,t)?!0:r.children.length===1?Wb(e,r.children[0]):!1}else return!R.isEditor(t)},yD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};R.withoutNormalizing(e,()=>{var{match:r,at:n=e.selection}=t,{hanging:o=!1,voids:a=!1,mode:i="lowest"}=t;if(n){if(r==null)if(ne.isPath(n)){var[l]=R.parent(e,n);r=O=>l.children.includes(O)}else r=O=>lt.isElement(O)&&R.isBlock(e,O);if(!o&&$e.isRange(n)&&(n=R.unhangRange(e,n,{voids:a})),$e.isRange(n))if($e.isCollapsed(n))n=n.anchor;else{var[,s]=$e.edges(n),u=R.pointRef(e,s);Re.delete(e,{at:n}),n=u.unref(),t.at==null&&Re.select(e,n)}var[c]=R.nodes(e,{at:n,match:r,voids:a,mode:i}),f=R.previous(e,{at:n,match:r,voids:a,mode:i});if(!(!c||!f)){var[p,h]=c,[v,g]=f;if(!(h.length===0||g.length===0)){var m=ne.next(g),b=ne.common(h,g),y=ne.isSibling(h,g),C=Array.from(R.levels(e,{at:h}),O=>{var[j]=O;return j}).slice(b.length).slice(0,-1),D=R.above(e,{at:h,mode:"highest",match:O=>C.includes(O)&&Wb(e,O)}),w=D&&R.pathRef(e,D[1]),k,E;if(ot.isText(p)&&ot.isText(v)){var x=vo(p,vD);E=v.text.length,k=x}else if(lt.isElement(p)&<.isElement(v)){var x=vo(p,bD);E=v.children.length,k=x}else throw new Error("Cannot merge the node at path [".concat(h,"] with the previous sibling because it is not the same kind: ").concat(Ir.stringify(p)," ").concat(Ir.stringify(v)));y||Re.moveNodes(e,{at:h,to:m,voids:a}),w&&Re.removeNodes(e,{at:w.current,voids:a}),R.shouldMergeNodesRemovePrevNode(e,f,c)?Re.removeNodes(e,{at:g,voids:a}):e.apply({type:"merge_node",path:m,position:E,properties:k}),w&&w.unref()}}}})},CD=(e,t)=>{R.withoutNormalizing(e,()=>{var{to:r,at:n=e.selection,mode:o="lowest",voids:a=!1}=t,{match:i}=t;if(n){i==null&&(i=ne.isPath(n)?ti(e,n):h=>lt.isElement(h)&&R.isBlock(e,h));var l=R.pathRef(e,r),s=R.nodes(e,{at:n,match:i,mode:o,voids:a}),u=Array.from(s,h=>{var[,v]=h;return R.pathRef(e,v)});for(var c of u){var f=c.unref(),p=l.current;f.length!==0&&e.apply({type:"move_node",path:f,newPath:p}),l.current&&ne.isSibling(p,f)&&ne.isAfter(p,f)&&(l.current=ne.next(l.current))}l.unref()}})},xD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};R.withoutNormalizing(e,()=>{var{hanging:r=!1,voids:n=!1,mode:o="lowest"}=t,{at:a=e.selection,match:i}=t;if(a){i==null&&(i=ne.isPath(a)?ti(e,a):p=>lt.isElement(p)&&R.isBlock(e,p)),!r&&$e.isRange(a)&&(a=R.unhangRange(e,a,{voids:n}));var l=R.nodes(e,{at:a,match:i,mode:o,voids:n}),s=Array.from(l,p=>{var[,h]=p;return R.pathRef(e,h)});for(var u of s){var c=u.unref();if(c){var[f]=R.node(e,c);e.apply({type:"remove_node",path:c,node:f})}}}})},wD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};R.withoutNormalizing(e,()=>{var{match:n,at:o=e.selection,compare:a,merge:i}=r,{hanging:l=!1,mode:s="lowest",split:u=!1,voids:c=!1}=r;if(o){if(n==null&&(n=ne.isPath(o)?ti(e,o):E=>lt.isElement(E)&&R.isBlock(e,E)),!l&&$e.isRange(o)&&(o=R.unhangRange(e,o,{voids:c})),u&&$e.isRange(o)){if($e.isCollapsed(o)&&R.leaf(e,o.anchor)[0].text.length>0)return;var f=R.rangeRef(e,o,{affinity:"inward"}),[p,h]=$e.edges(o),v=s==="lowest"?"lowest":"highest",g=R.isEnd(e,h,h.path);Re.splitNodes(e,{at:h,match:n,mode:v,voids:c,always:!g});var m=R.isStart(e,p,p.path);Re.splitNodes(e,{at:p,match:n,mode:v,voids:c,always:!m}),o=f.unref(),r.at==null&&Re.select(e,o)}a||(a=(E,x)=>E!==x);for(var[b,y]of R.nodes(e,{at:o,match:n,mode:s,voids:c})){var C={},D={};if(y.length!==0){var w=!1;for(var k in t)k==="children"||k==="text"||a(t[k],b[k])&&(w=!0,b.hasOwnProperty(k)&&(C[k]=b[k]),i?t[k]!=null&&(D[k]=i(b[k],t[k])):t[k]!=null&&(D[k]=t[k]));w&&e.apply({type:"set_node",path:y,properties:C,newProperties:D})}}}})},ED=(e,t)=>{if($e.isCollapsed(t))return t.anchor;var[,r]=$e.edges(t),n=R.pointRef(e,r);return Re.delete(e,{at:t}),n.unref()},kD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};R.withoutNormalizing(e,()=>{var{mode:r="lowest",voids:n=!1}=t,{match:o,at:a=e.selection,height:i=0,always:l=!1}=t;if(o==null&&(o=F=>lt.isElement(F)&&R.isBlock(e,F)),$e.isRange(a)&&(a=ED(e,a)),ne.isPath(a)){var s=a,u=R.point(e,s),[c]=R.parent(e,s);o=F=>F===c,i=u.path.length-s.length+1,a=u,l=!0}if(a){var f=R.pointRef(e,a,{affinity:"backward"}),p;try{var[h]=R.nodes(e,{at:a,match:o,mode:r,voids:n});if(!h)return;var v=R.void(e,{at:a,mode:"highest"}),g=0;if(!n&&v){var[m,b]=v;if(lt.isElement(m)&&e.isInline(m)){var y=R.after(e,b);if(!y){var C={text:""},D=ne.next(b);Re.insertNodes(e,C,{at:D,voids:n}),y=R.point(e,D)}a=y,l=!0}var w=a.path.length-b.length;i=w+1,l=!0}p=R.pointRef(e,a);var k=a.path.length-i,[,E]=h,x=a.path.slice(0,k),O=i===0?a.offset:a.path[k]+g;for(var[j,$]of R.levels(e,{at:x,reverse:!0,voids:n})){var P=!1;if($.length<E.length||$.length===0||!n&<.isElement(j)&&R.isVoid(e,j))break;var A=f.current,B=R.isEnd(e,A,$);if(l||!f||!R.isEdge(e,A,$)){P=!0;var S=Ge.extractProps(j);e.apply({type:"split_node",path:$,position:O,properties:S})}O=$[$.length-1]+(P||B?1:0)}if(t.at==null){var I=p.current||R.end(e,[]);Re.select(e,I)}}finally{var N;f.unref(),(N=p)===null||N===void 0||N.unref()}}})},DD=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};Array.isArray(t)||(t=[t]);var n={};for(var o of t)n[o]=null;Re.setNodes(e,n,r)},SD=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};R.withoutNormalizing(e,()=>{var{mode:r="lowest",split:n=!1,voids:o=!1}=t,{at:a=e.selection,match:i}=t;if(a){i==null&&(i=ne.isPath(a)?ti(e,a):p=>lt.isElement(p)&&R.isBlock(e,p)),ne.isPath(a)&&(a=R.range(e,a));var l=$e.isRange(a)?R.rangeRef(e,a):null,s=R.nodes(e,{at:a,match:i,mode:r,voids:o}),u=Array.from(s,p=>{var[,h]=p;return R.pathRef(e,h)}).reverse(),c=function(){var p=f.unref(),[h]=R.node(e,p),v=R.range(e,p);n&&l&&(v=$e.intersection(l.current,v)),Re.liftNodes(e,{at:v,match:g=>lt.isAncestor(h)&&h.children.includes(g),voids:o})};for(var f of u)c();l&&l.unref()}})};function yh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ch(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yh(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var $D=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};R.withoutNormalizing(e,()=>{var{mode:n="lowest",split:o=!1,voids:a=!1}=r,{match:i,at:l=e.selection}=r;if(l){if(i==null&&(ne.isPath(l)?i=ti(e,l):e.isInline(t)?i=v=>lt.isElement(v)&&R.isInline(e,v)||ot.isText(v):i=v=>lt.isElement(v)&&R.isBlock(e,v)),o&&$e.isRange(l)){var[s,u]=$e.edges(l),c=R.rangeRef(e,l,{affinity:"inward"});Re.splitNodes(e,{at:u,match:i,voids:a}),Re.splitNodes(e,{at:s,match:i,voids:a}),l=c.unref(),r.at==null&&Re.select(e,l)}var f=Array.from(R.nodes(e,{at:l,match:e.isInline(t)?v=>lt.isElement(v)&&R.isBlock(e,v):v=>R.isEditor(v),mode:"lowest",voids:a})),p=function(){var v=$e.isRange(l)?$e.intersection(l,R.range(e,h)):l;if(!v)return 0;var g=Array.from(R.nodes(e,{at:v,match:i,mode:n,voids:a}));if(g.length>0){var[m]=g,b=g[g.length-1],[,y]=m,[,C]=b;if(y.length===0&&C.length===0)return 0;var D=ne.equals(y,C)?ne.parent(y):ne.common(y,C),w=R.range(e,y,C),k=R.node(e,D),[E]=k,x=D.length+1,O=ne.next(C.slice(0,x)),j=Ch(Ch({},t),{},{children:[]});Re.insertNodes(e,j,{at:O,voids:a}),Re.moveNodes(e,{at:w,match:$=>lt.isAncestor(E)&&E.children.includes($),to:O.concat(0),voids:a})}};for(var[,h]of f)p()}})},BD=()=>{var e={children:[],operations:[],selection:null,marks:null,isElementReadOnly:()=>!1,isInline:()=>!1,isSelectable:()=>!0,isVoid:()=>!1,markableVoid:()=>!1,onChange:()=>{},apply:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return JE(e,...r)},addMark:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ok(e,...r)},deleteBackward:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return lk(e,...r)},deleteForward:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return sk(e,...r)},deleteFragment:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return uk(e,...r)},getFragment:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ek(e,...r)},insertBreak:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Ck(e,...r)},insertSoftBreak:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return wk(e,...r)},insertFragment:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return sD(e,...r)},insertNode:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return xk(e,...r)},insertText:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return kk(e,...r)},normalizeNode:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return tk(e,...r)},removeMark:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return eD(e,...r)},getDirtyPaths:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return QE(e,...r)},shouldNormalize:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return rk(e,...r)},above:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return nk(e,...r)},after:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ak(e,...r)},before:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ik(e,...r)},collapse:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return uD(e,...r)},delete:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return lD(e,...r)},deselect:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return cD(e,...r)},edges:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return ck(e,...r)},elementReadOnly:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return dk(e,...r)},end:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return fk(e,...r)},first:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return pk(e,...r)},fragment:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return mk(e,...r)},getMarks:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Rk(e,...r)},hasBlocks:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return gk(e,...r)},hasInlines:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return vk(e,...r)},hasPath:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return bk(e,...r)},hasTexts:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return yk(e,...r)},insertNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return hD(e,...r)},isBlock:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Dk(e,...r)},isEdge:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Sk(e,...r)},isEmpty:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return $k(e,...r)},isEnd:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Bk(e,...r)},isNormalizing:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Ok(e,...r)},isStart:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Ak(e,...r)},last:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Fk(e,...r)},leaf:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Nk(e,...r)},levels:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Pk(e,...r)},liftNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return gD(e,...r)},mergeNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return yD(e,...r)},move:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return dD(e,...r)},moveNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return CD(e,...r)},next:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Mk(e,...r)},node:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Tk(e,...r)},nodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return zk(e,...r)},normalize:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return _k(e,...r)},parent:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Lk(e,...r)},path:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Kk(e,...r)},pathRef:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Hk(e,...r)},pathRefs:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Wk(e,...r)},point:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Gk(e,...r)},pointRef:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return qk(e,...r)},pointRefs:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Vk(e,...r)},positions:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Xk(e,...r)},previous:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Uk(e,...r)},range:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Jk(e,...r)},rangeRef:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Yk(e,...r)},rangeRefs:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return Zk(e,...r)},removeNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return xD(e,...r)},select:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return fD(e,...r)},setNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return wD(e,...r)},setNormalizing:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return tD(e,...r)},setPoint:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return pD(e,...r)},setSelection:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return mD(e,...r)},splitNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return kD(e,...r)},start:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return rD(e,...r)},string:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return nD(e,...r)},unhangRange:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return oD(e,...r)},unsetNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return DD(e,...r)},unwrapNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return SD(e,...r)},void:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return hk(e,...r)},withoutNormalizing:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return aD(e,...r)},wrapNodes:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return $D(e,...r)},shouldMergeNodesRemovePrevNode:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return iD(e,...r)}};return e},Zu,xh;function OD(){if(xh)return Zu;xh=1,Zu=o;var e="\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC",t="A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u0300-\u0590\u0800-\u1FFF\u200E\u2C00-\uFB1C\uFE00-\uFE6F\uFEFD-\uFFFF",r=new RegExp("^[^"+t+"]*["+e+"]"),n=new RegExp("^[^"+e+"]*["+t+"]");function o(a){return a=String(a||""),r.test(a)?"rtl":n.test(a)?"ltr":"neutral"}return Zu}var AD=OD();const Kb=vl(AD);var Ju,wh;function ip(){if(wh)return Ju;wh=1;function e(t){var r=typeof t;return t!=null&&(r=="object"||r=="function")}return Ju=e,Ju}var Qu,Eh;function FD(){if(Eh)return Qu;Eh=1;var e=typeof jl=="object"&&jl&&jl.Object===Object&&jl;return Qu=e,Qu}var ec,kh;function qb(){if(kh)return ec;kh=1;var e=FD(),t=typeof self=="object"&&self&&self.Object===Object&&self,r=e||t||Function("return this")();return ec=r,ec}var tc,Dh;function ND(){if(Dh)return tc;Dh=1;var e=qb(),t=function(){return e.Date.now()};return tc=t,tc}var rc,Sh;function PD(){if(Sh)return rc;Sh=1;var e=/\s/;function t(r){for(var n=r.length;n--&&e.test(r.charAt(n)););return n}return rc=t,rc}var nc,$h;function jD(){if($h)return nc;$h=1;var e=PD(),t=/^\s+/;function r(n){return n&&n.slice(0,e(n)+1).replace(t,"")}return nc=r,nc}var oc,Bh;function Vb(){if(Bh)return oc;Bh=1;var e=qb(),t=e.Symbol;return oc=t,oc}var ac,Oh;function ID(){if(Oh)return ac;Oh=1;var e=Vb(),t=Object.prototype,r=t.hasOwnProperty,n=t.toString,o=e?e.toStringTag:void 0;function a(i){var l=r.call(i,o),s=i[o];try{i[o]=void 0;var u=!0}catch{}var c=n.call(i);return u&&(l?i[o]=s:delete i[o]),c}return ac=a,ac}var ic,Ah;function RD(){if(Ah)return ic;Ah=1;var e=Object.prototype,t=e.toString;function r(n){return t.call(n)}return ic=r,ic}var lc,Fh;function MD(){if(Fh)return lc;Fh=1;var e=Vb(),t=ID(),r=RD(),n="[object Null]",o="[object Undefined]",a=e?e.toStringTag:void 0;function i(l){return l==null?l===void 0?o:n:a&&a in Object(l)?t(l):r(l)}return lc=i,lc}var sc,Nh;function TD(){if(Nh)return sc;Nh=1;function e(t){return t!=null&&typeof t=="object"}return sc=e,sc}var uc,Ph;function zD(){if(Ph)return uc;Ph=1;var e=MD(),t=TD(),r="[object Symbol]";function n(o){return typeof o=="symbol"||t(o)&&e(o)==r}return uc=n,uc}var cc,jh;function _D(){if(jh)return cc;jh=1;var e=jD(),t=ip(),r=zD(),n=NaN,o=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,i=/^0o[0-7]+$/i,l=parseInt;function s(u){if(typeof u=="number")return u;if(r(u))return n;if(t(u)){var c=typeof u.valueOf=="function"?u.valueOf():u;u=t(c)?c+"":c}if(typeof u!="string")return u===0?u:+u;u=e(u);var f=a.test(u);return f||i.test(u)?l(u.slice(2),f?2:8):o.test(u)?n:+u}return cc=s,cc}var dc,Ih;function Gb(){if(Ih)return dc;Ih=1;var e=ip(),t=ND(),r=_D(),n="Expected a function",o=Math.max,a=Math.min;function i(l,s,u){var c,f,p,h,v,g,m=0,b=!1,y=!1,C=!0;if(typeof l!="function")throw new TypeError(n);s=r(s)||0,e(u)&&(b=!!u.leading,y="maxWait"in u,p=y?o(r(u.maxWait)||0,s):p,C="trailing"in u?!!u.trailing:C);function D(A){var B=c,S=f;return c=f=void 0,m=A,h=l.apply(S,B),h}function w(A){return m=A,v=setTimeout(x,s),b?D(A):h}function k(A){var B=A-g,S=A-m,I=s-B;return y?a(I,p-S):I}function E(A){var B=A-g,S=A-m;return g===void 0||B>=s||B<0||y&&S>=p}function x(){var A=t();if(E(A))return O(A);v=setTimeout(x,k(A))}function O(A){return v=void 0,C&&c?D(A):(c=f=void 0,h)}function j(){v!==void 0&&clearTimeout(v),m=0,c=g=f=v=void 0}function $(){return v===void 0?h:O(t())}function P(){var A=t(),B=E(A);if(c=arguments,f=this,g=A,B){if(v===void 0)return w(g);if(y)return clearTimeout(v),v=setTimeout(x,s),D(g)}return v===void 0&&(v=setTimeout(x,s)),h}return P.cancel=j,P.flush=$,P}return dc=i,dc}var LD=Gb();const HD=vl(LD);var fc,Rh;function WD(){if(Rh)return fc;Rh=1;var e=Gb(),t=ip(),r="Expected a function";function n(o,a,i){var l=!0,s=!0;if(typeof o!="function")throw new TypeError(r);return t(i)&&(l="leading"in i?!!i.leading:l,s="trailing"in i?!!i.trailing:s),e(o,a,{leading:l,maxWait:a,trailing:s})}return fc=n,fc}var KD=WD();const qD=vl(KD),Mh=e=>typeof e=="object"&&e!=null&&e.nodeType===1,Th=(e,t)=>(!t||e!=="hidden")&&e!=="visible"&&e!=="clip",Rl=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){const r=getComputedStyle(e,null);return Th(r.overflowY,t)||Th(r.overflowX,t)||(n=>{const o=(a=>{if(!a.ownerDocument||!a.ownerDocument.defaultView)return null;try{return a.ownerDocument.defaultView.frameElement}catch{return null}})(n);return!!o&&(o.clientHeight<n.scrollHeight||o.clientWidth<n.scrollWidth)})(e)}return!1},Ml=(e,t,r,n,o,a,i,l)=>a<e&&i>t||a>e&&i<t?0:a<=e&&l<=r||i>=t&&l>=r?a-e-n:i>t&&l<r||a<e&&l>r?i-t+o:0,VD=e=>e.parentElement??(e.getRootNode().host||null),zh=(e,t)=>{var r,n,o,a;if(typeof document>"u")return[];const{scrollMode:i,block:l,inline:s,boundary:u,skipOverflowHiddenElements:c}=t,f=typeof u=="function"?u:I=>I!==u;if(!Mh(e))throw new TypeError("Invalid target");const p=document.scrollingElement||document.documentElement,h=[];let v=e;for(;Mh(v)&&f(v);){if(v=VD(v),v===p){h.push(v);break}v!=null&&v===document.body&&Rl(v)&&!Rl(document.documentElement)||v!=null&&Rl(v,c)&&h.push(v)}const g=(n=(r=window.visualViewport)==null?void 0:r.width)!=null?n:innerWidth,m=(a=(o=window.visualViewport)==null?void 0:o.height)!=null?a:innerHeight,{scrollX:b,scrollY:y}=window,{height:C,width:D,top:w,right:k,bottom:E,left:x}=e.getBoundingClientRect(),{top:O,right:j,bottom:$,left:P}=(I=>{const N=window.getComputedStyle(I);return{top:parseFloat(N.scrollMarginTop)||0,right:parseFloat(N.scrollMarginRight)||0,bottom:parseFloat(N.scrollMarginBottom)||0,left:parseFloat(N.scrollMarginLeft)||0}})(e);let A=l==="start"||l==="nearest"?w-O:l==="end"?E+$:w+C/2-O+$,B=s==="center"?x+D/2-P+j:s==="end"?k+j:x-P;const S=[];for(let I=0;I<h.length;I++){const N=h[I],{height:F,width:M,top:_,right:X,bottom:H,left:q}=N.getBoundingClientRect();if(i==="if-needed"&&w>=0&&x>=0&&E<=m&&k<=g&&(N===p&&!Rl(N)||w>=_&&E<=H&&x>=q&&k<=X))return S;const Z=getComputedStyle(N),te=parseInt(Z.borderLeftWidth,10),z=parseInt(Z.borderTopWidth,10),Y=parseInt(Z.borderRightWidth,10),V=parseInt(Z.borderBottomWidth,10);let U=0,K=0;const W="offsetWidth"in N?N.offsetWidth-N.clientWidth-te-Y:0,re="offsetHeight"in N?N.offsetHeight-N.clientHeight-z-V:0,G="offsetWidth"in N?N.offsetWidth===0?0:M/N.offsetWidth:0,J="offsetHeight"in N?N.offsetHeight===0?0:F/N.offsetHeight:0;if(p===N)U=l==="start"?A:l==="end"?A-m:l==="nearest"?Ml(y,y+m,m,z,V,y+A,y+A+C,C):A-m/2,K=s==="start"?B:s==="center"?B-g/2:s==="end"?B-g:Ml(b,b+g,g,te,Y,b+B,b+B+D,D),U=Math.max(0,U+y),K=Math.max(0,K+b);else{U=l==="start"?A-_-z:l==="end"?A-H+V+re:l==="nearest"?Ml(_,H,F,z,V+re,A,A+C,C):A-(_+F/2)+re/2,K=s==="start"?B-q-te:s==="center"?B-(q+M/2)+W/2:s==="end"?B-X+Y+W:Ml(q,X,M,te,Y+W,B,B+D,D);const{scrollLeft:oe,scrollTop:se}=N;U=J===0?0:Math.max(0,Math.min(se+U/J,N.scrollHeight-F/J+re)),K=G===0?0:Math.max(0,Math.min(oe+K/G,N.scrollWidth-M/G+W)),A+=se-U,B+=oe-K}S.push({el:N,top:U,left:K})}return S},GD=e=>e===!1?{block:"end",inline:"nearest"}:(t=>t===Object(t)&&Object.keys(t).length!==0)(e)?e:{block:"start",inline:"nearest"};function XD(e,t){if(!e.isConnected||!(o=>{let a=o;for(;a&&a.parentNode;){if(a.parentNode===document)return!0;a=a.parentNode instanceof ShadowRoot?a.parentNode.host:a.parentNode}return!1})(e))return;const r=(o=>{const a=window.getComputedStyle(o);return{top:parseFloat(a.scrollMarginTop)||0,right:parseFloat(a.scrollMarginRight)||0,bottom:parseFloat(a.scrollMarginBottom)||0,left:parseFloat(a.scrollMarginLeft)||0}})(e);if((o=>typeof o=="object"&&typeof o.behavior=="function")(t))return t.behavior(zh(e,t));const n=typeof t=="boolean"||t==null?void 0:t.behavior;for(const{el:o,top:a,left:i}of zh(e,GD(t))){const l=a-r.top+r.bottom,s=i-r.left+r.right;o.scroll({top:l,left:s,behavior:n})}}var Vo=[],UD=function(){return Vo.some(function(e){return e.activeTargets.length>0})},YD=function(){return Vo.some(function(e){return e.skippedTargets.length>0})},_h="ResizeObserver loop completed with undelivered notifications.",ZD=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:_h}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=_h),window.dispatchEvent(e)},Gi;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Gi||(Gi={}));var Go=function(e){return Object.freeze(e)},JD=(function(){function e(t,r){this.inlineSize=t,this.blockSize=r,Go(this)}return e})(),Xb=(function(){function e(t,r,n,o){return this.x=t,this.y=r,this.width=n,this.height=o,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,Go(this)}return e.prototype.toJSON=function(){var t=this,r=t.x,n=t.y,o=t.top,a=t.right,i=t.bottom,l=t.left,s=t.width,u=t.height;return{x:r,y:n,top:o,right:a,bottom:i,left:l,width:s,height:u}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e})(),lp=function(e){return e instanceof SVGElement&&"getBBox"in e},Ub=function(e){if(lp(e)){var t=e.getBBox(),r=t.width,n=t.height;return!r&&!n}var o=e,a=o.offsetWidth,i=o.offsetHeight;return!(a||i||e.getClientRects().length)},Lh=function(e){var t;if(e instanceof Element)return!0;var r=(t=e==null?void 0:e.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(r&&e instanceof r.Element)},QD=function(e){switch(e.tagName){case"INPUT":if(e.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},Ni=typeof window<"u"?window:{},Tl=new WeakMap,Hh=/auto|scroll/,eS=/^tb|vertical/,tS=/msie|trident/i.test(Ni.navigator&&Ni.navigator.userAgent),Kn=function(e){return parseFloat(e||"0")},Aa=function(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=0),r===void 0&&(r=!1),new JD((r?t:e)||0,(r?e:t)||0)},Wh=Go({devicePixelContentBoxSize:Aa(),borderBoxSize:Aa(),contentBoxSize:Aa(),contentRect:new Xb(0,0,0,0)}),Yb=function(e,t){if(t===void 0&&(t=!1),Tl.has(e)&&!t)return Tl.get(e);if(Ub(e))return Tl.set(e,Wh),Wh;var r=getComputedStyle(e),n=lp(e)&&e.ownerSVGElement&&e.getBBox(),o=!tS&&r.boxSizing==="border-box",a=eS.test(r.writingMode||""),i=!n&&Hh.test(r.overflowY||""),l=!n&&Hh.test(r.overflowX||""),s=n?0:Kn(r.paddingTop),u=n?0:Kn(r.paddingRight),c=n?0:Kn(r.paddingBottom),f=n?0:Kn(r.paddingLeft),p=n?0:Kn(r.borderTopWidth),h=n?0:Kn(r.borderRightWidth),v=n?0:Kn(r.borderBottomWidth),g=n?0:Kn(r.borderLeftWidth),m=f+u,b=s+c,y=g+h,C=p+v,D=l?e.offsetHeight-C-e.clientHeight:0,w=i?e.offsetWidth-y-e.clientWidth:0,k=o?m+y:0,E=o?b+C:0,x=n?n.width:Kn(r.width)-k-w,O=n?n.height:Kn(r.height)-E-D,j=x+m+w+y,$=O+b+D+C,P=Go({devicePixelContentBoxSize:Aa(Math.round(x*devicePixelRatio),Math.round(O*devicePixelRatio),a),borderBoxSize:Aa(j,$,a),contentBoxSize:Aa(x,O,a),contentRect:new Xb(f,s,x,O)});return Tl.set(e,P),P},Zb=function(e,t,r){var n=Yb(e,r),o=n.borderBoxSize,a=n.contentBoxSize,i=n.devicePixelContentBoxSize;switch(t){case Gi.DEVICE_PIXEL_CONTENT_BOX:return i;case Gi.BORDER_BOX:return o;default:return a}},rS=(function(){function e(t){var r=Yb(t);this.target=t,this.contentRect=r.contentRect,this.borderBoxSize=Go([r.borderBoxSize]),this.contentBoxSize=Go([r.contentBoxSize]),this.devicePixelContentBoxSize=Go([r.devicePixelContentBoxSize])}return e})(),Jb=function(e){if(Ub(e))return 1/0;for(var t=0,r=e.parentNode;r;)t+=1,r=r.parentNode;return t},nS=function(){var e=1/0,t=[];Vo.forEach(function(a){if(a.activeTargets.length!==0){var i=[];a.activeTargets.forEach(function(l){var s=new rS(l.target),u=Jb(l.target);i.push(s),l.lastReportedSize=Zb(l.target,l.observedBox),u<e&&(e=u)}),t.push(function(){a.callback.call(a.observer,i,a.observer)}),a.activeTargets.splice(0,a.activeTargets.length)}});for(var r=0,n=t;r<n.length;r++){var o=n[r];o()}return e},Kh=function(e){Vo.forEach(function(t){t.activeTargets.splice(0,t.activeTargets.length),t.skippedTargets.splice(0,t.skippedTargets.length),t.observationTargets.forEach(function(r){r.isActive()&&(Jb(r.target)>e?t.activeTargets.push(r):t.skippedTargets.push(r))})})},oS=function(){var e=0;for(Kh(e);UD();)e=nS(),Kh(e);return YD()&&ZD(),e>0},pc,Qb=[],aS=function(){return Qb.splice(0).forEach(function(e){return e()})},iS=function(e){if(!pc){var t=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return aS()}).observe(r,n),pc=function(){r.textContent="".concat(t?t--:t++)}}Qb.push(e),pc()},lS=function(e){iS(function(){requestAnimationFrame(e)})},os=0,sS=function(){return!!os},uS=250,cS={attributes:!0,characterData:!0,childList:!0,subtree:!0},qh=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Vh=function(e){return e===void 0&&(e=0),Date.now()+e},mc=!1,dS=(function(){function e(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return e.prototype.run=function(t){var r=this;if(t===void 0&&(t=uS),!mc){mc=!0;var n=Vh(t);lS(function(){var o=!1;try{o=oS()}finally{if(mc=!1,t=n-Vh(),!sS())return;o?r.run(1e3):t>0?r.run(t):r.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var t=this,r=function(){return t.observer&&t.observer.observe(document.body,cS)};document.body?r():Ni.addEventListener("DOMContentLoaded",r)},e.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),qh.forEach(function(r){return Ni.addEventListener(r,t.listener,!0)}))},e.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),qh.forEach(function(r){return Ni.removeEventListener(r,t.listener,!0)}),this.stopped=!0)},e})(),gd=new dS,Gh=function(e){!os&&e>0&&gd.start(),os+=e,!os&&gd.stop()},fS=function(e){return!lp(e)&&!QD(e)&&getComputedStyle(e).display==="inline"},pS=(function(){function e(t,r){this.target=t,this.observedBox=r||Gi.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var t=Zb(this.target,this.observedBox,!0);return fS(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e})(),mS=(function(){function e(t,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=r}return e})(),zl=new WeakMap,Xh=function(e,t){for(var r=0;r<e.length;r+=1)if(e[r].target===t)return r;return-1},_l=(function(){function e(){}return e.connect=function(t,r){var n=new mS(t,r);zl.set(t,n)},e.observe=function(t,r,n){var o=zl.get(t),a=o.observationTargets.length===0;Xh(o.observationTargets,r)<0&&(a&&Vo.push(o),o.observationTargets.push(new pS(r,n&&n.box)),Gh(1),gd.schedule())},e.unobserve=function(t,r){var n=zl.get(t),o=Xh(n.observationTargets,r),a=n.observationTargets.length===1;o>=0&&(a&&Vo.splice(Vo.indexOf(n),1),n.observationTargets.splice(o,1),Gh(-1))},e.disconnect=function(t){var r=this,n=zl.get(t);n.observationTargets.slice().forEach(function(o){return r.unobserve(t,o.target)}),n.activeTargets.splice(0,n.activeTargets.length)},e})(),hS=(function(){function e(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");_l.connect(this,t)}return e.prototype.observe=function(t,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Lh(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");_l.observe(this,t,r)},e.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Lh(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");_l.unobserve(this,t)},e.prototype.disconnect=function(){_l.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e})(),Pn={},Uh;function gS(){if(Uh)return Pn;Uh=1,Object.defineProperty(Pn,"__esModule",{value:!0});for(var e=typeof window<"u"&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),t={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},r={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:e?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},n={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222},o=1;o<20;o++)n["f"+o]=111+o;function a(p,h,v){h&&!("byKey"in h)&&(v=h,h=null),Array.isArray(p)||(p=[p]);var g=p.map(function(y){return s(y,h)}),m=function(y){return g.some(function(C){return u(C,y)})},b=v==null?m:m(v);return b}function i(p,h){return a(p,h)}function l(p,h){return a(p,{byKey:!0},h)}function s(p,h){var v=h&&h.byKey,g={};p=p.replace("++","+add");var m=p.split("+"),b=m.length;for(var y in t)g[t[y]]=!1;var C=!0,D=!1,w=void 0;try{for(var k=m[Symbol.iterator](),E;!(C=(E=k.next()).done);C=!0){var x=E.value,O=x.endsWith("?")&&x.length>1;O&&(x=x.slice(0,-1));var j=f(x),$=t[j];if(x.length>1&&!$&&!r[x]&&!n[j])throw new TypeError('Unknown modifier: "'+x+'"');(b===1||!$)&&(v?g.key=j:g.which=c(x)),$&&(g[$]=O?null:!0)}}catch(P){D=!0,w=P}finally{try{!C&&k.return&&k.return()}finally{if(D)throw w}}return g}function u(p,h){for(var v in p){var g=p[v],m=void 0;if(g!=null&&(v==="key"&&h.key!=null?m=h.key.toLowerCase():v==="which"?m=g===91&&h.which===93?91:h.which:m=h[v],!(m==null&&g===!1)&&m!==g))return!1}return!0}function c(p){p=f(p);var h=n[p]||p.toUpperCase().charCodeAt(0);return h}function f(p){return p=p.toLowerCase(),p=r[p]||p,p}return Pn.default=a,Pn.isHotkey=a,Pn.isCodeHotkey=i,Pn.isKeyHotkey=l,Pn.parseHotkey=s,Pn.compareHotkey=u,Pn.toKeyCode=c,Pn.toKeyName=f,Pn}var hc=gS();function vS(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function Ma(e,t){if(e==null)return{};var r=vS(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Xi(e){"@babel/helpers - typeof";return Xi=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},Xi(e)}function bS(e,t){if(Xi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Xi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function yS(e){var t=bS(e,"string");return Xi(t)==="symbol"?t:String(t)}function Bn(e,t,r){return t=yS(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var sp=Fn(null),Io=()=>{var e=Rr(sp);if(!e)throw new Error("The `useSlateStatic` hook must be used inside the <Slate> component's context.");return e},gc,vc,ey=parseInt(ee.version.split(".")[0],10),ty=typeof navigator<"u"&&typeof window<"u"&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,Yh=typeof navigator<"u"&&/Mac OS X/.test(navigator.userAgent),en=typeof navigator<"u"&&/Android/.test(navigator.userAgent),Da=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),Lo=typeof navigator<"u"&&/AppleWebKit(?!.*Chrome)/i.test(navigator.userAgent),CS=typeof navigator<"u"&&/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(?:\.)/i.test(navigator.userAgent),ry=typeof navigator<"u"&&/Chrome/i.test(navigator.userAgent),xS=typeof navigator<"u"&&/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(?:\.)/i.test(navigator.userAgent),wS=en&&typeof navigator<"u"&&/Chrome?\/(?:[0-5]?\d)(?:\.)/i.test(navigator.userAgent),ES=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox\/(?:[0-7][0-9]|[0-8][0-6])(?:\.)).*/i.test(navigator.userAgent),kS=typeof navigator<"u"&&/.*UCBrowser/.test(navigator.userAgent),DS=typeof navigator<"u"&&/.*Wechat/.test(navigator.userAgent)&&!/.*MacWechat/.test(navigator.userAgent),as=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";typeof navigator<"u"&&/Safari/.test(navigator.userAgent)&&/Version\/(\d+)/.test(navigator.userAgent)&&(gc=navigator.userAgent.match(/Version\/(\d+)/))!==null&&gc!==void 0&&gc[1]&&parseInt((vc=navigator.userAgent.match(/Version\/(\d+)/))===null||vc===void 0?void 0:vc[1],10)<17;var Co=(!xS||!wS)&&!CS&&typeof globalThis<"u"&&globalThis.InputEvent&&typeof globalThis.InputEvent.prototype.getTargetRanges=="function",Fa=new WeakMap,up=new WeakMap,cp=new WeakMap,ny=new WeakMap,is=new WeakMap,vd=new WeakMap,Ui=new WeakMap,Xo=new WeakMap,As=new WeakMap,lu=new WeakMap,bd=new WeakMap,$o=new WeakMap,Wo=new WeakMap,Pi=new WeakMap,yd=new WeakMap,dp=new WeakMap,Mn=new WeakMap,po=new WeakMap,sn=new WeakMap,Do=new WeakMap,So=new WeakMap,oy=new WeakMap,Ta=Symbol("placeholder"),ay=Symbol("mark-placeholder"),iy=globalThis.Node,SS=globalThis.Text,fp=e=>e&&e.ownerDocument&&e.ownerDocument.defaultView||null,$S=e=>Fo(e)&&e.nodeType===8,$n=e=>Fo(e)&&e.nodeType===1,Fo=e=>{var t=fp(e);return!!t&&e instanceof t.Node},Cd=e=>{var t=e&&e.anchorNode&&fp(e.anchorNode);return!!t&&e instanceof t.Selection},ly=e=>Fo(e)&&e.nodeType===3,BS=e=>e.clipboardData&&e.clipboardData.getData("text/plain")!==""&&e.clipboardData.types.length===1,OS=e=>{var[t,r]=e;if($n(t)&&t.childNodes.length){var n=r===t.childNodes.length,o=n?r-1:r;for([t,o]=sy(t,o,n?"backward":"forward"),n=o<r;$n(t)&&t.childNodes.length;){var a=n?t.childNodes.length-1:0;t=FS(t,a,n?"backward":"forward")}r=n&&t.textContent!=null?t.textContent.length:0}return[t,r]},AS=e=>{for(var t=e&&e.parentNode;t;){if(t.toString()==="[object ShadowRoot]")return!0;t=t.parentNode}return!1},sy=(e,t,r)=>{for(var{childNodes:n}=e,o=n[t],a=t,i=!1,l=!1;($S(o)||$n(o)&&o.childNodes.length===0||$n(o)&&o.getAttribute("contenteditable")==="false")&&!(i&&l);){if(a>=n.length){i=!0,a=t-1,r="backward";continue}if(a<0){l=!0,a=t+1,r="forward";continue}o=n[a],t=a,a+=r==="forward"?1:-1}return[o,t]},FS=(e,t,r)=>{var[n]=sy(e,t,r);return n},uy=e=>{var t="";if(ly(e)&&e.nodeValue)return e.nodeValue;if($n(e)){for(var r of Array.from(e.childNodes))t+=uy(r);var n=getComputedStyle(e).getPropertyValue("display");(n==="block"||n==="list"||e.tagName==="BR")&&(t+=`
|
|
15
|
+
`)}return t},NS=/data-slate-fragment="(.+?)"/m,PS=e=>{var t=e.getData("text/html"),[,r]=t.match(NS)||[];return r},ji=e=>e.getSelection!=null?e.getSelection():document.getSelection(),pp=(e,t,r)=>{var{target:n}=t;if($n(n)&&n.matches('[contentEditable="false"]'))return!1;var{document:o}=Ae.getWindow(e);if(o.contains(n))return Ae.hasDOMNode(e,n,{editable:!0});var a=r.find(i=>{var{addedNodes:l,removedNodes:s}=i;for(var u of l)if(u===n||u.contains(n))return!0;for(var c of s)if(c===n||c.contains(n))return!0});return!a||a===t?!1:pp(e,a,r)},jS=()=>{for(var e=document.activeElement;(t=e)!==null&&t!==void 0&&t.shadowRoot&&(r=e.shadowRoot)!==null&&r!==void 0&&r.activeElement;){var t,r,n;e=(n=e)===null||n===void 0||(n=n.shadowRoot)===null||n===void 0?void 0:n.activeElement}return e},Zh=(e,t)=>!!(e.compareDocumentPosition(t)&iy.DOCUMENT_POSITION_PRECEDING),IS=(e,t)=>!!(e.compareDocumentPosition(t)&iy.DOCUMENT_POSITION_FOLLOWING),RS=0;class MS{constructor(){Bn(this,"id",void 0),this.id="".concat(RS++)}}var Ae={androidPendingDiffs:e=>sn.get(e),androidScheduleFlush:e=>{var t;(t=dp.get(e))===null||t===void 0||t()},blur:e=>{var t=Ae.toDOMNode(e,e),r=Ae.findDocumentOrShadowRoot(e);$o.set(e,!1),r.activeElement===t&&t.blur()},deselect:e=>{var{selection:t}=e,r=Ae.findDocumentOrShadowRoot(e),n=ji(r);n&&n.rangeCount>0&&n.removeAllRanges(),t&&Re.deselect(e)},findDocumentOrShadowRoot:e=>{var t=Ae.toDOMNode(e,e),r=t.getRootNode();return r instanceof Document||r instanceof ShadowRoot?r:t.ownerDocument},findEventRange:(e,t)=>{"nativeEvent"in t&&(t=t.nativeEvent);var{clientX:r,clientY:n,target:o}=t;if(r==null||n==null)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));var a=Ae.toSlateNode(e,t.target),i=Ae.findPath(e,a);if(lt.isElement(a)&&R.isVoid(e,a)){var l=o.getBoundingClientRect(),s=e.isInline(a)?r-l.left<l.left+l.width-r:n-l.top<l.top+l.height-n,u=R.point(e,i,{edge:s?"start":"end"}),c=s?R.before(e,u):R.after(e,u);if(c){var f=R.range(e,c);return f}}var p,{document:h}=Ae.getWindow(e);if(h.caretRangeFromPoint)p=h.caretRangeFromPoint(r,n);else{var v=h.caretPositionFromPoint(r,n);v&&(p=h.createRange(),p.setStart(v.offsetNode,v.offset),p.setEnd(v.offsetNode,v.offset))}if(!p)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));var g=Ae.toSlateRange(e,p,{exactMatch:!1,suppressThrow:!1});return g},findKey:(e,t)=>{var r=As.get(t);return r||(r=new MS,As.set(t,r)),r},findPath:(e,t)=>{for(var r=[],n=t;;){var o=cp.get(n);if(o==null){if(R.isEditor(n))return r;break}var a=up.get(n);if(a==null)break;r.unshift(a),n=o}throw new Error("Unable to find the path for Slate node: ".concat(Ir.stringify(t)))},focus:function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{retries:5};if(!$o.get(e)){if(t.retries<=0)throw new Error("Could not set focus, editor seems stuck with pending operations");if(e.operations.length>0){setTimeout(()=>{Ae.focus(e,{retries:t.retries-1})},10);return}var r=Ae.toDOMNode(e,e),n=Ae.findDocumentOrShadowRoot(e);if(n.activeElement!==r){if(e.selection&&n instanceof Document){var o=ji(n),a=Ae.toDOMRange(e,e.selection);o==null||o.removeAllRanges(),o==null||o.addRange(a)}e.selection||Re.select(e,R.start(e,[])),$o.set(e,!0),r.focus({preventScroll:!0})}}},getWindow:e=>{var t=ny.get(e);if(!t)throw new Error("Unable to find a host window element for this editor");return t},hasDOMNode:function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{editable:n=!1}=r,o=Ae.toDOMNode(e,e),a;try{a=$n(t)?t:t.parentElement}catch(i){if(i instanceof Error&&!i.message.includes('Permission denied to access property "nodeType"'))throw i}return a?a.closest("[data-slate-editor]")===o&&(!n||a.isContentEditable?!0:typeof a.isContentEditable=="boolean"&&a.closest('[contenteditable="false"]')===o||!!a.getAttribute("data-slate-zero-width")):!1},hasEditableTarget:(e,t)=>Fo(t)&&Ae.hasDOMNode(e,t,{editable:!0}),hasRange:(e,t)=>{var{anchor:r,focus:n}=t;return R.hasPath(e,r.path)&&R.hasPath(e,n.path)},hasSelectableTarget:(e,t)=>Ae.hasEditableTarget(e,t)||Ae.isTargetInsideNonReadonlyVoid(e,t),hasTarget:(e,t)=>Fo(t)&&Ae.hasDOMNode(e,t),insertData:(e,t)=>{e.insertData(t)},insertFragmentData:(e,t)=>e.insertFragmentData(t),insertTextData:(e,t)=>e.insertTextData(t),isComposing:e=>!!Wo.get(e),isFocused:e=>!!$o.get(e),isReadOnly:e=>!!bd.get(e),isTargetInsideNonReadonlyVoid:(e,t)=>{if(bd.get(e))return!1;var r=Ae.hasTarget(e,t)&&Ae.toSlateNode(e,t);return lt.isElement(r)&&R.isVoid(e,r)},setFragmentData:(e,t,r)=>e.setFragmentData(t,r),toDOMNode:(e,t)=>{var r=lu.get(e),n=R.isEditor(t)?is.get(e):r==null?void 0:r.get(Ae.findKey(e,t));if(!n)throw new Error("Cannot resolve a DOM node from Slate node: ".concat(Ir.stringify(t)));return n},toDOMPoint:(e,t)=>{var[r]=R.node(e,t.path),n=Ae.toDOMNode(e,r),o;R.void(e,{at:t})&&(t={path:t.path,offset:0});for(var a="[data-slate-string], [data-slate-zero-width]",i=Array.from(n.querySelectorAll(a)),l=0,s=0;s<i.length;s++){var u=i[s],c=u.childNodes[0];if(!(c==null||c.textContent==null)){var{length:f}=c.textContent,p=u.getAttribute("data-slate-length"),h=p==null?f:parseInt(p,10),v=l+h,g=i[s+1];if(t.offset===v&&g!==null&&g!==void 0&&g.hasAttribute("data-slate-mark-placeholder")){var m,b=g.childNodes[0];o=[b instanceof SS?b:g,(m=g.textContent)!==null&&m!==void 0&&m.startsWith("\uFEFF")?1:0];break}if(t.offset<=v){var y=Math.min(f,Math.max(0,t.offset-l));o=[c,y];break}l=v}}if(!o)throw new Error("Cannot resolve a DOM point from Slate point: ".concat(Ir.stringify(t)));return o},toDOMRange:(e,t)=>{var{anchor:r,focus:n}=t,o=$e.isBackward(t),a=Ae.toDOMPoint(e,r),i=$e.isCollapsed(t)?a:Ae.toDOMPoint(e,n),l=Ae.getWindow(e),s=l.document.createRange(),[u,c]=o?i:a,[f,p]=o?a:i,h=$n(u)?u:u.parentElement,v=!!h.getAttribute("data-slate-zero-width"),g=$n(f)?f:f.parentElement,m=!!g.getAttribute("data-slate-zero-width");return s.setStart(u,v?1:c),s.setEnd(f,m?1:p),s},toSlateNode:(e,t)=>{var r=$n(t)?t:t.parentElement;r&&!r.hasAttribute("data-slate-node")&&(r=r.closest("[data-slate-node]"));var n=r?Ui.get(r):null;if(!n)throw new Error("Cannot resolve a Slate node from DOM node: ".concat(r));return n},toSlatePoint:(e,t,r)=>{var{exactMatch:n,suppressThrow:o,searchDirection:a="backward"}=r,[i,l]=n?t:OS(t),s=i.parentNode,u=null,c=0;if(s){var f,p,h=Ae.toDOMNode(e,e),v=s.closest('[data-slate-void="true"]'),g=v&&h.contains(v)?v:null,m=s.closest('[contenteditable="false"]'),b=m&&h.contains(m)?m:null,y=s.closest("[data-slate-leaf]"),C=null;if(y){if(u=y.closest('[data-slate-node="text"]'),u){var D=Ae.getWindow(e),w=D.document.createRange();w.setStart(u,0),w.setEnd(i,l);var k=w.cloneContents(),E=[...Array.prototype.slice.call(k.querySelectorAll("[data-slate-zero-width]")),...Array.prototype.slice.call(k.querySelectorAll("[contenteditable=false]"))];E.forEach(q=>{if(en&&!n&&q.hasAttribute("data-slate-zero-width")&&q.textContent.length>0&&q.textContext!=="\uFEFF"){q.textContent.startsWith("\uFEFF")&&(q.textContent=q.textContent.slice(1));return}q.parentNode.removeChild(q)}),c=k.textContent.length,C=u}}else if(g){for(var x=g.querySelectorAll("[data-slate-leaf]"),O=0;O<x.length;O++){var j=x[O];if(Ae.hasDOMNode(e,j)){y=j;break}}y?(u=y.closest('[data-slate-node="text"]'),C=y,c=C.textContent.length,C.querySelectorAll("[data-slate-zero-width]").forEach(q=>{c-=q.textContent.length})):c=1}else if(b){var $=q=>q?q.querySelectorAll("[data-slate-leaf]:not(:scope [data-slate-editor] [data-slate-leaf])"):[],P=b.closest('[data-slate-node="element"]');if(a==="forward"){var A,B=[...$(P),...$(P==null?void 0:P.nextElementSibling)];y=(A=B.find(q=>IS(b,q)))!==null&&A!==void 0?A:null}else{var S,I=[...$(P==null?void 0:P.previousElementSibling),...$(P)];y=(S=I.findLast(q=>Zh(b,q)))!==null&&S!==void 0?S:null}y&&(u=y.closest('[data-slate-node="text"]'),C=y,a==="forward"?c=0:(c=C.textContent.length,C.querySelectorAll("[data-slate-zero-width]").forEach(q=>{c-=q.textContent.length})))}C&&c===C.textContent.length&&en&&C.getAttribute("data-slate-zero-width")==="z"&&(f=C.textContent)!==null&&f!==void 0&&f.startsWith("\uFEFF")&&(s.hasAttribute("data-slate-zero-width")||Da&&(p=C.textContent)!==null&&p!==void 0&&p.endsWith(`
|
|
16
|
+
|
|
17
|
+
`))&&c--}if(en&&!u&&!n){var N=s.hasAttribute("data-slate-node")?s:s.closest("[data-slate-node]");if(N&&Ae.hasDOMNode(e,N,{editable:!0})){var F=Ae.toSlateNode(e,N),{path:M,offset:_}=R.start(e,Ae.findPath(e,F));return N.querySelector("[data-slate-leaf]")||(_=l),{path:M,offset:_}}}if(!u){if(o)return null;throw new Error("Cannot resolve a Slate point from DOM point: ".concat(t))}var X=Ae.toSlateNode(e,u),H=Ae.findPath(e,X);return{path:H,offset:c}},toSlateRange:(e,t,r)=>{var n,{exactMatch:o,suppressThrow:a}=r,i=Cd(t)?t.anchorNode:t.startContainer,l,s,u,c,f;if(i)if(Cd(t)){if(Da&&t.rangeCount>1){u=t.focusNode;var p=t.getRangeAt(0),h=t.getRangeAt(t.rangeCount-1);if(u instanceof HTMLTableRowElement&&p.startContainer instanceof HTMLTableRowElement&&h.startContainer instanceof HTMLTableRowElement){let k=function(E){return E.childElementCount>0?k(E.children[0]):E};var v=p.startContainer,g=h.startContainer,m=k(v.children[p.startOffset]),b=k(g.children[h.startOffset]);c=0,b.childNodes.length>0?l=b.childNodes[0]:l=b,m.childNodes.length>0?u=m.childNodes[0]:u=m,b instanceof HTMLElement?s=b.innerHTML.length:s=0}else p.startContainer===u?(l=h.endContainer,s=h.endOffset,c=p.startOffset):(l=p.startContainer,s=p.endOffset,c=h.startOffset)}else l=t.anchorNode,s=t.anchorOffset,u=t.focusNode,c=t.focusOffset;ry&&AS(l)||Da?f=t.anchorNode===t.focusNode&&t.anchorOffset===t.focusOffset:f=t.isCollapsed}else l=t.startContainer,s=t.startOffset,u=t.endContainer,c=t.endOffset,f=t.collapsed;if(l==null||u==null||s==null||c==null)throw new Error("Cannot resolve a Slate range from DOM range: ".concat(t));Da&&(n=u.textContent)!==null&&n!==void 0&&n.endsWith(`
|
|
18
|
+
|
|
19
|
+
`)&&c===u.textContent.length&&c--;var y=Ae.toSlatePoint(e,[l,s],{exactMatch:o,suppressThrow:a});if(!y)return null;var C=Zh(l,u)||l===u&&c<s,D=f?y:Ae.toSlatePoint(e,[u,c],{exactMatch:o,suppressThrow:a,searchDirection:C?"forward":"backward"});if(!D)return null;var w={anchor:y,focus:D};return $e.isExpanded(w)&&$e.isForward(w)&&$n(u)&&R.void(e,{at:w.focus,mode:"highest"})&&(w=R.unhangRange(e,w,{voids:!0})),w}};function TS(e,t){var{path:r,diff:n}=t;if(!R.hasPath(e,r))return!1;var o=Ge.get(e,r);if(!ot.isText(o))return!1;if(n.start!==o.text.length||n.text.length===0)return o.text.slice(n.start,n.start+n.text.length)===n.text;var a=ne.next(r);if(!R.hasPath(e,a))return!1;var i=Ge.get(e,a);return ot.isText(i)&&i.text.startsWith(n.text)}function cy(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return r.reduce((o,a)=>o.slice(0,a.start)+a.text+o.slice(a.end),e)}function zS(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++)if(e.charAt(n)!==t.charAt(n))return n;return r}function _S(e,t,r){for(var n=Math.min(e.length,t.length,r),o=0;o<n;o++)if(e.charAt(e.length-o-1)!==t.charAt(t.length-o-1))return o;return n}function dy(e,t){var{start:r,end:n,text:o}=t,a=e.slice(r,n),i=zS(a,o),l=Math.min(a.length-i,o.length-i),s=_S(a,o,l),u={start:r+i,end:n-s,text:o.slice(i,o.length-s)};return u.start===u.end&&u.text.length===0?null:u}function LS(e,t,r){var n=Math.min(t.start,r.start),o=Math.max(0,Math.min(t.start+t.text.length,r.end)-r.start),a=cy(e,t,r),i=Math.max(r.start+r.text.length,t.start+t.text.length+(t.start+t.text.length>r.start?r.text.length:0)-o),l=a.slice(n,i),s=Math.max(t.end,r.end-t.text.length+(t.end-t.start));return dy(e,{start:n,end:s,text:l})}function HS(e){var{path:t,diff:r}=e;return{anchor:{path:t,offset:r.start},focus:{path:t,offset:r.end}}}function xd(e,t){var{path:r,offset:n}=t;if(!R.hasPath(e,r))return null;var o=Ge.get(e,r);if(!ot.isText(o))return null;var a=R.above(e,{match:l=>lt.isElement(l)&&R.isBlock(e,l),at:r});if(!a)return null;for(;n>o.text.length;){var i=R.next(e,{at:r,match:ot.isText});if(!i||!ne.isDescendant(i[1],a[1]))return null;n-=o.text.length,o=i[0],r=i[1]}return{path:r,offset:n}}function Jh(e,t){var r=xd(e,t.anchor);if(!r)return null;if($e.isCollapsed(t))return{anchor:r,focus:r};var n=xd(e,t.focus);return n?{anchor:r,focus:n}:null}function wd(e,t,r){var n=sn.get(e),o=n==null?void 0:n.find(c=>{var{path:f}=c;return ne.equals(f,t.path)});if(!o||t.offset<=o.diff.start)return Rt.transform(t,r,{affinity:"backward"});var{diff:a}=o;if(t.offset<=a.start+a.text.length){var i={path:t.path,offset:a.start},l=Rt.transform(i,r,{affinity:"backward"});return l?{path:l.path,offset:l.offset+t.offset-a.start}:null}var s={path:t.path,offset:t.offset-a.text.length+a.end-a.start},u=Rt.transform(s,r,{affinity:"backward"});return u?r.type==="split_node"&&ne.equals(r.path,t.path)&&s.offset<r.position&&a.start<r.position?u:{path:u.path,offset:u.offset+a.text.length-a.end+a.start}:null}function Qh(e,t,r){var n=wd(e,t.anchor,r);if(!n)return null;if($e.isCollapsed(t))return{anchor:n,focus:n};var o=wd(e,t.focus,r);return o?{anchor:n,focus:o}:null}function WS(e,t){var{path:r,diff:n,id:o}=e;switch(t.type){case"insert_text":return!ne.equals(t.path,r)||t.offset>=n.end?e:t.offset<=n.start?{diff:{start:t.text.length+n.start,end:t.text.length+n.end,text:n.text},id:o,path:r}:{diff:{start:n.start,end:n.end+t.text.length,text:n.text},id:o,path:r};case"remove_text":return!ne.equals(t.path,r)||t.offset>=n.end?e:t.offset+t.text.length<=n.start?{diff:{start:n.start-t.text.length,end:n.end-t.text.length,text:n.text},id:o,path:r}:{diff:{start:n.start,end:n.end-t.text.length,text:n.text},id:o,path:r};case"split_node":return!ne.equals(t.path,r)||t.position>=n.end?{diff:n,id:o,path:ne.transform(r,t,{affinity:"backward"})}:t.position>n.start?{diff:{start:n.start,end:Math.min(t.position,n.end),text:n.text},id:o,path:r}:{diff:{start:n.start-t.position,end:n.end-t.position,text:n.text},id:o,path:ne.transform(r,t,{affinity:"forward"})};case"merge_node":return ne.equals(t.path,r)?{diff:{start:n.start+t.position,end:n.end+t.position,text:n.text},id:o,path:ne.transform(r,t)}:{diff:n,id:o,path:ne.transform(r,t)}}var a=ne.transform(r,t);return a?{diff:n,path:a,id:o}:null}function eg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ll(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?eg(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):eg(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var KS=25,qS=200,VS=function(){},GS=e=>(e==null?void 0:e.constructor.name)==="DataTransfer";function XS(e){var{editor:t,scheduleOnDOMSelectionChange:r,onDOMSelectionChange:n}=e,o=!1,a=null,i=null,l=null,s=0,u=!1,c=()=>{var P=So.get(t);if(So.delete(t),P){var{selection:A}=t,B=Jh(t,P);B&&(!A||!$e.equals(B,A))&&Re.select(t,B)}},f=()=>{var P=Do.get(t);if(Do.delete(t),!!P){if(P.at){var A=Rt.isPoint(P.at)?xd(t,P.at):Jh(t,P.at);if(!A)return;var B=R.range(t,A);(!t.selection||!$e.equals(t.selection,B))&&Re.select(t,A)}P.run()}},p=()=>{if(i&&(clearTimeout(i),i=null),l&&(clearTimeout(l),l=null),!D()&&!C()){c();return}o||(o=!0,setTimeout(()=>o=!1)),C()&&(o="action");var P=t.selection&&R.rangeRef(t,t.selection,{affinity:"forward"});po.set(t,t.marks),VS("flush",Do.get(t),sn.get(t));for(var A=D(),B;B=(S=sn.get(t))===null||S===void 0?void 0:S[0];){var S,I,N=Mn.get(t);N!==void 0&&(Mn.delete(t),t.marks=N),N&&u===!1&&(u=null);var F=HS(B);(!t.selection||!$e.equals(t.selection,F))&&Re.select(t,F),B.diff.text?R.insertText(t,B.diff.text):R.deleteFragment(t),sn.set(t,(I=sn.get(t))===null||I===void 0?void 0:I.filter(X=>{var{id:H}=X;return H!==B.id})),TS(t,B)||(A=!1,Do.delete(t),po.delete(t),o="action",So.delete(t),r.cancel(),n.cancel(),P==null||P.unref())}var M=P==null?void 0:P.unref();if(M&&!So.get(t)&&(!t.selection||!$e.equals(M,t.selection))&&Re.select(t,M),C()){f();return}A&&r(),r.flush(),n.flush(),c();var _=po.get(t);po.delete(t),_!==void 0&&(t.marks=_,t.onChange())},h=P=>{a&&clearTimeout(a),a=setTimeout(()=>{Wo.set(t,!1),p()},KS)},v=P=>{Wo.set(t,!0),a&&(clearTimeout(a),a=null)},g=function(){var P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,A=vd.get(t);if(A){if(D()||P){A.style.display="none";return}A.style.removeProperty("display")}},m=(P,A)=>{var B,S=(B=sn.get(t))!==null&&B!==void 0?B:[];sn.set(t,S);var I=Ge.leaf(t,P),N=S.findIndex(_=>ne.equals(_.path,P));if(N<0){var F=dy(I.text,A);F&&S.push({path:P,diff:A,id:s++}),g();return}var M=LS(I.text,S[N].diff,A);if(!M){S.splice(N,1),g();return}S[N]=Ll(Ll({},S[N]),{},{diff:M})},b=function(P){var{at:A}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};u=!1,So.delete(t),r.cancel(),n.cancel(),C()&&p(),Do.set(t,{at:A,run:P}),l=setTimeout(p)},y=P=>{var A;if(i&&(clearTimeout(i),i=null),!Fa.get(t)){var{inputType:B}=P,S=null,I=P.dataTransfer||P.data||void 0;u!==!1&&B!=="insertText"&&B!=="insertCompositionText"&&(u=!1);var[N]=P.getTargetRanges();N&&(S=Ae.toSlateRange(t,N,{exactMatch:!1,suppressThrow:!0}));var F=Ae.getWindow(t),M=F.getSelection();if(!S&&M&&(N=M,S=Ae.toSlateRange(t,M,{exactMatch:!1,suppressThrow:!0})),S=(A=S)!==null&&A!==void 0?A:t.selection,!!S){var _=!0;if(B.startsWith("delete")){if($e.isExpanded(S)){var[X,H]=$e.edges(S),q=Ge.leaf(t,X.path);if(q.text.length===X.offset&&H.offset===0){var Z=R.next(t,{at:X.path,match:ot.isText});Z&&ne.equals(Z[1],H.path)&&(S={anchor:H,focus:H})}}var te=B.endsWith("Backward")?"backward":"forward",[z,Y]=$e.edges(S),[V,U]=R.leaf(t,z.path),K={text:"",start:z.offset,end:Y.offset},W=sn.get(t),re=W==null?void 0:W.find(Le=>ne.equals(Le.path,U)),G=re?[re.diff,K]:[K],J=cy(V.text,...G);if(J.length===0&&(_=!1),$e.isExpanded(S)){if(_&&ne.equals(S.anchor.path,S.focus.path)){var oe={path:S.anchor.path,offset:z.offset},se=R.range(t,oe,oe);return E(se),m(S.anchor.path,{text:"",end:Y.offset,start:z.offset})}return b(()=>R.deleteFragment(t,{direction:te}),{at:S})}}switch(B){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":return b(()=>R.deleteFragment(t),{at:S});case"deleteContent":case"deleteContentForward":{var{anchor:ge}=S;if(_&&$e.isCollapsed(S)){var Ee=Ge.leaf(t,ge.path);if(ge.offset<Ee.text.length)return m(ge.path,{text:"",start:ge.offset,end:ge.offset+1})}return b(()=>R.deleteForward(t),{at:S})}case"deleteContentBackward":{var je,{anchor:ve}=S,ye=Cd(N)?N.isCollapsed:!!((je=N)!==null&&je!==void 0&&je.collapsed);return _&&ye&&$e.isCollapsed(S)&&ve.offset>0?m(ve.path,{text:"",start:ve.offset-1,end:ve.offset}):b(()=>R.deleteBackward(t),{at:S})}case"deleteEntireSoftLine":return b(()=>{R.deleteBackward(t,{unit:"line"}),R.deleteForward(t,{unit:"line"})},{at:S});case"deleteHardLineBackward":return b(()=>R.deleteBackward(t,{unit:"block"}),{at:S});case"deleteSoftLineBackward":return b(()=>R.deleteBackward(t,{unit:"line"}),{at:S});case"deleteHardLineForward":return b(()=>R.deleteForward(t,{unit:"block"}),{at:S});case"deleteSoftLineForward":return b(()=>R.deleteForward(t,{unit:"line"}),{at:S});case"deleteWordBackward":return b(()=>R.deleteBackward(t,{unit:"word"}),{at:S});case"deleteWordForward":return b(()=>R.deleteForward(t,{unit:"word"}),{at:S});case"insertLineBreak":return b(()=>R.insertSoftBreak(t),{at:S});case"insertParagraph":return b(()=>R.insertBreak(t),{at:S});case"insertCompositionText":case"deleteCompositionText":case"insertFromComposition":case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":{if(GS(I))return b(()=>Ae.insertData(t,I),{at:S});var ke=I??"";if(Mn.get(t)&&(ke=ke.replace("\uFEFF","")),B==="insertText"&&/.*\n.*\n$/.test(ke)&&(ke=ke.slice(0,-1)),ke.includes(`
|
|
20
|
+
`))return b(()=>{var Le=ke.split(`
|
|
21
|
+
`);Le.forEach((Fe,fe)=>{Fe&&R.insertText(t,Fe),fe!==Le.length-1&&R.insertSoftBreak(t)})},{at:S});if(ne.equals(S.anchor.path,S.focus.path)){var[we,De]=$e.edges(S),Ne={start:we.offset,end:De.offset,text:ke};if(ke&&u&&B==="insertCompositionText"){var Oe=u.start+u.text.search(/\S|$/),Xe=Ne.start+Ne.text.search(/\S|$/);Xe===Oe+1&&Ne.end===u.start+u.text.length?(Ne.start-=1,u=null,j()):u=!1}else B==="insertText"?u===null?u=Ne:u&&$e.isCollapsed(S)&&u.end+u.text.length===we.offset?u=Ll(Ll({},u),{},{text:u.text+ke}):u=!1:u=!1;if(_){m(we.path,Ne);return}}return b(()=>R.insertText(t,ke),{at:S})}}}}},C=()=>!!Do.get(t),D=()=>{var P;return!!((P=sn.get(t))!==null&&P!==void 0&&P.length)},w=()=>C()||D(),k=()=>o,E=P=>{So.set(t,P),i&&(clearTimeout(i),i=null);var{selection:A}=t;if(P){var B=!A||!ne.equals(A.anchor.path,P.anchor.path),S=!A||!ne.equals(A.anchor.path.slice(0,-1),P.anchor.path.slice(0,-1));(B&&u||S)&&(u=!1),(B||D())&&(i=setTimeout(p,qS))}},x=()=>{(C()||!D())&&p()},O=P=>{D()||(g(!0),setTimeout(g))},j=()=>{C()||(l=setTimeout(p))},$=P=>{if(!(D()||C())&&P.some(B=>pp(t,B,P))){var A;(A=oy.get(t))===null||A===void 0||A()}};return{flush:p,scheduleFlush:j,hasPendingDiffs:D,hasPendingAction:C,hasPendingChanges:w,isFlushing:k,handleUserSelect:E,handleCompositionEnd:h,handleCompositionStart:v,handleDOMBeforeInput:y,handleKeyDown:O,handleDomMutations:$,handleInput:x}}function US(){var e=qe(!1);return Ot(()=>(e.current=!0,()=>{e.current=!1}),[]),e.current}var Yi=as?Fb:Ot;function YS(e,t,r){var[n]=yt(()=>new MutationObserver(t));Yi(()=>{n.takeRecords()}),Ot(()=>{if(!e.current)throw new Error("Failed to attach MutationObserver, `node` is undefined");return n.observe(e.current,r),()=>n.disconnect()},[n,e,r])}var ZS=["node"];function tg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function JS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?tg(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):tg(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var QS={subtree:!0,childList:!0,characterData:!0},e$=en?e=>{var{node:t}=e,r=Ma(e,ZS);if(!en)return null;var n=Io(),o=US(),[a]=yt(()=>XS(JS({editor:n},r)));return YS(t,a.handleDomMutations,QS),dp.set(n,a.scheduleFlush),o&&a.flush(),a}:()=>null,t$=["anchor","focus"],r$=["anchor","focus"],n$=(e,t)=>Object.keys(e).length===Object.keys(t).length&&Object.keys(e).every(r=>t.hasOwnProperty(r)&&e[r]===t[r]),fy=(e,t)=>{var r=Ma(e,t$),n=Ma(t,r$);return e[Ta]===t[Ta]&&n$(r,n)},o$=(e,t)=>{if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++){var n=e[r],o=t[r];if(!$e.equals(n,o)||!fy(n,o))return!1}return!0},a$=(e,t)=>{if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++){var n=e[r],o=t[r];if(n.anchor.offset!==o.anchor.offset||n.focus.offset!==o.focus.offset||!fy(n,o))return!1}return!0};function rg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function i$(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?rg(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):rg(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var l$=e=>{var{isLast:t,leaf:r,parent:n,text:o}=e,a=Io(),i=Ae.findPath(a,o),l=ne.parent(i),s=!!r[ay];return a.isVoid(n)?ee.createElement(bc,{length:Ge.string(n).length}):r.text===""&&n.children[n.children.length-1]===o&&!a.isInline(n)&&R.string(a,l)===""?ee.createElement(bc,{isLineBreak:!0,isMarkPlaceholder:s}):r.text===""?ee.createElement(bc,{isMarkPlaceholder:s}):t&&r.text.slice(-1)===`
|
|
22
|
+
`?ee.createElement(ng,{isTrailing:!0,text:r.text}):ee.createElement(ng,{text:r.text})},ng=e=>{var{text:t,isTrailing:r=!1}=e,n=qe(null),o=()=>"".concat(t??"").concat(r?`
|
|
23
|
+
`:""),[a]=yt(o);return Yi(()=>{var i=o();n.current&&n.current.textContent!==i&&(n.current.textContent=i)}),ee.createElement(s$,{ref:n},a)},s$=Vw(dn((e,t)=>ee.createElement("span",{"data-slate-string":!0,ref:t},e.children))),bc=e=>{var{length:t=0,isLineBreak:r=!1,isMarkPlaceholder:n=!1}=e,o={"data-slate-zero-width":r?"n":"z","data-slate-length":t};return n&&(o["data-slate-mark-placeholder"]=!0),ee.createElement("span",i$({},o),!(en||ty)||!r?"\uFEFF":null,r?ee.createElement("br",null):null)};function og(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function py(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?og(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):og(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var u$=en?300:0;function c$(e,t){e.current&&(e.current.disconnect(),t&&(e.current=null))}function ag(e){e.current&&(clearTimeout(e.current),e.current=null)}var d$=e=>{var{leaf:t,isLast:r,text:n,parent:o,renderPlaceholder:a,renderLeaf:i=y=>ee.createElement(p$,py({},y))}=e,l=Io(),s=qe(null),u=qe(null),[c,f]=yt(!1),p=qe(null),h=mt(y=>{if(c$(s,y==null),y==null){var C;vd.delete(l),(C=t.onPlaceholderResize)===null||C===void 0||C.call(t,null)}else{if(vd.set(l,y),!s.current){var D=window.ResizeObserver||hS;s.current=new D(()=>{var w;(w=t.onPlaceholderResize)===null||w===void 0||w.call(t,y)})}s.current.observe(y),u.current=y}},[u,t,l]),v=ee.createElement(l$,{isLast:r,leaf:t,parent:o,text:n}),g=!!t[Ta];if(Ot(()=>(g?p.current||(p.current=setTimeout(()=>{f(!0),p.current=null},u$)):(ag(p),f(!1)),()=>ag(p)),[g,f]),g&&c){var m={children:t.placeholder,attributes:{"data-slate-placeholder":!0,style:{position:"absolute",top:0,pointerEvents:"none",width:"100%",maxWidth:"100%",display:"block",opacity:"0.333",userSelect:"none",textDecoration:"none",WebkitUserModify:Lo?"inherit":void 0},contentEditable:!1,ref:h}};v=ee.createElement(ee.Fragment,null,a(m),v)}var b={"data-slate-leaf":!0};return i({attributes:b,children:v,leaf:t,text:n})},f$=ee.memo(d$,(e,t)=>t.parent===e.parent&&t.isLast===e.isLast&&t.renderLeaf===e.renderLeaf&&t.renderPlaceholder===e.renderPlaceholder&&t.text===e.text&&ot.equals(t.leaf,e.leaf)&&t.leaf[Ta]===e.leaf[Ta]),p$=e=>{var{attributes:t,children:r}=e;return ee.createElement("span",py({},t),r)},m$=e=>{for(var{decorations:t,isLast:r,parent:n,renderPlaceholder:o,renderLeaf:a,text:i}=e,l=Io(),s=qe(null),u=ot.decorations(i,t),c=Ae.findKey(l,i),f=[],p=0;p<u.length;p++){var h=u[p];f.push(ee.createElement(f$,{isLast:r&&p===u.length-1,key:"".concat(c.id,"-").concat(p),renderPlaceholder:o,leaf:h,text:i,parent:n,renderLeaf:a}))}var v=mt(g=>{var m=lu.get(l);g?(m==null||m.set(c,g),Xo.set(i,g),Ui.set(g,i)):(m==null||m.delete(c),Xo.delete(i),s.current&&Ui.delete(s.current)),s.current=g},[s,l,c,i]);return ee.createElement("span",{"data-slate-node":"text",ref:v},f)},my=ee.memo(m$,(e,t)=>t.parent===e.parent&&t.isLast===e.isLast&&t.renderLeaf===e.renderLeaf&&t.renderPlaceholder===e.renderPlaceholder&&t.text===e.text&&a$(t.decorations,e.decorations));function ig(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ed(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ig(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ig(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var h$=e=>{var{decorations:t,element:r,renderElement:n=y=>ee.createElement(v$,Ed({},y)),renderPlaceholder:o,renderLeaf:a,selection:i}=e,l=Io(),s=C$(),u=l.isInline(r),c=Ae.findKey(l,r),f=mt(y=>{var C=lu.get(l);y?(C==null||C.set(c,y),Xo.set(r,y),Ui.set(y,r)):(C==null||C.delete(c),Xo.delete(r))},[l,c,r]),p=gy({decorations:t,node:r,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:i}),h={"data-slate-node":"element",ref:f};if(u&&(h["data-slate-inline"]=!0),!u&&R.hasInlines(l,r)){var v=Ge.string(r),g=Kb(v);g==="rtl"&&(h.dir=g)}if(R.isVoid(l,r)){h["data-slate-void"]=!0,!s&&u&&(h.contentEditable=!1);var m=u?"span":"div",[[b]]=Ge.texts(r);p=ee.createElement(m,{"data-slate-spacer":!0,style:{height:"0",color:"transparent",outline:"none",position:"absolute"}},ee.createElement(my,{renderPlaceholder:o,decorations:[],isLast:!1,parent:r,text:b})),up.set(b,0),cp.set(b,r)}return n({attributes:h,children:p,element:r})},g$=ee.memo(h$,(e,t)=>e.element===t.element&&e.renderElement===t.renderElement&&e.renderLeaf===t.renderLeaf&&e.renderPlaceholder===t.renderPlaceholder&&o$(e.decorations,t.decorations)&&(e.selection===t.selection||!!e.selection&&!!t.selection&&$e.equals(e.selection,t.selection))),v$=e=>{var{attributes:t,children:r,element:n}=e,o=Io(),a=o.isInline(n)?"span":"div";return ee.createElement(a,Ed(Ed({},t),{},{style:{position:"relative"}}),r)},hy=Fn(()=>[]),b$=()=>Rr(hy),y$=Fn(!1),gy=e=>{var{decorations:t,node:r,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:i}=e,l=b$(),s=Io();Fa.set(s,!1);for(var u=Ae.findPath(s,r),c=[],f=lt.isElement(r)&&!s.isInline(r)&&R.hasInlines(s,r),p=0;p<r.children.length;p++){var h=u.concat(p),v=r.children[p],g=Ae.findKey(s,v),m=R.range(s,h),b=i&&$e.intersection(m,i),y=l([v,h]);for(var C of t){var D=$e.intersection(C,m);D&&y.push(D)}lt.isElement(v)?c.push(ee.createElement(y$.Provider,{key:"provider-".concat(g.id),value:!!b},ee.createElement(g$,{decorations:y,element:v,key:g.id,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:b}))):c.push(ee.createElement(my,{decorations:y,key:g.id,isLast:f&&p===r.children.length-1,parent:r,renderPlaceholder:o,renderLeaf:a,text:v})),up.set(v,p),cp.set(v,r)}return c},vy=Fn(!1),C$=()=>Rr(vy),by=Fn(null),yy=()=>{var e=Rr(by);if(!e)throw new Error("The `useSlate` hook must be used inside the <Slate> component's context.");var{editor:t}=e;return t};function x$(){var e=Io(),t=qe(!1),r=qe(0),n=mt(()=>{if(!t.current){t.current=!0;var o=Ae.getWindow(e);o.cancelAnimationFrame(r.current),r.current=o.requestAnimationFrame(()=>{t.current=!1})}},[e]);return Ot(()=>()=>cancelAnimationFrame(r.current),[]),{receivedUserInput:t,onUserInput:n}}var w$=3,E$={bold:"mod+b",compose:["down","left","right","up","backspace","enter"],moveBackward:"left",moveForward:"right",moveWordBackward:"ctrl+left",moveWordForward:"ctrl+right",deleteBackward:"shift?+backspace",deleteForward:"shift?+delete",extendBackward:"shift+left",extendForward:"shift+right",italic:"mod+i",insertSoftBreak:"shift+enter",splitBlock:"enter",undo:"mod+z"},k$={moveLineBackward:"opt+up",moveLineForward:"opt+down",moveWordBackward:"opt+left",moveWordForward:"opt+right",deleteBackward:["ctrl+backspace","ctrl+h"],deleteForward:["ctrl+delete","ctrl+d"],deleteLineBackward:"cmd+shift?+backspace",deleteLineForward:["cmd+shift?+delete","ctrl+k"],deleteWordBackward:"opt+shift?+backspace",deleteWordForward:"opt+shift?+delete",extendLineBackward:"opt+shift+up",extendLineForward:"opt+shift+down",redo:"cmd+shift+z",transposeCharacter:"ctrl+t"},D$={deleteWordBackward:"ctrl+shift?+backspace",deleteWordForward:"ctrl+shift?+delete",redo:["ctrl+y","ctrl+shift+z"]},ir=e=>{var t=E$[e],r=k$[e],n=D$[e],o=t&&hc.isHotkey(t),a=r&&hc.isHotkey(r),i=n&&hc.isHotkey(n);return l=>!!(o&&o(l)||Yh&&a&&a(l)||!Yh&&i&&i(l))},cr={isBold:ir("bold"),isCompose:ir("compose"),isMoveBackward:ir("moveBackward"),isMoveForward:ir("moveForward"),isDeleteBackward:ir("deleteBackward"),isDeleteForward:ir("deleteForward"),isDeleteLineBackward:ir("deleteLineBackward"),isDeleteLineForward:ir("deleteLineForward"),isDeleteWordBackward:ir("deleteWordBackward"),isDeleteWordForward:ir("deleteWordForward"),isExtendBackward:ir("extendBackward"),isExtendForward:ir("extendForward"),isExtendLineBackward:ir("extendLineBackward"),isExtendLineForward:ir("extendLineForward"),isItalic:ir("italic"),isMoveLineBackward:ir("moveLineBackward"),isMoveLineForward:ir("moveLineForward"),isMoveWordBackward:ir("moveWordBackward"),isMoveWordForward:ir("moveWordForward"),isRedo:ir("redo"),isSoftBreak:ir("insertSoftBreak"),isSplitBlock:ir("splitBlock"),isTransposeCharacter:ir("transposeCharacter"),isUndo:ir("undo")},S$=(e,t)=>{var r=[],n=()=>{r=[]},o=i=>{if(t.current){var l=i.filter(s=>pp(e,s,i));r.push(...l)}};function a(){r.length>0&&(r.reverse().forEach(i=>{i.type!=="characterData"&&(i.removedNodes.forEach(l=>{i.target.insertBefore(l,i.nextSibling)}),i.addedNodes.forEach(l=>{i.target.removeChild(l)}))}),n())}return{registerMutations:o,restoreDOM:a,clear:n}},$$={subtree:!0,childList:!0,characterData:!0,characterDataOldValue:!0};class Cy extends qw{constructor(){super(...arguments),Bn(this,"context",null),Bn(this,"manager",null),Bn(this,"mutationObserver",null)}observe(){var t,{node:r}=this.props;if(!r.current)throw new Error("Failed to attach MutationObserver, `node` is undefined");(t=this.mutationObserver)===null||t===void 0||t.observe(r.current,$$)}componentDidMount(){var{receivedUserInput:t}=this.props,r=this.context;this.manager=S$(r,t),this.mutationObserver=new MutationObserver(this.manager.registerMutations),this.observe()}getSnapshotBeforeUpdate(){var t,r,n,o=(t=this.mutationObserver)===null||t===void 0?void 0:t.takeRecords();if(o!=null&&o.length){var a;(a=this.manager)===null||a===void 0||a.registerMutations(o)}return(r=this.mutationObserver)===null||r===void 0||r.disconnect(),(n=this.manager)===null||n===void 0||n.restoreDOM(),null}componentDidUpdate(){var t;(t=this.manager)===null||t===void 0||t.clear(),this.observe()}componentWillUnmount(){var t;(t=this.mutationObserver)===null||t===void 0||t.disconnect()}render(){return this.props.children}}Bn(Cy,"contextType",sp);var B$=en?Cy:e=>{var{children:t}=e;return ee.createElement(ee.Fragment,null,t)},O$=Fn(!1),A$=["autoFocus","decorate","onDOMBeforeInput","placeholder","readOnly","renderElement","renderLeaf","renderPlaceholder","scrollSelectionIntoView","style","as","disableDefaultStyles"],F$=["text"];function lg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function qn(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lg(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lg(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var N$=e=>ee.createElement(ee.Fragment,null,gy(e)),yc=dn((e,t)=>{var r=mt(z=>ee.createElement(P$,qn({},z)),[]),{autoFocus:n,decorate:o=j$,onDOMBeforeInput:a,placeholder:i,readOnly:l=!1,renderElement:s,renderLeaf:u,renderPlaceholder:c=r,scrollSelectionIntoView:f=I$,style:p={},as:h="div",disableDefaultStyles:v=!1}=e,g=Ma(e,A$),m=yy(),[b,y]=yt(!1),C=qe(null),D=qe([]),[w,k]=yt(),E=qe(!1),{onUserInput:x,receivedUserInput:O}=x$(),[,j]=Kw(z=>z+1,0);oy.set(m,j),bd.set(m,l);var $=xt(()=>({isDraggingInternally:!1,isUpdatingSelection:!1,latestElement:null,hasMarkPlaceholder:!1}),[]);Ot(()=>{C.current&&n&&C.current.focus()},[n]);var P=qe(),A=xt(()=>qD(()=>{if(Fa.get(m)){A();return}var z=Ae.toDOMNode(m,m),Y=z.getRootNode();if(!E.current&&Lo&&Y instanceof ShadowRoot){E.current=!0;var V=jS();V?document.execCommand("indent"):Re.deselect(m),E.current=!1;return}var U=P.current;if((en||!Ae.isComposing(m))&&(!$.isUpdatingSelection||U!=null&&U.isFlushing())&&!$.isDraggingInternally){var K=Ae.findDocumentOrShadowRoot(m),{activeElement:W}=K,re=Ae.toDOMNode(m,m),G=ji(K);if(W===re?($.latestElement=W,$o.set(m,!0)):$o.delete(m),!G)return Re.deselect(m);var{anchorNode:J,focusNode:oe}=G,se=Ae.hasEditableTarget(m,J)||Ae.isTargetInsideNonReadonlyVoid(m,J),ge=Ae.hasTarget(m,oe);if(se&&ge){var Ee=Ae.toSlateRange(m,G,{exactMatch:!1,suppressThrow:!0});Ee&&(!Ae.isComposing(m)&&!(U!=null&&U.hasPendingChanges())&&!(U!=null&&U.isFlushing())?Re.select(m,Ee):U==null||U.handleUserSelect(Ee))}l&&(!se||!ge)&&Re.deselect(m)}},100),[m,l,$]),B=xt(()=>HD(A,0),[A]);P.current=e$({node:C,onDOMSelectionChange:A,scheduleOnDOMSelectionChange:B}),Yi(()=>{var z,Y,V;C.current&&(V=fp(C.current))?(ny.set(m,V),is.set(m,C.current),Xo.set(m,C.current),Ui.set(C.current,m)):Xo.delete(m);var{selection:U}=m,K=Ae.findDocumentOrShadowRoot(m),W=ji(K);if(!(!W||!Ae.isFocused(m)||(z=P.current)!==null&&z!==void 0&&z.hasPendingAction())){var re=se=>{var ge=W.type!=="None";if(!(!U&&!ge)){var Ee=W.focusNode,je;if(Da&&W.rangeCount>1){var ve=W.getRangeAt(0),ye=W.getRangeAt(W.rangeCount-1);ve.startContainer===Ee?je=ye.endContainer:je=ve.startContainer}else je=W.anchorNode;var ke=is.get(m),we=!1;if(ke.contains(je)&&ke.contains(Ee)&&(we=!0),ge&&we&&U&&!se){var De=Ae.toSlateRange(m,W,{exactMatch:!0,suppressThrow:!0});if(De&&$e.equals(De,U)){var Ne;if(!$.hasMarkPlaceholder||(Ne=je)!==null&&Ne!==void 0&&(Ne=Ne.parentElement)!==null&&Ne!==void 0&&Ne.hasAttribute("data-slate-mark-placeholder"))return}}if(U&&!Ae.hasRange(m,U)){m.selection=Ae.toSlateRange(m,W,{exactMatch:!1,suppressThrow:!0});return}$.isUpdatingSelection=!0;var Oe=U&&Ae.toDOMRange(m,U);return Oe?(Ae.isComposing(m)&&!en?W.collapseToEnd():$e.isBackward(U)?W.setBaseAndExtent(Oe.endContainer,Oe.endOffset,Oe.startContainer,Oe.startOffset):W.setBaseAndExtent(Oe.startContainer,Oe.startOffset,Oe.endContainer,Oe.endOffset),f(m,Oe)):W.removeAllRanges(),Oe}};W.rangeCount<=1&&re();var G=((Y=P.current)===null||Y===void 0?void 0:Y.isFlushing())==="action";if(!en||!G){setTimeout(()=>{$.isUpdatingSelection=!1});return}var J=null,oe=requestAnimationFrame(()=>{if(G){var se=ge=>{try{var Ee=Ae.toDOMNode(m,m);Ee.focus(),re(ge)}catch{}};se(),J=setTimeout(()=>{se(!0),$.isUpdatingSelection=!1})}});return()=>{cancelAnimationFrame(oe),J&&clearTimeout(J)}}});var S=mt(z=>{var Y=Ae.toDOMNode(m,m),V=Y.getRootNode();if(E!=null&&E.current&&Lo&&V instanceof ShadowRoot){var U=z.getTargetRanges(),K=U[0],W=new window.Range;W.setStart(K.startContainer,K.startOffset),W.setEnd(K.endContainer,K.endOffset);var re=Ae.toSlateRange(m,W,{exactMatch:!1,suppressThrow:!1});Re.select(m,re),z.preventDefault(),z.stopImmediatePropagation();return}if(x(),!l&&Ae.hasEditableTarget(m,z.target)&&!R$(z,a)){var G;if(P.current)return P.current.handleDOMBeforeInput(z);B.flush(),A.flush();var{selection:J}=m,{inputType:oe}=z,se=z.dataTransfer||z.data||void 0,ge=oe==="insertCompositionText"||oe==="deleteCompositionText";if(ge&&Ae.isComposing(m))return;var Ee=!1;if(oe==="insertText"&&J&&$e.isCollapsed(J)&&z.data&&z.data.length===1&&/[a-z ]/i.test(z.data)&&J.anchor.offset!==0&&(Ee=!0,m.marks&&(Ee=!1),!Fa.get(m))){var je,ve,{anchor:ye}=J,[ke,we]=Ae.toDOMPoint(m,ye),De=(je=ke.parentElement)===null||je===void 0?void 0:je.closest("a"),Ne=Ae.getWindow(m);if(Ee&&De&&Ae.hasDOMNode(m,De)){var Oe,Xe=Ne==null?void 0:Ne.document.createTreeWalker(De,NodeFilter.SHOW_TEXT).lastChild();Xe===ke&&((Oe=Xe.textContent)===null||Oe===void 0?void 0:Oe.length)===we&&(Ee=!1)}if(Ee&&ke.parentElement&&(Ne==null||(ve=Ne.getComputedStyle(ke.parentElement))===null||ve===void 0?void 0:ve.whiteSpace)==="pre"){var Le=R.above(m,{at:ye.path,match:Ve=>lt.isElement(Ve)&&R.isBlock(m,Ve)});Le&&Ge.string(Le[0]).includes(" ")&&(Ee=!1)}}if((!oe.startsWith("delete")||oe.startsWith("deleteBy"))&&!Fa.get(m)){var[Fe]=z.getTargetRanges();if(Fe){var fe=Ae.toSlateRange(m,Fe,{exactMatch:!1,suppressThrow:!1});if(!J||!$e.equals(J,fe)){Ee=!1;var Be=!ge&&m.selection&&R.rangeRef(m,m.selection);Re.select(m,fe),Be&&Pi.set(m,Be)}}}if(ge)return;if(Ee||z.preventDefault(),J&&$e.isExpanded(J)&&oe.startsWith("delete")){var We=oe.endsWith("Backward")?"backward":"forward";R.deleteFragment(m,{direction:We});return}switch(oe){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":{R.deleteFragment(m);break}case"deleteContent":case"deleteContentForward":{R.deleteForward(m);break}case"deleteContentBackward":{R.deleteBackward(m);break}case"deleteEntireSoftLine":{R.deleteBackward(m,{unit:"line"}),R.deleteForward(m,{unit:"line"});break}case"deleteHardLineBackward":{R.deleteBackward(m,{unit:"block"});break}case"deleteSoftLineBackward":{R.deleteBackward(m,{unit:"line"});break}case"deleteHardLineForward":{R.deleteForward(m,{unit:"block"});break}case"deleteSoftLineForward":{R.deleteForward(m,{unit:"line"});break}case"deleteWordBackward":{R.deleteBackward(m,{unit:"word"});break}case"deleteWordForward":{R.deleteForward(m,{unit:"word"});break}case"insertLineBreak":R.insertSoftBreak(m);break;case"insertParagraph":{R.insertBreak(m);break}case"insertFromComposition":case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":{oe==="insertFromComposition"&&Ae.isComposing(m)&&(y(!1),Wo.set(m,!1)),(se==null?void 0:se.constructor.name)==="DataTransfer"?Ae.insertData(m,se):typeof se=="string"&&(Ee?D.current.push(()=>R.insertText(m,se)):R.insertText(m,se));break}}var Ye=(G=Pi.get(m))===null||G===void 0?void 0:G.unref();Pi.delete(m),Ye&&(!m.selection||!$e.equals(m.selection,Ye))&&Re.select(m,Ye)}},[m,A,x,a,l,B]),I=mt(z=>{z==null?(A.cancel(),B.cancel(),is.delete(m),Xo.delete(m),C.current&&Co&&C.current.removeEventListener("beforeinput",S)):Co&&z.addEventListener("beforeinput",S),C.current=z,typeof t=="function"?t(z):t&&(t.current=z)},[A,B,m,S,t]);Yi(()=>{var z=Ae.getWindow(m);z.document.addEventListener("selectionchange",B);var Y=()=>{$.isDraggingInternally=!1};return z.document.addEventListener("dragend",Y),z.document.addEventListener("drop",Y),()=>{z.document.removeEventListener("selectionchange",B),z.document.removeEventListener("dragend",Y),z.document.removeEventListener("drop",Y)}},[B,$]);var N=o([m,[]]),F=i&&m.children.length===1&&Array.from(Ge.texts(m)).length===1&&Ge.string(m)===""&&!b,M=mt(z=>{if(z&&F){var Y;k((Y=z.getBoundingClientRect())===null||Y===void 0?void 0:Y.height)}else k(void 0)},[F]);if(F){var _=R.start(m,[]);N.push({[Ta]:!0,placeholder:i,onPlaceholderResize:M,anchor:_,focus:_})}var{marks:X}=m;if($.hasMarkPlaceholder=!1,m.selection&&$e.isCollapsed(m.selection)&&X){var{anchor:H}=m.selection,q=Ge.leaf(m,H.path),Z=Ma(q,F$);if(!ot.equals(q,X,{loose:!0})){$.hasMarkPlaceholder=!0;var te=Object.fromEntries(Object.keys(Z).map(z=>[z,null]));N.push(qn(qn(qn({[ay]:!0},te),X),{},{anchor:H,focus:H}))}}return Ot(()=>{setTimeout(()=>{var{selection:z}=m;if(z){var{anchor:Y}=z,V=Ge.leaf(m,Y.path);if(X&&!ot.equals(V,X,{loose:!0})){Mn.set(m,X);return}}Mn.delete(m)})}),ee.createElement(vy.Provider,{value:l},ee.createElement(O$.Provider,{value:b},ee.createElement(hy.Provider,{value:o},ee.createElement(B$,{node:C,receivedUserInput:O},ee.createElement(h,qn(qn({role:l?void 0:"textbox","aria-multiline":l?void 0:!0},g),{},{spellCheck:Co||!as?g.spellCheck:!1,autoCorrect:Co||!as?g.autoCorrect:"false",autoCapitalize:Co||!as?g.autoCapitalize:"false","data-slate-editor":!0,"data-slate-node":"value",contentEditable:!l,zindex:-1,suppressContentEditableWarning:!0,ref:I,style:qn(qn({},v?{}:qn({position:"relative",whiteSpace:"pre-wrap",wordWrap:"break-word"},w?{minHeight:w}:{})),p),onBeforeInput:mt(z=>{if(!Co&&!l&&!Qr(z,g.onBeforeInput)&&Ae.hasSelectableTarget(m,z.target)&&(z.preventDefault(),!Ae.isComposing(m))){var Y=z.data;R.insertText(m,Y)}},[g.onBeforeInput,m,l]),onInput:mt(z=>{if(!Qr(z,g.onInput)){if(P.current){P.current.handleInput();return}for(var Y of D.current)Y();if(D.current=[],!Ae.isFocused(m)){var V=z.nativeEvent,U=m;if(V.inputType==="historyUndo"&&typeof U.undo=="function"){U.undo();return}if(V.inputType==="historyRedo"&&typeof U.redo=="function"){U.redo();return}}}},[g.onInput,m]),onBlur:mt(z=>{if(!(l||$.isUpdatingSelection||!Ae.hasSelectableTarget(m,z.target)||Qr(z,g.onBlur))){var Y=Ae.findDocumentOrShadowRoot(m);if($.latestElement!==Y.activeElement){var{relatedTarget:V}=z,U=Ae.toDOMNode(m,m);if(V!==U&&!($n(V)&&V.hasAttribute("data-slate-spacer"))){if(V!=null&&Fo(V)&&Ae.hasDOMNode(m,V)){var K=Ae.toSlateNode(m,V);if(lt.isElement(K)&&!m.isVoid(K))return}if(Lo){var W=ji(Y);W==null||W.removeAllRanges()}$o.delete(m)}}}},[l,$.isUpdatingSelection,$.latestElement,m,g.onBlur]),onClick:mt(z=>{if(Ae.hasTarget(m,z.target)&&!Qr(z,g.onClick)&&Fo(z.target)){var Y=Ae.toSlateNode(m,z.target),V=Ae.findPath(m,Y);if(!R.hasPath(m,V)||Ge.get(m,V)!==Y)return;if(z.detail===w$&&V.length>=1){var U=V;if(!(lt.isElement(Y)&&R.isBlock(m,Y))){var K,W=R.above(m,{match:Ee=>lt.isElement(Ee)&&R.isBlock(m,Ee),at:V});U=(K=W==null?void 0:W[1])!==null&&K!==void 0?K:V.slice(0,1)}var re=R.range(m,U);Re.select(m,re);return}if(l)return;var G=R.start(m,V),J=R.end(m,V),oe=R.void(m,{at:G}),se=R.void(m,{at:J});if(oe&&se&&ne.equals(oe[1],se[1])){var ge=R.range(m,G);Re.select(m,ge)}}},[m,g.onClick,l]),onCompositionEnd:mt(z=>{if(Ae.hasSelectableTarget(m,z.target)){var Y;if(Ae.isComposing(m)&&Promise.resolve().then(()=>{y(!1),Wo.set(m,!1)}),(Y=P.current)===null||Y===void 0||Y.handleCompositionEnd(z),Qr(z,g.onCompositionEnd)||en)return;if(!Lo&&!ES&&!ty&&!DS&&!kS&&z.data){var V=Mn.get(m);Mn.delete(m),V!==void 0&&(po.set(m,m.marks),m.marks=V),R.insertText(m,z.data);var U=po.get(m);po.delete(m),U!==void 0&&(m.marks=U)}}},[g.onCompositionEnd,m]),onCompositionUpdate:mt(z=>{Ae.hasSelectableTarget(m,z.target)&&!Qr(z,g.onCompositionUpdate)&&(Ae.isComposing(m)||(y(!0),Wo.set(m,!0)))},[g.onCompositionUpdate,m]),onCompositionStart:mt(z=>{if(Ae.hasSelectableTarget(m,z.target)){var Y;if((Y=P.current)===null||Y===void 0||Y.handleCompositionStart(z),Qr(z,g.onCompositionStart)||en)return;y(!0);var{selection:V}=m;if(V&&$e.isExpanded(V)){R.deleteFragment(m);return}}},[g.onCompositionStart,m]),onCopy:mt(z=>{Ae.hasSelectableTarget(m,z.target)&&!Qr(z,g.onCopy)&&!sg(z)&&(z.preventDefault(),Ae.setFragmentData(m,z.clipboardData,"copy"))},[g.onCopy,m]),onCut:mt(z=>{if(!l&&Ae.hasSelectableTarget(m,z.target)&&!Qr(z,g.onCut)&&!sg(z)){z.preventDefault(),Ae.setFragmentData(m,z.clipboardData,"cut");var{selection:Y}=m;if(Y)if($e.isExpanded(Y))R.deleteFragment(m);else{var V=Ge.parent(m,Y.anchor.path);R.isVoid(m,V)&&Re.delete(m)}}},[l,m,g.onCut]),onDragOver:mt(z=>{if(Ae.hasTarget(m,z.target)&&!Qr(z,g.onDragOver)){var Y=Ae.toSlateNode(m,z.target);lt.isElement(Y)&&R.isVoid(m,Y)&&z.preventDefault()}},[g.onDragOver,m]),onDragStart:mt(z=>{if(!l&&Ae.hasTarget(m,z.target)&&!Qr(z,g.onDragStart)){var Y=Ae.toSlateNode(m,z.target),V=Ae.findPath(m,Y),U=lt.isElement(Y)&&R.isVoid(m,Y)||R.void(m,{at:V,voids:!0});if(U){var K=R.range(m,V);Re.select(m,K)}$.isDraggingInternally=!0,Ae.setFragmentData(m,z.dataTransfer,"drag")}},[l,m,g.onDragStart,$]),onDrop:mt(z=>{if(!l&&Ae.hasTarget(m,z.target)&&!Qr(z,g.onDrop)){z.preventDefault();var Y=m.selection,V=Ae.findEventRange(m,z),U=z.dataTransfer;Re.select(m,V),$.isDraggingInternally&&Y&&!$e.equals(Y,V)&&!R.void(m,{at:V,voids:!0})&&Re.delete(m,{at:Y}),Ae.insertData(m,U),Ae.isFocused(m)||Ae.focus(m)}},[l,m,g.onDrop,$]),onDragEnd:mt(z=>{!l&&$.isDraggingInternally&&g.onDragEnd&&Ae.hasTarget(m,z.target)&&g.onDragEnd(z)},[l,$,g,m]),onFocus:mt(z=>{if(!l&&!$.isUpdatingSelection&&Ae.hasEditableTarget(m,z.target)&&!Qr(z,g.onFocus)){var Y=Ae.toDOMNode(m,m),V=Ae.findDocumentOrShadowRoot(m);if($.latestElement=V.activeElement,Da&&z.target!==Y){Y.focus();return}$o.set(m,!0)}},[l,$,m,g.onFocus]),onKeyDown:mt(z=>{if(!l&&Ae.hasEditableTarget(m,z.target)){var Y;(Y=P.current)===null||Y===void 0||Y.handleKeyDown(z);var{nativeEvent:V}=z;if(Ae.isComposing(m)&&V.isComposing===!1&&(Wo.set(m,!1),y(!1)),Qr(z,g.onKeyDown)||Ae.isComposing(m))return;var{selection:U}=m,K=m.children[U!==null?U.focus.path[0]:0],W=Kb(Ge.string(K))==="rtl";if(cr.isRedo(V)){z.preventDefault();var re=m;typeof re.redo=="function"&&re.redo();return}if(cr.isUndo(V)){z.preventDefault();var G=m;typeof G.undo=="function"&&G.undo();return}if(cr.isMoveLineBackward(V)){z.preventDefault(),Re.move(m,{unit:"line",reverse:!0});return}if(cr.isMoveLineForward(V)){z.preventDefault(),Re.move(m,{unit:"line"});return}if(cr.isExtendLineBackward(V)){z.preventDefault(),Re.move(m,{unit:"line",edge:"focus",reverse:!0});return}if(cr.isExtendLineForward(V)){z.preventDefault(),Re.move(m,{unit:"line",edge:"focus"});return}if(cr.isMoveBackward(V)){z.preventDefault(),U&&$e.isCollapsed(U)?Re.move(m,{reverse:!W}):Re.collapse(m,{edge:W?"end":"start"});return}if(cr.isMoveForward(V)){z.preventDefault(),U&&$e.isCollapsed(U)?Re.move(m,{reverse:W}):Re.collapse(m,{edge:W?"start":"end"});return}if(cr.isMoveWordBackward(V)){z.preventDefault(),U&&$e.isExpanded(U)&&Re.collapse(m,{edge:"focus"}),Re.move(m,{unit:"word",reverse:!W});return}if(cr.isMoveWordForward(V)){z.preventDefault(),U&&$e.isExpanded(U)&&Re.collapse(m,{edge:"focus"}),Re.move(m,{unit:"word",reverse:W});return}if(Co){if((ry||Lo)&&U&&(cr.isDeleteBackward(V)||cr.isDeleteForward(V))&&$e.isCollapsed(U)){var J=Ge.parent(m,U.anchor.path);if(lt.isElement(J)&&R.isVoid(m,J)&&(R.isInline(m,J)||R.isBlock(m,J))){z.preventDefault(),R.deleteBackward(m,{unit:"block"});return}}}else{if(cr.isBold(V)||cr.isItalic(V)||cr.isTransposeCharacter(V)){z.preventDefault();return}if(cr.isSoftBreak(V)){z.preventDefault(),R.insertSoftBreak(m);return}if(cr.isSplitBlock(V)){z.preventDefault(),R.insertBreak(m);return}if(cr.isDeleteBackward(V)){z.preventDefault(),U&&$e.isExpanded(U)?R.deleteFragment(m,{direction:"backward"}):R.deleteBackward(m);return}if(cr.isDeleteForward(V)){z.preventDefault(),U&&$e.isExpanded(U)?R.deleteFragment(m,{direction:"forward"}):R.deleteForward(m);return}if(cr.isDeleteLineBackward(V)){z.preventDefault(),U&&$e.isExpanded(U)?R.deleteFragment(m,{direction:"backward"}):R.deleteBackward(m,{unit:"line"});return}if(cr.isDeleteLineForward(V)){z.preventDefault(),U&&$e.isExpanded(U)?R.deleteFragment(m,{direction:"forward"}):R.deleteForward(m,{unit:"line"});return}if(cr.isDeleteWordBackward(V)){z.preventDefault(),U&&$e.isExpanded(U)?R.deleteFragment(m,{direction:"backward"}):R.deleteBackward(m,{unit:"word"});return}if(cr.isDeleteWordForward(V)){z.preventDefault(),U&&$e.isExpanded(U)?R.deleteFragment(m,{direction:"forward"}):R.deleteForward(m,{unit:"word"});return}}}},[l,m,g.onKeyDown]),onPaste:mt(z=>{!l&&Ae.hasEditableTarget(m,z.target)&&!Qr(z,g.onPaste)&&(!Co||BS(z.nativeEvent)||Lo)&&(z.preventDefault(),Ae.insertData(m,z.clipboardData))},[l,m,g.onPaste])}),ee.createElement(N$,{decorations:N,node:m,renderElement:s,renderPlaceholder:c,renderLeaf:u,selection:m.selection}))))))}),P$=e=>{var{attributes:t,children:r}=e;return ee.createElement("span",qn({},t),r,en&&ee.createElement("br",null))},j$=()=>[],I$=(e,t)=>{if(t.getBoundingClientRect&&(!e.selection||e.selection&&$e.isCollapsed(e.selection))){var r=t.startContainer.parentElement;r.getBoundingClientRect=t.getBoundingClientRect.bind(t),XD(r,{scrollMode:"if-needed"}),delete r.getBoundingClientRect}},Qr=(e,t)=>{if(!t)return!1;var r=t(e);return r??(e.isDefaultPrevented()||e.isPropagationStopped())},sg=e=>Fo(e.target)&&(e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement),R$=(e,t)=>{if(!t)return!1;var r=t(e);return r??e.defaultPrevented},M$=Fn(!1),T$=Fn({});function z$(e){var t=qe([]).current,r=qe({editor:e}).current,n=mt(a=>{r.editor=a,t.forEach(i=>i(a))},[t,r]),o=xt(()=>({getSlate:()=>r.editor,addEventListener:a=>(t.push(a),()=>{t.splice(t.indexOf(a),1)})}),[t,r]);return{selectorContext:o,onChange:n}}var _$=["editor","children","onChange","onSelectionChange","onValueChange","initialValue"],Cc=e=>{var{editor:t,children:r,onChange:n,onSelectionChange:o,onValueChange:a,initialValue:i}=e,l=Ma(e,_$),[s,u]=ee.useState(()=>{if(!Ge.isNodeList(i))throw new Error("[Slate] initialValue is invalid! Expected a list of elements but got: ".concat(Ir.stringify(i)));if(!R.isEditor(t))throw new Error("[Slate] editor is invalid! You passed: ".concat(Ir.stringify(t)));return t.children=i,Object.assign(t,l),{v:0,editor:t}}),{selectorContext:c,onChange:f}=z$(t),p=mt(g=>{var m;switch(n&&n(t.children),g==null||(m=g.operation)===null||m===void 0?void 0:m.type){case"set_selection":o==null||o(t.selection);break;default:a==null||a(t.children)}u(b=>({v:b.v+1,editor:t})),f(t)},[t,f,n,o,a]);Ot(()=>(yd.set(t,p),()=>{yd.set(t,()=>{})}),[t,p]);var[h,v]=yt(Ae.isFocused(t));return Ot(()=>{v(Ae.isFocused(t))},[t]),Yi(()=>{var g=()=>v(Ae.isFocused(t));return ey>=17?(document.addEventListener("focusin",g),document.addEventListener("focusout",g),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",g)}):(document.addEventListener("focus",g,!0),document.addEventListener("blur",g,!0),()=>{document.removeEventListener("focus",g,!0),document.removeEventListener("blur",g,!0)})},[]),ee.createElement(T$.Provider,{value:c},ee.createElement(by.Provider,{value:s},ee.createElement(sp.Provider,{value:s.editor},ee.createElement(M$.Provider,{value:h},r))))},ug=(e,t)=>{var r=(t.top+t.bottom)/2;return e.top<=r&&e.bottom>=r},cg=(e,t,r)=>{var n=Ae.toDOMRange(e,t).getBoundingClientRect(),o=Ae.toDOMRange(e,r).getBoundingClientRect();return ug(n,o)&&ug(o,n)},L$=(e,t)=>{var r=R.range(e,$e.end(t)),n=Array.from(R.positions(e,{at:t})),o=0,a=n.length,i=Math.floor(a/2);if(cg(e,R.range(e,n[o]),r))return R.range(e,n[o],r);if(n.length<2)return R.range(e,n[n.length-1],r);for(;i!==n.length&&i!==o;)cg(e,R.range(e,n[i]),r)?a=i:o=i,i=Math.floor((o+a)/2);return R.range(e,n[a],r)};function dg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function fg(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?dg(Object(r),!0).forEach(function(n){Bn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dg(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var H$=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"x-slate-fragment",r=e,{apply:n,onChange:o,deleteBackward:a,addMark:i,removeMark:l}=r;return lu.set(r,new WeakMap),r.addMark=(s,u)=>{var c,f;(c=dp.get(r))===null||c===void 0||c(),!Mn.get(r)&&(f=sn.get(r))!==null&&f!==void 0&&f.length&&Mn.set(r,null),po.delete(r),i(s,u)},r.removeMark=s=>{var u;!Mn.get(r)&&(u=sn.get(r))!==null&&u!==void 0&&u.length&&Mn.set(r,null),po.delete(r),l(s)},r.deleteBackward=s=>{if(s!=="line")return a(s);if(r.selection&&$e.isCollapsed(r.selection)){var u=R.above(r,{match:h=>lt.isElement(h)&&R.isBlock(r,h),at:r.selection});if(u){var[,c]=u,f=R.range(r,c,r.selection.anchor),p=L$(r,f);$e.isCollapsed(p)||Re.delete(r,{at:p})}}},r.apply=s=>{var u=[],c=[],f=sn.get(r);if(f!=null&&f.length){var p=f.map(A=>WS(A,s)).filter(Boolean);sn.set(r,p)}var h=So.get(r);h&&So.set(r,Qh(r,h,s));var v=Do.get(r);if(v!=null&&v.at){var g=Rt.isPoint(v==null?void 0:v.at)?wd(r,v.at,s):Qh(r,v.at,s);Do.set(r,g?fg(fg({},v),{},{at:g}):null)}switch(s.type){case"insert_text":case"remove_text":case"set_node":case"split_node":{u.push(...pa(r,s.path));break}case"set_selection":{var m;(m=Pi.get(r))===null||m===void 0||m.unref(),Pi.delete(r);break}case"insert_node":case"remove_node":{u.push(...pa(r,ne.parent(s.path)));break}case"merge_node":{var b=ne.previous(s.path);u.push(...pa(r,b));break}case"move_node":{var y=ne.common(ne.parent(s.path),ne.parent(s.newPath));u.push(...pa(r,y));var C;ne.isBefore(s.path,s.newPath)?(u.push(...pa(r,ne.parent(s.path))),C=s.newPath):(u.push(...pa(r,ne.parent(s.newPath))),C=s.path);var D=Ge.get(e,ne.parent(C)),w=Ae.findKey(r,D),k=R.pathRef(r,ne.parent(C));c.push([k,w]);break}}switch(n(s),s.type){case"insert_node":case"remove_node":case"merge_node":case"move_node":case"split_node":Fa.set(r,!0)}for(var[E,x]of u){var[O]=R.node(r,E);As.set(O,x)}for(var[j,$]of c){if(j.current){var[P]=R.node(r,j.current);As.set(P,$)}j.unref()}},r.setFragmentData=s=>{var{selection:u}=r;if(u){var[c,f]=$e.edges(u),p=R.void(r,{at:c.path}),h=R.void(r,{at:f.path});if(!($e.isCollapsed(u)&&!p)){var v=Ae.toDOMRange(r,u),g=v.cloneContents(),m=g.childNodes[0];if(g.childNodes.forEach(O=>{O.textContent&&O.textContent.trim()!==""&&(m=O)}),h){var[b]=h,y=v.cloneRange(),C=Ae.toDOMNode(r,b);y.setEndAfter(C),g=y.cloneContents()}if(p&&(m=g.querySelector("[data-slate-spacer]")),Array.from(g.querySelectorAll("[data-slate-zero-width]")).forEach(O=>{var j=O.getAttribute("data-slate-zero-width")==="n";O.textContent=j?`
|
|
24
|
+
`:""}),ly(m)){var D=m.ownerDocument.createElement("span");D.style.whiteSpace="pre",D.appendChild(m),g.appendChild(D),m=D}var w=r.getFragment(),k=JSON.stringify(w),E=window.btoa(encodeURIComponent(k));m.setAttribute("data-slate-fragment",E),s.setData("application/".concat(t),E);var x=g.ownerDocument.createElement("div");return x.appendChild(g),x.setAttribute("hidden","true"),g.ownerDocument.body.appendChild(x),s.setData("text/html",x.innerHTML),s.setData("text/plain",uy(x)),g.ownerDocument.body.removeChild(x),s}}},r.insertData=s=>{r.insertFragmentData(s)||r.insertTextData(s)},r.insertFragmentData=s=>{var u=s.getData("application/".concat(t))||PS(s);if(u){var c=decodeURIComponent(window.atob(u)),f=JSON.parse(c);return r.insertFragment(f),!0}return!1},r.insertTextData=s=>{var u=s.getData("text/plain");if(u){var c=u.split(/\r\n|\r|\n/),f=!1;for(var p of c)f&&Re.splitNodes(r,{always:!0}),r.insertText(p),f=!0;return!0}return!1},r.onChange=s=>{var u=ey<18?Wi.unstable_batchedUpdates:c=>c();u(()=>{var c=yd.get(r);c&&c(s),o(s)})},r},pa=(e,t)=>{var r=[];for(var[n,o]of R.levels(e,{at:t})){var a=Ae.findKey(e,n);r.push([o,a])}return r};function mp(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var ia=mp();function xy(e){ia=e}var Ii={exec:()=>null};function Yt(e,t=""){let r=typeof e=="string"?e:e.source;const n={replace:(o,a)=>{let i=typeof a=="string"?a:a.source;return i=i.replace(tn.caret,"$1"),r=r.replace(o,i),n},getRegex:()=>new RegExp(r,t)};return n}var tn={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},W$=/^(?:[ \t]*(?:\n|$))+/,K$=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,q$=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,bl=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,V$=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hp=/(?:[*+-]|\d{1,9}[.)])/,wy=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Ey=Yt(wy).replace(/bull/g,hp).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),G$=Yt(wy).replace(/bull/g,hp).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),gp=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,X$=/^[^\n]+/,vp=/(?!\s*\])(?:\\.|[^\[\]\\])+/,U$=Yt(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",vp).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Y$=Yt(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,hp).getRegex(),su="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",bp=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Z$=Yt("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",bp).replace("tag",su).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),ky=Yt(gp).replace("hr",bl).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",su).getRegex(),J$=Yt(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",ky).getRegex(),yp={blockquote:J$,code:K$,def:U$,fences:q$,heading:V$,hr:bl,html:Z$,lheading:Ey,list:Y$,newline:W$,paragraph:ky,table:Ii,text:X$},pg=Yt("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",bl).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",su).getRegex(),Q$={...yp,lheading:G$,table:pg,paragraph:Yt(gp).replace("hr",bl).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",pg).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",su).getRegex()},e2={...yp,html:Yt(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",bp).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Ii,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Yt(gp).replace("hr",bl).replace("heading",` *#{1,6} *[^
|
|
25
|
+
]`).replace("lheading",Ey).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},t2=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,r2=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Dy=/^( {2,}|\\)\n(?!\s*$)/,n2=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,uu=/[\p{P}\p{S}]/u,Cp=/[\s\p{P}\p{S}]/u,Sy=/[^\s\p{P}\p{S}]/u,o2=Yt(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,Cp).getRegex(),$y=/(?!~)[\p{P}\p{S}]/u,a2=/(?!~)[\s\p{P}\p{S}]/u,i2=/(?:[^\s\p{P}\p{S}]|~)/u,l2=/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,By=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,s2=Yt(By,"u").replace(/punct/g,uu).getRegex(),u2=Yt(By,"u").replace(/punct/g,$y).getRegex(),Oy="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",c2=Yt(Oy,"gu").replace(/notPunctSpace/g,Sy).replace(/punctSpace/g,Cp).replace(/punct/g,uu).getRegex(),d2=Yt(Oy,"gu").replace(/notPunctSpace/g,i2).replace(/punctSpace/g,a2).replace(/punct/g,$y).getRegex(),f2=Yt("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Sy).replace(/punctSpace/g,Cp).replace(/punct/g,uu).getRegex(),p2=Yt(/\\(punct)/,"gu").replace(/punct/g,uu).getRegex(),m2=Yt(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),h2=Yt(bp).replace("(?:-->|$)","-->").getRegex(),g2=Yt("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",h2).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Fs=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,v2=Yt(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",Fs).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Ay=Yt(/^!?\[(label)\]\[(ref)\]/).replace("label",Fs).replace("ref",vp).getRegex(),Fy=Yt(/^!?\[(ref)\](?:\[\])?/).replace("ref",vp).getRegex(),b2=Yt("reflink|nolink(?!\\()","g").replace("reflink",Ay).replace("nolink",Fy).getRegex(),xp={_backpedal:Ii,anyPunctuation:p2,autolink:m2,blockSkip:l2,br:Dy,code:r2,del:Ii,emStrongLDelim:s2,emStrongRDelimAst:c2,emStrongRDelimUnd:f2,escape:t2,link:v2,nolink:Fy,punctuation:o2,reflink:Ay,reflinkSearch:b2,tag:g2,text:n2,url:Ii},y2={...xp,link:Yt(/^!?\[(label)\]\((.*?)\)/).replace("label",Fs).getRegex(),reflink:Yt(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Fs).getRegex()},kd={...xp,emStrongRDelimAst:d2,emStrongLDelim:u2,url:Yt(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},C2={...kd,br:Yt(Dy).replace("{2,}","*").getRegex(),text:Yt(kd.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},Hl={normal:yp,gfm:Q$,pedantic:e2},gi={normal:xp,gfm:kd,breaks:C2,pedantic:y2},x2={"&":"&","<":"<",">":">",'"':""","'":"'"},mg=e=>x2[e];function Vn(e,t){if(t){if(tn.escapeTest.test(e))return e.replace(tn.escapeReplace,mg)}else if(tn.escapeTestNoEncode.test(e))return e.replace(tn.escapeReplaceNoEncode,mg);return e}function hg(e){try{e=encodeURI(e).replace(tn.percentDecode,"%")}catch{return null}return e}function gg(e,t){var a;const r=e.replace(tn.findPipe,(i,l,s)=>{let u=!1,c=l;for(;--c>=0&&s[c]==="\\";)u=!u;return u?"|":" |"}),n=r.split(tn.splitPipe);let o=0;if(n[0].trim()||n.shift(),n.length>0&&!((a=n.at(-1))!=null&&a.trim())&&n.pop(),t)if(n.length>t)n.splice(t);else for(;n.length<t;)n.push("");for(;o<n.length;o++)n[o]=n[o].trim().replace(tn.slashPipe,"|");return n}function vi(e,t,r){const n=e.length;if(n===0)return"";let o=0;for(;o<n&&e.charAt(n-o-1)===t;)o++;return e.slice(0,n-o)}function w2(e,t){if(e.indexOf(t[1])===-1)return-1;let r=0;for(let n=0;n<e.length;n++)if(e[n]==="\\")n++;else if(e[n]===t[0])r++;else if(e[n]===t[1]&&(r--,r<0))return n;return r>0?-2:-1}function vg(e,t,r,n,o){const a=t.href,i=t.title||null,l=e[1].replace(o.other.outputLinkReplace,"$1");n.state.inLink=!0;const s={type:e[0].charAt(0)==="!"?"image":"link",raw:r,href:a,title:i,text:l,tokens:n.inlineTokens(l)};return n.state.inLink=!1,s}function E2(e,t,r){const n=e.match(r.other.indentCodeCompensation);if(n===null)return t;const o=n[1];return t.split(`
|
|
26
|
+
`).map(a=>{const i=a.match(r.other.beginningSpace);if(i===null)return a;const[l]=i;return l.length>=o.length?a.slice(o.length):a}).join(`
|
|
27
|
+
`)}var Ns=class{constructor(e){rr(this,"options"),rr(this,"rules"),rr(this,"lexer"),this.options=e||ia}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const r=t[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?r:vi(r,`
|
|
28
|
+
`)}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const r=t[0],n=E2(r,t[3]||"",this.rules);return{type:"code",raw:r,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:n}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let r=t[2].trim();if(this.rules.other.endingHash.test(r)){const n=vi(r,"#");(this.options.pedantic||!n||this.rules.other.endingSpaceChar.test(n))&&(r=n.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:vi(t[0],`
|
|
29
|
+
`)}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){let r=vi(t[0],`
|
|
30
|
+
`).split(`
|
|
31
|
+
`),n="",o="";const a=[];for(;r.length>0;){let i=!1;const l=[];let s;for(s=0;s<r.length;s++)if(this.rules.other.blockquoteStart.test(r[s]))l.push(r[s]),i=!0;else if(!i)l.push(r[s]);else break;r=r.slice(s);const u=l.join(`
|
|
32
|
+
`),c=u.replace(this.rules.other.blockquoteSetextReplace,`
|
|
33
|
+
$1`).replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}
|
|
34
|
+
${u}`:u,o=o?`${o}
|
|
35
|
+
${c}`:c;const f=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(c,a,!0),this.lexer.state.top=f,r.length===0)break;const p=a.at(-1);if((p==null?void 0:p.type)==="code")break;if((p==null?void 0:p.type)==="blockquote"){const h=p,v=h.raw+`
|
|
36
|
+
`+r.join(`
|
|
37
|
+
`),g=this.blockquote(v);a[a.length-1]=g,n=n.substring(0,n.length-h.raw.length)+g.raw,o=o.substring(0,o.length-h.text.length)+g.text;break}else if((p==null?void 0:p.type)==="list"){const h=p,v=h.raw+`
|
|
38
|
+
`+r.join(`
|
|
39
|
+
`),g=this.list(v);a[a.length-1]=g,n=n.substring(0,n.length-p.raw.length)+g.raw,o=o.substring(0,o.length-h.raw.length)+g.raw,r=v.substring(a.at(-1).raw.length).split(`
|
|
40
|
+
`);continue}}return{type:"blockquote",raw:n,tokens:a,text:o}}}list(e){let t=this.rules.block.list.exec(e);if(t){let r=t[1].trim();const n=r.length>1,o={type:"list",raw:"",ordered:n,start:n?+r.slice(0,-1):"",loose:!1,items:[]};r=n?`\\d{1,9}\\${r.slice(-1)}`:`\\${r}`,this.options.pedantic&&(r=n?r:"[*+-]");const a=this.rules.other.listItemRegex(r);let i=!1;for(;e;){let s=!1,u="",c="";if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;u=t[0],e=e.substring(u.length);let f=t[2].split(`
|
|
41
|
+
`,1)[0].replace(this.rules.other.listReplaceTabs,b=>" ".repeat(3*b.length)),p=e.split(`
|
|
42
|
+
`,1)[0],h=!f.trim(),v=0;if(this.options.pedantic?(v=2,c=f.trimStart()):h?v=t[1].length+1:(v=t[2].search(this.rules.other.nonSpaceChar),v=v>4?1:v,c=f.slice(v),v+=t[1].length),h&&this.rules.other.blankLine.test(p)&&(u+=p+`
|
|
43
|
+
`,e=e.substring(p.length+1),s=!0),!s){const b=this.rules.other.nextBulletRegex(v),y=this.rules.other.hrRegex(v),C=this.rules.other.fencesBeginRegex(v),D=this.rules.other.headingBeginRegex(v),w=this.rules.other.htmlBeginRegex(v);for(;e;){const k=e.split(`
|
|
44
|
+
`,1)[0];let E;if(p=k,this.options.pedantic?(p=p.replace(this.rules.other.listReplaceNesting," "),E=p):E=p.replace(this.rules.other.tabCharGlobal," "),C.test(p)||D.test(p)||w.test(p)||b.test(p)||y.test(p))break;if(E.search(this.rules.other.nonSpaceChar)>=v||!p.trim())c+=`
|
|
45
|
+
`+E.slice(v);else{if(h||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||C.test(f)||D.test(f)||y.test(f))break;c+=`
|
|
46
|
+
`+p}!h&&!p.trim()&&(h=!0),u+=k+`
|
|
47
|
+
`,e=e.substring(k.length+1),f=E.slice(v)}}o.loose||(i?o.loose=!0:this.rules.other.doubleBlankLine.test(u)&&(i=!0));let g=null,m;this.options.gfm&&(g=this.rules.other.listIsTask.exec(c),g&&(m=g[0]!=="[ ] ",c=c.replace(this.rules.other.listReplaceTask,""))),o.items.push({type:"list_item",raw:u,task:!!g,checked:m,loose:!1,text:c,tokens:[]}),o.raw+=u}const l=o.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;o.raw=o.raw.trimEnd();for(let s=0;s<o.items.length;s++)if(this.lexer.state.top=!1,o.items[s].tokens=this.lexer.blockTokens(o.items[s].text,[]),!o.loose){const u=o.items[s].tokens.filter(f=>f.type==="space"),c=u.length>0&&u.some(f=>this.rules.other.anyLine.test(f.raw));o.loose=c}if(o.loose)for(let s=0;s<o.items.length;s++)o.items[s].loose=!0;return o}}html(e){const t=this.rules.block.html.exec(e);if(t)return{type:"html",block:!0,raw:t[0],pre:t[1]==="pre"||t[1]==="script"||t[1]==="style",text:t[0]}}def(e){const t=this.rules.block.def.exec(e);if(t){const r=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",o=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:r,raw:t[0],href:n,title:o}}}table(e){var i;const t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;const r=gg(t[1]),n=t[2].replace(this.rules.other.tableAlignChars,"").split("|"),o=(i=t[3])!=null&&i.trim()?t[3].replace(this.rules.other.tableRowBlankLine,"").split(`
|
|
48
|
+
`):[],a={type:"table",raw:t[0],header:[],align:[],rows:[]};if(r.length===n.length){for(const l of n)this.rules.other.tableAlignRight.test(l)?a.align.push("right"):this.rules.other.tableAlignCenter.test(l)?a.align.push("center"):this.rules.other.tableAlignLeft.test(l)?a.align.push("left"):a.align.push(null);for(let l=0;l<r.length;l++)a.header.push({text:r[l],tokens:this.lexer.inline(r[l]),header:!0,align:a.align[l]});for(const l of o)a.rows.push(gg(l,a.header.length).map((s,u)=>({text:s,tokens:this.lexer.inline(s),header:!1,align:a.align[u]})));return a}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[2].charAt(0)==="="?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const r=t[1].charAt(t[1].length-1)===`
|
|
49
|
+
`?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:r,tokens:this.lexer.inline(r)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const r=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;const a=vi(r.slice(0,-1),"\\");if((r.length-a.length)%2===0)return}else{const a=w2(t[2],"()");if(a===-2)return;if(a>-1){const i=(t[0].indexOf("!")===0?5:4)+t[1].length+a;t[2]=t[2].substring(0,a),t[0]=t[0].substring(0,i).trim(),t[3]=""}}let n=t[2],o="";if(this.options.pedantic){const a=this.rules.other.pedanticHrefTitle.exec(n);a&&(n=a[1],o=a[3])}else o=t[3]?t[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?n=n.slice(1):n=n.slice(1,-1)),vg(t,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:o&&o.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer,this.rules)}}reflink(e,t){let r;if((r=this.rules.inline.reflink.exec(e))||(r=this.rules.inline.nolink.exec(e))){const n=(r[2]||r[1]).replace(this.rules.other.multipleSpaceGlobal," "),o=t[n.toLowerCase()];if(!o){const a=r[0].charAt(0);return{type:"text",raw:a,text:a}}return vg(r,o,r[0],this.lexer,this.rules)}}emStrong(e,t,r=""){let n=this.rules.inline.emStrongLDelim.exec(e);if(!(!n||n[3]&&r.match(this.rules.other.unicodeAlphaNumeric))&&(!(n[1]||n[2])||!r||this.rules.inline.punctuation.exec(r))){const o=[...n[0]].length-1;let a,i,l=o,s=0;const u=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(u.lastIndex=0,t=t.slice(-1*e.length+o);(n=u.exec(t))!=null;){if(a=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!a)continue;if(i=[...a].length,n[3]||n[4]){l+=i;continue}else if((n[5]||n[6])&&o%3&&!((o+i)%3)){s+=i;continue}if(l-=i,l>0)continue;i=Math.min(i,i+l+s);const c=[...n[0]][0].length,f=e.slice(0,o+n.index+c+i);if(Math.min(o,i)%2){const h=f.slice(1,-1);return{type:"em",raw:f,text:h,tokens:this.lexer.inlineTokens(h)}}const p=f.slice(2,-2);return{type:"strong",raw:f,text:p,tokens:this.lexer.inlineTokens(p)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let r=t[2].replace(this.rules.other.newLineCharGlobal," ");const n=this.rules.other.nonSpaceChar.test(r),o=this.rules.other.startingSpaceChar.test(r)&&this.rules.other.endingSpaceChar.test(r);return n&&o&&(r=r.substring(1,r.length-1)),{type:"codespan",raw:t[0],text:r}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){const t=this.rules.inline.autolink.exec(e);if(t){let r,n;return t[2]==="@"?(r=t[1],n="mailto:"+r):(r=t[1],n=r),{type:"link",raw:t[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}}}url(e){var r;let t;if(t=this.rules.inline.url.exec(e)){let n,o;if(t[2]==="@")n=t[0],o="mailto:"+n;else{let a;do a=t[0],t[0]=((r=this.rules.inline._backpedal.exec(t[0]))==null?void 0:r[0])??"";while(a!==t[0]);n=t[0],t[1]==="www."?o="http://"+t[0]:o=t[0]}return{type:"link",raw:t[0],text:n,href:o,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(e){const t=this.rules.inline.text.exec(e);if(t){const r=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:t[0],escaped:r}}}},mo=class Dd{constructor(t){rr(this,"tokens"),rr(this,"options"),rr(this,"state"),rr(this,"tokenizer"),rr(this,"inlineQueue"),this.tokens=[],this.tokens.links=Object.create(null),this.options=t||ia,this.options.tokenizer=this.options.tokenizer||new Ns,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const r={other:tn,block:Hl.normal,inline:gi.normal};this.options.pedantic?(r.block=Hl.pedantic,r.inline=gi.pedantic):this.options.gfm&&(r.block=Hl.gfm,this.options.breaks?r.inline=gi.breaks:r.inline=gi.gfm),this.tokenizer.rules=r}static get rules(){return{block:Hl,inline:gi}}static lex(t,r){return new Dd(r).lex(t)}static lexInline(t,r){return new Dd(r).inlineTokens(t)}lex(t){t=t.replace(tn.carriageReturn,`
|
|
50
|
+
`),this.blockTokens(t,this.tokens);for(let r=0;r<this.inlineQueue.length;r++){const n=this.inlineQueue[r];this.inlineTokens(n.src,n.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,r=[],n=!1){var o,a,i;for(this.options.pedantic&&(t=t.replace(tn.tabCharGlobal," ").replace(tn.spaceLine,""));t;){let l;if((a=(o=this.options.extensions)==null?void 0:o.block)!=null&&a.some(u=>(l=u.call({lexer:this},t,r))?(t=t.substring(l.raw.length),r.push(l),!0):!1))continue;if(l=this.tokenizer.space(t)){t=t.substring(l.raw.length);const u=r.at(-1);l.raw.length===1&&u!==void 0?u.raw+=`
|
|
51
|
+
`:r.push(l);continue}if(l=this.tokenizer.code(t)){t=t.substring(l.raw.length);const u=r.at(-1);(u==null?void 0:u.type)==="paragraph"||(u==null?void 0:u.type)==="text"?(u.raw+=`
|
|
52
|
+
`+l.raw,u.text+=`
|
|
53
|
+
`+l.text,this.inlineQueue.at(-1).src=u.text):r.push(l);continue}if(l=this.tokenizer.fences(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.heading(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.hr(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.blockquote(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.list(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.html(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.def(t)){t=t.substring(l.raw.length);const u=r.at(-1);(u==null?void 0:u.type)==="paragraph"||(u==null?void 0:u.type)==="text"?(u.raw+=`
|
|
54
|
+
`+l.raw,u.text+=`
|
|
55
|
+
`+l.raw,this.inlineQueue.at(-1).src=u.text):this.tokens.links[l.tag]||(this.tokens.links[l.tag]={href:l.href,title:l.title});continue}if(l=this.tokenizer.table(t)){t=t.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.lheading(t)){t=t.substring(l.raw.length),r.push(l);continue}let s=t;if((i=this.options.extensions)!=null&&i.startBlock){let u=1/0;const c=t.slice(1);let f;this.options.extensions.startBlock.forEach(p=>{f=p.call({lexer:this},c),typeof f=="number"&&f>=0&&(u=Math.min(u,f))}),u<1/0&&u>=0&&(s=t.substring(0,u+1))}if(this.state.top&&(l=this.tokenizer.paragraph(s))){const u=r.at(-1);n&&(u==null?void 0:u.type)==="paragraph"?(u.raw+=`
|
|
56
|
+
`+l.raw,u.text+=`
|
|
57
|
+
`+l.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=u.text):r.push(l),n=s.length!==t.length,t=t.substring(l.raw.length);continue}if(l=this.tokenizer.text(t)){t=t.substring(l.raw.length);const u=r.at(-1);(u==null?void 0:u.type)==="text"?(u.raw+=`
|
|
58
|
+
`+l.raw,u.text+=`
|
|
59
|
+
`+l.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=u.text):r.push(l);continue}if(t){const u="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(u);break}else throw new Error(u)}}return this.state.top=!0,r}inline(t,r=[]){return this.inlineQueue.push({src:t,tokens:r}),r}inlineTokens(t,r=[]){var l,s,u;let n=t,o=null;if(this.tokens.links){const c=Object.keys(this.tokens.links);if(c.length>0)for(;(o=this.tokenizer.rules.inline.reflinkSearch.exec(n))!=null;)c.includes(o[0].slice(o[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,o.index)+"["+"a".repeat(o[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(o=this.tokenizer.rules.inline.anyPunctuation.exec(n))!=null;)n=n.slice(0,o.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;(o=this.tokenizer.rules.inline.blockSkip.exec(n))!=null;)n=n.slice(0,o.index)+"["+"a".repeat(o[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let a=!1,i="";for(;t;){a||(i=""),a=!1;let c;if((s=(l=this.options.extensions)==null?void 0:l.inline)!=null&&s.some(p=>(c=p.call({lexer:this},t,r))?(t=t.substring(c.raw.length),r.push(c),!0):!1))continue;if(c=this.tokenizer.escape(t)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.tag(t)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.link(t)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(c.raw.length);const p=r.at(-1);c.type==="text"&&(p==null?void 0:p.type)==="text"?(p.raw+=c.raw,p.text+=c.text):r.push(c);continue}if(c=this.tokenizer.emStrong(t,n,i)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.codespan(t)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.br(t)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.del(t)){t=t.substring(c.raw.length),r.push(c);continue}if(c=this.tokenizer.autolink(t)){t=t.substring(c.raw.length),r.push(c);continue}if(!this.state.inLink&&(c=this.tokenizer.url(t))){t=t.substring(c.raw.length),r.push(c);continue}let f=t;if((u=this.options.extensions)!=null&&u.startInline){let p=1/0;const h=t.slice(1);let v;this.options.extensions.startInline.forEach(g=>{v=g.call({lexer:this},h),typeof v=="number"&&v>=0&&(p=Math.min(p,v))}),p<1/0&&p>=0&&(f=t.substring(0,p+1))}if(c=this.tokenizer.inlineText(f)){t=t.substring(c.raw.length),c.raw.slice(-1)!=="_"&&(i=c.raw.slice(-1)),a=!0;const p=r.at(-1);(p==null?void 0:p.type)==="text"?(p.raw+=c.raw,p.text+=c.text):r.push(c);continue}if(t){const p="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(p);break}else throw new Error(p)}}return r}},Ps=class{constructor(e){rr(this,"options"),rr(this,"parser"),this.options=e||ia}space(e){return""}code({text:e,lang:t,escaped:r}){var a;const n=(a=(t||"").match(tn.notSpaceStart))==null?void 0:a[0],o=e.replace(tn.endingNewline,"")+`
|
|
60
|
+
`;return n?'<pre><code class="language-'+Vn(n)+'">'+(r?o:Vn(o,!0))+`</code></pre>
|
|
61
|
+
`:"<pre><code>"+(r?o:Vn(o,!0))+`</code></pre>
|
|
62
|
+
`}blockquote({tokens:e}){return`<blockquote>
|
|
63
|
+
${this.parser.parse(e)}</blockquote>
|
|
64
|
+
`}html({text:e}){return e}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>
|
|
65
|
+
`}hr(e){return`<hr>
|
|
66
|
+
`}list(e){const t=e.ordered,r=e.start;let n="";for(let i=0;i<e.items.length;i++){const l=e.items[i];n+=this.listitem(l)}const o=t?"ol":"ul",a=t&&r!==1?' start="'+r+'"':"";return"<"+o+a+`>
|
|
67
|
+
`+n+"</"+o+`>
|
|
68
|
+
`}listitem(e){var r;let t="";if(e.task){const n=this.checkbox({checked:!!e.checked});e.loose?((r=e.tokens[0])==null?void 0:r.type)==="paragraph"?(e.tokens[0].text=n+" "+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&e.tokens[0].tokens[0].type==="text"&&(e.tokens[0].tokens[0].text=n+" "+Vn(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:"text",raw:n+" ",text:n+" ",escaped:!0}):t+=n+" "}return t+=this.parser.parse(e.tokens,!!e.loose),`<li>${t}</li>
|
|
69
|
+
`}checkbox({checked:e}){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:e}){return`<p>${this.parser.parseInline(e)}</p>
|
|
70
|
+
`}table(e){let t="",r="";for(let o=0;o<e.header.length;o++)r+=this.tablecell(e.header[o]);t+=this.tablerow({text:r});let n="";for(let o=0;o<e.rows.length;o++){const a=e.rows[o];r="";for(let i=0;i<a.length;i++)r+=this.tablecell(a[i]);n+=this.tablerow({text:r})}return n&&(n=`<tbody>${n}</tbody>`),`<table>
|
|
71
|
+
<thead>
|
|
72
|
+
`+t+`</thead>
|
|
73
|
+
`+n+`</table>
|
|
74
|
+
`}tablerow({text:e}){return`<tr>
|
|
75
|
+
${e}</tr>
|
|
76
|
+
`}tablecell(e){const t=this.parser.parseInline(e.tokens),r=e.header?"th":"td";return(e.align?`<${r} align="${e.align}">`:`<${r}>`)+t+`</${r}>
|
|
77
|
+
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${Vn(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,tokens:r}){const n=this.parser.parseInline(r),o=hg(e);if(o===null)return n;e=o;let a='<a href="'+e+'"';return t&&(a+=' title="'+Vn(t)+'"'),a+=">"+n+"</a>",a}image({href:e,title:t,text:r,tokens:n}){n&&(r=this.parser.parseInline(n,this.parser.textRenderer));const o=hg(e);if(o===null)return Vn(r);e=o;let a=`<img src="${e}" alt="${r}"`;return t&&(a+=` title="${Vn(t)}"`),a+=">",a}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:Vn(e.text)}},wp=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}},ho=class Sd{constructor(t){rr(this,"options"),rr(this,"renderer"),rr(this,"textRenderer"),this.options=t||ia,this.options.renderer=this.options.renderer||new Ps,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new wp}static parse(t,r){return new Sd(r).parse(t)}static parseInline(t,r){return new Sd(r).parseInline(t)}parse(t,r=!0){var o,a;let n="";for(let i=0;i<t.length;i++){const l=t[i];if((a=(o=this.options.extensions)==null?void 0:o.renderers)!=null&&a[l.type]){const u=l,c=this.options.extensions.renderers[u.type].call({parser:this},u);if(c!==!1||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(u.type)){n+=c||"";continue}}const s=l;switch(s.type){case"space":{n+=this.renderer.space(s);continue}case"hr":{n+=this.renderer.hr(s);continue}case"heading":{n+=this.renderer.heading(s);continue}case"code":{n+=this.renderer.code(s);continue}case"table":{n+=this.renderer.table(s);continue}case"blockquote":{n+=this.renderer.blockquote(s);continue}case"list":{n+=this.renderer.list(s);continue}case"html":{n+=this.renderer.html(s);continue}case"paragraph":{n+=this.renderer.paragraph(s);continue}case"text":{let u=s,c=this.renderer.text(u);for(;i+1<t.length&&t[i+1].type==="text";)u=t[++i],c+=`
|
|
78
|
+
`+this.renderer.text(u);r?n+=this.renderer.paragraph({type:"paragraph",raw:c,text:c,tokens:[{type:"text",raw:c,text:c,escaped:!0}]}):n+=c;continue}default:{const u='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(u),"";throw new Error(u)}}}return n}parseInline(t,r=this.renderer){var o,a;let n="";for(let i=0;i<t.length;i++){const l=t[i];if((a=(o=this.options.extensions)==null?void 0:o.renderers)!=null&&a[l.type]){const u=this.options.extensions.renderers[l.type].call({parser:this},l);if(u!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(l.type)){n+=u||"";continue}}const s=l;switch(s.type){case"escape":{n+=r.text(s);break}case"html":{n+=r.html(s);break}case"link":{n+=r.link(s);break}case"image":{n+=r.image(s);break}case"strong":{n+=r.strong(s);break}case"em":{n+=r.em(s);break}case"codespan":{n+=r.codespan(s);break}case"br":{n+=r.br(s);break}case"del":{n+=r.del(s);break}case"text":{n+=r.text(s);break}default:{const u='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(u),"";throw new Error(u)}}}return n}},xc,ls=(xc=class{constructor(e){rr(this,"options"),rr(this,"block"),this.options=e||ia}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}provideLexer(){return this.block?mo.lex:mo.lexInline}provideParser(){return this.block?ho.parse:ho.parseInline}},rr(xc,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"])),xc),k2=class{constructor(...e){rr(this,"defaults",mp()),rr(this,"options",this.setOptions),rr(this,"parse",this.parseMarkdown(!0)),rr(this,"parseInline",this.parseMarkdown(!1)),rr(this,"Parser",ho),rr(this,"Renderer",Ps),rr(this,"TextRenderer",wp),rr(this,"Lexer",mo),rr(this,"Tokenizer",Ns),rr(this,"Hooks",ls),this.use(...e)}walkTokens(e,t){var n,o;let r=[];for(const a of e)switch(r=r.concat(t.call(this,a)),a.type){case"table":{const i=a;for(const l of i.header)r=r.concat(this.walkTokens(l.tokens,t));for(const l of i.rows)for(const s of l)r=r.concat(this.walkTokens(s.tokens,t));break}case"list":{const i=a;r=r.concat(this.walkTokens(i.items,t));break}default:{const i=a;(o=(n=this.defaults.extensions)==null?void 0:n.childTokens)!=null&&o[i.type]?this.defaults.extensions.childTokens[i.type].forEach(l=>{const s=i[l].flat(1/0);r=r.concat(this.walkTokens(s,t))}):i.tokens&&(r=r.concat(this.walkTokens(i.tokens,t)))}}return r}use(...e){const t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(r=>{const n={...r};if(n.async=this.defaults.async||n.async||!1,r.extensions&&(r.extensions.forEach(o=>{if(!o.name)throw new Error("extension name required");if("renderer"in o){const a=t.renderers[o.name];a?t.renderers[o.name]=function(...i){let l=o.renderer.apply(this,i);return l===!1&&(l=a.apply(this,i)),l}:t.renderers[o.name]=o.renderer}if("tokenizer"in o){if(!o.level||o.level!=="block"&&o.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");const a=t[o.level];a?a.unshift(o.tokenizer):t[o.level]=[o.tokenizer],o.start&&(o.level==="block"?t.startBlock?t.startBlock.push(o.start):t.startBlock=[o.start]:o.level==="inline"&&(t.startInline?t.startInline.push(o.start):t.startInline=[o.start]))}"childTokens"in o&&o.childTokens&&(t.childTokens[o.name]=o.childTokens)}),n.extensions=t),r.renderer){const o=this.defaults.renderer||new Ps(this.defaults);for(const a in r.renderer){if(!(a in o))throw new Error(`renderer '${a}' does not exist`);if(["options","parser"].includes(a))continue;const i=a,l=r.renderer[i],s=o[i];o[i]=(...u)=>{let c=l.apply(o,u);return c===!1&&(c=s.apply(o,u)),c||""}}n.renderer=o}if(r.tokenizer){const o=this.defaults.tokenizer||new Ns(this.defaults);for(const a in r.tokenizer){if(!(a in o))throw new Error(`tokenizer '${a}' does not exist`);if(["options","rules","lexer"].includes(a))continue;const i=a,l=r.tokenizer[i],s=o[i];o[i]=(...u)=>{let c=l.apply(o,u);return c===!1&&(c=s.apply(o,u)),c}}n.tokenizer=o}if(r.hooks){const o=this.defaults.hooks||new ls;for(const a in r.hooks){if(!(a in o))throw new Error(`hook '${a}' does not exist`);if(["options","block"].includes(a))continue;const i=a,l=r.hooks[i],s=o[i];ls.passThroughHooks.has(a)?o[i]=u=>{if(this.defaults.async)return Promise.resolve(l.call(o,u)).then(f=>s.call(o,f));const c=l.call(o,u);return s.call(o,c)}:o[i]=(...u)=>{let c=l.apply(o,u);return c===!1&&(c=s.apply(o,u)),c}}n.hooks=o}if(r.walkTokens){const o=this.defaults.walkTokens,a=r.walkTokens;n.walkTokens=function(i){let l=[];return l.push(a.call(this,i)),o&&(l=l.concat(o.call(this,i))),l}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return mo.lex(e,t??this.defaults)}parser(e,t){return ho.parse(e,t??this.defaults)}parseMarkdown(e){return(t,r)=>{const n={...r},o={...this.defaults,...n},a=this.onError(!!o.silent,!!o.async);if(this.defaults.async===!0&&n.async===!1)return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof t>"u"||t===null)return a(new Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));o.hooks&&(o.hooks.options=o,o.hooks.block=e);const i=o.hooks?o.hooks.provideLexer():e?mo.lex:mo.lexInline,l=o.hooks?o.hooks.provideParser():e?ho.parse:ho.parseInline;if(o.async)return Promise.resolve(o.hooks?o.hooks.preprocess(t):t).then(s=>i(s,o)).then(s=>o.hooks?o.hooks.processAllTokens(s):s).then(s=>o.walkTokens?Promise.all(this.walkTokens(s,o.walkTokens)).then(()=>s):s).then(s=>l(s,o)).then(s=>o.hooks?o.hooks.postprocess(s):s).catch(a);try{o.hooks&&(t=o.hooks.preprocess(t));let s=i(t,o);o.hooks&&(s=o.hooks.processAllTokens(s)),o.walkTokens&&this.walkTokens(s,o.walkTokens);let u=l(s,o);return o.hooks&&(u=o.hooks.postprocess(u)),u}catch(s){return a(s)}}}onError(e,t){return r=>{if(r.message+=`
|
|
79
|
+
Please report this to https://github.com/markedjs/marked.`,e){const n="<p>An error occurred:</p><pre>"+Vn(r.message+"",!0)+"</pre>";return t?Promise.resolve(n):n}if(t)return Promise.reject(r);throw r}}},ta=new k2;function Kt(e,t){return ta.parse(e,t)}Kt.options=Kt.setOptions=function(e){return ta.setOptions(e),Kt.defaults=ta.defaults,xy(Kt.defaults),Kt};Kt.getDefaults=mp;Kt.defaults=ia;Kt.use=function(...e){return ta.use(...e),Kt.defaults=ta.defaults,xy(Kt.defaults),Kt};Kt.walkTokens=function(e,t){return ta.walkTokens(e,t)};Kt.parseInline=ta.parseInline;Kt.Parser=ho;Kt.parser=ho.parse;Kt.Renderer=Ps;Kt.TextRenderer=wp;Kt.Lexer=mo;Kt.lexer=mo.lex;Kt.Tokenizer=Ns;Kt.Hooks=ls;Kt.parse=Kt;Kt.options;Kt.setOptions;Kt.use;Kt.walkTokens;Kt.parseInline;ho.parse;mo.lex;var cn=function(){return cn=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},cn.apply(this,arguments)};function js(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,a;n<o;n++)(a||!(n in t))&&(a||(a=Array.prototype.slice.call(t,0,n)),a[n]=t[n]);return e.concat(a||Array.prototype.slice.call(t))}var or="-ms-",Ri="-moz-",Ut="-webkit-",Ny="comm",cu="rule",Ep="decl",D2="@import",Py="@keyframes",S2="@layer",jy=Math.abs,kp=String.fromCharCode,$d=Object.assign;function $2(e,t){return jr(e,0)^45?(((t<<2^jr(e,0))<<2^jr(e,1))<<2^jr(e,2))<<2^jr(e,3):0}function Iy(e){return e.trim()}function uo(e,t){return(e=t.exec(e))?e[0]:e}function Nt(e,t,r){return e.replace(t,r)}function ss(e,t,r){return e.indexOf(t,r)}function jr(e,t){return e.charCodeAt(t)|0}function za(e,t,r){return e.slice(t,r)}function Un(e){return e.length}function Ry(e){return e.length}function Si(e,t){return t.push(e),e}function B2(e,t){return e.map(t).join("")}function bg(e,t){return e.filter(function(r){return!uo(r,t)})}var du=1,_a=1,My=0,On=0,Er=0,ri="";function fu(e,t,r,n,o,a,i,l){return{value:e,root:t,parent:r,type:n,props:o,children:a,line:du,column:_a,length:i,return:"",siblings:l}}function wo(e,t){return $d(fu("",null,null,"",null,null,0,e.siblings),e,{length:-e.length},t)}function ma(e){for(;e.root;)e=wo(e.root,{children:[e]});Si(e,e.siblings)}function O2(){return Er}function A2(){return Er=On>0?jr(ri,--On):0,_a--,Er===10&&(_a=1,du--),Er}function Tn(){return Er=On<My?jr(ri,On++):0,_a++,Er===10&&(_a=1,du++),Er}function Uo(){return jr(ri,On)}function us(){return On}function pu(e,t){return za(ri,e,t)}function Bd(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function F2(e){return du=_a=1,My=Un(ri=e),On=0,[]}function N2(e){return ri="",e}function wc(e){return Iy(pu(On-1,Od(e===91?e+2:e===40?e+1:e)))}function P2(e){for(;(Er=Uo())&&Er<33;)Tn();return Bd(e)>2||Bd(Er)>3?"":" "}function j2(e,t){for(;--t&&Tn()&&!(Er<48||Er>102||Er>57&&Er<65||Er>70&&Er<97););return pu(e,us()+(t<6&&Uo()==32&&Tn()==32))}function Od(e){for(;Tn();)switch(Er){case e:return On;case 34:case 39:e!==34&&e!==39&&Od(Er);break;case 40:e===41&&Od(e);break;case 92:Tn();break}return On}function I2(e,t){for(;Tn()&&e+Er!==57&&!(e+Er===84&&Uo()===47););return"/*"+pu(t,On-1)+"*"+kp(e===47?e:Tn())}function R2(e){for(;!Bd(Uo());)Tn();return pu(e,On)}function M2(e){return N2(cs("",null,null,null,[""],e=F2(e),0,[0],e))}function cs(e,t,r,n,o,a,i,l,s){for(var u=0,c=0,f=i,p=0,h=0,v=0,g=1,m=1,b=1,y=0,C="",D=o,w=a,k=n,E=C;m;)switch(v=y,y=Tn()){case 40:if(v!=108&&jr(E,f-1)==58){ss(E+=Nt(wc(y),"&","&\f"),"&\f",jy(u?l[u-1]:0))!=-1&&(b=-1);break}case 34:case 39:case 91:E+=wc(y);break;case 9:case 10:case 13:case 32:E+=P2(v);break;case 92:E+=j2(us()-1,7);continue;case 47:switch(Uo()){case 42:case 47:Si(T2(I2(Tn(),us()),t,r,s),s);break;default:E+="/"}break;case 123*g:l[u++]=Un(E)*b;case 125*g:case 59:case 0:switch(y){case 0:case 125:m=0;case 59+c:b==-1&&(E=Nt(E,/\f/g,"")),h>0&&Un(E)-f&&Si(h>32?Cg(E+";",n,r,f-1,s):Cg(Nt(E," ","")+";",n,r,f-2,s),s);break;case 59:E+=";";default:if(Si(k=yg(E,t,r,u,c,o,l,C,D=[],w=[],f,a),a),y===123)if(c===0)cs(E,t,k,k,D,a,f,l,w);else switch(p===99&&jr(E,3)===110?100:p){case 100:case 108:case 109:case 115:cs(e,k,k,n&&Si(yg(e,k,k,0,0,o,l,C,o,D=[],f,w),w),o,w,f,l,n?D:w);break;default:cs(E,k,k,k,[""],w,0,l,w)}}u=c=h=0,g=b=1,C=E="",f=i;break;case 58:f=1+Un(E),h=v;default:if(g<1){if(y==123)--g;else if(y==125&&g++==0&&A2()==125)continue}switch(E+=kp(y),y*g){case 38:b=c>0?1:(E+="\f",-1);break;case 44:l[u++]=(Un(E)-1)*b,b=1;break;case 64:Uo()===45&&(E+=wc(Tn())),p=Uo(),c=f=Un(C=E+=R2(us())),y++;break;case 45:v===45&&Un(E)==2&&(g=0)}}return a}function yg(e,t,r,n,o,a,i,l,s,u,c,f){for(var p=o-1,h=o===0?a:[""],v=Ry(h),g=0,m=0,b=0;g<n;++g)for(var y=0,C=za(e,p+1,p=jy(m=i[g])),D=e;y<v;++y)(D=Iy(m>0?h[y]+" "+C:Nt(C,/&\f/g,h[y])))&&(s[b++]=D);return fu(e,t,r,o===0?cu:l,s,u,c,f)}function T2(e,t,r,n){return fu(e,t,r,Ny,kp(O2()),za(e,2,-2),0,n)}function Cg(e,t,r,n,o){return fu(e,t,r,Ep,za(e,0,n),za(e,n+1,-1),n,o)}function Ty(e,t,r){switch($2(e,t)){case 5103:return Ut+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Ut+e+e;case 4789:return Ri+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Ut+e+Ri+e+or+e+e;case 5936:switch(jr(e,t+11)){case 114:return Ut+e+or+Nt(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Ut+e+or+Nt(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Ut+e+or+Nt(e,/[svh]\w+-[tblr]{2}/,"lr")+e}case 6828:case 4268:case 2903:return Ut+e+or+e+e;case 6165:return Ut+e+or+"flex-"+e+e;case 5187:return Ut+e+Nt(e,/(\w+).+(:[^]+)/,Ut+"box-$1$2"+or+"flex-$1$2")+e;case 5443:return Ut+e+or+"flex-item-"+Nt(e,/flex-|-self/g,"")+(uo(e,/flex-|baseline/)?"":or+"grid-row-"+Nt(e,/flex-|-self/g,""))+e;case 4675:return Ut+e+or+"flex-line-pack"+Nt(e,/align-content|flex-|-self/g,"")+e;case 5548:return Ut+e+or+Nt(e,"shrink","negative")+e;case 5292:return Ut+e+or+Nt(e,"basis","preferred-size")+e;case 6060:return Ut+"box-"+Nt(e,"-grow","")+Ut+e+or+Nt(e,"grow","positive")+e;case 4554:return Ut+Nt(e,/([^-])(transform)/g,"$1"+Ut+"$2")+e;case 6187:return Nt(Nt(Nt(e,/(zoom-|grab)/,Ut+"$1"),/(image-set)/,Ut+"$1"),e,"")+e;case 5495:case 3959:return Nt(e,/(image-set\([^]*)/,Ut+"$1$`$1");case 4968:return Nt(Nt(e,/(.+:)(flex-)?(.*)/,Ut+"box-pack:$3"+or+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Ut+e+e;case 4200:if(!uo(e,/flex-|baseline/))return or+"grid-column-align"+za(e,t)+e;break;case 2592:case 3360:return or+Nt(e,"template-","")+e;case 4384:case 3616:return r&&r.some(function(n,o){return t=o,uo(n.props,/grid-\w+-end/)})?~ss(e+(r=r[t].value),"span",0)?e:or+Nt(e,"-start","")+e+or+"grid-row-span:"+(~ss(r,"span",0)?uo(r,/\d+/):+uo(r,/\d+/)-+uo(e,/\d+/))+";":or+Nt(e,"-start","")+e;case 4896:case 4128:return r&&r.some(function(n){return uo(n.props,/grid-\w+-start/)})?e:or+Nt(Nt(e,"-end","-span"),"span ","")+e;case 4095:case 3583:case 4068:case 2532:return Nt(e,/(.+)-inline(.+)/,Ut+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Un(e)-1-t>6)switch(jr(e,t+1)){case 109:if(jr(e,t+4)!==45)break;case 102:return Nt(e,/(.+:)(.+)-([^]+)/,"$1"+Ut+"$2-$3$1"+Ri+(jr(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~ss(e,"stretch",0)?Ty(Nt(e,"stretch","fill-available"),t,r)+e:e}break;case 5152:case 5920:return Nt(e,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(n,o,a,i,l,s,u){return or+o+":"+a+u+(i?or+o+"-span:"+(l?s:+s-+a)+u:"")+e});case 4949:if(jr(e,t+6)===121)return Nt(e,":",":"+Ut)+e;break;case 6444:switch(jr(e,jr(e,14)===45?18:11)){case 120:return Nt(e,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+Ut+(jr(e,14)===45?"inline-":"")+"box$3$1"+Ut+"$2$3$1"+or+"$2box$3")+e;case 100:return Nt(e,":",":"+or)+e}break;case 5719:case 2647:case 2135:case 3927:case 2391:return Nt(e,"scroll-","scroll-snap-")+e}return e}function Is(e,t){for(var r="",n=0;n<e.length;n++)r+=t(e[n],n,e,t)||"";return r}function z2(e,t,r,n){switch(e.type){case S2:if(e.children.length)break;case D2:case Ep:return e.return=e.return||e.value;case Ny:return"";case Py:return e.return=e.value+"{"+Is(e.children,n)+"}";case cu:if(!Un(e.value=e.props.join(",")))return""}return Un(r=Is(e.children,n))?e.return=e.value+"{"+r+"}":""}function _2(e){var t=Ry(e);return function(r,n,o,a){for(var i="",l=0;l<t;l++)i+=e[l](r,n,o,a)||"";return i}}function L2(e){return function(t){t.root||(t=t.return)&&e(t)}}function H2(e,t,r,n){if(e.length>-1&&!e.return)switch(e.type){case Ep:e.return=Ty(e.value,e.length,r);return;case Py:return Is([wo(e,{value:Nt(e.value,"@","@"+Ut)})],n);case cu:if(e.length)return B2(r=e.props,function(o){switch(uo(o,n=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":ma(wo(e,{props:[Nt(o,/:(read-\w+)/,":"+Ri+"$1")]})),ma(wo(e,{props:[o]})),$d(e,{props:bg(r,n)});break;case"::placeholder":ma(wo(e,{props:[Nt(o,/:(plac\w+)/,":"+Ut+"input-$1")]})),ma(wo(e,{props:[Nt(o,/:(plac\w+)/,":"+Ri+"$1")]})),ma(wo(e,{props:[Nt(o,/:(plac\w+)/,or+"input-$1")]})),ma(wo(e,{props:[o]})),$d(e,{props:bg(r,n)});break}return""})}}var W2={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,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},La=typeof process<"u"&&gn!==void 0&&(gn.REACT_APP_SC_ATTR||gn.SC_ATTR)||"data-styled",zy="active",_y="data-styled-version",mu="6.1.19",Dp=`/*!sc*/
|
|
80
|
+
`,Rs=typeof window<"u"&&typeof document<"u",K2=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof process<"u"&&gn!==void 0&&gn.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&gn.REACT_APP_SC_DISABLE_SPEEDY!==""?gn.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&gn.REACT_APP_SC_DISABLE_SPEEDY:typeof process<"u"&&gn!==void 0&&gn.SC_DISABLE_SPEEDY!==void 0&&gn.SC_DISABLE_SPEEDY!==""&&gn.SC_DISABLE_SPEEDY!=="false"&&gn.SC_DISABLE_SPEEDY),hu=Object.freeze([]),Ha=Object.freeze({});function q2(e,t,r){return r===void 0&&(r=Ha),e.theme!==r.theme&&e.theme||t||r.theme}var Ly=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),V2=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,G2=/(^-|-$)/g;function xg(e){return e.replace(V2,"-").replace(G2,"")}var X2=/(a)(d)/gi,Wl=52,wg=function(e){return String.fromCharCode(e+(e>25?39:97))};function Ad(e){var t,r="";for(t=Math.abs(e);t>Wl;t=t/Wl|0)r=wg(t%Wl)+r;return(wg(t%Wl)+r).replace(X2,"$1-$2")}var Ec,Hy=5381,Sa=function(e,t){for(var r=t.length;r;)e=33*e^t.charCodeAt(--r);return e},Wy=function(e){return Sa(Hy,e)};function U2(e){return Ad(Wy(e)>>>0)}function Y2(e){return e.displayName||e.name||"Component"}function kc(e){return typeof e=="string"&&!0}var Ky=typeof Symbol=="function"&&Symbol.for,qy=Ky?Symbol.for("react.memo"):60115,Z2=Ky?Symbol.for("react.forward_ref"):60112,J2={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Q2={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},Vy={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},eB=((Ec={})[Z2]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Ec[qy]=Vy,Ec);function Eg(e){return("type"in(t=e)&&t.type.$$typeof)===qy?Vy:"$$typeof"in e?eB[e.$$typeof]:J2;var t}var tB=Object.defineProperty,rB=Object.getOwnPropertyNames,kg=Object.getOwnPropertySymbols,nB=Object.getOwnPropertyDescriptor,oB=Object.getPrototypeOf,Dg=Object.prototype;function Gy(e,t,r){if(typeof t!="string"){if(Dg){var n=oB(t);n&&n!==Dg&&Gy(e,n,r)}var o=rB(t);kg&&(o=o.concat(kg(t)));for(var a=Eg(e),i=Eg(t),l=0;l<o.length;++l){var s=o[l];if(!(s in Q2||r&&r[s]||i&&s in i||a&&s in a)){var u=nB(t,s);try{tB(e,s,u)}catch{}}}}return e}function Wa(e){return typeof e=="function"}function Sp(e){return typeof e=="object"&&"styledComponentId"in e}function Ko(e,t){return e&&t?"".concat(e," ").concat(t):e||t||""}function Sg(e,t){if(e.length===0)return"";for(var r=e[0],n=1;n<e.length;n++)r+=e[n];return r}function Zi(e){return e!==null&&typeof e=="object"&&e.constructor.name===Object.name&&!("props"in e&&e.$$typeof)}function Fd(e,t,r){if(r===void 0&&(r=!1),!r&&!Zi(e)&&!Array.isArray(e))return t;if(Array.isArray(t))for(var n=0;n<t.length;n++)e[n]=Fd(e[n],t[n]);else if(Zi(t))for(var n in t)e[n]=Fd(e[n],t[n]);return e}function $p(e,t){Object.defineProperty(e,"toString",{value:t})}function yl(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(e," for more information.").concat(t.length>0?" Args: ".concat(t.join(", ")):""))}var aB=(function(){function e(t){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=t}return e.prototype.indexOfGroup=function(t){for(var r=0,n=0;n<t;n++)r+=this.groupSizes[n];return r},e.prototype.insertRules=function(t,r){if(t>=this.groupSizes.length){for(var n=this.groupSizes,o=n.length,a=o;t>=a;)if((a<<=1)<0)throw yl(16,"".concat(t));this.groupSizes=new Uint32Array(a),this.groupSizes.set(n),this.length=a;for(var i=o;i<a;i++)this.groupSizes[i]=0}for(var l=this.indexOfGroup(t+1),s=(i=0,r.length);i<s;i++)this.tag.insertRule(l,r[i])&&(this.groupSizes[t]++,l++)},e.prototype.clearGroup=function(t){if(t<this.length){var r=this.groupSizes[t],n=this.indexOfGroup(t),o=n+r;this.groupSizes[t]=0;for(var a=n;a<o;a++)this.tag.deleteRule(n)}},e.prototype.getGroup=function(t){var r="";if(t>=this.length||this.groupSizes[t]===0)return r;for(var n=this.groupSizes[t],o=this.indexOfGroup(t),a=o+n,i=o;i<a;i++)r+="".concat(this.tag.getRule(i)).concat(Dp);return r},e})(),ds=new Map,Ms=new Map,fs=1,Kl=function(e){if(ds.has(e))return ds.get(e);for(;Ms.has(fs);)fs++;var t=fs++;return ds.set(e,t),Ms.set(t,e),t},iB=function(e,t){fs=t+1,ds.set(e,t),Ms.set(t,e)},lB="style[".concat(La,"][").concat(_y,'="').concat(mu,'"]'),sB=new RegExp("^".concat(La,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),uB=function(e,t,r){for(var n,o=r.split(","),a=0,i=o.length;a<i;a++)(n=o[a])&&e.registerName(t,n)},cB=function(e,t){for(var r,n=((r=t.textContent)!==null&&r!==void 0?r:"").split(Dp),o=[],a=0,i=n.length;a<i;a++){var l=n[a].trim();if(l){var s=l.match(sB);if(s){var u=0|parseInt(s[1],10),c=s[2];u!==0&&(iB(c,u),uB(e,c,s[3]),e.getTag().insertRules(u,o)),o.length=0}else o.push(l)}}},$g=function(e){for(var t=document.querySelectorAll(lB),r=0,n=t.length;r<n;r++){var o=t[r];o&&o.getAttribute(La)!==zy&&(cB(e,o),o.parentNode&&o.parentNode.removeChild(o))}};function dB(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:null}var Xy=function(e){var t=document.head,r=e||t,n=document.createElement("style"),o=(function(l){var s=Array.from(l.querySelectorAll("style[".concat(La,"]")));return s[s.length-1]})(r),a=o!==void 0?o.nextSibling:null;n.setAttribute(La,zy),n.setAttribute(_y,mu);var i=dB();return i&&n.setAttribute("nonce",i),r.insertBefore(n,a),n},fB=(function(){function e(t){this.element=Xy(t),this.element.appendChild(document.createTextNode("")),this.sheet=(function(r){if(r.sheet)return r.sheet;for(var n=document.styleSheets,o=0,a=n.length;o<a;o++){var i=n[o];if(i.ownerNode===r)return i}throw yl(17)})(this.element),this.length=0}return e.prototype.insertRule=function(t,r){try{return this.sheet.insertRule(r,t),this.length++,!0}catch{return!1}},e.prototype.deleteRule=function(t){this.sheet.deleteRule(t),this.length--},e.prototype.getRule=function(t){var r=this.sheet.cssRules[t];return r&&r.cssText?r.cssText:""},e})(),pB=(function(){function e(t){this.element=Xy(t),this.nodes=this.element.childNodes,this.length=0}return e.prototype.insertRule=function(t,r){if(t<=this.length&&t>=0){var n=document.createTextNode(r);return this.element.insertBefore(n,this.nodes[t]||null),this.length++,!0}return!1},e.prototype.deleteRule=function(t){this.element.removeChild(this.nodes[t]),this.length--},e.prototype.getRule=function(t){return t<this.length?this.nodes[t].textContent:""},e})(),mB=(function(){function e(t){this.rules=[],this.length=0}return e.prototype.insertRule=function(t,r){return t<=this.length&&(this.rules.splice(t,0,r),this.length++,!0)},e.prototype.deleteRule=function(t){this.rules.splice(t,1),this.length--},e.prototype.getRule=function(t){return t<this.length?this.rules[t]:""},e})(),Bg=Rs,hB={isServer:!Rs,useCSSOMInjection:!K2},Uy=(function(){function e(t,r,n){t===void 0&&(t=Ha),r===void 0&&(r={});var o=this;this.options=cn(cn({},hB),t),this.gs=r,this.names=new Map(n),this.server=!!t.isServer,!this.server&&Rs&&Bg&&(Bg=!1,$g(this)),$p(this,function(){return(function(a){for(var i=a.getTag(),l=i.length,s="",u=function(f){var p=(function(b){return Ms.get(b)})(f);if(p===void 0)return"continue";var h=a.names.get(p),v=i.getGroup(f);if(h===void 0||!h.size||v.length===0)return"continue";var g="".concat(La,".g").concat(f,'[id="').concat(p,'"]'),m="";h!==void 0&&h.forEach(function(b){b.length>0&&(m+="".concat(b,","))}),s+="".concat(v).concat(g,'{content:"').concat(m,'"}').concat(Dp)},c=0;c<l;c++)u(c);return s})(o)})}return e.registerId=function(t){return Kl(t)},e.prototype.rehydrate=function(){!this.server&&Rs&&$g(this)},e.prototype.reconstructWithOptions=function(t,r){return r===void 0&&(r=!0),new e(cn(cn({},this.options),t),this.gs,r&&this.names||void 0)},e.prototype.allocateGSInstance=function(t){return this.gs[t]=(this.gs[t]||0)+1},e.prototype.getTag=function(){return this.tag||(this.tag=(t=(function(r){var n=r.useCSSOMInjection,o=r.target;return r.isServer?new mB(o):n?new fB(o):new pB(o)})(this.options),new aB(t)));var t},e.prototype.hasNameForId=function(t,r){return this.names.has(t)&&this.names.get(t).has(r)},e.prototype.registerName=function(t,r){if(Kl(t),this.names.has(t))this.names.get(t).add(r);else{var n=new Set;n.add(r),this.names.set(t,n)}},e.prototype.insertRules=function(t,r,n){this.registerName(t,r),this.getTag().insertRules(Kl(t),n)},e.prototype.clearNames=function(t){this.names.has(t)&&this.names.get(t).clear()},e.prototype.clearRules=function(t){this.getTag().clearGroup(Kl(t)),this.clearNames(t)},e.prototype.clearTag=function(){this.tag=void 0},e})(),gB=/&/g,vB=/^\s*\/\/.*$/gm;function Yy(e,t){return e.map(function(r){return r.type==="rule"&&(r.value="".concat(t," ").concat(r.value),r.value=r.value.replaceAll(",",",".concat(t," ")),r.props=r.props.map(function(n){return"".concat(t," ").concat(n)})),Array.isArray(r.children)&&r.type!=="@keyframes"&&(r.children=Yy(r.children,t)),r})}function bB(e){var t,r,n,o=Ha,a=o.options,i=a===void 0?Ha:a,l=o.plugins,s=l===void 0?hu:l,u=function(p,h,v){return v.startsWith(r)&&v.endsWith(r)&&v.replaceAll(r,"").length>0?".".concat(t):p},c=s.slice();c.push(function(p){p.type===cu&&p.value.includes("&")&&(p.props[0]=p.props[0].replace(gB,r).replace(n,u))}),i.prefix&&c.push(H2),c.push(z2);var f=function(p,h,v,g){h===void 0&&(h=""),v===void 0&&(v=""),g===void 0&&(g="&"),t=g,r=h,n=new RegExp("\\".concat(r,"\\b"),"g");var m=p.replace(vB,""),b=M2(v||h?"".concat(v," ").concat(h," { ").concat(m," }"):m);i.namespace&&(b=Yy(b,i.namespace));var y=[];return Is(b,_2(c.concat(L2(function(C){return y.push(C)})))),y};return f.hash=s.length?s.reduce(function(p,h){return h.name||yl(15),Sa(p,h.name)},Hy).toString():"",f}var yB=new Uy,Nd=bB(),Zy=ee.createContext({shouldForwardProp:void 0,styleSheet:yB,stylis:Nd});Zy.Consumer;ee.createContext(void 0);function Og(){return Rr(Zy)}var CB=(function(){function e(t,r){var n=this;this.inject=function(o,a){a===void 0&&(a=Nd);var i=n.name+a.hash;o.hasNameForId(n.id,i)||o.insertRules(n.id,i,a(n.rules,i,"@keyframes"))},this.name=t,this.id="sc-keyframes-".concat(t),this.rules=r,$p(this,function(){throw yl(12,String(n.name))})}return e.prototype.getName=function(t){return t===void 0&&(t=Nd),this.name+t.hash},e})(),xB=function(e){return e>="A"&&e<="Z"};function Ag(e){for(var t="",r=0;r<e.length;r++){var n=e[r];if(r===1&&n==="-"&&e[0]==="-")return e;xB(n)?t+="-"+n.toLowerCase():t+=n}return t.startsWith("ms-")?"-"+t:t}var Jy=function(e){return e==null||e===!1||e===""},Qy=function(e){var t,r,n=[];for(var o in e){var a=e[o];e.hasOwnProperty(o)&&!Jy(a)&&(Array.isArray(a)&&a.isCss||Wa(a)?n.push("".concat(Ag(o),":"),a,";"):Zi(a)?n.push.apply(n,js(js(["".concat(o," {")],Qy(a),!1),["}"],!1)):n.push("".concat(Ag(o),": ").concat((t=o,(r=a)==null||typeof r=="boolean"||r===""?"":typeof r!="number"||r===0||t in W2||t.startsWith("--")?String(r).trim():"".concat(r,"px")),";")))}return n};function Yo(e,t,r,n){if(Jy(e))return[];if(Sp(e))return[".".concat(e.styledComponentId)];if(Wa(e)){if(!Wa(a=e)||a.prototype&&a.prototype.isReactComponent||!t)return[e];var o=e(t);return Yo(o,t,r,n)}var a;return e instanceof CB?r?(e.inject(r,n),[e.getName(n)]):[e]:Zi(e)?Qy(e):Array.isArray(e)?Array.prototype.concat.apply(hu,e.map(function(i){return Yo(i,t,r,n)})):[e.toString()]}function wB(e){for(var t=0;t<e.length;t+=1){var r=e[t];if(Wa(r)&&!Sp(r))return!1}return!0}var EB=Wy(mu),kB=(function(){function e(t,r,n){this.rules=t,this.staticRulesId="",this.isStatic=(n===void 0||n.isStatic)&&wB(t),this.componentId=r,this.baseHash=Sa(EB,r),this.baseStyle=n,Uy.registerId(r)}return e.prototype.generateAndInjectStyles=function(t,r,n){var o=this.baseStyle?this.baseStyle.generateAndInjectStyles(t,r,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&r.hasNameForId(this.componentId,this.staticRulesId))o=Ko(o,this.staticRulesId);else{var a=Sg(Yo(this.rules,t,r,n)),i=Ad(Sa(this.baseHash,a)>>>0);if(!r.hasNameForId(this.componentId,i)){var l=n(a,".".concat(i),void 0,this.componentId);r.insertRules(this.componentId,i,l)}o=Ko(o,i),this.staticRulesId=i}else{for(var s=Sa(this.baseHash,n.hash),u="",c=0;c<this.rules.length;c++){var f=this.rules[c];if(typeof f=="string")u+=f;else if(f){var p=Sg(Yo(f,t,r,n));s=Sa(s,p+c),u+=p}}if(u){var h=Ad(s>>>0);r.hasNameForId(this.componentId,h)||r.insertRules(this.componentId,h,n(u,".".concat(h),void 0,this.componentId)),o=Ko(o,h)}}return o},e})(),e1=ee.createContext(void 0);e1.Consumer;var Dc={};function DB(e,t,r){var n=Sp(e),o=e,a=!kc(e),i=t.attrs,l=i===void 0?hu:i,s=t.componentId,u=s===void 0?(function(D,w){var k=typeof D!="string"?"sc":xg(D);Dc[k]=(Dc[k]||0)+1;var E="".concat(k,"-").concat(U2(mu+k+Dc[k]));return w?"".concat(w,"-").concat(E):E})(t.displayName,t.parentComponentId):s,c=t.displayName,f=c===void 0?(function(D){return kc(D)?"styled.".concat(D):"Styled(".concat(Y2(D),")")})(e):c,p=t.displayName&&t.componentId?"".concat(xg(t.displayName),"-").concat(t.componentId):t.componentId||u,h=n&&o.attrs?o.attrs.concat(l).filter(Boolean):l,v=t.shouldForwardProp;if(n&&o.shouldForwardProp){var g=o.shouldForwardProp;if(t.shouldForwardProp){var m=t.shouldForwardProp;v=function(D,w){return g(D,w)&&m(D,w)}}else v=g}var b=new kB(r,p,n?o.componentStyle:void 0);function y(D,w){return(function(k,E,x){var O=k.attrs,j=k.componentStyle,$=k.defaultProps,P=k.foldedComponentIds,A=k.styledComponentId,B=k.target,S=ee.useContext(e1),I=Og(),N=k.shouldForwardProp||I.shouldForwardProp,F=q2(E,S,$)||Ha,M=(function(te,z,Y){for(var V,U=cn(cn({},z),{className:void 0,theme:Y}),K=0;K<te.length;K+=1){var W=Wa(V=te[K])?V(U):V;for(var re in W)U[re]=re==="className"?Ko(U[re],W[re]):re==="style"?cn(cn({},U[re]),W[re]):W[re]}return z.className&&(U.className=Ko(U.className,z.className)),U})(O,E,F),_=M.as||B,X={};for(var H in M)M[H]===void 0||H[0]==="$"||H==="as"||H==="theme"&&M.theme===F||(H==="forwardedAs"?X.as=M.forwardedAs:N&&!N(H,_)||(X[H]=M[H]));var q=(function(te,z){var Y=Og(),V=te.generateAndInjectStyles(z,Y.styleSheet,Y.stylis);return V})(j,M),Z=Ko(P,A);return q&&(Z+=" "+q),M.className&&(Z+=" "+M.className),X[kc(_)&&!Ly.has(_)?"class":"className"]=Z,x&&(X.ref=x),ks(_,X)})(C,D,w)}y.displayName=f;var C=ee.forwardRef(y);return C.attrs=h,C.componentStyle=b,C.displayName=f,C.shouldForwardProp=v,C.foldedComponentIds=n?Ko(o.foldedComponentIds,o.styledComponentId):"",C.styledComponentId=p,C.target=n?o.target:e,Object.defineProperty(C,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(D){this._foldedDefaultProps=n?(function(w){for(var k=[],E=1;E<arguments.length;E++)k[E-1]=arguments[E];for(var x=0,O=k;x<O.length;x++)Fd(w,O[x],!0);return w})({},o.defaultProps,D):D}}),$p(C,function(){return".".concat(C.styledComponentId)}),a&&Gy(C,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),C}function Fg(e,t){for(var r=[e[0]],n=0,o=t.length;n<o;n+=1)r.push(t[n],e[n+1]);return r}var Ng=function(e){return Object.assign(e,{isCss:!0})};function SB(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(Wa(e)||Zi(e))return Ng(Yo(Fg(hu,js([e],t,!0))));var n=e;return t.length===0&&n.length===1&&typeof n[0]=="string"?Yo(n):Ng(Yo(Fg(n,t)))}function Pd(e,t,r){if(r===void 0&&(r=Ha),!t)throw yl(1,t);var n=function(o){for(var a=[],i=1;i<arguments.length;i++)a[i-1]=arguments[i];return e(t,r,SB.apply(void 0,js([o],a,!1)))};return n.attrs=function(o){return Pd(e,t,cn(cn({},r),{attrs:Array.prototype.concat(r.attrs,o).filter(Boolean)}))},n.withConfig=function(o){return Pd(e,t,cn(cn({},r),o))},n}var t1=function(e){return Pd(DB,e)},fr=t1;Ly.forEach(function(e){fr[e]=t1(e)});const $B=fr.span`
|
|
81
|
+
display: inline-block;
|
|
82
|
+
min-width: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.minWidth)||"80px"}};
|
|
83
|
+
padding: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.padding)||"2px 6px"}};
|
|
84
|
+
margin: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.margin)||"0 2px"}};
|
|
85
|
+
border-radius: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderRadius)||"4px"}};
|
|
86
|
+
border: none !important;
|
|
87
|
+
cursor: pointer;
|
|
88
|
+
transition: all 0.2s;
|
|
89
|
+
font-weight: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.fontWeight)||"500"}};
|
|
90
|
+
user-select: none;
|
|
91
|
+
font-size: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.fontSize)||"14px"}};
|
|
92
|
+
line-height: 2;
|
|
93
|
+
width: auto; /* 让宽度根据内容自动调整 */
|
|
94
|
+
min-width: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.minWidth)||"80px"}};
|
|
95
|
+
min-height: ${e=>{var i,l,s,u;const t=((l=(i=e.$styles)==null?void 0:i.templateField)==null?void 0:l.padding)||"2px 6px",r=((u=(s=e.$styles)==null?void 0:s.templateField)==null?void 0:u.fontSize)||"14px",n=t.split(" ").map(c=>parseInt(c)),o=(n.length,n[0]),a=parseInt(r);return o*2+a*1.4+"px"}};
|
|
96
|
+
|
|
97
|
+
/* 高度自适应 */
|
|
98
|
+
height: auto; /* 允许高度根据内容自动调整 */
|
|
99
|
+
white-space: normal; /* 允许换行 */
|
|
100
|
+
box-sizing: border-box; /* 确保padding和border包含在宽度内 */
|
|
101
|
+
overflow: visible; /* 确保内容不被隐藏 */
|
|
102
|
+
word-wrap: break-word; /* 允许长单词换行 */
|
|
103
|
+
max-width: 100%; /* 限制在容器宽度内 */
|
|
104
|
+
|
|
105
|
+
/* 使用传入的样式配置 */
|
|
106
|
+
background-color: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.backgroundColor)||"#E5EEFF"}};
|
|
107
|
+
color: #055AFF;
|
|
108
|
+
border: 1px solid ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderColor)||"#84ADFF"}};
|
|
109
|
+
|
|
110
|
+
${e=>{var t,r;return e.$isEditing&&`
|
|
111
|
+
background-color: white !important;
|
|
112
|
+
color: #055AFF !important;
|
|
113
|
+
border: 2px solid ${((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderColor)||"#84ADFF"} !important;
|
|
114
|
+
outline: none;
|
|
115
|
+
min-width: 30px;
|
|
116
|
+
`}}
|
|
117
|
+
|
|
118
|
+
&:hover {
|
|
119
|
+
opacity: 0.8;
|
|
120
|
+
}
|
|
121
|
+
`,BB=fr.input`
|
|
122
|
+
background: white;
|
|
123
|
+
border: 2px solid ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderColor)||"#84ADFF"}};
|
|
124
|
+
border-radius: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderRadius)||"4px"}};
|
|
125
|
+
padding: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.padding)||"2px 6px"}};
|
|
126
|
+
margin: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.margin)||"0 2px"}};
|
|
127
|
+
min-width: ${"30px"};
|
|
128
|
+
width: ${e=>{var u,c,f,p;const t=e.$value.length;if(t===0)return((c=(u=e.$styles)==null?void 0:u.templateField)==null?void 0:c.minWidth)||"120px";const r=((p=(f=e.$styles)==null?void 0:f.templateField)==null?void 0:p.padding)||"2px 6.2px",n=r.split(" ").map(h=>parseInt(h)),o=n.length===2?n[1]:n[0],a=12.5,i=20,l=t*a+o*2+i,s=Math.min(Math.max(l,120),e.$maxWidth);return console.log("TemplateInput \u5BBD\u5EA6\u8BA1\u7B97\u8C03\u8BD5:",{contentLength:t,padding:r,paddingValues:n,leftRightPadding:o,charWidth:a,bufferSpace:i,calculatedWidth:l,maxWidth:e.$maxWidth,finalWidth:s,inputValue:e.$value}),s+"px"}} !important; /* 使用!important确保宽度不被覆盖 */
|
|
129
|
+
height: ${e=>{var i,l,s,u;const t=((l=(i=e.$styles)==null?void 0:i.templateField)==null?void 0:l.padding)||"2px 6px",r=((u=(s=e.$styles)==null?void 0:s.templateField)==null?void 0:u.fontSize)||"14px",n=t.split(" ").map(c=>parseInt(c)),o=(n.length,n[0]),a=parseInt(r);return o*2+a*1.4+"px"}};
|
|
130
|
+
font-size: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.fontSize)||"14px"}};
|
|
131
|
+
font-family: inherit;
|
|
132
|
+
outline: none;
|
|
133
|
+
color: #055AFF;
|
|
134
|
+
line-height: 2;
|
|
135
|
+
box-sizing: border-box;
|
|
136
|
+
white-space: nowrap; /* 防止内部换行 */
|
|
137
|
+
overflow: hidden; /* 隐藏超出部分 */
|
|
138
|
+
text-overflow: ellipsis; /* 超出部分显示省略号 */
|
|
139
|
+
|
|
140
|
+
&:focus {
|
|
141
|
+
border-color: ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderColor)||"#84ADFF"}};
|
|
142
|
+
box-shadow: 0 0 0 3px ${e=>{var t,r;return((r=(t=e.$styles)==null?void 0:t.templateField)==null?void 0:r.borderColor)||"#84ADFF"}}20;
|
|
143
|
+
}
|
|
144
|
+
`,r1=dn(({element:e,attributes:t,children:r,styles:n,onTemplateChange:o},a)=>{var k,E,x,O,j,$,P,A,B,S,I,N;const i=yy(),[l,s]=yt(!1),[u,c]=yt(e.value||""),[f,p]=yt(e.value&&e.value!==""?e.value:e.placeholder||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9"),[h,v]=yt(600),g=qe(null),m=mt(()=>{try{const F=document.querySelector('[data-slate-editor="true"]');if(F){const M=F.closest('.sc-jwTyAe, .bdQKlw, [role="textbox"]')||F.parentElement;if(M){const _=M.clientWidth,X=_-40;return console.log("TemplateField: \u7F16\u8F91\u5668\u5BB9\u5668\u5BBD\u5EA6:",_,"\u53EF\u7528\u5BBD\u5EA6:",X),Math.max(X,200)}}return 600}catch(F){return console.warn("TemplateField: \u65E0\u6CD5\u83B7\u53D6\u7F16\u8F91\u5668\u5BBD\u5EA6\uFF0C\u4F7F\u7528\u9ED8\u8BA4\u503C:",F),600}},[]);Ot(()=>{p(e.value&&e.value!==""?e.value:e.placeholder||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9");const F=m();v(F)},[e.value,e.placeholder,m]);const b=mt(()=>{s(!0),c(e.value||""),setTimeout(()=>{g.current&&(g.current.focus(),g.current.select())},0)},[e.value]),y=mt(F=>{const M=F.target.value;c(M)},[]),C=mt(()=>{const F=Ae.findPath(i,e);console.log("TemplateField: \u627E\u5230\u5143\u7D20\u8DEF\u5F84:",F),console.log("TemplateField: \u5F53\u524D\u5143\u7D20:",e),console.log("TemplateField: \u8981\u8BBE\u7F6E\u7684\u503C:",u),Re.setNodes(i,{value:u},{at:F});const M=u.trim()!==""?u:e.placeholder||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9";p(M);const _=i.children[F[0]];if(_&&"children"in _){const X=_.children[F[1]];console.log("TemplateField: \u66F4\u65B0\u540E\u7684\u5143\u7D20:",X)}s(!1)},[i,e,u]),D=mt(()=>{C()},[C]),w=mt(F=>{F.key==="Enter"?(F.preventDefault(),C()):F.key==="Escape"&&(F.preventDefault(),c(e.value||""),s(!1))},[C,e.value]);return l?Q.jsxs("span",{...t,"data-slate-void":"true","data-slate-inline":"true","data-slate-length":"0",contentEditable:!1,children:[Q.jsx(BB,{ref:g,value:u,onChange:y,onBlur:D,onKeyDown:w,placeholder:"",$styles:n,$value:u,$maxWidth:h,style:{backgroundColor:"white",color:((k=n==null?void 0:n.templateField)==null?void 0:k.textColor)||"#055AFF",border:`2px solid ${((E=n==null?void 0:n.templateField)==null?void 0:E.borderColor)||"#84ADFF"}`,minWidth:((x=n==null?void 0:n.templateField)==null?void 0:x.minWidth)||"120px"}}),r]}):Q.jsxs("span",{...t,"data-slate-void":"true","data-slate-inline":"true","data-slate-length":"0",contentEditable:!1,children:[Q.jsxs($B,{ref:a,$style:e.style||"blue",$isEditing:!1,$styles:n,$contentLength:f.length,onClick:b,style:{letterSpacing:n==null?void 0:n.letterSpacing,lineHeight:n==null?void 0:n.lineHeight,backgroundColor:(O=n==null?void 0:n.templateField)==null?void 0:O.backgroundColor,borderColor:(j=n==null?void 0:n.templateField)==null?void 0:j.borderColor,borderRadius:($=n==null?void 0:n.templateField)==null?void 0:$.borderRadius,padding:(P=n==null?void 0:n.templateField)==null?void 0:P.padding,margin:(A=n==null?void 0:n.templateField)==null?void 0:A.margin,fontSize:(B=n==null?void 0:n.templateField)==null?void 0:B.fontSize,fontWeight:(S=n==null?void 0:n.templateField)==null?void 0:S.fontWeight,minWidth:(I=n==null?void 0:n.templateField)==null?void 0:I.minWidth,color:(N=n==null?void 0:n.templateField)==null?void 0:N.textColor,width:"auto",maxWidth:"100%"},children:[(console.log("TemplateField \u6E32\u67D3\u8C03\u8BD5:",{elementValue:e.value,elementPlaceholder:e.placeholder,displayValue:f,displayValueLength:f.length,contentLength:f.length}),null),f]}),Q.jsx("span",{contentEditable:!1,style:{display:"none"},children:r})]})});r1.displayName="TemplateField";const OB=({children:e,attributes:t,styles:r,extraProps:n})=>{var a;const o=!!(n!=null&&n.isCollapsed);return Q.jsxs("div",{...t,className:"think-container",children:[Q.jsx("div",{className:"think-indicator"}),Q.jsx("div",{className:"think-content",children:Q.jsx("div",{className:"think-text text-[#86909C] pl-5 my-3 border border-[#ECECEE] border-solid border-l-3 border-t-0 border-b-0 border-r-0",style:{color:`${(a=r==null?void 0:r.text)==null?void 0:a.color} !important`,display:o?"none":"block"},children:e})})]})};var Pg={exports:{}};/*!
|
|
145
|
+
Copyright (c) 2018 Jed Watson.
|
|
146
|
+
Licensed under the MIT License (MIT), see
|
|
147
|
+
http://jedwatson.github.io/classnames
|
|
148
|
+
*/var jg;function AB(){return jg||(jg=1,(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var a="",i=0;i<arguments.length;i++){var l=arguments[i];l&&(a=o(a,n(l)))}return a}function n(a){if(typeof a=="string"||typeof a=="number")return a;if(typeof a!="object")return"";if(Array.isArray(a))return r.apply(null,a);if(a.toString!==Object.prototype.toString&&!a.toString.toString().includes("[native code]"))return a.toString();var i="";for(var l in a)t.call(a,l)&&a[l]&&(i=o(i,l));return i}function o(a,i){return i?a?a+" "+i:a+i:a}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(Pg)),Pg.exports}var FB=AB();const pe=vl(FB);function Me(){return Me=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Me.apply(null,arguments)}function at(e){"@babel/helpers - typeof";return at=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},at(e)}var NB=Symbol.for("react.element"),PB=Symbol.for("react.transitional.element"),jB=Symbol.for("react.fragment");function n1(e){return e&&at(e)==="object"&&(e.$$typeof===NB||e.$$typeof===PB)&&e.type===jB}function Ln(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=[];return ee.Children.forEach(e,function(n){n==null&&!t.keepEmpty||(Array.isArray(n)?r=r.concat(Ln(n)):n1(n)&&n.props?r=r.concat(Ln(n.props.children,t)):r.push(n))}),r}var jd={},IB=function(e){};function RB(e,t){}function MB(e,t){}function TB(){jd={}}function o1(e,t,r){!t&&!jd[r]&&(e(!1,r),jd[r]=!0)}function lr(e,t){o1(RB,e,t)}function zB(e,t){o1(MB,e,t)}lr.preMessage=IB;lr.resetWarned=TB;lr.noteOnce=zB;function _B(e,t){if(at(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(at(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function a1(e){var t=_B(e,"string");return at(t)=="symbol"?t:t+""}function T(e,t,r){return(t=a1(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ig(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function L(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ig(Object(r),!0).forEach(function(n){T(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ig(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Ji(e){return e instanceof HTMLElement||e instanceof SVGElement}function gu(e){return e&&at(e)==="object"&&Ji(e.nativeElement)?e.nativeElement:Ji(e)?e:null}function ps(e){var t=gu(e);if(t)return t;if(e instanceof ee.Component){var r;return(r=Wi.findDOMNode)===null||r===void 0?void 0:r.call(Wi,e)}return null}var Rg={exports:{}},Xt={};/**
|
|
149
|
+
* @license React
|
|
150
|
+
* react-is.production.min.js
|
|
151
|
+
*
|
|
152
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
153
|
+
*
|
|
154
|
+
* This source code is licensed under the MIT license found in the
|
|
155
|
+
* LICENSE file in the root directory of this source tree.
|
|
156
|
+
*/var Mg;function LB(){if(Mg)return Xt;Mg=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),s=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),h=Symbol.for("react.offscreen"),v;v=Symbol.for("react.module.reference");function g(m){if(typeof m=="object"&&m!==null){var b=m.$$typeof;switch(b){case e:switch(m=m.type,m){case r:case o:case n:case u:case c:return m;default:switch(m=m&&m.$$typeof,m){case l:case i:case s:case p:case f:case a:return m;default:return b}}case t:return b}}}return Xt.ContextConsumer=i,Xt.ContextProvider=a,Xt.Element=e,Xt.ForwardRef=s,Xt.Fragment=r,Xt.Lazy=p,Xt.Memo=f,Xt.Portal=t,Xt.Profiler=o,Xt.StrictMode=n,Xt.Suspense=u,Xt.SuspenseList=c,Xt.isAsyncMode=function(){return!1},Xt.isConcurrentMode=function(){return!1},Xt.isContextConsumer=function(m){return g(m)===i},Xt.isContextProvider=function(m){return g(m)===a},Xt.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===e},Xt.isForwardRef=function(m){return g(m)===s},Xt.isFragment=function(m){return g(m)===r},Xt.isLazy=function(m){return g(m)===p},Xt.isMemo=function(m){return g(m)===f},Xt.isPortal=function(m){return g(m)===t},Xt.isProfiler=function(m){return g(m)===o},Xt.isStrictMode=function(m){return g(m)===n},Xt.isSuspense=function(m){return g(m)===u},Xt.isSuspenseList=function(m){return g(m)===c},Xt.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===r||m===o||m===n||m===u||m===c||m===h||typeof m=="object"&&m!==null&&(m.$$typeof===p||m.$$typeof===f||m.$$typeof===a||m.$$typeof===i||m.$$typeof===s||m.$$typeof===v||m.getModuleId!==void 0)},Xt.typeOf=g,Xt}var Tg;function HB(){return Tg||(Tg=1,Rg.exports=LB()),Rg.exports}var Sc=HB();function la(e,t,r){var n=d.useRef({});return(!("value"in n.current)||r(n.current.condition,t))&&(n.current.value=e(),n.current.condition=t),n.current.value}var WB=Number(_w.split(".")[0]),Qi=function(e,t){typeof e=="function"?e(t):at(e)==="object"&&e&&"current"in e&&(e.current=t)},ro=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=t.filter(Boolean);return n.length<=1?n[0]:function(o){t.forEach(function(a){Qi(a,o)})}},sa=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return la(function(){return ro.apply(void 0,t)},t,function(n,o){return n.length!==o.length||n.every(function(a,i){return a!==o[i]})})},Zn=function(e){var t,r;if(!e)return!1;if(Bp(e)&&WB>=19)return!0;var n=Sc.isMemo(e)?e.type.type:e.type;return!(typeof n=="function"&&!((t=n.prototype)!==null&&t!==void 0&&t.render)&&n.$$typeof!==Sc.ForwardRef||typeof e=="function"&&!((r=e.prototype)!==null&&r!==void 0&&r.render)&&e.$$typeof!==Sc.ForwardRef)};function Bp(e){return Hw(e)&&!n1(e)}var KB=function(e){return Bp(e)&&Zn(e)},ua=function(e){if(e&&Bp(e)){var t=e;return t.props.propertyIsEnumerable("ref")?t.props.ref:t.ref}return null},Id=d.createContext(null);function qB(e){var t=e.children,r=e.onBatchResize,n=d.useRef(0),o=d.useRef([]),a=d.useContext(Id),i=d.useCallback(function(l,s,u){n.current+=1;var c=n.current;o.current.push({size:l,element:s,data:u}),Promise.resolve().then(function(){c===n.current&&(r==null||r(o.current),o.current=[])}),a==null||a(l,s,u)},[r,a]);return d.createElement(Id.Provider,{value:i},t)}var i1=(function(){if(typeof Map<"u")return Map;function e(t,r){var n=-1;return t.some(function(o,a){return o[0]===r?(n=a,!0):!1}),n}return(function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(r){var n=e(this.__entries__,r),o=this.__entries__[n];return o&&o[1]},t.prototype.set=function(r,n){var o=e(this.__entries__,r);~o?this.__entries__[o][1]=n:this.__entries__.push([r,n])},t.prototype.delete=function(r){var n=this.__entries__,o=e(n,r);~o&&n.splice(o,1)},t.prototype.has=function(r){return!!~e(this.__entries__,r)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(r,n){n===void 0&&(n=null);for(var o=0,a=this.__entries__;o<a.length;o++){var i=a[o];r.call(n,i[1],i[0])}},t})()})(),Rd=typeof window<"u"&&typeof document<"u"&&window.document===document,Ts=(function(){return typeof global<"u"&&global.Math===Math?global:typeof self<"u"&&self.Math===Math?self:typeof window<"u"&&window.Math===Math?window:Function("return this")()})(),VB=(function(){return typeof requestAnimationFrame=="function"?requestAnimationFrame.bind(Ts):function(e){return setTimeout(function(){return e(Date.now())},1e3/60)}})(),GB=2;function XB(e,t){var r=!1,n=!1,o=0;function a(){r&&(r=!1,e()),n&&l()}function i(){VB(a)}function l(){var s=Date.now();if(r){if(s-o<GB)return;n=!0}else r=!0,n=!1,setTimeout(i,t);o=s}return l}var UB=20,YB=["top","right","bottom","left","width","height","size","weight"],ZB=typeof MutationObserver<"u",JB=(function(){function e(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=XB(this.refresh.bind(this),UB)}return e.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},e.prototype.removeObserver=function(t){var r=this.observers_,n=r.indexOf(t);~n&&r.splice(n,1),!r.length&&this.connected_&&this.disconnect_()},e.prototype.refresh=function(){var t=this.updateObservers_();t&&this.refresh()},e.prototype.updateObservers_=function(){var t=this.observers_.filter(function(r){return r.gatherActive(),r.hasActive()});return t.forEach(function(r){return r.broadcastActive()}),t.length>0},e.prototype.connect_=function(){!Rd||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),ZB?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){!Rd||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(t){var r=t.propertyName,n=r===void 0?"":r,o=YB.some(function(a){return!!~n.indexOf(a)});o&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e})(),l1=(function(e,t){for(var r=0,n=Object.keys(t);r<n.length;r++){var o=n[r];Object.defineProperty(e,o,{value:t[o],enumerable:!1,writable:!1,configurable:!0})}return e}),Ka=(function(e){var t=e&&e.ownerDocument&&e.ownerDocument.defaultView;return t||Ts}),s1=vu(0,0,0,0);function zs(e){return parseFloat(e)||0}function zg(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return t.reduce(function(n,o){var a=e["border-"+o+"-width"];return n+zs(a)},0)}function QB(e){for(var t=["top","right","bottom","left"],r={},n=0,o=t;n<o.length;n++){var a=o[n],i=e["padding-"+a];r[a]=zs(i)}return r}function eO(e){var t=e.getBBox();return vu(0,0,t.width,t.height)}function tO(e){var t=e.clientWidth,r=e.clientHeight;if(!t&&!r)return s1;var n=Ka(e).getComputedStyle(e),o=QB(n),a=o.left+o.right,i=o.top+o.bottom,l=zs(n.width),s=zs(n.height);if(n.boxSizing==="border-box"&&(Math.round(l+a)!==t&&(l-=zg(n,"left","right")+a),Math.round(s+i)!==r&&(s-=zg(n,"top","bottom")+i)),!nO(e)){var u=Math.round(l+a)-t,c=Math.round(s+i)-r;Math.abs(u)!==1&&(l-=u),Math.abs(c)!==1&&(s-=c)}return vu(o.left,o.top,l,s)}var rO=(function(){return typeof SVGGraphicsElement<"u"?function(e){return e instanceof Ka(e).SVGGraphicsElement}:function(e){return e instanceof Ka(e).SVGElement&&typeof e.getBBox=="function"}})();function nO(e){return e===Ka(e).document.documentElement}function oO(e){return Rd?rO(e)?eO(e):tO(e):s1}function aO(e){var t=e.x,r=e.y,n=e.width,o=e.height,a=typeof DOMRectReadOnly<"u"?DOMRectReadOnly:Object,i=Object.create(a.prototype);return l1(i,{x:t,y:r,width:n,height:o,top:r,right:t+n,bottom:o+r,left:t}),i}function vu(e,t,r,n){return{x:e,y:t,width:r,height:n}}var iO=(function(){function e(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=vu(0,0,0,0),this.target=t}return e.prototype.isActive=function(){var t=oO(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},e.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t},e})(),lO=(function(){function e(t,r){var n=aO(r);l1(this,{target:t,contentRect:n})}return e})(),sO=(function(){function e(t,r,n){if(this.activeObservations_=[],this.observations_=new i1,typeof t!="function")throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=r,this.callbackCtx_=n}return e.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof Ka(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var r=this.observations_;r.has(t)||(r.set(t,new iO(t)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof Ka(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var r=this.observations_;r.has(t)&&(r.delete(t),r.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach(function(r){r.isActive()&&t.activeObservations_.push(r)})},e.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,r=this.activeObservations_.map(function(n){return new lO(n.target,n.broadcastRect())});this.callback_.call(t,r,t),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e})(),u1=typeof WeakMap<"u"?new WeakMap:new i1,c1=(function(){function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var r=JB.getInstance(),n=new sO(t,r,this);u1.set(this,n)}return e})();["observe","unobserve","disconnect"].forEach(function(e){c1.prototype[e]=function(){var t;return(t=u1.get(this))[e].apply(t,arguments)}});var uO=(function(){return typeof Ts.ResizeObserver<"u"?Ts.ResizeObserver:c1})(),Bo=new Map;function cO(e){e.forEach(function(t){var r,n=t.target;(r=Bo.get(n))===null||r===void 0||r.forEach(function(o){return o(n)})})}var d1=new uO(cO);function dO(e,t){Bo.has(e)||(Bo.set(e,new Set),d1.observe(e)),Bo.get(e).add(t)}function fO(e,t){Bo.has(e)&&(Bo.get(e).delete(t),Bo.get(e).size||(d1.unobserve(e),Bo.delete(e)))}function vr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _g(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,a1(n.key),n)}}function br(e,t,r){return t&&_g(e.prototype,t),r&&_g(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function el(e,t){return el=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},el(e,t)}function no(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&el(e,t)}function tl(e){return tl=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},tl(e)}function Op(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Op=function(){return!!e})()}function et(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pO(e,t){if(t&&(at(t)=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return et(e)}function oo(e){var t=Op();return function(){var r,n=tl(e);if(t){var o=tl(this).constructor;r=Reflect.construct(n,arguments,o)}else r=n.apply(this,arguments);return pO(this,r)}}var mO=(function(e){no(r,e);var t=oo(r);function r(){return vr(this,r),t.apply(this,arguments)}return br(r,[{key:"render",value:function(){return this.props.children}}]),r})(d.Component);function hO(e,t){var r=e.children,n=e.disabled,o=d.useRef(null),a=d.useRef(null),i=d.useContext(Id),l=typeof r=="function",s=l?r(o):r,u=d.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),c=!l&&d.isValidElement(s)&&Zn(s),f=c?ua(s):null,p=sa(f,o),h=function(){var m;return ps(o.current)||(o.current&&at(o.current)==="object"?ps((m=o.current)===null||m===void 0?void 0:m.nativeElement):null)||ps(a.current)};d.useImperativeHandle(t,function(){return h()});var v=d.useRef(e);v.current=e;var g=d.useCallback(function(m){var b=v.current,y=b.onResize,C=b.data,D=m.getBoundingClientRect(),w=D.width,k=D.height,E=m.offsetWidth,x=m.offsetHeight,O=Math.floor(w),j=Math.floor(k);if(u.current.width!==O||u.current.height!==j||u.current.offsetWidth!==E||u.current.offsetHeight!==x){var $={width:O,height:j,offsetWidth:E,offsetHeight:x};u.current=$;var P=E===Math.round(w)?w:E,A=x===Math.round(k)?k:x,B=L(L({},$),{},{offsetWidth:P,offsetHeight:A});i==null||i(B,m,C),y&&Promise.resolve().then(function(){y(B,m)})}},[]);return d.useEffect(function(){var m=h();return m&&!n&&dO(m,g),function(){return fO(m,g)}},[o.current,n]),d.createElement(mO,{ref:a},c?d.cloneElement(s,{ref:p}):s)}var gO=d.forwardRef(hO),vO="rc-observer-key";function bO(e,t){var r=e.children,n=typeof r=="function"?[r]:Ln(r);return n.map(function(o,a){var i=(o==null?void 0:o.key)||"".concat(vO,"-").concat(a);return d.createElement(gO,Me({},e,{key:i,ref:a===0?t:void 0}),o)})}var ao=d.forwardRef(bO);ao.Collection=qB;function Md(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function yO(e){if(Array.isArray(e))return Md(e)}function f1(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Ap(e,t){if(e){if(typeof e=="string")return Md(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Md(e,t):void 0}}function CO(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
157
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ie(e){return yO(e)||f1(e)||Ap(e)||CO()}var p1=function(e){return+setTimeout(e,16)},m1=function(e){return clearTimeout(e)};typeof window<"u"&&"requestAnimationFrame"in window&&(p1=function(e){return window.requestAnimationFrame(e)},m1=function(e){return window.cancelAnimationFrame(e)});var Lg=0,Fp=new Map;function h1(e){Fp.delete(e)}var qt=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;Lg+=1;var r=Lg;function n(o){if(o===0)h1(r),e();else{var a=p1(function(){n(o-1)});Fp.set(r,a)}}return n(t),r};qt.cancel=function(e){var t=Fp.get(e);return h1(e),m1(t)};function g1(e){if(Array.isArray(e))return e}function xO(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,o,a,i,l=[],s=!0,u=!1;try{if(a=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;s=!1}else for(;!(s=(n=a.call(r)).done)&&(l.push(n.value),l.length!==t);s=!0);}catch(c){u=!0,o=c}finally{try{if(!s&&r.return!=null&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return l}}function v1(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
158
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ce(e,t){return g1(e)||xO(e,t)||Ap(e,t)||v1()}function rl(e){for(var t=0,r,n=0,o=e.length;o>=4;++n,o-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.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 Xr(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function wO(e,t){if(!e)return!1;if(e.contains)return e.contains(t);for(var r=t;r;){if(r===e)return!0;r=r.parentNode}return!1}var Hg="data-rc-order",Wg="data-rc-priority",EO="rc-util-key",Td=new Map;function b1(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=e.mark;return t?t.startsWith("data-")?t:"data-".concat(t):EO}function bu(e){if(e.attachTo)return e.attachTo;var t=document.querySelector("head");return t||document.body}function kO(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function Np(e){return Array.from((Td.get(e)||e).children).filter(function(t){return t.tagName==="STYLE"})}function y1(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!Xr())return null;var r=t.csp,n=t.prepend,o=t.priority,a=o===void 0?0:o,i=kO(n),l=i==="prependQueue",s=document.createElement("style");s.setAttribute(Hg,i),l&&a&&s.setAttribute(Wg,"".concat(a)),r!=null&&r.nonce&&(s.nonce=r==null?void 0:r.nonce),s.innerHTML=e;var u=bu(t),c=u.firstChild;if(n){if(l){var f=(t.styles||Np(u)).filter(function(p){if(!["prepend","prependQueue"].includes(p.getAttribute(Hg)))return!1;var h=Number(p.getAttribute(Wg)||0);return a>=h});if(f.length)return u.insertBefore(s,f[f.length-1].nextSibling),s}u.insertBefore(s,c)}else u.appendChild(s);return s}function C1(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=bu(t);return(t.styles||Np(r)).find(function(n){return n.getAttribute(b1(t))===e})}function nl(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=C1(e,t);if(r){var n=bu(t);n.removeChild(r)}}function DO(e,t){var r=Td.get(e);if(!r||!wO(document,r)){var n=y1("",t),o=n.parentNode;Td.set(e,o),e.removeChild(n)}}function go(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=bu(r),o=Np(n),a=L(L({},r),{},{styles:o});DO(n,a);var i=C1(t,a);if(i){var l,s;if((l=a.csp)!==null&&l!==void 0&&l.nonce&&i.nonce!==((s=a.csp)===null||s===void 0?void 0:s.nonce)){var u;i.nonce=(u=a.csp)===null||u===void 0?void 0:u.nonce}return i.innerHTML!==e&&(i.innerHTML=e),i}var c=y1(e,a);return c.setAttribute(b1(a),t),c}function SO(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function bt(e,t){if(e==null)return{};var r,n,o=SO(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)r=a[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function Jn(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=new Set;function o(a,i){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,s=n.has(a);if(lr(!s,"Warning: There may be circular references"),s)return!1;if(a===i)return!0;if(r&&l>1)return!1;n.add(a);var u=l+1;if(Array.isArray(a)){if(!Array.isArray(i)||a.length!==i.length)return!1;for(var c=0;c<a.length;c++)if(!o(a[c],i[c],u))return!1;return!0}if(a&&i&&at(a)==="object"&&at(i)==="object"){var f=Object.keys(a);return f.length!==Object.keys(i).length?!1:f.every(function(p){return o(a[p],i[p],u)})}return!1}return o(e,t)}var $O="%";function zd(e){return e.join($O)}var BO=(function(){function e(t){vr(this,e),T(this,"instanceId",void 0),T(this,"cache",new Map),T(this,"extracted",new Set),this.instanceId=t}return br(e,[{key:"get",value:function(t){return this.opGet(zd(t))}},{key:"opGet",value:function(t){return this.cache.get(t)||null}},{key:"update",value:function(t,r){return this.opUpdate(zd(t),r)}},{key:"opUpdate",value:function(t,r){var n=this.cache.get(t),o=r(n);o===null?this.cache.delete(t):this.cache.set(t,o)}}]),e})(),qa="data-token-hash",zn="data-css-hash",Oo="__cssinjs_instance__";function OO(){var e=Math.random().toString(12).slice(2);if(typeof document<"u"&&document.head&&document.body){var t=document.body.querySelectorAll("style[".concat(zn,"]"))||[],r=document.head.firstChild;Array.from(t).forEach(function(o){o[Oo]=o[Oo]||e,o[Oo]===e&&document.head.insertBefore(o,r)});var n={};Array.from(document.querySelectorAll("style[".concat(zn,"]"))).forEach(function(o){var a=o.getAttribute(zn);if(n[a]){if(o[Oo]===e){var i;(i=o.parentNode)===null||i===void 0||i.removeChild(o)}}else n[a]=!0})}return new BO(e)}var Cl=d.createContext({hashPriority:"low",cache:OO(),defaultCache:!0});function AO(e,t){if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}var Pp=(function(){function e(){vr(this,e),T(this,"cache",void 0),T(this,"keys",void 0),T(this,"cacheCallTimes",void 0),this.cache=new Map,this.keys=[],this.cacheCallTimes=0}return br(e,[{key:"size",value:function(){return this.keys.length}},{key:"internalGet",value:function(t){var r,n,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,a={map:this.cache};return t.forEach(function(i){if(!a)a=void 0;else{var l;a=(l=a)===null||l===void 0||(l=l.map)===null||l===void 0?void 0:l.get(i)}}),(r=a)!==null&&r!==void 0&&r.value&&o&&(a.value[1]=this.cacheCallTimes++),(n=a)===null||n===void 0?void 0:n.value}},{key:"get",value:function(t){var r;return(r=this.internalGet(t,!0))===null||r===void 0?void 0:r[0]}},{key:"has",value:function(t){return!!this.internalGet(t)}},{key:"set",value:function(t,r){var n=this;if(!this.has(t)){if(this.size()+1>e.MAX_CACHE_SIZE+e.MAX_CACHE_OFFSET){var o=this.keys.reduce(function(s,u){var c=ce(s,2),f=c[1];return n.internalGet(u)[1]<f?[u,n.internalGet(u)[1]]:s},[this.keys[0],this.cacheCallTimes]),a=ce(o,1),i=a[0];this.delete(i)}this.keys.push(t)}var l=this.cache;t.forEach(function(s,u){if(u===t.length-1)l.set(s,{value:[r,n.cacheCallTimes++]});else{var c=l.get(s);c?c.map||(c.map=new Map):l.set(s,{map:new Map}),l=l.get(s).map}})}},{key:"deleteByPath",value:function(t,r){var n=t.get(r[0]);if(r.length===1){var o;return n.map?t.set(r[0],{map:n.map}):t.delete(r[0]),(o=n.value)===null||o===void 0?void 0:o[0]}var a=this.deleteByPath(n.map,r.slice(1));return(!n.map||n.map.size===0)&&!n.value&&t.delete(r[0]),a}},{key:"delete",value:function(t){if(this.has(t))return this.keys=this.keys.filter(function(r){return!AO(r,t)}),this.deleteByPath(this.cache,t)}}]),e})();T(Pp,"MAX_CACHE_SIZE",20);T(Pp,"MAX_CACHE_OFFSET",5);var Kg=0,x1=(function(){function e(t){vr(this,e),T(this,"derivatives",void 0),T(this,"id",void 0),this.derivatives=Array.isArray(t)?t:[t],this.id=Kg,t.length===0&&(t.length>0,void 0),Kg+=1}return br(e,[{key:"getDerivativeToken",value:function(t){return this.derivatives.reduce(function(r,n){return n(t,r)},void 0)}}]),e})(),$c=new Pp;function _d(e){var t=Array.isArray(e)?e:[e];return $c.has(t)||$c.set(t,new x1(t)),$c.get(t)}var FO=new WeakMap,Bc={};function NO(e,t){for(var r=FO,n=0;n<t.length;n+=1){var o=t[n];r.has(o)||r.set(o,new WeakMap),r=r.get(o)}return r.has(Bc)||r.set(Bc,e()),r.get(Bc)}var qg=new WeakMap;function Mi(e){var t=qg.get(e)||"";return t||(Object.keys(e).forEach(function(r){var n=e[r];t+=r,n instanceof x1?t+=n.id:n&&at(n)==="object"?t+=Mi(n):t+=n}),t=rl(t),qg.set(e,t)),t}function Vg(e,t){return rl("".concat(t,"_").concat(Mi(e)))}var Ld=Xr();function ue(e){return typeof e=="number"?"".concat(e,"px"):e}function _s(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(o)return e;var a=L(L({},n),{},T(T({},qa,t),zn,r)),i=Object.keys(a).map(function(l){var s=a[l];return s?"".concat(l,'="').concat(s,'"'):null}).filter(function(l){return l}).join(" ");return"<style ".concat(i,">").concat(e,"</style>")}var ms=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return"--".concat(t?"".concat(t,"-"):"").concat(e).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()},PO=function(e,t,r){return Object.keys(e).length?".".concat(t).concat(r!=null&&r.scope?".".concat(r.scope):"","{").concat(Object.entries(e).map(function(n){var o=ce(n,2),a=o[0],i=o[1];return"".concat(a,":").concat(i,";")}).join(""),"}"):""},w1=function(e,t,r){var n={},o={};return Object.entries(e).forEach(function(a){var i,l,s=ce(a,2),u=s[0],c=s[1];if(r!=null&&(i=r.preserve)!==null&&i!==void 0&&i[u])o[u]=c;else if((typeof c=="string"||typeof c=="number")&&!(r!=null&&(l=r.ignore)!==null&&l!==void 0&&l[u])){var f,p=ms(u,r==null?void 0:r.prefix);n[p]=typeof c=="number"&&!(r!=null&&(f=r.unitless)!==null&&f!==void 0&&f[u])?"".concat(c,"px"):String(c),o[u]="var(".concat(p,")")}}),[o,PO(n,t,{scope:r==null?void 0:r.scope})]},Gg=Xr()?d.useLayoutEffect:d.useEffect,Wt=function(e,t){var r=d.useRef(!0);Gg(function(){return e(r.current)},t),Gg(function(){return r.current=!1,function(){r.current=!0}},[])},Xg=function(e,t){Wt(function(r){if(!r)return e()},t)},jO=L({},d),Ug=jO.useInsertionEffect,IO=function(e,t,r){d.useMemo(e,r),Wt(function(){return t(!0)},r)},RO=Ug?function(e,t,r){return Ug(function(){return e(),t()},r)}:IO,MO=L({},d),TO=MO.useInsertionEffect,zO=function(e){var t=[],r=!1;function n(o){r||t.push(o)}return d.useEffect(function(){return r=!1,function(){r=!0,t.length&&t.forEach(function(o){return o()})}},e),n},_O=function(){return function(e){e()}},LO=typeof TO<"u"?zO:_O;function jp(e,t,r,n,o){var a=d.useContext(Cl),i=a.cache,l=[e].concat(Ie(t)),s=zd(l),u=LO([s]),c=function(h){i.opUpdate(s,function(v){var g=v||[void 0,void 0],m=ce(g,2),b=m[0],y=b===void 0?0:b,C=m[1],D=C,w=D||r(),k=[y,w];return h?h(k):k})};d.useMemo(function(){c()},[s]);var f=i.opGet(s),p=f[1];return RO(function(){o==null||o(p)},function(h){return c(function(v){var g=ce(v,2),m=g[0],b=g[1];return h&&m===0&&(o==null||o(p)),[m+1,b]}),function(){i.opUpdate(s,function(v){var g=v||[],m=ce(g,2),b=m[0],y=b===void 0?0:b,C=m[1],D=y-1;return D===0?(u(function(){(h||!i.opGet(s))&&(n==null||n(C,!1))}),null):[y-1,C]})}},[s]),p}var HO={},WO="css",Ho=new Map;function KO(e){Ho.set(e,(Ho.get(e)||0)+1)}function qO(e,t){if(typeof document<"u"){var r=document.querySelectorAll("style[".concat(qa,'="').concat(e,'"]'));r.forEach(function(n){if(n[Oo]===t){var o;(o=n.parentNode)===null||o===void 0||o.removeChild(n)}})}}var VO=0;function GO(e,t){Ho.set(e,(Ho.get(e)||0)-1);var r=new Set;Ho.forEach(function(n,o){n<=0&&r.add(o)}),Ho.size-r.size>VO&&r.forEach(function(n){qO(n,t),Ho.delete(n)})}var XO=function(e,t,r,n){var o=r.getDerivativeToken(e),a=L(L({},o),t);return n&&(a=n(a)),a},E1="token";function UO(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=Rr(Cl),o=n.cache.instanceId,a=n.container,i=r.salt,l=i===void 0?"":i,s=r.override,u=s===void 0?HO:s,c=r.formatToken,f=r.getComputedToken,p=r.cssVar,h=NO(function(){return Object.assign.apply(Object,[{}].concat(Ie(t)))},t),v=Mi(h),g=Mi(u),m=p?Mi(p):"",b=jp(E1,[l,e.id,v,g,m],function(){var y,C=f?f(h,u,e):XO(h,u,e,c),D=L({},C),w="";if(p){var k=w1(C,p.key,{prefix:p.prefix,ignore:p.ignore,unitless:p.unitless,preserve:p.preserve}),E=ce(k,2);C=E[0],w=E[1]}var x=Vg(C,l);C._tokenKey=x,D._tokenKey=Vg(D,l);var O=(y=p==null?void 0:p.key)!==null&&y!==void 0?y:x;C._themeKey=O,KO(O);var j="".concat(WO,"-").concat(rl(x));return C._hashId=j,[C,j,D,w,(p==null?void 0:p.key)||""]},function(y){GO(y[0]._themeKey,o)},function(y){var C=ce(y,4),D=C[0],w=C[3];if(p&&w){var k=go(w,rl("css-variables-".concat(D._themeKey)),{mark:zn,prepend:"queue",attachTo:a,priority:-999});k[Oo]=o,k.setAttribute(qa,D._themeKey)}});return b}var YO=function(e,t,r){var n=ce(e,5),o=n[2],a=n[3],i=n[4],l=r||{},s=l.plain;if(!a)return null;var u=o._tokenKey,c=-999,f={"data-rc-order":"prependQueue","data-rc-priority":"".concat(c)},p=_s(a,i,u,f,s);return[c,u,p]},ZO={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},k1="comm",D1="rule",S1="decl",JO="@import",QO="@namespace",eA="@keyframes",tA="@layer",$1=Math.abs,Ip=String.fromCharCode;function B1(e){return e.trim()}function hs(e,t,r){return e.replace(t,r)}function rA(e,t,r){return e.indexOf(t,r)}function Na(e,t){return e.charCodeAt(t)|0}function Va(e,t,r){return e.slice(t,r)}function Xn(e){return e.length}function nA(e){return e.length}function ql(e,t){return t.push(e),e}var yu=1,Ga=1,O1=0,An=0,kr=0,ni="";function Rp(e,t,r,n,o,a,i,l){return{value:e,root:t,parent:r,type:n,props:o,children:a,line:yu,column:Ga,length:i,return:"",siblings:l}}function oA(){return kr}function aA(){return kr=An>0?Na(ni,--An):0,Ga--,kr===10&&(Ga=1,yu--),kr}function _n(){return kr=An<O1?Na(ni,An++):0,Ga++,kr===10&&(Ga=1,yu++),kr}function Ao(){return Na(ni,An)}function gs(){return An}function Cu(e,t){return Va(ni,e,t)}function ol(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function iA(e){return yu=Ga=1,O1=Xn(ni=e),An=0,[]}function lA(e){return ni="",e}function Oc(e){return B1(Cu(An-1,Hd(e===91?e+2:e===40?e+1:e)))}function sA(e){for(;(kr=Ao())&&kr<33;)_n();return ol(e)>2||ol(kr)>3?"":" "}function uA(e,t){for(;--t&&_n()&&!(kr<48||kr>102||kr>57&&kr<65||kr>70&&kr<97););return Cu(e,gs()+(t<6&&Ao()==32&&_n()==32))}function Hd(e){for(;_n();)switch(kr){case e:return An;case 34:case 39:e!==34&&e!==39&&Hd(kr);break;case 40:e===41&&Hd(e);break;case 92:_n();break}return An}function cA(e,t){for(;_n()&&e+kr!==57&&!(e+kr===84&&Ao()===47););return"/*"+Cu(t,An-1)+"*"+Ip(e===47?e:_n())}function dA(e){for(;!ol(Ao());)_n();return Cu(e,An)}function fA(e){return lA(vs("",null,null,null,[""],e=iA(e),0,[0],e))}function vs(e,t,r,n,o,a,i,l,s){for(var u=0,c=0,f=i,p=0,h=0,v=0,g=1,m=1,b=1,y=0,C="",D=o,w=a,k=n,E=C;m;)switch(v=y,y=_n()){case 40:if(v!=108&&Na(E,f-1)==58){rA(E+=hs(Oc(y),"&","&\f"),"&\f",$1(u?l[u-1]:0))!=-1&&(b=-1);break}case 34:case 39:case 91:E+=Oc(y);break;case 9:case 10:case 13:case 32:E+=sA(v);break;case 92:E+=uA(gs()-1,7);continue;case 47:switch(Ao()){case 42:case 47:ql(pA(cA(_n(),gs()),t,r,s),s),(ol(v||1)==5||ol(Ao()||1)==5)&&Xn(E)&&Va(E,-1,void 0)!==" "&&(E+=" ");break;default:E+="/"}break;case 123*g:l[u++]=Xn(E)*b;case 125*g:case 59:case 0:switch(y){case 0:case 125:m=0;case 59+c:b==-1&&(E=hs(E,/\f/g,"")),h>0&&(Xn(E)-f||g===0&&v===47)&&ql(h>32?Zg(E+";",n,r,f-1,s):Zg(hs(E," ","")+";",n,r,f-2,s),s);break;case 59:E+=";";default:if(ql(k=Yg(E,t,r,u,c,o,l,C,D=[],w=[],f,a),a),y===123)if(c===0)vs(E,t,k,k,D,a,f,l,w);else{switch(p){case 99:if(Na(E,3)===110)break;case 108:if(Na(E,2)===97)break;default:c=0;case 100:case 109:case 115:}c?vs(e,k,k,n&&ql(Yg(e,k,k,0,0,o,l,C,o,D=[],f,w),w),o,w,f,l,n?D:w):vs(E,k,k,k,[""],w,0,l,w)}}u=c=h=0,g=b=1,C=E="",f=i;break;case 58:f=1+Xn(E),h=v;default:if(g<1){if(y==123)--g;else if(y==125&&g++==0&&aA()==125)continue}switch(E+=Ip(y),y*g){case 38:b=c>0?1:(E+="\f",-1);break;case 44:l[u++]=(Xn(E)-1)*b,b=1;break;case 64:Ao()===45&&(E+=Oc(_n())),p=Ao(),c=f=Xn(C=E+=dA(gs())),y++;break;case 45:v===45&&Xn(E)==2&&(g=0)}}return a}function Yg(e,t,r,n,o,a,i,l,s,u,c,f){for(var p=o-1,h=o===0?a:[""],v=nA(h),g=0,m=0,b=0;g<n;++g)for(var y=0,C=Va(e,p+1,p=$1(m=i[g])),D=e;y<v;++y)(D=B1(m>0?h[y]+" "+C:hs(C,/&\f/g,h[y])))&&(s[b++]=D);return Rp(e,t,r,o===0?D1:l,s,u,c,f)}function pA(e,t,r,n){return Rp(e,t,r,k1,Ip(oA()),Va(e,2,-2),0,n)}function Zg(e,t,r,n,o){return Rp(e,t,r,S1,Va(e,0,n),Va(e,n+1,-1),n,o)}function Wd(e,t){for(var r="",n=0;n<e.length;n++)r+=t(e[n],n,e,t)||"";return r}function mA(e,t,r,n){switch(e.type){case tA:if(e.children.length)break;case JO:case QO:case S1:return e.return=e.return||e.value;case k1:return"";case eA:return e.return=e.value+"{"+Wd(e.children,n)+"}";case D1:if(!Xn(e.value=e.props.join(",")))return""}return Xn(r=Wd(e.children,n))?e.return=e.value+"{"+r+"}":""}var Jg="data-ant-cssinjs-cache-path",A1="_FILE_STYLE__",Zo,F1=!0;function hA(){if(!Zo&&(Zo={},Xr())){var e=document.createElement("div");e.className=Jg,e.style.position="fixed",e.style.visibility="hidden",e.style.top="-9999px",document.body.appendChild(e);var t=getComputedStyle(e).content||"";t=t.replace(/^"/,"").replace(/"$/,""),t.split(";").forEach(function(o){var a=o.split(":"),i=ce(a,2),l=i[0],s=i[1];Zo[l]=s});var r=document.querySelector("style[".concat(Jg,"]"));if(r){var n;F1=!1,(n=r.parentNode)===null||n===void 0||n.removeChild(r)}document.body.removeChild(e)}}function gA(e){return hA(),!!Zo[e]}function vA(e){var t=Zo[e],r=null;if(t&&Xr())if(F1)r=A1;else{var n=document.querySelector("style[".concat(zn,'="').concat(Zo[e],'"]'));n?r=n.innerHTML:delete Zo[e]}return[r,t]}var bA="_skip_check_",N1="_multi_value_";function bs(e){var t=Wd(fA(e),mA);return t.replace(/\{%%%\:[^;];}/g,";")}function yA(e){return at(e)==="object"&&e&&(bA in e||N1 in e)}function Qg(e,t,r){if(!t)return e;var n=".".concat(t),o=r==="low"?":where(".concat(n,")"):n,a=e.split(",").map(function(i){var l,s=i.trim().split(/\s+/),u=s[0]||"",c=((l=u.match(/^\w+/))===null||l===void 0?void 0:l[0])||"";return u="".concat(c).concat(o).concat(u.slice(c.length)),[u].concat(Ie(s.slice(1))).join(" ")});return a.join(",")}var CA=function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{root:!0,parentSelectors:[]},o=n.root,a=n.injectHash,i=n.parentSelectors,l=r.hashId,s=r.layer;r.path;var u=r.hashPriority,c=r.transformers,f=c===void 0?[]:c;r.linters;var p="",h={};function v(b){var y=b.getName(l);if(!h[y]){var C=e(b.style,r,{root:!1,parentSelectors:i}),D=ce(C,1),w=D[0];h[y]="@keyframes ".concat(b.getName(l)).concat(w)}}function g(b){var y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return b.forEach(function(C){Array.isArray(C)?g(C,y):C&&y.push(C)}),y}var m=g(Array.isArray(t)?t:[t]);return m.forEach(function(b){var y=typeof b=="string"&&!o?{}:b;if(typeof y=="string")p+="".concat(y,`
|
|
159
|
+
`);else if(y._keyframe)v(y);else{var C=f.reduce(function(D,w){var k;return(w==null||(k=w.visit)===null||k===void 0?void 0:k.call(w,D))||D},y);Object.keys(C).forEach(function(D){var w=C[D];if(at(w)==="object"&&w&&(D!=="animationName"||!w._keyframe)&&!yA(w)){var k=!1,E=D.trim(),x=!1;(o||a)&&l?E.startsWith("@")?k=!0:E==="&"?E=Qg("",l,u):E=Qg(D,l,u):o&&!l&&(E==="&"||E==="")&&(E="",x=!0);var O=e(w,r,{root:x,injectHash:k,parentSelectors:[].concat(Ie(i),[E])}),j=ce(O,2),$=j[0],P=j[1];h=L(L({},h),P),p+="".concat(E).concat($)}else{let S=function(I,N){var F=I.replace(/[A-Z]/g,function(_){return"-".concat(_.toLowerCase())}),M=N;!ZO[I]&&typeof M=="number"&&M!==0&&(M="".concat(M,"px")),I==="animationName"&&N!==null&&N!==void 0&&N._keyframe&&(v(N),M=N.getName(l)),p+="".concat(F,":").concat(M,";")};var A,B=(A=w==null?void 0:w.value)!==null&&A!==void 0?A:w;at(w)==="object"&&w!==null&&w!==void 0&&w[N1]&&Array.isArray(B)?B.forEach(function(I){S(D,I)}):S(D,B)}})}}),o?s&&(p&&(p="@layer ".concat(s.name," {").concat(p,"}")),s.dependencies&&(h["@layer ".concat(s.name)]=s.dependencies.map(function(b){return"@layer ".concat(b,", ").concat(s.name,";")}).join(`
|
|
160
|
+
`))):p="{".concat(p,"}"),[p,h]};function P1(e,t){return rl("".concat(e.join("%")).concat(t))}function xA(){return null}var j1="style";function Kd(e,t){var r=e.token,n=e.path,o=e.hashId,a=e.layer,i=e.nonce,l=e.clientOnly,s=e.order,u=s===void 0?0:s,c=d.useContext(Cl),f=c.autoClear;c.mock;var p=c.defaultCache,h=c.hashPriority,v=c.container,g=c.ssrInline,m=c.transformers,b=c.linters,y=c.cache,C=c.layer,D=r._tokenKey,w=[D];C&&w.push("layer"),w.push.apply(w,Ie(n));var k=Ld,E=jp(j1,w,function(){var P=w.join("|");if(gA(P)){var A=vA(P),B=ce(A,2),S=B[0],I=B[1];if(S)return[S,D,I,{},l,u]}var N=t(),F=CA(N,{hashId:o,hashPriority:h,layer:C?a:void 0,path:n.join("-"),transformers:m,linters:b}),M=ce(F,2),_=M[0],X=M[1],H=bs(_),q=P1(w,H);return[H,D,q,X,l,u]},function(P,A){var B=ce(P,3),S=B[2];(A||f)&&Ld&&nl(S,{mark:zn,attachTo:v})},function(P){var A=ce(P,4),B=A[0];A[1];var S=A[2],I=A[3];if(k&&B!==A1){var N={mark:zn,prepend:C?!1:"queue",attachTo:v,priority:u},F=typeof i=="function"?i():i;F&&(N.csp={nonce:F});var M=[],_=[];Object.keys(I).forEach(function(H){H.startsWith("@layer")?M.push(H):_.push(H)}),M.forEach(function(H){go(bs(I[H]),"_layer-".concat(H),L(L({},N),{},{prepend:!0}))});var X=go(B,S,N);X[Oo]=y.instanceId,X.setAttribute(qa,D),_.forEach(function(H){go(bs(I[H]),"_effect-".concat(H),N)})}}),x=ce(E,3),O=x[0],j=x[1],$=x[2];return function(P){var A;return!g||k||!p?A=d.createElement(xA,null):A=d.createElement("style",Me({},T(T({},qa,j),zn,$),{dangerouslySetInnerHTML:{__html:O}})),d.createElement(d.Fragment,null,A,P)}}var wA=function(e,t,r){var n=ce(e,6),o=n[0],a=n[1],i=n[2],l=n[3],s=n[4],u=n[5],c=r||{},f=c.plain;if(s)return null;var p=o,h={"data-rc-order":"prependQueue","data-rc-priority":"".concat(u)};return p=_s(o,a,i,h,f),l&&Object.keys(l).forEach(function(v){if(!t[v]){t[v]=!0;var g=bs(l[v]),m=_s(g,a,"_effect-".concat(v),h,f);v.startsWith("@layer")?p=m+p:p+=m}}),[u,i,p]},I1="cssVar",EA=function(e,t){var r=e.key,n=e.prefix,o=e.unitless,a=e.ignore,i=e.token,l=e.scope,s=l===void 0?"":l,u=Rr(Cl),c=u.cache.instanceId,f=u.container,p=i._tokenKey,h=[].concat(Ie(e.path),[r,s,p]),v=jp(I1,h,function(){var g=t(),m=w1(g,r,{prefix:n,unitless:o,ignore:a,scope:s}),b=ce(m,2),y=b[0],C=b[1],D=P1(h,C);return[y,C,D,r]},function(g){var m=ce(g,3),b=m[2];Ld&&nl(b,{mark:zn,attachTo:f})},function(g){var m=ce(g,3),b=m[1],y=m[2];if(b){var C=go(b,y,{mark:zn,prepend:"queue",attachTo:f,priority:-999});C[Oo]=c,C.setAttribute(qa,r)}});return v},kA=function(e,t,r){var n=ce(e,4),o=n[1],a=n[2],i=n[3],l=r||{},s=l.plain;if(!o)return null;var u=-999,c={"data-rc-order":"prependQueue","data-rc-priority":"".concat(u)},f=_s(o,i,a,c,s);return[u,a,f]};T(T(T({},j1,wA),E1,YO),I1,kA);var Vt=(function(){function e(t,r){vr(this,e),T(this,"name",void 0),T(this,"style",void 0),T(this,"_keyframe",!0),this.name=t,this.style=r}return br(e,[{key:"getName",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return t?"".concat(t,"-").concat(this.name):this.name}}]),e})();function ha(e){return e.notSplit=!0,e}ha(["borderTop","borderBottom"]),ha(["borderTop"]),ha(["borderBottom"]),ha(["borderLeft","borderRight"]),ha(["borderLeft"]),ha(["borderRight"]);var Mp=Fn({});function R1(e){return g1(e)||f1(e)||Ap(e)||v1()}function vn(e,t){for(var r=e,n=0;n<t.length;n+=1){if(r==null)return;r=r[t[n]]}return r}function M1(e,t,r,n){if(!t.length)return r;var o=R1(t),a=o[0],i=o.slice(1),l;return!e&&typeof a=="number"?l=[]:Array.isArray(e)?l=Ie(e):l=L({},e),n&&r===void 0&&i.length===1?delete l[a][i[0]]:l[a]=M1(l[a],i,r,n),l}function jn(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return t.length&&n&&r===void 0&&!vn(e,t.slice(0,-1))?e:M1(e,t,r,n)}function DA(e){return at(e)==="object"&&e!==null&&Object.getPrototypeOf(e)===Object.prototype}function ev(e){return Array.isArray(e)?[]:{}}var SA=typeof Reflect>"u"?Object.keys:Reflect.ownKeys;function $a(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=ev(t[0]);return t.forEach(function(o){function a(i,l){var s=new Set(l),u=vn(o,i),c=Array.isArray(u);if(c||DA(u)){if(!s.has(u)){s.add(u);var f=vn(n,i);c?n=jn(n,i,[]):(!f||at(f)!=="object")&&(n=jn(n,i,ev(u))),SA(u).forEach(function(p){a([].concat(Ie(i),[p]),s)})}}else n=jn(n,i,u)}a([])}),n}function $A(){}const BA=d.createContext({}),oi=()=>{const e=()=>{};return e.deprecated=$A,e},OA=Fn(void 0);var T1={items_per_page:"/ page",jump_to:"Go to",jump_to_confirm:"confirm",page:"Page",prev_page:"Previous Page",next_page:"Next Page",prev_5:"Previous 5 Pages",next_5:"Next 5 Pages",prev_3:"Previous 3 Pages",next_3:"Next 3 Pages",page_size:"Page Size"},AA={yearFormat:"YYYY",dayFormat:"D",cellMeridiemFormat:"A",monthBeforeYear:!0},FA=L(L({},AA),{},{locale:"en_US",today:"Today",now:"Now",backToToday:"Back to today",ok:"OK",clear:"Clear",week:"Week",month:"Month",year:"Year",timeSelect:"select time",dateSelect:"select date",weekSelect:"Choose a week",monthSelect:"Choose a month",yearSelect:"Choose a year",decadeSelect:"Choose a decade",dateFormat:"M/D/YYYY",dateTimeFormat:"M/D/YYYY HH:mm:ss",previousMonth:"Previous month (PageUp)",nextMonth:"Next month (PageDown)",previousYear:"Last year (Control + left)",nextYear:"Next year (Control + right)",previousDecade:"Last decade",nextDecade:"Next decade",previousCentury:"Last century",nextCentury:"Next century"});const z1={placeholder:"Select time",rangePlaceholder:["Start time","End time"]},tv={lang:Object.assign({placeholder:"Select date",yearPlaceholder:"Select year",quarterPlaceholder:"Select quarter",monthPlaceholder:"Select month",weekPlaceholder:"Select week",rangePlaceholder:["Start date","End date"],rangeYearPlaceholder:["Start year","End year"],rangeQuarterPlaceholder:["Start quarter","End quarter"],rangeMonthPlaceholder:["Start month","End month"],rangeWeekPlaceholder:["Start week","End week"]},FA),timePickerLocale:Object.assign({},z1)},mn="${label} is not a valid ${type}",ra={locale:"en",Pagination:T1,DatePicker:tv,TimePicker:z1,Calendar:tv,global:{placeholder:"Please select",close:"Close"},Table:{filterTitle:"Filter menu",filterConfirm:"OK",filterReset:"Reset",filterEmptyText:"No filters",filterCheckAll:"Select all items",filterSearchPlaceholder:"Search in filters",emptyText:"No data",selectAll:"Select current page",selectInvert:"Invert current page",selectNone:"Clear all data",selectionAll:"Select all data",sortTitle:"Sort",expand:"Expand row",collapse:"Collapse row",triggerDesc:"Click to sort descending",triggerAsc:"Click to sort ascending",cancelSort:"Click to cancel sorting"},Tour:{Next:"Next",Previous:"Previous",Finish:"Finish"},Modal:{okText:"OK",cancelText:"Cancel",justOkText:"OK"},Popconfirm:{okText:"OK",cancelText:"Cancel"},Transfer:{titles:["",""],searchPlaceholder:"Search here",itemUnit:"item",itemsUnit:"items",remove:"Remove",selectCurrent:"Select current page",removeCurrent:"Remove current page",selectAll:"Select all data",deselectAll:"Deselect all data",removeAll:"Remove all data",selectInvert:"Invert current page"},Upload:{uploading:"Uploading...",removeFile:"Remove file",uploadError:"Upload error",previewFile:"Preview file",downloadFile:"Download file"},Empty:{description:"No data"},Icon:{icon:"icon"},Text:{edit:"Edit",copy:"Copy",copied:"Copied",expand:"Expand",collapse:"Collapse"},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:mn,method:mn,array:mn,object:mn,number:mn,date:mn,boolean:mn,integer:mn,float:mn,regexp:mn,email:mn,url:mn,hex:mn},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}"}}},Image:{preview:"Preview"},QRCode:{expired:"QR code expired",refresh:"Refresh",scanned:"Scanned"},ColorPicker:{presetEmpty:"Empty",transparent:"Transparent",singleColor:"Single",gradientColor:"Gradient"}};Object.assign({},ra.Modal);let ys=[];const rv=()=>ys.reduce((e,t)=>Object.assign(Object.assign({},e),t),ra.Modal);function NA(e){if(e){const t=Object.assign({},e);return ys.push(t),rv(),()=>{ys=ys.filter(r=>r!==t),rv()}}Object.assign({},ra.Modal)}const Tp=Fn(void 0),xu=(e,t)=>{const r=d.useContext(Tp),n=d.useMemo(()=>{var a;const i=t||ra[e],l=(a=r==null?void 0:r[e])!==null&&a!==void 0?a:{};return Object.assign(Object.assign({},typeof i=="function"?i():i),l||{})},[e,t,r]),o=d.useMemo(()=>{const a=r==null?void 0:r.locale;return r!=null&&r.exist&&!a?ra.locale:a},[r]);return[n,o]},PA="internalMark",jA=e=>{const{locale:t={},children:r,_ANT_MARK__:n}=e;d.useEffect(()=>NA(t==null?void 0:t.Modal),[t]);const o=d.useMemo(()=>Object.assign(Object.assign({},t),{exist:!0}),[t]);return d.createElement(Tp.Provider,{value:o},r)},_1={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"},al=Object.assign(Object.assign({},_1),{colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorLink:"",colorTextBase:"",colorBgBase:"",fontFamily:`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
|
|
161
|
+
'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
|
|
162
|
+
'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}),Nr=Math.round;function Ac(e,t){const r=e.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],n=r.map(o=>parseFloat(o));for(let o=0;o<3;o+=1)n[o]=t(n[o]||0,r[o]||"",o);return r[3]?n[3]=r[3].includes("%")?n[3]/100:n[3]:n[3]=1,n}const nv=(e,t,r)=>r===0?e:e/100;function bi(e,t){const r=t||255;return e>r?r:e<0?0:e}class Ht{constructor(t){T(this,"isValid",!0),T(this,"r",0),T(this,"g",0),T(this,"b",0),T(this,"a",1),T(this,"_h",void 0),T(this,"_s",void 0),T(this,"_l",void 0),T(this,"_v",void 0),T(this,"_max",void 0),T(this,"_min",void 0),T(this,"_brightness",void 0);function r(n){return n[0]in t&&n[1]in t&&n[2]in t}if(t)if(typeof t=="string"){let n=function(a){return o.startsWith(a)};const o=t.trim();/^#?[A-F\d]{3,8}$/i.test(o)?this.fromHexString(o):n("rgb")?this.fromRgbString(o):n("hsl")?this.fromHslString(o):(n("hsv")||n("hsb"))&&this.fromHsvString(o)}else if(t instanceof Ht)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(r("rgb"))this.r=bi(t.r),this.g=bi(t.g),this.b=bi(t.b),this.a=typeof t.a=="number"?bi(t.a,1):1;else if(r("hsl"))this.fromHsl(t);else if(r("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 r=this.toHsv();return r.h=t,this._c(r)}getLuminance(){function t(a){const i=a/255;return i<=.03928?i/12.92:Math.pow((i+.055)/1.055,2.4)}const r=t(this.r),n=t(this.g),o=t(this.b);return .2126*r+.7152*n+.0722*o}getHue(){if(typeof this._h>"u"){const t=this.getMax()-this.getMin();t===0?this._h=0:this._h=Nr(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 r=this.getHue(),n=this.getSaturation();let o=this.getLightness()-t/100;return o<0&&(o=0),this._c({h:r,s:n,l:o,a:this.a})}lighten(t=10){const r=this.getHue(),n=this.getSaturation();let o=this.getLightness()+t/100;return o>1&&(o=1),this._c({h:r,s:n,l:o,a:this.a})}mix(t,r=50){const n=this._c(t),o=r/100,a=l=>(n[l]-this[l])*o+this[l],i={r:Nr(a("r")),g:Nr(a("g")),b:Nr(a("b")),a:Nr(a("a")*100)/100};return this._c(i)}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 r=this._c(t),n=this.a+r.a*(1-this.a),o=a=>Nr((this[a]*this.a+r[a]*r.a*(1-this.a))/n);return this._c({r:o("r"),g:o("g"),b:o("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 r=(this.r||0).toString(16);t+=r.length===2?r:"0"+r;const n=(this.g||0).toString(16);t+=n.length===2?n:"0"+n;const o=(this.b||0).toString(16);if(t+=o.length===2?o:"0"+o,typeof this.a=="number"&&this.a>=0&&this.a<1){const a=Nr(this.a*255).toString(16);t+=a.length===2?a:"0"+a}return t}toHsl(){return{h:this.getHue(),s:this.getSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const t=this.getHue(),r=Nr(this.getSaturation()*100),n=Nr(this.getLightness()*100);return this.a!==1?`hsla(${t},${r}%,${n}%,${this.a})`:`hsl(${t},${r}%,${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,r,n){const o=this.clone();return o[t]=bi(r,n),o}_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 r=t.replace("#","");function n(o,a){return parseInt(r[o]+r[a||o],16)}r.length<6?(this.r=n(0),this.g=n(1),this.b=n(2),this.a=r[3]?n(3)/255:1):(this.r=n(0,1),this.g=n(2,3),this.b=n(4,5),this.a=r[6]?n(6,7)/255:1)}fromHsl({h:t,s:r,l:n,a:o}){if(this._h=t%360,this._s=r,this._l=n,this.a=typeof o=="number"?o:1,r<=0){const p=Nr(n*255);this.r=p,this.g=p,this.b=p}let a=0,i=0,l=0;const s=t/60,u=(1-Math.abs(2*n-1))*r,c=u*(1-Math.abs(s%2-1));s>=0&&s<1?(a=u,i=c):s>=1&&s<2?(a=c,i=u):s>=2&&s<3?(i=u,l=c):s>=3&&s<4?(i=c,l=u):s>=4&&s<5?(a=c,l=u):s>=5&&s<6&&(a=u,l=c);const f=n-u/2;this.r=Nr((a+f)*255),this.g=Nr((i+f)*255),this.b=Nr((l+f)*255)}fromHsv({h:t,s:r,v:n,a:o}){this._h=t%360,this._s=r,this._v=n,this.a=typeof o=="number"?o:1;const a=Nr(n*255);if(this.r=a,this.g=a,this.b=a,r<=0)return;const i=t/60,l=Math.floor(i),s=i-l,u=Nr(n*(1-r)*255),c=Nr(n*(1-r*s)*255),f=Nr(n*(1-r*(1-s))*255);switch(l){case 0:this.g=f,this.b=u;break;case 1:this.r=c,this.b=u;break;case 2:this.r=u,this.b=f;break;case 3:this.r=u,this.g=c;break;case 4:this.r=f,this.g=u;break;case 5:default:this.g=u,this.b=c;break}}fromHsvString(t){const r=Ac(t,nv);this.fromHsv({h:r[0],s:r[1],v:r[2],a:r[3]})}fromHslString(t){const r=Ac(t,nv);this.fromHsl({h:r[0],s:r[1],l:r[2],a:r[3]})}fromRgbString(t){const r=Ac(t,(n,o)=>o.includes("%")?Nr(n/100*255):n);this.r=r[0],this.g=r[1],this.b=r[2],this.a=r[3]}}var Vl=2,ov=.16,IA=.05,RA=.05,MA=.15,L1=5,H1=4,TA=[{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 av(e,t,r){var n;return Math.round(e.h)>=60&&Math.round(e.h)<=240?n=r?Math.round(e.h)-Vl*t:Math.round(e.h)+Vl*t:n=r?Math.round(e.h)+Vl*t:Math.round(e.h)-Vl*t,n<0?n+=360:n>=360&&(n-=360),n}function iv(e,t,r){if(e.h===0&&e.s===0)return e.s;var n;return r?n=e.s-ov*t:t===H1?n=e.s+ov:n=e.s+IA*t,n>1&&(n=1),r&&t===L1&&n>.1&&(n=.1),n<.06&&(n=.06),Math.round(n*100)/100}function lv(e,t,r){var n;return r?n=e.v+RA*t:n=e.v-MA*t,n=Math.max(0,Math.min(1,n)),Math.round(n*100)/100}function il(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=[],n=new Ht(e),o=n.toHsv(),a=L1;a>0;a-=1){var i=new Ht({h:av(o,a,!0),s:iv(o,a,!0),v:lv(o,a,!0)});r.push(i)}r.push(n);for(var l=1;l<=H1;l+=1){var s=new Ht({h:av(o,l),s:iv(o,l),v:lv(o,l)});r.push(s)}return t.theme==="dark"?TA.map(function(u){var c=u.index,f=u.amount;return new Ht(t.backgroundColor||"#141414").mix(r[c],f).toHexString()}):r.map(function(u){return u.toHexString()})}var Fc={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"},qd=["#fff1f0","#ffccc7","#ffa39e","#ff7875","#ff4d4f","#f5222d","#cf1322","#a8071a","#820014","#5c0011"];qd.primary=qd[5];var Vd=["#fff2e8","#ffd8bf","#ffbb96","#ff9c6e","#ff7a45","#fa541c","#d4380d","#ad2102","#871400","#610b00"];Vd.primary=Vd[5];var Gd=["#fff7e6","#ffe7ba","#ffd591","#ffc069","#ffa940","#fa8c16","#d46b08","#ad4e00","#873800","#612500"];Gd.primary=Gd[5];var Xd=["#fffbe6","#fff1b8","#ffe58f","#ffd666","#ffc53d","#faad14","#d48806","#ad6800","#874d00","#613400"];Xd.primary=Xd[5];var Ud=["#feffe6","#ffffb8","#fffb8f","#fff566","#ffec3d","#fadb14","#d4b106","#ad8b00","#876800","#614700"];Ud.primary=Ud[5];var Yd=["#fcffe6","#f4ffb8","#eaff8f","#d3f261","#bae637","#a0d911","#7cb305","#5b8c00","#3f6600","#254000"];Yd.primary=Yd[5];var Zd=["#f6ffed","#d9f7be","#b7eb8f","#95de64","#73d13d","#52c41a","#389e0d","#237804","#135200","#092b00"];Zd.primary=Zd[5];var Jd=["#e6fffb","#b5f5ec","#87e8de","#5cdbd3","#36cfc9","#13c2c2","#08979c","#006d75","#00474f","#002329"];Jd.primary=Jd[5];var Ls=["#e6f4ff","#bae0ff","#91caff","#69b1ff","#4096ff","#1677ff","#0958d9","#003eb3","#002c8c","#001d66"];Ls.primary=Ls[5];var Qd=["#f0f5ff","#d6e4ff","#adc6ff","#85a5ff","#597ef7","#2f54eb","#1d39c4","#10239e","#061178","#030852"];Qd.primary=Qd[5];var ef=["#f9f0ff","#efdbff","#d3adf7","#b37feb","#9254de","#722ed1","#531dab","#391085","#22075e","#120338"];ef.primary=ef[5];var tf=["#fff0f6","#ffd6e7","#ffadd2","#ff85c0","#f759ab","#eb2f96","#c41d7f","#9e1068","#780650","#520339"];tf.primary=tf[5];var rf=["#a6a6a6","#999999","#8c8c8c","#808080","#737373","#666666","#404040","#1a1a1a","#000000","#000000"];rf.primary=rf[5];var Nc={red:qd,volcano:Vd,orange:Gd,gold:Xd,yellow:Ud,lime:Yd,green:Zd,cyan:Jd,blue:Ls,geekblue:Qd,purple:ef,magenta:tf,grey:rf};function zA(e,{generateColorPalettes:t,generateNeutralColorPalettes:r}){const{colorSuccess:n,colorWarning:o,colorError:a,colorInfo:i,colorPrimary:l,colorBgBase:s,colorTextBase:u}=e,c=t(l),f=t(n),p=t(o),h=t(a),v=t(i),g=r(s,u),m=e.colorLink||e.colorInfo,b=t(m),y=new Ht(h[1]).mix(new Ht(h[3]),50).toHexString();return Object.assign(Object.assign({},g),{colorPrimaryBg:c[1],colorPrimaryBgHover:c[2],colorPrimaryBorder:c[3],colorPrimaryBorderHover:c[4],colorPrimaryHover:c[5],colorPrimary:c[6],colorPrimaryActive:c[7],colorPrimaryTextHover:c[8],colorPrimaryText:c[9],colorPrimaryTextActive:c[10],colorSuccessBg:f[1],colorSuccessBgHover:f[2],colorSuccessBorder:f[3],colorSuccessBorderHover:f[4],colorSuccessHover:f[4],colorSuccess:f[6],colorSuccessActive:f[7],colorSuccessTextHover:f[8],colorSuccessText:f[9],colorSuccessTextActive:f[10],colorErrorBg:h[1],colorErrorBgHover:h[2],colorErrorBgFilledHover:y,colorErrorBgActive:h[3],colorErrorBorder:h[3],colorErrorBorderHover:h[4],colorErrorHover:h[5],colorError:h[6],colorErrorActive:h[7],colorErrorTextHover:h[8],colorErrorText:h[9],colorErrorTextActive:h[10],colorWarningBg:p[1],colorWarningBgHover:p[2],colorWarningBorder:p[3],colorWarningBorderHover:p[4],colorWarningHover:p[4],colorWarning:p[6],colorWarningActive:p[7],colorWarningTextHover:p[8],colorWarningText:p[9],colorWarningTextActive:p[10],colorInfoBg:v[1],colorInfoBgHover:v[2],colorInfoBorder:v[3],colorInfoBorderHover:v[4],colorInfoHover:v[4],colorInfo:v[6],colorInfoActive:v[7],colorInfoTextHover:v[8],colorInfoText:v[9],colorInfoTextActive:v[10],colorLinkHover:b[4],colorLink:b[6],colorLinkActive:b[7],colorBgMask:new Ht("#000").setA(.45).toRgbString(),colorWhite:"#fff"})}const _A=e=>{let t=e,r=e,n=e,o=e;return e<6&&e>=5?t=e+1:e<16&&e>=6?t=e+2:e>=16&&(t=16),e<7&&e>=5?r=4:e<8&&e>=7?r=5:e<14&&e>=8?r=6:e<16&&e>=14?r=7:e>=16&&(r=8),e<6&&e>=2?n=1:e>=6&&(n=2),e>4&&e<8?o=4:e>=8&&(o=6),{borderRadius:e,borderRadiusXS:n,borderRadiusSM:r,borderRadiusLG:t,borderRadiusOuter:o}};function LA(e){const{motionUnit:t,motionBase:r,borderRadius:n,lineWidth:o}=e;return Object.assign({motionDurationFast:`${(r+t).toFixed(1)}s`,motionDurationMid:`${(r+t*2).toFixed(1)}s`,motionDurationSlow:`${(r+t*3).toFixed(1)}s`,lineWidthBold:o+1},_A(n))}const HA=e=>{const{controlHeight:t}=e;return{controlHeightSM:t*.75,controlHeightXS:t*.5,controlHeightLG:t*1.25}};function Cs(e){return(e+8)/e}function WA(e){const t=Array.from({length:10}).map((r,n)=>{const o=n-1,a=e*Math.pow(Math.E,o/5),i=n>1?Math.floor(a):Math.ceil(a);return Math.floor(i/2)*2});return t[1]=e,t.map(r=>({size:r,lineHeight:Cs(r)}))}const KA=e=>{const t=WA(e),r=t.map(c=>c.size),n=t.map(c=>c.lineHeight),o=r[1],a=r[0],i=r[2],l=n[1],s=n[0],u=n[2];return{fontSizeSM:a,fontSize:o,fontSizeLG:i,fontSizeXL:r[3],fontSizeHeading1:r[6],fontSizeHeading2:r[5],fontSizeHeading3:r[4],fontSizeHeading4:r[3],fontSizeHeading5:r[2],lineHeight:l,lineHeightLG:u,lineHeightSM:s,fontHeight:Math.round(l*o),fontHeightLG:Math.round(u*i),fontHeightSM:Math.round(s*a),lineHeightHeading1:n[6],lineHeightHeading2:n[5],lineHeightHeading3:n[4],lineHeightHeading4:n[3],lineHeightHeading5:n[2]}};function qA(e){const{sizeUnit:t,sizeStep:r}=e;return{sizeXXL:t*(r+8),sizeXL:t*(r+4),sizeLG:t*(r+2),sizeMD:t*(r+1),sizeMS:t*r,size:t*r,sizeSM:t*(r-1),sizeXS:t*(r-2),sizeXXS:t*(r-3)}}const kn=(e,t)=>new Ht(e).setA(t).toRgbString(),yi=(e,t)=>new Ht(e).darken(t).toHexString(),VA=e=>{const t=il(e);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]}},GA=(e,t)=>{const r=e||"#fff",n=t||"#000";return{colorBgBase:r,colorTextBase:n,colorText:kn(n,.88),colorTextSecondary:kn(n,.65),colorTextTertiary:kn(n,.45),colorTextQuaternary:kn(n,.25),colorFill:kn(n,.15),colorFillSecondary:kn(n,.06),colorFillTertiary:kn(n,.04),colorFillQuaternary:kn(n,.02),colorBgSolid:kn(n,1),colorBgSolidHover:kn(n,.75),colorBgSolidActive:kn(n,.95),colorBgLayout:yi(r,4),colorBgContainer:yi(r,0),colorBgElevated:yi(r,0),colorBgSpotlight:kn(n,.85),colorBgBlur:"transparent",colorBorder:yi(r,15),colorBorderSecondary:yi(r,6)}};function XA(e){Fc.pink=Fc.magenta,Nc.pink=Nc.magenta;const t=Object.keys(_1).map(r=>{const n=e[r]===Fc[r]?Nc[r]:il(e[r]);return Array.from({length:10},()=>1).reduce((o,a,i)=>(o[`${r}-${i+1}`]=n[i],o[`${r}${i+1}`]=n[i],o),{})}).reduce((r,n)=>(r=Object.assign(Object.assign({},r),n),r),{});return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},e),t),zA(e,{generateColorPalettes:VA,generateNeutralColorPalettes:GA})),KA(e.fontSize)),qA(e)),HA(e)),LA(e))}const W1=_d(XA),nf={token:al,override:{override:al},hashed:!0},K1=ee.createContext(nf),ll="ant",zp="anticon",UA=["outlined","borderless","filled","underlined"],YA=(e,t)=>t||(e?`${ll}-${e}`:ll),Zt=d.createContext({getPrefixCls:YA,iconPrefixCls:zp}),{Consumer:iz}=Zt,sv={};function Ro(e){const t=d.useContext(Zt),{getPrefixCls:r,direction:n,getPopupContainer:o}=t,a=t[e];return Object.assign(Object.assign({classNames:sv,styles:sv},a),{getPrefixCls:r,direction:n,getPopupContainer:o})}const ZA=`-ant-${Date.now()}-${Math.random()}`;function JA(e,t){const r={},n=(a,i)=>{let l=a.clone();return l=(i==null?void 0:i(l))||l,l.toRgbString()},o=(a,i)=>{const l=new Ht(a),s=il(l.toRgbString());r[`${i}-color`]=n(l),r[`${i}-color-disabled`]=s[1],r[`${i}-color-hover`]=s[4],r[`${i}-color-active`]=s[6],r[`${i}-color-outline`]=l.clone().setA(.2).toRgbString(),r[`${i}-color-deprecated-bg`]=s[0],r[`${i}-color-deprecated-border`]=s[2]};if(t.primaryColor){o(t.primaryColor,"primary");const a=new Ht(t.primaryColor),i=il(a.toRgbString());i.forEach((s,u)=>{r[`primary-${u+1}`]=s}),r["primary-color-deprecated-l-35"]=n(a,s=>s.lighten(35)),r["primary-color-deprecated-l-20"]=n(a,s=>s.lighten(20)),r["primary-color-deprecated-t-20"]=n(a,s=>s.tint(20)),r["primary-color-deprecated-t-50"]=n(a,s=>s.tint(50)),r["primary-color-deprecated-f-12"]=n(a,s=>s.setA(s.a*.12));const l=new Ht(i[0]);r["primary-color-active-deprecated-f-30"]=n(l,s=>s.setA(s.a*.3)),r["primary-color-active-deprecated-d-02"]=n(l,s=>s.darken(2))}return t.successColor&&o(t.successColor,"success"),t.warningColor&&o(t.warningColor,"warning"),t.errorColor&&o(t.errorColor,"error"),t.infoColor&&o(t.infoColor,"info"),`
|
|
163
|
+
:root {
|
|
164
|
+
${Object.keys(r).map(a=>`--${e}-${a}: ${r[a]};`).join(`
|
|
165
|
+
`)}
|
|
166
|
+
}
|
|
167
|
+
`.trim()}function QA(e,t){const r=JA(e,t);Xr()&&go(r,`${ZA}-dynamic-theme`)}const No=d.createContext(!1),eF=({children:e,disabled:t})=>{const r=d.useContext(No);return d.createElement(No.Provider,{value:t??r},e)},Xa=d.createContext(void 0),tF=({children:e,size:t})=>{const r=d.useContext(Xa);return d.createElement(Xa.Provider,{value:t||r},e)};function rF(){const e=Rr(No),t=Rr(Xa);return{componentDisabled:e,componentSize:t}}var q1=br(function e(){vr(this,e)}),V1="CALC_UNIT",nF=new RegExp(V1,"g");function Pc(e){return typeof e=="number"?"".concat(e).concat(V1):e}var oF=(function(e){no(r,e);var t=oo(r);function r(n,o){var a;vr(this,r),a=t.call(this),T(et(a),"result",""),T(et(a),"unitlessCssVar",void 0),T(et(a),"lowPriority",void 0);var i=at(n);return a.unitlessCssVar=o,n instanceof r?a.result="(".concat(n.result,")"):i==="number"?a.result=Pc(n):i==="string"&&(a.result=n),a}return br(r,[{key:"add",value:function(n){return n instanceof r?this.result="".concat(this.result," + ").concat(n.getResult()):(typeof n=="number"||typeof n=="string")&&(this.result="".concat(this.result," + ").concat(Pc(n))),this.lowPriority=!0,this}},{key:"sub",value:function(n){return n instanceof r?this.result="".concat(this.result," - ").concat(n.getResult()):(typeof n=="number"||typeof n=="string")&&(this.result="".concat(this.result," - ").concat(Pc(n))),this.lowPriority=!0,this}},{key:"mul",value:function(n){return this.lowPriority&&(this.result="(".concat(this.result,")")),n instanceof r?this.result="".concat(this.result," * ").concat(n.getResult(!0)):(typeof n=="number"||typeof n=="string")&&(this.result="".concat(this.result," * ").concat(n)),this.lowPriority=!1,this}},{key:"div",value:function(n){return this.lowPriority&&(this.result="(".concat(this.result,")")),n instanceof r?this.result="".concat(this.result," / ").concat(n.getResult(!0)):(typeof n=="number"||typeof n=="string")&&(this.result="".concat(this.result," / ").concat(n)),this.lowPriority=!1,this}},{key:"getResult",value:function(n){return this.lowPriority||n?"(".concat(this.result,")"):this.result}},{key:"equal",value:function(n){var o=this,a=n||{},i=a.unit,l=!0;return typeof i=="boolean"?l=i:Array.from(this.unitlessCssVar).some(function(s){return o.result.includes(s)})&&(l=!1),this.result=this.result.replace(nF,l?"px":""),typeof this.lowPriority<"u"?"calc(".concat(this.result,")"):this.result}}]),r})(q1),aF=(function(e){no(r,e);var t=oo(r);function r(n){var o;return vr(this,r),o=t.call(this),T(et(o),"result",0),n instanceof r?o.result=n.result:typeof n=="number"&&(o.result=n),o}return br(r,[{key:"add",value:function(n){return n instanceof r?this.result+=n.result:typeof n=="number"&&(this.result+=n),this}},{key:"sub",value:function(n){return n instanceof r?this.result-=n.result:typeof n=="number"&&(this.result-=n),this}},{key:"mul",value:function(n){return n instanceof r?this.result*=n.result:typeof n=="number"&&(this.result*=n),this}},{key:"div",value:function(n){return n instanceof r?this.result/=n.result:typeof n=="number"&&(this.result/=n),this}},{key:"equal",value:function(){return this.result}}]),r})(q1),iF=function(e,t){var r=e==="css"?oF:aF;return function(n){return new r(n,t)}},uv=function(e,t){return"".concat([t,e.replace(/([A-Z]+)([A-Z][a-z]+)/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2")].filter(Boolean).join("-"))};function nr(e){var t=d.useRef();t.current=e;var r=d.useCallback(function(){for(var n,o=arguments.length,a=new Array(o),i=0;i<o;i++)a[i]=arguments[i];return(n=t.current)===null||n===void 0?void 0:n.call.apply(n,[t].concat(a))},[]);return r}function sl(e){var t=d.useRef(!1),r=d.useState(e),n=ce(r,2),o=n[0],a=n[1];d.useEffect(function(){return t.current=!1,function(){t.current=!0}},[]);function i(l,s){s&&t.current||a(l)}return[o,i]}function jc(e){return e!==void 0}function Gr(e,t){var r=t||{},n=r.defaultValue,o=r.value,a=r.onChange,i=r.postState,l=sl(function(){return jc(o)?o:jc(n)?typeof n=="function"?n():n:typeof e=="function"?e():e}),s=ce(l,2),u=s[0],c=s[1],f=o!==void 0?o:u,p=i?i(f):f,h=nr(a),v=sl([f]),g=ce(v,2),m=g[0],b=g[1];Xg(function(){var C=m[0];u!==C&&h(u,C)},[m]),Xg(function(){jc(o)||c(o)},[o]);var y=nr(function(C,D){c(C,D),b([f],D)});return[p,y]}function cv(e,t,r,n){var o=L({},t[e]);if(n!=null&&n.deprecatedTokens){var a=n.deprecatedTokens;a.forEach(function(l){var s=ce(l,2),u=s[0],c=s[1];if(o!=null&&o[u]||o!=null&&o[c]){var f;(f=o[c])!==null&&f!==void 0||(o[c]=o==null?void 0:o[u])}})}var i=L(L({},r),o);return Object.keys(i).forEach(function(l){i[l]===t[l]&&delete i[l]}),i}var G1=typeof CSSINJS_STATISTIC<"u",of=!0;function er(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];if(!G1)return Object.assign.apply(Object,[{}].concat(t));of=!1;var n={};return t.forEach(function(o){if(at(o)==="object"){var a=Object.keys(o);a.forEach(function(i){Object.defineProperty(n,i,{configurable:!0,enumerable:!0,get:function(){return o[i]}})})}}),of=!0,n}var dv={};function lF(){}var sF=function(e){var t,r=e,n=lF;return G1&&typeof Proxy<"u"&&(t=new Set,r=new Proxy(e,{get:function(o,a){if(of){var i;(i=t)===null||i===void 0||i.add(a)}return o[a]}}),n=function(o,a){var i;dv[o]={global:Array.from(t),component:L(L({},(i=dv[o])===null||i===void 0?void 0:i.component),a)}}),{token:r,keys:t,flush:n}};function fv(e,t,r){if(typeof r=="function"){var n;return r(er(t,(n=t[e])!==null&&n!==void 0?n:{}))}return r??{}}function uF(e){return e==="js"?{max:Math.max,min:Math.min}:{max:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return"max(".concat(r.map(function(o){return ue(o)}).join(","),")")},min:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return"min(".concat(r.map(function(o){return ue(o)}).join(","),")")}}}var cF=1e3*60*10,dF=(function(){function e(){vr(this,e),T(this,"map",new Map),T(this,"objectIDMap",new WeakMap),T(this,"nextID",0),T(this,"lastAccessBeat",new Map),T(this,"accessBeat",0)}return br(e,[{key:"set",value:function(t,r){this.clear();var n=this.getCompositeKey(t);this.map.set(n,r),this.lastAccessBeat.set(n,Date.now())}},{key:"get",value:function(t){var r=this.getCompositeKey(t),n=this.map.get(r);return this.lastAccessBeat.set(r,Date.now()),this.accessBeat+=1,n}},{key:"getCompositeKey",value:function(t){var r=this,n=t.map(function(o){return o&&at(o)==="object"?"obj_".concat(r.getObjectID(o)):"".concat(at(o),"_").concat(o)});return n.join("|")}},{key:"getObjectID",value:function(t){if(this.objectIDMap.has(t))return this.objectIDMap.get(t);var r=this.nextID;return this.objectIDMap.set(t,r),this.nextID+=1,r}},{key:"clear",value:function(){var t=this;if(this.accessBeat>1e4){var r=Date.now();this.lastAccessBeat.forEach(function(n,o){r-n>cF&&(t.map.delete(o),t.lastAccessBeat.delete(o))}),this.accessBeat=0}}}]),e})(),pv=new dF;function fF(e,t){return ee.useMemo(function(){var r=pv.get(t);if(r)return r;var n=e();return pv.set(t,n),n},t)}var pF=function(){return{}};function mF(e){var t=e.useCSP,r=t===void 0?pF:t,n=e.useToken,o=e.usePrefix,a=e.getResetStyles,i=e.getCommonStyle,l=e.getCompUnitless;function s(p,h,v,g){var m=Array.isArray(p)?p[0]:p;function b(x){return"".concat(String(m)).concat(x.slice(0,1).toUpperCase()).concat(x.slice(1))}var y=(g==null?void 0:g.unitless)||{},C=typeof l=="function"?l(p):{},D=L(L({},C),{},T({},b("zIndexPopup"),!0));Object.keys(y).forEach(function(x){D[b(x)]=y[x]});var w=L(L({},g),{},{unitless:D,prefixToken:b}),k=c(p,h,v,w),E=u(m,v,w);return function(x){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:x,j=k(x,O),$=ce(j,2),P=$[1],A=E(O),B=ce(A,2),S=B[0],I=B[1];return[S,P,I]}}function u(p,h,v){var g=v.unitless,m=v.injectStyle,b=m===void 0?!0:m,y=v.prefixToken,C=v.ignore,D=function(k){var E=k.rootCls,x=k.cssVar,O=x===void 0?{}:x,j=n(),$=j.realToken;return EA({path:[p],prefix:O.prefix,key:O.key,unitless:g,ignore:C,token:$,scope:E},function(){var P=fv(p,$,h),A=cv(p,$,P,{deprecatedTokens:v==null?void 0:v.deprecatedTokens});return Object.keys(P).forEach(function(B){A[y(B)]=A[B],delete A[B]}),A}),null},w=function(k){var E=n(),x=E.cssVar;return[function(O){return b&&x?ee.createElement(ee.Fragment,null,ee.createElement(D,{rootCls:k,cssVar:x,component:p}),O):O},x==null?void 0:x.key]};return w}function c(p,h,v){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},m=Array.isArray(p)?p:[p,p],b=ce(m,1),y=b[0],C=m.join("-"),D=e.layer||{name:"antd"};return function(w){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:w,E=n(),x=E.theme,O=E.realToken,j=E.hashId,$=E.token,P=E.cssVar,A=o(),B=A.rootPrefixCls,S=A.iconPrefixCls,I=r(),N=P?"css":"js",F=fF(function(){var Z=new Set;return P&&Object.keys(g.unitless||{}).forEach(function(te){Z.add(ms(te,P.prefix)),Z.add(ms(te,uv(y,P.prefix)))}),iF(N,Z)},[N,y,P==null?void 0:P.prefix]),M=uF(N),_=M.max,X=M.min,H={theme:x,token:$,hashId:j,nonce:function(){return I.nonce},clientOnly:g.clientOnly,layer:D,order:g.order||-999};typeof a=="function"&&Kd(L(L({},H),{},{clientOnly:!1,path:["Shared",B]}),function(){return a($,{prefix:{rootPrefixCls:B,iconPrefixCls:S},csp:I})});var q=Kd(L(L({},H),{},{path:[C,w,S]}),function(){if(g.injectStyle===!1)return[];var Z=sF($),te=Z.token,z=Z.flush,Y=fv(y,O,v),V=".".concat(w),U=cv(y,O,Y,{deprecatedTokens:g.deprecatedTokens});P&&Y&&at(Y)==="object"&&Object.keys(Y).forEach(function(G){Y[G]="var(".concat(ms(G,uv(y,P.prefix)),")")});var K=er(te,{componentCls:V,prefixCls:w,iconCls:".".concat(S),antCls:".".concat(B),calc:F,max:_,min:X},P?Y:U),W=h(K,{hashId:j,prefixCls:w,rootPrefixCls:B,iconPrefixCls:S});z(y,U);var re=typeof i=="function"?i(K,w,k,g.resetFont):null;return[g.resetStyle===!1?null:re,W]});return[q,j]}}function f(p,h,v){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},m=c(p,h,v,L({resetStyle:!1,order:-998},g)),b=function(y){var C=y.prefixCls,D=y.rootCls,w=D===void 0?C:D;return m(C,w),null};return b}return{genStyleHooks:s,genSubStyleComponent:f,genComponentStyleHook:c}}const na=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"],hF="5.27.1";function Ic(e){return e>=0&&e<=255}function $i(e,t){const{r,g:n,b:o,a}=new Ht(e).toRgb();if(a<1)return e;const{r:i,g:l,b:s}=new Ht(t).toRgb();for(let u=.01;u<=1;u+=.01){const c=Math.round((r-i*(1-u))/u),f=Math.round((n-l*(1-u))/u),p=Math.round((o-s*(1-u))/u);if(Ic(c)&&Ic(f)&&Ic(p))return new Ht({r:c,g:f,b:p,a:Math.round(u*100)/100}).toRgbString()}return new Ht({r,g:n,b:o,a:1}).toRgbString()}var gF=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};function X1(e){const{override:t}=e,r=gF(e,["override"]),n=Object.assign({},t);Object.keys(al).forEach(f=>{delete n[f]});const o=Object.assign(Object.assign({},r),n),a=480,i=576,l=768,s=992,u=1200,c=1600;return o.motion===!1&&(o.motionDurationFast="0s",o.motionDurationMid="0s",o.motionDurationSlow="0s"),Object.assign(Object.assign(Object.assign({},o),{colorFillContent:o.colorFillSecondary,colorFillContentHover:o.colorFill,colorFillAlter:o.colorFillQuaternary,colorBgContainerDisabled:o.colorFillTertiary,colorBorderBg:o.colorBgContainer,colorSplit:$i(o.colorBorderSecondary,o.colorBgContainer),colorTextPlaceholder:o.colorTextQuaternary,colorTextDisabled:o.colorTextQuaternary,colorTextHeading:o.colorText,colorTextLabel:o.colorTextSecondary,colorTextDescription:o.colorTextTertiary,colorTextLightSolid:o.colorWhite,colorHighlight:o.colorError,colorBgTextHover:o.colorFillSecondary,colorBgTextActive:o.colorFill,colorIcon:o.colorTextTertiary,colorIconHover:o.colorText,colorErrorOutline:$i(o.colorErrorBg,o.colorBgContainer),colorWarningOutline:$i(o.colorWarningBg,o.colorBgContainer),fontSizeIcon:o.fontSizeSM,lineWidthFocus:o.lineWidth*3,lineWidth:o.lineWidth,controlOutlineWidth:o.lineWidth*2,controlInteractiveSize:o.controlHeight/2,controlItemBgHover:o.colorFillTertiary,controlItemBgActive:o.colorPrimaryBg,controlItemBgActiveHover:o.colorPrimaryBgHover,controlItemBgActiveDisabled:o.colorFill,controlTmpOutline:o.colorFillQuaternary,controlOutline:$i(o.colorPrimaryBg,o.colorBgContainer),lineType:o.lineType,borderRadius:o.borderRadius,borderRadiusXS:o.borderRadiusXS,borderRadiusSM:o.borderRadiusSM,borderRadiusLG:o.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:o.sizeXXS,paddingXS:o.sizeXS,paddingSM:o.sizeSM,padding:o.size,paddingMD:o.sizeMD,paddingLG:o.sizeLG,paddingXL:o.sizeXL,paddingContentHorizontalLG:o.sizeLG,paddingContentVerticalLG:o.sizeMS,paddingContentHorizontal:o.sizeMS,paddingContentVertical:o.sizeSM,paddingContentHorizontalSM:o.size,paddingContentVerticalSM:o.sizeXS,marginXXS:o.sizeXXS,marginXS:o.sizeXS,marginSM:o.sizeSM,margin:o.size,marginMD:o.sizeMD,marginLG:o.sizeLG,marginXL:o.sizeXL,marginXXL:o.sizeXXL,boxShadow:`
|
|
168
|
+
0 6px 16px 0 rgba(0, 0, 0, 0.08),
|
|
169
|
+
0 3px 6px -4px rgba(0, 0, 0, 0.12),
|
|
170
|
+
0 9px 28px 8px rgba(0, 0, 0, 0.05)
|
|
171
|
+
`,boxShadowSecondary:`
|
|
172
|
+
0 6px 16px 0 rgba(0, 0, 0, 0.08),
|
|
173
|
+
0 3px 6px -4px rgba(0, 0, 0, 0.12),
|
|
174
|
+
0 9px 28px 8px rgba(0, 0, 0, 0.05)
|
|
175
|
+
`,boxShadowTertiary:`
|
|
176
|
+
0 1px 2px 0 rgba(0, 0, 0, 0.03),
|
|
177
|
+
0 1px 6px -1px rgba(0, 0, 0, 0.02),
|
|
178
|
+
0 2px 4px 0 rgba(0, 0, 0, 0.02)
|
|
179
|
+
`,screenXS:a,screenXSMin:a,screenXSMax:i-1,screenSM:i,screenSMMin:i,screenSMMax:l-1,screenMD:l,screenMDMin:l,screenMDMax:s-1,screenLG:s,screenLGMin:s,screenLGMax:u-1,screenXL:u,screenXLMin:u,screenXLMax:c-1,screenXXL:c,screenXXLMin:c,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:`
|
|
180
|
+
0 1px 2px -2px ${new Ht("rgba(0, 0, 0, 0.16)").toRgbString()},
|
|
181
|
+
0 3px 6px 0 ${new Ht("rgba(0, 0, 0, 0.12)").toRgbString()},
|
|
182
|
+
0 5px 12px 4px ${new Ht("rgba(0, 0, 0, 0.09)").toRgbString()}
|
|
183
|
+
`,boxShadowDrawerRight:`
|
|
184
|
+
-6px 0 16px 0 rgba(0, 0, 0, 0.08),
|
|
185
|
+
-3px 0 6px -4px rgba(0, 0, 0, 0.12),
|
|
186
|
+
-9px 0 28px 8px rgba(0, 0, 0, 0.05)
|
|
187
|
+
`,boxShadowDrawerLeft:`
|
|
188
|
+
6px 0 16px 0 rgba(0, 0, 0, 0.08),
|
|
189
|
+
3px 0 6px -4px rgba(0, 0, 0, 0.12),
|
|
190
|
+
9px 0 28px 8px rgba(0, 0, 0, 0.05)
|
|
191
|
+
`,boxShadowDrawerUp:`
|
|
192
|
+
0 6px 16px 0 rgba(0, 0, 0, 0.08),
|
|
193
|
+
0 3px 6px -4px rgba(0, 0, 0, 0.12),
|
|
194
|
+
0 9px 28px 8px rgba(0, 0, 0, 0.05)
|
|
195
|
+
`,boxShadowDrawerDown:`
|
|
196
|
+
0 -6px 16px 0 rgba(0, 0, 0, 0.08),
|
|
197
|
+
0 -3px 6px -4px rgba(0, 0, 0, 0.12),
|
|
198
|
+
0 -9px 28px 8px rgba(0, 0, 0, 0.05)
|
|
199
|
+
`,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 mv=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const U1={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},vF={motionBase:!0,motionUnit:!0},bF={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},Y1=(e,t,r)=>{const n=r.getDerivativeToken(e),{override:o}=t,a=mv(t,["override"]);let i=Object.assign(Object.assign({},n),{override:o});return i=X1(i),a&&Object.entries(a).forEach(([l,s])=>{const{theme:u}=s,c=mv(s,["theme"]);let f=c;u&&(f=Y1(Object.assign(Object.assign({},i),c),{override:c},u)),i[l]=f}),i};function Yr(){const{token:e,hashed:t,theme:r,override:n,cssVar:o}=ee.useContext(K1),a=`${hF}-${t||""}`,i=r||W1,[l,s,u]=UO(i,[al,e],{salt:a,override:n,getComputedToken:Y1,formatToken:X1,cssVar:o&&{prefix:o.prefix,key:o.key,unitless:U1,ignore:vF,preserve:bF}});return[i,u,t?s:"",l,o]}const ul={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},Br=(e,t=!1)=>({boxSizing:"border-box",margin:0,padding:0,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,listStyle:"none",fontFamily:t?"inherit":e.fontFamily}),xl=()=>({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"}}),Hs=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),yF=e=>({a:{color:e.colorLink,textDecoration:e.linkDecoration,backgroundColor:"transparent",outline:"none",cursor:"pointer",transition:`color ${e.motionDurationSlow}`,"-webkit-text-decoration-skip":"objects","&:hover":{color:e.colorLinkHover},"&:active":{color:e.colorLinkActive},"&:active, &:hover":{textDecoration:e.linkHoverDecoration,outline:0},"&:focus":{textDecoration:e.linkFocusDecoration,outline:0},"&[disabled]":{color:e.colorTextDisabled,cursor:"not-allowed"}}}),CF=(e,t,r,n)=>{const o=`[class^="${t}"], [class*=" ${t}"]`,a=r?`.${r}`:o,i={boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}};let l={};return n!==!1&&(l={fontFamily:e.fontFamily,fontSize:e.fontSize}),{[a]:Object.assign(Object.assign(Object.assign({},l),i),{[o]:i})}},Po=(e,t)=>({outline:`${ue(e.lineWidthFocus)} solid ${e.colorPrimaryBorder}`,outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),cl=(e,t)=>({"&:focus-visible":Po(e)}),Z1=e=>({[`.${e}`]:Object.assign(Object.assign({},xl()),{[`.${e} .${e}-icon`]:{display:"block"}})}),xF=e=>Object.assign(Object.assign({color:e.colorLink,textDecoration:e.linkDecoration,outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}`,border:0,padding:0,background:"none",userSelect:"none"},cl(e)),{"&:focus, &:hover":{color:e.colorLinkHover},"&:active":{color:e.colorLinkActive}}),{genStyleHooks:Hr,genComponentStyleHook:wF,genSubStyleComponent:J1}=mF({usePrefix:()=>{const{getPrefixCls:e,iconPrefixCls:t}=Rr(Zt);return{rootPrefixCls:e(),iconPrefixCls:t}},useToken:()=>{const[e,t,r,n,o]=Yr();return{theme:e,realToken:t,hashId:r,token:n,cssVar:o}},useCSP:()=>{const{csp:e}=Rr(Zt);return e??{}},getResetStyles:(e,t)=>{var r;const n=yF(e);return[n,{"&":n},Z1((r=t==null?void 0:t.prefix.iconPrefixCls)!==null&&r!==void 0?r:zp)]},getCommonStyle:CF,getCompUnitless:()=>U1});function EF(e,t){return na.reduce((r,n)=>{const o=e[`${n}1`],a=e[`${n}3`],i=e[`${n}6`],l=e[`${n}7`];return Object.assign(Object.assign({},r),t(n,{lightColor:o,lightBorderColor:a,darkColor:i,textColor:l}))},{})}const kF=(e,t)=>{const[r,n]=Yr();return Kd({token:n,hashId:"",path:["ant-design-icons",e],nonce:()=>t==null?void 0:t.nonce,layer:{name:"antd"}},()=>Z1(e))},DF=Object.assign({},d),{useId:hv}=DF,SF=()=>"",$F=typeof hv>"u"?SF:hv;function BF(e,t,r){var n;oi();const o=e||{},a=o.inherit===!1||!t?Object.assign(Object.assign({},nf),{hashed:(n=t==null?void 0:t.hashed)!==null&&n!==void 0?n:nf.hashed,cssVar:t==null?void 0:t.cssVar}):t,i=$F();return la(()=>{var l,s;if(!e)return t;const u=Object.assign({},a.components);Object.keys(e.components||{}).forEach(p=>{u[p]=Object.assign(Object.assign({},u[p]),e.components[p])});const c=`css-var-${i.replace(/:/g,"")}`,f=((l=o.cssVar)!==null&&l!==void 0?l:a.cssVar)&&Object.assign(Object.assign(Object.assign({prefix:r==null?void 0:r.prefixCls},typeof a.cssVar=="object"?a.cssVar:{}),typeof o.cssVar=="object"?o.cssVar:{}),{key:typeof o.cssVar=="object"&&((s=o.cssVar)===null||s===void 0?void 0:s.key)||c});return Object.assign(Object.assign(Object.assign({},a),o),{token:Object.assign(Object.assign({},a.token),o.token),components:u,cssVar:f})},[o,a],(l,s)=>l.some((u,c)=>{const f=s[c];return!Jn(u,f,!0)}))}var OF=["children"],Q1=d.createContext({});function AF(e){var t=e.children,r=bt(e,OF);return d.createElement(Q1.Provider,{value:r},t)}var FF=(function(e){no(r,e);var t=oo(r);function r(){return vr(this,r),t.apply(this,arguments)}return br(r,[{key:"render",value:function(){return this.props.children}}]),r})(d.Component);function NF(e){var t=d.useReducer(function(l){return l+1},0),r=ce(t,2),n=r[1],o=d.useRef(e),a=nr(function(){return o.current}),i=nr(function(l){o.current=typeof l=="function"?l(o.current):l,n()});return[a,i]}var Eo="none",Gl="appear",Xl="enter",Ul="leave",gv="none",In="prepare",Ba="start",Oa="active",_p="end",eC="prepared";function vv(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit".concat(e)]="webkit".concat(t),r["Moz".concat(e)]="moz".concat(t),r["ms".concat(e)]="MS".concat(t),r["O".concat(e)]="o".concat(t.toLowerCase()),r}function PF(e,t){var r={animationend:vv("Animation","AnimationEnd"),transitionend:vv("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete r.animationend.animation,"TransitionEvent"in t||delete r.transitionend.transition),r}var jF=PF(Xr(),typeof window<"u"?window:{}),tC={};if(Xr()){var IF=document.createElement("div");tC=IF.style}var Yl={};function rC(e){if(Yl[e])return Yl[e];var t=jF[e];if(t)for(var r=Object.keys(t),n=r.length,o=0;o<n;o+=1){var a=r[o];if(Object.prototype.hasOwnProperty.call(t,a)&&a in tC)return Yl[e]=t[a],Yl[e]}return""}var nC=rC("animationend"),oC=rC("transitionend"),aC=!!(nC&&oC),bv=nC||"animationend",yv=oC||"transitionend";function Cv(e,t){if(!e)return null;if(at(e)==="object"){var r=t.replace(/-\w/g,function(n){return n[1].toUpperCase()});return e[r]}return"".concat(e,"-").concat(t)}const RF=(function(e){var t=qe();function r(o){o&&(o.removeEventListener(yv,e),o.removeEventListener(bv,e))}function n(o){t.current&&t.current!==o&&r(t.current),o&&o!==t.current&&(o.addEventListener(yv,e),o.addEventListener(bv,e),t.current=o)}return d.useEffect(function(){return function(){r(t.current)}},[]),[n,r]});var iC=Xr()?Fb:Ot;const MF=(function(){var e=d.useRef(null);function t(){qt.cancel(e.current)}function r(n){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;t();var a=qt(function(){o<=1?n({isCanceled:function(){return a!==e.current}}):r(n,o-1)});e.current=a}return d.useEffect(function(){return function(){t()}},[]),[r,t]});var TF=[In,Ba,Oa,_p],zF=[In,eC],lC=!1,_F=!0;function sC(e){return e===Oa||e===_p}const LF=(function(e,t,r){var n=sl(gv),o=ce(n,2),a=o[0],i=o[1],l=MF(),s=ce(l,2),u=s[0],c=s[1];function f(){i(In,!0)}var p=t?zF:TF;return iC(function(){if(a!==gv&&a!==_p){var h=p.indexOf(a),v=p[h+1],g=r(a);g===lC?i(v,!0):v&&u(function(m){function b(){m.isCanceled()||i(v,!0)}g===!0?b():Promise.resolve(g).then(b)})}},[e,a]),d.useEffect(function(){return function(){c()}},[]),[f,a]});function HF(e,t,r,n){var o=n.motionEnter,a=o===void 0?!0:o,i=n.motionAppear,l=i===void 0?!0:i,s=n.motionLeave,u=s===void 0?!0:s,c=n.motionDeadline,f=n.motionLeaveImmediately,p=n.onAppearPrepare,h=n.onEnterPrepare,v=n.onLeavePrepare,g=n.onAppearStart,m=n.onEnterStart,b=n.onLeaveStart,y=n.onAppearActive,C=n.onEnterActive,D=n.onLeaveActive,w=n.onAppearEnd,k=n.onEnterEnd,E=n.onLeaveEnd,x=n.onVisibleChanged,O=sl(),j=ce(O,2),$=j[0],P=j[1],A=NF(Eo),B=ce(A,2),S=B[0],I=B[1],N=sl(null),F=ce(N,2),M=F[0],_=F[1],X=S(),H=qe(!1),q=qe(null);function Z(){return r()}var te=qe(!1);function z(){I(Eo),_(null,!0)}var Y=nr(function(ye){var ke=S();if(ke!==Eo){var we=Z();if(!(ye&&!ye.deadline&&ye.target!==we)){var De=te.current,Ne;ke===Gl&&De?Ne=w==null?void 0:w(we,ye):ke===Xl&&De?Ne=k==null?void 0:k(we,ye):ke===Ul&&De&&(Ne=E==null?void 0:E(we,ye)),De&&Ne!==!1&&z()}}}),V=RF(Y),U=ce(V,1),K=U[0],W=function(ye){switch(ye){case Gl:return T(T(T({},In,p),Ba,g),Oa,y);case Xl:return T(T(T({},In,h),Ba,m),Oa,C);case Ul:return T(T(T({},In,v),Ba,b),Oa,D);default:return{}}},re=d.useMemo(function(){return W(X)},[X]),G=LF(X,!e,function(ye){if(ye===In){var ke=re[In];return ke?ke(Z()):lC}if(se in re){var we;_(((we=re[se])===null||we===void 0?void 0:we.call(re,Z(),null))||null)}return se===Oa&&X!==Eo&&(K(Z()),c>0&&(clearTimeout(q.current),q.current=setTimeout(function(){Y({deadline:!0})},c))),se===eC&&z(),_F}),J=ce(G,2),oe=J[0],se=J[1],ge=sC(se);te.current=ge;var Ee=qe(null);iC(function(){if(!(H.current&&Ee.current===t)){P(t);var ye=H.current;H.current=!0;var ke;!ye&&t&&l&&(ke=Gl),ye&&t&&a&&(ke=Xl),(ye&&!t&&u||!ye&&f&&!t&&u)&&(ke=Ul);var we=W(ke);ke&&(e||we[In])?(I(ke),oe()):I(Eo),Ee.current=t}},[t]),Ot(function(){(X===Gl&&!l||X===Xl&&!a||X===Ul&&!u)&&I(Eo)},[l,a,u]),Ot(function(){return function(){H.current=!1,clearTimeout(q.current)}},[]);var je=d.useRef(!1);Ot(function(){$&&(je.current=!0),$!==void 0&&X===Eo&&((je.current||$)&&(x==null||x($)),je.current=!0)},[$,X]);var ve=M;return re[In]&&se===Ba&&(ve=L({transition:"none"},ve)),[X,se,ve,$??t]}function WF(e){var t=e;at(e)==="object"&&(t=e.transitionSupport);function r(o,a){return!!(o.motionName&&t&&a!==!1)}var n=d.forwardRef(function(o,a){var i=o.visible,l=i===void 0?!0:i,s=o.removeOnLeave,u=s===void 0?!0:s,c=o.forceRender,f=o.children,p=o.motionName,h=o.leavedClassName,v=o.eventProps,g=d.useContext(Q1),m=g.motion,b=r(o,m),y=qe(),C=qe();function D(){try{return y.current instanceof HTMLElement?y.current:ps(C.current)}catch{return null}}var w=HF(b,l,D,o),k=ce(w,4),E=k[0],x=k[1],O=k[2],j=k[3],$=d.useRef(j);j&&($.current=!0);var P=d.useCallback(function(F){y.current=F,Qi(a,F)},[a]),A,B=L(L({},v),{},{visible:l});if(!f)A=null;else if(E===Eo)j?A=f(L({},B),P):!u&&$.current&&h?A=f(L(L({},B),{},{className:h}),P):c||!u&&!h?A=f(L(L({},B),{},{style:{display:"none"}}),P):A=null;else{var S;x===In?S="prepare":sC(x)?S="active":x===Ba&&(S="start");var I=Cv(p,"".concat(E,"-").concat(S));A=f(L(L({},B),{},{className:pe(Cv(p,E),T(T({},I,I&&S),p,typeof p=="string")),style:O}),P)}if(d.isValidElement(A)&&Zn(A)){var N=ua(A);N||(A=d.cloneElement(A,{ref:P}))}return d.createElement(FF,{ref:C},A)});return n.displayName="CSSMotion",n}const ca=WF(aC);var af="add",lf="keep",sf="remove",Rc="removed";function KF(e){var t;return e&&at(e)==="object"&&"key"in e?t=e:t={key:e},L(L({},t),{},{key:String(t.key)})}function uf(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(KF)}function qF(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=[],n=0,o=t.length,a=uf(e),i=uf(t);a.forEach(function(u){for(var c=!1,f=n;f<o;f+=1){var p=i[f];if(p.key===u.key){n<f&&(r=r.concat(i.slice(n,f).map(function(h){return L(L({},h),{},{status:af})})),n=f),r.push(L(L({},p),{},{status:lf})),n+=1,c=!0;break}}c||r.push(L(L({},u),{},{status:sf}))}),n<o&&(r=r.concat(i.slice(n).map(function(u){return L(L({},u),{},{status:af})})));var l={};r.forEach(function(u){var c=u.key;l[c]=(l[c]||0)+1});var s=Object.keys(l).filter(function(u){return l[u]>1});return s.forEach(function(u){r=r.filter(function(c){var f=c.key,p=c.status;return f!==u||p!==sf}),r.forEach(function(c){c.key===u&&(c.status=lf)})}),r}var VF=["component","children","onVisibleChanged","onAllRemoved"],GF=["status"],XF=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function UF(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ca,r=(function(n){no(a,n);var o=oo(a);function a(){var i;vr(this,a);for(var l=arguments.length,s=new Array(l),u=0;u<l;u++)s[u]=arguments[u];return i=o.call.apply(o,[this].concat(s)),T(et(i),"state",{keyEntities:[]}),T(et(i),"removeKey",function(c){i.setState(function(f){var p=f.keyEntities.map(function(h){return h.key!==c?h:L(L({},h),{},{status:Rc})});return{keyEntities:p}},function(){var f=i.state.keyEntities,p=f.filter(function(h){var v=h.status;return v!==Rc}).length;p===0&&i.props.onAllRemoved&&i.props.onAllRemoved()})}),i}return br(a,[{key:"render",value:function(){var i=this,l=this.state.keyEntities,s=this.props,u=s.component,c=s.children,f=s.onVisibleChanged;s.onAllRemoved;var p=bt(s,VF),h=u||d.Fragment,v={};return XF.forEach(function(g){v[g]=p[g],delete p[g]}),delete p.keys,d.createElement(h,p,l.map(function(g,m){var b=g.status,y=bt(g,GF),C=b===af||b===lf;return d.createElement(t,Me({},v,{key:y.key,visible:C,eventProps:y,onVisibleChanged:function(D){f==null||f(D,{key:y.key}),D||i.removeKey(y.key)}}),function(D,w){return c(L(L({},D),{},{index:m}),w)})}))}}],[{key:"getDerivedStateFromProps",value:function(i,l){var s=i.keys,u=l.keyEntities,c=uf(s),f=qF(u,c);return{keyEntities:f.filter(function(p){var h=u.find(function(v){var g=v.key;return p.key===g});return!(h&&h.status===Rc&&p.status===sf)})}}}]),a})(d.Component);return T(r,"defaultProps",{component:"div"}),r}UF(aC);const xv=d.createContext(!0);function YF(e){const t=d.useContext(xv),{children:r}=e,[,n]=Yr(),{motion:o}=n,a=d.useRef(!1);return a.current||(a.current=t!==o),a.current?d.createElement(xv.Provider,{value:o},d.createElement(AF,{motion:o},r)):r}const ZF=()=>null;var JF=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const QF=["getTargetContainer","getPopupContainer","renderEmpty","input","pagination","form","select","button"];let uC;function e3(){return uC||ll}function t3(e){return Object.keys(e).some(t=>t.endsWith("Color"))}const r3=e=>{const{prefixCls:t,iconPrefixCls:r,theme:n,holderRender:o}=e;t!==void 0&&(uC=t),n&&t3(n)&&QA(e3(),n)},n3=e=>{const{children:t,csp:r,autoInsertSpaceInButton:n,alert:o,anchor:a,form:i,locale:l,componentSize:s,direction:u,space:c,splitter:f,virtual:p,dropdownMatchSelectWidth:h,popupMatchSelectWidth:v,popupOverflow:g,legacyLocale:m,parentContext:b,iconPrefixCls:y,theme:C,componentDisabled:D,segmented:w,statistic:k,spin:E,calendar:x,carousel:O,cascader:j,collapse:$,typography:P,checkbox:A,descriptions:B,divider:S,drawer:I,skeleton:N,steps:F,image:M,layout:_,list:X,mentions:H,modal:q,progress:Z,result:te,slider:z,breadcrumb:Y,menu:V,pagination:U,input:K,textArea:W,empty:re,badge:G,radio:J,rate:oe,switch:se,transfer:ge,avatar:Ee,message:je,tag:ve,table:ye,card:ke,tabs:we,timeline:De,timePicker:Ne,upload:Oe,notification:Xe,tree:Le,colorPicker:Fe,datePicker:fe,rangePicker:Be,flex:We,wave:Ye,dropdown:Ve,warning:Te,tour:it,tooltip:Ue,popover:nt,popconfirm:pt,floatButton:St,floatButtonGroup:dt,variant:ht,inputNumber:Pt,treeSelect:At}=e,ct=d.useCallback((ze,_e)=>{const{prefixCls:Ke}=e;if(_e)return _e;const Pe=Ke||b.getPrefixCls("");return ze?`${Pe}-${ze}`:Pe},[b.getPrefixCls,e.prefixCls]),ut=y||b.iconPrefixCls||zp,ae=r||b.csp;kF(ut,ae);const he=BF(C,b.theme,{prefixCls:ct("")}),xe={csp:ae,autoInsertSpaceInButton:n,alert:o,anchor:a,locale:l||m,direction:u,space:c,splitter:f,virtual:p,popupMatchSelectWidth:v??h,popupOverflow:g,getPrefixCls:ct,iconPrefixCls:ut,theme:he,segmented:w,statistic:k,spin:E,calendar:x,carousel:O,cascader:j,collapse:$,typography:P,checkbox:A,descriptions:B,divider:S,drawer:I,skeleton:N,steps:F,image:M,input:K,textArea:W,layout:_,list:X,mentions:H,modal:q,progress:Z,result:te,slider:z,breadcrumb:Y,menu:V,pagination:U,empty:re,badge:G,radio:J,rate:oe,switch:se,transfer:ge,avatar:Ee,message:je,tag:ve,table:ye,card:ke,tabs:we,timeline:De,timePicker:Ne,upload:Oe,notification:Xe,tree:Le,colorPicker:Fe,datePicker:fe,rangePicker:Be,flex:We,wave:Ye,dropdown:Ve,warning:Te,tour:it,tooltip:Ue,popover:nt,popconfirm:pt,floatButton:St,floatButtonGroup:dt,variant:ht,inputNumber:Pt,treeSelect:At},be=Object.assign({},b);Object.keys(xe).forEach(ze=>{xe[ze]!==void 0&&(be[ze]=xe[ze])}),QF.forEach(ze=>{const _e=e[ze];_e&&(be[ze]=_e)}),typeof n<"u"&&(be.button=Object.assign({autoInsertSpace:n},be.button));const Ce=la(()=>be,be,(ze,_e)=>{const Ke=Object.keys(ze),Pe=Object.keys(_e);return Ke.length!==Pe.length||Ke.some(Ze=>ze[Ze]!==_e[Ze])}),{layer:de}=d.useContext(Cl),Se=d.useMemo(()=>({prefixCls:ut,csp:ae,layer:de?"antd":void 0}),[ut,ae,de]);let le=d.createElement(d.Fragment,null,d.createElement(ZF,{dropdownMatchSelectWidth:h}),t);const ie=d.useMemo(()=>{var ze,_e,Ke,Pe;return $a(((ze=ra.Form)===null||ze===void 0?void 0:ze.defaultValidateMessages)||{},((Ke=(_e=Ce.locale)===null||_e===void 0?void 0:_e.Form)===null||Ke===void 0?void 0:Ke.defaultValidateMessages)||{},((Pe=Ce.form)===null||Pe===void 0?void 0:Pe.validateMessages)||{},(i==null?void 0:i.validateMessages)||{})},[Ce,i==null?void 0:i.validateMessages]);Object.keys(ie).length>0&&(le=d.createElement(OA.Provider,{value:ie},le)),l&&(le=d.createElement(jA,{locale:l,_ANT_MARK__:PA},le)),le=d.createElement(Mp.Provider,{value:Se},le),s&&(le=d.createElement(tF,{size:s},le)),le=d.createElement(YF,null,le);const me=d.useMemo(()=>{const ze=he||{},{algorithm:_e,token:Ke,components:Pe,cssVar:Ze}=ze,wt=JF(ze,["algorithm","token","components","cssVar"]),jt=_e&&(!Array.isArray(_e)||_e.length>0)?_d(_e):W1,It={};Object.entries(Pe||{}).forEach(([Jt,pr])=>{const He=Object.assign({},pr);"algorithm"in He&&(He.algorithm===!0?He.theme=jt:(Array.isArray(He.algorithm)||typeof He.algorithm=="function")&&(He.theme=_d(He.algorithm)),delete He.algorithm),It[Jt]=He});const Et=Object.assign(Object.assign({},al),Ke);return Object.assign(Object.assign({},wt),{theme:jt,token:Et,components:It,override:Object.assign({override:Et},It),cssVar:Ze})},[he]);return C&&(le=d.createElement(K1.Provider,{value:me},le)),Ce.warning&&(le=d.createElement(BA.Provider,{value:Ce.warning},le)),D!==void 0&&(le=d.createElement(eF,{disabled:D},le)),d.createElement(Zt.Provider,{value:Ce},le)},ai=e=>{const t=d.useContext(Zt),r=d.useContext(Tp);return d.createElement(n3,Object.assign({parentContext:t,legacyLocale:r},e))};ai.ConfigContext=Zt;ai.SizeContext=Xa;ai.config=r3;ai.useConfig=rF;Object.defineProperty(ai,"SizeContext",{get:()=>Xa});function cC(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}function o3(e){return cC(e)instanceof ShadowRoot}function Ws(e){return o3(e)?cC(e):null}function a3(e){return e.replace(/-(.)/g,function(t,r){return r.toUpperCase()})}function i3(e,t){lr(e,"[@ant-design/icons] ".concat(t))}function wv(e){return at(e)==="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(at(e.icon)==="object"||typeof e.icon=="function")}function Ev(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(e).reduce(function(t,r){var n=e[r];switch(r){case"class":t.className=n,delete t.class;break;default:delete t[r],t[a3(r)]=n}return t},{})}function cf(e,t,r){return r?ee.createElement(e.tag,L(L({key:t},Ev(e.attrs)),r),(e.children||[]).map(function(n,o){return cf(n,"".concat(t,"-").concat(e.tag,"-").concat(o))})):ee.createElement(e.tag,L({key:t},Ev(e.attrs)),(e.children||[]).map(function(n,o){return cf(n,"".concat(t,"-").concat(e.tag,"-").concat(o))}))}function dC(e){return il(e)[0]}function fC(e){return e?Array.isArray(e)?e:[e]:[]}var l3=`
|
|
200
|
+
.anticon {
|
|
201
|
+
display: inline-flex;
|
|
202
|
+
align-items: center;
|
|
203
|
+
color: inherit;
|
|
204
|
+
font-style: normal;
|
|
205
|
+
line-height: 0;
|
|
206
|
+
text-align: center;
|
|
207
|
+
text-transform: none;
|
|
208
|
+
vertical-align: -0.125em;
|
|
209
|
+
text-rendering: optimizeLegibility;
|
|
210
|
+
-webkit-font-smoothing: antialiased;
|
|
211
|
+
-moz-osx-font-smoothing: grayscale;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
.anticon > * {
|
|
215
|
+
line-height: 1;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.anticon svg {
|
|
219
|
+
display: inline-block;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
.anticon::before {
|
|
223
|
+
display: none;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.anticon .anticon-icon {
|
|
227
|
+
display: block;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.anticon[tabindex] {
|
|
231
|
+
cursor: pointer;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.anticon-spin::before,
|
|
235
|
+
.anticon-spin {
|
|
236
|
+
display: inline-block;
|
|
237
|
+
-webkit-animation: loadingCircle 1s infinite linear;
|
|
238
|
+
animation: loadingCircle 1s infinite linear;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
@-webkit-keyframes loadingCircle {
|
|
242
|
+
100% {
|
|
243
|
+
-webkit-transform: rotate(360deg);
|
|
244
|
+
transform: rotate(360deg);
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
@keyframes loadingCircle {
|
|
249
|
+
100% {
|
|
250
|
+
-webkit-transform: rotate(360deg);
|
|
251
|
+
transform: rotate(360deg);
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
`,s3=function(e){var t=Rr(Mp),r=t.csp,n=t.prefixCls,o=t.layer,a=l3;n&&(a=a.replace(/anticon/g,n)),o&&(a="@layer ".concat(o,` {
|
|
255
|
+
`).concat(a,`
|
|
256
|
+
}`)),Ot(function(){var i=e.current,l=Ws(i);go(a,"@ant-design-icons",{prepend:!o,csp:r,attachTo:l})},[])},u3=["icon","className","onClick","style","primaryColor","secondaryColor"],Ti={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function c3(e){var t=e.primaryColor,r=e.secondaryColor;Ti.primaryColor=t,Ti.secondaryColor=r||dC(t),Ti.calculated=!!r}function d3(){return L({},Ti)}var ii=function(e){var t=e.icon,r=e.className,n=e.onClick,o=e.style,a=e.primaryColor,i=e.secondaryColor,l=bt(e,u3),s=d.useRef(),u=Ti;if(a&&(u={primaryColor:a,secondaryColor:i||dC(a)}),s3(s),i3(wv(t),"icon should be icon definiton, but got ".concat(t)),!wv(t))return null;var c=t;return c&&typeof c.icon=="function"&&(c=L(L({},c),{},{icon:c.icon(u.primaryColor,u.secondaryColor)})),cf(c.icon,"svg-".concat(c.name),L(L({className:r,onClick:n,style:o,"data-icon":c.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},l),{},{ref:s}))};ii.displayName="IconReact";ii.getTwoToneColors=d3;ii.setTwoToneColors=c3;function pC(e){var t=fC(e),r=ce(t,2),n=r[0],o=r[1];return ii.setTwoToneColors({primaryColor:n,secondaryColor:o})}function f3(){var e=ii.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor}var p3=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];pC(Ls.primary);var sr=d.forwardRef(function(e,t){var r=e.className,n=e.icon,o=e.spin,a=e.rotate,i=e.tabIndex,l=e.onClick,s=e.twoToneColor,u=bt(e,p3),c=d.useContext(Mp),f=c.prefixCls,p=f===void 0?"anticon":f,h=c.rootClassName,v=pe(h,p,T(T({},"".concat(p,"-").concat(n.name),!!n.name),"".concat(p,"-spin"),!!o||n.name==="loading"),r),g=i;g===void 0&&l&&(g=-1);var m=a?{msTransform:"rotate(".concat(a,"deg)"),transform:"rotate(".concat(a,"deg)")}:void 0,b=fC(s),y=ce(b,2),C=y[0],D=y[1];return d.createElement("span",Me({role:"img","aria-label":n.name},u,{ref:t,tabIndex:g,onClick:l,className:v}),d.createElement(ii,{icon:n,primaryColor:C,secondaryColor:D,style:m}))});sr.displayName="AntdIcon";sr.getTwoToneColor=f3;sr.setTwoToneColor=pC;var m3={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"},h3=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:m3}))},mC=d.forwardRef(h3),g3={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"},v3=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:g3}))},b3=d.forwardRef(v3),y3=`accept acceptCharset accessKey action allowFullScreen allowTransparency
|
|
257
|
+
alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
|
|
258
|
+
charSet checked classID className colSpan cols content contentEditable contextMenu
|
|
259
|
+
controls coords crossOrigin data dateTime default defer dir disabled download draggable
|
|
260
|
+
encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
|
|
261
|
+
headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
|
|
262
|
+
is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
|
|
263
|
+
mediaGroup method min minLength multiple muted name noValidate nonce open
|
|
264
|
+
optimum pattern placeholder poster preload radioGroup readOnly rel required
|
|
265
|
+
reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
|
|
266
|
+
shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
|
|
267
|
+
summary tabIndex target title type useMap value width wmode wrap`,C3=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
|
|
268
|
+
onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
|
|
269
|
+
onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
|
|
270
|
+
onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
|
|
271
|
+
onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
|
|
272
|
+
onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
|
|
273
|
+
onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,x3="".concat(y3," ").concat(C3).split(/[\s\n]+/),w3="aria-",E3="data-";function kv(e,t){return e.indexOf(t)===0}function Qn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r;t===!1?r={aria:!0,data:!0,attr:!0}:t===!0?r={aria:!0}:r=L({},t);var n={};return Object.keys(e).forEach(function(o){(r.aria&&(o==="role"||kv(o,w3))||r.data&&kv(o,E3)||r.attr&&x3.includes(o))&&(n[o]=e[o])}),n}function hC(e){return e&&ee.isValidElement(e)&&e.type===ee.Fragment}const k3=(e,t,r)=>ee.isValidElement(e)?ee.cloneElement(e,typeof r=="function"?r(e.props||{}):r):t;function eo(e,t){return k3(e,e,t)}function df(e){return e!=null&&e===e.window}const D3=e=>{var t,r;if(typeof window>"u")return 0;let n=0;return df(e)?n=e.pageYOffset:e instanceof Document?n=e.documentElement.scrollTop:(e instanceof HTMLElement||e)&&(n=e.scrollTop),e&&!df(e)&&typeof n!="number"&&(n=(r=((t=e.ownerDocument)!==null&&t!==void 0?t:e).documentElement)===null||r===void 0?void 0:r.scrollTop),n};function S3(e,t,r,n){const o=r-t;return e/=n/2,e<1?o/2*e*e*e+t:o/2*((e-=2)*e*e+2)+t}function $3(e,t={}){const{getContainer:r=()=>window,callback:n,duration:o=450}=t,a=r(),i=D3(a),l=Date.now(),s=()=>{const u=Date.now()-l,c=S3(u>o?o:u,i,e,o);df(a)?a.scrollTo(window.pageXOffset,c):a instanceof Document||a.constructor.name==="HTMLDocument"?a.documentElement.scrollTop=c:a.scrollTop=c,u<o?qt(s):typeof n=="function"&&n()};qt(s)}const bo=e=>{const[,,,,t]=Yr();return t?`${e}-css-var`:""};var rt={BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,CAPS_LOCK:20,ESC:27,SPACE:32,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,N:78,P:80,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,SEMICOLON:186,EQUALS:187,WIN_KEY:224},B3={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"},O3=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:B3}))},Lp=d.forwardRef(O3);const Hp=ee.createContext(void 0),Mo=100,gC={Modal:Mo,Drawer:Mo,Popover:Mo,Popconfirm:Mo,Tooltip:Mo,Tour:Mo,FloatButton:Mo},A3={SelectLike:50,Dropdown:50,DatePicker:50,Menu:50,ImagePreview:1};function F3(e){return e in gC}const wu=(e,t)=>{const[,r]=Yr(),n=ee.useContext(Hp),o=F3(e);let a;if(t!==void 0)a=[t,t];else{let i=n??0;o?i+=(n?0:r.zIndexPopupBase)+gC[e]:i+=A3[e],a=[n===void 0?t:i,i]}return a};function vC(e,t){this.v=e,this.k=t}function Kr(e,t,r,n){var o=Object.defineProperty;try{o({},"",{})}catch{o=0}Kr=function(a,i,l,s){function u(c,f){Kr(a,c,function(p){return this._invoke(c,f,p)})}i?o?o(a,i,{value:l,enumerable:!s,configurable:!s,writable:!s}):a[i]=l:(u("next",0),u("throw",1),u("return",2))},Kr(e,t,r,n)}function Wp(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */var e,t,r=typeof Symbol=="function"?Symbol:{},n=r.iterator||"@@iterator",o=r.toStringTag||"@@toStringTag";function a(h,v,g,m){var b=v&&v.prototype instanceof l?v:l,y=Object.create(b.prototype);return Kr(y,"_invoke",(function(C,D,w){var k,E,x,O=0,j=w||[],$=!1,P={p:0,n:0,v:e,a:A,f:A.bind(e,4),d:function(B,S){return k=B,E=0,x=e,P.n=S,i}};function A(B,S){for(E=B,x=S,t=0;!$&&O&&!I&&t<j.length;t++){var I,N=j[t],F=P.p,M=N[2];B>3?(I=M===S)&&(x=N[(E=N[4])?5:(E=3,3)],N[4]=N[5]=e):N[0]<=F&&((I=B<2&&F<N[1])?(E=0,P.v=S,P.n=N[1]):F<M&&(I=B<3||N[0]>S||S>M)&&(N[4]=B,N[5]=S,P.n=M,E=0))}if(I||B>1)return i;throw $=!0,S}return function(B,S,I){if(O>1)throw TypeError("Generator is already running");for($&&S===1&&A(S,I),E=S,x=I;(t=E<2?e:x)||!$;){k||(E?E<3?(E>1&&(P.n=-1),A(E,x)):P.n=x:P.v=x);try{if(O=2,k){if(E||(B="next"),t=k[B]){if(!(t=t.call(k,x)))throw TypeError("iterator result is not an object");if(!t.done)return t;x=t.value,E<2&&(E=0)}else E===1&&(t=k.return)&&t.call(k),E<2&&(x=TypeError("The iterator does not provide a '"+B+"' method"),E=1);k=e}else if((t=($=P.n<0)?x:C.call(D,P))!==i)break}catch(N){k=e,E=1,x=N}finally{O=1}}return{value:t,done:$}}})(h,g,m),!0),y}var i={};function l(){}function s(){}function u(){}t=Object.getPrototypeOf;var c=[][n]?t(t([][n]())):(Kr(t={},n,function(){return this}),t),f=u.prototype=l.prototype=Object.create(c);function p(h){return Object.setPrototypeOf?Object.setPrototypeOf(h,u):(h.__proto__=u,Kr(h,o,"GeneratorFunction")),h.prototype=Object.create(f),h}return s.prototype=u,Kr(f,"constructor",u),Kr(u,"constructor",s),s.displayName="GeneratorFunction",Kr(u,o,"GeneratorFunction"),Kr(f),Kr(f,o,"Generator"),Kr(f,n,function(){return this}),Kr(f,"toString",function(){return"[object Generator]"}),(Wp=function(){return{w:a,m:p}})()}function Ks(e,t){function r(o,a,i,l){try{var s=e[o](a),u=s.value;return u instanceof vC?t.resolve(u.v).then(function(c){r("next",c,i,l)},function(c){r("throw",c,i,l)}):t.resolve(u).then(function(c){s.value=c,i(s)},function(c){return r("throw",c,i,l)})}catch(c){l(c)}}var n;this.next||(Kr(Ks.prototype),Kr(Ks.prototype,typeof Symbol=="function"&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),Kr(this,"_invoke",function(o,a,i){function l(){return new t(function(s,u){r(o,i,s,u)})}return n=n?n.then(l,l):l()},!0)}function bC(e,t,r,n,o){return new Ks(Wp().w(e,t,r,n),o||Promise)}function N3(e,t,r,n,o){var a=bC(e,t,r,n,o);return a.next().then(function(i){return i.done?i.value:a.next()})}function P3(e){var t=Object(e),r=[];for(var n in t)r.unshift(n);return function o(){for(;r.length;)if((n=r.pop())in t)return o.value=n,o.done=!1,o;return o.done=!0,o}}function Dv(e){if(e!=null){var t=e[typeof Symbol=="function"&&Symbol.iterator||"@@iterator"],r=0;if(t)return t.call(e);if(typeof e.next=="function")return e;if(!isNaN(e.length))return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}}}throw new TypeError(at(e)+" is not iterable")}function Ur(){var e=Wp(),t=e.m(Ur),r=(Object.getPrototypeOf?Object.getPrototypeOf(t):t.__proto__).constructor;function n(i){var l=typeof i=="function"&&i.constructor;return!!l&&(l===r||(l.displayName||l.name)==="GeneratorFunction")}var o={throw:1,return:2,break:3,continue:3};function a(i){var l,s;return function(u){l||(l={stop:function(){return s(u.a,2)},catch:function(){return u.v},abrupt:function(c,f){return s(u.a,o[c],f)},delegateYield:function(c,f,p){return l.resultName=f,s(u.d,Dv(c),p)},finish:function(c){return s(u.f,c)}},s=function(c,f,p){u.p=l.prev,u.n=l.next;try{return c(f,p)}finally{l.next=u.n}}),l.resultName&&(l[l.resultName]=u.v,l.resultName=void 0),l.sent=u.v,l.next=u.n;try{return i.call(this,l)}finally{u.p=l.prev,u.n=l.next}}}return(Ur=function(){return{wrap:function(i,l,s,u){return e.w(a(i),l,s,u&&u.reverse())},isGeneratorFunction:n,mark:e.m,awrap:function(i,l){return new vC(i,l)},AsyncIterator:Ks,async:function(i,l,s,u,c){return(n(l)?bC:N3)(a(i),l,s,u,c)},keys:P3,values:Dv}})()}function Sv(e,t,r,n,o,a,i){try{var l=e[a](i),s=l.value}catch(u){return void r(u)}l.done?t(s):Promise.resolve(s).then(n,o)}function da(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var a=e.apply(t,r);function i(s){Sv(a,n,o,i,l,"next",s)}function l(s){Sv(a,n,o,i,l,"throw",s)}i(void 0)})}}var wl=L({},Gw),j3=wl.version,Mc=wl.render,I3=wl.unmountComponentAtNode,Eu;try{var R3=Number((j3||"").split(".")[0]);R3>=18&&(Eu=wl.createRoot)}catch{}function $v(e){var t=wl.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&at(t)==="object"&&(t.usingClientEntryPoint=e)}var qs="__rc_react_root__";function M3(e,t){$v(!0);var r=t[qs]||Eu(t);$v(!1),r.render(e),t[qs]=r}function T3(e,t){Mc==null||Mc(e,t)}function z3(e,t){if(Eu){M3(e,t);return}T3(e,t)}function _3(e){return ff.apply(this,arguments)}function ff(){return ff=da(Ur().mark(function e(t){return Ur().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.abrupt("return",Promise.resolve().then(function(){var n;(n=t[qs])===null||n===void 0||n.unmount(),delete t[qs]}));case 1:case"end":return r.stop()}},e)})),ff.apply(this,arguments)}function L3(e){I3(e)}function H3(e){return pf.apply(this,arguments)}function pf(){return pf=da(Ur().mark(function e(t){return Ur().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:if(Eu===void 0){r.next=2;break}return r.abrupt("return",_3(t));case 2:L3(t);case 3:case"end":return r.stop()}},e)})),pf.apply(this,arguments)}const W3=(e,t)=>(z3(e,t),()=>H3(t));let K3=W3;function q3(e){return K3}const Tc=()=>({height:0,opacity:0}),Bv=e=>{const{scrollHeight:t}=e;return{height:t,opacity:1}},V3=e=>({height:e?e.offsetHeight:0}),zc=(e,t)=>(t==null?void 0:t.deadline)===!0||t.propertyName==="height",yC=(e=ll)=>({motionName:`${e}-motion-collapse`,onAppearStart:Tc,onEnterStart:Tc,onAppearActive:Bv,onEnterActive:Bv,onLeaveStart:V3,onLeaveActive:Tc,onAppearEnd:zc,onEnterEnd:zc,onLeaveEnd:zc,motionDeadline:500}),CC=(e,t,r)=>r!==void 0?r:`${e}-${t}`;function fn(e,t){var r=Object.assign({},e);return Array.isArray(t)&&t.forEach(function(n){delete r[n]}),r}const ku=(function(e){if(!e)return!1;if(e instanceof Element){if(e.offsetParent)return!0;if(e.getBBox){var t=e.getBBox(),r=t.width,n=t.height;if(r||n)return!0}if(e.getBoundingClientRect){var o=e.getBoundingClientRect(),a=o.width,i=o.height;if(a||i)return!0}}return!1}),G3=e=>{const{componentCls:t,colorPrimary:r}=e;return{[t]:{position:"absolute",background:"transparent",pointerEvents:"none",boxSizing:"border-box",color:`var(--wave-color, ${r})`,boxShadow:"0 0 0 0 currentcolor",opacity:.2,"&.wave-motion-appear":{transition:[`box-shadow 0.4s ${e.motionEaseOutCirc}`,`opacity 2s ${e.motionEaseOutCirc}`].join(","),"&-active":{boxShadow:"0 0 0 6px currentcolor",opacity:0},"&.wave-quick":{transition:[`box-shadow ${e.motionDurationSlow} ${e.motionEaseInOut}`,`opacity ${e.motionDurationSlow} ${e.motionEaseInOut}`].join(",")}}}}},X3=wF("Wave",G3),Du=`${ll}-wave-target`;function U3(e){return e&&e!=="#fff"&&e!=="#ffffff"&&e!=="rgb(255, 255, 255)"&&e!=="rgba(255, 255, 255, 1)"&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&e!=="transparent"&&e!=="canvastext"}function Y3(e){var t;const{borderTopColor:r,borderColor:n,backgroundColor:o}=getComputedStyle(e);return(t=[r,n,o].find(U3))!==null&&t!==void 0?t:null}function _c(e){return Number.isNaN(e)?0:e}const Z3=e=>{const{className:t,target:r,component:n,registerUnmount:o}=e,a=d.useRef(null),i=d.useRef(null);d.useEffect(()=>{i.current=o()},[]);const[l,s]=d.useState(null),[u,c]=d.useState([]),[f,p]=d.useState(0),[h,v]=d.useState(0),[g,m]=d.useState(0),[b,y]=d.useState(0),[C,D]=d.useState(!1),w={left:f,top:h,width:g,height:b,borderRadius:u.map(x=>`${x}px`).join(" ")};l&&(w["--wave-color"]=l);function k(){const x=getComputedStyle(r);s(Y3(r));const O=x.position==="static",{borderLeftWidth:j,borderTopWidth:$}=x;p(O?r.offsetLeft:_c(-parseFloat(j))),v(O?r.offsetTop:_c(-parseFloat($))),m(r.offsetWidth),y(r.offsetHeight);const{borderTopLeftRadius:P,borderTopRightRadius:A,borderBottomLeftRadius:B,borderBottomRightRadius:S}=x;c([P,A,S,B].map(I=>_c(parseFloat(I))))}if(d.useEffect(()=>{if(r){const x=qt(()=>{k(),D(!0)});let O;return typeof ResizeObserver<"u"&&(O=new ResizeObserver(k),O.observe(r)),()=>{qt.cancel(x),O==null||O.disconnect()}}},[]),!C)return null;const E=(n==="Checkbox"||n==="Radio")&&(r==null?void 0:r.classList.contains(Du));return d.createElement(ca,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:(x,O)=>{var j,$;if(O.deadline||O.propertyName==="opacity"){const P=(j=a.current)===null||j===void 0?void 0:j.parentElement;($=i.current)===null||$===void 0||$.call(i).then(()=>{P==null||P.remove()})}return!1}},({className:x},O)=>d.createElement("div",{ref:ro(a,O),className:pe(t,x,{"wave-quick":E}),style:w}))},J3=(e,t)=>{var r;const{component:n}=t;if(n==="Checkbox"&&!(!((r=e.querySelector("input"))===null||r===void 0)&&r.checked))return;const o=document.createElement("div");o.style.position="absolute",o.style.left="0px",o.style.top="0px",e==null||e.insertBefore(o,e==null?void 0:e.firstChild);const a=q3();let i=null;function l(){return i}i=a(d.createElement(Z3,Object.assign({},t,{target:e,registerUnmount:l})),o)},Q3=(e,t,r)=>{const{wave:n}=d.useContext(Zt),[,o,a]=Yr(),i=nr(s=>{const u=e.current;if(n!=null&&n.disabled||!u)return;const c=u.querySelector(`.${Du}`)||u,{showEffect:f}=n||{};(f||J3)(c,{className:t,token:o,component:r,event:s,hashId:a})}),l=d.useRef(null);return s=>{qt.cancel(l.current),l.current=qt(()=>{i(s)})}},Kp=e=>{const{children:t,disabled:r,component:n}=e,{getPrefixCls:o}=Rr(Zt),a=qe(null),i=o("wave"),[,l]=X3(i),s=Q3(a,pe(i,l),n);if(ee.useEffect(()=>{const c=a.current;if(!c||c.nodeType!==1||r)return;const f=p=>{!ku(p.target)||!c.getAttribute||c.getAttribute("disabled")||c.disabled||c.className.includes("disabled")||c.className.includes("-leave")||s(p)};return c.addEventListener("click",f,!0),()=>{c.removeEventListener("click",f,!0)}},[r]),!ee.isValidElement(t))return t??null;const u=Zn(t)?ro(ua(t),a):a;return eo(t,{ref:u})},fa=e=>{const t=ee.useContext(Xa);return ee.useMemo(()=>e?typeof e=="string"?e??t:typeof e=="function"?e(t):t:t,[e,t])},e5=e=>{const{componentCls:t}=e;return{[t]:{"&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"}}}},t5=e=>{const{componentCls:t,antCls:r}=e;return{[t]:{display:"inline-flex","&-rtl":{direction:"rtl"},"&-vertical":{flexDirection:"column"},"&-align":{flexDirection:"column","&-center":{alignItems:"center"},"&-start":{alignItems:"flex-start"},"&-end":{alignItems:"flex-end"},"&-baseline":{alignItems:"baseline"}},[`${t}-item:empty`]:{display:"none"},[`${t}-item > ${r}-badge-not-a-wrapper:only-child`]:{display:"block"}}}},r5=e=>{const{componentCls:t}=e;return{[t]:{"&-gap-row-small":{rowGap:e.spaceGapSmallSize},"&-gap-row-middle":{rowGap:e.spaceGapMiddleSize},"&-gap-row-large":{rowGap:e.spaceGapLargeSize},"&-gap-col-small":{columnGap:e.spaceGapSmallSize},"&-gap-col-middle":{columnGap:e.spaceGapMiddleSize},"&-gap-col-large":{columnGap:e.spaceGapLargeSize}}}},xC=Hr("Space",e=>{const t=er(e,{spaceGapSmallSize:e.paddingXS,spaceGapMiddleSize:e.padding,spaceGapLargeSize:e.paddingLG});return[t5(t),r5(t),e5(t)]},()=>({}),{resetStyle:!1});var wC=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const Su=d.createContext(null),$u=(e,t)=>{const r=d.useContext(Su),n=d.useMemo(()=>{if(!r)return"";const{compactDirection:o,isFirstItem:a,isLastItem:i}=r,l=o==="vertical"?"-vertical-":"-";return pe(`${e}-compact${l}item`,{[`${e}-compact${l}first-item`]:a,[`${e}-compact${l}last-item`]:i,[`${e}-compact${l}item-rtl`]:t==="rtl"})},[e,t,r]);return{compactSize:r==null?void 0:r.compactSize,compactDirection:r==null?void 0:r.compactDirection,compactItemClassnames:n}},n5=e=>{const{children:t}=e;return d.createElement(Su.Provider,{value:null},t)},o5=e=>{const{children:t}=e,r=wC(e,["children"]);return d.createElement(Su.Provider,{value:d.useMemo(()=>r,[r])},t)},a5=e=>{const{getPrefixCls:t,direction:r}=d.useContext(Zt),{size:n,direction:o,block:a,prefixCls:i,className:l,rootClassName:s,children:u}=e,c=wC(e,["size","direction","block","prefixCls","className","rootClassName","children"]),f=fa(C=>n??C),p=t("space-compact",i),[h,v]=xC(p),g=pe(p,v,{[`${p}-rtl`]:r==="rtl",[`${p}-block`]:a,[`${p}-vertical`]:o==="vertical"},l,s),m=d.useContext(Su),b=Ln(u),y=d.useMemo(()=>b.map((C,D)=>{const w=(C==null?void 0:C.key)||`${p}-item-${D}`;return d.createElement(o5,{key:w,compactSize:f,compactDirection:o,isFirstItem:D===0&&(!m||(m==null?void 0:m.isFirstItem)),isLastItem:D===b.length-1&&(!m||(m==null?void 0:m.isLastItem))},C)}),[n,b,m]);return b.length===0?null:h(d.createElement("div",Object.assign({className:g},c),y))};var i5=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const EC=d.createContext(void 0),l5=e=>{const{getPrefixCls:t,direction:r}=d.useContext(Zt),{prefixCls:n,size:o,className:a}=e,i=i5(e,["prefixCls","size","className"]),l=t("btn-group",n),[,,s]=Yr(),u=d.useMemo(()=>{switch(o){case"large":return"lg";case"small":return"sm";default:return""}},[o]),c=pe(l,{[`${l}-${u}`]:u,[`${l}-rtl`]:r==="rtl"},a,s);return d.createElement(EC.Provider,{value:o},d.createElement("div",Object.assign({},i,{className:c})))},Ov=/^[\u4E00-\u9FA5]{2}$/,mf=Ov.test.bind(Ov);function Av(e){return typeof e=="string"}function Lc(e){return e==="text"||e==="link"}function s5(e,t){if(e==null)return;const r=t?" ":"";return typeof e!="string"&&typeof e!="number"&&Av(e.type)&&mf(e.props.children)?eo(e,{children:e.props.children.split("").join(r)}):Av(e)?mf(e)?ee.createElement("span",null,e.split("").join(r)):ee.createElement("span",null,e):hC(e)?ee.createElement("span",null,e):e}function u5(e,t){let r=!1;const n=[];return ee.Children.forEach(e,o=>{const a=typeof o,i=a==="string"||a==="number";if(r&&i){const l=n.length-1,s=n[l];n[l]=`${s}${o}`}else n.push(o);r=i}),ee.Children.map(n,o=>s5(o,t))}["default","primary","danger"].concat(Ie(na));const hf=dn((e,t)=>{const{className:r,style:n,children:o,prefixCls:a}=e,i=pe(`${a}-icon`,r);return ee.createElement("span",{ref:t,className:i,style:n},o)}),Fv=dn((e,t)=>{const{prefixCls:r,className:n,style:o,iconClassName:a}=e,i=pe(`${r}-loading-icon`,n);return ee.createElement(hf,{prefixCls:r,className:i,style:o,ref:t},ee.createElement(Lp,{className:a}))}),Hc=()=>({width:0,opacity:0,transform:"scale(0)"}),Wc=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"}),c5=e=>{const{prefixCls:t,loading:r,existIcon:n,className:o,style:a,mount:i}=e,l=!!r;return n?ee.createElement(Fv,{prefixCls:t,className:o,style:a}):ee.createElement(ca,{visible:l,motionName:`${t}-loading-icon-motion`,motionAppear:!i,motionEnter:!i,motionLeave:!i,removeOnLeave:!0,onAppearStart:Hc,onAppearActive:Wc,onEnterStart:Hc,onEnterActive:Wc,onLeaveStart:Wc,onLeaveActive:Hc},({className:s,style:u},c)=>{const f=Object.assign(Object.assign({},a),u);return ee.createElement(Fv,{prefixCls:t,className:pe(o,s),style:f,ref:c})})},Nv=(e,t)=>({[`> span, > ${e}`]:{"&:not(:last-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}}),d5=e=>{const{componentCls:t,fontSize:r,lineWidth:n,groupBorderColor:o,colorErrorHover:a}=e;return{[`${t}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${t}`]:{"&:not(:last-child)":{[`&, & > ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:e.calc(n).mul(-1).equal(),[`&, & > ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,"&:hover, &:focus, &:active":{zIndex:2},"&[disabled]":{zIndex:0}},[`${t}-icon-only`]:{fontSize:r}},Nv(`${t}-primary`,o),Nv(`${t}-danger`,a)]}};var f5=["b"],p5=["v"],Kc=function(e){return Math.round(Number(e||0))},m5=function(e){if(e instanceof Ht)return e;if(e&&at(e)==="object"&&"h"in e&&"b"in e){var t=e,r=t.b,n=bt(t,f5);return L(L({},n),{},{v:r})}return typeof e=="string"&&/hsb/.test(e)?e.replace(/hsb/,"hsv"):e},dl=(function(e){no(r,e);var t=oo(r);function r(n){return vr(this,r),t.call(this,m5(n))}return br(r,[{key:"toHsbString",value:function(){var n=this.toHsb(),o=Kc(n.s*100),a=Kc(n.b*100),i=Kc(n.h),l=n.a,s="hsb(".concat(i,", ").concat(o,"%, ").concat(a,"%)"),u="hsba(".concat(i,", ").concat(o,"%, ").concat(a,"%, ").concat(l.toFixed(l===0?0:2),")");return l===1?s:u}},{key:"toHsb",value:function(){var n=this.toHsv(),o=n.v,a=bt(n,p5);return L(L({},a),{},{b:o,a:this.a})}}]),r})(Ht),h5=function(e){return e instanceof dl?e:new dl(e)};h5("#1677ff");const g5=(e,t)=>(e==null?void 0:e.replace(/[^\w/]/g,"").slice(0,t?8:6))||"",v5=(e,t)=>e?g5(e,t):"";let gf=(function(){function e(t){vr(this,e);var r;if(this.cleared=!1,t instanceof e){this.metaColor=t.metaColor.clone(),this.colors=(r=t.colors)===null||r===void 0?void 0:r.map(o=>({color:new e(o.color),percent:o.percent})),this.cleared=t.cleared;return}const n=Array.isArray(t);n&&t.length?(this.colors=t.map(({color:o,percent:a})=>({color:new e(o),percent:a})),this.metaColor=new dl(this.colors[0].color.metaColor)):this.metaColor=new dl(n?"":t),(!t||n&&!this.colors)&&(this.metaColor=this.metaColor.setA(0),this.cleared=!0)}return br(e,[{key:"toHsb",value:function(){return this.metaColor.toHsb()}},{key:"toHsbString",value:function(){return this.metaColor.toHsbString()}},{key:"toHex",value:function(){return v5(this.toHexString(),this.metaColor.a<1)}},{key:"toHexString",value:function(){return this.metaColor.toHexString()}},{key:"toRgb",value:function(){return this.metaColor.toRgb()}},{key:"toRgbString",value:function(){return this.metaColor.toRgbString()}},{key:"isGradient",value:function(){return!!this.colors&&!this.cleared}},{key:"getColors",value:function(){return this.colors||[{color:this,percent:0}]}},{key:"toCssString",value:function(){const{colors:t}=this;return t?`linear-gradient(90deg, ${t.map(r=>`${r.color.toRgbString()} ${r.percent}%`).join(", ")})`:this.metaColor.toRgbString()}},{key:"equals",value:function(t){return!t||this.isGradient()!==t.isGradient()?!1:this.isGradient()?this.colors.length===t.colors.length&&this.colors.every((r,n)=>{const o=t.colors[n];return r.percent===o.percent&&r.color.equals(o.color)}):this.toHexString()===t.toHexString()}}])})();var b5={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"},y5=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:b5}))},vf=d.forwardRef(y5);const kC=e=>({[e.componentCls]:{[`${e.antCls}-motion-collapse-legacy`]:{overflow:"hidden","&-active":{transition:`height ${e.motionDurationMid} ${e.motionEaseInOut},
|
|
274
|
+
opacity ${e.motionDurationMid} ${e.motionEaseInOut} !important`}},[`${e.antCls}-motion-collapse`]:{overflow:"hidden",transition:`height ${e.motionDurationMid} ${e.motionEaseInOut},
|
|
275
|
+
opacity ${e.motionDurationMid} ${e.motionEaseInOut} !important`}}}),C5=e=>({animationDuration:e,animationFillMode:"both"}),x5=e=>({animationDuration:e,animationFillMode:"both"}),qp=(e,t,r,n,o=!1)=>{const a=o?"&":"";return{[`
|
|
276
|
+
${a}${e}-enter,
|
|
277
|
+
${a}${e}-appear
|
|
278
|
+
`]:Object.assign(Object.assign({},C5(n)),{animationPlayState:"paused"}),[`${a}${e}-leave`]:Object.assign(Object.assign({},x5(n)),{animationPlayState:"paused"}),[`
|
|
279
|
+
${a}${e}-enter${e}-enter-active,
|
|
280
|
+
${a}${e}-appear${e}-appear-active
|
|
281
|
+
`]:{animationName:t,animationPlayState:"running"},[`${a}${e}-leave${e}-leave-active`]:{animationName:r,animationPlayState:"running",pointerEvents:"none"}}},w5=new Vt("antMoveDownIn",{"0%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),E5=new Vt("antMoveDownOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0}}),k5=new Vt("antMoveLeftIn",{"0%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),D5=new Vt("antMoveLeftOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),S5=new Vt("antMoveRightIn",{"0%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),$5=new Vt("antMoveRightOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),B5=new Vt("antMoveUpIn",{"0%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),O5=new Vt("antMoveUpOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0}}),A5={"move-up":{inKeyframes:B5,outKeyframes:O5},"move-down":{inKeyframes:w5,outKeyframes:E5},"move-left":{inKeyframes:k5,outKeyframes:D5},"move-right":{inKeyframes:S5,outKeyframes:$5}},Vs=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:o,outKeyframes:a}=A5[t];return[qp(n,o,a,e.motionDurationMid),{[`
|
|
282
|
+
${n}-enter,
|
|
283
|
+
${n}-appear
|
|
284
|
+
`]:{opacity:0,animationTimingFunction:e.motionEaseOutCirc},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]},Vp=new Vt("antSlideUpIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1}}),Gp=new Vt("antSlideUpOut",{"0%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0}}),Xp=new Vt("antSlideDownIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1}}),Up=new Vt("antSlideDownOut",{"0%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0}}),F5=new Vt("antSlideLeftIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1}}),N5=new Vt("antSlideLeftOut",{"0%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0}}),P5=new Vt("antSlideRightIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1}}),j5=new Vt("antSlideRightOut",{"0%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0}}),I5={"slide-up":{inKeyframes:Vp,outKeyframes:Gp},"slide-down":{inKeyframes:Xp,outKeyframes:Up},"slide-left":{inKeyframes:F5,outKeyframes:N5},"slide-right":{inKeyframes:P5,outKeyframes:j5}},Ua=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:o,outKeyframes:a}=I5[t];return[qp(n,o,a,e.motionDurationMid),{[`
|
|
285
|
+
${n}-enter,
|
|
286
|
+
${n}-appear
|
|
287
|
+
`]:{transform:"scale(0)",transformOrigin:"0% 0%",opacity:0,animationTimingFunction:e.motionEaseOutQuint,"&-prepare":{transform:"scale(1)"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInQuint}}]},R5=new Vt("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),M5=new Vt("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),Pv=new Vt("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),jv=new Vt("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),T5=new Vt("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),z5=new Vt("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),_5=new Vt("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),L5=new Vt("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),H5=new Vt("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),W5=new Vt("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}}),K5=new Vt("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),q5=new Vt("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}}),V5={zoom:{inKeyframes:R5,outKeyframes:M5},"zoom-big":{inKeyframes:Pv,outKeyframes:jv},"zoom-big-fast":{inKeyframes:Pv,outKeyframes:jv},"zoom-left":{inKeyframes:_5,outKeyframes:L5},"zoom-right":{inKeyframes:H5,outKeyframes:W5},"zoom-up":{inKeyframes:T5,outKeyframes:z5},"zoom-down":{inKeyframes:K5,outKeyframes:q5}},Yp=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:o,outKeyframes:a}=V5[t];return[qp(n,o,a,t==="zoom-big-fast"?e.motionDurationFast:e.motionDurationMid),{[`
|
|
288
|
+
${n}-enter,
|
|
289
|
+
${n}-appear
|
|
290
|
+
`]:{transform:"scale(0)",opacity:0,animationTimingFunction:e.motionEaseOutCirc,"&-prepare":{transform:"none"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]},G5=e=>e instanceof gf?e:new gf(e),X5=(e,t)=>{const{r,g:n,b:o,a}=e.toRgb(),i=new dl(e.toRgbString()).onBackground(t).toHsv();return a<=.5?i.v>.5:r*.299+n*.587+o*.114>192},DC=e=>{const{paddingInline:t,onlyIconSize:r}=e;return er(e,{buttonPaddingHorizontal:t,buttonPaddingVertical:0,buttonIconOnlyFontSize:r})},SC=e=>{var t,r,n,o,a,i;const l=(t=e.contentFontSize)!==null&&t!==void 0?t:e.fontSize,s=(r=e.contentFontSizeSM)!==null&&r!==void 0?r:e.fontSize,u=(n=e.contentFontSizeLG)!==null&&n!==void 0?n:e.fontSizeLG,c=(o=e.contentLineHeight)!==null&&o!==void 0?o:Cs(l),f=(a=e.contentLineHeightSM)!==null&&a!==void 0?a:Cs(s),p=(i=e.contentLineHeightLG)!==null&&i!==void 0?i:Cs(u),h=X5(new gf(e.colorBgSolid),"#fff")?"#000":"#fff",v=na.reduce((g,m)=>Object.assign(Object.assign({},g),{[`${m}ShadowColor`]:`0 ${ue(e.controlOutlineWidth)} 0 ${$i(e[`${m}1`],e.colorBgContainer)}`}),{});return Object.assign(Object.assign({},v),{fontWeight:400,iconGap:e.marginXS,defaultShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlTmpOutline}`,primaryShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlOutline}`,dangerShadow:`0 ${e.controlOutlineWidth}px 0 ${e.colorErrorOutline}`,primaryColor:e.colorTextLightSolid,dangerColor:e.colorTextLightSolid,borderColorDisabled:e.colorBorder,defaultGhostColor:e.colorBgContainer,ghostBg:"transparent",defaultGhostBorderColor:e.colorBgContainer,paddingInline:e.paddingContentHorizontal-e.lineWidth,paddingInlineLG:e.paddingContentHorizontal-e.lineWidth,paddingInlineSM:8-e.lineWidth,onlyIconSize:"inherit",onlyIconSizeSM:"inherit",onlyIconSizeLG:"inherit",groupBorderColor:e.colorPrimaryHover,linkHoverBg:"transparent",textTextColor:e.colorText,textTextHoverColor:e.colorText,textTextActiveColor:e.colorText,textHoverBg:e.colorFillTertiary,defaultColor:e.colorText,defaultBg:e.colorBgContainer,defaultBorderColor:e.colorBorder,defaultBorderColorDisabled:e.colorBorder,defaultHoverBg:e.colorBgContainer,defaultHoverColor:e.colorPrimaryHover,defaultHoverBorderColor:e.colorPrimaryHover,defaultActiveBg:e.colorBgContainer,defaultActiveColor:e.colorPrimaryActive,defaultActiveBorderColor:e.colorPrimaryActive,solidTextColor:h,contentFontSize:l,contentFontSizeSM:s,contentFontSizeLG:u,contentLineHeight:c,contentLineHeightSM:f,contentLineHeightLG:p,paddingBlock:Math.max((e.controlHeight-l*c)/2-e.lineWidth,0),paddingBlockSM:Math.max((e.controlHeightSM-s*f)/2-e.lineWidth,0),paddingBlockLG:Math.max((e.controlHeightLG-u*p)/2-e.lineWidth,0)})},U5=e=>{const{componentCls:t,iconCls:r,fontWeight:n,opacityLoading:o,motionDurationSlow:a,motionEaseInOut:i,iconGap:l,calc:s}=e;return{[t]:{outline:"none",position:"relative",display:"inline-flex",gap:l,alignItems:"center",justifyContent:"center",fontWeight:n,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",background:"transparent",border:`${ue(e.lineWidth)} ${e.lineType} transparent`,cursor:"pointer",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,userSelect:"none",touchAction:"manipulation",color:e.colorText,"&:disabled > *":{pointerEvents:"none"},[`${t}-icon > svg`]:xl(),"> a":{color:"currentColor"},"&:not(:disabled)":cl(e),[`&${t}-two-chinese-chars::first-letter`]:{letterSpacing:"0.34em"},[`&${t}-two-chinese-chars > *:not(${r})`]:{marginInlineEnd:"-0.34em",letterSpacing:"0.34em"},[`&${t}-icon-only`]:{paddingInline:0,[`&${t}-compact-item`]:{flex:"none"},[`&${t}-round`]:{width:"auto"}},[`&${t}-loading`]:{opacity:o,cursor:"default"},[`${t}-loading-icon`]:{transition:["width","opacity","margin"].map(u=>`${u} ${a} ${i}`).join(",")},[`&:not(${t}-icon-end)`]:{[`${t}-loading-icon-motion`]:{"&-appear-start, &-enter-start":{marginInlineEnd:s(l).mul(-1).equal()},"&-appear-active, &-enter-active":{marginInlineEnd:0},"&-leave-start":{marginInlineEnd:0},"&-leave-active":{marginInlineEnd:s(l).mul(-1).equal()}}},"&-icon-end":{flexDirection:"row-reverse",[`${t}-loading-icon-motion`]:{"&-appear-start, &-enter-start":{marginInlineStart:s(l).mul(-1).equal()},"&-appear-active, &-enter-active":{marginInlineStart:0},"&-leave-start":{marginInlineStart:0},"&-leave-active":{marginInlineStart:s(l).mul(-1).equal()}}}}}},$C=(e,t,r)=>({[`&:not(:disabled):not(${e}-disabled)`]:{"&:hover":t,"&:active":r}}),Y5=e=>({minWidth:e.controlHeight,paddingInlineStart:0,paddingInlineEnd:0,borderRadius:"50%"}),Z5=e=>({borderRadius:e.controlHeight,paddingInlineStart:e.calc(e.controlHeight).div(2).equal(),paddingInlineEnd:e.calc(e.controlHeight).div(2).equal()}),J5=e=>({cursor:"not-allowed",borderColor:e.borderColorDisabled,color:e.colorTextDisabled,background:e.colorBgContainerDisabled,boxShadow:"none"}),Bu=(e,t,r,n,o,a,i,l)=>({[`&${e}-background-ghost`]:Object.assign(Object.assign({color:r||void 0,background:t,borderColor:n||void 0,boxShadow:"none"},$C(e,Object.assign({background:t},i),Object.assign({background:t},l))),{"&:disabled":{cursor:"not-allowed",color:o||void 0,borderColor:a||void 0}})}),Q5=e=>({[`&:disabled, &${e.componentCls}-disabled`]:Object.assign({},J5(e))}),eN=e=>({[`&:disabled, &${e.componentCls}-disabled`]:{cursor:"not-allowed",color:e.colorTextDisabled}}),Ou=(e,t,r,n)=>{const o=n&&["link","text"].includes(n)?eN:Q5;return Object.assign(Object.assign({},o(e)),$C(e.componentCls,t,r))},Au=(e,t,r,n,o)=>({[`&${e.componentCls}-variant-solid`]:Object.assign({color:t,background:r},Ou(e,n,o))}),Fu=(e,t,r,n,o)=>({[`&${e.componentCls}-variant-outlined, &${e.componentCls}-variant-dashed`]:Object.assign({borderColor:t,background:r},Ou(e,n,o))}),Nu=e=>({[`&${e.componentCls}-variant-dashed`]:{borderStyle:"dashed"}}),Pu=(e,t,r,n)=>({[`&${e.componentCls}-variant-filled`]:Object.assign({boxShadow:"none",background:t},Ou(e,r,n))}),to=(e,t,r,n,o)=>({[`&${e.componentCls}-variant-${r}`]:Object.assign({color:t,boxShadow:"none"},Ou(e,n,o,r))}),tN=e=>{const{componentCls:t}=e;return na.reduce((r,n)=>{const o=e[`${n}6`],a=e[`${n}1`],i=e[`${n}5`],l=e[`${n}2`],s=e[`${n}3`],u=e[`${n}7`];return Object.assign(Object.assign({},r),{[`&${t}-color-${n}`]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({color:o,boxShadow:e[`${n}ShadowColor`]},Au(e,e.colorTextLightSolid,o,{background:i},{background:u})),Fu(e,o,e.colorBgContainer,{color:i,borderColor:i,background:e.colorBgContainer},{color:u,borderColor:u,background:e.colorBgContainer})),Nu(e)),Pu(e,a,{color:o,background:l},{color:o,background:s})),to(e,o,"link",{color:i},{color:u})),to(e,o,"text",{color:i,background:a},{color:u,background:s}))})},{})},rN=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({color:e.defaultColor,boxShadow:e.defaultShadow},Au(e,e.solidTextColor,e.colorBgSolid,{color:e.solidTextColor,background:e.colorBgSolidHover},{color:e.solidTextColor,background:e.colorBgSolidActive})),Nu(e)),Pu(e,e.colorFillTertiary,{color:e.defaultColor,background:e.colorFillSecondary},{color:e.defaultColor,background:e.colorFill})),Bu(e.componentCls,e.ghostBg,e.defaultGhostColor,e.defaultGhostBorderColor,e.colorTextDisabled,e.colorBorder)),to(e,e.textTextColor,"link",{color:e.colorLinkHover,background:e.linkHoverBg},{color:e.colorLinkActive})),nN=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({color:e.colorPrimary,boxShadow:e.primaryShadow},Fu(e,e.colorPrimary,e.colorBgContainer,{color:e.colorPrimaryTextHover,borderColor:e.colorPrimaryHover,background:e.colorBgContainer},{color:e.colorPrimaryTextActive,borderColor:e.colorPrimaryActive,background:e.colorBgContainer})),Nu(e)),Pu(e,e.colorPrimaryBg,{color:e.colorPrimary,background:e.colorPrimaryBgHover},{color:e.colorPrimary,background:e.colorPrimaryBorder})),to(e,e.colorPrimaryText,"text",{color:e.colorPrimaryTextHover,background:e.colorPrimaryBg},{color:e.colorPrimaryTextActive,background:e.colorPrimaryBorder})),to(e,e.colorPrimaryText,"link",{color:e.colorPrimaryTextHover,background:e.linkHoverBg},{color:e.colorPrimaryTextActive})),Bu(e.componentCls,e.ghostBg,e.colorPrimary,e.colorPrimary,e.colorTextDisabled,e.colorBorder,{color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})),oN=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({color:e.colorError,boxShadow:e.dangerShadow},Au(e,e.dangerColor,e.colorError,{background:e.colorErrorHover},{background:e.colorErrorActive})),Fu(e,e.colorError,e.colorBgContainer,{color:e.colorErrorHover,borderColor:e.colorErrorBorderHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),Nu(e)),Pu(e,e.colorErrorBg,{color:e.colorError,background:e.colorErrorBgFilledHover},{color:e.colorError,background:e.colorErrorBgActive})),to(e,e.colorError,"text",{color:e.colorErrorHover,background:e.colorErrorBg},{color:e.colorErrorHover,background:e.colorErrorBgActive})),to(e,e.colorError,"link",{color:e.colorErrorHover},{color:e.colorErrorActive})),Bu(e.componentCls,e.ghostBg,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder,{color:e.colorErrorHover,borderColor:e.colorErrorHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),aN=e=>Object.assign(Object.assign({},to(e,e.colorLink,"link",{color:e.colorLinkHover},{color:e.colorLinkActive})),Bu(e.componentCls,e.ghostBg,e.colorInfo,e.colorInfo,e.colorTextDisabled,e.colorBorder,{color:e.colorInfoHover,borderColor:e.colorInfoHover},{color:e.colorInfoActive,borderColor:e.colorInfoActive})),iN=e=>{const{componentCls:t}=e;return Object.assign({[`${t}-color-default`]:rN(e),[`${t}-color-primary`]:nN(e),[`${t}-color-dangerous`]:oN(e),[`${t}-color-link`]:aN(e)},tN(e))},lN=e=>Object.assign(Object.assign(Object.assign(Object.assign({},Fu(e,e.defaultBorderColor,e.defaultBg,{color:e.defaultHoverColor,borderColor:e.defaultHoverBorderColor,background:e.defaultHoverBg},{color:e.defaultActiveColor,borderColor:e.defaultActiveBorderColor,background:e.defaultActiveBg})),to(e,e.textTextColor,"text",{color:e.textTextHoverColor,background:e.textHoverBg},{color:e.textTextActiveColor,background:e.colorBgTextActive})),Au(e,e.primaryColor,e.colorPrimary,{background:e.colorPrimaryHover,color:e.primaryColor},{background:e.colorPrimaryActive,color:e.primaryColor})),to(e,e.colorLink,"link",{color:e.colorLinkHover,background:e.linkHoverBg},{color:e.colorLinkActive})),Zp=(e,t="")=>{const{componentCls:r,controlHeight:n,fontSize:o,borderRadius:a,buttonPaddingHorizontal:i,iconCls:l,buttonPaddingVertical:s,buttonIconOnlyFontSize:u}=e;return[{[t]:{fontSize:o,height:n,padding:`${ue(s)} ${ue(i)}`,borderRadius:a,[`&${r}-icon-only`]:{width:n,[l]:{fontSize:u}}}},{[`${r}${r}-circle${t}`]:Y5(e)},{[`${r}${r}-round${t}`]:Z5(e)}]},sN=e=>{const t=er(e,{fontSize:e.contentFontSize});return Zp(t,e.componentCls)},uN=e=>{const t=er(e,{controlHeight:e.controlHeightSM,fontSize:e.contentFontSizeSM,padding:e.paddingXS,buttonPaddingHorizontal:e.paddingInlineSM,buttonPaddingVertical:0,borderRadius:e.borderRadiusSM,buttonIconOnlyFontSize:e.onlyIconSizeSM});return Zp(t,`${e.componentCls}-sm`)},cN=e=>{const t=er(e,{controlHeight:e.controlHeightLG,fontSize:e.contentFontSizeLG,buttonPaddingHorizontal:e.paddingInlineLG,buttonPaddingVertical:0,borderRadius:e.borderRadiusLG,buttonIconOnlyFontSize:e.onlyIconSizeLG});return Zp(t,`${e.componentCls}-lg`)},dN=e=>{const{componentCls:t}=e;return{[t]:{[`&${t}-block`]:{width:"100%"}}}},fN=Hr("Button",e=>{const t=DC(e);return[U5(t),sN(t),uN(t),cN(t),dN(t),iN(t),lN(t),d5(t)]},SC,{unitless:{fontWeight:!0,contentLineHeight:!0,contentLineHeightSM:!0,contentLineHeightLG:!0}});function pN(e,t,r,n){const{focusElCls:o,focus:a,borderElCls:i}=r,l=i?"> *":"",s=["hover",a?"focus":null,"active"].filter(Boolean).map(u=>`&:${u} ${l}`).join(",");return{[`&-item:not(${t}-last-item)`]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal()},[`&-item:not(${n}-status-success)`]:{zIndex:2},"&-item":Object.assign(Object.assign({[s]:{zIndex:3}},o?{[`&${o}`]:{zIndex:3}}:{}),{[`&[disabled] ${l}`]:{zIndex:0}})}}function mN(e,t,r){const{borderElCls:n}=r,o=n?`> ${n}`:"";return{[`&-item:not(${t}-first-item):not(${t}-last-item) ${o}`]:{borderRadius:0},[`&-item:not(${t}-last-item)${t}-first-item`]:{[`& ${o}, &${e}-sm ${o}, &${e}-lg ${o}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${t}-first-item)${t}-last-item`]:{[`& ${o}, &${e}-sm ${o}, &${e}-lg ${o}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}function Jp(e,t={focus:!0}){const{componentCls:r}=e,n=`${r}-compact`;return{[n]:Object.assign(Object.assign({},pN(e,n,t,r)),mN(r,n,t))}}function hN(e,t,r){return{[`&-item:not(${t}-last-item)`]:{marginBottom:e.calc(e.lineWidth).mul(-1).equal()},[`&-item:not(${r}-status-success)`]:{zIndex:2},"&-item":{"&:hover,&:focus,&:active":{zIndex:3},"&[disabled]":{zIndex:0}}}}function gN(e,t){return{[`&-item:not(${t}-first-item):not(${t}-last-item)`]:{borderRadius:0},[`&-item${t}-first-item:not(${t}-last-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderEndEndRadius:0,borderEndStartRadius:0}},[`&-item${t}-last-item:not(${t}-first-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderStartStartRadius:0,borderStartEndRadius:0}}}}function vN(e){const t=`${e.componentCls}-compact-vertical`;return{[t]:Object.assign(Object.assign({},hN(e,t,e.componentCls)),gN(e.componentCls,t))}}const bN=e=>{const{componentCls:t,colorPrimaryHover:r,lineWidth:n,calc:o}=e,a=o(n).mul(-1).equal(),i=l=>{const s=`${t}-compact${l?"-vertical":""}-item${t}-primary:not([disabled])`;return{[`${s} + ${s}::before`]:{position:"absolute",top:l?a:0,insetInlineStart:l?0:a,backgroundColor:r,content:'""',width:l?"100%":n,height:l?n:"100%"}}};return Object.assign(Object.assign({},i()),i(!0))},yN=J1(["Button","compact"],e=>{const t=DC(e);return[Jp(t),vN(t),bN(t)]},SC);var CN=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};function xN(e){if(typeof e=="object"&&e){let t=e==null?void 0:e.delay;return t=!Number.isNaN(t)&&typeof t=="number"?t:0,{loading:t<=0,delay:t}}return{loading:!!e,delay:0}}const wN={default:["default","outlined"],primary:["primary","solid"],dashed:["default","dashed"],link:["link","link"],text:["default","text"]},EN=ee.forwardRef((e,t)=>{var r,n;const{loading:o=!1,prefixCls:a,color:i,variant:l,type:s,danger:u=!1,shape:c,size:f,styles:p,disabled:h,className:v,rootClassName:g,children:m,icon:b,iconPosition:y="start",ghost:C=!1,block:D=!1,htmlType:w="button",classNames:k,style:E={},autoInsertSpace:x,autoFocus:O}=e,j=CN(e,["loading","prefixCls","color","variant","type","danger","shape","size","styles","disabled","className","rootClassName","children","icon","iconPosition","ghost","block","htmlType","classNames","style","autoInsertSpace","autoFocus"]),$=s||"default",{button:P}=ee.useContext(Zt),A=c||(P==null?void 0:P.shape)||"default",[B,S]=xt(()=>{if(i&&l)return[i,l];if(s||u){const it=wN[$]||[];return u?["danger",it[1]]:it}return P!=null&&P.color&&(P!=null&&P.variant)?[P.color,P.variant]:["default","outlined"]},[s,i,l,u,P==null?void 0:P.variant,P==null?void 0:P.color]),I=B==="danger"?"dangerous":B,{getPrefixCls:N,direction:F,autoInsertSpace:M,className:_,style:X,classNames:H,styles:q}=Ro("button"),Z=(r=x??M)!==null&&r!==void 0?r:!0,te=N("btn",a),[z,Y,V]=fN(te),U=Rr(No),K=h??U,W=Rr(EC),re=xt(()=>xN(o),[o]),[G,J]=yt(re.loading),[oe,se]=yt(!1),ge=qe(null),Ee=sa(t,ge),je=Lw.count(m)===1&&!b&&!Lc(S),ve=qe(!0);ee.useEffect(()=>(ve.current=!1,()=>{ve.current=!0}),[]),Wt(()=>{let it=null;re.delay>0?it=setTimeout(()=>{it=null,J(!0)},re.delay):J(re.loading);function Ue(){it&&(clearTimeout(it),it=null)}return Ue},[re.delay,re.loading]),Ot(()=>{if(!ge.current||!Z)return;const it=ge.current.textContent||"";je&&mf(it)?oe||se(!0):oe&&se(!1)}),Ot(()=>{O&&ge.current&&ge.current.focus()},[]);const ye=ee.useCallback(it=>{var Ue;if(G||K){it.preventDefault();return}(Ue=e.onClick)===null||Ue===void 0||Ue.call(e,it)},[e.onClick,G,K]),{compactSize:ke,compactItemClassnames:we}=$u(te,F),De={large:"lg",small:"sm",middle:void 0},Ne=fa(it=>{var Ue,nt;return(nt=(Ue=f??ke)!==null&&Ue!==void 0?Ue:W)!==null&&nt!==void 0?nt:it}),Oe=Ne&&(n=De[Ne])!==null&&n!==void 0?n:"",Xe=G?"loading":b,Le=fn(j,["navigate"]),Fe=pe(te,Y,V,{[`${te}-${A}`]:A!=="default"&&A,[`${te}-${$}`]:$,[`${te}-dangerous`]:u,[`${te}-color-${I}`]:I,[`${te}-variant-${S}`]:S,[`${te}-${Oe}`]:Oe,[`${te}-icon-only`]:!m&&m!==0&&!!Xe,[`${te}-background-ghost`]:C&&!Lc(S),[`${te}-loading`]:G,[`${te}-two-chinese-chars`]:oe&&Z&&!G,[`${te}-block`]:D,[`${te}-rtl`]:F==="rtl",[`${te}-icon-end`]:y==="end"},we,v,g,_),fe=Object.assign(Object.assign({},X),E),Be=pe(k==null?void 0:k.icon,H.icon),We=Object.assign(Object.assign({},(p==null?void 0:p.icon)||{}),q.icon||{}),Ye=b&&!G?ee.createElement(hf,{prefixCls:te,className:Be,style:We},b):o&&typeof o=="object"&&o.icon?ee.createElement(hf,{prefixCls:te,className:Be,style:We},o.icon):ee.createElement(c5,{existIcon:!!b,prefixCls:te,loading:G,mount:ve.current}),Ve=m||m===0?u5(m,je&&Z):null;if(Le.href!==void 0)return z(ee.createElement("a",Object.assign({},Le,{className:pe(Fe,{[`${te}-disabled`]:K}),href:K?void 0:Le.href,style:fe,onClick:ye,ref:Ee,tabIndex:K?-1:0}),Ye,Ve));let Te=ee.createElement("button",Object.assign({},j,{type:w,className:Fe,style:fe,onClick:ye,disabled:K,ref:Ee}),Ye,Ve,we&&ee.createElement(yN,{prefixCls:te}));return Lc(S)||(Te=ee.createElement(Kp,{component:"Button",disabled:G},Te)),z(Te)}),Ya=EN;Ya.Group=l5;Ya.__ANT_BUTTON=!0;var BC=d.createContext(null),Iv=[];function kN(e,t){var r=d.useState(function(){if(!Xr())return null;var v=document.createElement("div");return v}),n=ce(r,1),o=n[0],a=d.useRef(!1),i=d.useContext(BC),l=d.useState(Iv),s=ce(l,2),u=s[0],c=s[1],f=i||(a.current?void 0:function(v){c(function(g){var m=[v].concat(Ie(g));return m})});function p(){o.parentElement||document.body.appendChild(o),a.current=!0}function h(){var v;(v=o.parentElement)===null||v===void 0||v.removeChild(o),a.current=!1}return Wt(function(){return e?i?i(p):p():h(),h},[e]),Wt(function(){u.length&&(u.forEach(function(v){return v()}),c(Iv))},[u]),[o,f]}var qc;function OC(e){var t="rc-scrollbar-measure-".concat(Math.random().toString(36).substring(7)),r=document.createElement("div");r.id=t;var n=r.style;n.position="absolute",n.left="0",n.top="0",n.width="100px",n.height="100px",n.overflow="scroll";var o,a;if(e){var i=getComputedStyle(e);n.scrollbarColor=i.scrollbarColor,n.scrollbarWidth=i.scrollbarWidth;var l=getComputedStyle(e,"::-webkit-scrollbar"),s=parseInt(l.width,10),u=parseInt(l.height,10);try{var c=s?"width: ".concat(l.width,";"):"",f=u?"height: ".concat(l.height,";"):"";go(`
|
|
291
|
+
#`.concat(t,`::-webkit-scrollbar {
|
|
292
|
+
`).concat(c,`
|
|
293
|
+
`).concat(f,`
|
|
294
|
+
}`),t)}catch(v){console.error(v),o=s,a=u}}document.body.appendChild(r);var p=e&&o&&!isNaN(o)?o:r.offsetWidth-r.clientWidth,h=e&&a&&!isNaN(a)?a:r.offsetHeight-r.clientHeight;return document.body.removeChild(r),nl(t),{width:p,height:h}}function Rv(e){return typeof document>"u"?0:(qc===void 0&&(qc=OC()),qc.width)}function bf(e){return typeof document>"u"||!e||!(e instanceof Element)?{width:0,height:0}:OC(e)}function DN(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}var SN="rc-util-locker-".concat(Date.now()),Mv=0;function $N(e){var t=!!e,r=d.useState(function(){return Mv+=1,"".concat(SN,"_").concat(Mv)}),n=ce(r,1),o=n[0];Wt(function(){if(t){var a=bf(document.body).width,i=DN();go(`
|
|
295
|
+
html body {
|
|
296
|
+
overflow-y: hidden;
|
|
297
|
+
`.concat(i?"width: calc(100% - ".concat(a,"px);"):"",`
|
|
298
|
+
}`),o)}else nl(o);return function(){nl(o)}},[t,o])}var BN=!1;function ON(e){return BN}var Tv=function(e){return e===!1?!1:!Xr()||!e?null:typeof e=="string"?document.querySelector(e):typeof e=="function"?e():e},AC=d.forwardRef(function(e,t){var r=e.open,n=e.autoLock,o=e.getContainer;e.debug;var a=e.autoDestroy,i=a===void 0?!0:a,l=e.children,s=d.useState(r),u=ce(s,2),c=u[0],f=u[1],p=c||r;d.useEffect(function(){(i||r)&&f(r)},[r,i]);var h=d.useState(function(){return Tv(o)}),v=ce(h,2),g=v[0],m=v[1];d.useEffect(function(){var $=Tv(o);m($??null)});var b=kN(p&&!g),y=ce(b,2),C=y[0],D=y[1],w=g??C;$N(n&&r&&Xr()&&(w===C||w===document.body));var k=null;if(l&&Zn(l)&&t){var E=l;k=E.ref}var x=sa(k,t);if(!p||!Xr()||g===void 0)return null;var O=w===!1||ON(),j=l;return t&&(j=d.cloneElement(l,{ref:x})),d.createElement(BC.Provider,{value:D},O?j:Pb(j,w))});function AN(){var e=L({},d);return e.useId}var zv=0,_v=AN();const Qp=_v?(function(e){var t=_v();return e||t}):(function(e){var t=d.useState("ssr-id"),r=ce(t,2),n=r[0],o=r[1];return d.useEffect(function(){var a=zv;zv+=1,o("rc_unique_".concat(a))},[]),e||n});var qo="RC_FORM_INTERNAL_HOOKS",Qt=function(){lr(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},Za=d.createContext({getFieldValue:Qt,getFieldsValue:Qt,getFieldError:Qt,getFieldWarning:Qt,getFieldsError:Qt,isFieldsTouched:Qt,isFieldTouched:Qt,isFieldValidating:Qt,isFieldsValidating:Qt,resetFields:Qt,setFields:Qt,setFieldValue:Qt,setFieldsValue:Qt,validateFields:Qt,submit:Qt,getInternalHooks:function(){return Qt(),{dispatch:Qt,initEntityValue:Qt,registerField:Qt,useSubscribe:Qt,setInitialValues:Qt,destroyForm:Qt,setCallbacks:Qt,registerWatch:Qt,getFields:Qt,setValidateMessages:Qt,setPreserve:Qt,getInitialValue:Qt}}}),Gs=d.createContext(null);function yf(e){return e==null?[]:Array.isArray(e)?e:[e]}function FN(e){return e&&!!e._init}function Cf(){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 e=JSON.parse(JSON.stringify(this));return e.clone=this.clone,e}}}var xf=Cf();function NN(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function PN(e,t,r){if(Op())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var o=new(e.bind.apply(e,n));return r&&el(o,r.prototype),o}function wf(e){var t=typeof Map=="function"?new Map:void 0;return wf=function(r){if(r===null||!NN(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(t!==void 0){if(t.has(r))return t.get(r);t.set(r,n)}function n(){return PN(r,arguments,tl(this).constructor)}return n.prototype=Object.create(r.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),el(n,r)},wf(e)}var jN=/%[sdj%]/g,IN=function(){};function Ef(e){if(!e||!e.length)return null;var t={};return e.forEach(function(r){var n=r.field;t[n]=t[n]||[],t[n].push(r)}),t}function bn(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];var o=0,a=r.length;if(typeof e=="function")return e.apply(null,r);if(typeof e=="string"){var i=e.replace(jN,function(l){if(l==="%%")return"%";if(o>=a)return l;switch(l){case"%s":return String(r[o++]);case"%d":return Number(r[o++]);case"%j":try{return JSON.stringify(r[o++])}catch{return"[Circular]"}break;default:return l}});return i}return e}function RN(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function Or(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||RN(t)&&typeof e=="string"&&!e)}function MN(e,t,r){var n=[],o=0,a=e.length;function i(l){n.push.apply(n,Ie(l||[])),o++,o===a&&r(n)}e.forEach(function(l){t(l,i)})}function Lv(e,t,r){var n=0,o=e.length;function a(i){if(i&&i.length){r(i);return}var l=n;n=n+1,l<o?t(e[l],a):r([])}a([])}function TN(e){var t=[];return Object.keys(e).forEach(function(r){t.push.apply(t,Ie(e[r]||[]))}),t}var Hv=(function(e){no(r,e);var t=oo(r);function r(n,o){var a;return vr(this,r),a=t.call(this,"Async Validation Error"),T(et(a),"errors",void 0),T(et(a),"fields",void 0),a.errors=n,a.fields=o,a}return br(r)})(wf(Error));function zN(e,t,r,n,o){if(t.first){var a=new Promise(function(p,h){var v=function(m){return n(m),m.length?h(new Hv(m,Ef(m))):p(o)},g=TN(e);Lv(g,r,v)});return a.catch(function(p){return p}),a}var i=t.firstFields===!0?Object.keys(e):t.firstFields||[],l=Object.keys(e),s=l.length,u=0,c=[],f=new Promise(function(p,h){var v=function(g){if(c.push.apply(c,g),u++,u===s)return n(c),c.length?h(new Hv(c,Ef(c))):p(o)};l.length||(n(c),p(o)),l.forEach(function(g){var m=e[g];i.indexOf(g)!==-1?Lv(m,r,v):MN(m,r,v)})});return f.catch(function(p){return p}),f}function _N(e){return!!(e&&e.message!==void 0)}function LN(e,t){for(var r=e,n=0;n<t.length;n++){if(r==null)return r;r=r[t[n]]}return r}function Wv(e,t){return function(r){var n;return e.fullFields?n=LN(t,e.fullFields):n=t[r.field||e.fullField],_N(r)?(r.field=r.field||e.fullField,r.fieldValue=n,r):{message:typeof r=="function"?r():r,fieldValue:n,field:r.field||e.fullField}}}function Kv(e,t){if(t){for(var r in t)if(t.hasOwnProperty(r)){var n=t[r];at(n)==="object"&&at(e[r])==="object"?e[r]=L(L({},e[r]),n):e[r]=n}}return e}var ga="enum",HN=function(e,t,r,n,o){e[ga]=Array.isArray(e[ga])?e[ga]:[],e[ga].indexOf(t)===-1&&n.push(bn(o.messages[ga],e.fullField,e[ga].join(", ")))},WN=function(e,t,r,n,o){if(e.pattern){if(e.pattern instanceof RegExp)e.pattern.lastIndex=0,e.pattern.test(t)||n.push(bn(o.messages.pattern.mismatch,e.fullField,t,e.pattern));else if(typeof e.pattern=="string"){var a=new RegExp(e.pattern);a.test(t)||n.push(bn(o.messages.pattern.mismatch,e.fullField,t,e.pattern))}}},KN=function(e,t,r,n,o){var a=typeof e.len=="number",i=typeof e.min=="number",l=typeof e.max=="number",s=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,u=t,c=null,f=typeof t=="number",p=typeof t=="string",h=Array.isArray(t);if(f?c="number":p?c="string":h&&(c="array"),!c)return!1;h&&(u=t.length),p&&(u=t.replace(s,"_").length),a?u!==e.len&&n.push(bn(o.messages[c].len,e.fullField,e.len)):i&&!l&&u<e.min?n.push(bn(o.messages[c].min,e.fullField,e.min)):l&&!i&&u>e.max?n.push(bn(o.messages[c].max,e.fullField,e.max)):i&&l&&(u<e.min||u>e.max)&&n.push(bn(o.messages[c].range,e.fullField,e.min,e.max))},FC=function(e,t,r,n,o,a){e.required&&(!r.hasOwnProperty(e.field)||Or(t,a||e.type))&&n.push(bn(o.messages.required,e.fullField))},Zl;const qN=(function(){if(Zl)return Zl;var e="[a-fA-F\\d:]",t=function(w){return w&&w.includeBoundaries?"(?:(?<=\\s|^)(?=".concat(e,")|(?<=").concat(e,")(?=\\s|$))"):""},r="(?: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}",o=["(?:".concat(n,":){7}(?:").concat(n,"|:)"),"(?:".concat(n,":){6}(?:").concat(r,"|:").concat(n,"|:)"),"(?:".concat(n,":){5}(?::").concat(r,"|(?::").concat(n,"){1,2}|:)"),"(?:".concat(n,":){4}(?:(?::").concat(n,"){0,1}:").concat(r,"|(?::").concat(n,"){1,3}|:)"),"(?:".concat(n,":){3}(?:(?::").concat(n,"){0,2}:").concat(r,"|(?::").concat(n,"){1,4}|:)"),"(?:".concat(n,":){2}(?:(?::").concat(n,"){0,3}:").concat(r,"|(?::").concat(n,"){1,5}|:)"),"(?:".concat(n,":){1}(?:(?::").concat(n,"){0,4}:").concat(r,"|(?::").concat(n,"){1,6}|:)"),"(?::(?:(?::".concat(n,"){0,5}:").concat(r,"|(?::").concat(n,"){1,7}|:))")],a="(?:%[0-9a-zA-Z]{1,})?",i="(?:".concat(o.join("|"),")").concat(a),l=new RegExp("(?:^".concat(r,"$)|(?:^").concat(i,"$)")),s=new RegExp("^".concat(r,"$")),u=new RegExp("^".concat(i,"$")),c=function(w){return w&&w.exact?l:new RegExp("(?:".concat(t(w)).concat(r).concat(t(w),")|(?:").concat(t(w)).concat(i).concat(t(w),")"),"g")};c.v4=function(w){return w&&w.exact?s:new RegExp("".concat(t(w)).concat(r).concat(t(w)),"g")},c.v6=function(w){return w&&w.exact?u:new RegExp("".concat(t(w)).concat(i).concat(t(w)),"g")};var f="(?:(?:[a-z]+:)?//)",p="(?:\\S+(?::\\S*)?@)?",h=c.v4().source,v=c.v6().source,g="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",m="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",b="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",y="(?::\\d{2,5})?",C='(?:[/?#][^\\s"]*)?',D="(?:".concat(f,"|www\\.)").concat(p,"(?:localhost|").concat(h,"|").concat(v,"|").concat(g).concat(m).concat(b,")").concat(y).concat(C);return Zl=new RegExp("(?:^".concat(D,"$)"),"i"),Zl});var qv={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},Bi={integer:function(e){return Bi.number(e)&&parseInt(e,10)===e},float:function(e){return Bi.number(e)&&!Bi.integer(e)},array:function(e){return Array.isArray(e)},regexp:function(e){if(e instanceof RegExp)return!0;try{return!!new RegExp(e)}catch{return!1}},date:function(e){return typeof e.getTime=="function"&&typeof e.getMonth=="function"&&typeof e.getYear=="function"&&!isNaN(e.getTime())},number:function(e){return isNaN(e)?!1:typeof e=="number"},object:function(e){return at(e)==="object"&&!Bi.array(e)},method:function(e){return typeof e=="function"},email:function(e){return typeof e=="string"&&e.length<=320&&!!e.match(qv.email)},url:function(e){return typeof e=="string"&&e.length<=2048&&!!e.match(qN())},hex:function(e){return typeof e=="string"&&!!e.match(qv.hex)}},VN=function(e,t,r,n,o){if(e.required&&t===void 0){FC(e,t,r,n,o);return}var a=["integer","float","array","regexp","object","method","email","number","date","url","hex"],i=e.type;a.indexOf(i)>-1?Bi[i](t)||n.push(bn(o.messages.types[i],e.fullField,e.type)):i&&at(t)!==e.type&&n.push(bn(o.messages.types[i],e.fullField,e.type))},GN=function(e,t,r,n,o){(/^\s+$/.test(t)||t==="")&&n.push(bn(o.messages.whitespace,e.fullField))};const zt={required:FC,whitespace:GN,type:VN,range:KN,enum:HN,pattern:WN};var XN=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o)}r(a)},UN=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(t==null&&!e.required)return r();zt.required(e,t,n,a,o,"array"),t!=null&&(zt.type(e,t,n,a,o),zt.range(e,t,n,a,o))}r(a)},YN=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&zt.type(e,t,n,a,o)}r(a)},ZN=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t,"date")&&!e.required)return r();if(zt.required(e,t,n,a,o),!Or(t,"date")){var l;t instanceof Date?l=t:l=new Date(t),zt.type(e,l,n,a,o),l&&zt.range(e,l.getTime(),n,a,o)}}r(a)},JN="enum",QN=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&zt[JN](e,t,n,a,o)}r(a)},eP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&(zt.type(e,t,n,a,o),zt.range(e,t,n,a,o))}r(a)},tP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&(zt.type(e,t,n,a,o),zt.range(e,t,n,a,o))}r(a)},rP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&zt.type(e,t,n,a,o)}r(a)},nP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(t===""&&(t=void 0),Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&(zt.type(e,t,n,a,o),zt.range(e,t,n,a,o))}r(a)},oP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),t!==void 0&&zt.type(e,t,n,a,o)}r(a)},aP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t,"string")&&!e.required)return r();zt.required(e,t,n,a,o),Or(t,"string")||zt.pattern(e,t,n,a,o)}r(a)},iP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t)&&!e.required)return r();zt.required(e,t,n,a,o),Or(t)||zt.type(e,t,n,a,o)}r(a)},lP=function(e,t,r,n,o){var a=[],i=Array.isArray(t)?"array":at(t);zt.required(e,t,n,a,o,i),r(a)},sP=function(e,t,r,n,o){var a=[],i=e.required||!e.required&&n.hasOwnProperty(e.field);if(i){if(Or(t,"string")&&!e.required)return r();zt.required(e,t,n,a,o,"string"),Or(t,"string")||(zt.type(e,t,n,a,o),zt.range(e,t,n,a,o),zt.pattern(e,t,n,a,o),e.whitespace===!0&&zt.whitespace(e,t,n,a,o))}r(a)},Vc=function(e,t,r,n,o){var a=e.type,i=[],l=e.required||!e.required&&n.hasOwnProperty(e.field);if(l){if(Or(t,a)&&!e.required)return r();zt.required(e,t,n,i,o,a),Or(t,a)||zt.type(e,t,n,i,o)}r(i)};const zi={string:sP,method:rP,number:nP,boolean:YN,regexp:iP,integer:tP,float:eP,array:UN,object:oP,enum:QN,pattern:aP,date:ZN,url:Vc,hex:Vc,email:Vc,required:lP,any:XN};var El=(function(){function e(t){vr(this,e),T(this,"rules",null),T(this,"_messages",xf),this.define(t)}return br(e,[{key:"define",value:function(t){var r=this;if(!t)throw new Error("Cannot configure a schema with no rules");if(at(t)!=="object"||Array.isArray(t))throw new Error("Rules must be an object");this.rules={},Object.keys(t).forEach(function(n){var o=t[n];r.rules[n]=Array.isArray(o)?o:[o]})}},{key:"messages",value:function(t){return t&&(this._messages=Kv(Cf(),t)),this._messages}},{key:"validate",value:function(t){var r=this,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},a=t,i=n,l=o;if(typeof i=="function"&&(l=i,i={}),!this.rules||Object.keys(this.rules).length===0)return l&&l(null,a),Promise.resolve(a);function s(h){var v=[],g={};function m(y){if(Array.isArray(y)){var C;v=(C=v).concat.apply(C,Ie(y))}else v.push(y)}for(var b=0;b<h.length;b++)m(h[b]);v.length?(g=Ef(v),l(v,g)):l(null,a)}if(i.messages){var u=this.messages();u===xf&&(u=Cf()),Kv(u,i.messages),i.messages=u}else i.messages=this.messages();var c={},f=i.keys||Object.keys(this.rules);f.forEach(function(h){var v=r.rules[h],g=a[h];v.forEach(function(m){var b=m;typeof b.transform=="function"&&(a===t&&(a=L({},a)),g=a[h]=b.transform(g),g!=null&&(b.type=b.type||(Array.isArray(g)?"array":at(g)))),typeof b=="function"?b={validator:b}:b=L({},b),b.validator=r.getValidationMethod(b),b.validator&&(b.field=h,b.fullField=b.fullField||h,b.type=r.getType(b),c[h]=c[h]||[],c[h].push({rule:b,value:g,source:a,field:h}))})});var p={};return zN(c,i,function(h,v){var g=h.rule,m=(g.type==="object"||g.type==="array")&&(at(g.fields)==="object"||at(g.defaultField)==="object");m=m&&(g.required||!g.required&&h.value),g.field=h.field;function b(k,E){return L(L({},E),{},{fullField:"".concat(g.fullField,".").concat(k),fullFields:g.fullFields?[].concat(Ie(g.fullFields),[k]):[k]})}function y(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],E=Array.isArray(k)?k:[k];!i.suppressWarning&&E.length&&e.warning("async-validator:",E),E.length&&g.message!==void 0&&(E=[].concat(g.message));var x=E.map(Wv(g,a));if(i.first&&x.length)return p[g.field]=1,v(x);if(!m)v(x);else{if(g.required&&!h.value)return g.message!==void 0?x=[].concat(g.message).map(Wv(g,a)):i.error&&(x=[i.error(g,bn(i.messages.required,g.field))]),v(x);var O={};g.defaultField&&Object.keys(h.value).map(function(P){O[P]=g.defaultField}),O=L(L({},O),h.rule.fields);var j={};Object.keys(O).forEach(function(P){var A=O[P],B=Array.isArray(A)?A:[A];j[P]=B.map(b.bind(null,P))});var $=new e(j);$.messages(i.messages),h.rule.options&&(h.rule.options.messages=i.messages,h.rule.options.error=i.error),$.validate(h.value,h.rule.options||i,function(P){var A=[];x&&x.length&&A.push.apply(A,Ie(x)),P&&P.length&&A.push.apply(A,Ie(P)),v(A.length?A:null)})}}var C;if(g.asyncValidator)C=g.asyncValidator(g,h.value,y,h.source,i);else if(g.validator){try{C=g.validator(g,h.value,y,h.source,i)}catch(k){var D,w;(D=(w=console).error)===null||D===void 0||D.call(w,k),i.suppressValidatorError||setTimeout(function(){throw k},0),y(k.message)}C===!0?y():C===!1?y(typeof g.message=="function"?g.message(g.fullField||g.field):g.message||"".concat(g.fullField||g.field," fails")):C instanceof Array?y(C):C instanceof Error&&y(C.message)}C&&C.then&&C.then(function(){return y()},function(k){return y(k)})},function(h){s(h)},a)}},{key:"getType",value:function(t){if(t.type===void 0&&t.pattern instanceof RegExp&&(t.type="pattern"),typeof t.validator!="function"&&t.type&&!zi.hasOwnProperty(t.type))throw new Error(bn("Unknown rule type %s",t.type));return t.type||"string"}},{key:"getValidationMethod",value:function(t){if(typeof t.validator=="function")return t.validator;var r=Object.keys(t),n=r.indexOf("message");return n!==-1&&r.splice(n,1),r.length===1&&r[0]==="required"?zi.required:zi[this.getType(t)]||void 0}}]),e})();T(El,"register",function(e,t){if(typeof t!="function")throw new Error("Cannot register a validator by type, validator is not a function");zi[e]=t});T(El,"warning",IN);T(El,"messages",xf);T(El,"validators",zi);var hn="'${name}' is not a valid ${type}",NC={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:hn,method:hn,array:hn,object:hn,number:hn,date:hn,boolean:hn,integer:hn,float:hn,regexp:hn,email:hn,url:hn,hex:hn},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}"}},Vv=El;function uP(e,t){return e.replace(/\\?\$\{\w+\}/g,function(r){if(r.startsWith("\\"))return r.slice(1);var n=r.slice(2,-1);return t[n]})}var Gv="CODE_LOGIC_ERROR";function kf(e,t,r,n,o){return Df.apply(this,arguments)}function Df(){return Df=da(Ur().mark(function e(t,r,n,o,a){var i,l,s,u,c,f,p,h,v;return Ur().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return i=L({},n),delete i.ruleIndex,Vv.warning=function(){},i.validator&&(l=i.validator,i.validator=function(){try{return l.apply(void 0,arguments)}catch(m){return console.error(m),Promise.reject(Gv)}}),s=null,i&&i.type==="array"&&i.defaultField&&(s=i.defaultField,delete i.defaultField),u=new Vv(T({},t,[i])),c=$a(NC,o.validateMessages),u.messages(c),f=[],g.prev=10,g.next=13,Promise.resolve(u.validate(T({},t,r),L({},o)));case 13:g.next=18;break;case 15:g.prev=15,g.t0=g.catch(10),g.t0.errors&&(f=g.t0.errors.map(function(m,b){var y=m.message,C=y===Gv?c.default:y;return d.isValidElement(C)?d.cloneElement(C,{key:"error_".concat(b)}):C}));case 18:if(!(!f.length&&s)){g.next=23;break}return g.next=21,Promise.all(r.map(function(m,b){return kf("".concat(t,".").concat(b),m,s,o,a)}));case 21:return p=g.sent,g.abrupt("return",p.reduce(function(m,b){return[].concat(Ie(m),Ie(b))},[]));case 23:return h=L(L({},n),{},{name:t,enum:(n.enum||[]).join(", ")},a),v=f.map(function(m){return typeof m=="string"?uP(m,h):m}),g.abrupt("return",v);case 26:case"end":return g.stop()}},e,null,[[10,15]])})),Df.apply(this,arguments)}function cP(e,t,r,n,o,a){var i=e.join("."),l=r.map(function(c,f){var p=c.validator,h=L(L({},c),{},{ruleIndex:f});return p&&(h.validator=function(v,g,m){var b=!1,y=function(){for(var D=arguments.length,w=new Array(D),k=0;k<D;k++)w[k]=arguments[k];Promise.resolve().then(function(){lr(!b,"Your validator function has already return a promise. `callback` will be ignored."),b||m.apply(void 0,w)})},C=p(v,g,y);b=C&&typeof C.then=="function"&&typeof C.catch=="function",lr(b,"`callback` is deprecated. Please return a promise instead."),b&&C.then(function(){m()}).catch(function(D){m(D||" ")})}),h}).sort(function(c,f){var p=c.warningOnly,h=c.ruleIndex,v=f.warningOnly,g=f.ruleIndex;return!!p==!!v?h-g:p?1:-1}),s;if(o===!0)s=new Promise((function(){var c=da(Ur().mark(function f(p,h){var v,g,m;return Ur().wrap(function(b){for(;;)switch(b.prev=b.next){case 0:v=0;case 1:if(!(v<l.length)){b.next=12;break}return g=l[v],b.next=5,kf(i,t,g,n,a);case 5:if(m=b.sent,!m.length){b.next=9;break}return h([{errors:m,rule:g}]),b.abrupt("return");case 9:v+=1,b.next=1;break;case 12:p([]);case 13:case"end":return b.stop()}},f)}));return function(f,p){return c.apply(this,arguments)}})());else{var u=l.map(function(c){return kf(i,t,c,n,a).then(function(f){return{errors:f,rule:c}})});s=(o?fP(u):dP(u)).then(function(c){return Promise.reject(c)})}return s.catch(function(c){return c}),s}function dP(e){return Sf.apply(this,arguments)}function Sf(){return Sf=da(Ur().mark(function e(t){return Ur().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.abrupt("return",Promise.all(t).then(function(n){var o,a=(o=[]).concat.apply(o,Ie(n));return a}));case 1:case"end":return r.stop()}},e)})),Sf.apply(this,arguments)}function fP(e){return $f.apply(this,arguments)}function $f(){return $f=da(Ur().mark(function e(t){var r;return Ur().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return r=0,n.abrupt("return",new Promise(function(o){t.forEach(function(a){a.then(function(i){i.errors.length&&o([i]),r+=1,r===t.length&&o([])})})}));case 2:case"end":return n.stop()}},e)})),$f.apply(this,arguments)}function gr(e){return yf(e)}function Xv(e,t){var r={};return t.forEach(function(n){var o=vn(e,n);r=jn(r,n,o)}),r}function Pa(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return e&&e.some(function(n){return PC(t,n,r)})}function PC(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return!e||!t||!r&&e.length!==t.length?!1:t.every(function(n,o){return e[o]===n})}function pP(e,t){if(e===t)return!0;if(!e&&t||e&&!t||!e||!t||at(e)!=="object"||at(t)!=="object")return!1;var r=Object.keys(e),n=Object.keys(t),o=new Set([].concat(r,n));return Ie(o).every(function(a){var i=e[a],l=t[a];return typeof i=="function"&&typeof l=="function"?!0:i===l})}function mP(e){var t=arguments.length<=1?void 0:arguments[1];return t&&t.target&&at(t.target)==="object"&&e in t.target?t.target[e]:t}function Uv(e,t,r){var n=e.length;if(t<0||t>=n||r<0||r>=n)return e;var o=e[t],a=t-r;return a>0?[].concat(Ie(e.slice(0,r)),[o],Ie(e.slice(r,t)),Ie(e.slice(t+1,n))):a<0?[].concat(Ie(e.slice(0,t)),Ie(e.slice(t+1,r+1)),[o],Ie(e.slice(r+1,n))):e}var hP=["name"],Dn=[];function Gc(e,t,r,n,o,a){return typeof e=="function"?e(t,r,"source"in a?{source:a.source}:{}):n!==o}var em=(function(e){no(r,e);var t=oo(r);function r(n){var o;if(vr(this,r),o=t.call(this,n),T(et(o),"state",{resetCount:0}),T(et(o),"cancelRegisterFunc",null),T(et(o),"mounted",!1),T(et(o),"touched",!1),T(et(o),"dirty",!1),T(et(o),"validatePromise",void 0),T(et(o),"prevValidating",void 0),T(et(o),"errors",Dn),T(et(o),"warnings",Dn),T(et(o),"cancelRegister",function(){var s=o.props,u=s.preserve,c=s.isListField,f=s.name;o.cancelRegisterFunc&&o.cancelRegisterFunc(c,u,gr(f)),o.cancelRegisterFunc=null}),T(et(o),"getNamePath",function(){var s=o.props,u=s.name,c=s.fieldContext,f=c.prefixName,p=f===void 0?[]:f;return u!==void 0?[].concat(Ie(p),Ie(u)):[]}),T(et(o),"getRules",function(){var s=o.props,u=s.rules,c=u===void 0?[]:u,f=s.fieldContext;return c.map(function(p){return typeof p=="function"?p(f):p})}),T(et(o),"refresh",function(){o.mounted&&o.setState(function(s){var u=s.resetCount;return{resetCount:u+1}})}),T(et(o),"metaCache",null),T(et(o),"triggerMetaEvent",function(s){var u=o.props.onMetaChange;if(u){var c=L(L({},o.getMeta()),{},{destroy:s});Jn(o.metaCache,c)||u(c),o.metaCache=c}else o.metaCache=null}),T(et(o),"onStoreChange",function(s,u,c){var f=o.props,p=f.shouldUpdate,h=f.dependencies,v=h===void 0?[]:h,g=f.onReset,m=c.store,b=o.getNamePath(),y=o.getValue(s),C=o.getValue(m),D=u&&Pa(u,b);switch(c.type==="valueUpdate"&&c.source==="external"&&!Jn(y,C)&&(o.touched=!0,o.dirty=!0,o.validatePromise=null,o.errors=Dn,o.warnings=Dn,o.triggerMetaEvent()),c.type){case"reset":if(!u||D){o.touched=!1,o.dirty=!1,o.validatePromise=void 0,o.errors=Dn,o.warnings=Dn,o.triggerMetaEvent(),g==null||g(),o.refresh();return}break;case"remove":{if(p&&Gc(p,s,m,y,C,c)){o.reRender();return}break}case"setField":{var w=c.data;if(D){"touched"in w&&(o.touched=w.touched),"validating"in w&&!("originRCField"in w)&&(o.validatePromise=w.validating?Promise.resolve([]):null),"errors"in w&&(o.errors=w.errors||Dn),"warnings"in w&&(o.warnings=w.warnings||Dn),o.dirty=!0,o.triggerMetaEvent(),o.reRender();return}else if("value"in w&&Pa(u,b,!0)){o.reRender();return}if(p&&!b.length&&Gc(p,s,m,y,C,c)){o.reRender();return}break}case"dependenciesUpdate":{var k=v.map(gr);if(k.some(function(E){return Pa(c.relatedFields,E)})){o.reRender();return}break}default:if(D||(!v.length||b.length||p)&&Gc(p,s,m,y,C,c)){o.reRender();return}break}p===!0&&o.reRender()}),T(et(o),"validateRules",function(s){var u=o.getNamePath(),c=o.getValue(),f=s||{},p=f.triggerName,h=f.validateOnly,v=h===void 0?!1:h,g=Promise.resolve().then(da(Ur().mark(function m(){var b,y,C,D,w,k,E;return Ur().wrap(function(x){for(;;)switch(x.prev=x.next){case 0:if(o.mounted){x.next=2;break}return x.abrupt("return",[]);case 2:if(b=o.props,y=b.validateFirst,C=y===void 0?!1:y,D=b.messageVariables,w=b.validateDebounce,k=o.getRules(),p&&(k=k.filter(function(O){return O}).filter(function(O){var j=O.validateTrigger;if(!j)return!0;var $=yf(j);return $.includes(p)})),!(w&&p)){x.next=10;break}return x.next=8,new Promise(function(O){setTimeout(O,w)});case 8:if(o.validatePromise===g){x.next=10;break}return x.abrupt("return",[]);case 10:return E=cP(u,c,k,s,C,D),E.catch(function(O){return O}).then(function(){var O=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Dn;if(o.validatePromise===g){var j;o.validatePromise=null;var $=[],P=[];(j=O.forEach)===null||j===void 0||j.call(O,function(A){var B=A.rule.warningOnly,S=A.errors,I=S===void 0?Dn:S;B?P.push.apply(P,Ie(I)):$.push.apply($,Ie(I))}),o.errors=$,o.warnings=P,o.triggerMetaEvent(),o.reRender()}}),x.abrupt("return",E);case 13:case"end":return x.stop()}},m)})));return v||(o.validatePromise=g,o.dirty=!0,o.errors=Dn,o.warnings=Dn,o.triggerMetaEvent(),o.reRender()),g}),T(et(o),"isFieldValidating",function(){return!!o.validatePromise}),T(et(o),"isFieldTouched",function(){return o.touched}),T(et(o),"isFieldDirty",function(){if(o.dirty||o.props.initialValue!==void 0)return!0;var s=o.props.fieldContext,u=s.getInternalHooks(qo),c=u.getInitialValue;return c(o.getNamePath())!==void 0}),T(et(o),"getErrors",function(){return o.errors}),T(et(o),"getWarnings",function(){return o.warnings}),T(et(o),"isListField",function(){return o.props.isListField}),T(et(o),"isList",function(){return o.props.isList}),T(et(o),"isPreserve",function(){return o.props.preserve}),T(et(o),"getMeta",function(){o.prevValidating=o.isFieldValidating();var s={touched:o.isFieldTouched(),validating:o.prevValidating,errors:o.errors,warnings:o.warnings,name:o.getNamePath(),validated:o.validatePromise===null};return s}),T(et(o),"getOnlyChild",function(s){if(typeof s=="function"){var u=o.getMeta();return L(L({},o.getOnlyChild(s(o.getControlled(),u,o.props.fieldContext))),{},{isFunction:!0})}var c=Ln(s);return c.length!==1||!d.isValidElement(c[0])?{child:c,isFunction:!1}:{child:c[0],isFunction:!1}}),T(et(o),"getValue",function(s){var u=o.props.fieldContext.getFieldsValue,c=o.getNamePath();return vn(s||u(!0),c)}),T(et(o),"getControlled",function(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},u=o.props,c=u.name,f=u.trigger,p=u.validateTrigger,h=u.getValueFromEvent,v=u.normalize,g=u.valuePropName,m=u.getValueProps,b=u.fieldContext,y=p!==void 0?p:b.validateTrigger,C=o.getNamePath(),D=b.getInternalHooks,w=b.getFieldsValue,k=D(qo),E=k.dispatch,x=o.getValue(),O=m||function(B){return T({},g,B)},j=s[f],$=c!==void 0?O(x):{},P=L(L({},s),$);P[f]=function(){o.touched=!0,o.dirty=!0,o.triggerMetaEvent();for(var B,S=arguments.length,I=new Array(S),N=0;N<S;N++)I[N]=arguments[N];h?B=h.apply(void 0,I):B=mP.apply(void 0,[g].concat(I)),v&&(B=v(B,x,w(!0))),B!==x&&E({type:"updateValue",namePath:C,value:B}),j&&j.apply(void 0,I)};var A=yf(y||[]);return A.forEach(function(B){var S=P[B];P[B]=function(){S&&S.apply(void 0,arguments);var I=o.props.rules;I&&I.length&&E({type:"validateField",namePath:C,triggerName:B})}}),P}),n.fieldContext){var a=n.fieldContext.getInternalHooks,i=a(qo),l=i.initEntityValue;l(et(o))}return o}return br(r,[{key:"componentDidMount",value:function(){var n=this.props,o=n.shouldUpdate,a=n.fieldContext;if(this.mounted=!0,a){var i=a.getInternalHooks,l=i(qo),s=l.registerField;this.cancelRegisterFunc=s(this)}o===!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 n=this.state.resetCount,o=this.props.children,a=this.getOnlyChild(o),i=a.child,l=a.isFunction,s;return l?s=i:d.isValidElement(i)?s=d.cloneElement(i,this.getControlled(i.props)):(lr(!i,"`children` of Field is not validate ReactElement."),s=i),d.createElement(d.Fragment,{key:n},s)}}]),r})(d.Component);T(em,"contextType",Za);T(em,"defaultProps",{trigger:"onChange",valuePropName:"value"});function jC(e){var t,r=e.name,n=bt(e,hP),o=d.useContext(Za),a=d.useContext(Gs),i=r!==void 0?gr(r):void 0,l=(t=n.isListField)!==null&&t!==void 0?t:!!a,s="keep";return l||(s="_".concat((i||[]).join("_"))),d.createElement(em,Me({key:s,name:i,isListField:l},n,{fieldContext:o}))}function gP(e){var t=e.name,r=e.initialValue,n=e.children,o=e.rules,a=e.validateTrigger,i=e.isListField,l=d.useContext(Za),s=d.useContext(Gs),u=d.useRef({keys:[],id:0}),c=u.current,f=d.useMemo(function(){var g=gr(l.prefixName)||[];return[].concat(Ie(g),Ie(gr(t)))},[l.prefixName,t]),p=d.useMemo(function(){return L(L({},l),{},{prefixName:f})},[l,f]),h=d.useMemo(function(){return{getKey:function(g){var m=f.length,b=g[m];return[c.keys[b],g.slice(m+1)]}}},[f]);if(typeof n!="function")return lr(!1,"Form.List only accepts function as children."),null;var v=function(g,m,b){var y=b.source;return y==="internal"?!1:g!==m};return d.createElement(Gs.Provider,{value:h},d.createElement(Za.Provider,{value:p},d.createElement(jC,{name:[],shouldUpdate:v,rules:o,validateTrigger:a,initialValue:r,isList:!0,isListField:i??!!s},function(g,m){var b=g.value,y=b===void 0?[]:b,C=g.onChange,D=l.getFieldValue,w=function(){var x=D(f||[]);return x||[]},k={add:function(x,O){var j=w();O>=0&&O<=j.length?(c.keys=[].concat(Ie(c.keys.slice(0,O)),[c.id],Ie(c.keys.slice(O))),C([].concat(Ie(j.slice(0,O)),[x],Ie(j.slice(O))))):(c.keys=[].concat(Ie(c.keys),[c.id]),C([].concat(Ie(j),[x]))),c.id+=1},remove:function(x){var O=w(),j=new Set(Array.isArray(x)?x:[x]);j.size<=0||(c.keys=c.keys.filter(function($,P){return!j.has(P)}),C(O.filter(function($,P){return!j.has(P)})))},move:function(x,O){if(x!==O){var j=w();x<0||x>=j.length||O<0||O>=j.length||(c.keys=Uv(c.keys,x,O),C(Uv(j,x,O)))}}},E=y||[];return Array.isArray(E)||(E=[]),n(E.map(function(x,O){var j=c.keys[O];return j===void 0&&(c.keys[O]=c.id,j=c.keys[O],c.id+=1),{name:O,key:j,isListField:!0}}),k,m)})))}function vP(e){var t=!1,r=e.length,n=[];return e.length?new Promise(function(o,a){e.forEach(function(i,l){i.catch(function(s){return t=!0,s}).then(function(s){r-=1,n[l]=s,!(r>0)&&(t&&a(n),o(n))})})}):Promise.resolve([])}var IC="__@field_split__";function Xc(e){return e.map(function(t){return"".concat(at(t),":").concat(t)}).join(IC)}var va=(function(){function e(){vr(this,e),T(this,"kvs",new Map)}return br(e,[{key:"set",value:function(t,r){this.kvs.set(Xc(t),r)}},{key:"get",value:function(t){return this.kvs.get(Xc(t))}},{key:"update",value:function(t,r){var n=this.get(t),o=r(n);o?this.set(t,o):this.delete(t)}},{key:"delete",value:function(t){this.kvs.delete(Xc(t))}},{key:"map",value:function(t){return Ie(this.kvs.entries()).map(function(r){var n=ce(r,2),o=n[0],a=n[1],i=o.split(IC);return t({key:i.map(function(l){var s=l.match(/^([^:]*):(.*)$/),u=ce(s,3),c=u[1],f=u[2];return c==="number"?Number(f):f}),value:a})})}},{key:"toJSON",value:function(){var t={};return this.map(function(r){var n=r.key,o=r.value;return t[n.join(".")]=o,null}),t}}]),e})(),bP=["name"],yP=br(function e(t){var r=this;vr(this,e),T(this,"formHooked",!1),T(this,"forceRootUpdate",void 0),T(this,"subscribable",!0),T(this,"store",{}),T(this,"fieldEntities",[]),T(this,"initialValues",{}),T(this,"callbacks",{}),T(this,"validateMessages",null),T(this,"preserve",null),T(this,"lastValidatePromise",null),T(this,"getForm",function(){return{getFieldValue:r.getFieldValue,getFieldsValue:r.getFieldsValue,getFieldError:r.getFieldError,getFieldWarning:r.getFieldWarning,getFieldsError:r.getFieldsError,isFieldsTouched:r.isFieldsTouched,isFieldTouched:r.isFieldTouched,isFieldValidating:r.isFieldValidating,isFieldsValidating:r.isFieldsValidating,resetFields:r.resetFields,setFields:r.setFields,setFieldValue:r.setFieldValue,setFieldsValue:r.setFieldsValue,validateFields:r.validateFields,submit:r.submit,_init:!0,getInternalHooks:r.getInternalHooks}}),T(this,"getInternalHooks",function(n){return n===qo?(r.formHooked=!0,{dispatch:r.dispatch,initEntityValue:r.initEntityValue,registerField:r.registerField,useSubscribe:r.useSubscribe,setInitialValues:r.setInitialValues,destroyForm:r.destroyForm,setCallbacks:r.setCallbacks,setValidateMessages:r.setValidateMessages,getFields:r.getFields,setPreserve:r.setPreserve,getInitialValue:r.getInitialValue,registerWatch:r.registerWatch}):(lr(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)}),T(this,"useSubscribe",function(n){r.subscribable=n}),T(this,"prevWithoutPreserves",null),T(this,"setInitialValues",function(n,o){if(r.initialValues=n||{},o){var a,i=$a(n,r.store);(a=r.prevWithoutPreserves)===null||a===void 0||a.map(function(l){var s=l.key;i=jn(i,s,vn(n,s))}),r.prevWithoutPreserves=null,r.updateStore(i)}}),T(this,"destroyForm",function(n){if(n)r.updateStore({});else{var o=new va;r.getFieldEntities(!0).forEach(function(a){r.isMergedPreserve(a.isPreserve())||o.set(a.getNamePath(),!0)}),r.prevWithoutPreserves=o}}),T(this,"getInitialValue",function(n){var o=vn(r.initialValues,n);return n.length?$a(o):o}),T(this,"setCallbacks",function(n){r.callbacks=n}),T(this,"setValidateMessages",function(n){r.validateMessages=n}),T(this,"setPreserve",function(n){r.preserve=n}),T(this,"watchList",[]),T(this,"registerWatch",function(n){return r.watchList.push(n),function(){r.watchList=r.watchList.filter(function(o){return o!==n})}}),T(this,"notifyWatch",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(r.watchList.length){var o=r.getFieldsValue(),a=r.getFieldsValue(!0);r.watchList.forEach(function(i){i(o,a,n)})}}),T(this,"timeoutId",null),T(this,"warningUnhooked",function(){}),T(this,"updateStore",function(n){r.store=n}),T(this,"getFieldEntities",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return n?r.fieldEntities.filter(function(o){return o.getNamePath().length}):r.fieldEntities}),T(this,"getFieldsMap",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,o=new va;return r.getFieldEntities(n).forEach(function(a){var i=a.getNamePath();o.set(i,a)}),o}),T(this,"getFieldEntitiesForNamePathList",function(n){if(!n)return r.getFieldEntities(!0);var o=r.getFieldsMap(!0);return n.map(function(a){var i=gr(a);return o.get(i)||{INVALIDATE_NAME_PATH:gr(a)}})}),T(this,"getFieldsValue",function(n,o){r.warningUnhooked();var a,i,l;if(n===!0||Array.isArray(n)?(a=n,i=o):n&&at(n)==="object"&&(l=n.strict,i=n.filter),a===!0&&!i)return r.store;var s=r.getFieldEntitiesForNamePathList(Array.isArray(a)?a:null),u=[];return s.forEach(function(c){var f,p,h="INVALIDATE_NAME_PATH"in c?c.INVALIDATE_NAME_PATH:c.getNamePath();if(l){var v,g;if((v=(g=c).isList)!==null&&v!==void 0&&v.call(g))return}else if(!a&&(f=(p=c).isListField)!==null&&f!==void 0&&f.call(p))return;if(!i)u.push(h);else{var m="getMeta"in c?c.getMeta():null;i(m)&&u.push(h)}}),Xv(r.store,u.map(gr))}),T(this,"getFieldValue",function(n){r.warningUnhooked();var o=gr(n);return vn(r.store,o)}),T(this,"getFieldsError",function(n){r.warningUnhooked();var o=r.getFieldEntitiesForNamePathList(n);return o.map(function(a,i){return a&&!("INVALIDATE_NAME_PATH"in a)?{name:a.getNamePath(),errors:a.getErrors(),warnings:a.getWarnings()}:{name:gr(n[i]),errors:[],warnings:[]}})}),T(this,"getFieldError",function(n){r.warningUnhooked();var o=gr(n),a=r.getFieldsError([o])[0];return a.errors}),T(this,"getFieldWarning",function(n){r.warningUnhooked();var o=gr(n),a=r.getFieldsError([o])[0];return a.warnings}),T(this,"isFieldsTouched",function(){r.warningUnhooked();for(var n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];var i=o[0],l=o[1],s,u=!1;o.length===0?s=null:o.length===1?Array.isArray(i)?(s=i.map(gr),u=!1):(s=null,u=i):(s=i.map(gr),u=l);var c=r.getFieldEntities(!0),f=function(g){return g.isFieldTouched()};if(!s)return u?c.every(function(g){return f(g)||g.isList()}):c.some(f);var p=new va;s.forEach(function(g){p.set(g,[])}),c.forEach(function(g){var m=g.getNamePath();s.forEach(function(b){b.every(function(y,C){return m[C]===y})&&p.update(b,function(y){return[].concat(Ie(y),[g])})})});var h=function(g){return g.some(f)},v=p.map(function(g){var m=g.value;return m});return u?v.every(h):v.some(h)}),T(this,"isFieldTouched",function(n){return r.warningUnhooked(),r.isFieldsTouched([n])}),T(this,"isFieldsValidating",function(n){r.warningUnhooked();var o=r.getFieldEntities();if(!n)return o.some(function(i){return i.isFieldValidating()});var a=n.map(gr);return o.some(function(i){var l=i.getNamePath();return Pa(a,l)&&i.isFieldValidating()})}),T(this,"isFieldValidating",function(n){return r.warningUnhooked(),r.isFieldsValidating([n])}),T(this,"resetWithFieldInitialValue",function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=new va,a=r.getFieldEntities(!0);a.forEach(function(s){var u=s.props.initialValue,c=s.getNamePath();if(u!==void 0){var f=o.get(c)||new Set;f.add({entity:s,value:u}),o.set(c,f)}});var i=function(s){s.forEach(function(u){var c=u.props.initialValue;if(c!==void 0){var f=u.getNamePath(),p=r.getInitialValue(f);if(p!==void 0)lr(!1,"Form already set 'initialValues' with path '".concat(f.join("."),"'. Field can not overwrite it."));else{var h=o.get(f);if(h&&h.size>1)lr(!1,"Multiple Field with path '".concat(f.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(h){var v=r.getFieldValue(f),g=u.isListField();!g&&(!n.skipExist||v===void 0)&&r.updateStore(jn(r.store,f,Ie(h)[0].value))}}}})},l;n.entities?l=n.entities:n.namePathList?(l=[],n.namePathList.forEach(function(s){var u=o.get(s);if(u){var c;(c=l).push.apply(c,Ie(Ie(u).map(function(f){return f.entity})))}})):l=a,i(l)}),T(this,"resetFields",function(n){r.warningUnhooked();var o=r.store;if(!n){r.updateStore($a(r.initialValues)),r.resetWithFieldInitialValue(),r.notifyObservers(o,null,{type:"reset"}),r.notifyWatch();return}var a=n.map(gr);a.forEach(function(i){var l=r.getInitialValue(i);r.updateStore(jn(r.store,i,l))}),r.resetWithFieldInitialValue({namePathList:a}),r.notifyObservers(o,a,{type:"reset"}),r.notifyWatch(a)}),T(this,"setFields",function(n){r.warningUnhooked();var o=r.store,a=[];n.forEach(function(i){var l=i.name,s=bt(i,bP),u=gr(l);a.push(u),"value"in s&&r.updateStore(jn(r.store,u,s.value)),r.notifyObservers(o,[u],{type:"setField",data:i})}),r.notifyWatch(a)}),T(this,"getFields",function(){var n=r.getFieldEntities(!0),o=n.map(function(a){var i=a.getNamePath(),l=a.getMeta(),s=L(L({},l),{},{name:i,value:r.getFieldValue(i)});return Object.defineProperty(s,"originRCField",{value:!0}),s});return o}),T(this,"initEntityValue",function(n){var o=n.props.initialValue;if(o!==void 0){var a=n.getNamePath(),i=vn(r.store,a);i===void 0&&r.updateStore(jn(r.store,a,o))}}),T(this,"isMergedPreserve",function(n){var o=n!==void 0?n:r.preserve;return o??!0}),T(this,"registerField",function(n){r.fieldEntities.push(n);var o=n.getNamePath();if(r.notifyWatch([o]),n.props.initialValue!==void 0){var a=r.store;r.resetWithFieldInitialValue({entities:[n],skipExist:!0}),r.notifyObservers(a,[n.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(i,l){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(r.fieldEntities=r.fieldEntities.filter(function(f){return f!==n}),!r.isMergedPreserve(l)&&(!i||s.length>1)){var u=i?void 0:r.getInitialValue(o);if(o.length&&r.getFieldValue(o)!==u&&r.fieldEntities.every(function(f){return!PC(f.getNamePath(),o)})){var c=r.store;r.updateStore(jn(c,o,u,!0)),r.notifyObservers(c,[o],{type:"remove"}),r.triggerDependenciesUpdate(c,o)}}r.notifyWatch([o])}}),T(this,"dispatch",function(n){switch(n.type){case"updateValue":{var o=n.namePath,a=n.value;r.updateValue(o,a);break}case"validateField":{var i=n.namePath,l=n.triggerName;r.validateFields([i],{triggerName:l});break}}}),T(this,"notifyObservers",function(n,o,a){if(r.subscribable){var i=L(L({},a),{},{store:r.getFieldsValue(!0)});r.getFieldEntities().forEach(function(l){var s=l.onStoreChange;s(n,o,i)})}else r.forceRootUpdate()}),T(this,"triggerDependenciesUpdate",function(n,o){var a=r.getDependencyChildrenFields(o);return a.length&&r.validateFields(a),r.notifyObservers(n,a,{type:"dependenciesUpdate",relatedFields:[o].concat(Ie(a))}),a}),T(this,"updateValue",function(n,o){var a=gr(n),i=r.store;r.updateStore(jn(r.store,a,o)),r.notifyObservers(i,[a],{type:"valueUpdate",source:"internal"}),r.notifyWatch([a]);var l=r.triggerDependenciesUpdate(i,a),s=r.callbacks.onValuesChange;if(s){var u=Xv(r.store,[a]);s(u,r.getFieldsValue())}r.triggerOnFieldsChange([a].concat(Ie(l)))}),T(this,"setFieldsValue",function(n){r.warningUnhooked();var o=r.store;if(n){var a=$a(r.store,n);r.updateStore(a)}r.notifyObservers(o,null,{type:"valueUpdate",source:"external"}),r.notifyWatch()}),T(this,"setFieldValue",function(n,o){r.setFields([{name:n,value:o,errors:[],warnings:[]}])}),T(this,"getDependencyChildrenFields",function(n){var o=new Set,a=[],i=new va;r.getFieldEntities().forEach(function(s){var u=s.props.dependencies;(u||[]).forEach(function(c){var f=gr(c);i.update(f,function(){var p=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return p.add(s),p})})});var l=function s(u){var c=i.get(u)||new Set;c.forEach(function(f){if(!o.has(f)){o.add(f);var p=f.getNamePath();f.isFieldDirty()&&p.length&&(a.push(p),s(p))}})};return l(n),a}),T(this,"triggerOnFieldsChange",function(n,o){var a=r.callbacks.onFieldsChange;if(a){var i=r.getFields();if(o){var l=new va;o.forEach(function(u){var c=u.name,f=u.errors;l.set(c,f)}),i.forEach(function(u){u.errors=l.get(u.name)||u.errors})}var s=i.filter(function(u){var c=u.name;return Pa(n,c)});s.length&&a(s,i)}}),T(this,"validateFields",function(n,o){r.warningUnhooked();var a,i;Array.isArray(n)||typeof n=="string"||typeof o=="string"?(a=n,i=o):i=n;var l=!!a,s=l?a.map(gr):[],u=[],c=String(Date.now()),f=new Set,p=i||{},h=p.recursive,v=p.dirty;r.getFieldEntities(!0).forEach(function(y){if(l||s.push(y.getNamePath()),!(!y.props.rules||!y.props.rules.length)&&!(v&&!y.isFieldDirty())){var C=y.getNamePath();if(f.add(C.join(c)),!l||Pa(s,C,h)){var D=y.validateRules(L({validateMessages:L(L({},NC),r.validateMessages)},i));u.push(D.then(function(){return{name:C,errors:[],warnings:[]}}).catch(function(w){var k,E=[],x=[];return(k=w.forEach)===null||k===void 0||k.call(w,function(O){var j=O.rule.warningOnly,$=O.errors;j?x.push.apply(x,Ie($)):E.push.apply(E,Ie($))}),E.length?Promise.reject({name:C,errors:E,warnings:x}):{name:C,errors:E,warnings:x}}))}}});var g=vP(u);r.lastValidatePromise=g,g.catch(function(y){return y}).then(function(y){var C=y.map(function(D){var w=D.name;return w});r.notifyObservers(r.store,C,{type:"validateFinish"}),r.triggerOnFieldsChange(C,y)});var m=g.then(function(){return r.lastValidatePromise===g?Promise.resolve(r.getFieldsValue(s)):Promise.reject([])}).catch(function(y){var C=y.filter(function(D){return D&&D.errors.length});return Promise.reject({values:r.getFieldsValue(s),errorFields:C,outOfDate:r.lastValidatePromise!==g})});m.catch(function(y){return y});var b=s.filter(function(y){return f.has(y.join(c))});return r.triggerOnFieldsChange(b),m}),T(this,"submit",function(){r.warningUnhooked(),r.validateFields().then(function(n){var o=r.callbacks.onFinish;if(o)try{o(n)}catch(a){console.error(a)}}).catch(function(n){var o=r.callbacks.onFinishFailed;o&&o(n)})}),this.forceRootUpdate=t});function RC(e){var t=d.useRef(),r=d.useState({}),n=ce(r,2),o=n[1];if(!t.current)if(e)t.current=e;else{var a=function(){o({})},i=new yP(a);t.current=i.getForm()}return[t.current]}var Bf=d.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),CP=function(e){var t=e.validateMessages,r=e.onFormChange,n=e.onFormFinish,o=e.children,a=d.useContext(Bf),i=d.useRef({});return d.createElement(Bf.Provider,{value:L(L({},a),{},{validateMessages:L(L({},a.validateMessages),t),triggerFormChange:function(l,s){r&&r(l,{changedFields:s,forms:i.current}),a.triggerFormChange(l,s)},triggerFormFinish:function(l,s){n&&n(l,{values:s,forms:i.current}),a.triggerFormFinish(l,s)},registerForm:function(l,s){l&&(i.current=L(L({},i.current),{},T({},l,s))),a.registerForm(l,s)},unregisterForm:function(l){var s=L({},i.current);delete s[l],i.current=s,a.unregisterForm(l)}})},o)},xP=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed","clearOnDestroy"],wP=function(e,t){var r=e.name,n=e.initialValues,o=e.fields,a=e.form,i=e.preserve,l=e.children,s=e.component,u=s===void 0?"form":s,c=e.validateMessages,f=e.validateTrigger,p=f===void 0?"onChange":f,h=e.onValuesChange,v=e.onFieldsChange,g=e.onFinish,m=e.onFinishFailed,b=e.clearOnDestroy,y=bt(e,xP),C=d.useRef(null),D=d.useContext(Bf),w=RC(a),k=ce(w,1),E=k[0],x=E.getInternalHooks(qo),O=x.useSubscribe,j=x.setInitialValues,$=x.setCallbacks,P=x.setValidateMessages,A=x.setPreserve,B=x.destroyForm;d.useImperativeHandle(t,function(){return L(L({},E),{},{nativeElement:C.current})}),d.useEffect(function(){return D.registerForm(r,E),function(){D.unregisterForm(r)}},[D,E,r]),P(L(L({},D.validateMessages),c)),$({onValuesChange:h,onFieldsChange:function(H){if(D.triggerFormChange(r,H),v){for(var q=arguments.length,Z=new Array(q>1?q-1:0),te=1;te<q;te++)Z[te-1]=arguments[te];v.apply(void 0,[H].concat(Z))}},onFinish:function(H){D.triggerFormFinish(r,H),g&&g(H)},onFinishFailed:m}),A(i);var S=d.useRef(null);j(n,!S.current),S.current||(S.current=!0),d.useEffect(function(){return function(){return B(b)}},[]);var I,N=typeof l=="function";if(N){var F=E.getFieldsValue(!0);I=l(F,E)}else I=l;O(!N);var M=d.useRef();d.useEffect(function(){pP(M.current||[],o||[])||E.setFields(o||[]),M.current=o},[o,E]);var _=d.useMemo(function(){return L(L({},E),{},{validateTrigger:p})},[E,p]),X=d.createElement(Gs.Provider,{value:null},d.createElement(Za.Provider,{value:_},I));return u===!1?X:d.createElement(u,Me({},y,{ref:C,onSubmit:function(H){H.preventDefault(),H.stopPropagation(),E.submit()},onReset:function(H){var q;H.preventDefault(),E.resetFields(),(q=y.onReset)===null||q===void 0||q.call(y,H)}}),X)};function Yv(e){try{return JSON.stringify(e)}catch{return Math.random()}}function EP(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=t[0],o=t[1],a=o===void 0?{}:o,i=FN(a)?{form:a}:a,l=i.form,s=yt(),u=ce(s,2),c=u[0],f=u[1],p=xt(function(){return Yv(c)},[c]),h=qe(p);h.current=p;var v=Rr(Za),g=l||v,m=g&&g._init,b=gr(n),y=qe(b);return y.current=b,Ot(function(){if(m){var C=g.getFieldsValue,D=g.getInternalHooks,w=D(qo),k=w.registerWatch,E=function(j,$){var P=i.preserve?$:j;return typeof n=="function"?n(P):vn(P,y.current)},x=k(function(j,$){var P=E(j,$),A=Yv(P);h.current!==A&&(h.current=A,f(P))}),O=E(C(),C(!0));return c!==O&&f(O),x}},[m]),c}var kP=d.forwardRef(wP),kl=kP;kl.FormProvider=CP;kl.Field=jC;kl.List=gP;kl.useForm=RC;kl.useWatch=EP;const oa=d.createContext({}),DP=({children:e,status:t,override:r})=>{const n=d.useContext(oa),o=d.useMemo(()=>{const a=Object.assign({},n);return r&&delete a.isFormItemInput,t&&(delete a.status,delete a.hasFeedback,delete a.feedbackIcon),a},[t,r,n]);return d.createElement(oa.Provider,{value:o},e)},SP=d.createContext(void 0),fl=e=>{const{space:t,form:r,children:n}=e;if(n==null)return null;let o=n;return r&&(o=ee.createElement(DP,{override:!0,status:!0},o)),t&&(o=ee.createElement(n5,null,o)),o};function MC(...e){const t={};return e.forEach(r=>{r&&Object.keys(r).forEach(n=>{r[n]!==void 0&&(t[n]=r[n])})}),t}var TC=function(e){if(Xr()&&window.document.documentElement){var t=Array.isArray(e)?e:[e],r=window.document.documentElement;return t.some(function(n){return n in r.style})}return!1},$P=function(e,t){if(!TC(e))return!1;var r=document.createElement("div"),n=r.style[e];return r.style[e]=t,r.style[e]!==n};function BP(e,t){return!Array.isArray(e)&&t!==void 0?$P(e,t):TC(e)}function OP(e){return t=>d.createElement(ai,{theme:{token:{motion:!1,zIndexPopupBase:0}}},d.createElement(e,Object.assign({},t)))}const zC=(e,t,r,n,o)=>OP(a=>{const{prefixCls:i,style:l}=a,s=d.useRef(null),[u,c]=d.useState(0),[f,p]=d.useState(0),[h,v]=Gr(!1,{value:a.open}),{getPrefixCls:g}=d.useContext(Zt),m=g(n||"select",i);d.useEffect(()=>{if(v(!0),typeof ResizeObserver<"u"){const C=new ResizeObserver(w=>{const k=w[0].target;c(k.offsetHeight+8),p(k.offsetWidth)}),D=setInterval(()=>{var w;const k=o?`.${o(m)}`:`.${m}-dropdown`,E=(w=s.current)===null||w===void 0?void 0:w.querySelector(k);E&&(clearInterval(D),C.observe(E))},10);return()=>{clearInterval(D),C.disconnect()}}},[]);let b=Object.assign(Object.assign({},a),{style:Object.assign(Object.assign({},l),{margin:0}),open:h,visible:h,getPopupContainer:()=>s.current});t&&Object.assign(b,{[t]:{overflow:{adjustX:!1,adjustY:!1}}});const y={paddingBottom:u,position:"relative",minWidth:f};return d.createElement("div",{ref:s,style:y},d.createElement(e,Object.assign({},b)))}),_C=(function(){if(typeof navigator>"u"||typeof window>"u")return!1;var e=navigator.userAgent||navigator.vendor||window.opera;return/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(e)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(e==null?void 0:e.substr(0,4))});var ju=function(e){var t=e.className,r=e.customizeIcon,n=e.customizeIconProps,o=e.children,a=e.onMouseDown,i=e.onClick,l=typeof r=="function"?r(n):r;return d.createElement("span",{className:t,onMouseDown:function(s){s.preventDefault(),a==null||a(s)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:i,"aria-hidden":!0},l!==void 0?l:d.createElement("span",{className:pe(t.split(/\s+/).map(function(s){return"".concat(s,"-icon")}))},o))},AP=function(e,t,r,n,o){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,i=arguments.length>6?arguments[6]:void 0,l=arguments.length>7?arguments[7]:void 0,s=ee.useMemo(function(){if(at(n)==="object")return n.clearIcon;if(o)return o},[n,o]),u=ee.useMemo(function(){return!!(!a&&n&&(r.length||i)&&!(l==="combobox"&&i===""))},[n,a,r.length,i,l]);return{allowClear:u,clearIcon:ee.createElement(ju,{className:"".concat(e,"-clear"),onMouseDown:t,customizeIcon:s},"\xD7")}},LC=d.createContext(null);function FP(){return d.useContext(LC)}function NP(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,t=d.useState(!1),r=ce(t,2),n=r[0],o=r[1],a=d.useRef(null),i=function(){window.clearTimeout(a.current)};d.useEffect(function(){return i},[]);var l=function(s,u){i(),a.current=window.setTimeout(function(){o(s),u&&u()},e)};return[n,l,i]}function HC(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,t=d.useRef(null),r=d.useRef(null);d.useEffect(function(){return function(){window.clearTimeout(r.current)}},[]);function n(o){(o||t.current===null)&&(t.current=o),window.clearTimeout(r.current),r.current=window.setTimeout(function(){t.current=null},e)}return[function(){return t.current},n]}function PP(e,t,r,n){var o=d.useRef(null);o.current={open:t,triggerOpen:r,customizedTrigger:n},d.useEffect(function(){function a(i){var l;if(!((l=o.current)!==null&&l!==void 0&&l.customizedTrigger)){var s=i.target;s.shadowRoot&&i.composed&&(s=i.composedPath()[0]||s),o.current.open&&e().filter(function(u){return u}).every(function(u){return!u.contains(s)&&u!==s})&&o.current.triggerOpen(!1)}}return window.addEventListener("mousedown",a),function(){return window.removeEventListener("mousedown",a)}},[])}function jP(e){return e&&![rt.ESC,rt.SHIFT,rt.BACKSPACE,rt.TAB,rt.WIN_KEY,rt.ALT,rt.META,rt.WIN_KEY_RIGHT,rt.CTRL,rt.SEMICOLON,rt.EQUALS,rt.CAPS_LOCK,rt.CONTEXT_MENU,rt.F1,rt.F2,rt.F3,rt.F4,rt.F5,rt.F6,rt.F7,rt.F8,rt.F9,rt.F10,rt.F11,rt.F12].includes(e)}var IP=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],ba=void 0;function RP(e,t){var r=e.prefixCls,n=e.invalidate,o=e.item,a=e.renderItem,i=e.responsive,l=e.responsiveDisabled,s=e.registerSize,u=e.itemKey,c=e.className,f=e.style,p=e.children,h=e.display,v=e.order,g=e.component,m=g===void 0?"div":g,b=bt(e,IP),y=i&&!h;function C(x){s(u,x)}d.useEffect(function(){return function(){C(null)}},[]);var D=a&&o!==ba?a(o,{index:v}):p,w;n||(w={opacity:y?0:1,height:y?0:ba,overflowY:y?"hidden":ba,order:i?v:ba,pointerEvents:y?"none":ba,position:y?"absolute":ba});var k={};y&&(k["aria-hidden"]=!0);var E=d.createElement(m,Me({className:pe(!n&&r,c),style:L(L({},w),f)},k,b,{ref:t}),D);return i&&(E=d.createElement(ao,{onResize:function(x){var O=x.offsetWidth;C(O)},disabled:l},E)),E}var _i=d.forwardRef(RP);_i.displayName="Item";function MP(e){if(typeof MessageChannel>"u")qt(e);else{var t=new MessageChannel;t.port1.onmessage=function(){return e()},t.port2.postMessage(void 0)}}function TP(){var e=d.useRef(null),t=function(r){e.current||(e.current=[],MP(function(){Nb(function(){e.current.forEach(function(n){n()}),e.current=null})})),e.current.push(r)};return t}function Ci(e,t){var r=d.useState(t),n=ce(r,2),o=n[0],a=n[1],i=nr(function(l){e(function(){a(l)})});return[o,i]}var Xs=ee.createContext(null),zP=["component"],_P=["className"],LP=["className"],HP=function(e,t){var r=d.useContext(Xs);if(!r){var n=e.component,o=n===void 0?"div":n,a=bt(e,zP);return d.createElement(o,Me({},a,{ref:t}))}var i=r.className,l=bt(r,_P),s=e.className,u=bt(e,LP);return d.createElement(Xs.Provider,{value:null},d.createElement(_i,Me({ref:t,className:pe(i,s)},l,u)))},WC=d.forwardRef(HP);WC.displayName="RawItem";var WP=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","suffix","component","itemComponent","onVisibleChange"],KC="responsive",qC="invalidate";function KP(e){return"+ ".concat(e.length," ...")}function qP(e,t){var r=e.prefixCls,n=r===void 0?"rc-overflow":r,o=e.data,a=o===void 0?[]:o,i=e.renderItem,l=e.renderRawItem,s=e.itemKey,u=e.itemWidth,c=u===void 0?10:u,f=e.ssr,p=e.style,h=e.className,v=e.maxCount,g=e.renderRest,m=e.renderRawRest,b=e.suffix,y=e.component,C=y===void 0?"div":y,D=e.itemComponent,w=e.onVisibleChange,k=bt(e,WP),E=f==="full",x=TP(),O=Ci(x,null),j=ce(O,2),$=j[0],P=j[1],A=$||0,B=Ci(x,new Map),S=ce(B,2),I=S[0],N=S[1],F=Ci(x,0),M=ce(F,2),_=M[0],X=M[1],H=Ci(x,0),q=ce(H,2),Z=q[0],te=q[1],z=Ci(x,0),Y=ce(z,2),V=Y[0],U=Y[1],K=yt(null),W=ce(K,2),re=W[0],G=W[1],J=yt(null),oe=ce(J,2),se=oe[0],ge=oe[1],Ee=d.useMemo(function(){return se===null&&E?Number.MAX_SAFE_INTEGER:se||0},[se,$]),je=yt(!1),ve=ce(je,2),ye=ve[0],ke=ve[1],we="".concat(n,"-item"),De=Math.max(_,Z),Ne=v===KC,Oe=a.length&&Ne,Xe=v===qC,Le=Oe||typeof v=="number"&&a.length>v,Fe=xt(function(){var ae=a;return Oe?$===null&&E?ae=a:ae=a.slice(0,Math.min(a.length,A/c)):typeof v=="number"&&(ae=a.slice(0,v)),ae},[a,c,$,v,Oe]),fe=xt(function(){return Oe?a.slice(Ee+1):a.slice(Fe.length)},[a,Fe,Oe,Ee]),Be=mt(function(ae,he){var xe;return typeof s=="function"?s(ae):(xe=s&&(ae==null?void 0:ae[s]))!==null&&xe!==void 0?xe:he},[s]),We=mt(i||function(ae){return ae},[i]);function Ye(ae,he,xe){se===ae&&(he===void 0||he===re)||(ge(ae),xe||(ke(ae<a.length-1),w==null||w(ae)),he!==void 0&&G(he))}function Ve(ae,he){P(he.clientWidth)}function Te(ae,he){N(function(xe){var be=new Map(xe);return he===null?be.delete(ae):be.set(ae,he),be})}function it(ae,he){te(he),X(Z)}function Ue(ae,he){U(he)}function nt(ae){return I.get(Be(Fe[ae],ae))}Wt(function(){if(A&&typeof De=="number"&&Fe){var ae=V,he=Fe.length,xe=he-1;if(!he){Ye(0,null);return}for(var be=0;be<he;be+=1){var Ce=nt(be);if(E&&(Ce=Ce||0),Ce===void 0){Ye(be-1,void 0,!0);break}if(ae+=Ce,xe===0&&ae<=A||be===xe-1&&ae+nt(xe)<=A){Ye(xe,null);break}else if(ae+De>A){Ye(be-1,ae-Ce-V+Z);break}}b&&nt(0)+V>A&&G(null)}},[A,I,Z,V,Be,Fe]);var pt=ye&&!!fe.length,St={};re!==null&&Oe&&(St={position:"absolute",left:re,top:0});var dt={prefixCls:we,responsive:Oe,component:D,invalidate:Xe},ht=l?function(ae,he){var xe=Be(ae,he);return d.createElement(Xs.Provider,{key:xe,value:L(L({},dt),{},{order:he,item:ae,itemKey:xe,registerSize:Te,display:he<=Ee})},l(ae,he))}:function(ae,he){var xe=Be(ae,he);return d.createElement(_i,Me({},dt,{order:he,key:xe,item:ae,renderItem:We,itemKey:xe,registerSize:Te,display:he<=Ee}))},Pt={order:pt?Ee:Number.MAX_SAFE_INTEGER,className:"".concat(we,"-rest"),registerSize:it,display:pt},At=g||KP,ct=m?d.createElement(Xs.Provider,{value:L(L({},dt),Pt)},m(fe)):d.createElement(_i,Me({},dt,Pt),typeof At=="function"?At(fe):At),ut=d.createElement(C,Me({className:pe(!Xe&&n,h),style:p,ref:t},k),Fe.map(ht),Le?ct:null,b&&d.createElement(_i,Me({},dt,{responsive:Ne,responsiveDisabled:!Oe,order:Ee,className:"".concat(we,"-suffix"),registerSize:Ue,display:!0,style:St}),b));return Ne?d.createElement(ao,{onResize:Ve,disabled:!Oe},ut):ut}var Yn=d.forwardRef(qP);Yn.displayName="Overflow";Yn.Item=WC;Yn.RESPONSIVE=KC;Yn.INVALIDATE=qC;function VP(e,t,r){var n=L(L({},e),t);return Object.keys(t).forEach(function(o){var a=t[o];typeof a=="function"&&(n[o]=function(){for(var i,l=arguments.length,s=new Array(l),u=0;u<l;u++)s[u]=arguments[u];return a.apply(void 0,s),(i=e[o])===null||i===void 0?void 0:i.call.apply(i,[e].concat(s))})}),n}var GP=["prefixCls","id","inputElement","autoFocus","autoComplete","editable","activeDescendantId","value","open","attrs"],XP=function(e,t){var r=e.prefixCls,n=e.id,o=e.inputElement,a=e.autoFocus,i=e.autoComplete,l=e.editable,s=e.activeDescendantId,u=e.value,c=e.open,f=e.attrs,p=bt(e,GP),h=o||d.createElement("input",null),v=h,g=v.ref,m=v.props;return"maxLength"in h.props,h=d.cloneElement(h,L(L(L({type:"search"},VP(p,m)),{},{id:n,ref:ro(t,g),autoComplete:i||"off",autoFocus:a,className:pe("".concat(r,"-selection-search-input"),m==null?void 0:m.className),role:"combobox","aria-expanded":c||!1,"aria-haspopup":"listbox","aria-owns":"".concat(n,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(n,"_list"),"aria-activedescendant":c?s:void 0},f),{},{value:l?u:"",readOnly:!l,unselectable:l?null:"on",style:L(L({},m.style),{},{opacity:l?null:0})})),h},VC=d.forwardRef(XP);function GC(e){return Array.isArray(e)?e:e!==void 0?[e]:[]}var UP=typeof window<"u"&&window.document&&window.document.documentElement,YP=UP;function ZP(e){return e!=null}function JP(e){return!e&&e!==0}function Zv(e){return["string","number"].includes(at(e))}function XC(e){var t=void 0;return e&&(Zv(e.title)?t=e.title.toString():Zv(e.label)&&(t=e.label.toString())),t}function QP(e,t){YP?d.useLayoutEffect(e,t):d.useEffect(e,t)}function e6(e){var t;return(t=e.key)!==null&&t!==void 0?t:e.value}var Jv=function(e){e.preventDefault(),e.stopPropagation()},t6=function(e){var t=e.id,r=e.prefixCls,n=e.values,o=e.open,a=e.searchValue,i=e.autoClearSearchValue,l=e.inputRef,s=e.placeholder,u=e.disabled,c=e.mode,f=e.showSearch,p=e.autoFocus,h=e.autoComplete,v=e.activeDescendantId,g=e.tabIndex,m=e.removeIcon,b=e.maxTagCount,y=e.maxTagTextLength,C=e.maxTagPlaceholder,D=C===void 0?function(G){return"+ ".concat(G.length," ...")}:C,w=e.tagRender,k=e.onToggleOpen,E=e.onRemove,x=e.onInputChange,O=e.onInputPaste,j=e.onInputKeyDown,$=e.onInputMouseDown,P=e.onInputCompositionStart,A=e.onInputCompositionEnd,B=e.onInputBlur,S=d.useRef(null),I=yt(0),N=ce(I,2),F=N[0],M=N[1],_=yt(!1),X=ce(_,2),H=X[0],q=X[1],Z="".concat(r,"-selection"),te=o||c==="multiple"&&i===!1||c==="tags"?a:"",z=c==="tags"||c==="multiple"&&i===!1||f&&(o||H);QP(function(){M(S.current.scrollWidth)},[te]);var Y=function(G,J,oe,se,ge){return d.createElement("span",{title:XC(G),className:pe("".concat(Z,"-item"),T({},"".concat(Z,"-item-disabled"),oe))},d.createElement("span",{className:"".concat(Z,"-item-content")},J),se&&d.createElement(ju,{className:"".concat(Z,"-item-remove"),onMouseDown:Jv,onClick:ge,customizeIcon:m},"\xD7"))},V=function(G,J,oe,se,ge,Ee){var je=function(ve){Jv(ve),k(!o)};return d.createElement("span",{onMouseDown:je},w({label:J,value:G,disabled:oe,closable:se,onClose:ge,isMaxTag:!!Ee}))},U=function(G){var J=G.disabled,oe=G.label,se=G.value,ge=!u&&!J,Ee=oe;if(typeof y=="number"&&(typeof oe=="string"||typeof oe=="number")){var je=String(Ee);je.length>y&&(Ee="".concat(je.slice(0,y),"..."))}var ve=function(ye){ye&&ye.stopPropagation(),E(G)};return typeof w=="function"?V(se,Ee,J,ge,ve):Y(G,Ee,J,ge,ve)},K=function(G){if(!n.length)return null;var J=typeof D=="function"?D(G):D;return typeof w=="function"?V(void 0,J,!1,!1,void 0,!0):Y({title:J},J,!1)},W=d.createElement("div",{className:"".concat(Z,"-search"),style:{width:F},onFocus:function(){q(!0)},onBlur:function(){q(!1)}},d.createElement(VC,{ref:l,open:o,prefixCls:r,id:t,inputElement:null,disabled:u,autoFocus:p,autoComplete:h,editable:z,activeDescendantId:v,value:te,onKeyDown:j,onMouseDown:$,onChange:x,onPaste:O,onCompositionStart:P,onCompositionEnd:A,onBlur:B,tabIndex:g,attrs:Qn(e,!0)}),d.createElement("span",{ref:S,className:"".concat(Z,"-search-mirror"),"aria-hidden":!0},te,"\xA0")),re=d.createElement(Yn,{prefixCls:"".concat(Z,"-overflow"),data:n,renderItem:U,renderRest:K,suffix:W,itemKey:e6,maxCount:b});return d.createElement("span",{className:"".concat(Z,"-wrap")},re,!n.length&&!te&&d.createElement("span",{className:"".concat(Z,"-placeholder")},s))},r6=function(e){var t=e.inputElement,r=e.prefixCls,n=e.id,o=e.inputRef,a=e.disabled,i=e.autoFocus,l=e.autoComplete,s=e.activeDescendantId,u=e.mode,c=e.open,f=e.values,p=e.placeholder,h=e.tabIndex,v=e.showSearch,g=e.searchValue,m=e.activeValue,b=e.maxLength,y=e.onInputKeyDown,C=e.onInputMouseDown,D=e.onInputChange,w=e.onInputPaste,k=e.onInputCompositionStart,E=e.onInputCompositionEnd,x=e.onInputBlur,O=e.title,j=d.useState(!1),$=ce(j,2),P=$[0],A=$[1],B=u==="combobox",S=B||v,I=f[0],N=g||"";B&&m&&!P&&(N=m),d.useEffect(function(){B&&A(!1)},[B,m]);var F=u!=="combobox"&&!c&&!v?!1:!!N,M=O===void 0?XC(I):O,_=d.useMemo(function(){return I?null:d.createElement("span",{className:"".concat(r,"-selection-placeholder"),style:F?{visibility:"hidden"}:void 0},p)},[I,F,p,r]);return d.createElement("span",{className:"".concat(r,"-selection-wrap")},d.createElement("span",{className:"".concat(r,"-selection-search")},d.createElement(VC,{ref:o,prefixCls:r,id:n,open:c,inputElement:t,disabled:a,autoFocus:i,autoComplete:l,editable:S,activeDescendantId:s,value:N,onKeyDown:y,onMouseDown:C,onChange:function(X){A(!0),D(X)},onPaste:w,onCompositionStart:k,onCompositionEnd:E,onBlur:x,tabIndex:h,attrs:Qn(e,!0),maxLength:B?b:void 0})),!B&&I?d.createElement("span",{className:"".concat(r,"-selection-item"),title:M,style:F?{visibility:"hidden"}:void 0},I.label):null,_)},n6=function(e,t){var r=qe(null),n=qe(!1),o=e.prefixCls,a=e.open,i=e.mode,l=e.showSearch,s=e.tokenWithEnter,u=e.disabled,c=e.prefix,f=e.autoClearSearchValue,p=e.onSearch,h=e.onSearchSubmit,v=e.onToggleOpen,g=e.onInputKeyDown,m=e.onInputBlur,b=e.domRef;d.useImperativeHandle(t,function(){return{focus:function(F){r.current.focus(F)},blur:function(){r.current.blur()}}});var y=HC(0),C=ce(y,2),D=C[0],w=C[1],k=function(F){var M=F.which,_=r.current instanceof HTMLTextAreaElement;!_&&a&&(M===rt.UP||M===rt.DOWN)&&F.preventDefault(),g&&g(F),M===rt.ENTER&&i==="tags"&&!n.current&&!a&&(h==null||h(F.target.value)),!(_&&!a&&~[rt.UP,rt.DOWN,rt.LEFT,rt.RIGHT].indexOf(M))&&jP(M)&&v(!0)},E=function(){w(!0)},x=qe(null),O=function(F){p(F,!0,n.current)!==!1&&v(!0)},j=function(){n.current=!0},$=function(F){n.current=!1,i!=="combobox"&&O(F.target.value)},P=function(F){var M=F.target.value;if(s&&x.current&&/[\r\n]/.test(x.current)){var _=x.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");M=M.replace(_,x.current)}x.current=null,O(M)},A=function(F){var M=F.clipboardData,_=M==null?void 0:M.getData("text");x.current=_||""},B=function(F){var M=F.target;if(M!==r.current){var _=document.body.style.msTouchAction!==void 0;_?setTimeout(function(){r.current.focus()}):r.current.focus()}},S=function(F){var M=D();F.target!==r.current&&!M&&!(i==="combobox"&&u)&&F.preventDefault(),(i!=="combobox"&&(!l||!M)||!a)&&(a&&f!==!1&&p("",!0,!1),v())},I={inputRef:r,onInputKeyDown:k,onInputMouseDown:E,onInputChange:P,onInputPaste:A,onInputCompositionStart:j,onInputCompositionEnd:$,onInputBlur:m},N=i==="multiple"||i==="tags"?d.createElement(t6,Me({},e,I)):d.createElement(r6,Me({},e,I));return d.createElement("div",{ref:b,className:"".concat(o,"-selector"),onClick:B,onMouseDown:S},c&&d.createElement("div",{className:"".concat(o,"-prefix")},c),N)},o6=d.forwardRef(n6);function a6(e){var t=e.prefixCls,r=e.align,n=e.arrow,o=e.arrowPos,a=n||{},i=a.className,l=a.content,s=o.x,u=s===void 0?0:s,c=o.y,f=c===void 0?0:c,p=d.useRef();if(!r||!r.points)return null;var h={position:"absolute"};if(r.autoArrow!==!1){var v=r.points[0],g=r.points[1],m=v[0],b=v[1],y=g[0],C=g[1];m===y||!["t","b"].includes(m)?h.top=f:m==="t"?h.top=0:h.bottom=0,b===C||!["l","r"].includes(b)?h.left=u:b==="l"?h.left=0:h.right=0}return d.createElement("div",{ref:p,className:pe("".concat(t,"-arrow"),i),style:h},l)}function i6(e){var t=e.prefixCls,r=e.open,n=e.zIndex,o=e.mask,a=e.motion;return o?d.createElement(ca,Me({},a,{motionAppear:!0,visible:r,removeOnLeave:!0}),function(i){var l=i.className;return d.createElement("div",{style:{zIndex:n},className:pe("".concat(t,"-mask"),l)})}):null}var l6=d.memo(function(e){var t=e.children;return t},function(e,t){return t.cache}),s6=d.forwardRef(function(e,t){var r=e.popup,n=e.className,o=e.prefixCls,a=e.style,i=e.target,l=e.onVisibleChanged,s=e.open,u=e.keepDom,c=e.fresh,f=e.onClick,p=e.mask,h=e.arrow,v=e.arrowPos,g=e.align,m=e.motion,b=e.maskMotion,y=e.forceRender,C=e.getPopupContainer,D=e.autoDestroy,w=e.portal,k=e.zIndex,E=e.onMouseEnter,x=e.onMouseLeave,O=e.onPointerEnter,j=e.onPointerDownCapture,$=e.ready,P=e.offsetX,A=e.offsetY,B=e.offsetR,S=e.offsetB,I=e.onAlign,N=e.onPrepare,F=e.stretch,M=e.targetWidth,_=e.targetHeight,X=typeof r=="function"?r():r,H=s||u,q=(C==null?void 0:C.length)>0,Z=d.useState(!C||!q),te=ce(Z,2),z=te[0],Y=te[1];if(Wt(function(){!z&&q&&i&&Y(!0)},[z,q,i]),!z)return null;var V="auto",U={left:"-1000vw",top:"-1000vh",right:V,bottom:V};if($||!s){var K,W=g.points,re=g.dynamicInset||((K=g._experimental)===null||K===void 0?void 0:K.dynamicInset),G=re&&W[0][1]==="r",J=re&&W[0][0]==="b";G?(U.right=B,U.left=V):(U.left=P,U.right=V),J?(U.bottom=S,U.top=V):(U.top=A,U.bottom=V)}var oe={};return F&&(F.includes("height")&&_?oe.height=_:F.includes("minHeight")&&_&&(oe.minHeight=_),F.includes("width")&&M?oe.width=M:F.includes("minWidth")&&M&&(oe.minWidth=M)),s||(oe.pointerEvents="none"),d.createElement(w,{open:y||H,getContainer:C&&function(){return C(i)},autoDestroy:D},d.createElement(i6,{prefixCls:o,open:s,zIndex:k,mask:p,motion:b}),d.createElement(ao,{onResize:I,disabled:!s},function(se){return d.createElement(ca,Me({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:y,leavedClassName:"".concat(o,"-hidden")},m,{onAppearPrepare:N,onEnterPrepare:N,visible:s,onVisibleChanged:function(ge){var Ee;m==null||(Ee=m.onVisibleChanged)===null||Ee===void 0||Ee.call(m,ge),l(ge)}}),function(ge,Ee){var je=ge.className,ve=ge.style,ye=pe(o,je,n);return d.createElement("div",{ref:ro(se,t,Ee),className:ye,style:L(L(L(L({"--arrow-x":"".concat(v.x||0,"px"),"--arrow-y":"".concat(v.y||0,"px")},U),oe),ve),{},{boxSizing:"border-box",zIndex:k},a),onMouseEnter:E,onMouseLeave:x,onPointerEnter:O,onClick:f,onPointerDownCapture:j},h&&d.createElement(a6,{prefixCls:o,arrow:h,arrowPos:v,align:g}),d.createElement(l6,{cache:!s&&!c},X))})}))}),u6=d.forwardRef(function(e,t){var r=e.children,n=e.getTriggerDOMNode,o=Zn(r),a=d.useCallback(function(l){Qi(t,n?n(l):l)},[n]),i=sa(a,ua(r));return o?d.cloneElement(r,{ref:i}):r}),Qv=d.createContext(null);function e0(e){return e?Array.isArray(e)?e:[e]:[]}function c6(e,t,r,n){return d.useMemo(function(){var o=e0(r??t),a=e0(n??t),i=new Set(o),l=new Set(a);return e&&(i.has("hover")&&(i.delete("hover"),i.add("click")),l.has("hover")&&(l.delete("hover"),l.add("click"))),[i,l]},[e,t,r,n])}function d6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0;return r?e[0]===t[0]:e[0]===t[0]&&e[1]===t[1]}function f6(e,t,r,n){for(var o=r.points,a=Object.keys(e),i=0;i<a.length;i+=1){var l,s=a[i];if(d6((l=e[s])===null||l===void 0?void 0:l.points,o,n))return"".concat(t,"-placement-").concat(s)}return""}function t0(e,t,r,n){return t||(r?{motionName:"".concat(e,"-").concat(r)}:n?{motionName:n}:null)}function Dl(e){return e.ownerDocument.defaultView}function Of(e){for(var t=[],r=e==null?void 0:e.parentElement,n=["hidden","scroll","clip","auto"];r;){var o=Dl(r).getComputedStyle(r),a=o.overflowX,i=o.overflowY,l=o.overflow;[a,i,l].some(function(s){return n.includes(s)})&&t.push(r),r=r.parentElement}return t}function pl(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;return Number.isNaN(e)?t:e}function xi(e){return pl(parseFloat(e),0)}function r0(e,t){var r=L({},e);return(t||[]).forEach(function(n){if(!(n instanceof HTMLBodyElement||n instanceof HTMLHtmlElement)){var o=Dl(n).getComputedStyle(n),a=o.overflow,i=o.overflowClipMargin,l=o.borderTopWidth,s=o.borderBottomWidth,u=o.borderLeftWidth,c=o.borderRightWidth,f=n.getBoundingClientRect(),p=n.offsetHeight,h=n.clientHeight,v=n.offsetWidth,g=n.clientWidth,m=xi(l),b=xi(s),y=xi(u),C=xi(c),D=pl(Math.round(f.width/v*1e3)/1e3),w=pl(Math.round(f.height/p*1e3)/1e3),k=(v-g-y-C)*D,E=(p-h-m-b)*w,x=m*w,O=b*w,j=y*D,$=C*D,P=0,A=0;if(a==="clip"){var B=xi(i);P=B*D,A=B*w}var S=f.x+j-P,I=f.y+x-A,N=S+f.width+2*P-j-$-k,F=I+f.height+2*A-x-O-E;r.left=Math.max(r.left,S),r.top=Math.max(r.top,I),r.right=Math.min(r.right,N),r.bottom=Math.min(r.bottom,F)}}),r}function n0(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r="".concat(t),n=r.match(/^(.*)\%$/);return n?e*(parseFloat(n[1])/100):parseFloat(r)}function o0(e,t){var r=t||[],n=ce(r,2),o=n[0],a=n[1];return[n0(e.width,o),n0(e.height,a)]}function a0(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return[e[0],e[1]]}function ya(e,t){var r=t[0],n=t[1],o,a;return r==="t"?a=e.y:r==="b"?a=e.y+e.height:a=e.y+e.height/2,n==="l"?o=e.x:n==="r"?o=e.x+e.width:o=e.x+e.width/2,{x:o,y:a}}function xo(e,t){var r={t:"b",b:"t",l:"r",r:"l"};return e.map(function(n,o){return o===t?r[n]||"c":n}).join("")}function p6(e,t,r,n,o,a,i){var l=d.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:o[n]||{}}),s=ce(l,2),u=s[0],c=s[1],f=d.useRef(0),p=d.useMemo(function(){return t?Of(t):[]},[t]),h=d.useRef({}),v=function(){h.current={}};e||v();var g=nr(function(){if(t&&r&&e){let ur=function(Wr,Nn){var En=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Ne,io=H.x+Wr,Al=H.y+Nn,qu=io+J,Vu=Al+G,Gu=Math.max(io,En.left),tt=Math.max(Al,En.top),Tt=Math.min(qu,En.right),Fr=Math.min(Vu,En.bottom);return Math.max(0,(Tt-Gu)*(Fr-tt))},pn=function(){jt=H.y+be,It=jt+G,Et=H.x+xe,Jt=Et+J};var y,C,D,w,k=t,E=k.ownerDocument,x=Dl(k),O=x.getComputedStyle(k),j=O.position,$=k.style.left,P=k.style.top,A=k.style.right,B=k.style.bottom,S=k.style.overflow,I=L(L({},o[n]),a),N=E.createElement("div");(y=k.parentElement)===null||y===void 0||y.appendChild(N),N.style.left="".concat(k.offsetLeft,"px"),N.style.top="".concat(k.offsetTop,"px"),N.style.position=j,N.style.height="".concat(k.offsetHeight,"px"),N.style.width="".concat(k.offsetWidth,"px"),k.style.left="0",k.style.top="0",k.style.right="auto",k.style.bottom="auto",k.style.overflow="hidden";var F;if(Array.isArray(r))F={x:r[0],y:r[1],width:0,height:0};else{var M,_,X=r.getBoundingClientRect();X.x=(M=X.x)!==null&&M!==void 0?M:X.left,X.y=(_=X.y)!==null&&_!==void 0?_:X.top,F={x:X.x,y:X.y,width:X.width,height:X.height}}var H=k.getBoundingClientRect(),q=x.getComputedStyle(k),Z=q.height,te=q.width;H.x=(C=H.x)!==null&&C!==void 0?C:H.left,H.y=(D=H.y)!==null&&D!==void 0?D:H.top;var z=E.documentElement,Y=z.clientWidth,V=z.clientHeight,U=z.scrollWidth,K=z.scrollHeight,W=z.scrollTop,re=z.scrollLeft,G=H.height,J=H.width,oe=F.height,se=F.width,ge={left:0,top:0,right:Y,bottom:V},Ee={left:-re,top:-W,right:U-re,bottom:K-W},je=I.htmlRegion,ve="visible",ye="visibleFirst";je!=="scroll"&&je!==ye&&(je=ve);var ke=je===ye,we=r0(Ee,p),De=r0(ge,p),Ne=je===ve?De:we,Oe=ke?De:Ne;k.style.left="auto",k.style.top="auto",k.style.right="0",k.style.bottom="0";var Xe=k.getBoundingClientRect();k.style.left=$,k.style.top=P,k.style.right=A,k.style.bottom=B,k.style.overflow=S,(w=k.parentElement)===null||w===void 0||w.removeChild(N);var Le=pl(Math.round(J/parseFloat(te)*1e3)/1e3),Fe=pl(Math.round(G/parseFloat(Z)*1e3)/1e3);if(Le===0||Fe===0||Ji(r)&&!ku(r))return;var fe=I.offset,Be=I.targetOffset,We=o0(H,fe),Ye=ce(We,2),Ve=Ye[0],Te=Ye[1],it=o0(F,Be),Ue=ce(it,2),nt=Ue[0],pt=Ue[1];F.x-=nt,F.y-=pt;var St=I.points||[],dt=ce(St,2),ht=dt[0],Pt=dt[1],At=a0(Pt),ct=a0(ht),ut=ya(F,At),ae=ya(H,ct),he=L({},I),xe=ut.x-ae.x+Ve,be=ut.y-ae.y+Te,Ce=ur(xe,be),de=ur(xe,be,De),Se=ya(F,["t","l"]),le=ya(H,["t","l"]),ie=ya(F,["b","r"]),me=ya(H,["b","r"]),ze=I.overflow||{},_e=ze.adjustX,Ke=ze.adjustY,Pe=ze.shiftX,Ze=ze.shiftY,wt=function(Wr){return typeof Wr=="boolean"?Wr:Wr>=0},jt,It,Et,Jt;pn();var pr=wt(Ke),He=ct[0]===At[0];if(pr&&ct[0]==="t"&&(It>Oe.bottom||h.current.bt)){var Qe=be;He?Qe-=G-oe:Qe=Se.y-me.y-Te;var gt=ur(xe,Qe),Mt=ur(xe,Qe,De);gt>Ce||gt===Ce&&(!ke||Mt>=de)?(h.current.bt=!0,be=Qe,Te=-Te,he.points=[xo(ct,0),xo(At,0)]):h.current.bt=!1}if(pr&&ct[0]==="b"&&(jt<Oe.top||h.current.tb)){var Ft=be;He?Ft+=G-oe:Ft=ie.y-le.y-Te;var yr=ur(xe,Ft),Cr=ur(xe,Ft,De);yr>Ce||yr===Ce&&(!ke||Cr>=de)?(h.current.tb=!0,be=Ft,Te=-Te,he.points=[xo(ct,0),xo(At,0)]):h.current.tb=!1}var st=wt(_e),$t=ct[1]===At[1];if(st&&ct[1]==="l"&&(Jt>Oe.right||h.current.rl)){var Bt=xe;$t?Bt-=J-se:Bt=Se.x-me.x-Ve;var Gt=ur(Bt,be),Mr=ur(Bt,be,De);Gt>Ce||Gt===Ce&&(!ke||Mr>=de)?(h.current.rl=!0,xe=Bt,Ve=-Ve,he.points=[xo(ct,1),xo(At,1)]):h.current.rl=!1}if(st&&ct[1]==="r"&&(Et<Oe.left||h.current.lr)){var Zr=xe;$t?Zr+=J-se:Zr=ie.x-le.x-Ve;var xn=ur(Zr,be),on=ur(Zr,be,De);xn>Ce||xn===Ce&&(!ke||on>=de)?(h.current.lr=!0,xe=Zr,Ve=-Ve,he.points=[xo(ct,1),xo(At,1)]):h.current.lr=!1}pn();var Tr=Pe===!0?0:Pe;typeof Tr=="number"&&(Et<De.left&&(xe-=Et-De.left-Ve,F.x+se<De.left+Tr&&(xe+=F.x-De.left+se-Tr)),Jt>De.right&&(xe-=Jt-De.right-Ve,F.x>De.right-Tr&&(xe+=F.x-De.right+Tr)));var an=Ze===!0?0:Ze;typeof an=="number"&&(jt<De.top&&(be-=jt-De.top-Te,F.y+oe<De.top+an&&(be+=F.y-De.top+oe-an)),It>De.bottom&&(be-=It-De.bottom-Te,F.y>De.bottom-an&&(be+=F.y-De.bottom+an)));var Jr=H.x+xe,zr=Jr+J,ln=H.y+be,Ct=ln+G,Je=F.x,vt=Je+se,Lt=F.y,_t=Lt+oe,tr=Math.max(Jr,Je),Dr=Math.min(zr,vt),mr=(tr+Dr)/2,_r=mr-Jr,xr=Math.max(ln,Lt),Ar=Math.min(Ct,_t),wn=(xr+Ar)/2,ft=wn-ln;i==null||i(t,he);var kt=Xe.right-H.x-(xe+H.width),Sr=Xe.bottom-H.y-(be+H.height);Le===1&&(xe=Math.round(xe),kt=Math.round(kt)),Fe===1&&(be=Math.round(be),Sr=Math.round(Sr));var hr={ready:!0,offsetX:xe/Le,offsetY:be/Fe,offsetR:kt/Le,offsetB:Sr/Fe,arrowX:_r/Le,arrowY:ft/Fe,scaleX:Le,scaleY:Fe,align:he};c(hr)}}),m=function(){f.current+=1;var y=f.current;Promise.resolve().then(function(){f.current===y&&g()})},b=function(){c(function(y){return L(L({},y),{},{ready:!1})})};return Wt(b,[n]),Wt(function(){e||b()},[e]),[u.ready,u.offsetX,u.offsetY,u.offsetR,u.offsetB,u.arrowX,u.arrowY,u.scaleX,u.scaleY,u.align,m]}function m6(e,t,r,n,o){Wt(function(){if(e&&t&&r){let f=function(){n(),o()};var a=t,i=r,l=Of(a),s=Of(i),u=Dl(i),c=new Set([u].concat(Ie(l),Ie(s)));return c.forEach(function(p){p.addEventListener("scroll",f,{passive:!0})}),u.addEventListener("resize",f,{passive:!0}),n(),function(){c.forEach(function(p){p.removeEventListener("scroll",f),u.removeEventListener("resize",f)})}}},[e,t,r])}function h6(e,t,r,n,o,a,i,l){var s=d.useRef(e);s.current=e;var u=d.useRef(!1);d.useEffect(function(){if(t&&n&&(!o||a)){var f=function(){u.current=!1},p=function(g){var m;s.current&&!i(((m=g.composedPath)===null||m===void 0||(m=m.call(g))===null||m===void 0?void 0:m[0])||g.target)&&!u.current&&l(!1)},h=Dl(n);h.addEventListener("pointerdown",f,!0),h.addEventListener("mousedown",p,!0),h.addEventListener("contextmenu",p,!0);var v=Ws(r);return v&&(v.addEventListener("mousedown",p,!0),v.addEventListener("contextmenu",p,!0)),function(){h.removeEventListener("pointerdown",f,!0),h.removeEventListener("mousedown",p,!0),h.removeEventListener("contextmenu",p,!0),v&&(v.removeEventListener("mousedown",p,!0),v.removeEventListener("contextmenu",p,!0))}}},[t,r,n,o,a]);function c(){u.current=!0}return c}var g6=["prefixCls","children","action","showAction","hideAction","popupVisible","defaultPopupVisible","onPopupVisibleChange","afterPopupVisibleChange","mouseEnterDelay","mouseLeaveDelay","focusDelay","blurDelay","mask","maskClosable","getPopupContainer","forceRender","autoDestroy","destroyPopupOnHide","popup","popupClassName","popupStyle","popupPlacement","builtinPlacements","popupAlign","zIndex","stretch","getPopupClassNameFromAlign","fresh","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"];function v6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:AC,t=d.forwardRef(function(r,n){var o=r.prefixCls,a=o===void 0?"rc-trigger-popup":o,i=r.children,l=r.action,s=l===void 0?"hover":l,u=r.showAction,c=r.hideAction,f=r.popupVisible,p=r.defaultPopupVisible,h=r.onPopupVisibleChange,v=r.afterPopupVisibleChange,g=r.mouseEnterDelay,m=r.mouseLeaveDelay,b=m===void 0?.1:m,y=r.focusDelay,C=r.blurDelay,D=r.mask,w=r.maskClosable,k=w===void 0?!0:w,E=r.getPopupContainer,x=r.forceRender,O=r.autoDestroy,j=r.destroyPopupOnHide,$=r.popup,P=r.popupClassName,A=r.popupStyle,B=r.popupPlacement,S=r.builtinPlacements,I=S===void 0?{}:S,N=r.popupAlign,F=r.zIndex,M=r.stretch,_=r.getPopupClassNameFromAlign,X=r.fresh,H=r.alignPoint,q=r.onPopupClick,Z=r.onPopupAlign,te=r.arrow,z=r.popupMotion,Y=r.maskMotion,V=r.popupTransitionName,U=r.popupAnimation,K=r.maskTransitionName,W=r.maskAnimation,re=r.className,G=r.getTriggerDOMNode,J=bt(r,g6),oe=O||j||!1,se=d.useState(!1),ge=ce(se,2),Ee=ge[0],je=ge[1];Wt(function(){je(_C())},[]);var ve=d.useRef({}),ye=d.useContext(Qv),ke=d.useMemo(function(){return{registerSubPopup:function(tt,Tt){ve.current[tt]=Tt,ye==null||ye.registerSubPopup(tt,Tt)}}},[ye]),we=Qp(),De=d.useState(null),Ne=ce(De,2),Oe=Ne[0],Xe=Ne[1],Le=d.useRef(null),Fe=nr(function(tt){Le.current=tt,Ji(tt)&&Oe!==tt&&Xe(tt),ye==null||ye.registerSubPopup(we,tt)}),fe=d.useState(null),Be=ce(fe,2),We=Be[0],Ye=Be[1],Ve=d.useRef(null),Te=nr(function(tt){Ji(tt)&&We!==tt&&(Ye(tt),Ve.current=tt)}),it=d.Children.only(i),Ue=(it==null?void 0:it.props)||{},nt={},pt=nr(function(tt){var Tt,Fr,$r=We;return($r==null?void 0:$r.contains(tt))||((Tt=Ws($r))===null||Tt===void 0?void 0:Tt.host)===tt||tt===$r||(Oe==null?void 0:Oe.contains(tt))||((Fr=Ws(Oe))===null||Fr===void 0?void 0:Fr.host)===tt||tt===Oe||Object.values(ve.current).some(function(dr){return(dr==null?void 0:dr.contains(tt))||tt===dr})}),St=t0(a,z,U,V),dt=t0(a,Y,W,K),ht=d.useState(p||!1),Pt=ce(ht,2),At=Pt[0],ct=Pt[1],ut=f??At,ae=nr(function(tt){f===void 0&&ct(tt)});Wt(function(){ct(f||!1)},[f]);var he=d.useRef(ut);he.current=ut;var xe=d.useRef([]);xe.current=[];var be=nr(function(tt){var Tt;ae(tt),((Tt=xe.current[xe.current.length-1])!==null&&Tt!==void 0?Tt:ut)!==tt&&(xe.current.push(tt),h==null||h(tt))}),Ce=d.useRef(),de=function(){clearTimeout(Ce.current)},Se=function(tt){var Tt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;de(),Tt===0?be(tt):Ce.current=setTimeout(function(){be(tt)},Tt*1e3)};d.useEffect(function(){return de},[]);var le=d.useState(!1),ie=ce(le,2),me=ie[0],ze=ie[1];Wt(function(tt){(!tt||ut)&&ze(!0)},[ut]);var _e=d.useState(null),Ke=ce(_e,2),Pe=Ke[0],Ze=Ke[1],wt=d.useState(null),jt=ce(wt,2),It=jt[0],Et=jt[1],Jt=function(tt){Et([tt.clientX,tt.clientY])},pr=p6(ut,Oe,H&&It!==null?It:We,B,I,N,Z),He=ce(pr,11),Qe=He[0],gt=He[1],Mt=He[2],Ft=He[3],yr=He[4],Cr=He[5],st=He[6],$t=He[7],Bt=He[8],Gt=He[9],Mr=He[10],Zr=c6(Ee,s,u,c),xn=ce(Zr,2),on=xn[0],Tr=xn[1],an=on.has("click"),Jr=Tr.has("click")||Tr.has("contextMenu"),zr=nr(function(){me||Mr()}),ln=function(){he.current&&H&&Jr&&Se(!1)};m6(ut,We,Oe,zr,ln),Wt(function(){zr()},[It,B]),Wt(function(){ut&&!(I!=null&&I[B])&&zr()},[JSON.stringify(N)]);var Ct=d.useMemo(function(){var tt=f6(I,a,Gt,H);return pe(tt,_==null?void 0:_(Gt))},[Gt,_,I,a,H]);d.useImperativeHandle(n,function(){return{nativeElement:Ve.current,popupElement:Le.current,forceAlign:zr}});var Je=d.useState(0),vt=ce(Je,2),Lt=vt[0],_t=vt[1],tr=d.useState(0),Dr=ce(tr,2),mr=Dr[0],_r=Dr[1],xr=function(){if(M&&We){var tt=We.getBoundingClientRect();_t(tt.width),_r(tt.height)}},Ar=function(){xr(),zr()},wn=function(tt){ze(!1),Mr(),v==null||v(tt)},ft=function(){return new Promise(function(tt){xr(),Ze(function(){return tt})})};Wt(function(){Pe&&(Mr(),Pe(),Ze(null))},[Pe]);function kt(tt,Tt,Fr,$r){nt[tt]=function(dr){var Fl;$r==null||$r(dr),Se(Tt,Fr);for(var Xu=arguments.length,Nm=new Array(Xu>1?Xu-1:0),Nl=1;Nl<Xu;Nl++)Nm[Nl-1]=arguments[Nl];(Fl=Ue[tt])===null||Fl===void 0||Fl.call.apply(Fl,[Ue,dr].concat(Nm))}}(an||Jr)&&(nt.onClick=function(tt){var Tt;he.current&&Jr?Se(!1):!he.current&&an&&(Jt(tt),Se(!0));for(var Fr=arguments.length,$r=new Array(Fr>1?Fr-1:0),dr=1;dr<Fr;dr++)$r[dr-1]=arguments[dr];(Tt=Ue.onClick)===null||Tt===void 0||Tt.call.apply(Tt,[Ue,tt].concat($r))});var Sr=h6(ut,Jr,We,Oe,D,k,pt,Se),hr=on.has("hover"),ur=Tr.has("hover"),pn,Wr;hr&&(kt("onMouseEnter",!0,g,function(tt){Jt(tt)}),kt("onPointerEnter",!0,g,function(tt){Jt(tt)}),pn=function(tt){(ut||me)&&Oe!==null&&Oe!==void 0&&Oe.contains(tt.target)&&Se(!0,g)},H&&(nt.onMouseMove=function(tt){var Tt;(Tt=Ue.onMouseMove)===null||Tt===void 0||Tt.call(Ue,tt)})),ur&&(kt("onMouseLeave",!1,b),kt("onPointerLeave",!1,b),Wr=function(){Se(!1,b)}),on.has("focus")&&kt("onFocus",!0,y),Tr.has("focus")&&kt("onBlur",!1,C),on.has("contextMenu")&&(nt.onContextMenu=function(tt){var Tt;he.current&&Tr.has("contextMenu")?Se(!1):(Jt(tt),Se(!0)),tt.preventDefault();for(var Fr=arguments.length,$r=new Array(Fr>1?Fr-1:0),dr=1;dr<Fr;dr++)$r[dr-1]=arguments[dr];(Tt=Ue.onContextMenu)===null||Tt===void 0||Tt.call.apply(Tt,[Ue,tt].concat($r))}),re&&(nt.className=pe(Ue.className,re));var Nn=d.useRef(!1);Nn.current||(Nn.current=x||ut||me);var En=L(L({},Ue),nt),io={},Al=["onContextMenu","onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur"];Al.forEach(function(tt){J[tt]&&(io[tt]=function(){for(var Tt,Fr=arguments.length,$r=new Array(Fr),dr=0;dr<Fr;dr++)$r[dr]=arguments[dr];(Tt=En[tt])===null||Tt===void 0||Tt.call.apply(Tt,[En].concat($r)),J[tt].apply(J,$r)})});var qu=d.cloneElement(it,L(L({},En),io)),Vu={x:Cr,y:st},Gu=te?L({},te!==!0?te:{}):null;return d.createElement(d.Fragment,null,d.createElement(ao,{disabled:!ut,ref:Te,onResize:Ar},d.createElement(u6,{getTriggerDOMNode:G},qu)),Nn.current&&d.createElement(Qv.Provider,{value:ke},d.createElement(s6,{portal:e,ref:Fe,prefixCls:a,popup:$,className:pe(P,Ct),style:A,target:We,onMouseEnter:pn,onMouseLeave:Wr,onPointerEnter:pn,zIndex:F,open:ut,keepDom:me,fresh:X,onClick:q,onPointerDownCapture:Sr,mask:D,motion:St,maskMotion:dt,onVisibleChanged:wn,onPrepare:ft,forceRender:x,autoDestroy:oe,getPopupContainer:E,align:Gt,arrow:Gu,arrowPos:Vu,ready:Qe,offsetX:gt,offsetY:Mt,offsetR:Ft,offsetB:yr,onAlign:zr,stretch:M,targetWidth:Lt/$t,targetHeight:mr/Bt})))});return t}const Iu=v6(AC);var b6=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],y6=function(e){var t=e===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"}}},C6=function(e,t){var r=e.prefixCls;e.disabled;var n=e.visible,o=e.children,a=e.popupElement,i=e.animation,l=e.transitionName,s=e.dropdownStyle,u=e.dropdownClassName,c=e.direction,f=c===void 0?"ltr":c,p=e.placement,h=e.builtinPlacements,v=e.dropdownMatchSelectWidth,g=e.dropdownRender,m=e.dropdownAlign,b=e.getPopupContainer,y=e.empty,C=e.getTriggerDOMNode,D=e.onPopupVisibleChange,w=e.onPopupMouseEnter,k=bt(e,b6),E="".concat(r,"-dropdown"),x=a;g&&(x=g(a));var O=d.useMemo(function(){return h||y6(v)},[h,v]),j=i?"".concat(E,"-").concat(i):l,$=typeof v=="number",P=d.useMemo(function(){return $?null:v===!1?"minWidth":"width"},[v,$]),A=s;$&&(A=L(L({},A),{},{width:v}));var B=d.useRef(null);return d.useImperativeHandle(t,function(){return{getPopupElement:function(){var S;return(S=B.current)===null||S===void 0?void 0:S.popupElement}}}),d.createElement(Iu,Me({},k,{showAction:D?["click"]:[],hideAction:D?["click"]:[],popupPlacement:p||(f==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:O,prefixCls:E,popupTransitionName:j,popup:d.createElement("div",{onMouseEnter:w},x),ref:B,stretch:P,popupAlign:m,popupVisible:n,getPopupContainer:b,popupClassName:pe(u,T({},"".concat(E,"-empty"),y)),popupStyle:A,getTriggerDOMNode:C,onPopupVisibleChange:D}),o)},x6=d.forwardRef(C6);function i0(e,t){var r=e.key,n;return"value"in e&&(n=e.value),r??(n!==void 0?n:"rc-index-key-".concat(t))}function Af(e){return typeof e<"u"&&!Number.isNaN(e)}function UC(e,t){var r=e||{},n=r.label,o=r.value,a=r.options,i=r.groupLabel,l=n||(t?"children":"label");return{label:l,value:o||"value",options:a||"options",groupLabel:i||l}}function w6(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.fieldNames,n=t.childrenAsData,o=[],a=UC(r,!1),i=a.label,l=a.value,s=a.options,u=a.groupLabel;function c(f,p){Array.isArray(f)&&f.forEach(function(h){if(p||!(s in h)){var v=h[l];o.push({key:i0(h,o.length),groupOption:p,data:h,label:h[i],value:v})}else{var g=h[u];g===void 0&&n&&(g=h.label),o.push({key:i0(h,o.length),group:!0,data:h,label:g}),c(h[s],!0)}})}return c(e,!1),o}function Ff(e){var t=L({},e);return"props"in t||Object.defineProperty(t,"props",{get:function(){return lr(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}var E6=function(e,t,r){if(!t||!t.length)return null;var n=!1,o=function i(l,s){var u=R1(s),c=u[0],f=u.slice(1);if(!c)return[l];var p=l.split(c);return n=n||p.length>1,p.reduce(function(h,v){return[].concat(Ie(h),Ie(i(v,f)))},[]).filter(Boolean)},a=o(e,t);return n?typeof r<"u"?a.slice(0,r):a:null},tm=d.createContext(null);function k6(e){var t=e.visible,r=e.values;if(!t)return null;var n=50;return d.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(r.slice(0,n).map(function(o){var a=o.label,i=o.value;return["number","string"].includes(at(a))?a:i}).join(", ")),r.length>n?", ...":null)}var D6=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],S6=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],Nf=function(e){return e==="tags"||e==="multiple"},$6=d.forwardRef(function(e,t){var r,n=e.id,o=e.prefixCls,a=e.className,i=e.showSearch,l=e.tagRender,s=e.direction,u=e.omitDomProps,c=e.displayValues,f=e.onDisplayValuesChange,p=e.emptyOptions,h=e.notFoundContent,v=h===void 0?"Not Found":h,g=e.onClear,m=e.mode,b=e.disabled,y=e.loading,C=e.getInputElement,D=e.getRawInputElement,w=e.open,k=e.defaultOpen,E=e.onDropdownVisibleChange,x=e.activeValue,O=e.onActiveValueChange,j=e.activeDescendantId,$=e.searchValue,P=e.autoClearSearchValue,A=e.onSearch,B=e.onSearchSplit,S=e.tokenSeparators,I=e.allowClear,N=e.prefix,F=e.suffixIcon,M=e.clearIcon,_=e.OptionList,X=e.animation,H=e.transitionName,q=e.dropdownStyle,Z=e.dropdownClassName,te=e.dropdownMatchSelectWidth,z=e.dropdownRender,Y=e.dropdownAlign,V=e.placement,U=e.builtinPlacements,K=e.getPopupContainer,W=e.showAction,re=W===void 0?[]:W,G=e.onFocus,J=e.onBlur,oe=e.onKeyUp,se=e.onKeyDown,ge=e.onMouseDown,Ee=bt(e,D6),je=Nf(m),ve=(i!==void 0?i:je)||m==="combobox",ye=L({},Ee);S6.forEach(function(Je){delete ye[Je]}),u==null||u.forEach(function(Je){delete ye[Je]});var ke=d.useState(!1),we=ce(ke,2),De=we[0],Ne=we[1];d.useEffect(function(){Ne(_C())},[]);var Oe=d.useRef(null),Xe=d.useRef(null),Le=d.useRef(null),Fe=d.useRef(null),fe=d.useRef(null),Be=d.useRef(!1),We=NP(),Ye=ce(We,3),Ve=Ye[0],Te=Ye[1],it=Ye[2];d.useImperativeHandle(t,function(){var Je,vt;return{focus:(Je=Fe.current)===null||Je===void 0?void 0:Je.focus,blur:(vt=Fe.current)===null||vt===void 0?void 0:vt.blur,scrollTo:function(Lt){var _t;return(_t=fe.current)===null||_t===void 0?void 0:_t.scrollTo(Lt)},nativeElement:Oe.current||Xe.current}});var Ue=d.useMemo(function(){var Je;if(m!=="combobox")return $;var vt=(Je=c[0])===null||Je===void 0?void 0:Je.value;return typeof vt=="string"||typeof vt=="number"?String(vt):""},[$,m,c]),nt=m==="combobox"&&typeof C=="function"&&C()||null,pt=typeof D=="function"&&D(),St=sa(Xe,pt==null||(r=pt.props)===null||r===void 0?void 0:r.ref),dt=d.useState(!1),ht=ce(dt,2),Pt=ht[0],At=ht[1];Wt(function(){At(!0)},[]);var ct=Gr(!1,{defaultValue:k,value:w}),ut=ce(ct,2),ae=ut[0],he=ut[1],xe=Pt?ae:!1,be=!v&&p;(b||be&&xe&&m==="combobox")&&(xe=!1);var Ce=be?!1:xe,de=d.useCallback(function(Je){var vt=Je!==void 0?Je:!xe;b||(he(vt),xe!==vt&&(E==null||E(vt)))},[b,xe,he,E]),Se=d.useMemo(function(){return(S||[]).some(function(Je){return[`
|
|
299
|
+
`,`\r
|
|
300
|
+
`].includes(Je)})},[S]),le=d.useContext(tm)||{},ie=le.maxCount,me=le.rawValues,ze=function(Je,vt,Lt){if(!(je&&Af(ie)&&(me==null?void 0:me.size)>=ie)){var _t=!0,tr=Je;O==null||O(null);var Dr=E6(Je,S,Af(ie)?ie-me.size:void 0),mr=Lt?null:Dr;return m!=="combobox"&&mr&&(tr="",B==null||B(mr),de(!1),_t=!1),A&&Ue!==tr&&A(tr,{source:vt?"typing":"effect"}),_t}},_e=function(Je){!Je||!Je.trim()||A(Je,{source:"submit"})};d.useEffect(function(){!xe&&!je&&m!=="combobox"&&ze("",!1,!1)},[xe]),d.useEffect(function(){ae&&b&&he(!1),b&&!Be.current&&Te(!1)},[b]);var Ke=HC(),Pe=ce(Ke,2),Ze=Pe[0],wt=Pe[1],jt=d.useRef(!1),It=function(Je){var vt=Ze(),Lt=Je.key,_t=Lt==="Enter";if(_t&&(m!=="combobox"&&Je.preventDefault(),xe||de(!0)),wt(!!Ue),Lt==="Backspace"&&!vt&&je&&!Ue&&c.length){for(var tr=Ie(c),Dr=null,mr=tr.length-1;mr>=0;mr-=1){var _r=tr[mr];if(!_r.disabled){tr.splice(mr,1),Dr=_r;break}}Dr&&f(tr,{type:"remove",values:[Dr]})}for(var xr=arguments.length,Ar=new Array(xr>1?xr-1:0),wn=1;wn<xr;wn++)Ar[wn-1]=arguments[wn];if(xe&&(!_t||!jt.current)){var ft;_t&&(jt.current=!0),(ft=fe.current)===null||ft===void 0||ft.onKeyDown.apply(ft,[Je].concat(Ar))}se==null||se.apply(void 0,[Je].concat(Ar))},Et=function(Je){for(var vt=arguments.length,Lt=new Array(vt>1?vt-1:0),_t=1;_t<vt;_t++)Lt[_t-1]=arguments[_t];if(xe){var tr;(tr=fe.current)===null||tr===void 0||tr.onKeyUp.apply(tr,[Je].concat(Lt))}Je.key==="Enter"&&(jt.current=!1),oe==null||oe.apply(void 0,[Je].concat(Lt))},Jt=function(Je){var vt=c.filter(function(Lt){return Lt!==Je});f(vt,{type:"remove",values:[Je]})},pr=function(){jt.current=!1},He=d.useRef(!1),Qe=function(){Te(!0),b||(G&&!He.current&&G.apply(void 0,arguments),re.includes("focus")&&de(!0)),He.current=!0},gt=function(){Be.current=!0,Te(!1,function(){He.current=!1,Be.current=!1,de(!1)}),!b&&(Ue&&(m==="tags"?A(Ue,{source:"submit"}):m==="multiple"&&A("",{source:"blur"})),J&&J.apply(void 0,arguments))},Mt=[];d.useEffect(function(){return function(){Mt.forEach(function(Je){return clearTimeout(Je)}),Mt.splice(0,Mt.length)}},[]);var Ft=function(Je){var vt,Lt=Je.target,_t=(vt=Le.current)===null||vt===void 0?void 0:vt.getPopupElement();if(_t&&_t.contains(Lt)){var tr=setTimeout(function(){var xr=Mt.indexOf(tr);if(xr!==-1&&Mt.splice(xr,1),it(),!De&&!_t.contains(document.activeElement)){var Ar;(Ar=Fe.current)===null||Ar===void 0||Ar.focus()}});Mt.push(tr)}for(var Dr=arguments.length,mr=new Array(Dr>1?Dr-1:0),_r=1;_r<Dr;_r++)mr[_r-1]=arguments[_r];ge==null||ge.apply(void 0,[Je].concat(mr))},yr=d.useState({}),Cr=ce(yr,2),st=Cr[1];function $t(){st({})}var Bt;pt&&(Bt=function(Je){de(Je)}),PP(function(){var Je;return[Oe.current,(Je=Le.current)===null||Je===void 0?void 0:Je.getPopupElement()]},Ce,de,!!pt);var Gt=d.useMemo(function(){return L(L({},e),{},{notFoundContent:v,open:xe,triggerOpen:Ce,id:n,showSearch:ve,multiple:je,toggleOpen:de})},[e,v,Ce,xe,n,ve,je,de]),Mr=!!F||y,Zr;Mr&&(Zr=d.createElement(ju,{className:pe("".concat(o,"-arrow"),T({},"".concat(o,"-arrow-loading"),y)),customizeIcon:F,customizeIconProps:{loading:y,searchValue:Ue,open:xe,focused:Ve,showSearch:ve}}));var xn=function(){var Je;g==null||g(),(Je=Fe.current)===null||Je===void 0||Je.focus(),f([],{type:"clear",values:c}),ze("",!1,!1)},on=AP(o,xn,c,I,M,b,Ue,m),Tr=on.allowClear,an=on.clearIcon,Jr=d.createElement(_,{ref:fe}),zr=pe(o,a,T(T(T(T(T(T(T(T(T(T({},"".concat(o,"-focused"),Ve),"".concat(o,"-multiple"),je),"".concat(o,"-single"),!je),"".concat(o,"-allow-clear"),I),"".concat(o,"-show-arrow"),Mr),"".concat(o,"-disabled"),b),"".concat(o,"-loading"),y),"".concat(o,"-open"),xe),"".concat(o,"-customize-input"),nt),"".concat(o,"-show-search"),ve)),ln=d.createElement(x6,{ref:Le,disabled:b,prefixCls:o,visible:Ce,popupElement:Jr,animation:X,transitionName:H,dropdownStyle:q,dropdownClassName:Z,direction:s,dropdownMatchSelectWidth:te,dropdownRender:z,dropdownAlign:Y,placement:V,builtinPlacements:U,getPopupContainer:K,empty:p,getTriggerDOMNode:function(Je){return Xe.current||Je},onPopupVisibleChange:Bt,onPopupMouseEnter:$t},pt?d.cloneElement(pt,{ref:St}):d.createElement(o6,Me({},e,{domRef:Xe,prefixCls:o,inputElement:nt,ref:Fe,id:n,prefix:N,showSearch:ve,autoClearSearchValue:P,mode:m,activeDescendantId:j,tagRender:l,values:c,open:xe,onToggleOpen:de,activeValue:x,searchValue:Ue,onSearch:ze,onSearchSubmit:_e,onRemove:Jt,tokenWithEnter:Se,onInputBlur:pr}))),Ct;return pt?Ct=ln:Ct=d.createElement("div",Me({className:zr},ye,{ref:Oe,onMouseDown:Ft,onKeyDown:It,onKeyUp:Et,onFocus:Qe,onBlur:gt}),d.createElement(k6,{visible:Ve&&!xe,values:c}),ln,Zr,Tr&&an),d.createElement(LC.Provider,{value:Gt},Ct)}),rm=function(){return null};rm.isSelectOptGroup=!0;var nm=function(){return null};nm.isSelectOption=!0;var YC=d.forwardRef(function(e,t){var r=e.height,n=e.offsetY,o=e.offsetX,a=e.children,i=e.prefixCls,l=e.onInnerResize,s=e.innerProps,u=e.rtl,c=e.extra,f={},p={display:"flex",flexDirection:"column"};return n!==void 0&&(f={height:r,position:"relative",overflow:"hidden"},p=L(L({},p),{},T(T(T(T(T({transform:"translateY(".concat(n,"px)")},u?"marginRight":"marginLeft",-o),"position","absolute"),"left",0),"right",0),"top",0))),d.createElement("div",{style:f},d.createElement(ao,{onResize:function(h){var v=h.offsetHeight;v&&l&&l()}},d.createElement("div",Me({style:p,className:pe(T({},"".concat(i,"-holder-inner"),i)),ref:t},s),a,c)))});YC.displayName="Filler";function B6(e){var t=e.children,r=e.setRef,n=d.useCallback(function(o){r(o)},[]);return d.cloneElement(t,{ref:n})}function O6(e,t,r,n,o,a,i,l){var s=l.getKey;return e.slice(t,r+1).map(function(u,c){var f=t+c,p=i(u,f,{style:{width:n},offsetX:o}),h=s(u);return d.createElement(B6,{key:h,setRef:function(v){return a(u,v)}},p)})}function A6(e,t,r){var n=e.length,o=t.length,a,i;if(n===0&&o===0)return null;n<o?(a=e,i=t):(a=t,i=e);var l={__EMPTY_ITEM__:!0};function s(v){return v!==void 0?r(v):l}for(var u=null,c=Math.abs(n-o)!==1,f=0;f<i.length;f+=1){var p=s(a[f]),h=s(i[f]);if(p!==h){u=f,c=c||p!==s(i[f+1]);break}}return u===null?null:{index:u,multiple:c}}function F6(e,t,r){var n=d.useState(e),o=ce(n,2),a=o[0],i=o[1],l=d.useState(null),s=ce(l,2),u=s[0],c=s[1];return d.useEffect(function(){var f=A6(a||[],e||[],t);(f==null?void 0:f.index)!==void 0&&c(e[f.index]),i(e)},[e]),[u]}var l0=(typeof navigator>"u"?"undefined":at(navigator))==="object"&&/Firefox/i.test(navigator.userAgent);const ZC=(function(e,t,r,n){var o=qe(!1),a=qe(null);function i(){clearTimeout(a.current),o.current=!0,a.current=setTimeout(function(){o.current=!1},50)}var l=qe({top:e,bottom:t,left:r,right:n});return l.current.top=e,l.current.bottom=t,l.current.left=r,l.current.right=n,function(s,u){var c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,f=s?u<0&&l.current.left||u>0&&l.current.right:u<0&&l.current.top||u>0&&l.current.bottom;return c&&f?(clearTimeout(a.current),o.current=!1):(!f||o.current)&&i(),!o.current&&f}});function N6(e,t,r,n,o,a,i){var l=qe(0),s=qe(null),u=qe(null),c=qe(!1),f=ZC(t,r,n,o);function p(y,C){if(qt.cancel(s.current),!f(!1,C)){var D=y;if(!D._virtualHandled)D._virtualHandled=!0;else return;l.current+=C,u.current=C,l0||D.preventDefault(),s.current=qt(function(){var w=c.current?10:1;i(l.current*w,!1),l.current=0})}}function h(y,C){i(C,!0),l0||y.preventDefault()}var v=qe(null),g=qe(null);function m(y){if(e){qt.cancel(g.current),g.current=qt(function(){v.current=null},2);var C=y.deltaX,D=y.deltaY,w=y.shiftKey,k=C,E=D;(v.current==="sx"||!v.current&&w&&D&&!C)&&(k=D,E=0,v.current="sx");var x=Math.abs(k),O=Math.abs(E);v.current===null&&(v.current=a&&x>O?"x":"y"),v.current==="y"?p(y,E):h(y,k)}}function b(y){e&&(c.current=y.detail===u.current)}return[m,b]}function P6(e,t,r,n){var o=d.useMemo(function(){return[new Map,[]]},[e,r.id,n]),a=ce(o,2),i=a[0],l=a[1],s=function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:u,f=i.get(u),p=i.get(c);if(f===void 0||p===void 0)for(var h=e.length,v=l.length;v<h;v+=1){var g,m=e[v],b=t(m);i.set(b,v);var y=(g=r.get(b))!==null&&g!==void 0?g:n;if(l[v]=(l[v-1]||0)+y,b===u&&(f=v),b===c&&(p=v),f!==void 0&&p!==void 0)break}return{top:l[f-1]||0,bottom:l[p]}};return s}var j6=(function(){function e(){vr(this,e),T(this,"maps",void 0),T(this,"id",0),T(this,"diffRecords",new Map),this.maps=Object.create(null)}return br(e,[{key:"set",value:function(t,r){this.diffRecords.set(t,this.maps[t]),this.maps[t]=r,this.id+=1}},{key:"get",value:function(t){return this.maps[t]}},{key:"resetRecord",value:function(){this.diffRecords.clear()}},{key:"getRecord",value:function(){return this.diffRecords}}]),e})();function s0(e){var t=parseFloat(e);return isNaN(t)?0:t}function I6(e,t,r){var n=d.useState(0),o=ce(n,2),a=o[0],i=o[1],l=qe(new Map),s=qe(new j6),u=qe(0);function c(){u.current+=1}function f(){var h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;c();var v=function(){var m=!1;l.current.forEach(function(b,y){if(b&&b.offsetParent){var C=b.offsetHeight,D=getComputedStyle(b),w=D.marginTop,k=D.marginBottom,E=s0(w),x=s0(k),O=C+E+x;s.current.get(y)!==O&&(s.current.set(y,O),m=!0)}}),m&&i(function(b){return b+1})};if(h)v();else{u.current+=1;var g=u.current;Promise.resolve().then(function(){g===u.current&&v()})}}function p(h,v){var g=e(h);l.current.get(g),v?(l.current.set(g,v),f()):l.current.delete(g)}return Ot(function(){return c},[]),[p,f,s.current,a]}var u0=14/15;function R6(e,t,r){var n=qe(!1),o=qe(0),a=qe(0),i=qe(null),l=qe(null),s,u=function(p){if(n.current){var h=Math.ceil(p.touches[0].pageX),v=Math.ceil(p.touches[0].pageY),g=o.current-h,m=a.current-v,b=Math.abs(g)>Math.abs(m);b?o.current=h:a.current=v;var y=r(b,b?g:m,!1,p);y&&p.preventDefault(),clearInterval(l.current),y&&(l.current=setInterval(function(){b?g*=u0:m*=u0;var C=Math.floor(b?g:m);(!r(b,C,!0)||Math.abs(C)<=.1)&&clearInterval(l.current)},16))}},c=function(){n.current=!1,s()},f=function(p){s(),p.touches.length===1&&!n.current&&(n.current=!0,o.current=Math.ceil(p.touches[0].pageX),a.current=Math.ceil(p.touches[0].pageY),i.current=p.target,i.current.addEventListener("touchmove",u,{passive:!1}),i.current.addEventListener("touchend",c,{passive:!0}))};s=function(){i.current&&(i.current.removeEventListener("touchmove",u),i.current.removeEventListener("touchend",c))},Wt(function(){return e&&t.current.addEventListener("touchstart",f,{passive:!0}),function(){var p;(p=t.current)===null||p===void 0||p.removeEventListener("touchstart",f),s(),clearInterval(l.current)}},[e])}function c0(e){return Math.floor(Math.pow(e,.5))}function Pf(e,t){var r="touches"in e?e.touches[0]:e;return r[t?"pageX":"pageY"]-window[t?"scrollX":"scrollY"]}function M6(e,t,r){d.useEffect(function(){var n=t.current;if(e&&n){var o=!1,a,i,l=function(){qt.cancel(a)},s=function p(){l(),a=qt(function(){r(i),p()})},u=function(p){if(!(p.target.draggable||p.button!==0)){var h=p;h._virtualHandled||(h._virtualHandled=!0,o=!0)}},c=function(){o=!1,l()},f=function(p){if(o){var h=Pf(p,!1),v=n.getBoundingClientRect(),g=v.top,m=v.bottom;if(h<=g){var b=g-h;i=-c0(b),s()}else if(h>=m){var y=h-m;i=c0(y),s()}else l()}};return n.addEventListener("mousedown",u),n.ownerDocument.addEventListener("mouseup",c),n.ownerDocument.addEventListener("mousemove",f),function(){n.removeEventListener("mousedown",u),n.ownerDocument.removeEventListener("mouseup",c),n.ownerDocument.removeEventListener("mousemove",f),l()}}},[e])}var T6=10;function z6(e,t,r,n,o,a,i,l){var s=d.useRef(),u=d.useState(null),c=ce(u,2),f=c[0],p=c[1];return Wt(function(){if(f&&f.times<T6){if(!e.current){p(function(M){return L({},M)});return}a();var h=f.targetAlign,v=f.originAlign,g=f.index,m=f.offset,b=e.current.clientHeight,y=!1,C=h,D=null;if(b){for(var w=h||v,k=0,E=0,x=0,O=Math.min(t.length-1,g),j=0;j<=O;j+=1){var $=o(t[j]);E=k;var P=r.get($);x=E+(P===void 0?n:P),k=x}for(var A=w==="top"?m:b-m,B=O;B>=0;B-=1){var S=o(t[B]),I=r.get(S);if(I===void 0){y=!0;break}if(A-=I,A<=0)break}switch(w){case"top":D=E-m;break;case"bottom":D=x-b+m;break;default:{var N=e.current.scrollTop,F=N+b;E<N?C="top":x>F&&(C="bottom")}}D!==null&&i(D),D!==f.lastTop&&(y=!0)}y&&p(L(L({},f),{},{times:f.times+1,targetAlign:C,lastTop:D}))}},[f,e.current]),function(h){if(h==null){l();return}if(qt.cancel(s.current),typeof h=="number")i(h);else if(h&&at(h)==="object"){var v,g=h.align;"index"in h?v=h.index:v=t.findIndex(function(y){return o(y)===h.key});var m=h.offset,b=m===void 0?0:m;p({times:0,index:v,offset:b,originAlign:g})}}}var d0=d.forwardRef(function(e,t){var r=e.prefixCls,n=e.rtl,o=e.scrollOffset,a=e.scrollRange,i=e.onStartMove,l=e.onStopMove,s=e.onScroll,u=e.horizontal,c=e.spinSize,f=e.containerSize,p=e.style,h=e.thumbStyle,v=e.showScrollBar,g=d.useState(!1),m=ce(g,2),b=m[0],y=m[1],C=d.useState(null),D=ce(C,2),w=D[0],k=D[1],E=d.useState(null),x=ce(E,2),O=x[0],j=x[1],$=!n,P=d.useRef(),A=d.useRef(),B=d.useState(v),S=ce(B,2),I=S[0],N=S[1],F=d.useRef(),M=function(){v===!0||v===!1||(clearTimeout(F.current),N(!0),F.current=setTimeout(function(){N(!1)},3e3))},_=a-f||0,X=f-c||0,H=d.useMemo(function(){if(o===0||_===0)return 0;var W=o/_;return W*X},[o,_,X]),q=function(W){W.stopPropagation(),W.preventDefault()},Z=d.useRef({top:H,dragging:b,pageY:w,startTop:O});Z.current={top:H,dragging:b,pageY:w,startTop:O};var te=function(W){y(!0),k(Pf(W,u)),j(Z.current.top),i(),W.stopPropagation(),W.preventDefault()};d.useEffect(function(){var W=function(J){J.preventDefault()},re=P.current,G=A.current;return re.addEventListener("touchstart",W,{passive:!1}),G.addEventListener("touchstart",te,{passive:!1}),function(){re.removeEventListener("touchstart",W),G.removeEventListener("touchstart",te)}},[]);var z=d.useRef();z.current=_;var Y=d.useRef();Y.current=X,d.useEffect(function(){if(b){var W,re=function(J){var oe=Z.current,se=oe.dragging,ge=oe.pageY,Ee=oe.startTop;qt.cancel(W);var je=P.current.getBoundingClientRect(),ve=f/(u?je.width:je.height);if(se){var ye=(Pf(J,u)-ge)*ve,ke=Ee;!$&&u?ke-=ye:ke+=ye;var we=z.current,De=Y.current,Ne=De?ke/De:0,Oe=Math.ceil(Ne*we);Oe=Math.max(Oe,0),Oe=Math.min(Oe,we),W=qt(function(){s(Oe,u)})}},G=function(){y(!1),l()};return window.addEventListener("mousemove",re,{passive:!0}),window.addEventListener("touchmove",re,{passive:!0}),window.addEventListener("mouseup",G,{passive:!0}),window.addEventListener("touchend",G,{passive:!0}),function(){window.removeEventListener("mousemove",re),window.removeEventListener("touchmove",re),window.removeEventListener("mouseup",G),window.removeEventListener("touchend",G),qt.cancel(W)}}},[b]),d.useEffect(function(){return M(),function(){clearTimeout(F.current)}},[o]),d.useImperativeHandle(t,function(){return{delayHidden:M}});var V="".concat(r,"-scrollbar"),U={position:"absolute",visibility:I?null:"hidden"},K={position:"absolute",borderRadius:99,background:"var(--rc-virtual-list-scrollbar-bg, rgba(0, 0, 0, 0.5))",cursor:"pointer",userSelect:"none"};return u?(Object.assign(U,{height:8,left:0,right:0,bottom:0}),Object.assign(K,T({height:"100%",width:c},$?"left":"right",H))):(Object.assign(U,T({width:8,top:0,bottom:0},$?"right":"left",0)),Object.assign(K,{width:"100%",height:c,top:H})),d.createElement("div",{ref:P,className:pe(V,T(T(T({},"".concat(V,"-horizontal"),u),"".concat(V,"-vertical"),!u),"".concat(V,"-visible"),I)),style:L(L({},U),p),onMouseDown:q,onMouseMove:M},d.createElement("div",{ref:A,className:pe("".concat(V,"-thumb"),T({},"".concat(V,"-thumb-moving"),b)),style:L(L({},K),h),onMouseDown:te}))}),_6=20;function f0(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=e/t*e;return isNaN(r)&&(r=0),r=Math.max(r,_6),Math.floor(r)}var L6=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],H6=[],W6={overflowY:"auto",overflowAnchor:"none"};function K6(e,t){var r=e.prefixCls,n=r===void 0?"rc-virtual-list":r,o=e.className,a=e.height,i=e.itemHeight,l=e.fullHeight,s=l===void 0?!0:l,u=e.style,c=e.data,f=e.children,p=e.itemKey,h=e.virtual,v=e.direction,g=e.scrollWidth,m=e.component,b=m===void 0?"div":m,y=e.onScroll,C=e.onVirtualScroll,D=e.onVisibleChange,w=e.innerProps,k=e.extraRender,E=e.styles,x=e.showScrollBar,O=x===void 0?"optional":x,j=bt(e,L6),$=d.useCallback(function(He){return typeof p=="function"?p(He):He==null?void 0:He[p]},[p]),P=I6($),A=ce(P,4),B=A[0],S=A[1],I=A[2],N=A[3],F=!!(h!==!1&&a&&i),M=d.useMemo(function(){return Object.values(I.maps).reduce(function(He,Qe){return He+Qe},0)},[I.id,I.maps]),_=F&&c&&(Math.max(i*c.length,M)>a||!!g),X=v==="rtl",H=pe(n,T({},"".concat(n,"-rtl"),X),o),q=c||H6,Z=qe(),te=qe(),z=qe(),Y=yt(0),V=ce(Y,2),U=V[0],K=V[1],W=yt(0),re=ce(W,2),G=re[0],J=re[1],oe=yt(!1),se=ce(oe,2),ge=se[0],Ee=se[1],je=function(){Ee(!0)},ve=function(){Ee(!1)},ye={getKey:$};function ke(He){K(function(Qe){var gt;typeof He=="function"?gt=He(Qe):gt=He;var Mt=At(gt);return Z.current.scrollTop=Mt,Mt})}var we=qe({start:0,end:q.length}),De=qe(),Ne=F6(q,$),Oe=ce(Ne,1),Xe=Oe[0];De.current=Xe;var Le=d.useMemo(function(){if(!F)return{scrollHeight:void 0,start:0,end:q.length-1,offset:void 0};if(!_){var He;return{scrollHeight:((He=te.current)===null||He===void 0?void 0:He.offsetHeight)||0,start:0,end:q.length-1,offset:void 0}}for(var Qe=0,gt,Mt,Ft,yr=q.length,Cr=0;Cr<yr;Cr+=1){var st=q[Cr],$t=$(st),Bt=I.get($t),Gt=Qe+(Bt===void 0?i:Bt);Gt>=U&>===void 0&&(gt=Cr,Mt=Qe),Gt>U+a&&Ft===void 0&&(Ft=Cr),Qe=Gt}return gt===void 0&&(gt=0,Mt=0,Ft=Math.ceil(a/i)),Ft===void 0&&(Ft=q.length-1),Ft=Math.min(Ft+1,q.length-1),{scrollHeight:Qe,start:gt,end:Ft,offset:Mt}},[_,F,U,q,N,a]),Fe=Le.scrollHeight,fe=Le.start,Be=Le.end,We=Le.offset;we.current.start=fe,we.current.end=Be,d.useLayoutEffect(function(){var He=I.getRecord();if(He.size===1){var Qe=Array.from(He.keys())[0],gt=He.get(Qe),Mt=q[fe];if(Mt&>===void 0){var Ft=$(Mt);if(Ft===Qe){var yr=I.get(Qe),Cr=yr-i;ke(function(st){return st+Cr})}}}I.resetRecord()},[Fe]);var Ye=d.useState({width:0,height:a}),Ve=ce(Ye,2),Te=Ve[0],it=Ve[1],Ue=function(He){it({width:He.offsetWidth,height:He.offsetHeight})},nt=qe(),pt=qe(),St=d.useMemo(function(){return f0(Te.width,g)},[Te.width,g]),dt=d.useMemo(function(){return f0(Te.height,Fe)},[Te.height,Fe]),ht=Fe-a,Pt=qe(ht);Pt.current=ht;function At(He){var Qe=He;return Number.isNaN(Pt.current)||(Qe=Math.min(Qe,Pt.current)),Qe=Math.max(Qe,0),Qe}var ct=U<=0,ut=U>=ht,ae=G<=0,he=G>=g,xe=ZC(ct,ut,ae,he),be=function(){return{x:X?-G:G,y:U}},Ce=qe(be()),de=nr(function(He){if(C){var Qe=L(L({},be()),He);(Ce.current.x!==Qe.x||Ce.current.y!==Qe.y)&&(C(Qe),Ce.current=Qe)}});function Se(He,Qe){var gt=He;Qe?(ud(function(){J(gt)}),de()):ke(gt)}function le(He){var Qe=He.currentTarget.scrollTop;Qe!==U&&ke(Qe),y==null||y(He),de()}var ie=function(He){var Qe=He,gt=g?g-Te.width:0;return Qe=Math.max(Qe,0),Qe=Math.min(Qe,gt),Qe},me=nr(function(He,Qe){Qe?(ud(function(){J(function(gt){var Mt=gt+(X?-He:He);return ie(Mt)})}),de()):ke(function(gt){var Mt=gt+He;return Mt})}),ze=N6(F,ct,ut,ae,he,!!g,me),_e=ce(ze,2),Ke=_e[0],Pe=_e[1];R6(F,Z,function(He,Qe,gt,Mt){var Ft=Mt;return xe(He,Qe,gt)?!1:!Ft||!Ft._virtualHandled?(Ft&&(Ft._virtualHandled=!0),Ke({preventDefault:function(){},deltaX:He?Qe:0,deltaY:He?0:Qe}),!0):!1}),M6(_,Z,function(He){ke(function(Qe){return Qe+He})}),Wt(function(){function He(gt){var Mt=ct&>.detail<0,Ft=ut&>.detail>0;F&&!Mt&&!Ft&>.preventDefault()}var Qe=Z.current;return Qe.addEventListener("wheel",Ke,{passive:!1}),Qe.addEventListener("DOMMouseScroll",Pe,{passive:!0}),Qe.addEventListener("MozMousePixelScroll",He,{passive:!1}),function(){Qe.removeEventListener("wheel",Ke),Qe.removeEventListener("DOMMouseScroll",Pe),Qe.removeEventListener("MozMousePixelScroll",He)}},[F,ct,ut]),Wt(function(){if(g){var He=ie(G);J(He),de({x:He})}},[Te.width,g]);var Ze=function(){var He,Qe;(He=nt.current)===null||He===void 0||He.delayHidden(),(Qe=pt.current)===null||Qe===void 0||Qe.delayHidden()},wt=z6(Z,q,I,i,$,function(){return S(!0)},ke,Ze);d.useImperativeHandle(t,function(){return{nativeElement:z.current,getScrollInfo:be,scrollTo:function(He){function Qe(gt){return gt&&at(gt)==="object"&&("left"in gt||"top"in gt)}Qe(He)?(He.left!==void 0&&J(ie(He.left)),wt(He.top)):wt(He)}}}),Wt(function(){if(D){var He=q.slice(fe,Be+1);D(He,q)}},[fe,Be,q]);var jt=P6(q,$,I,i),It=k==null?void 0:k({start:fe,end:Be,virtual:_,offsetX:G,offsetY:We,rtl:X,getSize:jt}),Et=O6(q,fe,Be,g,G,B,f,ye),Jt=null;a&&(Jt=L(T({},s?"height":"maxHeight",a),W6),F&&(Jt.overflowY="hidden",g&&(Jt.overflowX="hidden"),ge&&(Jt.pointerEvents="none")));var pr={};return X&&(pr.dir="rtl"),d.createElement("div",Me({ref:z,style:L(L({},u),{},{position:"relative"}),className:H},pr,j),d.createElement(ao,{onResize:Ue},d.createElement(b,{className:"".concat(n,"-holder"),style:Jt,ref:Z,onScroll:le,onMouseEnter:Ze},d.createElement(YC,{prefixCls:n,height:Fe,offsetX:G,offsetY:We,scrollWidth:g,onInnerResize:S,ref:te,innerProps:w,rtl:X,extra:It},Et))),_&&Fe>a&&d.createElement(d0,{ref:nt,prefixCls:n,scrollOffset:U,scrollRange:Fe,rtl:X,onScroll:Se,onStartMove:je,onStopMove:ve,spinSize:dt,containerSize:Te.height,style:E==null?void 0:E.verticalScrollBar,thumbStyle:E==null?void 0:E.verticalScrollBarThumb,showScrollBar:O}),_&&g>Te.width&&d.createElement(d0,{ref:pt,prefixCls:n,scrollOffset:G,scrollRange:g,rtl:X,onScroll:Se,onStartMove:je,onStopMove:ve,spinSize:St,containerSize:Te.width,horizontal:!0,style:E==null?void 0:E.horizontalScrollBar,thumbStyle:E==null?void 0:E.horizontalScrollBarThumb,showScrollBar:O}))}var Ru=d.forwardRef(K6);Ru.displayName="List";function q6(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var V6=["disabled","title","children","style","className"];function p0(e){return typeof e=="string"||typeof e=="number"}var G6=function(e,t){var r=FP(),n=r.prefixCls,o=r.id,a=r.open,i=r.multiple,l=r.mode,s=r.searchValue,u=r.toggleOpen,c=r.notFoundContent,f=r.onPopupScroll,p=d.useContext(tm),h=p.maxCount,v=p.flattenOptions,g=p.onActiveValue,m=p.defaultActiveFirstOption,b=p.onSelect,y=p.menuItemSelectedIcon,C=p.rawValues,D=p.fieldNames,w=p.virtual,k=p.direction,E=p.listHeight,x=p.listItemHeight,O=p.optionRender,j="".concat(n,"-item"),$=la(function(){return v},[a,v],function(K,W){return W[0]&&K[1]!==W[1]}),P=d.useRef(null),A=d.useMemo(function(){return i&&Af(h)&&(C==null?void 0:C.size)>=h},[i,h,C==null?void 0:C.size]),B=function(K){K.preventDefault()},S=function(K){var W;(W=P.current)===null||W===void 0||W.scrollTo(typeof K=="number"?{index:K}:K)},I=d.useCallback(function(K){return l==="combobox"?!1:C.has(K)},[l,Ie(C).toString(),C.size]),N=function(K){for(var W=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,re=$.length,G=0;G<re;G+=1){var J=(K+G*W+re)%re,oe=$[J]||{},se=oe.group,ge=oe.data;if(!se&&!(ge!=null&&ge.disabled)&&(I(ge.value)||!A))return J}return-1},F=d.useState(function(){return N(0)}),M=ce(F,2),_=M[0],X=M[1],H=function(K){var W=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;X(K);var re={source:W?"keyboard":"mouse"},G=$[K];if(!G){g(null,-1,re);return}g(G.value,K,re)};Ot(function(){H(m!==!1?N(0):-1)},[$.length,s]);var q=d.useCallback(function(K){return l==="combobox"?String(K).toLowerCase()===s.toLowerCase():C.has(K)},[l,s,Ie(C).toString(),C.size]);Ot(function(){var K=setTimeout(function(){if(!i&&a&&C.size===1){var re=Array.from(C)[0],G=$.findIndex(function(J){var oe=J.data;return s?String(oe.value).startsWith(s):oe.value===re});G!==-1&&(H(G),S(G))}});if(a){var W;(W=P.current)===null||W===void 0||W.scrollTo(void 0)}return function(){return clearTimeout(K)}},[a,s]);var Z=function(K){K!==void 0&&b(K,{selected:!C.has(K)}),i||u(!1)};if(d.useImperativeHandle(t,function(){return{onKeyDown:function(K){var W=K.which,re=K.ctrlKey;switch(W){case rt.N:case rt.P:case rt.UP:case rt.DOWN:{var G=0;if(W===rt.UP?G=-1:W===rt.DOWN?G=1:q6()&&re&&(W===rt.N?G=1:W===rt.P&&(G=-1)),G!==0){var J=N(_+G,G);S(J),H(J,!0)}break}case rt.TAB:case rt.ENTER:{var oe,se=$[_];se&&!(se!=null&&(oe=se.data)!==null&&oe!==void 0&&oe.disabled)&&!A?Z(se.value):Z(void 0),a&&K.preventDefault();break}case rt.ESC:u(!1),a&&K.stopPropagation()}},onKeyUp:function(){},scrollTo:function(K){S(K)}}}),$.length===0)return d.createElement("div",{role:"listbox",id:"".concat(o,"_list"),className:"".concat(j,"-empty"),onMouseDown:B},c);var te=Object.keys(D).map(function(K){return D[K]}),z=function(K){return K.label};function Y(K,W){var re=K.group;return{role:re?"presentation":"option",id:"".concat(o,"_list_").concat(W)}}var V=function(K){var W=$[K];if(!W)return null;var re=W.data||{},G=re.value,J=W.group,oe=Qn(re,!0),se=z(W);return W?d.createElement("div",Me({"aria-label":typeof se=="string"&&!J?se:null},oe,{key:K},Y(W,K),{"aria-selected":q(G)}),G):null},U={role:"listbox",id:"".concat(o,"_list")};return d.createElement(d.Fragment,null,w&&d.createElement("div",Me({},U,{style:{height:0,width:0,overflow:"hidden"}}),V(_-1),V(_),V(_+1)),d.createElement(Ru,{itemKey:"key",ref:P,data:$,height:E,itemHeight:x,fullHeight:!1,onMouseDown:B,onScroll:f,virtual:w,direction:k,innerProps:w?null:U},function(K,W){var re=K.group,G=K.groupOption,J=K.data,oe=K.label,se=K.value,ge=J.key;if(re){var Ee,je=(Ee=J.title)!==null&&Ee!==void 0?Ee:p0(oe)?oe.toString():void 0;return d.createElement("div",{className:pe(j,"".concat(j,"-group"),J.className),title:je},oe!==void 0?oe:ge)}var ve=J.disabled,ye=J.title;J.children;var ke=J.style,we=J.className,De=bt(J,V6),Ne=fn(De,te),Oe=I(se),Xe=ve||!Oe&&A,Le="".concat(j,"-option"),Fe=pe(j,Le,we,T(T(T(T({},"".concat(Le,"-grouped"),G),"".concat(Le,"-active"),_===W&&!Xe),"".concat(Le,"-disabled"),Xe),"".concat(Le,"-selected"),Oe)),fe=z(K),Be=!y||typeof y=="function"||Oe,We=typeof fe=="number"?fe:fe||se,Ye=p0(We)?We.toString():void 0;return ye!==void 0&&(Ye=ye),d.createElement("div",Me({},Qn(Ne),w?{}:Y(K,W),{"aria-selected":q(se),className:Fe,title:Ye,onMouseMove:function(){_===W||Xe||H(W)},onClick:function(){Xe||Z(se)},style:ke}),d.createElement("div",{className:"".concat(Le,"-content")},typeof O=="function"?O(K,{index:W}):We),d.isValidElement(y)||Oe,Be&&d.createElement(ju,{className:"".concat(j,"-option-state"),customizeIcon:y,customizeIconProps:{value:se,disabled:Xe,isSelected:Oe}},Oe?"\u2713":null))}))},X6=d.forwardRef(G6);const U6=(function(e,t){var r=d.useRef({values:new Map,options:new Map}),n=d.useMemo(function(){var a=r.current,i=a.values,l=a.options,s=e.map(function(f){if(f.label===void 0){var p;return L(L({},f),{},{label:(p=i.get(f.value))===null||p===void 0?void 0:p.label})}return f}),u=new Map,c=new Map;return s.forEach(function(f){u.set(f.value,f),c.set(f.value,t.get(f.value)||l.get(f.value))}),r.current.values=u,r.current.options=c,s},[e,t]),o=d.useCallback(function(a){return t.get(a)||r.current.options.get(a)},[t]);return[n,o]});function Uc(e,t){return GC(e).join("").toUpperCase().includes(t)}const Y6=(function(e,t,r,n,o){return d.useMemo(function(){if(!r||n===!1)return e;var a=t.options,i=t.label,l=t.value,s=[],u=typeof n=="function",c=r.toUpperCase(),f=u?n:function(h,v){return o?Uc(v[o],c):v[a]?Uc(v[i!=="children"?i:"label"],c):Uc(v[l],c)},p=u?function(h){return Ff(h)}:function(h){return h};return e.forEach(function(h){if(h[a]){var v=f(r,p(h));if(v)s.push(h);else{var g=h[a].filter(function(m){return f(r,p(m))});g.length&&s.push(L(L({},h),{},T({},a,g)))}return}f(r,p(h))&&s.push(h)}),s},[e,n,o,r,t])});var m0=0,Z6=Xr();function J6(){var e;return Z6?(e=m0,m0+=1):e="TEST_OR_SSR",e}function Q6(e){var t=d.useState(),r=ce(t,2),n=r[0],o=r[1];return d.useEffect(function(){o("rc_select_".concat(J6()))},[]),e||n}var ej=["children","value"],tj=["children"];function rj(e){var t=e,r=t.key,n=t.props,o=n.children,a=n.value,i=bt(n,ej);return L({key:r,value:a!==void 0?a:r,children:o},i)}function JC(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return Ln(e).map(function(r,n){if(!d.isValidElement(r)||!r.type)return null;var o=r,a=o.type.isSelectOptGroup,i=o.key,l=o.props,s=l.children,u=bt(l,tj);return t||!a?rj(r):L(L({key:"__RC_SELECT_GRP__".concat(i===null?n:i,"__"),label:i},u),{},{options:JC(s)})}).filter(function(r){return r})}var nj=function(e,t,r,n,o){return d.useMemo(function(){var a=e,i=!e;i&&(a=JC(t));var l=new Map,s=new Map,u=function(f,p,h){h&&typeof h=="string"&&f.set(p[h],p)},c=function f(p){for(var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,v=0;v<p.length;v+=1){var g=p[v];!g[r.options]||h?(l.set(g[r.value],g),u(s,g,r.label),u(s,g,n),u(s,g,o)):f(g[r.options],!0)}};return c(a),{options:a,valueOptions:l,labelOptions:s}},[e,t,r,n,o])};function h0(e){var t=d.useRef();t.current=e;var r=d.useCallback(function(){return t.current.apply(t,arguments)},[]);return r}var oj=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],aj=["inputValue"];function ij(e){return!e||at(e)!=="object"}var lj=d.forwardRef(function(e,t){var r=e.id,n=e.mode,o=e.prefixCls,a=o===void 0?"rc-select":o,i=e.backfill,l=e.fieldNames,s=e.inputValue,u=e.searchValue,c=e.onSearch,f=e.autoClearSearchValue,p=f===void 0?!0:f,h=e.onSelect,v=e.onDeselect,g=e.dropdownMatchSelectWidth,m=g===void 0?!0:g,b=e.filterOption,y=e.filterSort,C=e.optionFilterProp,D=e.optionLabelProp,w=e.options,k=e.optionRender,E=e.children,x=e.defaultActiveFirstOption,O=e.menuItemSelectedIcon,j=e.virtual,$=e.direction,P=e.listHeight,A=P===void 0?200:P,B=e.listItemHeight,S=B===void 0?20:B,I=e.labelRender,N=e.value,F=e.defaultValue,M=e.labelInValue,_=e.onChange,X=e.maxCount,H=bt(e,oj),q=Q6(r),Z=Nf(n),te=!!(!w&&E),z=d.useMemo(function(){return b===void 0&&n==="combobox"?!1:b},[b,n]),Y=d.useMemo(function(){return UC(l,te)},[JSON.stringify(l),te]),V=Gr("",{value:u!==void 0?u:s,postState:function(de){return de||""}}),U=ce(V,2),K=U[0],W=U[1],re=nj(w,E,Y,C,D),G=re.valueOptions,J=re.labelOptions,oe=re.options,se=d.useCallback(function(de){var Se=GC(de);return Se.map(function(le){var ie,me,ze,_e,Ke;if(ij(le))ie=le;else{var Pe;ze=le.key,me=le.label,ie=(Pe=le.value)!==null&&Pe!==void 0?Pe:ze}var Ze=G.get(ie);if(Ze){var wt;me===void 0&&(me=Ze==null?void 0:Ze[D||Y.label]),ze===void 0&&(ze=(wt=Ze==null?void 0:Ze.key)!==null&&wt!==void 0?wt:ie),_e=Ze==null?void 0:Ze.disabled,Ke=Ze==null?void 0:Ze.title}return{label:me,value:ie,key:ze,disabled:_e,title:Ke}})},[Y,D,G]),ge=Gr(F,{value:N}),Ee=ce(ge,2),je=Ee[0],ve=Ee[1],ye=d.useMemo(function(){var de,Se=Z&&je===null?[]:je,le=se(Se);return n==="combobox"&&JP((de=le[0])===null||de===void 0?void 0:de.value)?[]:le},[je,se,n,Z]),ke=U6(ye,G),we=ce(ke,2),De=we[0],Ne=we[1],Oe=d.useMemo(function(){if(!n&&De.length===1){var de=De[0];if(de.value===null&&(de.label===null||de.label===void 0))return[]}return De.map(function(Se){var le;return L(L({},Se),{},{label:(le=typeof I=="function"?I(Se):Se.label)!==null&&le!==void 0?le:Se.value})})},[n,De,I]),Xe=d.useMemo(function(){return new Set(De.map(function(de){return de.value}))},[De]);d.useEffect(function(){if(n==="combobox"){var de,Se=(de=De[0])===null||de===void 0?void 0:de.value;W(ZP(Se)?String(Se):"")}},[De]);var Le=h0(function(de,Se){var le=Se??de;return T(T({},Y.value,de),Y.label,le)}),Fe=d.useMemo(function(){if(n!=="tags")return oe;var de=Ie(oe),Se=function(le){return G.has(le)};return Ie(De).sort(function(le,ie){return le.value<ie.value?-1:1}).forEach(function(le){var ie=le.value;Se(ie)||de.push(Le(ie,le.label))}),de},[Le,oe,G,De,n]),fe=Y6(Fe,Y,K,z,C),Be=d.useMemo(function(){return n!=="tags"||!K||fe.some(function(de){return de[C||"value"]===K})||fe.some(function(de){return de[Y.value]===K})?fe:[Le(K)].concat(Ie(fe))},[Le,C,n,fe,K,Y]),We=function de(Se){var le=Ie(Se).sort(function(ie,me){return y(ie,me,{searchValue:K})});return le.map(function(ie){return Array.isArray(ie.options)?L(L({},ie),{},{options:ie.options.length>0?de(ie.options):ie.options}):ie})},Ye=d.useMemo(function(){return y?We(Be):Be},[Be,y,K]),Ve=d.useMemo(function(){return w6(Ye,{fieldNames:Y,childrenAsData:te})},[Ye,Y,te]),Te=function(de){var Se=se(de);if(ve(Se),_&&(Se.length!==De.length||Se.some(function(me,ze){var _e;return((_e=De[ze])===null||_e===void 0?void 0:_e.value)!==(me==null?void 0:me.value)}))){var le=M?Se:Se.map(function(me){return me.value}),ie=Se.map(function(me){return Ff(Ne(me.value))});_(Z?le:le[0],Z?ie:ie[0])}},it=d.useState(null),Ue=ce(it,2),nt=Ue[0],pt=Ue[1],St=d.useState(0),dt=ce(St,2),ht=dt[0],Pt=dt[1],At=x!==void 0?x:n!=="combobox",ct=d.useCallback(function(de,Se){var le=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},ie=le.source,me=ie===void 0?"keyboard":ie;Pt(Se),i&&n==="combobox"&&de!==null&&me==="keyboard"&&pt(String(de))},[i,n]),ut=function(de,Se,le){var ie=function(){var It,Et=Ne(de);return[M?{label:Et==null?void 0:Et[Y.label],value:de,key:(It=Et==null?void 0:Et.key)!==null&&It!==void 0?It:de}:de,Ff(Et)]};if(Se&&h){var me=ie(),ze=ce(me,2),_e=ze[0],Ke=ze[1];h(_e,Ke)}else if(!Se&&v&&le!=="clear"){var Pe=ie(),Ze=ce(Pe,2),wt=Ze[0],jt=Ze[1];v(wt,jt)}},ae=h0(function(de,Se){var le,ie=Z?Se.selected:!0;ie?le=Z?[].concat(Ie(De),[de]):[de]:le=De.filter(function(me){return me.value!==de}),Te(le),ut(de,ie),n==="combobox"?pt(""):(!Nf||p)&&(W(""),pt(""))}),he=function(de,Se){Te(de);var le=Se.type,ie=Se.values;(le==="remove"||le==="clear")&&ie.forEach(function(me){ut(me.value,!1,le)})},xe=function(de,Se){if(W(de),pt(null),Se.source==="submit"){var le=(de||"").trim();if(le){var ie=Array.from(new Set([].concat(Ie(Xe),[le])));Te(ie),ut(le,!0),W("")}return}Se.source!=="blur"&&(n==="combobox"&&Te(de),c==null||c(de))},be=function(de){var Se=de;n!=="tags"&&(Se=de.map(function(ie){var me=J.get(ie);return me==null?void 0:me.value}).filter(function(ie){return ie!==void 0}));var le=Array.from(new Set([].concat(Ie(Xe),Ie(Se))));Te(le),le.forEach(function(ie){ut(ie,!0)})},Ce=d.useMemo(function(){var de=j!==!1&&m!==!1;return L(L({},re),{},{flattenOptions:Ve,onActiveValue:ct,defaultActiveFirstOption:At,onSelect:ae,menuItemSelectedIcon:O,rawValues:Xe,fieldNames:Y,virtual:de,direction:$,listHeight:A,listItemHeight:S,childrenAsData:te,maxCount:X,optionRender:k})},[X,re,Ve,ct,At,ae,O,Xe,Y,j,m,$,A,S,te,k]);return d.createElement(tm.Provider,{value:Ce},d.createElement($6,Me({},H,{id:q,prefixCls:a,ref:t,omitDomProps:aj,mode:n,displayValues:Oe,onDisplayValuesChange:he,direction:$,searchValue:K,onSearch:xe,autoClearSearchValue:p,onSearchSplit:be,dropdownMatchSelectWidth:m,OptionList:X6,emptyOptions:!Ve.length,activeValue:nt,activeDescendantId:"".concat(q,"_list_").concat(ht)})))}),om=lj;om.Option=nm;om.OptGroup=rm;function jf(e,t,r){return pe({[`${e}-status-success`]:t==="success",[`${e}-status-warning`]:t==="warning",[`${e}-status-error`]:t==="error",[`${e}-status-validating`]:t==="validating",[`${e}-has-feedback`]:r})}const QC=(e,t)=>t||e,sj=()=>{const[,e]=Yr(),[t]=xu("Empty"),r=new Ht(e.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return d.createElement("svg",{style:r,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},d.createElement("title",null,(t==null?void 0:t.description)||"Empty"),d.createElement("g",{fill:"none",fillRule:"evenodd"},d.createElement("g",{transform:"translate(24 31.67)"},d.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),d.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),d.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),d.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),d.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),d.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),d.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},d.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),d.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},uj=()=>{const[,e]=Yr(),[t]=xu("Empty"),{colorFill:r,colorFillTertiary:n,colorFillQuaternary:o,colorBgContainer:a}=e,{borderColor:i,shadowColor:l,contentColor:s}=xt(()=>({borderColor:new Ht(r).onBackground(a).toHexString(),shadowColor:new Ht(n).onBackground(a).toHexString(),contentColor:new Ht(o).onBackground(a).toHexString()}),[r,n,o,a]);return d.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},d.createElement("title",null,(t==null?void 0:t.description)||"Empty"),d.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},d.createElement("ellipse",{fill:l,cx:"32",cy:"33",rx:"32",ry:"7"}),d.createElement("g",{fillRule:"nonzero",stroke:i},d.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),d.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:s}))))},cj=e=>{const{componentCls:t,margin:r,marginXS:n,marginXL:o,fontSize:a,lineHeight:i}=e;return{[t]:{marginInline:n,fontSize:a,lineHeight:i,textAlign:"center",[`${t}-image`]:{height:e.emptyImgHeight,marginBottom:n,opacity:e.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${t}-description`]:{color:e.colorTextDescription},[`${t}-footer`]:{marginTop:r},"&-normal":{marginBlock:o,color:e.colorTextDescription,[`${t}-description`]:{color:e.colorTextDescription},[`${t}-image`]:{height:e.emptyImgHeightMD}},"&-small":{marginBlock:n,color:e.colorTextDescription,[`${t}-image`]:{height:e.emptyImgHeightSM}}}}},dj=Hr("Empty",e=>{const{componentCls:t,controlHeightLG:r,calc:n}=e,o=er(e,{emptyImgCls:`${t}-img`,emptyImgHeight:n(r).mul(2.5).equal(),emptyImgHeightMD:r,emptyImgHeightSM:n(r).mul(.875).equal()});return cj(o)});var fj=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const ex=d.createElement(sj,null),tx=d.createElement(uj,null),fo=e=>{var t;const{className:r,rootClassName:n,prefixCls:o,image:a,description:i,children:l,imageStyle:s,style:u,classNames:c,styles:f}=e,p=fj(e,["className","rootClassName","prefixCls","image","description","children","imageStyle","style","classNames","styles"]),{getPrefixCls:h,direction:v,className:g,style:m,classNames:b,styles:y,image:C}=Ro("empty"),D=h("empty",o),[w,k,E]=dj(D),[x]=xu("Empty"),O=typeof i<"u"?i:x==null?void 0:x.description,j=typeof O=="string"?O:"empty",$=(t=a??C)!==null&&t!==void 0?t:ex;let P=null;return typeof $=="string"?P=d.createElement("img",{alt:j,src:$}):P=$,w(d.createElement("div",Object.assign({className:pe(k,E,D,g,{[`${D}-normal`]:$===tx,[`${D}-rtl`]:v==="rtl"},r,n,b.root,c==null?void 0:c.root),style:Object.assign(Object.assign(Object.assign(Object.assign({},y.root),m),f==null?void 0:f.root),u)},p),d.createElement("div",{className:pe(`${D}-image`,b.image,c==null?void 0:c.image),style:Object.assign(Object.assign(Object.assign({},s),y.image),f==null?void 0:f.image)},P),O&&d.createElement("div",{className:pe(`${D}-description`,b.description,c==null?void 0:c.description),style:Object.assign(Object.assign({},y.description),f==null?void 0:f.description)},O),l&&d.createElement("div",{className:pe(`${D}-footer`,b.footer,c==null?void 0:c.footer),style:Object.assign(Object.assign({},y.footer),f==null?void 0:f.footer)},l)))};fo.PRESENTED_IMAGE_DEFAULT=ex;fo.PRESENTED_IMAGE_SIMPLE=tx;const rx=e=>{const{componentName:t}=e,{getPrefixCls:r}=Rr(Zt),n=r("empty");switch(t){case"Table":case"List":return ee.createElement(fo,{image:fo.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return ee.createElement(fo,{image:fo.PRESENTED_IMAGE_SIMPLE,className:`${n}-small`});case"Table.filter":return null;default:return ee.createElement(fo,null)}},nx=(e,t,r=void 0)=>{var n,o;const{variant:a,[e]:i}=d.useContext(Zt),l=d.useContext(SP),s=i==null?void 0:i.variant;let u;typeof t<"u"?u=t:r===!1?u="borderless":u=(o=(n=l??s)!==null&&n!==void 0?n:a)!==null&&o!==void 0?o:"outlined";const c=UA.includes(u);return[u,c]},pj=e=>{const t={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:e==="scroll"?"scroll":"visible",dynamicInset:!0};return{bottomLeft:Object.assign(Object.assign({},t),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},t),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},t),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},t),{points:["br","tr"],offset:[0,-4]})}};function mj(e,t){return e||pj(t)}const g0=e=>{const{optionHeight:t,optionFontSize:r,optionLineHeight:n,optionPadding:o}=e;return{position:"relative",display:"block",minHeight:t,padding:o,color:e.colorText,fontWeight:"normal",fontSize:r,lineHeight:n,boxSizing:"border-box"}},hj=e=>{const{antCls:t,componentCls:r}=e,n=`${r}-item`,o=`&${t}-slide-up-enter${t}-slide-up-enter-active`,a=`&${t}-slide-up-appear${t}-slide-up-appear-active`,i=`&${t}-slide-up-leave${t}-slide-up-leave-active`,l=`${r}-dropdown-placement-`,s=`${n}-option-selected`;return[{[`${r}-dropdown`]:Object.assign(Object.assign({},Br(e)),{position:"absolute",top:-9999,zIndex:e.zIndexPopup,boxSizing:"border-box",padding:e.paddingXXS,overflow:"hidden",fontSize:e.fontSize,fontVariant:"initial",backgroundColor:e.colorBgElevated,borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,[`
|
|
301
|
+
${o}${l}bottomLeft,
|
|
302
|
+
${a}${l}bottomLeft
|
|
303
|
+
`]:{animationName:Vp},[`
|
|
304
|
+
${o}${l}topLeft,
|
|
305
|
+
${a}${l}topLeft,
|
|
306
|
+
${o}${l}topRight,
|
|
307
|
+
${a}${l}topRight
|
|
308
|
+
`]:{animationName:Xp},[`${i}${l}bottomLeft`]:{animationName:Gp},[`
|
|
309
|
+
${i}${l}topLeft,
|
|
310
|
+
${i}${l}topRight
|
|
311
|
+
`]:{animationName:Up},"&-hidden":{display:"none"},[n]:Object.assign(Object.assign({},g0(e)),{cursor:"pointer",transition:`background ${e.motionDurationSlow} ease`,borderRadius:e.borderRadiusSM,"&-group":{color:e.colorTextDescription,fontSize:e.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":Object.assign({flex:"auto"},ul),"&-state":{flex:"none",display:"flex",alignItems:"center"},[`&-active:not(${n}-option-disabled)`]:{backgroundColor:e.optionActiveBg},[`&-selected:not(${n}-option-disabled)`]:{color:e.optionSelectedColor,fontWeight:e.optionSelectedFontWeight,backgroundColor:e.optionSelectedBg,[`${n}-option-state`]:{color:e.colorPrimary}},"&-disabled":{[`&${n}-option-selected`]:{backgroundColor:e.colorBgContainerDisabled},color:e.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:e.calc(e.controlPaddingHorizontal).mul(2).equal()}},"&-empty":Object.assign(Object.assign({},g0(e)),{color:e.colorTextDisabled})}),[`${s}:has(+ ${s})`]:{borderEndStartRadius:0,borderEndEndRadius:0,[`& + ${s}`]:{borderStartStartRadius:0,borderStartEndRadius:0}},"&-rtl":{direction:"rtl"}})},Ua(e,"slide-up"),Ua(e,"slide-down"),Vs(e,"move-up"),Vs(e,"move-down")]},gj=e=>{const{multipleSelectItemHeight:t,paddingXXS:r,lineWidth:n,INTERNAL_FIXED_ITEM_MARGIN:o}=e,a=e.max(e.calc(r).sub(n).equal(),0),i=e.max(e.calc(a).sub(o).equal(),0);return{basePadding:a,containerPadding:i,itemHeight:ue(t),itemLineHeight:ue(e.calc(t).sub(e.calc(e.lineWidth).mul(2)).equal())}},vj=e=>{const{multipleSelectItemHeight:t,selectHeight:r,lineWidth:n}=e;return e.calc(r).sub(t).div(2).sub(n).equal()},bj=e=>{const{componentCls:t,iconCls:r,borderRadiusSM:n,motionDurationSlow:o,paddingXS:a,multipleItemColorDisabled:i,multipleItemBorderColorDisabled:l,colorIcon:s,colorIconHover:u,INTERNAL_FIXED_ITEM_MARGIN:c}=e;return{[`${t}-selection-overflow`]:{position:"relative",display:"flex",flex:"auto",flexWrap:"wrap",maxWidth:"100%","&-item":{flex:"none",alignSelf:"center",maxWidth:"calc(100% - 4px)",display:"inline-flex"},[`${t}-selection-item`]:{display:"flex",alignSelf:"center",flex:"none",boxSizing:"border-box",maxWidth:"100%",marginBlock:c,borderRadius:n,cursor:"default",transition:`font-size ${o}, line-height ${o}, height ${o}`,marginInlineEnd:e.calc(c).mul(2).equal(),paddingInlineStart:a,paddingInlineEnd:e.calc(a).div(2).equal(),[`${t}-disabled&`]:{color:i,borderColor:l,cursor:"not-allowed"},"&-content":{display:"inline-block",marginInlineEnd:e.calc(a).div(2).equal(),overflow:"hidden",whiteSpace:"pre",textOverflow:"ellipsis"},"&-remove":Object.assign(Object.assign({},xl()),{display:"inline-flex",alignItems:"center",color:s,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",[`> ${r}`]:{verticalAlign:"-0.2em"},"&:hover":{color:u}})}}}},yj=(e,t)=>{const{componentCls:r,INTERNAL_FIXED_ITEM_MARGIN:n}=e,o=`${r}-selection-overflow`,a=e.multipleSelectItemHeight,i=vj(e),l=t?`${r}-${t}`:"",s=gj(e);return{[`${r}-multiple${l}`]:Object.assign(Object.assign({},bj(e)),{[`${r}-selector`]:{display:"flex",alignItems:"center",width:"100%",height:"100%",paddingInline:s.basePadding,paddingBlock:s.containerPadding,borderRadius:e.borderRadius,[`${r}-disabled&`]:{background:e.multipleSelectorBgDisabled,cursor:"not-allowed"},"&:after":{display:"inline-block",width:0,margin:`${ue(n)} 0`,lineHeight:ue(a),visibility:"hidden",content:'"\\a0"'}},[`${r}-selection-item`]:{height:s.itemHeight,lineHeight:ue(s.itemLineHeight)},[`${r}-selection-wrap`]:{alignSelf:"flex-start","&:after":{lineHeight:ue(a),marginBlock:n}},[`${r}-prefix`]:{marginInlineStart:e.calc(e.inputPaddingHorizontalBase).sub(s.basePadding).equal()},[`${o}-item + ${o}-item,
|
|
312
|
+
${r}-prefix + ${r}-selection-wrap
|
|
313
|
+
`]:{[`${r}-selection-search`]:{marginInlineStart:0},[`${r}-selection-placeholder`]:{insetInlineStart:0}},[`${o}-item-suffix`]:{minHeight:s.itemHeight,marginBlock:n},[`${r}-selection-search`]:{display:"inline-flex",position:"relative",maxWidth:"100%",marginInlineStart:e.calc(e.inputPaddingHorizontalBase).sub(i).equal(),"\n &-input,\n &-mirror\n ":{height:a,fontFamily:e.fontFamily,lineHeight:ue(a),transition:`all ${e.motionDurationSlow}`},"&-input":{width:"100%",minWidth:4.1},"&-mirror":{position:"absolute",top:0,insetInlineStart:0,insetInlineEnd:"auto",zIndex:999,whiteSpace:"pre",visibility:"hidden"}},[`${r}-selection-placeholder`]:{position:"absolute",top:"50%",insetInlineStart:e.calc(e.inputPaddingHorizontalBase).sub(s.basePadding).equal(),insetInlineEnd:e.inputPaddingHorizontalBase,transform:"translateY(-50%)",transition:`all ${e.motionDurationSlow}`}})}};function Yc(e,t){const{componentCls:r}=e,n=t?`${r}-${t}`:"",o={[`${r}-multiple${n}`]:{fontSize:e.fontSize,[`${r}-selector`]:{[`${r}-show-search&`]:{cursor:"text"}},[`
|
|
314
|
+
&${r}-show-arrow ${r}-selector,
|
|
315
|
+
&${r}-allow-clear ${r}-selector
|
|
316
|
+
`]:{paddingInlineEnd:e.calc(e.fontSizeIcon).add(e.controlPaddingHorizontal).equal()}}};return[yj(e,t),o]}const Cj=e=>{const{componentCls:t}=e,r=er(e,{selectHeight:e.controlHeightSM,multipleSelectItemHeight:e.multipleItemHeightSM,borderRadius:e.borderRadiusSM,borderRadiusSM:e.borderRadiusXS}),n=er(e,{fontSize:e.fontSizeLG,selectHeight:e.controlHeightLG,multipleSelectItemHeight:e.multipleItemHeightLG,borderRadius:e.borderRadiusLG,borderRadiusSM:e.borderRadius});return[Yc(e),Yc(r,"sm"),{[`${t}-multiple${t}-sm`]:{[`${t}-selection-placeholder`]:{insetInline:e.calc(e.controlPaddingHorizontalSM).sub(e.lineWidth).equal()},[`${t}-selection-search`]:{marginInlineStart:2}}},Yc(n,"lg")]};function Zc(e,t){const{componentCls:r,inputPaddingHorizontalBase:n,borderRadius:o}=e,a=e.calc(e.controlHeight).sub(e.calc(e.lineWidth).mul(2)).equal(),i=t?`${r}-${t}`:"";return{[`${r}-single${i}`]:{fontSize:e.fontSize,height:e.controlHeight,[`${r}-selector`]:Object.assign(Object.assign({},Br(e,!0)),{display:"flex",borderRadius:o,flex:"1 1 auto",[`${r}-selection-wrap:after`]:{lineHeight:ue(a)},[`${r}-selection-search`]:{position:"absolute",inset:0,width:"100%","&-input":{width:"100%",WebkitAppearance:"textfield"}},[`
|
|
317
|
+
${r}-selection-item,
|
|
318
|
+
${r}-selection-placeholder
|
|
319
|
+
`]:{display:"block",padding:0,lineHeight:ue(a),transition:`all ${e.motionDurationSlow}, visibility 0s`,alignSelf:"center"},[`${r}-selection-placeholder`]:{transition:"none",pointerEvents:"none"},[["&:after",`${r}-selection-item:empty:after`,`${r}-selection-placeholder:empty:after`].join(",")]:{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'}}),[`
|
|
320
|
+
&${r}-show-arrow ${r}-selection-item,
|
|
321
|
+
&${r}-show-arrow ${r}-selection-search,
|
|
322
|
+
&${r}-show-arrow ${r}-selection-placeholder
|
|
323
|
+
`]:{paddingInlineEnd:e.showArrowPaddingInlineEnd},[`&${r}-open ${r}-selection-item`]:{color:e.colorTextPlaceholder},[`&:not(${r}-customize-input)`]:{[`${r}-selector`]:{width:"100%",height:"100%",alignItems:"center",padding:`0 ${ue(n)}`,[`${r}-selection-search-input`]:{height:a,fontSize:e.fontSize},"&:after":{lineHeight:ue(a)}}},[`&${r}-customize-input`]:{[`${r}-selector`]:{"&:after":{display:"none"},[`${r}-selection-search`]:{position:"static",width:"100%"},[`${r}-selection-placeholder`]:{position:"absolute",insetInlineStart:0,insetInlineEnd:0,padding:`0 ${ue(n)}`,"&:after":{display:"none"}}}}}}}function xj(e){const{componentCls:t}=e,r=e.calc(e.controlPaddingHorizontalSM).sub(e.lineWidth).equal();return[Zc(e),Zc(er(e,{controlHeight:e.controlHeightSM,borderRadius:e.borderRadiusSM}),"sm"),{[`${t}-single${t}-sm`]:{[`&:not(${t}-customize-input)`]:{[`${t}-selector`]:{padding:`0 ${ue(r)}`},[`&${t}-show-arrow ${t}-selection-search`]:{insetInlineEnd:e.calc(r).add(e.calc(e.fontSize).mul(1.5)).equal()},[`
|
|
324
|
+
&${t}-show-arrow ${t}-selection-item,
|
|
325
|
+
&${t}-show-arrow ${t}-selection-placeholder
|
|
326
|
+
`]:{paddingInlineEnd:e.calc(e.fontSize).mul(1.5).equal()}}}},Zc(er(e,{controlHeight:e.singleItemHeightLG,fontSize:e.fontSizeLG,borderRadius:e.borderRadiusLG}),"lg")]}const wj=e=>{const{fontSize:t,lineHeight:r,lineWidth:n,controlHeight:o,controlHeightSM:a,controlHeightLG:i,paddingXXS:l,controlPaddingHorizontal:s,zIndexPopupBase:u,colorText:c,fontWeightStrong:f,controlItemBgActive:p,controlItemBgHover:h,colorBgContainer:v,colorFillSecondary:g,colorBgContainerDisabled:m,colorTextDisabled:b,colorPrimaryHover:y,colorPrimary:C,controlOutline:D}=e,w=l*2,k=n*2,E=Math.min(o-w,o-k),x=Math.min(a-w,a-k),O=Math.min(i-w,i-k);return{INTERNAL_FIXED_ITEM_MARGIN:Math.floor(l/2),zIndexPopup:u+50,optionSelectedColor:c,optionSelectedFontWeight:f,optionSelectedBg:p,optionActiveBg:h,optionPadding:`${(o-t*r)/2}px ${s}px`,optionFontSize:t,optionLineHeight:r,optionHeight:o,selectorBg:v,clearBg:v,singleItemHeightLG:i,multipleItemBg:g,multipleItemBorderColor:"transparent",multipleItemHeight:E,multipleItemHeightSM:x,multipleItemHeightLG:O,multipleSelectorBgDisabled:m,multipleItemColorDisabled:b,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(e.fontSize*1.25),hoverBorderColor:y,activeBorderColor:C,activeOutlineColor:D,selectAffixPadding:l}},ox=(e,t)=>{const{componentCls:r,antCls:n,controlOutlineWidth:o}=e;return{[`&:not(${r}-customize-input) ${r}-selector`]:{border:`${ue(e.lineWidth)} ${e.lineType} ${t.borderColor}`,background:e.selectorBg},[`&:not(${r}-disabled):not(${r}-customize-input):not(${n}-pagination-size-changer)`]:{[`&:hover ${r}-selector`]:{borderColor:t.hoverBorderHover},[`${r}-focused& ${r}-selector`]:{borderColor:t.activeBorderColor,boxShadow:`0 0 0 ${ue(o)} ${t.activeOutlineColor}`,outline:0},[`${r}-prefix`]:{color:t.color}}}},v0=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},ox(e,t))}),Ej=e=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign({},ox(e,{borderColor:e.colorBorder,hoverBorderHover:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeOutlineColor:e.activeOutlineColor,color:e.colorText})),v0(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,activeOutlineColor:e.colorErrorOutline,color:e.colorError})),v0(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,activeOutlineColor:e.colorWarningOutline,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${ue(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`}})}),ax=(e,t)=>{const{componentCls:r,antCls:n}=e;return{[`&:not(${r}-customize-input) ${r}-selector`]:{background:t.bg,border:`${ue(e.lineWidth)} ${e.lineType} transparent`,color:t.color},[`&:not(${r}-disabled):not(${r}-customize-input):not(${n}-pagination-size-changer)`]:{[`&:hover ${r}-selector`]:{background:t.hoverBg},[`${r}-focused& ${r}-selector`]:{background:e.selectorBg,borderColor:t.activeBorderColor,outline:0}}}},b0=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},ax(e,t))}),kj=e=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign({},ax(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor,color:e.colorText})),b0(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,color:e.colorError})),b0(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{borderColor:e.colorBorder,background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.colorBgContainer,border:`${ue(e.lineWidth)} ${e.lineType} ${e.colorSplit}`}})}),Dj=e=>({"&-borderless":{[`${e.componentCls}-selector`]:{background:"transparent",border:`${ue(e.lineWidth)} ${e.lineType} transparent`},[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${ue(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`},[`&${e.componentCls}-status-error`]:{[`${e.componentCls}-prefix, ${e.componentCls}-selection-item`]:{color:e.colorError}},[`&${e.componentCls}-status-warning`]:{[`${e.componentCls}-prefix, ${e.componentCls}-selection-item`]:{color:e.colorWarning}}}}),ix=(e,t)=>{const{componentCls:r,antCls:n}=e;return{[`&:not(${r}-customize-input) ${r}-selector`]:{borderWidth:`0 0 ${ue(e.lineWidth)} 0`,borderStyle:`none none ${e.lineType} none`,borderColor:t.borderColor,background:e.selectorBg,borderRadius:0},[`&:not(${r}-disabled):not(${r}-customize-input):not(${n}-pagination-size-changer)`]:{[`&:hover ${r}-selector`]:{borderColor:t.hoverBorderHover},[`${r}-focused& ${r}-selector`]:{borderColor:t.activeBorderColor,outline:0},[`${r}-prefix`]:{color:t.color}}}},y0=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},ix(e,t))}),Sj=e=>({"&-underlined":Object.assign(Object.assign(Object.assign(Object.assign({},ix(e,{borderColor:e.colorBorder,hoverBorderHover:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeOutlineColor:e.activeOutlineColor,color:e.colorText})),y0(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,activeOutlineColor:e.colorErrorOutline,color:e.colorError})),y0(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,activeOutlineColor:e.colorWarningOutline,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${ue(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`}})}),$j=e=>({[e.componentCls]:Object.assign(Object.assign(Object.assign(Object.assign({},Ej(e)),kj(e)),Dj(e)),Sj(e))}),Bj=e=>{const{componentCls:t}=e;return{position:"relative",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,input:{cursor:"pointer"},[`${t}-show-search&`]:{cursor:"text",input:{cursor:"auto",color:"inherit",height:"100%"}},[`${t}-disabled&`]:{cursor:"not-allowed",input:{cursor:"not-allowed"}}}},Oj=e=>{const{componentCls:t}=e;return{[`${t}-selection-search-input`]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none",fontFamily:"inherit","&::-webkit-search-cancel-button":{display:"none",appearance:"none"}}}},Aj=e=>{const{antCls:t,componentCls:r,inputPaddingHorizontalBase:n,iconCls:o}=e,a={[`${r}-clear`]:{opacity:1,background:e.colorBgBase,borderRadius:"50%"}};return{[r]:Object.assign(Object.assign({},Br(e)),{position:"relative",display:"inline-flex",cursor:"pointer",[`&:not(${r}-customize-input) ${r}-selector`]:Object.assign(Object.assign({},Bj(e)),Oj(e)),[`${r}-selection-item`]:Object.assign(Object.assign({flex:1,fontWeight:"normal",position:"relative",userSelect:"none"},ul),{[`> ${t}-typography`]:{display:"inline"}}),[`${r}-selection-placeholder`]:Object.assign(Object.assign({},ul),{flex:1,color:e.colorTextPlaceholder,pointerEvents:"none"}),[`${r}-arrow`]:Object.assign(Object.assign({},xl()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:n,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",transition:`opacity ${e.motionDurationSlow} ease`,[o]:{verticalAlign:"top",transition:`transform ${e.motionDurationSlow}`,"> svg":{verticalAlign:"top"},[`&:not(${r}-suffix)`]:{pointerEvents:"auto"}},[`${r}-disabled &`]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),[`${r}-selection-wrap`]:{display:"flex",width:"100%",position:"relative",minWidth:0,"&:after":{content:'"\\a0"',width:0,overflow:"hidden"}},[`${r}-prefix`]:{flex:"none",marginInlineEnd:e.selectAffixPadding},[`${r}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:n,zIndex:1,display:"inline-block",width:e.fontSizeIcon,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",cursor:"pointer",opacity:0,transition:`color ${e.motionDurationMid} ease, opacity ${e.motionDurationSlow} ease`,textRendering:"auto",transform:"translateZ(0)","&:before":{display:"block"},"&:hover":{color:e.colorIcon}},"@media(hover:none)":a,"&:hover":a}),[`${r}-status`]:{"&-error, &-warning, &-success, &-validating":{[`&${r}-has-feedback`]:{[`${r}-clear`]:{insetInlineEnd:e.calc(n).add(e.fontSize).add(e.paddingXS).equal()}}}}}},Fj=e=>{const{componentCls:t}=e;return[{[t]:{[`&${t}-in-form-item`]:{width:"100%"}}},Aj(e),xj(e),Cj(e),hj(e),{[`${t}-rtl`]:{direction:"rtl"}},Jp(e,{borderElCls:`${t}-selector`,focusElCls:`${t}-focused`})]},Nj=Hr("Select",(e,{rootPrefixCls:t})=>{const r=er(e,{rootPrefixCls:t,inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(1).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[Fj(r),$j(r)]},wj,{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}});var Pj={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},jj=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:Pj}))},Ij=d.forwardRef(jj),Rj={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"},Mj=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:Rj}))},lx=d.forwardRef(Mj),Tj={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},zj=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:Tj}))},sx=d.forwardRef(zj);function _j({suffixIcon:e,clearIcon:t,menuItemSelectedIcon:r,removeIcon:n,loading:o,multiple:a,hasFeedback:i,prefixCls:l,showSuffixIcon:s,feedbackIcon:u,showArrow:c,componentName:f}){const p=t??d.createElement(mC,null),h=b=>e===null&&!i&&!c?null:d.createElement(d.Fragment,null,s!==!1&&b,i&&u);let v=null;if(e!==void 0)v=h(e);else if(o)v=h(d.createElement(Lp,{spin:!0}));else{const b=`${l}-suffix`;v=({open:y,showSearch:C})=>h(y&&C?d.createElement(sx,{className:b}):d.createElement(lx,{className:b}))}let g=null;r!==void 0?g=r:a?g=d.createElement(Ij,null):g=null;let m=null;return n!==void 0?m=n:m=d.createElement(b3,null),{clearIcon:p,suffixIcon:v,itemIcon:g,removeIcon:m}}function Lj(e){return ee.useMemo(()=>{if(e)return(...t)=>ee.createElement(fl,{space:!0},e.apply(void 0,t))},[e])}function Hj(e,t){return t!==void 0?t:e!==null}var Wj=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const ux="SECRET_COMBOBOX_MODE_DO_NOT_USE",Kj=(e,t)=>{var r,n,o,a,i;const{prefixCls:l,bordered:s,className:u,rootClassName:c,getPopupContainer:f,popupClassName:p,dropdownClassName:h,listHeight:v=256,placement:g,listItemHeight:m,size:b,disabled:y,notFoundContent:C,status:D,builtinPlacements:w,dropdownMatchSelectWidth:k,popupMatchSelectWidth:E,direction:x,style:O,allowClear:j,variant:$,dropdownStyle:P,transitionName:A,tagRender:B,maxCount:S,prefix:I,dropdownRender:N,popupRender:F,onDropdownVisibleChange:M,onOpenChange:_,styles:X,classNames:H}=e,q=Wj(e,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear","variant","dropdownStyle","transitionName","tagRender","maxCount","prefix","dropdownRender","popupRender","onDropdownVisibleChange","onOpenChange","styles","classNames"]),{getPopupContainer:Z,getPrefixCls:te,renderEmpty:z,direction:Y,virtual:V,popupMatchSelectWidth:U,popupOverflow:K}=d.useContext(Zt),{showSearch:W,style:re,styles:G,className:J,classNames:oe}=Ro("select"),[,se]=Yr(),ge=m??(se==null?void 0:se.controlHeight),Ee=te("select",l),je=te(),ve=x??Y,{compactSize:ye,compactItemClassnames:ke}=$u(Ee,ve),[we,De]=nx("select",$,s),Ne=bo(Ee),[Oe,Xe,Le]=Nj(Ee,Ne),Fe=d.useMemo(()=>{const{mode:ie}=e;if(ie!=="combobox")return ie===ux?"combobox":ie},[e.mode]),fe=Fe==="multiple"||Fe==="tags",Be=Hj(e.suffixIcon,e.showArrow),We=(r=E??k)!==null&&r!==void 0?r:U,Ye=((n=X==null?void 0:X.popup)===null||n===void 0?void 0:n.root)||((o=G.popup)===null||o===void 0?void 0:o.root)||P,Ve=Lj(F||N),Te=_||M,{status:it,hasFeedback:Ue,isFormItemInput:nt,feedbackIcon:pt}=d.useContext(oa),St=QC(it,D);let dt;C!==void 0?dt=C:Fe==="combobox"?dt=null:dt=(z==null?void 0:z("Select"))||d.createElement(rx,{componentName:"Select"});const{suffixIcon:ht,itemIcon:Pt,removeIcon:At,clearIcon:ct}=_j(Object.assign(Object.assign({},q),{multiple:fe,hasFeedback:Ue,feedbackIcon:pt,showSuffixIcon:Be,prefixCls:Ee,componentName:"Select"})),ut=j===!0?{clearIcon:ct}:j,ae=fn(q,["suffixIcon","itemIcon"]),he=pe(((a=H==null?void 0:H.popup)===null||a===void 0?void 0:a.root)||((i=oe==null?void 0:oe.popup)===null||i===void 0?void 0:i.root)||p||h,{[`${Ee}-dropdown-${ve}`]:ve==="rtl"},c,oe.root,H==null?void 0:H.root,Le,Ne,Xe),xe=fa(ie=>{var me;return(me=b??ye)!==null&&me!==void 0?me:ie}),be=d.useContext(No),Ce=y??be,de=pe({[`${Ee}-lg`]:xe==="large",[`${Ee}-sm`]:xe==="small",[`${Ee}-rtl`]:ve==="rtl",[`${Ee}-${we}`]:De,[`${Ee}-in-form-item`]:nt},jf(Ee,St,Ue),ke,J,u,oe.root,H==null?void 0:H.root,c,Le,Ne,Xe),Se=d.useMemo(()=>g!==void 0?g:ve==="rtl"?"bottomRight":"bottomLeft",[g,ve]),[le]=wu("SelectLike",Ye==null?void 0:Ye.zIndex);return Oe(d.createElement(om,Object.assign({ref:t,virtual:V,showSearch:W},ae,{style:Object.assign(Object.assign(Object.assign(Object.assign({},G.root),X==null?void 0:X.root),re),O),dropdownMatchSelectWidth:We,transitionName:CC(je,"slide-up",A),builtinPlacements:mj(w,K),listHeight:v,listItemHeight:ge,mode:Fe,prefixCls:Ee,placement:Se,direction:ve,prefix:I,suffixIcon:ht,menuItemSelectedIcon:Pt,removeIcon:At,allowClear:ut,notFoundContent:dt,className:de,getPopupContainer:f||Z,dropdownClassName:he,disabled:Ce,dropdownStyle:Object.assign(Object.assign({},Ye),{zIndex:le}),maxCount:fe?S:void 0,tagRender:fe?B:void 0,dropdownRender:Ve,onDropdownVisibleChange:Te})))},li=d.forwardRef(Kj),qj=zC(li,"dropdownAlign");li.SECRET_COMBOBOX_MODE_DO_NOT_USE=ux;li.Option=nm;li.OptGroup=rm;li._InternalPanelDoNotUseOrYouWillBeFired=qj;const Vj=(e,t)=>{typeof(e==null?void 0:e.addEventListener)<"u"?e.addEventListener("change",t):typeof(e==null?void 0:e.addListener)<"u"&&e.addListener(t)},Gj=(e,t)=>{typeof(e==null?void 0:e.removeEventListener)<"u"?e.removeEventListener("change",t):typeof(e==null?void 0:e.removeListener)<"u"&&e.removeListener(t)},Xj=["xxl","xl","lg","md","sm","xs"],Uj=e=>({xs:`(max-width: ${e.screenXSMax}px)`,sm:`(min-width: ${e.screenSM}px)`,md:`(min-width: ${e.screenMD}px)`,lg:`(min-width: ${e.screenLG}px)`,xl:`(min-width: ${e.screenXL}px)`,xxl:`(min-width: ${e.screenXXL}px)`}),Yj=e=>{const t=e,r=[].concat(Xj).reverse();return r.forEach((n,o)=>{const a=n.toUpperCase(),i=`screen${a}Min`,l=`screen${a}`;if(!(t[i]<=t[l]))throw new Error(`${i}<=${l} fails : !(${t[i]}<=${t[l]})`);if(o<r.length-1){const s=`screen${a}Max`;if(!(t[l]<=t[s]))throw new Error(`${l}<=${s} fails : !(${t[l]}<=${t[s]})`);const u=`screen${r[o+1].toUpperCase()}Min`;if(!(t[s]<=t[u]))throw new Error(`${s}<=${u} fails : !(${t[s]}<=${t[u]})`)}}),e},Zj=()=>{const[,e]=Yr(),t=Uj(Yj(e));return ee.useMemo(()=>{const r=new Map;let n=-1,o={};return{responsiveMap:t,matchHandlers:{},dispatch(a){return o=a,r.forEach(i=>i(o)),r.size>=1},subscribe(a){return r.size||this.register(),n+=1,r.set(n,a),a(o),n},unsubscribe(a){r.delete(a),r.size||this.unregister()},register(){Object.entries(t).forEach(([a,i])=>{const l=({matches:u})=>{this.dispatch(Object.assign(Object.assign({},o),{[a]:u}))},s=window.matchMedia(i);Vj(s,l),this.matchHandlers[i]={mql:s,listener:l},l(s)})},unregister(){Object.values(t).forEach(a=>{const i=this.matchHandlers[a];Gj(i==null?void 0:i.mql,i==null?void 0:i.listener)}),r.clear()}}},[e])};function cx(){const[,e]=d.useReducer(t=>t+1,0);return e}function dx(e=!0,t={}){const r=qe(t),n=cx(),o=Zj();return Wt(()=>{const a=o.subscribe(i=>{r.current=i,e&&n()});return()=>o.unsubscribe(a)},[]),r.current}function fx(e){var t=e.children,r=e.prefixCls,n=e.id,o=e.overlayInnerStyle,a=e.bodyClassName,i=e.className,l=e.style;return d.createElement("div",{className:pe("".concat(r,"-content"),i),style:l},d.createElement("div",{className:pe("".concat(r,"-inner"),a),id:n,role:"tooltip",style:o},typeof t=="function"?t():t))}var Ca={shiftX:64,adjustY:1},xa={adjustX:1,shiftY:!0},Sn=[0,0],Jj={left:{points:["cr","cl"],overflow:xa,offset:[-4,0],targetOffset:Sn},right:{points:["cl","cr"],overflow:xa,offset:[4,0],targetOffset:Sn},top:{points:["bc","tc"],overflow:Ca,offset:[0,-4],targetOffset:Sn},bottom:{points:["tc","bc"],overflow:Ca,offset:[0,4],targetOffset:Sn},topLeft:{points:["bl","tl"],overflow:Ca,offset:[0,-4],targetOffset:Sn},leftTop:{points:["tr","tl"],overflow:xa,offset:[-4,0],targetOffset:Sn},topRight:{points:["br","tr"],overflow:Ca,offset:[0,-4],targetOffset:Sn},rightTop:{points:["tl","tr"],overflow:xa,offset:[4,0],targetOffset:Sn},bottomRight:{points:["tr","br"],overflow:Ca,offset:[0,4],targetOffset:Sn},rightBottom:{points:["bl","br"],overflow:xa,offset:[4,0],targetOffset:Sn},bottomLeft:{points:["tl","bl"],overflow:Ca,offset:[0,4],targetOffset:Sn},leftBottom:{points:["br","bl"],overflow:xa,offset:[-4,0],targetOffset:Sn}},Qj=["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow","classNames","styles"],eI=function(e,t){var r=e.overlayClassName,n=e.trigger,o=n===void 0?["hover"]:n,a=e.mouseEnterDelay,i=a===void 0?0:a,l=e.mouseLeaveDelay,s=l===void 0?.1:l,u=e.overlayStyle,c=e.prefixCls,f=c===void 0?"rc-tooltip":c,p=e.children,h=e.onVisibleChange,v=e.afterVisibleChange,g=e.transitionName,m=e.animation,b=e.motion,y=e.placement,C=y===void 0?"right":y,D=e.align,w=D===void 0?{}:D,k=e.destroyTooltipOnHide,E=k===void 0?!1:k,x=e.defaultVisible,O=e.getTooltipContainer,j=e.overlayInnerStyle;e.arrowContent;var $=e.overlay,P=e.id,A=e.showArrow,B=A===void 0?!0:A,S=e.classNames,I=e.styles,N=bt(e,Qj),F=Qp(P),M=qe(null);ei(t,function(){return M.current});var _=L({},N);"visible"in e&&(_.popupVisible=e.visible);var X=function(){return d.createElement(fx,{key:"content",prefixCls:f,id:F,bodyClassName:S==null?void 0:S.body,overlayInnerStyle:L(L({},j),I==null?void 0:I.body)},$)},H=function(){var q=d.Children.only(p),Z=(q==null?void 0:q.props)||{},te=L(L({},Z),{},{"aria-describedby":$?F:null});return d.cloneElement(p,te)};return d.createElement(Iu,Me({popupClassName:pe(r,S==null?void 0:S.root),prefixCls:f,popup:X,action:o,builtinPlacements:Jj,popupPlacement:C,ref:M,popupAlign:w,getPopupContainer:O,onPopupVisibleChange:h,afterPopupVisibleChange:v,popupTransitionName:g,popupAnimation:m,popupMotion:b,defaultPopupVisible:x,autoDestroy:E,mouseLeaveDelay:s,popupStyle:L(L({},u),I==null?void 0:I.root),mouseEnterDelay:i,arrow:B},_),H())};const tI=dn(eI);function px(e){const{sizePopupArrow:t,borderRadiusXS:r,borderRadiusOuter:n}=e,o=t/2,a=0,i=o,l=n*1/Math.sqrt(2),s=o-n*(1-1/Math.sqrt(2)),u=o-r*(1/Math.sqrt(2)),c=n*(Math.sqrt(2)-1)+r*(1/Math.sqrt(2)),f=2*o-u,p=c,h=2*o-l,v=s,g=2*o-a,m=i,b=o*Math.sqrt(2)+n*(Math.sqrt(2)-2),y=n*(Math.sqrt(2)-1),C=`polygon(${y}px 100%, 50% ${y}px, ${2*o-y}px 100%, ${y}px 100%)`,D=`path('M ${a} ${i} A ${n} ${n} 0 0 0 ${l} ${s} L ${u} ${c} A ${r} ${r} 0 0 1 ${f} ${p} L ${h} ${v} A ${n} ${n} 0 0 0 ${g} ${m} Z')`;return{arrowShadowWidth:b,arrowPath:D,arrowPolygon:C}}const rI=(e,t,r)=>{const{sizePopupArrow:n,arrowPolygon:o,arrowPath:a,arrowShadowWidth:i,borderRadiusXS:l,calc:s}=e;return{pointerEvents:"none",width:n,height:n,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:n,height:s(n).div(2).equal(),background:t,clipPath:{_multi_value_:!0,value:[o,a]},content:'""'},"&::after":{content:'""',position:"absolute",width:i,height:i,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${ue(l)} 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:r,zIndex:0,background:"transparent"}}},mx=8;function am(e){const{contentRadius:t,limitVerticalRadius:r}=e,n=t>12?t+2:12;return{arrowOffsetHorizontal:n,arrowOffsetVertical:r?mx:n}}function Jl(e,t){return e?t:{}}function hx(e,t,r){const{componentCls:n,boxShadowPopoverArrow:o,arrowOffsetVertical:a,arrowOffsetHorizontal:i}=e,{arrowDistance:l=0,arrowPlacement:s={left:!0,right:!0,top:!0,bottom:!0}}=r||{};return{[n]:Object.assign(Object.assign(Object.assign(Object.assign({[`${n}-arrow`]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},rI(e,t,o)),{"&:before":{background:t}})]},Jl(!!s.top,{[[`&-placement-top > ${n}-arrow`,`&-placement-topLeft > ${n}-arrow`,`&-placement-topRight > ${n}-arrow`].join(",")]:{bottom:l,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top > ${n}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},"&-placement-topLeft":{"--arrow-offset-horizontal":i,[`> ${n}-arrow`]:{left:{_skip_check_:!0,value:i}}},"&-placement-topRight":{"--arrow-offset-horizontal":`calc(100% - ${ue(i)})`,[`> ${n}-arrow`]:{right:{_skip_check_:!0,value:i}}}})),Jl(!!s.bottom,{[[`&-placement-bottom > ${n}-arrow`,`&-placement-bottomLeft > ${n}-arrow`,`&-placement-bottomRight > ${n}-arrow`].join(",")]:{top:l,transform:"translateY(-100%)"},[`&-placement-bottom > ${n}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},"&-placement-bottomLeft":{"--arrow-offset-horizontal":i,[`> ${n}-arrow`]:{left:{_skip_check_:!0,value:i}}},"&-placement-bottomRight":{"--arrow-offset-horizontal":`calc(100% - ${ue(i)})`,[`> ${n}-arrow`]:{right:{_skip_check_:!0,value:i}}}})),Jl(!!s.left,{[[`&-placement-left > ${n}-arrow`,`&-placement-leftTop > ${n}-arrow`,`&-placement-leftBottom > ${n}-arrow`].join(",")]:{right:{_skip_check_:!0,value:l},transform:"translateX(100%) rotate(90deg)"},[`&-placement-left > ${n}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},[`&-placement-leftTop > ${n}-arrow`]:{top:a},[`&-placement-leftBottom > ${n}-arrow`]:{bottom:a}})),Jl(!!s.right,{[[`&-placement-right > ${n}-arrow`,`&-placement-rightTop > ${n}-arrow`,`&-placement-rightBottom > ${n}-arrow`].join(",")]:{left:{_skip_check_:!0,value:l},transform:"translateX(-100%) rotate(-90deg)"},[`&-placement-right > ${n}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},[`&-placement-rightTop > ${n}-arrow`]:{top:a},[`&-placement-rightBottom > ${n}-arrow`]:{bottom:a}}))}}function nI(e,t,r,n){if(n===!1)return{adjustX:!1,adjustY:!1};const o=n&&typeof n=="object"?n:{},a={};switch(e){case"top":case"bottom":a.shiftX=t.arrowOffsetHorizontal*2+r,a.shiftY=!0,a.adjustY=!0;break;case"left":case"right":a.shiftY=t.arrowOffsetVertical*2+r,a.shiftX=!0,a.adjustX=!0;break}const i=Object.assign(Object.assign({},a),o);return i.shiftX||(i.adjustX=!0),i.shiftY||(i.adjustY=!0),i}const C0={left:{points:["cr","cl"]},right:{points:["cl","cr"]},top:{points:["bc","tc"]},bottom:{points:["tc","bc"]},topLeft:{points:["bl","tl"]},leftTop:{points:["tr","tl"]},topRight:{points:["br","tr"]},rightTop:{points:["tl","tr"]},bottomRight:{points:["tr","br"]},rightBottom:{points:["bl","br"]},bottomLeft:{points:["tl","bl"]},leftBottom:{points:["br","bl"]}},oI={topLeft:{points:["bl","tc"]},leftTop:{points:["tr","cl"]},topRight:{points:["br","tc"]},rightTop:{points:["tl","cr"]},bottomRight:{points:["tr","bc"]},rightBottom:{points:["bl","cr"]},bottomLeft:{points:["tl","bc"]},leftBottom:{points:["br","cl"]}},aI=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function gx(e){const{arrowWidth:t,autoAdjustOverflow:r,arrowPointAtCenter:n,offset:o,borderRadius:a,visibleFirst:i}=e,l=t/2,s={},u=am({contentRadius:a,limitVerticalRadius:!0});return Object.keys(C0).forEach(c=>{const f=n&&oI[c]||C0[c],p=Object.assign(Object.assign({},f),{offset:[0,0],dynamicInset:!0});switch(s[c]=p,aI.has(c)&&(p.autoArrow=!1),c){case"top":case"topLeft":case"topRight":p.offset[1]=-l-o;break;case"bottom":case"bottomLeft":case"bottomRight":p.offset[1]=l+o;break;case"left":case"leftTop":case"leftBottom":p.offset[0]=-l-o;break;case"right":case"rightTop":case"rightBottom":p.offset[0]=l+o;break}if(n)switch(c){case"topLeft":case"bottomLeft":p.offset[0]=-u.arrowOffsetHorizontal-l;break;case"topRight":case"bottomRight":p.offset[0]=u.arrowOffsetHorizontal+l;break;case"leftTop":case"rightTop":p.offset[1]=-u.arrowOffsetHorizontal*2+l;break;case"leftBottom":case"rightBottom":p.offset[1]=u.arrowOffsetHorizontal*2-l;break}p.overflow=nI(c,u,t,r),i&&(p.htmlRegion="visibleFirst")}),s}const iI=e=>{const{calc:t,componentCls:r,tooltipMaxWidth:n,tooltipColor:o,tooltipBg:a,tooltipBorderRadius:i,zIndexPopup:l,controlHeight:s,boxShadowSecondary:u,paddingSM:c,paddingXS:f,arrowOffsetHorizontal:p,sizePopupArrow:h}=e,v=t(i).add(h).add(p).equal(),g=t(i).mul(2).add(h).equal();return[{[r]:Object.assign(Object.assign(Object.assign(Object.assign({},Br(e)),{position:"absolute",zIndex:l,display:"block",width:"max-content",maxWidth:n,visibility:"visible","--valid-offset-x":"var(--arrow-offset-horizontal, var(--arrow-x))",transformOrigin:["var(--valid-offset-x, 50%)","var(--arrow-y, 50%)"].join(" "),"&-hidden":{display:"none"},"--antd-arrow-background-color":a,[`${r}-inner`]:{minWidth:g,minHeight:s,padding:`${ue(e.calc(c).div(2).equal())} ${ue(f)}`,color:`var(--ant-tooltip-color, ${o})`,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:a,borderRadius:i,boxShadow:u,boxSizing:"border-box"},[["&-placement-topLeft","&-placement-topRight","&-placement-bottomLeft","&-placement-bottomRight"].join(",")]:{minWidth:v},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${r}-inner`]:{borderRadius:e.min(i,mx)}},[`${r}-content`]:{position:"relative"}}),EF(e,(m,{darkColor:b})=>({[`&${r}-${m}`]:{[`${r}-inner`]:{backgroundColor:b},[`${r}-arrow`]:{"--antd-arrow-background-color":b}}}))),{"&-rtl":{direction:"rtl"}})},hx(e,"var(--antd-arrow-background-color)"),{[`${r}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}}]},lI=e=>Object.assign(Object.assign({zIndexPopup:e.zIndexPopupBase+70},am({contentRadius:e.borderRadius,limitVerticalRadius:!0})),px(er(e,{borderRadiusOuter:Math.min(e.borderRadiusOuter,4)}))),vx=(e,t=!0)=>Hr("Tooltip",r=>{const{borderRadius:n,colorTextLightSolid:o,colorBgSpotlight:a}=r,i=er(r,{tooltipMaxWidth:250,tooltipColor:o,tooltipBorderRadius:n,tooltipBg:a});return[iI(i),Yp(r,"zoom-big-fast")]},lI,{resetStyle:!1,injectStyle:t})(e),sI=na.map(e=>`${e}-inverse`);function uI(e,t=!0){return t?[].concat(Ie(sI),Ie(na)).includes(e):na.includes(e)}function bx(e,t){const r=uI(t),n=pe({[`${e}-${t}`]:t&&r}),o={},a={},i=G5(t).toRgb(),l=(.299*i.r+.587*i.g+.114*i.b)/255<.5?"#FFF":"#000";return t&&!r&&(o.background=t,o["--ant-tooltip-color"]=l,a["--antd-arrow-background-color"]=t),{className:n,overlayStyle:o,arrowStyle:a}}const cI=e=>{const{prefixCls:t,className:r,placement:n="top",title:o,color:a,overlayInnerStyle:i}=e,{getPrefixCls:l}=d.useContext(Zt),s=l("tooltip",t),[u,c,f]=vx(s),p=bx(s,a),h=p.arrowStyle,v=Object.assign(Object.assign({},i),p.overlayStyle),g=pe(c,f,s,`${s}-pure`,`${s}-placement-${n}`,r,p.className);return u(d.createElement("div",{className:g,style:h},d.createElement("div",{className:`${s}-arrow`}),d.createElement(fx,Object.assign({},e,{className:c,prefixCls:s,overlayInnerStyle:v}),o)))};var dI=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const fI=d.forwardRef((e,t)=>{var r,n;const{prefixCls:o,openClassName:a,getTooltipContainer:i,color:l,overlayInnerStyle:s,children:u,afterOpenChange:c,afterVisibleChange:f,destroyTooltipOnHide:p,destroyOnHidden:h,arrow:v=!0,title:g,overlay:m,builtinPlacements:b,arrowPointAtCenter:y=!1,autoAdjustOverflow:C=!0,motion:D,getPopupContainer:w,placement:k="top",mouseEnterDelay:E=.1,mouseLeaveDelay:x=.1,overlayStyle:O,rootClassName:j,overlayClassName:$,styles:P,classNames:A}=e,B=dI(e,["prefixCls","openClassName","getTooltipContainer","color","overlayInnerStyle","children","afterOpenChange","afterVisibleChange","destroyTooltipOnHide","destroyOnHidden","arrow","title","overlay","builtinPlacements","arrowPointAtCenter","autoAdjustOverflow","motion","getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName","overlayClassName","styles","classNames"]),S=!!v,[,I]=Yr(),{getPopupContainer:N,getPrefixCls:F,direction:M,className:_,style:X,classNames:H,styles:q}=Ro("tooltip"),Z=oi(),te=d.useRef(null),z=()=>{var Be;(Be=te.current)===null||Be===void 0||Be.forceAlign()};d.useImperativeHandle(t,()=>{var Be,We;return{forceAlign:z,forcePopupAlign:()=>{Z.deprecated(!1,"forcePopupAlign","forceAlign"),z()},nativeElement:(Be=te.current)===null||Be===void 0?void 0:Be.nativeElement,popupElement:(We=te.current)===null||We===void 0?void 0:We.popupElement}});const[Y,V]=Gr(!1,{value:(r=e.open)!==null&&r!==void 0?r:e.visible,defaultValue:(n=e.defaultOpen)!==null&&n!==void 0?n:e.defaultVisible}),U=!g&&!m&&g!==0,K=Be=>{var We,Ye;V(U?!1:Be),U||((We=e.onOpenChange)===null||We===void 0||We.call(e,Be),(Ye=e.onVisibleChange)===null||Ye===void 0||Ye.call(e,Be))},W=d.useMemo(()=>{var Be,We;let Ye=y;return typeof v=="object"&&(Ye=(We=(Be=v.pointAtCenter)!==null&&Be!==void 0?Be:v.arrowPointAtCenter)!==null&&We!==void 0?We:y),b||gx({arrowPointAtCenter:Ye,autoAdjustOverflow:C,arrowWidth:S?I.sizePopupArrow:0,borderRadius:I.borderRadius,offset:I.marginXXS,visibleFirst:!0})},[y,v,b,I]),re=d.useMemo(()=>g===0?g:m||g||"",[m,g]),G=d.createElement(fl,{space:!0},typeof re=="function"?re():re),J=F("tooltip",o),oe=F(),se=e["data-popover-inject"];let ge=Y;!("open"in e)&&!("visible"in e)&&U&&(ge=!1);const Ee=d.isValidElement(u)&&!hC(u)?u:d.createElement("span",null,u),je=Ee.props,ve=!je.className||typeof je.className=="string"?pe(je.className,a||`${J}-open`):je.className,[ye,ke,we]=vx(J,!se),De=bx(J,l),Ne=De.arrowStyle,Oe=pe($,{[`${J}-rtl`]:M==="rtl"},De.className,j,ke,we,_,H.root,A==null?void 0:A.root),Xe=pe(H.body,A==null?void 0:A.body),[Le,Fe]=wu("Tooltip",B.zIndex),fe=d.createElement(tI,Object.assign({},B,{zIndex:Le,showArrow:S,placement:k,mouseEnterDelay:E,mouseLeaveDelay:x,prefixCls:J,classNames:{root:Oe,body:Xe},styles:{root:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Ne),q.root),X),O),P==null?void 0:P.root),body:Object.assign(Object.assign(Object.assign(Object.assign({},q.body),s),P==null?void 0:P.body),De.overlayStyle)},getTooltipContainer:w||i||N,ref:te,builtinPlacements:W,overlay:G,visible:ge,onVisibleChange:K,afterVisibleChange:c??f,arrowContent:d.createElement("span",{className:`${J}-arrow-content`}),motion:{motionName:CC(oe,"zoom-big-fast",e.transitionName),motionDeadline:1e3},destroyTooltipOnHide:h??!!p}),ge?eo(Ee,{className:ve}):Ee);return ye(d.createElement(Hp.Provider,{value:Fe},fe))}),ml=fI;ml._InternalPanelDoNotUseOrYouWillBeFired=cI;var pI={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"},mI=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:pI}))},If=d.forwardRef(mI),hI=rt.ESC,gI=rt.TAB;function vI(e){var t=e.visible,r=e.triggerRef,n=e.onVisibleChange,o=e.autoFocus,a=e.overlayRef,i=d.useRef(!1),l=function(){if(t){var c,f;(c=r.current)===null||c===void 0||(f=c.focus)===null||f===void 0||f.call(c),n==null||n(!1)}},s=function(){var c;return(c=a.current)!==null&&c!==void 0&&c.focus?(a.current.focus(),i.current=!0,!0):!1},u=function(c){switch(c.keyCode){case hI:l();break;case gI:{var f=!1;i.current||(f=s()),f?c.preventDefault():l();break}}};d.useEffect(function(){return t?(window.addEventListener("keydown",u),o&&qt(s,3),function(){window.removeEventListener("keydown",u),i.current=!1}):function(){i.current=!1}},[t])}var bI=dn(function(e,t){var r=e.overlay,n=e.arrow,o=e.prefixCls,a=xt(function(){var l;return typeof r=="function"?l=r():l=r,l},[r]),i=ro(t,ua(a));return ee.createElement(ee.Fragment,null,n&&ee.createElement("div",{className:"".concat(o,"-arrow")}),ee.cloneElement(a,{ref:Zn(a)?i:void 0}))}),wa={adjustX:1,adjustY:1},Ea=[0,0],yI={topLeft:{points:["bl","tl"],overflow:wa,offset:[0,-4],targetOffset:Ea},top:{points:["bc","tc"],overflow:wa,offset:[0,-4],targetOffset:Ea},topRight:{points:["br","tr"],overflow:wa,offset:[0,-4],targetOffset:Ea},bottomLeft:{points:["tl","bl"],overflow:wa,offset:[0,4],targetOffset:Ea},bottom:{points:["tc","bc"],overflow:wa,offset:[0,4],targetOffset:Ea},bottomRight:{points:["tr","br"],overflow:wa,offset:[0,4],targetOffset:Ea}},CI=["arrow","prefixCls","transitionName","animation","align","placement","placements","getPopupContainer","showAction","hideAction","overlayClassName","overlayStyle","visible","trigger","autoFocus","overlay","children","onVisibleChange"];function xI(e,t){var r,n=e.arrow,o=n===void 0?!1:n,a=e.prefixCls,i=a===void 0?"rc-dropdown":a,l=e.transitionName,s=e.animation,u=e.align,c=e.placement,f=c===void 0?"bottomLeft":c,p=e.placements,h=p===void 0?yI:p,v=e.getPopupContainer,g=e.showAction,m=e.hideAction,b=e.overlayClassName,y=e.overlayStyle,C=e.visible,D=e.trigger,w=D===void 0?["hover"]:D,k=e.autoFocus,E=e.overlay,x=e.children,O=e.onVisibleChange,j=bt(e,CI),$=ee.useState(),P=ce($,2),A=P[0],B=P[1],S="visible"in e?C:A,I=ee.useRef(null),N=ee.useRef(null),F=ee.useRef(null);ee.useImperativeHandle(t,function(){return I.current});var M=function(Y){B(Y),O==null||O(Y)};vI({visible:S,triggerRef:F,onVisibleChange:M,autoFocus:k,overlayRef:N});var _=function(Y){var V=e.onOverlayClick;B(!1),V&&V(Y)},X=function(){return ee.createElement(bI,{ref:N,overlay:E,prefixCls:i,arrow:o})},H=function(){return typeof E=="function"?X:X()},q=function(){var Y=e.minOverlayWidthMatchTrigger,V=e.alignPoint;return"minOverlayWidthMatchTrigger"in e?Y:!V},Z=function(){var Y=e.openClassName;return Y!==void 0?Y:"".concat(i,"-open")},te=ee.cloneElement(x,{className:pe((r=x.props)===null||r===void 0?void 0:r.className,S&&Z()),ref:Zn(x)?ro(F,ua(x)):void 0}),z=m;return!z&&w.indexOf("contextMenu")!==-1&&(z=["click"]),ee.createElement(Iu,Me({builtinPlacements:h},j,{prefixCls:i,ref:I,popupClassName:pe(b,T({},"".concat(i,"-show-arrow"),o)),popupStyle:y,action:w,showAction:g,hideAction:z,popupPlacement:f,popupAlign:u,popupTransitionName:l,popupAnimation:s,popupVisible:S,stretch:q()?"minWidth":"",popup:H(),onPopupVisibleChange:M,onPopupClick:_,getPopupContainer:v}),te)}const wI=ee.forwardRef(xI),EI=e=>typeof e!="object"&&typeof e!="function"||e===null;var yx=d.createContext(null);function Cx(e,t){return e===void 0?null:"".concat(e,"-").concat(t)}function xx(e){var t=d.useContext(yx);return Cx(t,e)}var kI=["children","locked"],Hn=d.createContext(null);function DI(e,t){var r=L({},e);return Object.keys(t).forEach(function(n){var o=t[n];o!==void 0&&(r[n]=o)}),r}function hl(e){var t=e.children,r=e.locked,n=bt(e,kI),o=d.useContext(Hn),a=la(function(){return DI(o,n)},[o,n],function(i,l){return!r&&(i[0]!==l[0]||!Jn(i[1],l[1],!0))});return d.createElement(Hn.Provider,{value:a},t)}var SI=[],wx=d.createContext(null);function Mu(){return d.useContext(wx)}var Ex=d.createContext(SI);function si(e){var t=d.useContext(Ex);return d.useMemo(function(){return e!==void 0?[].concat(Ie(t),[e]):t},[t,e])}var kx=d.createContext(null),im=d.createContext({});function x0(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(ku(e)){var r=e.nodeName.toLowerCase(),n=["input","select","textarea","button"].includes(r)||e.isContentEditable||r==="a"&&!!e.getAttribute("href"),o=e.getAttribute("tabindex"),a=Number(o),i=null;return o&&!Number.isNaN(a)?i=a:n&&i===null&&(i=0),n&&e.disabled&&(i=null),i!==null&&(i>=0||t&&i<0)}return!1}function $I(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=Ie(e.querySelectorAll("*")).filter(function(n){return x0(n,t)});return x0(e,t)&&r.unshift(e),r}var Rf=rt.LEFT,Mf=rt.RIGHT,Tf=rt.UP,xs=rt.DOWN,ws=rt.ENTER,Dx=rt.ESC,wi=rt.HOME,Ei=rt.END,w0=[Tf,xs,Rf,Mf];function BI(e,t,r,n){var o,a="prev",i="next",l="children",s="parent";if(e==="inline"&&n===ws)return{inlineTrigger:!0};var u=T(T({},Tf,a),xs,i),c=T(T(T(T({},Rf,r?i:a),Mf,r?a:i),xs,l),ws,l),f=T(T(T(T(T(T({},Tf,a),xs,i),ws,l),Dx,s),Rf,r?l:s),Mf,r?s:l),p={inline:u,horizontal:c,vertical:f,inlineSub:u,horizontalSub:f,verticalSub:f},h=(o=p["".concat(e).concat(t?"":"Sub")])===null||o===void 0?void 0:o[n];switch(h){case a:return{offset:-1,sibling:!0};case i:return{offset:1,sibling:!0};case s:return{offset:-1,sibling:!1};case l:return{offset:1,sibling:!1};default:return null}}function OI(e){for(var t=e;t;){if(t.getAttribute("data-menu-list"))return t;t=t.parentElement}return null}function AI(e,t){for(var r=e||document.activeElement;r;){if(t.has(r))return r;r=r.parentElement}return null}function lm(e,t){var r=$I(e,!0);return r.filter(function(n){return t.has(n)})}function E0(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1;if(!e)return null;var o=lm(e,t),a=o.length,i=o.findIndex(function(l){return r===l});return n<0?i===-1?i=a-1:i-=1:n>0&&(i+=1),i=(i+a)%a,o[i]}var zf=function(e,t){var r=new Set,n=new Map,o=new Map;return e.forEach(function(a){var i=document.querySelector("[data-menu-id='".concat(Cx(t,a),"']"));i&&(r.add(i),o.set(i,a),n.set(a,i))}),{elements:r,key2element:n,element2key:o}};function FI(e,t,r,n,o,a,i,l,s,u){var c=d.useRef(),f=d.useRef();f.current=t;var p=function(){qt.cancel(c.current)};return d.useEffect(function(){return function(){p()}},[]),function(h){var v=h.which;if([].concat(w0,[ws,Dx,wi,Ei]).includes(v)){var g=a(),m=zf(g,n),b=m,y=b.elements,C=b.key2element,D=b.element2key,w=C.get(t),k=AI(w,y),E=D.get(k),x=BI(e,i(E,!0).length===1,r,v);if(!x&&v!==wi&&v!==Ei)return;(w0.includes(v)||[wi,Ei].includes(v))&&h.preventDefault();var O=function(I){if(I){var N=I,F=I.querySelector("a");F!=null&&F.getAttribute("href")&&(N=F);var M=D.get(I);l(M),p(),c.current=qt(function(){f.current===M&&N.focus()})}};if([wi,Ei].includes(v)||x.sibling||!k){var j;!k||e==="inline"?j=o.current:j=OI(k);var $,P=lm(j,y);v===wi?$=P[0]:v===Ei?$=P[P.length-1]:$=E0(j,y,k,x.offset),O($)}else if(x.inlineTrigger)s(E);else if(x.offset>0)s(E,!0),p(),c.current=qt(function(){m=zf(g,n);var I=k.getAttribute("aria-controls"),N=document.getElementById(I),F=E0(N,m.elements);O(F)},5);else if(x.offset<0){var A=i(E,!0),B=A[A.length-2],S=C.get(B);s(B,!1),O(S)}}u==null||u(h)}}function NI(e){Promise.resolve().then(e)}var sm="__RC_UTIL_PATH_SPLIT__",k0=function(e){return e.join(sm)},PI=function(e){return e.split(sm)},_f="rc-menu-more";function jI(){var e=d.useState({}),t=ce(e,2),r=t[1],n=qe(new Map),o=qe(new Map),a=d.useState([]),i=ce(a,2),l=i[0],s=i[1],u=qe(0),c=qe(!1),f=function(){c.current||r({})},p=mt(function(C,D){var w=k0(D);o.current.set(w,C),n.current.set(C,w),u.current+=1;var k=u.current;NI(function(){k===u.current&&f()})},[]),h=mt(function(C,D){var w=k0(D);o.current.delete(w),n.current.delete(C)},[]),v=mt(function(C){s(C)},[]),g=mt(function(C,D){var w=n.current.get(C)||"",k=PI(w);return D&&l.includes(k[0])&&k.unshift(_f),k},[l]),m=mt(function(C,D){return C.filter(function(w){return w!==void 0}).some(function(w){var k=g(w,!0);return k.includes(D)})},[g]),b=function(){var C=Ie(n.current.keys());return l.length&&C.push(_f),C},y=mt(function(C){var D="".concat(n.current.get(C)).concat(sm),w=new Set;return Ie(o.current.keys()).forEach(function(k){k.startsWith(D)&&w.add(o.current.get(k))}),w},[]);return d.useEffect(function(){return function(){c.current=!0}},[]),{registerPath:p,unregisterPath:h,refreshOverflowKeys:v,isSubPathKey:m,getKeyPath:g,getKeys:b,getSubPathKeys:y}}function Oi(e){var t=d.useRef(e);t.current=e;var r=d.useCallback(function(){for(var n,o=arguments.length,a=new Array(o),i=0;i<o;i++)a[i]=arguments[i];return(n=t.current)===null||n===void 0?void 0:n.call.apply(n,[t].concat(a))},[]);return e?r:void 0}var II=Math.random().toFixed(5).toString().slice(2),D0=0;function RI(e){var t=Gr(e,{value:e}),r=ce(t,2),n=r[0],o=r[1];return d.useEffect(function(){D0+=1;var a="".concat(II,"-").concat(D0);o("rc-menu-uuid-".concat(a))},[]),n}function Sx(e,t,r,n){var o=d.useContext(Hn),a=o.activeKey,i=o.onActive,l=o.onInactive,s={active:a===e};return t||(s.onMouseEnter=function(u){r==null||r({key:e,domEvent:u}),i(e)},s.onMouseLeave=function(u){n==null||n({key:e,domEvent:u}),l(e)}),s}function $x(e){var t=d.useContext(Hn),r=t.mode,n=t.rtl,o=t.inlineIndent;if(r!=="inline")return null;var a=e;return n?{paddingRight:a*o}:{paddingLeft:a*o}}function Bx(e){var t=e.icon,r=e.props,n=e.children,o;return t===null||t===!1?null:(typeof t=="function"?o=d.createElement(t,L({},r)):typeof t!="boolean"&&(o=t),o||n||null)}var MI=["item"];function Us(e){var t=e.item,r=bt(e,MI);return Object.defineProperty(r,"item",{get:function(){return lr(!1,"`info.item` is deprecated since we will move to function component that not provides React Node instance in future."),t}}),r}var TI=["title","attribute","elementRef"],zI=["style","className","eventKey","warnKey","disabled","itemIcon","children","role","onMouseEnter","onMouseLeave","onClick","onKeyDown","onFocus"],_I=["active"],LI=(function(e){no(r,e);var t=oo(r);function r(){return vr(this,r),t.apply(this,arguments)}return br(r,[{key:"render",value:function(){var n=this.props,o=n.title,a=n.attribute,i=n.elementRef,l=bt(n,TI),s=fn(l,["eventKey","popupClassName","popupOffset","onTitleClick"]);return lr(!a,"`attribute` of Menu.Item is deprecated. Please pass attribute directly."),d.createElement(Yn.Item,Me({},a,{title:typeof o=="string"?o:void 0},s,{ref:i}))}}]),r})(d.Component),HI=d.forwardRef(function(e,t){var r=e.style,n=e.className,o=e.eventKey;e.warnKey;var a=e.disabled,i=e.itemIcon,l=e.children,s=e.role,u=e.onMouseEnter,c=e.onMouseLeave,f=e.onClick,p=e.onKeyDown,h=e.onFocus,v=bt(e,zI),g=xx(o),m=d.useContext(Hn),b=m.prefixCls,y=m.onItemClick,C=m.disabled,D=m.overflowDisabled,w=m.itemIcon,k=m.selectedKeys,E=m.onActive,x=d.useContext(im),O=x._internalRenderMenuItem,j="".concat(b,"-item"),$=d.useRef(),P=d.useRef(),A=C||a,B=sa(t,P),S=si(o),I=function(V){return{key:o,keyPath:Ie(S).reverse(),item:$.current,domEvent:V}},N=i||w,F=Sx(o,A,u,c),M=F.active,_=bt(F,_I),X=k.includes(o),H=$x(S.length),q=function(V){if(!A){var U=I(V);f==null||f(Us(U)),y(U)}},Z=function(V){if(p==null||p(V),V.which===rt.ENTER){var U=I(V);f==null||f(Us(U)),y(U)}},te=function(V){E(o),h==null||h(V)},z={};e.role==="option"&&(z["aria-selected"]=X);var Y=d.createElement(LI,Me({ref:$,elementRef:B,role:s===null?"none":s||"menuitem",tabIndex:a?null:-1,"data-menu-id":D&&g?null:g},fn(v,["extra"]),_,z,{component:"li","aria-disabled":a,style:L(L({},H),r),className:pe(j,T(T(T({},"".concat(j,"-active"),M),"".concat(j,"-selected"),X),"".concat(j,"-disabled"),A),n),onClick:q,onKeyDown:Z,onFocus:te}),l,d.createElement(Bx,{props:L(L({},e),{},{isSelected:X}),icon:N}));return O&&(Y=O(Y,e,{selected:X})),Y});function WI(e,t){var r=e.eventKey,n=Mu(),o=si(r);return d.useEffect(function(){if(n)return n.registerPath(r,o),function(){n.unregisterPath(r,o)}},[o]),n?null:d.createElement(HI,Me({},e,{ref:t}))}const Tu=d.forwardRef(WI);var KI=["className","children"],qI=function(e,t){var r=e.className,n=e.children,o=bt(e,KI),a=d.useContext(Hn),i=a.prefixCls,l=a.mode,s=a.rtl;return d.createElement("ul",Me({className:pe(i,s&&"".concat(i,"-rtl"),"".concat(i,"-sub"),"".concat(i,"-").concat(l==="inline"?"inline":"vertical"),r),role:"menu"},o,{"data-menu-list":!0,ref:t}),n)},um=d.forwardRef(qI);um.displayName="SubMenuList";function cm(e,t){return Ln(e).map(function(r,n){if(d.isValidElement(r)){var o,a,i=r.key,l=(o=(a=r.props)===null||a===void 0?void 0:a.eventKey)!==null&&o!==void 0?o:i,s=l==null;s&&(l="tmp_key-".concat([].concat(Ie(t),[n]).join("-")));var u={key:l,eventKey:l};return d.cloneElement(r,u)}return r})}var qr={adjustX:1,adjustY:1},VI={topLeft:{points:["bl","tl"],overflow:qr},topRight:{points:["br","tr"],overflow:qr},bottomLeft:{points:["tl","bl"],overflow:qr},bottomRight:{points:["tr","br"],overflow:qr},leftTop:{points:["tr","tl"],overflow:qr},leftBottom:{points:["br","bl"],overflow:qr},rightTop:{points:["tl","tr"],overflow:qr},rightBottom:{points:["bl","br"],overflow:qr}},GI={topLeft:{points:["bl","tl"],overflow:qr},topRight:{points:["br","tr"],overflow:qr},bottomLeft:{points:["tl","bl"],overflow:qr},bottomRight:{points:["tr","br"],overflow:qr},rightTop:{points:["tr","tl"],overflow:qr},rightBottom:{points:["br","bl"],overflow:qr},leftTop:{points:["tl","tr"],overflow:qr},leftBottom:{points:["bl","br"],overflow:qr}};function Ox(e,t,r){if(t)return t;if(r)return r[e]||r.other}var XI={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"};function UI(e){var t=e.prefixCls,r=e.visible,n=e.children,o=e.popup,a=e.popupStyle,i=e.popupClassName,l=e.popupOffset,s=e.disabled,u=e.mode,c=e.onVisibleChange,f=d.useContext(Hn),p=f.getPopupContainer,h=f.rtl,v=f.subMenuOpenDelay,g=f.subMenuCloseDelay,m=f.builtinPlacements,b=f.triggerSubMenuAction,y=f.forceSubMenuRender,C=f.rootClassName,D=f.motion,w=f.defaultMotions,k=d.useState(!1),E=ce(k,2),x=E[0],O=E[1],j=L(h?L({},GI):L({},VI),m),$=XI[u],P=Ox(u,D,w),A=d.useRef(P);u!=="inline"&&(A.current=P);var B=L(L({},A.current),{},{leavedClassName:"".concat(t,"-hidden"),removeOnLeave:!1,motionAppear:!0}),S=d.useRef();return d.useEffect(function(){return S.current=qt(function(){O(r)}),function(){qt.cancel(S.current)}},[r]),d.createElement(Iu,{prefixCls:t,popupClassName:pe("".concat(t,"-popup"),T({},"".concat(t,"-rtl"),h),i,C),stretch:u==="horizontal"?"minWidth":null,getPopupContainer:p,builtinPlacements:j,popupPlacement:$,popupVisible:x,popup:o,popupStyle:a,popupAlign:l&&{offset:l},action:s?[]:[b],mouseEnterDelay:v,mouseLeaveDelay:g,onPopupVisibleChange:c,forceRender:y,popupMotion:B,fresh:!0},n)}function YI(e){var t=e.id,r=e.open,n=e.keyPath,o=e.children,a="inline",i=d.useContext(Hn),l=i.prefixCls,s=i.forceSubMenuRender,u=i.motion,c=i.defaultMotions,f=i.mode,p=d.useRef(!1);p.current=f===a;var h=d.useState(!p.current),v=ce(h,2),g=v[0],m=v[1],b=p.current?r:!1;d.useEffect(function(){p.current&&m(!1)},[f]);var y=L({},Ox(a,u,c));n.length>1&&(y.motionAppear=!1);var C=y.onVisibleChanged;return y.onVisibleChanged=function(D){return!p.current&&!D&&m(!0),C==null?void 0:C(D)},g?null:d.createElement(hl,{mode:a,locked:!p.current},d.createElement(ca,Me({visible:b},y,{forceRender:s,removeOnLeave:!1,leavedClassName:"".concat(l,"-hidden")}),function(D){var w=D.className,k=D.style;return d.createElement(um,{id:t,className:w,style:k},o)}))}var ZI=["style","className","title","eventKey","warnKey","disabled","internalPopupClose","children","itemIcon","expandIcon","popupClassName","popupOffset","popupStyle","onClick","onMouseEnter","onMouseLeave","onTitleClick","onTitleMouseEnter","onTitleMouseLeave"],JI=["active"],QI=d.forwardRef(function(e,t){var r=e.style,n=e.className,o=e.title,a=e.eventKey;e.warnKey;var i=e.disabled,l=e.internalPopupClose,s=e.children,u=e.itemIcon,c=e.expandIcon,f=e.popupClassName,p=e.popupOffset,h=e.popupStyle,v=e.onClick,g=e.onMouseEnter,m=e.onMouseLeave,b=e.onTitleClick,y=e.onTitleMouseEnter,C=e.onTitleMouseLeave,D=bt(e,ZI),w=xx(a),k=d.useContext(Hn),E=k.prefixCls,x=k.mode,O=k.openKeys,j=k.disabled,$=k.overflowDisabled,P=k.activeKey,A=k.selectedKeys,B=k.itemIcon,S=k.expandIcon,I=k.onItemClick,N=k.onOpenChange,F=k.onActive,M=d.useContext(im),_=M._internalRenderSubMenuItem,X=d.useContext(kx),H=X.isSubPathKey,q=si(),Z="".concat(E,"-submenu"),te=j||i,z=d.useRef(),Y=d.useRef(),V=u??B,U=c??S,K=O.includes(a),W=!$&&K,re=H(A,a),G=Sx(a,te,y,C),J=G.active,oe=bt(G,JI),se=d.useState(!1),ge=ce(se,2),Ee=ge[0],je=ge[1],ve=function(Te){te||je(Te)},ye=function(Te){ve(!0),g==null||g({key:a,domEvent:Te})},ke=function(Te){ve(!1),m==null||m({key:a,domEvent:Te})},we=d.useMemo(function(){return J||(x!=="inline"?Ee||H([P],a):!1)},[x,J,P,Ee,a,H]),De=$x(q.length),Ne=function(Te){te||(b==null||b({key:a,domEvent:Te}),x==="inline"&&N(a,!K))},Oe=Oi(function(Te){v==null||v(Us(Te)),I(Te)}),Xe=function(Te){x!=="inline"&&N(a,Te)},Le=function(){F(a)},Fe=w&&"".concat(w,"-popup"),fe=d.useMemo(function(){return d.createElement(Bx,{icon:x!=="horizontal"?U:void 0,props:L(L({},e),{},{isOpen:W,isSubMenu:!0})},d.createElement("i",{className:"".concat(Z,"-arrow")}))},[x,U,e,W,Z]),Be=d.createElement("div",Me({role:"menuitem",style:De,className:"".concat(Z,"-title"),tabIndex:te?null:-1,ref:z,title:typeof o=="string"?o:null,"data-menu-id":$&&w?null:w,"aria-expanded":W,"aria-haspopup":!0,"aria-controls":Fe,"aria-disabled":te,onClick:Ne,onFocus:Le},oe),o,fe),We=d.useRef(x);if(x!=="inline"&&q.length>1?We.current="vertical":We.current=x,!$){var Ye=We.current;Be=d.createElement(UI,{mode:Ye,prefixCls:Z,visible:!l&&W&&x!=="inline",popupClassName:f,popupOffset:p,popupStyle:h,popup:d.createElement(hl,{mode:Ye==="horizontal"?"vertical":Ye},d.createElement(um,{id:Fe,ref:Y},s)),disabled:te,onVisibleChange:Xe},Be)}var Ve=d.createElement(Yn.Item,Me({ref:t,role:"none"},D,{component:"li",style:r,className:pe(Z,"".concat(Z,"-").concat(x),n,T(T(T(T({},"".concat(Z,"-open"),W),"".concat(Z,"-active"),we),"".concat(Z,"-selected"),re),"".concat(Z,"-disabled"),te)),onMouseEnter:ye,onMouseLeave:ke}),Be,!$&&d.createElement(YI,{id:Fe,open:W,keyPath:q},s));return _&&(Ve=_(Ve,e,{selected:re,active:we,open:W,disabled:te})),d.createElement(hl,{onItemClick:Oe,mode:x==="horizontal"?"vertical":x,itemIcon:V,expandIcon:U},Ve)}),zu=d.forwardRef(function(e,t){var r=e.eventKey,n=e.children,o=si(r),a=cm(n,o),i=Mu();d.useEffect(function(){if(i)return i.registerPath(r,o),function(){i.unregisterPath(r,o)}},[o]);var l;return i?l=a:l=d.createElement(QI,Me({ref:t},e),a),d.createElement(Ex.Provider,{value:o},l)});function dm(e){var t=e.className,r=e.style,n=d.useContext(Hn),o=n.prefixCls,a=Mu();return a?null:d.createElement("li",{role:"separator",className:pe("".concat(o,"-item-divider"),t),style:r})}var e4=["className","title","eventKey","children"],t4=d.forwardRef(function(e,t){var r=e.className,n=e.title;e.eventKey;var o=e.children,a=bt(e,e4),i=d.useContext(Hn),l=i.prefixCls,s="".concat(l,"-item-group");return d.createElement("li",Me({ref:t,role:"presentation"},a,{onClick:function(u){return u.stopPropagation()},className:pe(s,r)}),d.createElement("div",{role:"presentation",className:"".concat(s,"-title"),title:typeof n=="string"?n:void 0},n),d.createElement("ul",{role:"group",className:"".concat(s,"-list")},o))}),fm=d.forwardRef(function(e,t){var r=e.eventKey,n=e.children,o=si(r),a=cm(n,o),i=Mu();return i?a:d.createElement(t4,Me({ref:t},fn(e,["warnKey"])),a)}),r4=["label","children","key","type","extra"];function Lf(e,t,r){var n=t.item,o=t.group,a=t.submenu,i=t.divider;return(e||[]).map(function(l,s){if(l&&at(l)==="object"){var u=l,c=u.label,f=u.children,p=u.key,h=u.type,v=u.extra,g=bt(u,r4),m=p??"tmp-".concat(s);return f||h==="group"?h==="group"?d.createElement(o,Me({key:m},g,{title:c}),Lf(f,t,r)):d.createElement(a,Me({key:m},g,{title:c}),Lf(f,t,r)):h==="divider"?d.createElement(i,Me({key:m},g)):d.createElement(n,Me({key:m},g,{extra:v}),c,(!!v||v===0)&&d.createElement("span",{className:"".concat(r,"-item-extra")},v))}return null}).filter(function(l){return l})}function S0(e,t,r,n,o){var a=e,i=L({divider:dm,item:Tu,group:fm,submenu:zu},n);return t&&(a=Lf(t,i,o)),cm(a,r)}var n4=["prefixCls","rootClassName","style","className","tabIndex","items","children","direction","id","mode","inlineCollapsed","disabled","disabledOverflow","subMenuOpenDelay","subMenuCloseDelay","forceSubMenuRender","defaultOpenKeys","openKeys","activeKey","defaultActiveFirst","selectable","multiple","defaultSelectedKeys","selectedKeys","onSelect","onDeselect","inlineIndent","motion","defaultMotions","triggerSubMenuAction","builtinPlacements","itemIcon","expandIcon","overflowedIndicator","overflowedIndicatorPopupClassName","getPopupContainer","onClick","onOpenChange","onKeyDown","openAnimation","openTransitionName","_internalRenderMenuItem","_internalRenderSubMenuItem","_internalComponents"],To=[],o4=d.forwardRef(function(e,t){var r,n=e,o=n.prefixCls,a=o===void 0?"rc-menu":o,i=n.rootClassName,l=n.style,s=n.className,u=n.tabIndex,c=u===void 0?0:u,f=n.items,p=n.children,h=n.direction,v=n.id,g=n.mode,m=g===void 0?"vertical":g,b=n.inlineCollapsed,y=n.disabled,C=n.disabledOverflow,D=n.subMenuOpenDelay,w=D===void 0?.1:D,k=n.subMenuCloseDelay,E=k===void 0?.1:k,x=n.forceSubMenuRender,O=n.defaultOpenKeys,j=n.openKeys,$=n.activeKey,P=n.defaultActiveFirst,A=n.selectable,B=A===void 0?!0:A,S=n.multiple,I=S===void 0?!1:S,N=n.defaultSelectedKeys,F=n.selectedKeys,M=n.onSelect,_=n.onDeselect,X=n.inlineIndent,H=X===void 0?24:X,q=n.motion,Z=n.defaultMotions,te=n.triggerSubMenuAction,z=te===void 0?"hover":te,Y=n.builtinPlacements,V=n.itemIcon,U=n.expandIcon,K=n.overflowedIndicator,W=K===void 0?"...":K,re=n.overflowedIndicatorPopupClassName,G=n.getPopupContainer,J=n.onClick,oe=n.onOpenChange,se=n.onKeyDown;n.openAnimation,n.openTransitionName;var ge=n._internalRenderMenuItem,Ee=n._internalRenderSubMenuItem,je=n._internalComponents,ve=bt(n,n4),ye=d.useMemo(function(){return[S0(p,f,To,je,a),S0(p,f,To,{},a)]},[p,f,je]),ke=ce(ye,2),we=ke[0],De=ke[1],Ne=d.useState(!1),Oe=ce(Ne,2),Xe=Oe[0],Le=Oe[1],Fe=d.useRef(),fe=RI(v),Be=h==="rtl",We=Gr(O,{value:j,postState:function(Ct){return Ct||To}}),Ye=ce(We,2),Ve=Ye[0],Te=Ye[1],it=function(Ct){var Je=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;function vt(){Te(Ct),oe==null||oe(Ct)}Je?ud(vt):vt()},Ue=d.useState(Ve),nt=ce(Ue,2),pt=nt[0],St=nt[1],dt=d.useRef(!1),ht=d.useMemo(function(){return(m==="inline"||m==="vertical")&&b?["vertical",b]:[m,!1]},[m,b]),Pt=ce(ht,2),At=Pt[0],ct=Pt[1],ut=At==="inline",ae=d.useState(At),he=ce(ae,2),xe=he[0],be=he[1],Ce=d.useState(ct),de=ce(Ce,2),Se=de[0],le=de[1];d.useEffect(function(){be(At),le(ct),dt.current&&(ut?Te(pt):it(To))},[At,ct]);var ie=d.useState(0),me=ce(ie,2),ze=me[0],_e=me[1],Ke=ze>=we.length-1||xe!=="horizontal"||C;d.useEffect(function(){ut&&St(Ve)},[Ve]),d.useEffect(function(){return dt.current=!0,function(){dt.current=!1}},[]);var Pe=jI(),Ze=Pe.registerPath,wt=Pe.unregisterPath,jt=Pe.refreshOverflowKeys,It=Pe.isSubPathKey,Et=Pe.getKeyPath,Jt=Pe.getKeys,pr=Pe.getSubPathKeys,He=d.useMemo(function(){return{registerPath:Ze,unregisterPath:wt}},[Ze,wt]),Qe=d.useMemo(function(){return{isSubPathKey:It}},[It]);d.useEffect(function(){jt(Ke?To:we.slice(ze+1).map(function(Ct){return Ct.key}))},[ze,Ke]);var gt=Gr($||P&&((r=we[0])===null||r===void 0?void 0:r.key),{value:$}),Mt=ce(gt,2),Ft=Mt[0],yr=Mt[1],Cr=Oi(function(Ct){yr(Ct)}),st=Oi(function(){yr(void 0)});ei(t,function(){return{list:Fe.current,focus:function(Ct){var Je,vt=Jt(),Lt=zf(vt,fe),_t=Lt.elements,tr=Lt.key2element,Dr=Lt.element2key,mr=lm(Fe.current,_t),_r=Ft??(mr[0]?Dr.get(mr[0]):(Je=we.find(function(wn){return!wn.props.disabled}))===null||Je===void 0?void 0:Je.key),xr=tr.get(_r);if(_r&&xr){var Ar;xr==null||(Ar=xr.focus)===null||Ar===void 0||Ar.call(xr,Ct)}}}});var $t=Gr(N||[],{value:F,postState:function(Ct){return Array.isArray(Ct)?Ct:Ct==null?To:[Ct]}}),Bt=ce($t,2),Gt=Bt[0],Mr=Bt[1],Zr=function(Ct){if(B){var Je=Ct.key,vt=Gt.includes(Je),Lt;I?vt?Lt=Gt.filter(function(tr){return tr!==Je}):Lt=[].concat(Ie(Gt),[Je]):Lt=[Je],Mr(Lt);var _t=L(L({},Ct),{},{selectedKeys:Lt});vt?_==null||_(_t):M==null||M(_t)}!I&&Ve.length&&xe!=="inline"&&it(To)},xn=Oi(function(Ct){J==null||J(Us(Ct)),Zr(Ct)}),on=Oi(function(Ct,Je){var vt=Ve.filter(function(_t){return _t!==Ct});if(Je)vt.push(Ct);else if(xe!=="inline"){var Lt=pr(Ct);vt=vt.filter(function(_t){return!Lt.has(_t)})}Jn(Ve,vt,!0)||it(vt,!0)}),Tr=function(Ct,Je){var vt=Je??!Ve.includes(Ct);on(Ct,vt)},an=FI(xe,Ft,Be,fe,Fe,Jt,Et,yr,Tr,se);d.useEffect(function(){Le(!0)},[]);var Jr=d.useMemo(function(){return{_internalRenderMenuItem:ge,_internalRenderSubMenuItem:Ee}},[ge,Ee]),zr=xe!=="horizontal"||C?we:we.map(function(Ct,Je){return d.createElement(hl,{key:Ct.key,overflowDisabled:Je>ze},Ct)}),ln=d.createElement(Yn,Me({id:v,ref:Fe,prefixCls:"".concat(a,"-overflow"),component:"ul",itemComponent:Tu,className:pe(a,"".concat(a,"-root"),"".concat(a,"-").concat(xe),s,T(T({},"".concat(a,"-inline-collapsed"),Se),"".concat(a,"-rtl"),Be),i),dir:h,style:l,role:"menu",tabIndex:c,data:zr,renderRawItem:function(Ct){return Ct},renderRawRest:function(Ct){var Je=Ct.length,vt=Je?we.slice(-Je):null;return d.createElement(zu,{eventKey:_f,title:W,disabled:Ke,internalPopupClose:Je===0,popupClassName:re},vt)},maxCount:xe!=="horizontal"||C?Yn.INVALIDATE:Yn.RESPONSIVE,ssr:"full","data-menu-list":!0,onVisibleChange:function(Ct){_e(Ct)},onKeyDown:an},ve));return d.createElement(im.Provider,{value:Jr},d.createElement(yx.Provider,{value:fe},d.createElement(hl,{prefixCls:a,rootClassName:i,mode:xe,openKeys:Ve,rtl:Be,disabled:y,motion:Xe?q:null,defaultMotions:Xe?Z:null,activeKey:Ft,onActive:Cr,onInactive:st,selectedKeys:Gt,inlineIndent:H,subMenuOpenDelay:w,subMenuCloseDelay:E,forceSubMenuRender:x,builtinPlacements:Y,triggerSubMenuAction:z,getPopupContainer:G,itemIcon:V,expandIcon:U,onItemClick:xn,onOpenChange:on},d.createElement(kx.Provider,{value:Qe},ln),d.createElement("div",{style:{display:"none"},"aria-hidden":!0},d.createElement(wx.Provider,{value:He},De)))))}),Sl=o4;Sl.Item=Tu;Sl.SubMenu=zu;Sl.ItemGroup=fm;Sl.Divider=dm;const a4=e=>{const{antCls:t,componentCls:r,colorText:n,footerBg:o,headerHeight:a,headerPadding:i,headerColor:l,footerPadding:s,fontSize:u,bodyBg:c,headerBg:f}=e;return{[r]:{display:"flex",flex:"auto",flexDirection:"column",minHeight:0,background:c,"&, *":{boxSizing:"border-box"},[`&${r}-has-sider`]:{flexDirection:"row",[`> ${r}, > ${r}-content`]:{width:0}},[`${r}-header, &${r}-footer`]:{flex:"0 0 auto"},"&-rtl":{direction:"rtl"}},[`${r}-header`]:{height:a,padding:i,color:l,lineHeight:ue(a),background:f,[`${t}-menu`]:{lineHeight:"inherit"}},[`${r}-footer`]:{padding:s,color:n,fontSize:u,background:o},[`${r}-content`]:{flex:"auto",color:n,minHeight:0}}},Ax=e=>{const{colorBgLayout:t,controlHeight:r,controlHeightLG:n,colorText:o,controlHeightSM:a,marginXXS:i,colorTextLightSolid:l,colorBgContainer:s}=e,u=n*1.25;return{colorBgHeader:"#001529",colorBgBody:t,colorBgTrigger:"#002140",bodyBg:t,headerBg:"#001529",headerHeight:r*2,headerPadding:`0 ${u}px`,headerColor:o,footerPadding:`${a}px ${u}px`,footerBg:t,siderBg:"#001529",triggerHeight:n+i*2,triggerBg:"#002140",triggerColor:l,zeroTriggerWidth:n,zeroTriggerHeight:n,lightSiderBg:s,lightTriggerBg:s,lightTriggerColor:o}},Fx=[["colorBgBody","bodyBg"],["colorBgHeader","headerBg"],["colorBgTrigger","triggerBg"]];Hr("Layout",a4,Ax,{deprecatedTokens:Fx});const i4=e=>{const{componentCls:t,siderBg:r,motionDurationMid:n,motionDurationSlow:o,antCls:a,triggerHeight:i,triggerColor:l,triggerBg:s,headerHeight:u,zeroTriggerWidth:c,zeroTriggerHeight:f,borderRadiusLG:p,lightSiderBg:h,lightTriggerColor:v,lightTriggerBg:g,bodyBg:m}=e;return{[t]:{position:"relative",minWidth:0,background:r,transition:`all ${n}, background 0s`,"&-has-trigger":{paddingBottom:i},"&-right":{order:1},[`${t}-children`]:{height:"100%",marginTop:-.1,paddingTop:.1,[`${a}-menu${a}-menu-inline-collapsed`]:{width:"auto"}},[`&-zero-width ${t}-children`]:{overflow:"hidden"},[`${t}-trigger`]:{position:"fixed",bottom:0,zIndex:1,height:i,color:l,lineHeight:ue(i),textAlign:"center",background:s,cursor:"pointer",transition:`all ${n}`},[`${t}-zero-width-trigger`]:{position:"absolute",top:u,insetInlineEnd:e.calc(c).mul(-1).equal(),zIndex:1,width:c,height:f,color:l,fontSize:e.fontSizeXL,display:"flex",alignItems:"center",justifyContent:"center",background:r,borderRadius:`0 ${ue(p)} ${ue(p)} 0`,cursor:"pointer",transition:`background ${o} ease`,"&::after":{position:"absolute",inset:0,background:"transparent",transition:`all ${o}`,content:'""'},"&:hover::after":{background:"rgba(255, 255, 255, 0.2)"},"&-right":{insetInlineStart:e.calc(c).mul(-1).equal(),borderRadius:`${ue(p)} 0 0 ${ue(p)}`}},"&-light":{background:h,[`${t}-trigger`]:{color:v,background:g},[`${t}-zero-width-trigger`]:{color:v,background:g,border:`1px solid ${m}`,borderInlineStart:0}}}}};Hr(["Layout","Sider"],i4,Ax,{deprecatedTokens:Fx});const Nx=d.createContext({});var l4={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"ellipsis",theme:"outlined"},s4=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:l4}))},Px=d.forwardRef(s4);const Ys=Fn({prefixCls:"",firstLevel:!0,inlineCollapsed:!1});var u4=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const jx=e=>{const{prefixCls:t,className:r,dashed:n}=e,o=u4(e,["prefixCls","className","dashed"]),{getPrefixCls:a}=d.useContext(Zt),i=a("menu",t),l=pe({[`${i}-item-divider-dashed`]:!!n},r);return d.createElement(dm,Object.assign({className:l},o))},Ix=e=>{var t;const{className:r,children:n,icon:o,title:a,danger:i,extra:l}=e,{prefixCls:s,firstLevel:u,direction:c,disableMenuItemTitleTooltip:f,inlineCollapsed:p}=d.useContext(Ys),h=C=>{const D=n==null?void 0:n[0],w=d.createElement("span",{className:pe(`${s}-title-content`,{[`${s}-title-content-with-extra`]:!!l||l===0})},n);return(!o||d.isValidElement(n)&&n.type==="span")&&n&&C&&u&&typeof D=="string"?d.createElement("div",{className:`${s}-inline-collapsed-noicon`},D.charAt(0)):w},{siderCollapsed:v}=d.useContext(Nx);let g=a;typeof a>"u"?g=u?n:"":a===!1&&(g="");const m={title:g};!v&&!p&&(m.title=null,m.open=!1);const b=Ln(n).length;let y=d.createElement(Tu,Object.assign({},fn(e,["title","icon","danger"]),{className:pe({[`${s}-item-danger`]:i,[`${s}-item-only-child`]:(o?b+1:b)===1},r),title:typeof a=="string"?a:void 0}),eo(o,{className:pe(d.isValidElement(o)?(t=o.props)===null||t===void 0?void 0:t.className:void 0,`${s}-item-icon`)}),h(p));return f||(y=d.createElement(ml,Object.assign({},m,{placement:c==="rtl"?"left":"right",classNames:{root:`${s}-inline-collapsed-tooltip`}}),y)),y};var c4=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const Zs=d.createContext(null),Rx=d.forwardRef((e,t)=>{const{children:r}=e,n=c4(e,["children"]),o=d.useContext(Zs),a=d.useMemo(()=>Object.assign(Object.assign({},o),n),[o,n.prefixCls,n.mode,n.selectable,n.rootClassName]),i=KB(r),l=sa(t,i?ua(r):null);return d.createElement(Zs.Provider,{value:a},d.createElement(fl,{space:!0},i?d.cloneElement(r,{ref:l}):r))}),d4=e=>{const{componentCls:t,motionDurationSlow:r,horizontalLineHeight:n,colorSplit:o,lineWidth:a,lineType:i,itemPaddingInline:l}=e;return{[`${t}-horizontal`]:{lineHeight:n,border:0,borderBottom:`${ue(a)} ${i} ${o}`,boxShadow:"none","&::after":{display:"block",clear:"both",height:0,content:'"\\20"'},[`${t}-item, ${t}-submenu`]:{position:"relative",display:"inline-block",verticalAlign:"bottom",paddingInline:l},[`> ${t}-item:hover,
|
|
327
|
+
> ${t}-item-active,
|
|
328
|
+
> ${t}-submenu ${t}-submenu-title:hover`]:{backgroundColor:"transparent"},[`${t}-item, ${t}-submenu-title`]:{transition:[`border-color ${r}`,`background ${r}`].join(",")},[`${t}-submenu-arrow`]:{display:"none"}}}},f4=({componentCls:e,menuArrowOffset:t,calc:r})=>({[`${e}-rtl`]:{direction:"rtl"},[`${e}-submenu-rtl`]:{transformOrigin:"100% 0"},[`${e}-rtl${e}-vertical,
|
|
329
|
+
${e}-submenu-rtl ${e}-vertical`]:{[`${e}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateY(${ue(r(t).mul(-1).equal())})`},"&::after":{transform:`rotate(45deg) translateY(${ue(t)})`}}}}),$0=e=>Po(e),B0=(e,t)=>{const{componentCls:r,itemColor:n,itemSelectedColor:o,subMenuItemSelectedColor:a,groupTitleColor:i,itemBg:l,subMenuItemBg:s,itemSelectedBg:u,activeBarHeight:c,activeBarWidth:f,activeBarBorderWidth:p,motionDurationSlow:h,motionEaseInOut:v,motionEaseOut:g,itemPaddingInline:m,motionDurationMid:b,itemHoverColor:y,lineType:C,colorSplit:D,itemDisabledColor:w,dangerItemColor:k,dangerItemHoverColor:E,dangerItemSelectedColor:x,dangerItemActiveBg:O,dangerItemSelectedBg:j,popupBg:$,itemHoverBg:P,itemActiveBg:A,menuSubMenuBg:B,horizontalItemSelectedColor:S,horizontalItemSelectedBg:I,horizontalItemBorderRadius:N,horizontalItemHoverBg:F}=e;return{[`${r}-${t}, ${r}-${t} > ${r}`]:{color:n,background:l,[`&${r}-root:focus-visible`]:Object.assign({},$0(e)),[`${r}-item`]:{"&-group-title, &-extra":{color:i}},[`${r}-submenu-selected > ${r}-submenu-title`]:{color:a},[`${r}-item, ${r}-submenu-title`]:{color:n,[`&:not(${r}-item-disabled):focus-visible`]:Object.assign({},$0(e))},[`${r}-item-disabled, ${r}-submenu-disabled`]:{color:`${w} !important`},[`${r}-item:not(${r}-item-selected):not(${r}-submenu-selected)`]:{[`&:hover, > ${r}-submenu-title:hover`]:{color:y}},[`&:not(${r}-horizontal)`]:{[`${r}-item:not(${r}-item-selected)`]:{"&:hover":{backgroundColor:P},"&:active":{backgroundColor:A}},[`${r}-submenu-title`]:{"&:hover":{backgroundColor:P},"&:active":{backgroundColor:A}}},[`${r}-item-danger`]:{color:k,[`&${r}-item:hover`]:{[`&:not(${r}-item-selected):not(${r}-submenu-selected)`]:{color:E}},[`&${r}-item:active`]:{background:O}},[`${r}-item a`]:{"&, &:hover":{color:"inherit"}},[`${r}-item-selected`]:{color:o,[`&${r}-item-danger`]:{color:x},"a, a:hover":{color:"inherit"}},[`& ${r}-item-selected`]:{backgroundColor:u,[`&${r}-item-danger`]:{backgroundColor:j}},[`&${r}-submenu > ${r}`]:{backgroundColor:B},[`&${r}-popup > ${r}`]:{backgroundColor:$},[`&${r}-submenu-popup > ${r}`]:{backgroundColor:$},[`&${r}-horizontal`]:Object.assign(Object.assign({},t==="dark"?{borderBottom:0}:{}),{[`> ${r}-item, > ${r}-submenu`]:{top:p,marginTop:e.calc(p).mul(-1).equal(),marginBottom:0,borderRadius:N,"&::after":{position:"absolute",insetInline:m,bottom:0,borderBottom:`${ue(c)} solid transparent`,transition:`border-color ${h} ${v}`,content:'""'},"&:hover, &-active, &-open":{background:F,"&::after":{borderBottomWidth:c,borderBottomColor:S}},"&-selected":{color:S,backgroundColor:I,"&:hover":{backgroundColor:I},"&::after":{borderBottomWidth:c,borderBottomColor:S}}}}),[`&${r}-root`]:{[`&${r}-inline, &${r}-vertical`]:{borderInlineEnd:`${ue(p)} ${C} ${D}`}},[`&${r}-inline`]:{[`${r}-sub${r}-inline`]:{background:s},[`${r}-item`]:{position:"relative","&::after":{position:"absolute",insetBlock:0,insetInlineEnd:0,borderInlineEnd:`${ue(f)} solid ${o}`,transform:"scaleY(0.0001)",opacity:0,transition:[`transform ${b} ${g}`,`opacity ${b} ${g}`].join(","),content:'""'},[`&${r}-item-danger`]:{"&::after":{borderInlineEndColor:x}}},[`${r}-selected, ${r}-item-selected`]:{"&::after":{transform:"scaleY(1)",opacity:1,transition:[`transform ${b} ${v}`,`opacity ${b} ${v}`].join(",")}}}}}},O0=e=>{const{componentCls:t,itemHeight:r,itemMarginInline:n,padding:o,menuArrowSize:a,marginXS:i,itemMarginBlock:l,itemWidth:s,itemPaddingInline:u}=e,c=e.calc(a).add(o).add(i).equal();return{[`${t}-item`]:{position:"relative",overflow:"hidden"},[`${t}-item, ${t}-submenu-title`]:{height:r,lineHeight:ue(r),paddingInline:u,overflow:"hidden",textOverflow:"ellipsis",marginInline:n,marginBlock:l,width:s},[`> ${t}-item,
|
|
330
|
+
> ${t}-submenu > ${t}-submenu-title`]:{height:r,lineHeight:ue(r)},[`${t}-item-group-list ${t}-submenu-title,
|
|
331
|
+
${t}-submenu-title`]:{paddingInlineEnd:c}}},p4=e=>{const{componentCls:t,iconCls:r,itemHeight:n,colorTextLightSolid:o,dropdownWidth:a,controlHeightLG:i,motionEaseOut:l,paddingXL:s,itemMarginInline:u,fontSizeLG:c,motionDurationFast:f,motionDurationSlow:p,paddingXS:h,boxShadowSecondary:v,collapsedWidth:g,collapsedIconSize:m}=e,b={height:n,lineHeight:ue(n),listStylePosition:"inside",listStyleType:"disc"};return[{[t]:{"&-inline, &-vertical":Object.assign({[`&${t}-root`]:{boxShadow:"none"}},O0(e))},[`${t}-submenu-popup`]:{[`${t}-vertical`]:Object.assign(Object.assign({},O0(e)),{boxShadow:v})}},{[`${t}-submenu-popup ${t}-vertical${t}-sub`]:{minWidth:a,maxHeight:`calc(100vh - ${ue(e.calc(i).mul(2.5).equal())})`,padding:"0",overflow:"hidden",borderInlineEnd:0,"&:not([class*='-active'])":{overflowX:"hidden",overflowY:"auto"}}},{[`${t}-inline`]:{width:"100%",[`&${t}-root`]:{[`${t}-item, ${t}-submenu-title`]:{display:"flex",alignItems:"center",transition:[`border-color ${p}`,`background ${p}`,`padding ${f} ${l}`].join(","),[`> ${t}-title-content`]:{flex:"auto",minWidth:0,overflow:"hidden",textOverflow:"ellipsis"},"> *":{flex:"none"}}},[`${t}-sub${t}-inline`]:{padding:0,border:0,borderRadius:0,boxShadow:"none",[`& > ${t}-submenu > ${t}-submenu-title`]:b,[`& ${t}-item-group-title`]:{paddingInlineStart:s}},[`${t}-item`]:b}},{[`${t}-inline-collapsed`]:{width:g,[`&${t}-root`]:{[`${t}-item, ${t}-submenu ${t}-submenu-title`]:{[`> ${t}-inline-collapsed-noicon`]:{fontSize:c,textAlign:"center"}}},[`> ${t}-item,
|
|
332
|
+
> ${t}-item-group > ${t}-item-group-list > ${t}-item,
|
|
333
|
+
> ${t}-item-group > ${t}-item-group-list > ${t}-submenu > ${t}-submenu-title,
|
|
334
|
+
> ${t}-submenu > ${t}-submenu-title`]:{insetInlineStart:0,paddingInline:`calc(50% - ${ue(e.calc(m).div(2).equal())} - ${ue(u)})`,textOverflow:"clip",[`
|
|
335
|
+
${t}-submenu-arrow,
|
|
336
|
+
${t}-submenu-expand-icon
|
|
337
|
+
`]:{opacity:0},[`${t}-item-icon, ${r}`]:{margin:0,fontSize:m,lineHeight:ue(n),"+ span":{display:"inline-block",opacity:0}}},[`${t}-item-icon, ${r}`]:{display:"inline-block"},"&-tooltip":{pointerEvents:"none",[`${t}-item-icon, ${r}`]:{display:"none"},"a, a:hover":{color:o}},[`${t}-item-group-title`]:Object.assign(Object.assign({},ul),{paddingInline:h})}}]},A0=e=>{const{componentCls:t,motionDurationSlow:r,motionDurationMid:n,motionEaseInOut:o,motionEaseOut:a,iconCls:i,iconSize:l,iconMarginInlineEnd:s}=e;return{[`${t}-item, ${t}-submenu-title`]:{position:"relative",display:"block",margin:0,whiteSpace:"nowrap",cursor:"pointer",transition:[`border-color ${r}`,`background ${r}`,`padding calc(${r} + 0.1s) ${o}`].join(","),[`${t}-item-icon, ${i}`]:{minWidth:l,fontSize:l,transition:[`font-size ${n} ${a}`,`margin ${r} ${o}`,`color ${r}`].join(","),"+ span":{marginInlineStart:s,opacity:1,transition:[`opacity ${r} ${o}`,`margin ${r}`,`color ${r}`].join(",")}},[`${t}-item-icon`]:Object.assign({},xl()),[`&${t}-item-only-child`]:{[`> ${i}, > ${t}-item-icon`]:{marginInlineEnd:0}}},[`${t}-item-disabled, ${t}-submenu-disabled`]:{background:"none !important",cursor:"not-allowed","&::after":{borderColor:"transparent !important"},a:{color:"inherit !important",cursor:"not-allowed",pointerEvents:"none"},[`> ${t}-submenu-title`]:{color:"inherit !important",cursor:"not-allowed"}}}},F0=e=>{const{componentCls:t,motionDurationSlow:r,motionEaseInOut:n,borderRadius:o,menuArrowSize:a,menuArrowOffset:i}=e;return{[`${t}-submenu`]:{"&-expand-icon, &-arrow":{position:"absolute",top:"50%",insetInlineEnd:e.margin,width:a,color:"currentcolor",transform:"translateY(-50%)",transition:`transform ${r} ${n}, opacity ${r}`},"&-arrow":{"&::before, &::after":{position:"absolute",width:e.calc(a).mul(.6).equal(),height:e.calc(a).mul(.15).equal(),backgroundColor:"currentcolor",borderRadius:o,transition:[`background ${r} ${n}`,`transform ${r} ${n}`,`top ${r} ${n}`,`color ${r} ${n}`].join(","),content:'""'},"&::before":{transform:`rotate(45deg) translateY(${ue(e.calc(i).mul(-1).equal())})`},"&::after":{transform:`rotate(-45deg) translateY(${ue(i)})`}}}}},m4=e=>{const{antCls:t,componentCls:r,fontSize:n,motionDurationSlow:o,motionDurationMid:a,motionEaseInOut:i,paddingXS:l,padding:s,colorSplit:u,lineWidth:c,zIndexPopup:f,borderRadiusLG:p,subMenuItemBorderRadius:h,menuArrowSize:v,menuArrowOffset:g,lineType:m,groupTitleLineHeight:b,groupTitleFontSize:y}=e;return[{"":{[r]:Object.assign(Object.assign({},Hs()),{"&-hidden":{display:"none"}})},[`${r}-submenu-hidden`]:{display:"none"}},{[r]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Br(e)),Hs()),{marginBottom:0,paddingInlineStart:0,fontSize:n,lineHeight:0,listStyle:"none",outline:"none",transition:`width ${o} cubic-bezier(0.2, 0, 0, 1) 0s`,"ul, ol":{margin:0,padding:0,listStyle:"none"},"&-overflow":{display:"flex",[`${r}-item`]:{flex:"none"}},[`${r}-item, ${r}-submenu, ${r}-submenu-title`]:{borderRadius:e.itemBorderRadius},[`${r}-item-group-title`]:{padding:`${ue(l)} ${ue(s)}`,fontSize:y,lineHeight:b,transition:`all ${o}`},[`&-horizontal ${r}-submenu`]:{transition:[`border-color ${o} ${i}`,`background ${o} ${i}`].join(",")},[`${r}-submenu, ${r}-submenu-inline`]:{transition:[`border-color ${o} ${i}`,`background ${o} ${i}`,`padding ${a} ${i}`].join(",")},[`${r}-submenu ${r}-sub`]:{cursor:"initial",transition:[`background ${o} ${i}`,`padding ${o} ${i}`].join(",")},[`${r}-title-content`]:{transition:`color ${o}`,"&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},[`> ${t}-typography-ellipsis-single-line`]:{display:"inline",verticalAlign:"unset"},[`${r}-item-extra`]:{marginInlineStart:"auto",paddingInlineStart:e.padding}},[`${r}-item a`]:{"&::before":{position:"absolute",inset:0,backgroundColor:"transparent",content:'""'}},[`${r}-item-divider`]:{overflow:"hidden",lineHeight:0,borderColor:u,borderStyle:m,borderWidth:0,borderTopWidth:c,marginBlock:c,padding:0,"&-dashed":{borderStyle:"dashed"}}}),A0(e)),{[`${r}-item-group`]:{[`${r}-item-group-list`]:{margin:0,padding:0,[`${r}-item, ${r}-submenu-title`]:{paddingInline:`${ue(e.calc(n).mul(2).equal())} ${ue(s)}`}}},"&-submenu":{"&-popup":{position:"absolute",zIndex:f,borderRadius:p,boxShadow:"none",transformOrigin:"0 0",[`&${r}-submenu`]:{background:"transparent"},"&::before":{position:"absolute",inset:0,zIndex:-1,width:"100%",height:"100%",opacity:0,content:'""'},[`> ${r}`]:Object.assign(Object.assign(Object.assign({borderRadius:p},A0(e)),F0(e)),{[`${r}-item, ${r}-submenu > ${r}-submenu-title`]:{borderRadius:h},[`${r}-submenu-title::after`]:{transition:`transform ${o} ${i}`}})},"\n &-placement-leftTop,\n &-placement-bottomRight,\n ":{transformOrigin:"100% 0"},"\n &-placement-leftBottom,\n &-placement-topRight,\n ":{transformOrigin:"100% 100%"},"\n &-placement-rightBottom,\n &-placement-topLeft,\n ":{transformOrigin:"0 100%"},"\n &-placement-bottomLeft,\n &-placement-rightTop,\n ":{transformOrigin:"0 0"},"\n &-placement-leftTop,\n &-placement-leftBottom\n ":{paddingInlineEnd:e.paddingXS},"\n &-placement-rightTop,\n &-placement-rightBottom\n ":{paddingInlineStart:e.paddingXS},"\n &-placement-topRight,\n &-placement-topLeft\n ":{paddingBottom:e.paddingXS},"\n &-placement-bottomRight,\n &-placement-bottomLeft\n ":{paddingTop:e.paddingXS}}}),F0(e)),{[`&-inline-collapsed ${r}-submenu-arrow,
|
|
338
|
+
&-inline ${r}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateX(${ue(g)})`},"&::after":{transform:`rotate(45deg) translateX(${ue(e.calc(g).mul(-1).equal())})`}},[`${r}-submenu-open${r}-submenu-inline > ${r}-submenu-title > ${r}-submenu-arrow`]:{transform:`translateY(${ue(e.calc(v).mul(.2).mul(-1).equal())})`,"&::after":{transform:`rotate(-45deg) translateX(${ue(e.calc(g).mul(-1).equal())})`},"&::before":{transform:`rotate(45deg) translateX(${ue(g)})`}}})},{[`${t}-layout-header`]:{[r]:{lineHeight:"inherit"}}}]},h4=e=>{var t,r,n;const{colorPrimary:o,colorError:a,colorTextDisabled:i,colorErrorBg:l,colorText:s,colorTextDescription:u,colorBgContainer:c,colorFillAlter:f,colorFillContent:p,lineWidth:h,lineWidthBold:v,controlItemBgActive:g,colorBgTextHover:m,controlHeightLG:b,lineHeight:y,colorBgElevated:C,marginXXS:D,padding:w,fontSize:k,controlHeightSM:E,fontSizeLG:x,colorTextLightSolid:O,colorErrorHover:j}=e,$=(t=e.activeBarWidth)!==null&&t!==void 0?t:0,P=(r=e.activeBarBorderWidth)!==null&&r!==void 0?r:h,A=(n=e.itemMarginInline)!==null&&n!==void 0?n:e.marginXXS,B=new Ht(O).setA(.65).toRgbString();return{dropdownWidth:160,zIndexPopup:e.zIndexPopupBase+50,radiusItem:e.borderRadiusLG,itemBorderRadius:e.borderRadiusLG,radiusSubMenuItem:e.borderRadiusSM,subMenuItemBorderRadius:e.borderRadiusSM,colorItemText:s,itemColor:s,colorItemTextHover:s,itemHoverColor:s,colorItemTextHoverHorizontal:o,horizontalItemHoverColor:o,colorGroupTitle:u,groupTitleColor:u,colorItemTextSelected:o,itemSelectedColor:o,subMenuItemSelectedColor:o,colorItemTextSelectedHorizontal:o,horizontalItemSelectedColor:o,colorItemBg:c,itemBg:c,colorItemBgHover:m,itemHoverBg:m,colorItemBgActive:p,itemActiveBg:g,colorSubItemBg:f,subMenuItemBg:f,colorItemBgSelected:g,itemSelectedBg:g,colorItemBgSelectedHorizontal:"transparent",horizontalItemSelectedBg:"transparent",colorActiveBarWidth:0,activeBarWidth:$,colorActiveBarHeight:v,activeBarHeight:v,colorActiveBarBorderSize:h,activeBarBorderWidth:P,colorItemTextDisabled:i,itemDisabledColor:i,colorDangerItemText:a,dangerItemColor:a,colorDangerItemTextHover:a,dangerItemHoverColor:a,colorDangerItemTextSelected:a,dangerItemSelectedColor:a,colorDangerItemBgActive:l,dangerItemActiveBg:l,colorDangerItemBgSelected:l,dangerItemSelectedBg:l,itemMarginInline:A,horizontalItemBorderRadius:0,horizontalItemHoverBg:"transparent",itemHeight:b,groupTitleLineHeight:y,collapsedWidth:b*2,popupBg:C,itemMarginBlock:D,itemPaddingInline:w,horizontalLineHeight:`${b*1.15}px`,iconSize:k,iconMarginInlineEnd:E-k,collapsedIconSize:x,groupTitleFontSize:k,darkItemDisabledColor:new Ht(O).setA(.25).toRgbString(),darkItemColor:B,darkDangerItemColor:a,darkItemBg:"#001529",darkPopupBg:"#001529",darkSubMenuItemBg:"#000c17",darkItemSelectedColor:O,darkItemSelectedBg:o,darkDangerItemSelectedBg:a,darkItemHoverBg:"transparent",darkGroupTitleColor:B,darkItemHoverColor:O,darkDangerItemHoverColor:j,darkDangerItemSelectedColor:O,darkDangerItemActiveBg:a,itemWidth:$?`calc(100% + ${P}px)`:`calc(100% - ${A*2}px)`}},g4=(e,t=e,r=!0)=>Hr("Menu",n=>{const{colorBgElevated:o,controlHeightLG:a,fontSize:i,darkItemColor:l,darkDangerItemColor:s,darkItemBg:u,darkSubMenuItemBg:c,darkItemSelectedColor:f,darkItemSelectedBg:p,darkDangerItemSelectedBg:h,darkItemHoverBg:v,darkGroupTitleColor:g,darkItemHoverColor:m,darkItemDisabledColor:b,darkDangerItemHoverColor:y,darkDangerItemSelectedColor:C,darkDangerItemActiveBg:D,popupBg:w,darkPopupBg:k}=n,E=n.calc(i).div(7).mul(5).equal(),x=er(n,{menuArrowSize:E,menuHorizontalHeight:n.calc(a).mul(1.15).equal(),menuArrowOffset:n.calc(E).mul(.25).equal(),menuSubMenuBg:o,calc:n.calc,popupBg:w}),O=er(x,{itemColor:l,itemHoverColor:m,groupTitleColor:g,itemSelectedColor:f,subMenuItemSelectedColor:f,itemBg:u,popupBg:k,subMenuItemBg:c,itemActiveBg:"transparent",itemSelectedBg:p,activeBarHeight:0,activeBarBorderWidth:0,itemHoverBg:v,itemDisabledColor:b,dangerItemColor:s,dangerItemHoverColor:y,dangerItemSelectedColor:C,dangerItemActiveBg:D,dangerItemSelectedBg:h,menuSubMenuBg:c,horizontalItemSelectedColor:f,horizontalItemSelectedBg:p});return[m4(x),d4(x),p4(x),B0(x,"light"),B0(O,"dark"),f4(x),kC(x),Ua(x,"slide-up"),Ua(x,"slide-down"),Yp(x,"zoom-big")]},h4,{deprecatedTokens:[["colorGroupTitle","groupTitleColor"],["radiusItem","itemBorderRadius"],["radiusSubMenuItem","subMenuItemBorderRadius"],["colorItemText","itemColor"],["colorItemTextHover","itemHoverColor"],["colorItemTextHoverHorizontal","horizontalItemHoverColor"],["colorItemTextSelected","itemSelectedColor"],["colorItemTextSelectedHorizontal","horizontalItemSelectedColor"],["colorItemTextDisabled","itemDisabledColor"],["colorDangerItemText","dangerItemColor"],["colorDangerItemTextHover","dangerItemHoverColor"],["colorDangerItemTextSelected","dangerItemSelectedColor"],["colorDangerItemBgActive","dangerItemActiveBg"],["colorDangerItemBgSelected","dangerItemSelectedBg"],["colorItemBg","itemBg"],["colorItemBgHover","itemHoverBg"],["colorSubItemBg","subMenuItemBg"],["colorItemBgActive","itemActiveBg"],["colorItemBgSelectedHorizontal","horizontalItemSelectedBg"],["colorActiveBarWidth","activeBarWidth"],["colorActiveBarHeight","activeBarHeight"],["colorActiveBarBorderSize","activeBarBorderWidth"],["colorItemBgSelected","itemSelectedBg"]],injectStyle:r,unitless:{groupTitleLineHeight:!0}})(e,t),Mx=e=>{var t;const{popupClassName:r,icon:n,title:o,theme:a}=e,i=d.useContext(Ys),{prefixCls:l,inlineCollapsed:s,theme:u}=i,c=si();let f;if(!n)f=s&&!c.length&&o&&typeof o=="string"?d.createElement("div",{className:`${l}-inline-collapsed-noicon`},o.charAt(0)):d.createElement("span",{className:`${l}-title-content`},o);else{const v=d.isValidElement(o)&&o.type==="span";f=d.createElement(d.Fragment,null,eo(n,{className:pe(d.isValidElement(n)?(t=n.props)===null||t===void 0?void 0:t.className:void 0,`${l}-item-icon`)}),v?o:d.createElement("span",{className:`${l}-title-content`},o))}const p=d.useMemo(()=>Object.assign(Object.assign({},i),{firstLevel:!1}),[i]),[h]=wu("Menu");return d.createElement(Ys.Provider,{value:p},d.createElement(zu,Object.assign({},fn(e,["icon"]),{title:f,popupClassName:pe(l,r,`${l}-${a||u}`),popupStyle:Object.assign({zIndex:h},e.popupStyle)})))};var v4=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};function Jc(e){return e===null||e===!1}const b4={item:Ix,submenu:Mx,divider:jx},y4=dn((e,t)=>{var r;const n=d.useContext(Zs),o=n||{},{getPrefixCls:a,getPopupContainer:i,direction:l,menu:s}=d.useContext(Zt),u=a(),{prefixCls:c,className:f,style:p,theme:h="light",expandIcon:v,_internalDisableMenuItemTitleTooltip:g,inlineCollapsed:m,siderCollapsed:b,rootClassName:y,mode:C,selectable:D,onClick:w,overflowedIndicatorPopupClassName:k}=e,E=v4(e,["prefixCls","className","style","theme","expandIcon","_internalDisableMenuItemTitleTooltip","inlineCollapsed","siderCollapsed","rootClassName","mode","selectable","onClick","overflowedIndicatorPopupClassName"]),x=fn(E,["collapsedWidth"]);(r=o.validator)===null||r===void 0||r.call(o,{mode:C});const O=nr((...H)=>{var q;w==null||w.apply(void 0,H),(q=o.onClick)===null||q===void 0||q.call(o)}),j=o.mode||C,$=D??o.selectable,P=m??b,A={horizontal:{motionName:`${u}-slide-up`},inline:yC(u),other:{motionName:`${u}-zoom-big`}},B=a("menu",c||o.prefixCls),S=bo(B),[I,N,F]=g4(B,S,!n),M=pe(`${B}-${h}`,s==null?void 0:s.className,f),_=d.useMemo(()=>{var H,q;if(typeof v=="function"||Jc(v))return v||null;if(typeof o.expandIcon=="function"||Jc(o.expandIcon))return o.expandIcon||null;if(typeof(s==null?void 0:s.expandIcon)=="function"||Jc(s==null?void 0:s.expandIcon))return(s==null?void 0:s.expandIcon)||null;const Z=(H=v??(o==null?void 0:o.expandIcon))!==null&&H!==void 0?H:s==null?void 0:s.expandIcon;return eo(Z,{className:pe(`${B}-submenu-expand-icon`,d.isValidElement(Z)?(q=Z.props)===null||q===void 0?void 0:q.className:void 0)})},[v,o==null?void 0:o.expandIcon,s==null?void 0:s.expandIcon,B]),X=d.useMemo(()=>({prefixCls:B,inlineCollapsed:P||!1,direction:l,firstLevel:!0,theme:h,mode:j,disableMenuItemTitleTooltip:g}),[B,P,l,g,h]);return I(d.createElement(Zs.Provider,{value:null},d.createElement(Ys.Provider,{value:X},d.createElement(Sl,Object.assign({getPopupContainer:i,overflowedIndicator:d.createElement(Px,null),overflowedIndicatorPopupClassName:pe(B,`${B}-${h}`,k),mode:j,selectable:$,onClick:O},x,{inlineCollapsed:P,style:Object.assign(Object.assign({},s==null?void 0:s.style),p),className:M,prefixCls:B,direction:l,defaultMotions:A,expandIcon:_,ref:t,rootClassName:pe(y,N,o.rootClassName,F,S),_internalComponents:b4})))))}),ui=dn((e,t)=>{const r=qe(null),n=d.useContext(Nx);return ei(t,()=>({menu:r.current,focus:o=>{var a;(a=r.current)===null||a===void 0||a.focus(o)}})),d.createElement(y4,Object.assign({ref:r},e,n))});ui.Item=Ix;ui.SubMenu=Mx;ui.Divider=jx;ui.ItemGroup=fm;const C4=e=>{const{componentCls:t,menuCls:r,colorError:n,colorTextLightSolid:o}=e,a=`${r}-item`;return{[`${t}, ${t}-menu-submenu`]:{[`${r} ${a}`]:{[`&${a}-danger:not(${a}-disabled)`]:{color:n,"&:hover":{color:o,backgroundColor:n}}}}}},x4=e=>{const{componentCls:t,menuCls:r,zIndexPopup:n,dropdownArrowDistance:o,sizePopupArrow:a,antCls:i,iconCls:l,motionDurationMid:s,paddingBlock:u,fontSize:c,dropdownEdgeChildPadding:f,colorTextDisabled:p,fontSizeIcon:h,controlPaddingHorizontal:v,colorBgElevated:g}=e;return[{[t]:{position:"absolute",top:-9999,left:{_skip_check_:!0,value:-9999},zIndex:n,display:"block","&::before":{position:"absolute",insetBlock:e.calc(a).div(2).sub(o).equal(),zIndex:-9999,opacity:1e-4,content:'""'},"&-menu-vertical":{maxHeight:"100vh",overflowY:"auto"},[`&-trigger${i}-btn`]:{[`& > ${l}-down, & > ${i}-btn-icon > ${l}-down`]:{fontSize:h}},[`${t}-wrap`]:{position:"relative",[`${i}-btn > ${l}-down`]:{fontSize:h},[`${l}-down::before`]:{transition:`transform ${s}`}},[`${t}-wrap-open`]:{[`${l}-down::before`]:{transform:"rotate(180deg)"}},"\n &-hidden,\n &-menu-hidden,\n &-menu-submenu-hidden\n ":{display:"none"},[`&${i}-slide-down-enter${i}-slide-down-enter-active${t}-placement-bottomLeft,
|
|
339
|
+
&${i}-slide-down-appear${i}-slide-down-appear-active${t}-placement-bottomLeft,
|
|
340
|
+
&${i}-slide-down-enter${i}-slide-down-enter-active${t}-placement-bottom,
|
|
341
|
+
&${i}-slide-down-appear${i}-slide-down-appear-active${t}-placement-bottom,
|
|
342
|
+
&${i}-slide-down-enter${i}-slide-down-enter-active${t}-placement-bottomRight,
|
|
343
|
+
&${i}-slide-down-appear${i}-slide-down-appear-active${t}-placement-bottomRight`]:{animationName:Vp},[`&${i}-slide-up-enter${i}-slide-up-enter-active${t}-placement-topLeft,
|
|
344
|
+
&${i}-slide-up-appear${i}-slide-up-appear-active${t}-placement-topLeft,
|
|
345
|
+
&${i}-slide-up-enter${i}-slide-up-enter-active${t}-placement-top,
|
|
346
|
+
&${i}-slide-up-appear${i}-slide-up-appear-active${t}-placement-top,
|
|
347
|
+
&${i}-slide-up-enter${i}-slide-up-enter-active${t}-placement-topRight,
|
|
348
|
+
&${i}-slide-up-appear${i}-slide-up-appear-active${t}-placement-topRight`]:{animationName:Xp},[`&${i}-slide-down-leave${i}-slide-down-leave-active${t}-placement-bottomLeft,
|
|
349
|
+
&${i}-slide-down-leave${i}-slide-down-leave-active${t}-placement-bottom,
|
|
350
|
+
&${i}-slide-down-leave${i}-slide-down-leave-active${t}-placement-bottomRight`]:{animationName:Gp},[`&${i}-slide-up-leave${i}-slide-up-leave-active${t}-placement-topLeft,
|
|
351
|
+
&${i}-slide-up-leave${i}-slide-up-leave-active${t}-placement-top,
|
|
352
|
+
&${i}-slide-up-leave${i}-slide-up-leave-active${t}-placement-topRight`]:{animationName:Up}}},hx(e,g,{arrowPlacement:{top:!0,bottom:!0}}),{[`${t} ${r}`]:{position:"relative",margin:0},[`${r}-submenu-popup`]:{position:"absolute",zIndex:n,background:"transparent",boxShadow:"none",transformOrigin:"0 0","ul, li":{listStyle:"none",margin:0}},[`${t}, ${t}-menu-submenu`]:Object.assign(Object.assign({},Br(e)),{[r]:Object.assign(Object.assign({padding:f,listStyleType:"none",backgroundColor:g,backgroundClip:"padding-box",borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary},cl(e)),{"&:empty":{padding:0,boxShadow:"none"},[`${r}-item-group-title`]:{padding:`${ue(u)} ${ue(v)}`,color:e.colorTextDescription,transition:`all ${s}`},[`${r}-item`]:{position:"relative",display:"flex",alignItems:"center"},[`${r}-item-icon`]:{minWidth:c,marginInlineEnd:e.marginXS,fontSize:e.fontSizeSM},[`${r}-title-content`]:{flex:"auto","&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},"> a":{color:"inherit",transition:`all ${s}`,"&:hover":{color:"inherit"},"&::after":{position:"absolute",inset:0,content:'""'}},[`${r}-item-extra`]:{paddingInlineStart:e.padding,marginInlineStart:"auto",fontSize:e.fontSizeSM,color:e.colorTextDescription}},[`${r}-item, ${r}-submenu-title`]:Object.assign(Object.assign({display:"flex",margin:0,padding:`${ue(u)} ${ue(v)}`,color:e.colorText,fontWeight:"normal",fontSize:c,lineHeight:e.lineHeight,cursor:"pointer",transition:`all ${s}`,borderRadius:e.borderRadiusSM,"&:hover, &-active":{backgroundColor:e.controlItemBgHover}},cl(e)),{"&-selected":{color:e.colorPrimary,backgroundColor:e.controlItemBgActive,"&:hover, &-active":{backgroundColor:e.controlItemBgActiveHover}},"&-disabled":{color:p,cursor:"not-allowed","&:hover":{color:p,backgroundColor:g,cursor:"not-allowed"},a:{pointerEvents:"none"}},"&-divider":{height:1,margin:`${ue(e.marginXXS)} 0`,overflow:"hidden",lineHeight:0,backgroundColor:e.colorSplit},[`${t}-menu-submenu-expand-icon`]:{position:"absolute",insetInlineEnd:e.paddingXS,[`${t}-menu-submenu-arrow-icon`]:{marginInlineEnd:"0 !important",color:e.colorIcon,fontSize:h,fontStyle:"normal"}}}),[`${r}-item-group-list`]:{margin:`0 ${ue(e.marginXS)}`,padding:0,listStyle:"none"},[`${r}-submenu-title`]:{paddingInlineEnd:e.calc(v).add(e.fontSizeSM).equal()},[`${r}-submenu-vertical`]:{position:"relative"},[`${r}-submenu${r}-submenu-disabled ${t}-menu-submenu-title`]:{[`&, ${t}-menu-submenu-arrow-icon`]:{color:p,backgroundColor:g,cursor:"not-allowed"}},[`${r}-submenu-selected ${t}-menu-submenu-title`]:{color:e.colorPrimary}})})},[Ua(e,"slide-up"),Ua(e,"slide-down"),Vs(e,"move-up"),Vs(e,"move-down"),Yp(e,"zoom-big")]]},w4=e=>Object.assign(Object.assign({zIndexPopup:e.zIndexPopupBase+50,paddingBlock:(e.controlHeight-e.fontSize*e.lineHeight)/2},am({contentRadius:e.borderRadiusLG,limitVerticalRadius:!0})),px(e)),E4=Hr("Dropdown",e=>{const{marginXXS:t,sizePopupArrow:r,paddingXXS:n,componentCls:o}=e,a=er(e,{menuCls:`${o}-menu`,dropdownArrowDistance:e.calc(r).div(2).add(t).equal(),dropdownEdgeChildPadding:n});return[x4(a),C4(a)]},w4,{resetStyle:!1}),_u=e=>{var t;const{menu:r,arrow:n,prefixCls:o,children:a,trigger:i,disabled:l,dropdownRender:s,popupRender:u,getPopupContainer:c,overlayClassName:f,rootClassName:p,overlayStyle:h,open:v,onOpenChange:g,visible:m,onVisibleChange:b,mouseEnterDelay:y=.15,mouseLeaveDelay:C=.1,autoAdjustOverflow:D=!0,placement:w="",overlay:k,transitionName:E,destroyOnHidden:x,destroyPopupOnHide:O}=e,{getPopupContainer:j,getPrefixCls:$,direction:P,dropdown:A}=d.useContext(Zt),B=u||s;oi();const S=d.useMemo(()=>{const ge=$();return E!==void 0?E:w.includes("top")?`${ge}-slide-down`:`${ge}-slide-up`},[$,w,E]),I=d.useMemo(()=>w?w.includes("Center")?w.slice(0,w.indexOf("Center")):w:P==="rtl"?"bottomRight":"bottomLeft",[w,P]),N=$("dropdown",o),F=bo(N),[M,_,X]=E4(N,F),[,H]=Yr(),q=d.Children.only(EI(a)?d.createElement("span",null,a):a),Z=eo(q,{className:pe(`${N}-trigger`,{[`${N}-rtl`]:P==="rtl"},q.props.className),disabled:(t=q.props.disabled)!==null&&t!==void 0?t:l}),te=l?[]:i,z=!!(te!=null&&te.includes("contextMenu")),[Y,V]=Gr(!1,{value:v??m}),U=nr(ge=>{g==null||g(ge,{source:"trigger"}),b==null||b(ge),V(ge)}),K=pe(f,p,_,X,F,A==null?void 0:A.className,{[`${N}-rtl`]:P==="rtl"}),W=gx({arrowPointAtCenter:typeof n=="object"&&n.pointAtCenter,autoAdjustOverflow:D,offset:H.marginXXS,arrowWidth:n?H.sizePopupArrow:0,borderRadius:H.borderRadius}),re=d.useCallback(()=>{r!=null&&r.selectable&&(r!=null&&r.multiple)||(g==null||g(!1,{source:"menu"}),V(!1))},[r==null?void 0:r.selectable,r==null?void 0:r.multiple]),G=()=>{let ge;return r!=null&&r.items?ge=d.createElement(ui,Object.assign({},r)):typeof k=="function"?ge=k():ge=k,B&&(ge=B(ge)),ge=d.Children.only(typeof ge=="string"?d.createElement("span",null,ge):ge),d.createElement(Rx,{prefixCls:`${N}-menu`,rootClassName:pe(X,F),expandIcon:d.createElement("span",{className:`${N}-menu-submenu-arrow`},P==="rtl"?d.createElement(If,{className:`${N}-menu-submenu-arrow-icon`}):d.createElement(vf,{className:`${N}-menu-submenu-arrow-icon`})),mode:"vertical",selectable:!1,onClick:re,validator:({mode:Ee})=>{}},ge)},[J,oe]=wu("Dropdown",h==null?void 0:h.zIndex);let se=d.createElement(wI,Object.assign({alignPoint:z},fn(e,["rootClassName"]),{mouseEnterDelay:y,mouseLeaveDelay:C,visible:Y,builtinPlacements:W,arrow:!!n,overlayClassName:K,prefixCls:N,getPopupContainer:c||j,transitionName:S,trigger:te,overlay:G,placement:I,onVisibleChange:U,overlayStyle:Object.assign(Object.assign(Object.assign({},A==null?void 0:A.style),h),{zIndex:J}),autoDestroy:x??O}),Z);return J&&(se=d.createElement(Hp.Provider,{value:oe},se)),M(se)},k4=zC(_u,"align",void 0,"dropdown",e=>e),D4=e=>d.createElement(k4,Object.assign({},e),d.createElement("span",null));_u._InternalPanelDoNotUseOrYouWillBeFired=D4;var Hf={exports:{}},S4=Hf.exports,N0;function $4(){return N0||(N0=1,(function(e,t){(function(r,n){e.exports=n()})(S4,(function(){var r=1e3,n=6e4,o=36e5,a="millisecond",i="second",l="minute",s="hour",u="day",c="week",f="month",p="quarter",h="year",v="date",g="Invalid Date",m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,b=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(B){var S=["th","st","nd","rd"],I=B%100;return"["+B+(S[(I-20)%10]||S[I]||S[0])+"]"}},C=function(B,S,I){var N=String(B);return!N||N.length>=S?B:""+Array(S+1-N.length).join(I)+B},D={s:C,z:function(B){var S=-B.utcOffset(),I=Math.abs(S),N=Math.floor(I/60),F=I%60;return(S<=0?"+":"-")+C(N,2,"0")+":"+C(F,2,"0")},m:function B(S,I){if(S.date()<I.date())return-B(I,S);var N=12*(I.year()-S.year())+(I.month()-S.month()),F=S.clone().add(N,f),M=I-F<0,_=S.clone().add(N+(M?-1:1),f);return+(-(N+(I-F)/(M?F-_:_-F))||0)},a:function(B){return B<0?Math.ceil(B)||0:Math.floor(B)},p:function(B){return{M:f,y:h,w:c,d:u,D:v,h:s,m:l,s:i,ms:a,Q:p}[B]||String(B||"").toLowerCase().replace(/s$/,"")},u:function(B){return B===void 0}},w="en",k={};k[w]=y;var E="$isDayjsObject",x=function(B){return B instanceof P||!(!B||!B[E])},O=function B(S,I,N){var F;if(!S)return w;if(typeof S=="string"){var M=S.toLowerCase();k[M]&&(F=M),I&&(k[M]=I,F=M);var _=S.split("-");if(!F&&_.length>1)return B(_[0])}else{var X=S.name;k[X]=S,F=X}return!N&&F&&(w=F),F||!N&&w},j=function(B,S){if(x(B))return B.clone();var I=typeof S=="object"?S:{};return I.date=B,I.args=arguments,new P(I)},$=D;$.l=O,$.i=x,$.w=function(B,S){return j(B,{locale:S.$L,utc:S.$u,x:S.$x,$offset:S.$offset})};var P=(function(){function B(I){this.$L=O(I.locale,null,!0),this.parse(I),this.$x=this.$x||I.x||{},this[E]=!0}var S=B.prototype;return S.parse=function(I){this.$d=(function(N){var F=N.date,M=N.utc;if(F===null)return new Date(NaN);if($.u(F))return new Date;if(F instanceof Date)return new Date(F);if(typeof F=="string"&&!/Z$/i.test(F)){var _=F.match(m);if(_){var X=_[2]-1||0,H=(_[7]||"0").substring(0,3);return M?new Date(Date.UTC(_[1],X,_[3]||1,_[4]||0,_[5]||0,_[6]||0,H)):new Date(_[1],X,_[3]||1,_[4]||0,_[5]||0,_[6]||0,H)}}return new Date(F)})(I),this.init()},S.init=function(){var I=this.$d;this.$y=I.getFullYear(),this.$M=I.getMonth(),this.$D=I.getDate(),this.$W=I.getDay(),this.$H=I.getHours(),this.$m=I.getMinutes(),this.$s=I.getSeconds(),this.$ms=I.getMilliseconds()},S.$utils=function(){return $},S.isValid=function(){return this.$d.toString()!==g},S.isSame=function(I,N){var F=j(I);return this.startOf(N)<=F&&F<=this.endOf(N)},S.isAfter=function(I,N){return j(I)<this.startOf(N)},S.isBefore=function(I,N){return this.endOf(N)<j(I)},S.$g=function(I,N,F){return $.u(I)?this[N]:this.set(F,I)},S.unix=function(){return Math.floor(this.valueOf()/1e3)},S.valueOf=function(){return this.$d.getTime()},S.startOf=function(I,N){var F=this,M=!!$.u(N)||N,_=$.p(I),X=function(U,K){var W=$.w(F.$u?Date.UTC(F.$y,K,U):new Date(F.$y,K,U),F);return M?W:W.endOf(u)},H=function(U,K){return $.w(F.toDate()[U].apply(F.toDate("s"),(M?[0,0,0,0]:[23,59,59,999]).slice(K)),F)},q=this.$W,Z=this.$M,te=this.$D,z="set"+(this.$u?"UTC":"");switch(_){case h:return M?X(1,0):X(31,11);case f:return M?X(1,Z):X(0,Z+1);case c:var Y=this.$locale().weekStart||0,V=(q<Y?q+7:q)-Y;return X(M?te-V:te+(6-V),Z);case u:case v:return H(z+"Hours",0);case s:return H(z+"Minutes",1);case l:return H(z+"Seconds",2);case i:return H(z+"Milliseconds",3);default:return this.clone()}},S.endOf=function(I){return this.startOf(I,!1)},S.$set=function(I,N){var F,M=$.p(I),_="set"+(this.$u?"UTC":""),X=(F={},F[u]=_+"Date",F[v]=_+"Date",F[f]=_+"Month",F[h]=_+"FullYear",F[s]=_+"Hours",F[l]=_+"Minutes",F[i]=_+"Seconds",F[a]=_+"Milliseconds",F)[M],H=M===u?this.$D+(N-this.$W):N;if(M===f||M===h){var q=this.clone().set(v,1);q.$d[X](H),q.init(),this.$d=q.set(v,Math.min(this.$D,q.daysInMonth())).$d}else X&&this.$d[X](H);return this.init(),this},S.set=function(I,N){return this.clone().$set(I,N)},S.get=function(I){return this[$.p(I)]()},S.add=function(I,N){var F,M=this;I=Number(I);var _=$.p(N),X=function(Z){var te=j(M);return $.w(te.date(te.date()+Math.round(Z*I)),M)};if(_===f)return this.set(f,this.$M+I);if(_===h)return this.set(h,this.$y+I);if(_===u)return X(1);if(_===c)return X(7);var H=(F={},F[l]=n,F[s]=o,F[i]=r,F)[_]||1,q=this.$d.getTime()+I*H;return $.w(q,this)},S.subtract=function(I,N){return this.add(-1*I,N)},S.format=function(I){var N=this,F=this.$locale();if(!this.isValid())return F.invalidDate||g;var M=I||"YYYY-MM-DDTHH:mm:ssZ",_=$.z(this),X=this.$H,H=this.$m,q=this.$M,Z=F.weekdays,te=F.months,z=F.meridiem,Y=function(K,W,re,G){return K&&(K[W]||K(N,M))||re[W].slice(0,G)},V=function(K){return $.s(X%12||12,K,"0")},U=z||function(K,W,re){var G=K<12?"AM":"PM";return re?G.toLowerCase():G};return M.replace(b,(function(K,W){return W||(function(re){switch(re){case"YY":return String(N.$y).slice(-2);case"YYYY":return $.s(N.$y,4,"0");case"M":return q+1;case"MM":return $.s(q+1,2,"0");case"MMM":return Y(F.monthsShort,q,te,3);case"MMMM":return Y(te,q);case"D":return N.$D;case"DD":return $.s(N.$D,2,"0");case"d":return String(N.$W);case"dd":return Y(F.weekdaysMin,N.$W,Z,2);case"ddd":return Y(F.weekdaysShort,N.$W,Z,3);case"dddd":return Z[N.$W];case"H":return String(X);case"HH":return $.s(X,2,"0");case"h":return V(1);case"hh":return V(2);case"a":return U(X,H,!0);case"A":return U(X,H,!1);case"m":return String(H);case"mm":return $.s(H,2,"0");case"s":return String(N.$s);case"ss":return $.s(N.$s,2,"0");case"SSS":return $.s(N.$ms,3,"0");case"Z":return _}return null})(K)||_.replace(":","")}))},S.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},S.diff=function(I,N,F){var M,_=this,X=$.p(N),H=j(I),q=(H.utcOffset()-this.utcOffset())*n,Z=this-H,te=function(){return $.m(_,H)};switch(X){case h:M=te()/12;break;case f:M=te();break;case p:M=te()/3;break;case c:M=(Z-q)/6048e5;break;case u:M=(Z-q)/864e5;break;case s:M=Z/o;break;case l:M=Z/n;break;case i:M=Z/r;break;default:M=Z}return F?M:$.a(M)},S.daysInMonth=function(){return this.endOf(f).$D},S.$locale=function(){return k[this.$L]},S.locale=function(I,N){if(!I)return this.$L;var F=this.clone(),M=O(I,N,!0);return M&&(F.$L=M),F},S.clone=function(){return $.w(this.$d,this)},S.toDate=function(){return new Date(this.valueOf())},S.toJSON=function(){return this.isValid()?this.toISOString():null},S.toISOString=function(){return this.$d.toISOString()},S.toString=function(){return this.$d.toUTCString()},B})(),A=P.prototype;return j.prototype=A,[["$ms",a],["$s",i],["$m",l],["$H",s],["$W",u],["$M",f],["$y",h],["$D",v]].forEach((function(B){A[B[1]]=function(S){return this.$g(S,B[0],B[1])}})),j.extend=function(B,S){return B.$i||(B(S,P,j),B.$i=!0),j},j.locale=O,j.isDayjs=x,j.unix=function(B){return j(1e3*B)},j.en=k[w],j.Ls=k,j.p={},j}))})(Hf)),Hf.exports}var B4=$4();const O4=vl(B4),Tx=d.createContext(null),A4=Tx.Provider,zx=d.createContext(null),F4=zx.Provider;var N4=["prefixCls","className","style","checked","disabled","defaultChecked","type","title","onChange"],_x=dn(function(e,t){var r=e.prefixCls,n=r===void 0?"rc-checkbox":r,o=e.className,a=e.style,i=e.checked,l=e.disabled,s=e.defaultChecked,u=s===void 0?!1:s,c=e.type,f=c===void 0?"checkbox":c,p=e.title,h=e.onChange,v=bt(e,N4),g=qe(null),m=qe(null),b=Gr(u,{value:i}),y=ce(b,2),C=y[0],D=y[1];ei(t,function(){return{focus:function(E){var x;(x=g.current)===null||x===void 0||x.focus(E)},blur:function(){var E;(E=g.current)===null||E===void 0||E.blur()},input:g.current,nativeElement:m.current}});var w=pe(n,o,T(T({},"".concat(n,"-checked"),C),"".concat(n,"-disabled"),l)),k=function(E){l||("checked"in e||D(E.target.checked),h==null||h({target:L(L({},e),{},{type:f,checked:E.target.checked}),stopPropagation:function(){E.stopPropagation()},preventDefault:function(){E.preventDefault()},nativeEvent:E.nativeEvent}))};return d.createElement("span",{className:w,title:p,style:a,ref:m},d.createElement("input",Me({},v,{className:"".concat(n,"-input"),ref:g,onChange:k,disabled:l,checked:!!C,type:f})),d.createElement("span",{className:"".concat(n,"-inner")}))});function Lx(e){const t=ee.useRef(null),r=()=>{qt.cancel(t.current),t.current=null};return[()=>{r(),t.current=qt(()=>{t.current=null})},n=>{t.current&&(n.stopPropagation(),r()),e==null||e(n)}]}const P4=e=>{const{componentCls:t,antCls:r}=e,n=`${t}-group`;return{[n]:Object.assign(Object.assign({},Br(e)),{display:"inline-block",fontSize:0,[`&${n}-rtl`]:{direction:"rtl"},[`&${n}-block`]:{display:"flex"},[`${r}-badge ${r}-badge-count`]:{zIndex:1},[`> ${r}-badge:not(:first-child) > ${r}-button-wrapper`]:{borderInlineStart:"none"}})}},j4=e=>{const{componentCls:t,wrapperMarginInlineEnd:r,colorPrimary:n,radioSize:o,motionDurationSlow:a,motionDurationMid:i,motionEaseInOutCirc:l,colorBgContainer:s,colorBorder:u,lineWidth:c,colorBgContainerDisabled:f,colorTextDisabled:p,paddingXS:h,dotColorDisabled:v,lineType:g,radioColor:m,radioBgColor:b,calc:y}=e,C=`${t}-inner`,D=y(o).sub(y(4).mul(2)),w=y(1).mul(o).equal({unit:!0});return{[`${t}-wrapper`]:Object.assign(Object.assign({},Br(e)),{display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:r,cursor:"pointer","&:last-child":{marginInlineEnd:0},[`&${t}-wrapper-rtl`]:{direction:"rtl"},"&-disabled":{cursor:"not-allowed",color:e.colorTextDisabled},"&::after":{display:"inline-block",width:0,overflow:"hidden",content:'"\\a0"'},"&-block":{flex:1,justifyContent:"center"},[`${t}-checked::after`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:"100%",height:"100%",border:`${ue(c)} ${g} ${n}`,borderRadius:"50%",visibility:"hidden",opacity:0,content:'""'},[t]:Object.assign(Object.assign({},Br(e)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center",borderRadius:"50%"}),[`${t}-wrapper:hover &,
|
|
353
|
+
&:hover ${C}`]:{borderColor:n},[`${t}-input:focus-visible + ${C}`]:Po(e),[`${t}:hover::after, ${t}-wrapper:hover &::after`]:{visibility:"visible"},[`${t}-inner`]:{"&::after":{boxSizing:"border-box",position:"absolute",insetBlockStart:"50%",insetInlineStart:"50%",display:"block",width:w,height:w,marginBlockStart:y(1).mul(o).div(-2).equal({unit:!0}),marginInlineStart:y(1).mul(o).div(-2).equal({unit:!0}),backgroundColor:m,borderBlockStart:0,borderInlineStart:0,borderRadius:w,transform:"scale(0)",opacity:0,transition:`all ${a} ${l}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:w,height:w,backgroundColor:s,borderColor:u,borderStyle:"solid",borderWidth:c,borderRadius:"50%",transition:`all ${i}`},[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0},[`${t}-checked`]:{[C]:{borderColor:n,backgroundColor:b,"&::after":{transform:`scale(${e.calc(e.dotSize).div(o).equal()})`,opacity:1,transition:`all ${a} ${l}`}}},[`${t}-disabled`]:{cursor:"not-allowed",[C]:{backgroundColor:f,borderColor:u,cursor:"not-allowed","&::after":{backgroundColor:v}},[`${t}-input`]:{cursor:"not-allowed"},[`${t}-disabled + span`]:{color:p,cursor:"not-allowed"},[`&${t}-checked`]:{[C]:{"&::after":{transform:`scale(${y(D).div(o).equal()})`}}}},[`span${t} + *`]:{paddingInlineStart:h,paddingInlineEnd:h}})}},I4=e=>{const{buttonColor:t,controlHeight:r,componentCls:n,lineWidth:o,lineType:a,colorBorder:i,motionDurationSlow:l,motionDurationMid:s,buttonPaddingInline:u,fontSize:c,buttonBg:f,fontSizeLG:p,controlHeightLG:h,controlHeightSM:v,paddingXS:g,borderRadius:m,borderRadiusSM:b,borderRadiusLG:y,buttonCheckedBg:C,buttonSolidCheckedColor:D,colorTextDisabled:w,colorBgContainerDisabled:k,buttonCheckedBgDisabled:E,buttonCheckedColorDisabled:x,colorPrimary:O,colorPrimaryHover:j,colorPrimaryActive:$,buttonSolidCheckedBg:P,buttonSolidCheckedHoverBg:A,buttonSolidCheckedActiveBg:B,calc:S}=e;return{[`${n}-button-wrapper`]:{position:"relative",display:"inline-block",height:r,margin:0,paddingInline:u,paddingBlock:0,color:t,fontSize:c,lineHeight:ue(S(r).sub(S(o).mul(2)).equal()),background:f,border:`${ue(o)} ${a} ${i}`,borderBlockStartWidth:S(o).add(.02).equal(),borderInlineStartWidth:0,borderInlineEndWidth:o,cursor:"pointer",transition:[`color ${s}`,`background ${s}`,`box-shadow ${s}`].join(","),a:{color:t},[`> ${n}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:first-child)":{"&::before":{position:"absolute",insetBlockStart:S(o).mul(-1).equal(),insetInlineStart:S(o).mul(-1).equal(),display:"block",boxSizing:"content-box",width:1,height:"100%",paddingBlock:o,paddingInline:0,backgroundColor:i,transition:`background-color ${l}`,content:'""'}},"&:first-child":{borderInlineStart:`${ue(o)} ${a} ${i}`,borderStartStartRadius:m,borderEndStartRadius:m},"&:last-child":{borderStartEndRadius:m,borderEndEndRadius:m},"&:first-child:last-child":{borderRadius:m},[`${n}-group-large &`]:{height:h,fontSize:p,lineHeight:ue(S(h).sub(S(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:y,borderEndStartRadius:y},"&:last-child":{borderStartEndRadius:y,borderEndEndRadius:y}},[`${n}-group-small &`]:{height:v,paddingInline:S(g).sub(o).equal(),paddingBlock:0,lineHeight:ue(S(v).sub(S(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:b,borderEndStartRadius:b},"&:last-child":{borderStartEndRadius:b,borderEndEndRadius:b}},"&:hover":{position:"relative",color:O},"&:has(:focus-visible)":Po(e),[`${n}-inner, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${n}-button-wrapper-disabled)`]:{zIndex:1,color:O,background:C,borderColor:O,"&::before":{backgroundColor:O},"&:first-child":{borderColor:O},"&:hover":{color:j,borderColor:j,"&::before":{backgroundColor:j}},"&:active":{color:$,borderColor:$,"&::before":{backgroundColor:$}}},[`${n}-group-solid &-checked:not(${n}-button-wrapper-disabled)`]:{color:D,background:P,borderColor:P,"&:hover":{color:D,background:A,borderColor:A},"&:active":{color:D,background:B,borderColor:B}},"&-disabled":{color:w,backgroundColor:k,borderColor:i,cursor:"not-allowed","&:first-child, &:hover":{color:w,backgroundColor:k,borderColor:i}},[`&-disabled${n}-button-wrapper-checked`]:{color:x,backgroundColor:E,borderColor:i,boxShadow:"none"},"&-block":{flex:1,textAlign:"center"}}}},R4=e=>{const{wireframe:t,padding:r,marginXS:n,lineWidth:o,fontSizeLG:a,colorText:i,colorBgContainer:l,colorTextDisabled:s,controlItemBgActiveDisabled:u,colorTextLightSolid:c,colorPrimary:f,colorPrimaryHover:p,colorPrimaryActive:h,colorWhite:v}=e,g=4,m=a,b=t?m-g*2:m-(g+o)*2;return{radioSize:m,dotSize:b,dotColorDisabled:s,buttonSolidCheckedColor:c,buttonSolidCheckedBg:f,buttonSolidCheckedHoverBg:p,buttonSolidCheckedActiveBg:h,buttonBg:l,buttonCheckedBg:l,buttonColor:i,buttonCheckedBgDisabled:u,buttonCheckedColorDisabled:s,buttonPaddingInline:r-o,wrapperMarginInlineEnd:n,radioColor:t?f:v,radioBgColor:t?l:f}},Hx=Hr("Radio",e=>{const{controlOutline:t,controlOutlineWidth:r}=e,n=`0 0 0 ${ue(r)} ${t}`,o=er(e,{radioFocusShadow:n,radioButtonFocusShadow:n});return[P4(o),j4(o),I4(o)]},R4,{unitless:{radioSize:!0,dotSize:!0}});var M4=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const T4=(e,t)=>{var r,n;const o=d.useContext(Tx),a=d.useContext(zx),{getPrefixCls:i,direction:l,radio:s}=d.useContext(Zt),u=d.useRef(null),c=ro(t,u),{isFormItemInput:f}=d.useContext(oa),p=I=>{var N,F;(N=e.onChange)===null||N===void 0||N.call(e,I),(F=o==null?void 0:o.onChange)===null||F===void 0||F.call(o,I)},{prefixCls:h,className:v,rootClassName:g,children:m,style:b,title:y}=e,C=M4(e,["prefixCls","className","rootClassName","children","style","title"]),D=i("radio",h),w=((o==null?void 0:o.optionType)||a)==="button",k=w?`${D}-button`:D,E=bo(D),[x,O,j]=Hx(D,E),$=Object.assign({},C),P=d.useContext(No);o&&($.name=o.name,$.onChange=p,$.checked=e.value===o.value,$.disabled=(r=$.disabled)!==null&&r!==void 0?r:o.disabled),$.disabled=(n=$.disabled)!==null&&n!==void 0?n:P;const A=pe(`${k}-wrapper`,{[`${k}-wrapper-checked`]:$.checked,[`${k}-wrapper-disabled`]:$.disabled,[`${k}-wrapper-rtl`]:l==="rtl",[`${k}-wrapper-in-form-item`]:f,[`${k}-wrapper-block`]:!!(o!=null&&o.block)},s==null?void 0:s.className,v,g,O,j,E),[B,S]=Lx($.onClick);return x(d.createElement(Kp,{component:"Radio",disabled:$.disabled},d.createElement("label",{className:A,style:Object.assign(Object.assign({},s==null?void 0:s.style),b),onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,title:y,onClick:B},d.createElement(_x,Object.assign({},$,{className:pe($.className,{[Du]:!w}),type:"radio",prefixCls:k,ref:c,onClick:S})),m!==void 0?d.createElement("span",{className:`${k}-label`},m):null)))},Js=d.forwardRef(T4);function z4(e){return e===void 0||e===!1?[]:Array.isArray(e)?e:[e]}function _4(e){return z4(e).join("_")}const L4=d.forwardRef((e,t)=>{const{getPrefixCls:r,direction:n}=d.useContext(Zt),{name:o}=d.useContext(oa),a=Qp(_4(o)),{prefixCls:i,className:l,rootClassName:s,options:u,buttonStyle:c="outline",disabled:f,children:p,size:h,style:v,id:g,optionType:m,name:b=a,defaultValue:y,value:C,block:D=!1,onChange:w,onMouseEnter:k,onMouseLeave:E,onFocus:x,onBlur:O}=e,[j,$]=Gr(y,{value:C}),P=d.useCallback(q=>{const Z=j,te=q.target.value;"value"in e||$(te),te!==Z&&(w==null||w(q))},[j,$,w]),A=r("radio",i),B=`${A}-group`,S=bo(A),[I,N,F]=Hx(A,S);let M=p;u&&u.length>0&&(M=u.map(q=>typeof q=="string"||typeof q=="number"?d.createElement(Js,{key:q.toString(),prefixCls:A,disabled:f,value:q,checked:j===q},q):d.createElement(Js,{key:`radio-group-value-options-${q.value}`,prefixCls:A,disabled:q.disabled||f,value:q.value,checked:j===q.value,title:q.title,style:q.style,className:q.className,id:q.id,required:q.required},q.label)));const _=fa(h),X=pe(B,`${B}-${c}`,{[`${B}-${_}`]:_,[`${B}-rtl`]:n==="rtl",[`${B}-block`]:D},l,s,N,F,S),H=d.useMemo(()=>({onChange:P,value:j,disabled:f,name:b,optionType:m,block:D}),[P,j,f,b,m,D]);return I(d.createElement("div",Object.assign({},Qn(e,{aria:!0,data:!0}),{className:X,style:v,onMouseEnter:k,onMouseLeave:E,onFocus:x,onBlur:O,id:g,ref:t}),d.createElement(A4,{value:H},M)))}),H4=d.memo(L4);var W4=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const K4=(e,t)=>{const{getPrefixCls:r}=d.useContext(Zt),{prefixCls:n}=e,o=W4(e,["prefixCls"]),a=r("radio",n);return d.createElement(F4,{value:"button"},d.createElement(Js,Object.assign({prefixCls:a},o,{type:"radio",ref:t})))},q4=d.forwardRef(K4),$l=Js;$l.Button=q4;$l.Group=H4;$l.__ANT_RADIO=!0;function pm(e){return er(e,{inputAffixPadding:e.paddingXXS})}const mm=e=>{const{controlHeight:t,fontSize:r,lineHeight:n,lineWidth:o,controlHeightSM:a,controlHeightLG:i,fontSizeLG:l,lineHeightLG:s,paddingSM:u,controlPaddingHorizontalSM:c,controlPaddingHorizontal:f,colorFillAlter:p,colorPrimaryHover:h,colorPrimary:v,controlOutlineWidth:g,controlOutline:m,colorErrorOutline:b,colorWarningOutline:y,colorBgContainer:C,inputFontSize:D,inputFontSizeLG:w,inputFontSizeSM:k}=e,E=D||r,x=k||E,O=w||l,j=Math.round((t-E*n)/2*10)/10-o,$=Math.round((a-x*n)/2*10)/10-o,P=Math.ceil((i-O*s)/2*10)/10-o;return{paddingBlock:Math.max(j,0),paddingBlockSM:Math.max($,0),paddingBlockLG:Math.max(P,0),paddingInline:u-o,paddingInlineSM:c-o,paddingInlineLG:f-o,addonBg:p,activeBorderColor:v,hoverBorderColor:h,activeShadow:`0 0 0 ${g}px ${m}`,errorActiveShadow:`0 0 0 ${g}px ${b}`,warningActiveShadow:`0 0 0 ${g}px ${y}`,hoverBg:C,activeBg:C,inputFontSize:E,inputFontSizeLG:O,inputFontSizeSM:x}},V4=e=>({borderColor:e.hoverBorderColor,backgroundColor:e.hoverBg}),Lu=e=>({color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,boxShadow:"none",cursor:"not-allowed",opacity:1,"input[disabled], textarea[disabled]":{cursor:"not-allowed"},"&:hover:not([disabled])":Object.assign({},V4(er(e,{hoverBorderColor:e.colorBorder,hoverBg:e.colorBgContainerDisabled})))}),hm=(e,t)=>({background:e.colorBgContainer,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:t.borderColor,"&:hover":{borderColor:t.hoverBorderColor,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:t.activeBorderColor,boxShadow:t.activeShadow,outline:0,backgroundColor:e.activeBg}}),P0=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:Object.assign(Object.assign({},hm(e,t)),{[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}}),[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:t.borderColor}}),G4=(e,t)=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},hm(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow})),{[`&${e.componentCls}-disabled, &[disabled]`]:Object.assign({},Lu(e))}),P0(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError})),P0(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning})),t)}),j0=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{borderColor:t.addonBorderColor,color:t.addonColor}}}),X4=e=>({"&-outlined":Object.assign(Object.assign(Object.assign({[`${e.componentCls}-group`]:{"&-addon":{background:e.addonBg,border:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:first-child":{borderInlineEnd:0},"&-addon:last-child":{borderInlineStart:0}}},j0(e,{status:"error",addonBorderColor:e.colorError,addonColor:e.colorErrorText})),j0(e,{status:"warning",addonBorderColor:e.colorWarning,addonColor:e.colorWarningText})),{[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group-addon`]:Object.assign({},Lu(e))}})}),U4=(e,t)=>{const{componentCls:r}=e;return{"&-borderless":Object.assign({background:"transparent",border:"none","&:focus, &:focus-within":{outline:"none"},[`&${r}-disabled, &[disabled]`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${r}-status-error`]:{"&, & input, & textarea":{color:e.colorError}},[`&${r}-status-warning`]:{"&, & input, & textarea":{color:e.colorWarning}}},t)}},Wx=(e,t)=>{var r;return{background:t.bg,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:"transparent","input&, & input, textarea&, & textarea":{color:(r=t==null?void 0:t.inputColor)!==null&&r!==void 0?r:"unset"},"&:hover":{background:t.hoverBg},"&:focus, &:focus-within":{outline:0,borderColor:t.activeBorderColor,backgroundColor:e.activeBg}}},I0=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:Object.assign(Object.assign({},Wx(e,t)),{[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}})}),Y4=(e,t)=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Wx(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor})),{[`&${e.componentCls}-disabled, &[disabled]`]:Object.assign({},Lu(e))}),I0(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,inputColor:e.colorErrorText,affixColor:e.colorError})),I0(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,inputColor:e.colorWarningText,affixColor:e.colorWarning})),t)}),R0=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{background:t.addonBg,color:t.addonColor}}}),Z4=e=>({"&-filled":Object.assign(Object.assign(Object.assign({[`${e.componentCls}-group-addon`]:{background:e.colorFillTertiary,"&:last-child":{position:"static"}}},R0(e,{status:"error",addonBg:e.colorErrorBg,addonColor:e.colorErrorText})),R0(e,{status:"warning",addonBg:e.colorWarningBg,addonColor:e.colorWarningText})),{[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group`]:{"&-addon":{background:e.colorFillTertiary,color:e.colorTextDisabled},"&-addon:first-child":{borderInlineStart:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:last-child":{borderInlineEnd:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`}}}})}),Kx=(e,t)=>({background:e.colorBgContainer,borderWidth:`${ue(e.lineWidth)} 0`,borderStyle:`${e.lineType} none`,borderColor:`transparent transparent ${t.borderColor} transparent`,borderRadius:0,"&:hover":{borderColor:`transparent transparent ${t.borderColor} transparent`,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:`transparent transparent ${t.activeBorderColor} transparent`,outline:0,backgroundColor:e.activeBg}}),M0=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:Object.assign(Object.assign({},Kx(e,t)),{[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}}),[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:`transparent transparent ${t.borderColor} transparent`}}),J4=(e,t)=>({"&-underlined":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Kx(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow})),{[`&${e.componentCls}-disabled, &[disabled]`]:{color:e.colorTextDisabled,boxShadow:"none",cursor:"not-allowed","&:hover":{borderColor:`transparent transparent ${e.colorBorder} transparent`}},"input[disabled], textarea[disabled]":{cursor:"not-allowed"}}),M0(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError})),M0(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning})),t)}),Q4=e=>({"&::-moz-placeholder":{opacity:1},"&::placeholder":{color:e,userSelect:"none"},"&:placeholder-shown":{textOverflow:"ellipsis"}}),qx=e=>{const{paddingBlockLG:t,lineHeightLG:r,borderRadiusLG:n,paddingInlineLG:o}=e;return{padding:`${ue(t)} ${ue(o)}`,fontSize:e.inputFontSizeLG,lineHeight:r,borderRadius:n}},gm=e=>({padding:`${ue(e.paddingBlockSM)} ${ue(e.paddingInlineSM)}`,fontSize:e.inputFontSizeSM,borderRadius:e.borderRadiusSM}),vm=e=>Object.assign(Object.assign({position:"relative",display:"inline-block",width:"100%",minWidth:0,padding:`${ue(e.paddingBlock)} ${ue(e.paddingInline)}`,color:e.colorText,fontSize:e.inputFontSize,lineHeight:e.lineHeight,borderRadius:e.borderRadius,transition:`all ${e.motionDurationMid}`},Q4(e.colorTextPlaceholder)),{"&-lg":Object.assign({},qx(e)),"&-sm":Object.assign({},gm(e)),"&-rtl, &-textarea-rtl":{direction:"rtl"}}),eR=e=>{const{componentCls:t,antCls:r}=e;return{position:"relative",display:"table",width:"100%",borderCollapse:"separate",borderSpacing:0,"&[class*='col-']":{paddingInlineEnd:e.paddingXS,"&:last-child":{paddingInlineEnd:0}},[`&-lg ${t}, &-lg > ${t}-group-addon`]:Object.assign({},qx(e)),[`&-sm ${t}, &-sm > ${t}-group-addon`]:Object.assign({},gm(e)),[`&-lg ${r}-select-single ${r}-select-selector`]:{height:e.controlHeightLG},[`&-sm ${r}-select-single ${r}-select-selector`]:{height:e.controlHeightSM},[`> ${t}`]:{display:"table-cell","&:not(:first-child):not(:last-child)":{borderRadius:0}},[`${t}-group`]:{"&-addon, &-wrap":{display:"table-cell",width:1,whiteSpace:"nowrap",verticalAlign:"middle","&:not(:first-child):not(:last-child)":{borderRadius:0}},"&-wrap > *":{display:"block !important"},"&-addon":{position:"relative",padding:`0 ${ue(e.paddingInline)}`,color:e.colorText,fontWeight:"normal",fontSize:e.inputFontSize,textAlign:"center",borderRadius:e.borderRadius,transition:`all ${e.motionDurationSlow}`,lineHeight:1,[`${r}-select`]:{margin:`${ue(e.calc(e.paddingBlock).add(1).mul(-1).equal())} ${ue(e.calc(e.paddingInline).mul(-1).equal())}`,[`&${r}-select-single:not(${r}-select-customize-input):not(${r}-pagination-size-changer)`]:{[`${r}-select-selector`]:{backgroundColor:"inherit",border:`${ue(e.lineWidth)} ${e.lineType} transparent`,boxShadow:"none"}}},[`${r}-cascader-picker`]:{margin:`-9px ${ue(e.calc(e.paddingInline).mul(-1).equal())}`,backgroundColor:"transparent",[`${r}-cascader-input`]:{textAlign:"start",border:0,boxShadow:"none"}}}},[t]:{width:"100%",marginBottom:0,textAlign:"inherit","&:focus":{zIndex:1,borderInlineEndWidth:1},"&:hover":{zIndex:1,borderInlineEndWidth:1,[`${t}-search-with-button &`]:{zIndex:0}}},[`> ${t}:first-child, ${t}-group-addon:first-child`]:{borderStartEndRadius:0,borderEndEndRadius:0,[`${r}-select ${r}-select-selector`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}-affix-wrapper`]:{[`&:not(:first-child) ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0},[`&:not(:last-child) ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}:last-child, ${t}-group-addon:last-child`]:{borderStartStartRadius:0,borderEndStartRadius:0,[`${r}-select ${r}-select-selector`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`${t}-affix-wrapper`]:{"&:not(:last-child)":{borderStartEndRadius:0,borderEndEndRadius:0,[`${t}-search &`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius}},[`&:not(:first-child), ${t}-search &:not(:first-child)`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`&${t}-group-compact`]:Object.assign(Object.assign({display:"block"},Hs()),{[`${t}-group-addon, ${t}-group-wrap, > ${t}`]:{"&:not(:first-child):not(:last-child)":{borderInlineEndWidth:e.lineWidth,"&:hover, &:focus":{zIndex:1}}},"& > *":{display:"inline-flex",float:"none",verticalAlign:"top",borderRadius:0},[`
|
|
354
|
+
& > ${t}-affix-wrapper,
|
|
355
|
+
& > ${t}-number-affix-wrapper,
|
|
356
|
+
& > ${r}-picker-range
|
|
357
|
+
`]:{display:"inline-flex"},"& > *:not(:last-child)":{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal(),borderInlineEndWidth:e.lineWidth},[t]:{float:"none"},[`& > ${r}-select > ${r}-select-selector,
|
|
358
|
+
& > ${r}-select-auto-complete ${t},
|
|
359
|
+
& > ${r}-cascader-picker ${t},
|
|
360
|
+
& > ${t}-group-wrapper ${t}`]:{borderInlineEndWidth:e.lineWidth,borderRadius:0,"&:hover, &:focus":{zIndex:1}},[`& > ${r}-select-focused`]:{zIndex:1},[`& > ${r}-select > ${r}-select-arrow`]:{zIndex:1},[`& > *:first-child,
|
|
361
|
+
& > ${r}-select:first-child > ${r}-select-selector,
|
|
362
|
+
& > ${r}-select-auto-complete:first-child ${t},
|
|
363
|
+
& > ${r}-cascader-picker:first-child ${t}`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius},[`& > *:last-child,
|
|
364
|
+
& > ${r}-select:last-child > ${r}-select-selector,
|
|
365
|
+
& > ${r}-cascader-picker:last-child ${t},
|
|
366
|
+
& > ${r}-cascader-picker-focused:last-child ${t}`]:{borderInlineEndWidth:e.lineWidth,borderStartEndRadius:e.borderRadius,borderEndEndRadius:e.borderRadius},[`& > ${r}-select-auto-complete ${t}`]:{verticalAlign:"top"},[`${t}-group-wrapper + ${t}-group-wrapper`]:{marginInlineStart:e.calc(e.lineWidth).mul(-1).equal(),[`${t}-affix-wrapper`]:{borderRadius:0}},[`${t}-group-wrapper:not(:last-child)`]:{[`&${t}-search > ${t}-group`]:{[`& > ${t}-group-addon > ${t}-search-button`]:{borderRadius:0},[`& > ${t}`]:{borderStartStartRadius:e.borderRadius,borderStartEndRadius:0,borderEndEndRadius:0,borderEndStartRadius:e.borderRadius}}}})}},tR=e=>{const{componentCls:t,controlHeightSM:r,lineWidth:n,calc:o}=e,a=o(r).sub(o(n).mul(2)).sub(16).div(2).equal();return{[t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Br(e)),vm(e)),G4(e)),Y4(e)),U4(e)),J4(e)),{'&[type="color"]':{height:e.controlHeight,[`&${t}-lg`]:{height:e.controlHeightLG},[`&${t}-sm`]:{height:r,paddingTop:a,paddingBottom:a}},'&[type="search"]::-webkit-search-cancel-button, &[type="search"]::-webkit-search-decoration':{appearance:"none"}})}},rR=e=>{const{componentCls:t}=e;return{[`${t}-clear-icon`]:{margin:0,padding:0,lineHeight:0,color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,verticalAlign:-1,cursor:"pointer",transition:`color ${e.motionDurationSlow}`,border:"none",outline:"none",backgroundColor:"transparent","&:hover":{color:e.colorIcon},"&:active":{color:e.colorText},"&-hidden":{visibility:"hidden"},"&-has-suffix":{margin:`0 ${ue(e.inputAffixPadding)}`}}}},nR=e=>{const{componentCls:t,inputAffixPadding:r,colorTextDescription:n,motionDurationSlow:o,colorIcon:a,colorIconHover:i,iconCls:l}=e,s=`${t}-affix-wrapper`,u=`${t}-affix-wrapper-disabled`;return{[s]:Object.assign(Object.assign(Object.assign(Object.assign({},vm(e)),{display:"inline-flex",[`&:not(${t}-disabled):hover`]:{zIndex:1,[`${t}-search-with-button &`]:{zIndex:0}},"&-focused, &:focus":{zIndex:1},[`> input${t}`]:{padding:0},[`> input${t}, > textarea${t}`]:{fontSize:"inherit",border:"none",borderRadius:0,outline:"none",background:"transparent",color:"inherit","&::-ms-reveal":{display:"none"},"&:focus":{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},[t]:{"&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center","> *:not(:last-child)":{marginInlineEnd:e.paddingXS}},"&-show-count-suffix":{color:n,direction:"ltr"},"&-show-count-has-suffix":{marginInlineEnd:e.paddingXXS},"&-prefix":{marginInlineEnd:r},"&-suffix":{marginInlineStart:r}}}),rR(e)),{[`${l}${t}-password-icon`]:{color:a,cursor:"pointer",transition:`all ${o}`,"&:hover":{color:i}}}),[`${t}-underlined`]:{borderRadius:0},[u]:{[`${l}${t}-password-icon`]:{color:a,cursor:"not-allowed","&:hover":{color:a}}}}},oR=e=>{const{componentCls:t,borderRadiusLG:r,borderRadiusSM:n}=e;return{[`${t}-group`]:Object.assign(Object.assign(Object.assign({},Br(e)),eR(e)),{"&-rtl":{direction:"rtl"},"&-wrapper":Object.assign(Object.assign(Object.assign({display:"inline-block",width:"100%",textAlign:"start",verticalAlign:"top","&-rtl":{direction:"rtl"},"&-lg":{[`${t}-group-addon`]:{borderRadius:r,fontSize:e.inputFontSizeLG}},"&-sm":{[`${t}-group-addon`]:{borderRadius:n}}},X4(e)),Z4(e)),{[`&:not(${t}-compact-first-item):not(${t}-compact-last-item)${t}-compact-item`]:{[`${t}, ${t}-group-addon`]:{borderRadius:0}},[`&:not(${t}-compact-last-item)${t}-compact-first-item`]:{[`${t}, ${t}-group-addon`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${t}-compact-first-item)${t}-compact-last-item`]:{[`${t}, ${t}-group-addon`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`&:not(${t}-compact-last-item)${t}-compact-item`]:{[`${t}-affix-wrapper`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${t}-compact-first-item)${t}-compact-item`]:{[`${t}-affix-wrapper`]:{borderStartStartRadius:0,borderEndStartRadius:0}}})})}},aR=e=>{const{componentCls:t,antCls:r}=e,n=`${t}-search`;return{[n]:{[t]:{"&:hover, &:focus":{[`+ ${t}-group-addon ${n}-button:not(${r}-btn-color-primary):not(${r}-btn-variant-text)`]:{borderInlineStartColor:e.colorPrimaryHover}}},[`${t}-affix-wrapper`]:{height:e.controlHeight,borderRadius:0},[`${t}-lg`]:{lineHeight:e.calc(e.lineHeightLG).sub(2e-4).equal()},[`> ${t}-group`]:{[`> ${t}-group-addon:last-child`]:{insetInlineStart:-1,padding:0,border:0,[`${n}-button`]:{marginInlineEnd:-1,borderStartStartRadius:0,borderEndStartRadius:0,boxShadow:"none"},[`${n}-button:not(${r}-btn-color-primary)`]:{color:e.colorTextDescription,"&:hover":{color:e.colorPrimaryHover},"&:active":{color:e.colorPrimaryActive},[`&${r}-btn-loading::before`]:{inset:0}}}},[`${n}-button`]:{height:e.controlHeight,"&:hover, &:focus":{zIndex:1}},"&-large":{[`${t}-affix-wrapper, ${n}-button`]:{height:e.controlHeightLG}},"&-small":{[`${t}-affix-wrapper, ${n}-button`]:{height:e.controlHeightSM}},"&-rtl":{direction:"rtl"},[`&${t}-compact-item`]:{[`&:not(${t}-compact-last-item)`]:{[`${t}-group-addon`]:{[`${t}-search-button`]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal(),borderRadius:0}}},[`&:not(${t}-compact-first-item)`]:{[`${t},${t}-affix-wrapper`]:{borderRadius:0}},[`> ${t}-group-addon ${t}-search-button,
|
|
367
|
+
> ${t},
|
|
368
|
+
${t}-affix-wrapper`]:{"&:hover, &:focus, &:active":{zIndex:2}},[`> ${t}-affix-wrapper-focused`]:{zIndex:2}}}}},iR=e=>{const{componentCls:t}=e;return{[`${t}-out-of-range`]:{[`&, & input, & textarea, ${t}-show-count-suffix, ${t}-data-count`]:{color:e.colorError}}}},lR=Hr(["Input","Shared"],e=>{const t=er(e,pm(e));return[tR(t),nR(t)]},mm,{resetFont:!1}),sR=Hr(["Input","Component"],e=>{const t=er(e,pm(e));return[oR(t),aR(t),iR(t),Jp(t)]},mm,{resetFont:!1});function uR(e,t,r){var n=r||{},o=n.noTrailing,a=o===void 0?!1:o,i=n.noLeading,l=i===void 0?!1:i,s=n.debounceMode,u=s===void 0?void 0:s,c,f=!1,p=0;function h(){c&&clearTimeout(c)}function v(m){var b=m||{},y=b.upcomingOnly,C=y===void 0?!1:y;h(),f=!C}function g(){for(var m=arguments.length,b=new Array(m),y=0;y<m;y++)b[y]=arguments[y];var C=this,D=Date.now()-p;if(f)return;function w(){p=Date.now(),t.apply(C,b)}function k(){c=void 0}!l&&u&&!c&&w(),h(),u===void 0&&D>e?l?(p=Date.now(),a||(c=setTimeout(u?k:w,e))):w():a!==!0&&(c=setTimeout(u?k:w,u===void 0?e-D:e))}return g.cancel=v,g}function cR(e,t,r){var n={},o=n.atBegin,a=o===void 0?!1:o;return uR(e,t,{debounceMode:a!==!1})}function un(e,t){return e[t]}var dR=["children"];function Vx(e,t){return"".concat(e,"-").concat(t)}function fR(e){return e&&e.type&&e.type.isTreeNode}function Bl(e,t){return e??t}function Ja(e){var t=e||{},r=t.title,n=t._title,o=t.key,a=t.children,i=r||"title";return{title:i,_title:n||[i],key:o||"key",children:a||"children"}}function Gx(e){function t(r){var n=Ln(r);return n.map(function(o){if(!fR(o))return lr(!o,"Tree/TreeNode can only accept TreeNode as children."),null;var a=o.key,i=o.props,l=i.children,s=bt(i,dR),u=L({key:a},s),c=t(l);return c.length&&(u.children=c),u}).filter(function(o){return o})}return t(e)}function Qc(e,t,r){var n=Ja(r),o=n._title,a=n.key,i=n.children,l=new Set(t===!0?[]:t),s=[];function u(c){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;return c.map(function(p,h){for(var v=Vx(f?f.pos:"0",h),g=Bl(p[a],v),m,b=0;b<o.length;b+=1){var y=o[b];if(p[y]!==void 0){m=p[y];break}}var C=Object.assign(fn(p,[].concat(Ie(o),[a,i])),{title:m,key:g,parent:f,pos:v,children:null,data:p,isStart:[].concat(Ie(f?f.isStart:[]),[h===0]),isEnd:[].concat(Ie(f?f.isEnd:[]),[h===c.length-1])});return s.push(C),t===!0||l.has(g)?C.children=u(p[i]||[],C):C.children=[],C})}return u(e),s}function pR(e,t,r){var n={};at(r)==="object"?n=r:n={externalGetKey:r},n=n||{};var o=n,a=o.childrenPropName,i=o.externalGetKey,l=o.fieldNames,s=Ja(l),u=s.key,c=s.children,f=a||c,p;i?typeof i=="string"?p=function(v){return v[i]}:typeof i=="function"&&(p=function(v){return i(v)}):p=function(v,g){return Bl(v[u],g)};function h(v,g,m,b){var y=v?v[f]:e,C=v?Vx(m.pos,g):"0",D=v?[].concat(Ie(b),[v]):[];if(v){var w=p(v,C),k={node:v,index:g,pos:C,key:w,parentPos:m.node?m.pos:null,level:m.level+1,nodes:D};t(k)}y&&y.forEach(function(E,x){h(E,x,{node:v,pos:C,level:m?m.level+1:-1},D)})}h(null)}function bm(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.initWrapper,n=t.processEntity,o=t.onProcessFinished,a=t.externalGetKey,i=t.childrenPropName,l=t.fieldNames,s=arguments.length>2?arguments[2]:void 0,u=a||s,c={},f={},p={posEntities:c,keyEntities:f};return r&&(p=r(p)||p),pR(e,function(h){var v=h.node,g=h.index,m=h.pos,b=h.key,y=h.parentPos,C=h.level,D=h.nodes,w={node:v,nodes:D,index:g,key:b,pos:m,level:C},k=Bl(b,m);c[m]=w,f[k]=w,w.parent=c[y],w.parent&&(w.parent.children=w.parent.children||[],w.parent.children.push(w)),n&&n(w,p)},{externalGetKey:u,childrenPropName:i,fieldNames:l}),o&&o(p),p}function Li(e,t){var r=t.expandedKeys,n=t.selectedKeys,o=t.loadedKeys,a=t.loadingKeys,i=t.checkedKeys,l=t.halfCheckedKeys,s=t.dragOverNodeKey,u=t.dropPosition,c=t.keyEntities,f=un(c,e),p={eventKey:e,expanded:r.indexOf(e)!==-1,selected:n.indexOf(e)!==-1,loaded:o.indexOf(e)!==-1,loading:a.indexOf(e)!==-1,checked:i.indexOf(e)!==-1,halfChecked:l.indexOf(e)!==-1,pos:String(f?f.pos:""),dragOver:s===e&&u===0,dragOverGapTop:s===e&&u===-1,dragOverGapBottom:s===e&&u===1};return p}function wr(e){var t=e.data,r=e.expanded,n=e.selected,o=e.checked,a=e.loaded,i=e.loading,l=e.halfChecked,s=e.dragOver,u=e.dragOverGapTop,c=e.dragOverGapBottom,f=e.pos,p=e.active,h=e.eventKey,v=L(L({},t),{},{expanded:r,selected:n,checked:o,loaded:a,loading:i,halfChecked:l,dragOver:s,dragOverGapTop:u,dragOverGapBottom:c,pos:f,active:p,key:h});return"props"in v||Object.defineProperty(v,"props",{get:function(){return lr(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),e}}),v}function Xx(e,t){var r=new Set;return e.forEach(function(n){t.has(n)||r.add(n)}),r}function mR(e){var t=e||{},r=t.disabled,n=t.disableCheckbox,o=t.checkable;return!!(r||n)||o===!1}function hR(e,t,r,n){for(var o=new Set(e),a=new Set,i=0;i<=r;i+=1){var l=t.get(i)||new Set;l.forEach(function(f){var p=f.key,h=f.node,v=f.children,g=v===void 0?[]:v;o.has(p)&&!n(h)&&g.filter(function(m){return!n(m.node)}).forEach(function(m){o.add(m.key)})})}for(var s=new Set,u=r;u>=0;u-=1){var c=t.get(u)||new Set;c.forEach(function(f){var p=f.parent,h=f.node;if(!(n(h)||!f.parent||s.has(f.parent.key))){if(n(f.parent.node)){s.add(p.key);return}var v=!0,g=!1;(p.children||[]).filter(function(m){return!n(m.node)}).forEach(function(m){var b=m.key,y=o.has(b);v&&!y&&(v=!1),!g&&(y||a.has(b))&&(g=!0)}),v&&o.add(p.key),g&&a.add(p.key),s.add(p.key)}})}return{checkedKeys:Array.from(o),halfCheckedKeys:Array.from(Xx(a,o))}}function gR(e,t,r,n,o){for(var a=new Set(e),i=new Set(t),l=0;l<=n;l+=1){var s=r.get(l)||new Set;s.forEach(function(p){var h=p.key,v=p.node,g=p.children,m=g===void 0?[]:g;!a.has(h)&&!i.has(h)&&!o(v)&&m.filter(function(b){return!o(b.node)}).forEach(function(b){a.delete(b.key)})})}i=new Set;for(var u=new Set,c=n;c>=0;c-=1){var f=r.get(c)||new Set;f.forEach(function(p){var h=p.parent,v=p.node;if(!(o(v)||!p.parent||u.has(p.parent.key))){if(o(p.parent.node)){u.add(h.key);return}var g=!0,m=!1;(h.children||[]).filter(function(b){return!o(b.node)}).forEach(function(b){var y=b.key,C=a.has(y);g&&!C&&(g=!1),!m&&(C||i.has(y))&&(m=!0)}),g||a.delete(h.key),m&&i.add(h.key),u.add(h.key)}})}return{checkedKeys:Array.from(a),halfCheckedKeys:Array.from(Xx(i,a))}}function ja(e,t,r,n){var o=[],a;n?a=n:a=mR;var i=new Set(e.filter(function(c){var f=!!un(r,c);return f||o.push(c),f})),l=new Map,s=0;Object.keys(r).forEach(function(c){var f=r[c],p=f.level,h=l.get(p);h||(h=new Set,l.set(p,h)),h.add(f),s=Math.max(s,p)}),lr(!o.length,"Tree missing follow keys: ".concat(o.slice(0,100).map(function(c){return"'".concat(c,"'")}).join(", ")));var u;return t===!0?u=hR(i,l,s,a):u=gR(i,t.halfCheckedKeys,l,s,a),u}const vR=e=>{const{checkboxCls:t}=e,r=`${t}-wrapper`;return[{[`${t}-group`]:Object.assign(Object.assign({},Br(e)),{display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}}),[r]:Object.assign(Object.assign({},Br(e)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${r}`]:{marginInlineStart:0},[`&${r}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[t]:Object.assign(Object.assign({},Br(e)),{position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",borderRadius:e.borderRadiusSM,alignSelf:"center",[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0,[`&:focus-visible + ${t}-inner`]:Po(e)},[`${t}-inner`]:{boxSizing:"border-box",display:"block",width:e.checkboxSize,height:e.checkboxSize,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"25%",display:"table",width:e.calc(e.checkboxSize).div(14).mul(5).equal(),height:e.calc(e.checkboxSize).div(14).mul(8).equal(),border:`${ue(e.lineWidthBold)} solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`}},"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}})},{[`
|
|
369
|
+
${r}:not(${r}-disabled),
|
|
370
|
+
${t}:not(${t}-disabled)
|
|
371
|
+
`]:{[`&:hover ${t}-inner`]:{borderColor:e.colorPrimary}},[`${r}:not(${r}-disabled)`]:{[`&:hover ${t}-checked:not(${t}-disabled) ${t}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"},[`&:hover ${t}-checked:not(${t}-disabled):after`]:{borderColor:e.colorPrimaryHover}}},{[`${t}-checked`]:{[`${t}-inner`]:{backgroundColor:e.colorPrimary,borderColor:e.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`}}},[`
|
|
372
|
+
${r}-checked:not(${r}-disabled),
|
|
373
|
+
${t}-checked:not(${t}-disabled)
|
|
374
|
+
`]:{[`&:hover ${t}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"}}},{[t]:{"&-indeterminate":{"&":{[`${t}-inner`]:{backgroundColor:`${e.colorBgContainer}`,borderColor:`${e.colorBorder}`,"&:after":{top:"50%",insetInlineStart:"50%",width:e.calc(e.fontSizeLG).div(2).equal(),height:e.calc(e.fontSizeLG).div(2).equal(),backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'}},[`&:hover ${t}-inner`]:{backgroundColor:`${e.colorBgContainer}`,borderColor:`${e.colorPrimary}`}}}}},{[`${r}-disabled`]:{cursor:"not-allowed"},[`${t}-disabled`]:{[`&, ${t}-input`]:{cursor:"not-allowed",pointerEvents:"none"},[`${t}-inner`]:{background:e.colorBgContainerDisabled,borderColor:e.colorBorder,"&:after":{borderColor:e.colorTextDisabled}},"&:after":{display:"none"},"& + span":{color:e.colorTextDisabled},[`&${t}-indeterminate ${t}-inner::after`]:{background:e.colorTextDisabled}}}]};function Ux(e,t){const r=er(t,{checkboxCls:`.${e}`,checkboxSize:t.controlInteractiveSize});return vR(r)}const Yx=Hr("Checkbox",(e,{prefixCls:t})=>[Ux(t,e)]),Zx=ee.createContext(null);var bR=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const yR=(e,t)=>{var r;const{prefixCls:n,className:o,rootClassName:a,children:i,indeterminate:l=!1,style:s,onMouseEnter:u,onMouseLeave:c,skipGroup:f=!1,disabled:p}=e,h=bR(e,["prefixCls","className","rootClassName","children","indeterminate","style","onMouseEnter","onMouseLeave","skipGroup","disabled"]),{getPrefixCls:v,direction:g,checkbox:m}=d.useContext(Zt),b=d.useContext(Zx),{isFormItemInput:y}=d.useContext(oa),C=d.useContext(No),D=(r=(b==null?void 0:b.disabled)||p)!==null&&r!==void 0?r:C,w=d.useRef(h.value),k=d.useRef(null),E=ro(t,k);d.useEffect(()=>{b==null||b.registerValue(h.value)},[]),d.useEffect(()=>{if(!f)return h.value!==w.current&&(b==null||b.cancelValue(w.current),b==null||b.registerValue(h.value),w.current=h.value),()=>b==null?void 0:b.cancelValue(h.value)},[h.value]),d.useEffect(()=>{var F;!((F=k.current)===null||F===void 0)&&F.input&&(k.current.input.indeterminate=l)},[l]);const x=v("checkbox",n),O=bo(x),[j,$,P]=Yx(x,O),A=Object.assign({},h);b&&!f&&(A.onChange=(...F)=>{h.onChange&&h.onChange.apply(h,F),b.toggleOption&&b.toggleOption({label:i,value:h.value})},A.name=b.name,A.checked=b.value.includes(h.value));const B=pe(`${x}-wrapper`,{[`${x}-rtl`]:g==="rtl",[`${x}-wrapper-checked`]:A.checked,[`${x}-wrapper-disabled`]:D,[`${x}-wrapper-in-form-item`]:y},m==null?void 0:m.className,o,a,P,O,$),S=pe({[`${x}-indeterminate`]:l},Du,$),[I,N]=Lx(A.onClick);return j(d.createElement(Kp,{component:"Checkbox",disabled:D},d.createElement("label",{className:B,style:Object.assign(Object.assign({},m==null?void 0:m.style),s),onMouseEnter:u,onMouseLeave:c,onClick:I},d.createElement(_x,Object.assign({},A,{onClick:N,prefixCls:x,className:S,disabled:D,ref:E})),i!=null&&d.createElement("span",{className:`${x}-label`},i))))},Jx=d.forwardRef(yR);var CR=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const xR=d.forwardRef((e,t)=>{const{defaultValue:r,children:n,options:o=[],prefixCls:a,className:i,rootClassName:l,style:s,onChange:u}=e,c=CR(e,["defaultValue","children","options","prefixCls","className","rootClassName","style","onChange"]),{getPrefixCls:f,direction:p}=d.useContext(Zt),[h,v]=d.useState(c.value||r||[]),[g,m]=d.useState([]);d.useEffect(()=>{"value"in c&&v(c.value||[])},[c.value]);const b=d.useMemo(()=>o.map(S=>typeof S=="string"||typeof S=="number"?{label:S,value:S}:S),[o]),y=S=>{m(I=>I.filter(N=>N!==S))},C=S=>{m(I=>[].concat(Ie(I),[S]))},D=S=>{const I=h.indexOf(S.value),N=Ie(h);I===-1?N.push(S.value):N.splice(I,1),"value"in c||v(N),u==null||u(N.filter(F=>g.includes(F)).sort((F,M)=>{const _=b.findIndex(H=>H.value===F),X=b.findIndex(H=>H.value===M);return _-X}))},w=f("checkbox",a),k=`${w}-group`,E=bo(w),[x,O,j]=Yx(w,E),$=fn(c,["value","disabled"]),P=o.length?b.map(S=>d.createElement(Jx,{prefixCls:w,key:S.value.toString(),disabled:"disabled"in S?S.disabled:c.disabled,value:S.value,checked:h.includes(S.value),onChange:S.onChange,className:pe(`${k}-item`,S.className),style:S.style,title:S.title,id:S.id,required:S.required},S.label)):n,A=d.useMemo(()=>({toggleOption:D,value:h,disabled:c.disabled,name:c.name,registerValue:C,cancelValue:y}),[D,h,c.disabled,c.name,C,y]),B=pe(k,{[`${k}-rtl`]:p==="rtl"},i,l,j,E,O);return x(d.createElement("div",Object.assign({className:B,style:s},$,{ref:t}),d.createElement(Zx.Provider,{value:A},P)))}),Qa=Jx;Qa.Group=xR;Qa.__ANT_CHECKBOX=!0;function wR(e){return!!(e.addonBefore||e.addonAfter)}function ER(e){return!!(e.prefix||e.suffix||e.allowClear)}function T0(e,t,r){var n=t.cloneNode(!0),o=Object.create(e,{target:{value:n},currentTarget:{value:n}});return n.value=r,typeof t.selectionStart=="number"&&typeof t.selectionEnd=="number"&&(n.selectionStart=t.selectionStart,n.selectionEnd=t.selectionEnd),n.setSelectionRange=function(){t.setSelectionRange.apply(t,arguments)},o}function z0(e,t,r,n){if(r){var o=t;if(t.type==="click"){o=T0(t,e,""),r(o);return}if(e.type!=="file"&&n!==void 0){o=T0(t,e,n),r(o);return}r(o)}}function kR(e,t){if(e){e.focus(t);var r=t||{},n=r.cursor;if(n){var o=e.value.length;switch(n){case"start":e.setSelectionRange(0,0);break;case"end":e.setSelectionRange(o,o);break;default:e.setSelectionRange(0,o)}}}}var DR=ee.forwardRef(function(e,t){var r,n,o,a=e.inputElement,i=e.children,l=e.prefixCls,s=e.prefix,u=e.suffix,c=e.addonBefore,f=e.addonAfter,p=e.className,h=e.style,v=e.disabled,g=e.readOnly,m=e.focused,b=e.triggerFocus,y=e.allowClear,C=e.value,D=e.handleReset,w=e.hidden,k=e.classes,E=e.classNames,x=e.dataAttrs,O=e.styles,j=e.components,$=e.onClear,P=i??a,A=(j==null?void 0:j.affixWrapper)||"span",B=(j==null?void 0:j.groupWrapper)||"span",S=(j==null?void 0:j.wrapper)||"span",I=(j==null?void 0:j.groupAddon)||"span",N=qe(null),F=function(J){var oe;(oe=N.current)!==null&&oe!==void 0&&oe.contains(J.target)&&(b==null||b())},M=ER(e),_=Ww(P,{value:C,className:pe((r=P.props)===null||r===void 0?void 0:r.className,!M&&(E==null?void 0:E.variant))||null}),X=qe(null);if(ee.useImperativeHandle(t,function(){return{nativeElement:X.current||N.current}}),M){var H=null;if(y){var q=!v&&!g&&C,Z="".concat(l,"-clear-icon"),te=at(y)==="object"&&y!==null&&y!==void 0&&y.clearIcon?y.clearIcon:"\u2716";H=ee.createElement("button",{type:"button",tabIndex:-1,onClick:function(J){D==null||D(J),$==null||$()},onMouseDown:function(J){return J.preventDefault()},className:pe(Z,T(T({},"".concat(Z,"-hidden"),!q),"".concat(Z,"-has-suffix"),!!u))},te)}var z="".concat(l,"-affix-wrapper"),Y=pe(z,T(T(T(T(T({},"".concat(l,"-disabled"),v),"".concat(z,"-disabled"),v),"".concat(z,"-focused"),m),"".concat(z,"-readonly"),g),"".concat(z,"-input-with-clear-btn"),u&&y&&C),k==null?void 0:k.affixWrapper,E==null?void 0:E.affixWrapper,E==null?void 0:E.variant),V=(u||y)&&ee.createElement("span",{className:pe("".concat(l,"-suffix"),E==null?void 0:E.suffix),style:O==null?void 0:O.suffix},H,u);_=ee.createElement(A,Me({className:Y,style:O==null?void 0:O.affixWrapper,onClick:F},x==null?void 0:x.affixWrapper,{ref:N}),s&&ee.createElement("span",{className:pe("".concat(l,"-prefix"),E==null?void 0:E.prefix),style:O==null?void 0:O.prefix},s),_,V)}if(wR(e)){var U="".concat(l,"-group"),K="".concat(U,"-addon"),W="".concat(U,"-wrapper"),re=pe("".concat(l,"-wrapper"),U,k==null?void 0:k.wrapper,E==null?void 0:E.wrapper),G=pe(W,T({},"".concat(W,"-disabled"),v),k==null?void 0:k.group,E==null?void 0:E.groupWrapper);_=ee.createElement(B,{className:G,ref:X},ee.createElement(S,{className:re},c&&ee.createElement(I,{className:K},c),_,f&&ee.createElement(I,{className:K},f)))}return ee.cloneElement(_,{className:pe((n=_.props)===null||n===void 0?void 0:n.className,p)||null,style:L(L({},(o=_.props)===null||o===void 0?void 0:o.style),h),hidden:w})}),SR=["show"];function $R(e,t){return d.useMemo(function(){var r={};t&&(r.show=at(t)==="object"&&t.formatter?t.formatter:!!t),r=L(L({},r),e);var n=r,o=n.show,a=bt(n,SR);return L(L({},a),{},{show:!!o,showFormatter:typeof o=="function"?o:void 0,strategy:a.strategy||function(i){return i.length}})},[e,t])}var BR=["autoComplete","onChange","onFocus","onBlur","onPressEnter","onKeyDown","onKeyUp","prefixCls","disabled","htmlSize","className","maxLength","suffix","showCount","count","type","classes","classNames","styles","onCompositionStart","onCompositionEnd"],OR=dn(function(e,t){var r=e.autoComplete,n=e.onChange,o=e.onFocus,a=e.onBlur,i=e.onPressEnter,l=e.onKeyDown,s=e.onKeyUp,u=e.prefixCls,c=u===void 0?"rc-input":u,f=e.disabled,p=e.htmlSize,h=e.className,v=e.maxLength,g=e.suffix,m=e.showCount,b=e.count,y=e.type,C=y===void 0?"text":y,D=e.classes,w=e.classNames,k=e.styles,E=e.onCompositionStart,x=e.onCompositionEnd,O=bt(e,BR),j=yt(!1),$=ce(j,2),P=$[0],A=$[1],B=qe(!1),S=qe(!1),I=qe(null),N=qe(null),F=function(we){I.current&&kR(I.current,we)},M=Gr(e.defaultValue,{value:e.value}),_=ce(M,2),X=_[0],H=_[1],q=X==null?"":String(X),Z=yt(null),te=ce(Z,2),z=te[0],Y=te[1],V=$R(b,m),U=V.max||v,K=V.strategy(q),W=!!U&&K>U;ei(t,function(){var we;return{focus:F,blur:function(){var De;(De=I.current)===null||De===void 0||De.blur()},setSelectionRange:function(De,Ne,Oe){var Xe;(Xe=I.current)===null||Xe===void 0||Xe.setSelectionRange(De,Ne,Oe)},select:function(){var De;(De=I.current)===null||De===void 0||De.select()},input:I.current,nativeElement:((we=N.current)===null||we===void 0?void 0:we.nativeElement)||I.current}}),Ot(function(){S.current&&(S.current=!1),A(function(we){return we&&f?!1:we})},[f]);var re=function(we,De,Ne){var Oe=De;if(!B.current&&V.exceedFormatter&&V.max&&V.strategy(De)>V.max){if(Oe=V.exceedFormatter(De,{max:V.max}),De!==Oe){var Xe,Le;Y([((Xe=I.current)===null||Xe===void 0?void 0:Xe.selectionStart)||0,((Le=I.current)===null||Le===void 0?void 0:Le.selectionEnd)||0])}}else if(Ne.source==="compositionEnd")return;H(Oe),I.current&&z0(I.current,we,n,Oe)};Ot(function(){if(z){var we;(we=I.current)===null||we===void 0||we.setSelectionRange.apply(we,Ie(z))}},[z]);var G=function(we){re(we,we.target.value,{source:"change"})},J=function(we){B.current=!1,re(we,we.currentTarget.value,{source:"compositionEnd"}),x==null||x(we)},oe=function(we){i&&we.key==="Enter"&&!S.current&&(S.current=!0,i(we)),l==null||l(we)},se=function(we){we.key==="Enter"&&(S.current=!1),s==null||s(we)},ge=function(we){A(!0),o==null||o(we)},Ee=function(we){S.current&&(S.current=!1),A(!1),a==null||a(we)},je=function(we){H(""),F(),I.current&&z0(I.current,we,n)},ve=W&&"".concat(c,"-out-of-range"),ye=function(){var we=fn(e,["prefixCls","onPressEnter","addonBefore","addonAfter","prefix","suffix","allowClear","defaultValue","showCount","count","classes","htmlSize","styles","classNames","onClear"]);return ee.createElement("input",Me({autoComplete:r},we,{onChange:G,onFocus:ge,onBlur:Ee,onKeyDown:oe,onKeyUp:se,className:pe(c,T({},"".concat(c,"-disabled"),f),w==null?void 0:w.input),style:k==null?void 0:k.input,ref:I,size:p,type:C,onCompositionStart:function(De){B.current=!0,E==null||E(De)},onCompositionEnd:J}))},ke=function(){var we=Number(U)>0;if(g||V.show){var De=V.showFormatter?V.showFormatter({value:q,count:K,maxLength:U}):"".concat(K).concat(we?" / ".concat(U):"");return ee.createElement(ee.Fragment,null,V.show&&ee.createElement("span",{className:pe("".concat(c,"-show-count-suffix"),T({},"".concat(c,"-show-count-has-suffix"),!!g),w==null?void 0:w.count),style:L({},k==null?void 0:k.count)},De),g)}return null};return ee.createElement(DR,Me({},O,{prefixCls:c,className:pe(h,ve),handleReset:je,value:q,focused:P,triggerFocus:F,suffix:ke(),disabled:f,classes:D,classNames:w,styles:k,ref:N}),ye())});const AR=e=>{let t;return typeof e=="object"&&(e!=null&&e.clearIcon)?t=e:e&&(t={clearIcon:ee.createElement(mC,null)}),t};function FR(e,t){const r=qe([]),n=()=>{r.current.push(setTimeout(()=>{var o,a,i,l;!((o=e.current)===null||o===void 0)&&o.input&&((a=e.current)===null||a===void 0?void 0:a.input.getAttribute("type"))==="password"&&!((i=e.current)===null||i===void 0)&&i.input.hasAttribute("value")&&((l=e.current)===null||l===void 0||l.input.removeAttribute("value"))}))};return Ot(()=>(n(),()=>r.current.forEach(o=>{o&&clearTimeout(o)})),[]),n}function NR(e){return!!(e.prefix||e.suffix||e.allowClear||e.showCount)}var PR=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const jR=dn((e,t)=>{const{prefixCls:r,bordered:n=!0,status:o,size:a,disabled:i,onBlur:l,onFocus:s,suffix:u,allowClear:c,addonAfter:f,addonBefore:p,className:h,style:v,styles:g,rootClassName:m,onChange:b,classNames:y,variant:C}=e,D=PR(e,["prefixCls","bordered","status","size","disabled","onBlur","onFocus","suffix","allowClear","addonAfter","addonBefore","className","style","styles","rootClassName","onChange","classNames","variant"]),{getPrefixCls:w,direction:k,allowClear:E,autoComplete:x,className:O,style:j,classNames:$,styles:P}=Ro("input"),A=w("input",r),B=qe(null),S=bo(A),[I,N,F]=lR(A,m),[M]=sR(A,S),{compactSize:_,compactItemClassnames:X}=$u(A,k),H=fa(Ee=>{var je;return(je=a??_)!==null&&je!==void 0?je:Ee}),q=ee.useContext(No),Z=i??q,{status:te,hasFeedback:z,feedbackIcon:Y}=Rr(oa),V=QC(te,o),U=NR(e)||!!z;qe(U);const K=FR(B),W=Ee=>{K(),l==null||l(Ee)},re=Ee=>{K(),s==null||s(Ee)},G=Ee=>{K(),b==null||b(Ee)},J=(z||u)&&ee.createElement(ee.Fragment,null,u,z&&Y),oe=AR(c??E),[se,ge]=nx("input",C,n);return I(M(ee.createElement(OR,Object.assign({ref:ro(t,B),prefixCls:A,autoComplete:x},D,{disabled:Z,onBlur:W,onFocus:re,style:Object.assign(Object.assign({},j),v),styles:Object.assign(Object.assign({},P),g),suffix:J,allowClear:oe,className:pe(h,m,F,S,X,O),onChange:G,addonBefore:p&&ee.createElement(fl,{form:!0,space:!0},p),addonAfter:f&&ee.createElement(fl,{form:!0,space:!0},f),classNames:Object.assign(Object.assign(Object.assign({},y),$),{input:pe({[`${A}-sm`]:H==="small",[`${A}-lg`]:H==="large",[`${A}-rtl`]:k==="rtl"},y==null?void 0:y.input,$.input,N),variant:pe({[`${A}-${se}`]:ge},jf(A,V)),affixWrapper:pe({[`${A}-affix-wrapper-sm`]:H==="small",[`${A}-affix-wrapper-lg`]:H==="large",[`${A}-affix-wrapper-rtl`]:k==="rtl"},N),wrapper:pe({[`${A}-group-rtl`]:k==="rtl"},N),groupWrapper:pe({[`${A}-group-wrapper-sm`]:H==="small",[`${A}-group-wrapper-lg`]:H==="large",[`${A}-group-wrapper-rtl`]:k==="rtl",[`${A}-group-wrapper-${se}`]:ge},jf(`${A}-group-wrapper`,V,z),N)})}))))});function _0(e){return["small","middle","large"].includes(e)}function L0(e){return e?typeof e=="number"&&!Number.isNaN(e):!1}const Qx=ee.createContext({latestIndex:0}),IR=Qx.Provider,RR=({className:e,index:t,children:r,split:n,style:o})=>{const{latestIndex:a}=d.useContext(Qx);return r==null?null:d.createElement(d.Fragment,null,d.createElement("div",{className:e,style:o},r),t<a&&n&&d.createElement("span",{className:`${e}-split`},n))};var MR=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const TR=d.forwardRef((e,t)=>{var r;const{getPrefixCls:n,direction:o,size:a,className:i,style:l,classNames:s,styles:u}=Ro("space"),{size:c=a??"small",align:f,className:p,rootClassName:h,children:v,direction:g="horizontal",prefixCls:m,split:b,style:y,wrap:C=!1,classNames:D,styles:w}=e,k=MR(e,["size","align","className","rootClassName","children","direction","prefixCls","split","style","wrap","classNames","styles"]),[E,x]=Array.isArray(c)?c:[c,c],O=_0(x),j=_0(E),$=L0(x),P=L0(E),A=Ln(v,{keepEmpty:!0}),B=f===void 0&&g==="horizontal"?"center":f,S=n("space",m),[I,N,F]=xC(S),M=pe(S,i,N,`${S}-${g}`,{[`${S}-rtl`]:o==="rtl",[`${S}-align-${B}`]:B,[`${S}-gap-row-${x}`]:O,[`${S}-gap-col-${E}`]:j},p,h,F),_=pe(`${S}-item`,(r=D==null?void 0:D.item)!==null&&r!==void 0?r:s.item);let X=0;const H=A.map((te,z)=>{var Y;te!=null&&(X=z);const V=(te==null?void 0:te.key)||`${_}-${z}`;return d.createElement(RR,{className:_,key:V,index:z,split:b,style:(Y=w==null?void 0:w.item)!==null&&Y!==void 0?Y:u.item},te)}),q=d.useMemo(()=>({latestIndex:X}),[X]);if(A.length===0)return null;const Z={};return C&&(Z.flexWrap="wrap"),!j&&P&&(Z.columnGap=E),!O&&$&&(Z.rowGap=x),I(d.createElement("div",Object.assign({ref:t,className:M,style:Object.assign(Object.assign(Object.assign({},Z),l),y)},k),d.createElement(IR,{value:q},H)))}),ew=TR;ew.Compact=a5;var zR=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const tw=e=>{const{getPopupContainer:t,getPrefixCls:r,direction:n}=d.useContext(Zt),{prefixCls:o,type:a="default",danger:i,disabled:l,loading:s,onClick:u,htmlType:c,children:f,className:p,menu:h,arrow:v,autoFocus:g,overlay:m,trigger:b,align:y,open:C,onOpenChange:D,placement:w,getPopupContainer:k,href:E,icon:x=d.createElement(Px,null),title:O,buttonsRender:j=K=>K,mouseEnterDelay:$,mouseLeaveDelay:P,overlayClassName:A,overlayStyle:B,destroyOnHidden:S,destroyPopupOnHide:I,dropdownRender:N,popupRender:F}=e,M=zR(e,["prefixCls","type","danger","disabled","loading","onClick","htmlType","children","className","menu","arrow","autoFocus","overlay","trigger","align","open","onOpenChange","placement","getPopupContainer","href","icon","title","buttonsRender","mouseEnterDelay","mouseLeaveDelay","overlayClassName","overlayStyle","destroyOnHidden","destroyPopupOnHide","dropdownRender","popupRender"]),_=r("dropdown",o),X=`${_}-button`,H={menu:h,arrow:v,autoFocus:g,align:y,disabled:l,trigger:l?[]:b,onOpenChange:D,getPopupContainer:k||t,mouseEnterDelay:$,mouseLeaveDelay:P,overlayClassName:A,overlayStyle:B,destroyOnHidden:S,popupRender:F||N},{compactSize:q,compactItemClassnames:Z}=$u(_,n),te=pe(X,Z,p);"destroyPopupOnHide"in e&&(H.destroyPopupOnHide=I),"overlay"in e&&(H.overlay=m),"open"in e&&(H.open=C),"placement"in e?H.placement=w:H.placement=n==="rtl"?"bottomLeft":"bottomRight";const z=d.createElement(Ya,{type:a,danger:i,disabled:l,loading:s,onClick:u,htmlType:c,href:E,title:O},f),Y=d.createElement(Ya,{type:a,danger:i,icon:x}),[V,U]=j([z,Y]);return d.createElement(ew.Compact,Object.assign({className:te,size:q,block:!0},M),V,d.createElement(_u,Object.assign({},H),U))};tw.__ANT_BUTTON=!0;const ym=_u;ym.Button=tw;function H0(e,t,r,n){var o=Wi.unstable_batchedUpdates?function(a){Wi.unstable_batchedUpdates(r,a)}:r;return e!=null&&e.addEventListener&&e.addEventListener(t,o,n),{remove:function(){e!=null&&e.removeEventListener&&e.removeEventListener(t,o,n)}}}var _R={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M272.9 512l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L186.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H532c6.7 0 10.4-7.7 6.3-12.9L272.9 512zm304 0l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L490.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H836c6.7 0 10.4-7.7 6.3-12.9L576.9 512z"}}]},name:"double-left",theme:"outlined"},LR=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:_R}))},W0=d.forwardRef(LR),HR={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z"}}]},name:"double-right",theme:"outlined"},WR=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:HR}))},K0=d.forwardRef(WR),KR={items_per_page:"\u6761/\u9875",jump_to:"\u8DF3\u81F3",jump_to_confirm:"\u786E\u5B9A",page:"\u9875",prev_page:"\u4E0A\u4E00\u9875",next_page:"\u4E0B\u4E00\u9875",prev_5:"\u5411\u524D 5 \u9875",next_5:"\u5411\u540E 5 \u9875",prev_3:"\u5411\u524D 3 \u9875",next_3:"\u5411\u540E 3 \u9875",page_size:"\u9875\u7801"},qR=[10,20,50,100],VR=function(e){var t=e.pageSizeOptions,r=t===void 0?qR:t,n=e.locale,o=e.changeSize,a=e.pageSize,i=e.goButton,l=e.quickGo,s=e.rootPrefixCls,u=e.disabled,c=e.buildOptionText,f=e.showSizeChanger,p=e.sizeChangerRender,h=ee.useState(""),v=ce(h,2),g=v[0],m=v[1],b=function(){return!g||Number.isNaN(g)?void 0:Number(g)},y=typeof c=="function"?c:function($){return"".concat($," ").concat(n.items_per_page)},C=function($){m($.target.value)},D=function($){i||g===""||(m(""),!($.relatedTarget&&($.relatedTarget.className.indexOf("".concat(s,"-item-link"))>=0||$.relatedTarget.className.indexOf("".concat(s,"-item"))>=0))&&(l==null||l(b())))},w=function($){g!==""&&($.keyCode===rt.ENTER||$.type==="click")&&(m(""),l==null||l(b()))},k=function(){return r.some(function($){return $.toString()===a.toString()})?r:r.concat([a]).sort(function($,P){var A=Number.isNaN(Number($))?0:Number($),B=Number.isNaN(Number(P))?0:Number(P);return A-B})},E="".concat(s,"-options");if(!f&&!l)return null;var x=null,O=null,j=null;return f&&p&&(x=p({disabled:u,size:a,onSizeChange:function($){o==null||o(Number($))},"aria-label":n.page_size,className:"".concat(E,"-size-changer"),options:k().map(function($){return{label:y($),value:$}})})),l&&(i&&(j=typeof i=="boolean"?ee.createElement("button",{type:"button",onClick:w,onKeyUp:w,disabled:u,className:"".concat(E,"-quick-jumper-button")},n.jump_to_confirm):ee.createElement("span",{onClick:w,onKeyUp:w},i)),O=ee.createElement("div",{className:"".concat(E,"-quick-jumper")},n.jump_to,ee.createElement("input",{disabled:u,type:"text",value:g,onChange:C,onKeyUp:w,onBlur:D,"aria-label":n.page}),n.page,j)),ee.createElement("li",{className:E},x,O)},ki=function(e){var t=e.rootPrefixCls,r=e.page,n=e.active,o=e.className,a=e.showTitle,i=e.onClick,l=e.onKeyPress,s=e.itemRender,u="".concat(t,"-item"),c=pe(u,"".concat(u,"-").concat(r),T(T({},"".concat(u,"-active"),n),"".concat(u,"-disabled"),!r),o),f=function(){i(r)},p=function(v){l(v,i,r)},h=s(r,"page",ee.createElement("a",{rel:"nofollow"},r));return h?ee.createElement("li",{title:a?String(r):null,className:c,onClick:f,onKeyDown:p,tabIndex:0},h):null},GR=function(e,t,r){return r};function q0(){}function V0(e){var t=Number(e);return typeof t=="number"&&!Number.isNaN(t)&&isFinite(t)&&Math.floor(t)===t}function zo(e,t,r){var n=typeof e>"u"?t:e;return Math.floor((r-1)/n)+1}var XR=function(e){var t=e.prefixCls,r=t===void 0?"rc-pagination":t,n=e.selectPrefixCls,o=n===void 0?"rc-select":n,a=e.className,i=e.current,l=e.defaultCurrent,s=l===void 0?1:l,u=e.total,c=u===void 0?0:u,f=e.pageSize,p=e.defaultPageSize,h=p===void 0?10:p,v=e.onChange,g=v===void 0?q0:v,m=e.hideOnSinglePage,b=e.align,y=e.showPrevNextJumpers,C=y===void 0?!0:y,D=e.showQuickJumper,w=e.showLessItems,k=e.showTitle,E=k===void 0?!0:k,x=e.onShowSizeChange,O=x===void 0?q0:x,j=e.locale,$=j===void 0?KR:j,P=e.style,A=e.totalBoundaryShowSizeChanger,B=A===void 0?50:A,S=e.disabled,I=e.simple,N=e.showTotal,F=e.showSizeChanger,M=F===void 0?c>B:F,_=e.sizeChangerRender,X=e.pageSizeOptions,H=e.itemRender,q=H===void 0?GR:H,Z=e.jumpPrevIcon,te=e.jumpNextIcon,z=e.prevIcon,Y=e.nextIcon,V=ee.useRef(null),U=Gr(10,{value:f,defaultValue:h}),K=ce(U,2),W=K[0],re=K[1],G=Gr(1,{value:i,defaultValue:s,postState:function(st){return Math.max(1,Math.min(st,zo(void 0,W,c)))}}),J=ce(G,2),oe=J[0],se=J[1],ge=ee.useState(oe),Ee=ce(ge,2),je=Ee[0],ve=Ee[1];Ot(function(){ve(oe)},[oe]);var ye=Math.max(1,oe-(w?3:5)),ke=Math.min(zo(void 0,W,c),oe+(w?3:5));function we(st,$t){var Bt=st||ee.createElement("button",{type:"button","aria-label":$t,className:"".concat(r,"-item-link")});return typeof st=="function"&&(Bt=ee.createElement(st,L({},e))),Bt}function De(st){var $t=st.target.value,Bt=zo(void 0,W,c),Gt;return $t===""?Gt=$t:Number.isNaN(Number($t))?Gt=je:$t>=Bt?Gt=Bt:Gt=Number($t),Gt}function Ne(st){return V0(st)&&st!==oe&&V0(c)&&c>0}var Oe=c>W?D:!1;function Xe(st){(st.keyCode===rt.UP||st.keyCode===rt.DOWN)&&st.preventDefault()}function Le(st){var $t=De(st);switch($t!==je&&ve($t),st.keyCode){case rt.ENTER:Be($t);break;case rt.UP:Be($t-1);break;case rt.DOWN:Be($t+1);break}}function Fe(st){Be(De(st))}function fe(st){var $t=zo(st,W,c),Bt=oe>$t&&$t!==0?$t:oe;re(st),ve(Bt),O==null||O(oe,st),se(Bt),g==null||g(Bt,st)}function Be(st){if(Ne(st)&&!S){var $t=zo(void 0,W,c),Bt=st;return st>$t?Bt=$t:st<1&&(Bt=1),Bt!==je&&ve(Bt),se(Bt),g==null||g(Bt,W),Bt}return oe}var We=oe>1,Ye=oe<zo(void 0,W,c);function Ve(){We&&Be(oe-1)}function Te(){Ye&&Be(oe+1)}function it(){Be(ye)}function Ue(){Be(ke)}function nt(st,$t){if(st.key==="Enter"||st.charCode===rt.ENTER||st.keyCode===rt.ENTER){for(var Bt=arguments.length,Gt=new Array(Bt>2?Bt-2:0),Mr=2;Mr<Bt;Mr++)Gt[Mr-2]=arguments[Mr];$t.apply(void 0,Gt)}}function pt(st){nt(st,Ve)}function St(st){nt(st,Te)}function dt(st){nt(st,it)}function ht(st){nt(st,Ue)}function Pt(st){var $t=q(st,"prev",we(z,"prev page"));return ee.isValidElement($t)?ee.cloneElement($t,{disabled:!We}):$t}function At(st){var $t=q(st,"next",we(Y,"next page"));return ee.isValidElement($t)?ee.cloneElement($t,{disabled:!Ye}):$t}function ct(st){(st.type==="click"||st.keyCode===rt.ENTER)&&Be(je)}var ut=null,ae=Qn(e,{aria:!0,data:!0}),he=N&&ee.createElement("li",{className:"".concat(r,"-total-text")},N(c,[c===0?0:(oe-1)*W+1,oe*W>c?c:oe*W])),xe=null,be=zo(void 0,W,c);if(m&&c<=W)return null;var Ce=[],de={rootPrefixCls:r,onClick:Be,onKeyPress:nt,showTitle:E,itemRender:q,page:-1},Se=oe-1>0?oe-1:0,le=oe+1<be?oe+1:be,ie=D&&D.goButton,me=at(I)==="object"?I.readOnly:!I,ze=ie,_e=null;I&&(ie&&(typeof ie=="boolean"?ze=ee.createElement("button",{type:"button",onClick:ct,onKeyUp:ct},$.jump_to_confirm):ze=ee.createElement("span",{onClick:ct,onKeyUp:ct},ie),ze=ee.createElement("li",{title:E?"".concat($.jump_to).concat(oe,"/").concat(be):null,className:"".concat(r,"-simple-pager")},ze)),_e=ee.createElement("li",{title:E?"".concat(oe,"/").concat(be):null,className:"".concat(r,"-simple-pager")},me?je:ee.createElement("input",{type:"text","aria-label":$.jump_to,value:je,disabled:S,onKeyDown:Xe,onKeyUp:Le,onChange:Le,onBlur:Fe,size:3}),ee.createElement("span",{className:"".concat(r,"-slash")},"/"),be));var Ke=w?1:2;if(be<=3+Ke*2){be||Ce.push(ee.createElement(ki,Me({},de,{key:"noPager",page:1,className:"".concat(r,"-item-disabled")})));for(var Pe=1;Pe<=be;Pe+=1)Ce.push(ee.createElement(ki,Me({},de,{key:Pe,page:Pe,active:oe===Pe})))}else{var Ze=w?$.prev_3:$.prev_5,wt=w?$.next_3:$.next_5,jt=q(ye,"jump-prev",we(Z,"prev page")),It=q(ke,"jump-next",we(te,"next page"));C&&(ut=jt?ee.createElement("li",{title:E?Ze:null,key:"prev",onClick:it,tabIndex:0,onKeyDown:dt,className:pe("".concat(r,"-jump-prev"),T({},"".concat(r,"-jump-prev-custom-icon"),!!Z))},jt):null,xe=It?ee.createElement("li",{title:E?wt:null,key:"next",onClick:Ue,tabIndex:0,onKeyDown:ht,className:pe("".concat(r,"-jump-next"),T({},"".concat(r,"-jump-next-custom-icon"),!!te))},It):null);var Et=Math.max(1,oe-Ke),Jt=Math.min(oe+Ke,be);oe-1<=Ke&&(Jt=1+Ke*2),be-oe<=Ke&&(Et=be-Ke*2);for(var pr=Et;pr<=Jt;pr+=1)Ce.push(ee.createElement(ki,Me({},de,{key:pr,page:pr,active:oe===pr})));if(oe-1>=Ke*2&&oe!==3&&(Ce[0]=ee.cloneElement(Ce[0],{className:pe("".concat(r,"-item-after-jump-prev"),Ce[0].props.className)}),Ce.unshift(ut)),be-oe>=Ke*2&&oe!==be-2){var He=Ce[Ce.length-1];Ce[Ce.length-1]=ee.cloneElement(He,{className:pe("".concat(r,"-item-before-jump-next"),He.props.className)}),Ce.push(xe)}Et!==1&&Ce.unshift(ee.createElement(ki,Me({},de,{key:1,page:1}))),Jt!==be&&Ce.push(ee.createElement(ki,Me({},de,{key:be,page:be})))}var Qe=Pt(Se);if(Qe){var gt=!We||!be;Qe=ee.createElement("li",{title:E?$.prev_page:null,onClick:Ve,tabIndex:gt?null:0,onKeyDown:pt,className:pe("".concat(r,"-prev"),T({},"".concat(r,"-disabled"),gt)),"aria-disabled":gt},Qe)}var Mt=At(le);if(Mt){var Ft,yr;I?(Ft=!Ye,yr=We?0:null):(Ft=!Ye||!be,yr=Ft?null:0),Mt=ee.createElement("li",{title:E?$.next_page:null,onClick:Te,tabIndex:yr,onKeyDown:St,className:pe("".concat(r,"-next"),T({},"".concat(r,"-disabled"),Ft)),"aria-disabled":Ft},Mt)}var Cr=pe(r,a,T(T(T(T(T({},"".concat(r,"-start"),b==="start"),"".concat(r,"-center"),b==="center"),"".concat(r,"-end"),b==="end"),"".concat(r,"-simple"),I),"".concat(r,"-disabled"),S));return ee.createElement("ul",Me({className:Cr,style:P,ref:V},ae),he,Qe,I?_e:Ce,Mt,ee.createElement(VR,{locale:$,rootPrefixCls:r,disabled:S,selectPrefixCls:o,changeSize:fe,pageSize:W,pageSizeOptions:X,quickGo:Oe?Be:null,goButton:ze,showSizeChanger:M,sizeChangerRender:_}))};const UR=e=>{const{componentCls:t}=e;return{[`${t}-disabled`]:{"&, &:hover":{cursor:"not-allowed",[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed"}},"&:focus-visible":{cursor:"not-allowed",[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed"}}},[`&${t}-disabled`]:{cursor:"not-allowed",[`${t}-item`]:{cursor:"not-allowed",backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"},a:{color:e.colorTextDisabled,backgroundColor:"transparent",border:"none",cursor:"not-allowed"},"&-active":{borderColor:e.colorBorder,backgroundColor:e.itemActiveBgDisabled,"&:hover, &:active":{backgroundColor:e.itemActiveBgDisabled},a:{color:e.itemActiveColorDisabled}}},[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed","&:hover, &:active":{backgroundColor:"transparent"},[`${t}-simple&`]:{backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"}}},[`${t}-simple-pager`]:{color:e.colorTextDisabled},[`${t}-jump-prev, ${t}-jump-next`]:{[`${t}-item-link-icon`]:{opacity:0},[`${t}-item-ellipsis`]:{opacity:1}}}}},YR=e=>{const{componentCls:t}=e;return{[`&${t}-mini ${t}-total-text, &${t}-mini ${t}-simple-pager`]:{height:e.itemSizeSM,lineHeight:ue(e.itemSizeSM)},[`&${t}-mini ${t}-item`]:{minWidth:e.itemSizeSM,height:e.itemSizeSM,margin:0,lineHeight:ue(e.calc(e.itemSizeSM).sub(2).equal())},[`&${t}-mini ${t}-prev, &${t}-mini ${t}-next`]:{minWidth:e.itemSizeSM,height:e.itemSizeSM,margin:0,lineHeight:ue(e.itemSizeSM)},[`&${t}-mini:not(${t}-disabled)`]:{[`${t}-prev, ${t}-next`]:{[`&:hover ${t}-item-link`]:{backgroundColor:e.colorBgTextHover},[`&:active ${t}-item-link`]:{backgroundColor:e.colorBgTextActive},[`&${t}-disabled:hover ${t}-item-link`]:{backgroundColor:"transparent"}}},[`
|
|
375
|
+
&${t}-mini ${t}-prev ${t}-item-link,
|
|
376
|
+
&${t}-mini ${t}-next ${t}-item-link
|
|
377
|
+
`]:{backgroundColor:"transparent",borderColor:"transparent","&::after":{height:e.itemSizeSM,lineHeight:ue(e.itemSizeSM)}},[`&${t}-mini ${t}-jump-prev, &${t}-mini ${t}-jump-next`]:{height:e.itemSizeSM,marginInlineEnd:0,lineHeight:ue(e.itemSizeSM)},[`&${t}-mini ${t}-options`]:{marginInlineStart:e.paginationMiniOptionsMarginInlineStart,"&-size-changer":{top:e.miniOptionsSizeChangerTop},"&-quick-jumper":{height:e.itemSizeSM,lineHeight:ue(e.itemSizeSM),input:Object.assign(Object.assign({},gm(e)),{width:e.paginationMiniQuickJumperInputWidth,height:e.controlHeightSM})}}}},ZR=e=>{const{componentCls:t}=e;return{[`&${t}-simple`]:{[`${t}-prev, ${t}-next`]:{height:e.itemSize,lineHeight:ue(e.itemSize),verticalAlign:"top",[`${t}-item-link`]:{height:e.itemSize,backgroundColor:"transparent",border:0,"&:hover":{backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive},"&::after":{height:e.itemSize,lineHeight:ue(e.itemSize)}}},[`${t}-simple-pager`]:{display:"inline-flex",alignItems:"center",height:e.itemSize,marginInlineEnd:e.marginXS,input:{boxSizing:"border-box",height:"100%",width:e.quickJumperInputWidth,padding:`0 ${ue(e.paginationItemPaddingInline)}`,textAlign:"center",backgroundColor:e.itemInputBg,border:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadius,outline:"none",transition:`border-color ${e.motionDurationMid}`,color:"inherit","&:hover":{borderColor:e.colorPrimary},"&:focus":{borderColor:e.colorPrimaryHover,boxShadow:`${ue(e.inputOutlineOffset)} 0 ${ue(e.controlOutlineWidth)} ${e.controlOutline}`},"&[disabled]":{color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,cursor:"not-allowed"}}},[`&${t}-disabled`]:{[`${t}-prev, ${t}-next`]:{[`${t}-item-link`]:{"&:hover, &:active":{backgroundColor:"transparent"}}}},[`&${t}-mini`]:{[`${t}-prev, ${t}-next`]:{height:e.itemSizeSM,lineHeight:ue(e.itemSizeSM),[`${t}-item-link`]:{height:e.itemSizeSM,"&::after":{height:e.itemSizeSM,lineHeight:ue(e.itemSizeSM)}}},[`${t}-simple-pager`]:{height:e.itemSizeSM,width:e.paginationMiniQuickJumperInputWidth}}}}},JR=e=>{const{componentCls:t}=e;return{[`${t}-jump-prev, ${t}-jump-next`]:{outline:0,[`${t}-item-container`]:{position:"relative",[`${t}-item-link-icon`]:{color:e.colorPrimary,fontSize:e.fontSizeSM,opacity:0,transition:`all ${e.motionDurationMid}`,"&-svg":{top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,margin:"auto"}},[`${t}-item-ellipsis`]:{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,display:"block",margin:"auto",color:e.colorTextDisabled,letterSpacing:e.paginationEllipsisLetterSpacing,textAlign:"center",textIndent:e.paginationEllipsisTextIndent,opacity:1,transition:`all ${e.motionDurationMid}`}},"&:hover":{[`${t}-item-link-icon`]:{opacity:1},[`${t}-item-ellipsis`]:{opacity:0}}},[`
|
|
378
|
+
${t}-prev,
|
|
379
|
+
${t}-jump-prev,
|
|
380
|
+
${t}-jump-next
|
|
381
|
+
`]:{marginInlineEnd:e.marginXS},[`
|
|
382
|
+
${t}-prev,
|
|
383
|
+
${t}-next,
|
|
384
|
+
${t}-jump-prev,
|
|
385
|
+
${t}-jump-next
|
|
386
|
+
`]:{display:"inline-block",minWidth:e.itemSize,height:e.itemSize,color:e.colorText,fontFamily:e.fontFamily,lineHeight:ue(e.itemSize),textAlign:"center",verticalAlign:"middle",listStyle:"none",borderRadius:e.borderRadius,cursor:"pointer",transition:`all ${e.motionDurationMid}`},[`${t}-prev, ${t}-next`]:{outline:0,button:{color:e.colorText,cursor:"pointer",userSelect:"none"},[`${t}-item-link`]:{display:"block",width:"100%",height:"100%",padding:0,fontSize:e.fontSizeSM,textAlign:"center",backgroundColor:"transparent",border:`${ue(e.lineWidth)} ${e.lineType} transparent`,borderRadius:e.borderRadius,outline:"none",transition:`all ${e.motionDurationMid}`},[`&:hover ${t}-item-link`]:{backgroundColor:e.colorBgTextHover},[`&:active ${t}-item-link`]:{backgroundColor:e.colorBgTextActive},[`&${t}-disabled:hover`]:{[`${t}-item-link`]:{backgroundColor:"transparent"}}},[`${t}-slash`]:{marginInlineEnd:e.paginationSlashMarginInlineEnd,marginInlineStart:e.paginationSlashMarginInlineStart},[`${t}-options`]:{display:"inline-block",marginInlineStart:e.margin,verticalAlign:"middle","&-size-changer":{display:"inline-block",width:"auto"},"&-quick-jumper":{display:"inline-block",height:e.controlHeight,marginInlineStart:e.marginXS,lineHeight:ue(e.controlHeight),verticalAlign:"top",input:Object.assign(Object.assign(Object.assign({},vm(e)),hm(e,{borderColor:e.colorBorder,hoverBorderColor:e.colorPrimaryHover,activeBorderColor:e.colorPrimary,activeShadow:e.activeShadow})),{"&[disabled]":Object.assign({},Lu(e)),width:e.quickJumperInputWidth,height:e.controlHeight,boxSizing:"border-box",margin:0,marginInlineStart:e.marginXS,marginInlineEnd:e.marginXS})}}}},QR=e=>{const{componentCls:t}=e;return{[`${t}-item`]:{display:"inline-block",minWidth:e.itemSize,height:e.itemSize,marginInlineEnd:e.marginXS,fontFamily:e.fontFamily,lineHeight:ue(e.calc(e.itemSize).sub(2).equal()),textAlign:"center",verticalAlign:"middle",listStyle:"none",backgroundColor:e.itemBg,border:`${ue(e.lineWidth)} ${e.lineType} transparent`,borderRadius:e.borderRadius,outline:0,cursor:"pointer",userSelect:"none",a:{display:"block",padding:`0 ${ue(e.paginationItemPaddingInline)}`,color:e.colorText,"&:hover":{textDecoration:"none"}},[`&:not(${t}-item-active)`]:{"&:hover":{transition:`all ${e.motionDurationMid}`,backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive}},"&-active":{fontWeight:e.fontWeightStrong,backgroundColor:e.itemActiveBg,borderColor:e.colorPrimary,a:{color:e.colorPrimary},"&:hover":{borderColor:e.colorPrimaryHover},"&:hover a":{color:e.colorPrimaryHover}}}}},e8=e=>{const{componentCls:t}=e;return{[t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Br(e)),{display:"flex","&-start":{justifyContent:"start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"end"},"ul, ol":{margin:0,padding:0,listStyle:"none"},"&::after":{display:"block",clear:"both",height:0,overflow:"hidden",visibility:"hidden",content:'""'},[`${t}-total-text`]:{display:"inline-block",height:e.itemSize,marginInlineEnd:e.marginXS,lineHeight:ue(e.calc(e.itemSize).sub(2).equal()),verticalAlign:"middle"}}),QR(e)),JR(e)),ZR(e)),YR(e)),UR(e)),{[`@media only screen and (max-width: ${e.screenLG}px)`]:{[`${t}-item`]:{"&-after-jump-prev, &-before-jump-next":{display:"none"}}},[`@media only screen and (max-width: ${e.screenSM}px)`]:{[`${t}-options`]:{display:"none"}}}),[`&${e.componentCls}-rtl`]:{direction:"rtl"}}},t8=e=>{const{componentCls:t}=e;return{[`${t}:not(${t}-disabled)`]:{[`${t}-item`]:Object.assign({},cl(e)),[`${t}-jump-prev, ${t}-jump-next`]:{"&:focus-visible":Object.assign({[`${t}-item-link-icon`]:{opacity:1},[`${t}-item-ellipsis`]:{opacity:0}},Po(e))},[`${t}-prev, ${t}-next`]:{[`&:focus-visible ${t}-item-link`]:Po(e)}}}},rw=e=>Object.assign({itemBg:e.colorBgContainer,itemSize:e.controlHeight,itemSizeSM:e.controlHeightSM,itemActiveBg:e.colorBgContainer,itemLinkBg:e.colorBgContainer,itemActiveColorDisabled:e.colorTextDisabled,itemActiveBgDisabled:e.controlItemBgActiveDisabled,itemInputBg:e.colorBgContainer,miniOptionsSizeChangerTop:0},mm(e)),nw=e=>er(e,{inputOutlineOffset:0,quickJumperInputWidth:e.calc(e.controlHeightLG).mul(1.25).equal(),paginationMiniOptionsMarginInlineStart:e.calc(e.marginXXS).div(2).equal(),paginationMiniQuickJumperInputWidth:e.calc(e.controlHeightLG).mul(1.1).equal(),paginationItemPaddingInline:e.calc(e.marginXXS).mul(1.5).equal(),paginationEllipsisLetterSpacing:e.calc(e.marginXXS).div(2).equal(),paginationSlashMarginInlineStart:e.marginSM,paginationSlashMarginInlineEnd:e.marginSM,paginationEllipsisTextIndent:"0.13em"},pm(e)),r8=Hr("Pagination",e=>{const t=nw(e);return[e8(t),t8(t)]},rw),n8=e=>{const{componentCls:t}=e;return{[`${t}${t}-bordered${t}-disabled:not(${t}-mini)`]:{"&, &:hover":{[`${t}-item-link`]:{borderColor:e.colorBorder}},"&:focus-visible":{[`${t}-item-link`]:{borderColor:e.colorBorder}},[`${t}-item, ${t}-item-link`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,[`&:hover:not(${t}-item-active)`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,a:{color:e.colorTextDisabled}},[`&${t}-item-active`]:{backgroundColor:e.itemActiveBgDisabled}},[`${t}-prev, ${t}-next`]:{"&:hover button":{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,color:e.colorTextDisabled},[`${t}-item-link`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder}}},[`${t}${t}-bordered:not(${t}-mini)`]:{[`${t}-prev, ${t}-next`]:{"&:hover button":{borderColor:e.colorPrimaryHover,backgroundColor:e.itemBg},[`${t}-item-link`]:{backgroundColor:e.itemLinkBg,borderColor:e.colorBorder},[`&:hover ${t}-item-link`]:{borderColor:e.colorPrimary,backgroundColor:e.itemBg,color:e.colorPrimary},[`&${t}-disabled`]:{[`${t}-item-link`]:{borderColor:e.colorBorder,color:e.colorTextDisabled}}},[`${t}-item`]:{backgroundColor:e.itemBg,border:`${ue(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,[`&:hover:not(${t}-item-active)`]:{borderColor:e.colorPrimary,backgroundColor:e.itemBg,a:{color:e.colorPrimary}},"&-active":{borderColor:e.colorPrimary}}}}},o8=J1(["Pagination","bordered"],e=>{const t=nw(e);return n8(t)},rw);function G0(e){return xt(()=>typeof e=="boolean"?[e,{}]:e&&typeof e=="object"?[!0,e]:[void 0,void 0],[e])}var a8=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const ow=e=>{const{align:t,prefixCls:r,selectPrefixCls:n,className:o,rootClassName:a,style:i,size:l,locale:s,responsive:u,showSizeChanger:c,selectComponentClass:f,pageSizeOptions:p}=e,h=a8(e,["align","prefixCls","selectPrefixCls","className","rootClassName","style","size","locale","responsive","showSizeChanger","selectComponentClass","pageSizeOptions"]),{xs:v}=dx(u),[,g]=Yr(),{getPrefixCls:m,direction:b,showSizeChanger:y,className:C,style:D}=Ro("pagination"),w=m("pagination",r),[k,E,x]=r8(w),O=fa(l),j=O==="small"||!!(v&&!O&&u),[$]=xu("Pagination",T1),P=Object.assign(Object.assign({},$),s),[A,B]=G0(c),[S,I]=G0(y),N=A??S,F=B??I,M=f||li,_=d.useMemo(()=>p?p.map(z=>Number(z)):void 0,[p]),X=z=>{var Y;const{disabled:V,size:U,onSizeChange:K,"aria-label":W,className:re,options:G}=z,{className:J,onChange:oe}=F||{},se=(Y=G.find(ge=>String(ge.value)===String(U)))===null||Y===void 0?void 0:Y.value;return d.createElement(M,Object.assign({disabled:V,showSearch:!0,popupMatchSelectWidth:!1,getPopupContainer:ge=>ge.parentNode,"aria-label":W,options:G},F,{value:se,onChange:(ge,Ee)=>{K==null||K(ge),oe==null||oe(ge,Ee)},size:j?"small":"middle",className:pe(re,J)}))},H=d.useMemo(()=>{const z=d.createElement("span",{className:`${w}-item-ellipsis`},"\u2022\u2022\u2022"),Y=d.createElement("button",{className:`${w}-item-link`,type:"button",tabIndex:-1},b==="rtl"?d.createElement(vf,null):d.createElement(If,null)),V=d.createElement("button",{className:`${w}-item-link`,type:"button",tabIndex:-1},b==="rtl"?d.createElement(If,null):d.createElement(vf,null)),U=d.createElement("a",{className:`${w}-item-link`},d.createElement("div",{className:`${w}-item-container`},b==="rtl"?d.createElement(K0,{className:`${w}-item-link-icon`}):d.createElement(W0,{className:`${w}-item-link-icon`}),z)),K=d.createElement("a",{className:`${w}-item-link`},d.createElement("div",{className:`${w}-item-container`},b==="rtl"?d.createElement(W0,{className:`${w}-item-link-icon`}):d.createElement(K0,{className:`${w}-item-link-icon`}),z));return{prevIcon:Y,nextIcon:V,jumpPrevIcon:U,jumpNextIcon:K}},[b,w]),q=m("select",n),Z=pe({[`${w}-${t}`]:!!t,[`${w}-mini`]:j,[`${w}-rtl`]:b==="rtl",[`${w}-bordered`]:g.wireframe},C,o,a,E,x),te=Object.assign(Object.assign({},D),i);return k(d.createElement(d.Fragment,null,g.wireframe&&d.createElement(o8,{prefixCls:w}),d.createElement(XR,Object.assign({},H,h,{style:te,prefixCls:w,selectPrefixCls:q,className:Z,locale:P,pageSizeOptions:_,showSizeChanger:N,sizeChangerRender:X}))))},Qs=100,aw=Qs/5,iw=Qs/2-aw/2,ed=iw*2*Math.PI,X0=50,U0=e=>{const{dotClassName:t,style:r,hasCircleCls:n}=e;return d.createElement("circle",{className:pe(`${t}-circle`,{[`${t}-circle-bg`]:n}),r:iw,cx:X0,cy:X0,strokeWidth:aw,style:r})},i8=({percent:e,prefixCls:t})=>{const r=`${t}-dot`,n=`${r}-holder`,o=`${n}-hidden`,[a,i]=d.useState(!1);Wt(()=>{e!==0&&i(!0)},[e!==0]);const l=Math.max(Math.min(e,100),0);if(!a)return null;const s={strokeDashoffset:`${ed/4}`,strokeDasharray:`${ed*l/100} ${ed*(100-l)/100}`};return d.createElement("span",{className:pe(n,`${r}-progress`,l<=0&&o)},d.createElement("svg",{viewBox:`0 0 ${Qs} ${Qs}`,role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":l},d.createElement(U0,{dotClassName:r,hasCircleCls:!0}),d.createElement(U0,{dotClassName:r,style:s})))};function l8(e){const{prefixCls:t,percent:r=0}=e,n=`${t}-dot`,o=`${n}-holder`,a=`${o}-hidden`;return d.createElement(d.Fragment,null,d.createElement("span",{className:pe(o,r>0&&a)},d.createElement("span",{className:pe(n,`${t}-dot-spin`)},[1,2,3,4].map(i=>d.createElement("i",{className:`${t}-dot-item`,key:i})))),d.createElement(i8,{prefixCls:t,percent:r}))}function s8(e){var t;const{prefixCls:r,indicator:n,percent:o}=e,a=`${r}-dot`;return n&&d.isValidElement(n)?eo(n,{className:pe((t=n.props)===null||t===void 0?void 0:t.className,a),percent:o}):d.createElement(l8,{prefixCls:r,percent:o})}const u8=new Vt("antSpinMove",{to:{opacity:1}}),c8=new Vt("antRotate",{to:{transform:"rotate(405deg)"}}),d8=e=>{const{componentCls:t,calc:r}=e;return{[t]:Object.assign(Object.assign({},Br(e)),{position:"absolute",display:"none",color:e.colorPrimary,fontSize:0,textAlign:"center",verticalAlign:"middle",opacity:0,transition:`transform ${e.motionDurationSlow} ${e.motionEaseInOutCirc}`,"&-spinning":{position:"relative",display:"inline-block",opacity:1},[`${t}-text`]:{fontSize:e.fontSize,paddingTop:r(r(e.dotSize).sub(e.fontSize)).div(2).add(2).equal()},"&-fullscreen":{position:"fixed",width:"100vw",height:"100vh",backgroundColor:e.colorBgMask,zIndex:e.zIndexPopupBase,inset:0,display:"flex",alignItems:"center",flexDirection:"column",justifyContent:"center",opacity:0,visibility:"hidden",transition:`all ${e.motionDurationMid}`,"&-show":{opacity:1,visibility:"visible"},[t]:{[`${t}-dot-holder`]:{color:e.colorWhite},[`${t}-text`]:{color:e.colorTextLightSolid}}},"&-nested-loading":{position:"relative",[`> div > ${t}`]:{position:"absolute",top:0,insetInlineStart:0,zIndex:4,display:"block",width:"100%",height:"100%",maxHeight:e.contentHeight,[`${t}-dot`]:{position:"absolute",top:"50%",insetInlineStart:"50%",margin:r(e.dotSize).mul(-1).div(2).equal()},[`${t}-text`]:{position:"absolute",top:"50%",width:"100%",textShadow:`0 1px 2px ${e.colorBgContainer}`},[`&${t}-show-text ${t}-dot`]:{marginTop:r(e.dotSize).div(2).mul(-1).sub(10).equal()},"&-sm":{[`${t}-dot`]:{margin:r(e.dotSizeSM).mul(-1).div(2).equal()},[`${t}-text`]:{paddingTop:r(r(e.dotSizeSM).sub(e.fontSize)).div(2).add(2).equal()},[`&${t}-show-text ${t}-dot`]:{marginTop:r(e.dotSizeSM).div(2).mul(-1).sub(10).equal()}},"&-lg":{[`${t}-dot`]:{margin:r(e.dotSizeLG).mul(-1).div(2).equal()},[`${t}-text`]:{paddingTop:r(r(e.dotSizeLG).sub(e.fontSize)).div(2).add(2).equal()},[`&${t}-show-text ${t}-dot`]:{marginTop:r(e.dotSizeLG).div(2).mul(-1).sub(10).equal()}}},[`${t}-container`]:{position:"relative",transition:`opacity ${e.motionDurationSlow}`,"&::after":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,zIndex:10,width:"100%",height:"100%",background:e.colorBgContainer,opacity:0,transition:`all ${e.motionDurationSlow}`,content:'""',pointerEvents:"none"}},[`${t}-blur`]:{clear:"both",opacity:.5,userSelect:"none",pointerEvents:"none","&::after":{opacity:.4,pointerEvents:"auto"}}},"&-tip":{color:e.spinDotDefault},[`${t}-dot-holder`]:{width:"1em",height:"1em",fontSize:e.dotSize,display:"inline-block",transition:`transform ${e.motionDurationSlow} ease, opacity ${e.motionDurationSlow} ease`,transformOrigin:"50% 50%",lineHeight:1,color:e.colorPrimary,"&-hidden":{transform:"scale(0.3)",opacity:0}},[`${t}-dot-progress`]:{position:"absolute",inset:0},[`${t}-dot`]:{position:"relative",display:"inline-block",fontSize:e.dotSize,width:"1em",height:"1em","&-item":{position:"absolute",display:"block",width:r(e.dotSize).sub(r(e.marginXXS).div(2)).div(2).equal(),height:r(e.dotSize).sub(r(e.marginXXS).div(2)).div(2).equal(),background:"currentColor",borderRadius:"100%",transform:"scale(0.75)",transformOrigin:"50% 50%",opacity:.3,animationName:u8,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear",animationDirection:"alternate","&:nth-child(1)":{top:0,insetInlineStart:0,animationDelay:"0s"},"&:nth-child(2)":{top:0,insetInlineEnd:0,animationDelay:"0.4s"},"&:nth-child(3)":{insetInlineEnd:0,bottom:0,animationDelay:"0.8s"},"&:nth-child(4)":{bottom:0,insetInlineStart:0,animationDelay:"1.2s"}},"&-spin":{transform:"rotate(45deg)",animationName:c8,animationDuration:"1.2s",animationIterationCount:"infinite",animationTimingFunction:"linear"},"&-circle":{strokeLinecap:"round",transition:["stroke-dashoffset","stroke-dasharray","stroke","stroke-width","opacity"].map(n=>`${n} ${e.motionDurationSlow} ease`).join(","),fillOpacity:0,stroke:"currentcolor"},"&-circle-bg":{stroke:e.colorFillSecondary}},[`&-sm ${t}-dot`]:{"&, &-holder":{fontSize:e.dotSizeSM}},[`&-sm ${t}-dot-holder`]:{i:{width:r(r(e.dotSizeSM).sub(r(e.marginXXS).div(2))).div(2).equal(),height:r(r(e.dotSizeSM).sub(r(e.marginXXS).div(2))).div(2).equal()}},[`&-lg ${t}-dot`]:{"&, &-holder":{fontSize:e.dotSizeLG}},[`&-lg ${t}-dot-holder`]:{i:{width:r(r(e.dotSizeLG).sub(e.marginXXS)).div(2).equal(),height:r(r(e.dotSizeLG).sub(e.marginXXS)).div(2).equal()}},[`&${t}-show-text ${t}-text`]:{display:"block"}})}},f8=e=>{const{controlHeightLG:t,controlHeight:r}=e;return{contentHeight:400,dotSize:t/2,dotSizeSM:t*.35,dotSizeLG:r}},p8=Hr("Spin",e=>{const t=er(e,{spinDotDefault:e.colorTextDescription});return d8(t)},f8),m8=200,Y0=[[30,.05],[70,.03],[96,.01]];function h8(e,t){const[r,n]=d.useState(0),o=d.useRef(null),a=t==="auto";return d.useEffect(()=>(a&&e&&(n(0),o.current=setInterval(()=>{n(i=>{const l=100-i;for(let s=0;s<Y0.length;s+=1){const[u,c]=Y0[s];if(i<=u)return i+l*c}return i})},m8)),()=>{clearInterval(o.current)}),[a,e]),a?r:t}var g8=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};let lw;function v8(e,t){return!!e&&!!t&&!Number.isNaN(Number(t))}const Cm=e=>{var t;const{prefixCls:r,spinning:n=!0,delay:o=0,className:a,rootClassName:i,size:l="default",tip:s,wrapperClassName:u,style:c,children:f,fullscreen:p=!1,indicator:h,percent:v}=e,g=g8(e,["prefixCls","spinning","delay","className","rootClassName","size","tip","wrapperClassName","style","children","fullscreen","indicator","percent"]),{getPrefixCls:m,direction:b,className:y,style:C,indicator:D}=Ro("spin"),w=m("spin",r),[k,E,x]=p8(w),[O,j]=d.useState(()=>n&&!v8(n,o)),$=h8(O,v);d.useEffect(()=>{if(n){const F=cR(o,()=>{j(!0)});return F(),()=>{var M;(M=F==null?void 0:F.cancel)===null||M===void 0||M.call(F)}}j(!1)},[o,n]);const P=d.useMemo(()=>typeof f<"u"&&!p,[f,p]),A=pe(w,y,{[`${w}-sm`]:l==="small",[`${w}-lg`]:l==="large",[`${w}-spinning`]:O,[`${w}-show-text`]:!!s,[`${w}-rtl`]:b==="rtl"},a,!p&&i,E,x),B=pe(`${w}-container`,{[`${w}-blur`]:O}),S=(t=h??D)!==null&&t!==void 0?t:lw,I=Object.assign(Object.assign({},C),c),N=d.createElement("div",Object.assign({},g,{style:I,className:A,"aria-live":"polite","aria-busy":O}),d.createElement(s8,{prefixCls:w,indicator:S,percent:$}),s&&(P||p)?d.createElement("div",{className:`${w}-text`},s):null);return k(P?d.createElement("div",Object.assign({},g,{className:pe(`${w}-nested-loading`,u,E,x)}),O&&d.createElement("div",{key:"loading"},N),d.createElement("div",{className:B,key:"container"},f)):p?d.createElement("div",{className:pe(`${w}-fullscreen`,{[`${w}-fullscreen-show`]:O},i,E,x)},N):N)};Cm.setDefaultIndicator=e=>{lw=e};var b8={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"filled"},y8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:b8}))},C8=d.forwardRef(y8),x8={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"outlined"},w8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:x8}))},E8=d.forwardRef(w8),k8={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M858.9 689L530.5 308.2c-9.4-10.9-27.5-10.9-37 0L165.1 689c-12.2 14.2-1.2 35 18.5 35h656.8c19.7 0 30.7-20.8 18.5-35z"}}]},name:"caret-up",theme:"outlined"},D8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:k8}))},S8=d.forwardRef(D8),$8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494z"}}]},name:"file",theme:"outlined"},B8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:$8}))},sw=d.forwardRef(B8),O8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M349 838c0 17.7 14.2 32 31.8 32h262.4c17.6 0 31.8-14.3 31.8-32V642H349v196zm531.1-684H143.9c-24.5 0-39.8 26.7-27.5 48l221.3 376h348.8l221.3-376c12.1-21.3-3.2-48-27.7-48z"}}]},name:"filter",theme:"filled"},A8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:O8}))},F8=d.forwardRef(A8),N8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 444H820V330.4c0-17.7-14.3-32-32-32H473L355.7 186.2a8.15 8.15 0 00-5.5-2.2H96c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h698c13 0 24.8-7.9 29.7-20l134-332c1.5-3.8 2.3-7.9 2.3-12 0-17.7-14.3-32-32-32zM136 256h188.5l119.6 114.4H748V444H238c-13 0-24.8 7.9-29.7 20L136 643.2V256zm635.3 512H159l103.3-256h612.4L771.3 768z"}}]},name:"folder-open",theme:"outlined"},P8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:N8}))},j8=d.forwardRef(P8),I8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M880 298.4H521L403.7 186.2a8.15 8.15 0 00-5.5-2.2H144c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V330.4c0-17.7-14.3-32-32-32zM840 768H184V256h188.5l119.6 114.4H840V768z"}}]},name:"folder",theme:"outlined"},R8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:I8}))},M8=d.forwardRef(R8),T8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M300 276.5a56 56 0 1056-97 56 56 0 00-56 97zm0 284a56 56 0 1056-97 56 56 0 00-56 97zM640 228a56 56 0 10112 0 56 56 0 00-112 0zm0 284a56 56 0 10112 0 56 56 0 00-112 0zM300 844.5a56 56 0 1056-97 56 56 0 00-56 97zM640 796a56 56 0 10112 0 56 56 0 00-112 0z"}}]},name:"holder",theme:"outlined"},z8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:T8}))},_8=d.forwardRef(z8),L8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"minus-square",theme:"outlined"},H8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:L8}))},W8=d.forwardRef(H8),K8={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"plus-square",theme:"outlined"},q8=function(e,t){return d.createElement(sr,Me({},e,{ref:t,icon:K8}))},V8=d.forwardRef(q8),co={},Ol="rc-table-internal-hook";function xm(e){var t=d.createContext(void 0),r=function(n){var o=n.value,a=n.children,i=d.useRef(o);i.current=o;var l=d.useState(function(){return{getValue:function(){return i.current},listeners:new Set}}),s=ce(l,1),u=s[0];return Wt(function(){Nb(function(){u.listeners.forEach(function(c){c(o)})})},[o]),d.createElement(t.Provider,{value:u},a)};return{Context:t,Provider:r,defaultValue:e}}function Lr(e,t){var r=nr(typeof t=="function"?t:function(f){if(t===void 0)return f;if(!Array.isArray(t))return f[t];var p={};return t.forEach(function(h){p[h]=f[h]}),p}),n=d.useContext(e==null?void 0:e.Context),o=n||{},a=o.listeners,i=o.getValue,l=d.useRef();l.current=r(n?i():e==null?void 0:e.defaultValue);var s=d.useState({}),u=ce(s,2),c=u[1];return Wt(function(){if(!n)return;function f(p){var h=r(p);Jn(l.current,h,!0)||c({})}return a.add(f),function(){a.delete(f)}},[n]),l.current}function G8(){var e=d.createContext(null);function t(){return d.useContext(e)}function r(o,a){var i=Zn(o),l=function(s,u){var c=i?{ref:u}:{},f=d.useRef(0),p=d.useRef(s),h=t();return h!==null?d.createElement(o,Me({},s,c)):((!a||a(p.current,s))&&(f.current+=1),p.current=s,d.createElement(e.Provider,{value:f.current},d.createElement(o,Me({},s,c))))};return i?d.forwardRef(l):l}function n(o,a){var i=Zn(o),l=function(s,u){var c=i?{ref:u}:{};return t(),d.createElement(o,Me({},s,c))};return i?d.memo(d.forwardRef(l),a):d.memo(l,a)}return{makeImmutable:r,responseImmutable:n,useImmutableMark:t}}var wm=G8(),uw=wm.makeImmutable,ci=wm.responseImmutable,X8=wm.useImmutableMark,nn=xm(),cw=d.createContext({renderWithProps:!1}),U8="RC_TABLE_KEY";function Y8(e){return e==null?[]:Array.isArray(e)?e:[e]}function Hu(e){var t=[],r={};return e.forEach(function(n){for(var o=n||{},a=o.key,i=o.dataIndex,l=a||Y8(i).join("-")||U8;r[l];)l="".concat(l,"_next");r[l]=!0,t.push(l)}),t}function Wf(e){return e!=null}function Z8(e){return typeof e=="number"&&!Number.isNaN(e)}function J8(e){return e&&at(e)==="object"&&!Array.isArray(e)&&!d.isValidElement(e)}function Q8(e,t,r,n,o,a){var i=d.useContext(cw),l=X8(),s=la(function(){if(Wf(n))return[n];var u=t==null||t===""?[]:Array.isArray(t)?t:[t],c=vn(e,u),f=c,p=void 0;if(o){var h=o(c,e,r);J8(h)?(f=h.children,p=h.props,i.renderWithProps=!0):f=h}return[f,p]},[l,e,n,t,o,r],function(u,c){if(a){var f=ce(u,2),p=f[1],h=ce(c,2),v=h[1];return a(v,p)}return i.renderWithProps?!0:!Jn(u,c,!0)});return s}function eM(e,t,r,n){var o=e+t-1;return e<=n&&o>=r}function tM(e,t){return Lr(nn,function(r){var n=eM(e,t||1,r.hoverStartRow,r.hoverEndRow);return[n,r.onHover]})}var rM=function(e){var t=e.ellipsis,r=e.rowType,n=e.children,o,a=t===!0?{showTitle:!0}:t;return a&&(a.showTitle||r==="header")&&(typeof n=="string"||typeof n=="number"?o=n.toString():d.isValidElement(n)&&typeof n.props.children=="string"&&(o=n.props.children)),o};function nM(e){var t,r,n,o,a,i,l,s,u=e.component,c=e.children,f=e.ellipsis,p=e.scope,h=e.prefixCls,v=e.className,g=e.align,m=e.record,b=e.render,y=e.dataIndex,C=e.renderIndex,D=e.shouldCellUpdate,w=e.index,k=e.rowType,E=e.colSpan,x=e.rowSpan,O=e.fixLeft,j=e.fixRight,$=e.firstFixLeft,P=e.lastFixLeft,A=e.firstFixRight,B=e.lastFixRight,S=e.appendNode,I=e.additionalProps,N=I===void 0?{}:I,F=e.isSticky,M="".concat(h,"-cell"),_=Lr(nn,["supportSticky","allColumnsFixedLeft","rowHoverable"]),X=_.supportSticky,H=_.allColumnsFixedLeft,q=_.rowHoverable,Z=Q8(m,y,C,c,b,D),te=ce(Z,2),z=te[0],Y=te[1],V={},U=typeof O=="number"&&X,K=typeof j=="number"&&X;U&&(V.position="sticky",V.left=O),K&&(V.position="sticky",V.right=j);var W=(t=(r=(n=Y==null?void 0:Y.colSpan)!==null&&n!==void 0?n:N.colSpan)!==null&&r!==void 0?r:E)!==null&&t!==void 0?t:1,re=(o=(a=(i=Y==null?void 0:Y.rowSpan)!==null&&i!==void 0?i:N.rowSpan)!==null&&a!==void 0?a:x)!==null&&o!==void 0?o:1,G=tM(w,re),J=ce(G,2),oe=J[0],se=J[1],ge=nr(function(De){var Ne;m&&se(w,w+re-1),N==null||(Ne=N.onMouseEnter)===null||Ne===void 0||Ne.call(N,De)}),Ee=nr(function(De){var Ne;m&&se(-1,-1),N==null||(Ne=N.onMouseLeave)===null||Ne===void 0||Ne.call(N,De)});if(W===0||re===0)return null;var je=(l=N.title)!==null&&l!==void 0?l:rM({rowType:k,ellipsis:f,children:z}),ve=pe(M,v,(s={},T(T(T(T(T(T(T(T(T(T(s,"".concat(M,"-fix-left"),U&&X),"".concat(M,"-fix-left-first"),$&&X),"".concat(M,"-fix-left-last"),P&&X),"".concat(M,"-fix-left-all"),P&&H&&X),"".concat(M,"-fix-right"),K&&X),"".concat(M,"-fix-right-first"),A&&X),"".concat(M,"-fix-right-last"),B&&X),"".concat(M,"-ellipsis"),f),"".concat(M,"-with-append"),S),"".concat(M,"-fix-sticky"),(U||K)&&F&&X),T(s,"".concat(M,"-row-hover"),!Y&&oe)),N.className,Y==null?void 0:Y.className),ye={};g&&(ye.textAlign=g);var ke=L(L(L(L({},Y==null?void 0:Y.style),V),ye),N.style),we=z;return at(we)==="object"&&!Array.isArray(we)&&!d.isValidElement(we)&&(we=null),f&&(P||A)&&(we=d.createElement("span",{className:"".concat(M,"-content")},we)),d.createElement(u,Me({},Y,N,{className:ve,style:ke,title:je,scope:p,onMouseEnter:q?ge:void 0,onMouseLeave:q?Ee:void 0,colSpan:W!==1?W:null,rowSpan:re!==1?re:null}),S,we)}const di=d.memo(nM);function Em(e,t,r,n,o){var a=r[e]||{},i=r[t]||{},l,s;a.fixed==="left"?l=n.left[o==="rtl"?t:e]:i.fixed==="right"&&(s=n.right[o==="rtl"?e:t]);var u=!1,c=!1,f=!1,p=!1,h=r[t+1],v=r[e-1],g=h&&!h.fixed||v&&!v.fixed||r.every(function(D){return D.fixed==="left"});if(o==="rtl"){if(l!==void 0){var m=v&&v.fixed==="left";p=!m&&g}else if(s!==void 0){var b=h&&h.fixed==="right";f=!b&&g}}else if(l!==void 0){var y=h&&h.fixed==="left";u=!y&&g}else if(s!==void 0){var C=v&&v.fixed==="right";c=!C&&g}return{fixLeft:l,fixRight:s,lastFixLeft:u,firstFixRight:c,lastFixRight:f,firstFixLeft:p,isSticky:n.isSticky}}var dw=d.createContext({});function oM(e){var t=e.className,r=e.index,n=e.children,o=e.colSpan,a=o===void 0?1:o,i=e.rowSpan,l=e.align,s=Lr(nn,["prefixCls","direction"]),u=s.prefixCls,c=s.direction,f=d.useContext(dw),p=f.scrollColumnIndex,h=f.stickyOffsets,v=f.flattenColumns,g=r+a-1,m=g+1===p?a+1:a,b=Em(r,r+m-1,v,h,c);return d.createElement(di,Me({className:t,index:r,component:"td",prefixCls:u,record:null,dataIndex:null,align:l,colSpan:m,rowSpan:i,render:function(){return n}},b))}var aM=["children"];function iM(e){var t=e.children,r=bt(e,aM);return d.createElement("tr",r,t)}function Wu(e){var t=e.children;return t}Wu.Row=iM;Wu.Cell=oM;function lM(e){var t=e.children,r=e.stickyOffsets,n=e.flattenColumns,o=Lr(nn,"prefixCls"),a=n.length-1,i=n[a],l=d.useMemo(function(){return{stickyOffsets:r,flattenColumns:n,scrollColumnIndex:i!=null&&i.scrollbar?a:null}},[i,n,a,r]);return d.createElement(dw.Provider,{value:l},d.createElement("tfoot",{className:"".concat(o,"-summary")},t))}const Ql=ci(lM);var fw=Wu;function sM(e){return null}function uM(e){return null}function pw(e,t,r,n,o,a,i){var l=a(t,i);e.push({record:t,indent:r,index:i,rowKey:l});var s=o==null?void 0:o.has(l);if(t&&Array.isArray(t[n])&&s)for(var u=0;u<t[n].length;u+=1)pw(e,t[n][u],r+1,n,o,a,u)}function mw(e,t,r,n){var o=d.useMemo(function(){if(r!=null&&r.size){for(var a=[],i=0;i<(e==null?void 0:e.length);i+=1){var l=e[i];pw(a,l,0,t,r,n,i)}return a}return e==null?void 0:e.map(function(s,u){return{record:s,indent:0,index:u,rowKey:n(s,u)}})},[e,t,r,n]);return o}function hw(e,t,r,n){var o=Lr(nn,["prefixCls","fixedInfoList","flattenColumns","expandableType","expandRowByClick","onTriggerExpand","rowClassName","expandedRowClassName","indentSize","expandIcon","expandedRowRender","expandIconColumnIndex","expandedKeys","childrenColumnName","rowExpandable","onRow"]),a=o.flattenColumns,i=o.expandableType,l=o.expandedKeys,s=o.childrenColumnName,u=o.onTriggerExpand,c=o.rowExpandable,f=o.onRow,p=o.expandRowByClick,h=o.rowClassName,v=i==="nest",g=i==="row"&&(!c||c(e)),m=g||v,b=l&&l.has(t),y=s&&e&&e[s],C=nr(u),D=f==null?void 0:f(e,r),w=D==null?void 0:D.onClick,k=function(O){p&&m&&u(e,O);for(var j=arguments.length,$=new Array(j>1?j-1:0),P=1;P<j;P++)$[P-1]=arguments[P];w==null||w.apply(void 0,[O].concat($))},E;typeof h=="string"?E=h:typeof h=="function"&&(E=h(e,r,n));var x=Hu(a);return L(L({},o),{},{columnsKey:x,nestExpandable:v,expanded:b,hasNestChildren:y,record:e,onTriggerExpand:C,rowSupportExpand:g,expandable:m,rowProps:L(L({},D),{},{className:pe(E,D==null?void 0:D.className),onClick:k})})}function gw(e){var t=e.prefixCls,r=e.children,n=e.component,o=e.cellComponent,a=e.className,i=e.expanded,l=e.colSpan,s=e.isEmpty,u=e.stickyOffset,c=u===void 0?0:u,f=Lr(nn,["scrollbarSize","fixHeader","fixColumn","componentWidth","horizonScroll"]),p=f.scrollbarSize,h=f.fixHeader,v=f.fixColumn,g=f.componentWidth,m=f.horizonScroll,b=r;return(s?m&&g:v)&&(b=d.createElement("div",{style:{width:g-c-(h&&!s?p:0),position:"sticky",left:c,overflow:"hidden"},className:"".concat(t,"-expanded-row-fixed")},b)),d.createElement(n,{className:a,style:{display:i?null:"none"}},d.createElement(di,{component:o,prefixCls:t,colSpan:l},b))}function cM(e){var t=e.prefixCls,r=e.record,n=e.onExpand,o=e.expanded,a=e.expandable,i="".concat(t,"-row-expand-icon");if(!a)return d.createElement("span",{className:pe(i,"".concat(t,"-row-spaced"))});var l=function(s){n(r,s),s.stopPropagation()};return d.createElement("span",{className:pe(i,T(T({},"".concat(t,"-row-expanded"),o),"".concat(t,"-row-collapsed"),!o)),onClick:l})}function dM(e,t,r){var n=[];function o(a){(a||[]).forEach(function(i,l){n.push(t(i,l)),o(i[r])})}return o(e),n}function vw(e,t,r,n){return typeof e=="string"?e:typeof e=="function"?e(t,r,n):""}function bw(e,t,r,n,o){var a,i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:[],l=arguments.length>6&&arguments[6]!==void 0?arguments[6]:0,s=e.record,u=e.prefixCls,c=e.columnsKey,f=e.fixedInfoList,p=e.expandIconColumnIndex,h=e.nestExpandable,v=e.indentSize,g=e.expandIcon,m=e.expanded,b=e.hasNestChildren,y=e.onTriggerExpand,C=e.expandable,D=e.expandedKeys,w=c[r],k=f[r],E;r===(p||0)&&h&&(E=d.createElement(d.Fragment,null,d.createElement("span",{style:{paddingLeft:"".concat(v*n,"px")},className:"".concat(u,"-row-indent indent-level-").concat(n)}),g({prefixCls:u,expanded:m,expandable:b,record:s,onExpand:y})));var x=((a=t.onCell)===null||a===void 0?void 0:a.call(t,s,o))||{};if(l){var O=x.rowSpan,j=O===void 0?1:O;if(C&&j&&r<l){for(var $=j,P=o;P<o+j;P+=1){var A=i[P];D.has(A)&&($+=1)}x.rowSpan=$}}return{key:w,fixedInfo:k,appendCellNode:E,additionalCellProps:x}}function fM(e){var t=e.className,r=e.style,n=e.record,o=e.index,a=e.renderIndex,i=e.rowKey,l=e.rowKeys,s=e.indent,u=s===void 0?0:s,c=e.rowComponent,f=e.cellComponent,p=e.scopeCellComponent,h=e.expandedRowInfo,v=hw(n,i,o,u),g=v.prefixCls,m=v.flattenColumns,b=v.expandedRowClassName,y=v.expandedRowRender,C=v.rowProps,D=v.expanded,w=v.rowSupportExpand,k=d.useRef(!1);k.current||(k.current=D);var E=vw(b,n,o,u),x=d.createElement(c,Me({},C,{"data-row-key":i,className:pe(t,"".concat(g,"-row"),"".concat(g,"-row-level-").concat(u),C==null?void 0:C.className,T({},E,u>=1)),style:L(L({},r),C==null?void 0:C.style)}),m.map(function($,P){var A=$.render,B=$.dataIndex,S=$.className,I=bw(v,$,P,u,o,l,h==null?void 0:h.offset),N=I.key,F=I.fixedInfo,M=I.appendCellNode,_=I.additionalCellProps;return d.createElement(di,Me({className:S,ellipsis:$.ellipsis,align:$.align,scope:$.rowScope,component:$.rowScope?p:f,prefixCls:g,key:N,record:n,index:o,renderIndex:a,dataIndex:B,render:A,shouldCellUpdate:$.shouldCellUpdate},F,{appendNode:M,additionalProps:_}))})),O;if(w&&(k.current||D)){var j=y(n,o,u+1,D);O=d.createElement(gw,{expanded:D,className:pe("".concat(g,"-expanded-row"),"".concat(g,"-expanded-row-level-").concat(u+1),E),prefixCls:g,component:c,cellComponent:f,colSpan:h?h.colSpan:m.length,stickyOffset:h==null?void 0:h.sticky,isEmpty:!1},j)}return d.createElement(d.Fragment,null,x,O)}const pM=ci(fM);function mM(e){var t=e.columnKey,r=e.onColumnResize,n=d.useRef();return Wt(function(){n.current&&r(t,n.current.offsetWidth)},[]),d.createElement(ao,{data:t},d.createElement("td",{ref:n,style:{padding:0,border:0,height:0}},d.createElement("div",{style:{height:0,overflow:"hidden"}},"\xA0")))}function hM(e){var t=e.prefixCls,r=e.columnsKey,n=e.onColumnResize,o=d.useRef(null);return d.createElement("tr",{"aria-hidden":"true",className:"".concat(t,"-measure-row"),style:{height:0,fontSize:0},ref:o},d.createElement(ao.Collection,{onBatchResize:function(a){ku(o.current)&&a.forEach(function(i){var l=i.data,s=i.size;n(l,s.offsetWidth)})}},r.map(function(a){return d.createElement(mM,{key:a,columnKey:a,onColumnResize:n})})))}function gM(e){var t=e.data,r=e.measureColumnWidth,n=Lr(nn,["prefixCls","getComponent","onColumnResize","flattenColumns","getRowKey","expandedKeys","childrenColumnName","emptyNode","expandedRowOffset","fixedInfoList","colWidths"]),o=n.prefixCls,a=n.getComponent,i=n.onColumnResize,l=n.flattenColumns,s=n.getRowKey,u=n.expandedKeys,c=n.childrenColumnName,f=n.emptyNode,p=n.expandedRowOffset,h=p===void 0?0:p,v=n.colWidths,g=mw(t,c,u,s),m=d.useMemo(function(){return g.map(function(O){return O.rowKey})},[g]),b=d.useRef({renderWithProps:!1}),y=d.useMemo(function(){for(var O=l.length-h,j=0,$=0;$<h;$+=1)j+=v[$]||0;return{offset:h,colSpan:O,sticky:j}},[l.length,h,v]),C=a(["body","wrapper"],"tbody"),D=a(["body","row"],"tr"),w=a(["body","cell"],"td"),k=a(["body","cell"],"th"),E;t.length?E=g.map(function(O,j){var $=O.record,P=O.indent,A=O.index,B=O.rowKey;return d.createElement(pM,{key:B,rowKey:B,rowKeys:m,record:$,index:j,renderIndex:A,rowComponent:D,cellComponent:w,scopeCellComponent:k,indent:P,expandedRowInfo:y})}):E=d.createElement(gw,{expanded:!0,className:"".concat(o,"-placeholder"),prefixCls:o,component:D,cellComponent:w,colSpan:l.length,isEmpty:!0},f);var x=Hu(l);return d.createElement(cw.Provider,{value:b.current},d.createElement(C,{className:"".concat(o,"-tbody")},r&&d.createElement(hM,{prefixCls:o,columnsKey:x,onColumnResize:i}),E))}const vM=ci(gM);var bM=["expandable"],Hi="RC_TABLE_INTERNAL_COL_DEFINE";function yM(e){var t=e.expandable,r=bt(e,bM),n;return"expandable"in e?n=L(L({},r),t):n=r,n.showExpandColumn===!1&&(n.expandIconColumnIndex=-1),n}var CM=["columnType"];function yw(e){for(var t=e.colWidths,r=e.columns,n=e.columCount,o=Lr(nn,["tableLayout"]),a=o.tableLayout,i=[],l=n||r.length,s=!1,u=l-1;u>=0;u-=1){var c=t[u],f=r&&r[u],p=void 0,h=void 0;if(f&&(p=f[Hi],a==="auto"&&(h=f.minWidth)),c||h||p||s){var v=p||{};v.columnType;var g=bt(v,CM);i.unshift(d.createElement("col",Me({key:u,style:{width:c,minWidth:h}},g))),s=!0}}return d.createElement("colgroup",null,i)}var xM=["className","noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","stickyTopOffset","stickyBottomOffset","stickyClassName","onScroll","maxContentScroll","children"];function wM(e,t){return xt(function(){for(var r=[],n=0;n<t;n+=1){var o=e[n];if(o!==void 0)r[n]=o;else return null}return r},[e.join("_"),t])}var EM=d.forwardRef(function(e,t){var r=e.className,n=e.noData,o=e.columns,a=e.flattenColumns,i=e.colWidths,l=e.columCount,s=e.stickyOffsets,u=e.direction,c=e.fixHeader,f=e.stickyTopOffset,p=e.stickyBottomOffset,h=e.stickyClassName,v=e.onScroll,g=e.maxContentScroll,m=e.children,b=bt(e,xM),y=Lr(nn,["prefixCls","scrollbarSize","isSticky","getComponent"]),C=y.prefixCls,D=y.scrollbarSize,w=y.isSticky,k=y.getComponent,E=k(["header","table"],"table"),x=w&&!c?0:D,O=d.useRef(null),j=d.useCallback(function(F){Qi(t,F),Qi(O,F)},[]);d.useEffect(function(){function F(_){var X=_,H=X.currentTarget,q=X.deltaX;q&&(v({currentTarget:H,scrollLeft:H.scrollLeft+q}),_.preventDefault())}var M=O.current;return M==null||M.addEventListener("wheel",F,{passive:!1}),function(){M==null||M.removeEventListener("wheel",F)}},[]);var $=d.useMemo(function(){return a.every(function(F){return F.width})},[a]),P=a[a.length-1],A={fixed:P?P.fixed:null,scrollbar:!0,onHeaderCell:function(){return{className:"".concat(C,"-cell-scrollbar")}}},B=xt(function(){return x?[].concat(Ie(o),[A]):o},[x,o]),S=xt(function(){return x?[].concat(Ie(a),[A]):a},[x,a]),I=xt(function(){var F=s.right,M=s.left;return L(L({},s),{},{left:u==="rtl"?[].concat(Ie(M.map(function(_){return _+x})),[0]):M,right:u==="rtl"?F:[].concat(Ie(F.map(function(_){return _+x})),[0]),isSticky:w})},[x,s,w]),N=wM(i,l);return d.createElement("div",{style:L({overflow:"hidden"},w?{top:f,bottom:p}:{}),ref:j,className:pe(r,T({},h,!!h))},d.createElement(E,{style:{tableLayout:"fixed",visibility:n||N?null:"hidden"}},(!n||!g||$)&&d.createElement(yw,{colWidths:N?[].concat(Ie(N),[x]):[],columCount:l+1,columns:S}),m(L(L({},b),{},{stickyOffsets:I,columns:B,flattenColumns:S}))))});const Z0=d.memo(EM);var kM=function(e){var t=e.cells,r=e.stickyOffsets,n=e.flattenColumns,o=e.rowComponent,a=e.cellComponent,i=e.onHeaderRow,l=e.index,s=Lr(nn,["prefixCls","direction"]),u=s.prefixCls,c=s.direction,f;i&&(f=i(t.map(function(h){return h.column}),l));var p=Hu(t.map(function(h){return h.column}));return d.createElement(o,f,t.map(function(h,v){var g=h.column,m=Em(h.colStart,h.colEnd,n,r,c),b;return g&&g.onHeaderCell&&(b=h.column.onHeaderCell(g)),d.createElement(di,Me({},h,{scope:g.title?h.colSpan>1?"colgroup":"col":null,ellipsis:g.ellipsis,align:g.align,component:a,prefixCls:u,key:p[v]},m,{additionalProps:b,rowType:"header"}))}))};function DM(e){var t=[];function r(i,l){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;t[s]=t[s]||[];var u=l,c=i.filter(Boolean).map(function(f){var p={key:f.key,className:f.className||"",children:f.title,column:f,colStart:u},h=1,v=f.children;return v&&v.length>0&&(h=r(v,u,s+1).reduce(function(g,m){return g+m},0),p.hasSubColumns=!0),"colSpan"in f&&(h=f.colSpan),"rowSpan"in f&&(p.rowSpan=f.rowSpan),p.colSpan=h,p.colEnd=p.colStart+h-1,t[s].push(p),u+=h,h});return c}r(e,0);for(var n=t.length,o=function(i){t[i].forEach(function(l){!("rowSpan"in l)&&!l.hasSubColumns&&(l.rowSpan=n-i)})},a=0;a<n;a+=1)o(a);return t}var SM=function(e){var t=e.stickyOffsets,r=e.columns,n=e.flattenColumns,o=e.onHeaderRow,a=Lr(nn,["prefixCls","getComponent"]),i=a.prefixCls,l=a.getComponent,s=d.useMemo(function(){return DM(r)},[r]),u=l(["header","wrapper"],"thead"),c=l(["header","row"],"tr"),f=l(["header","cell"],"th");return d.createElement(u,{className:"".concat(i,"-thead")},s.map(function(p,h){var v=d.createElement(kM,{key:h,flattenColumns:n,cells:p,stickyOffsets:t,rowComponent:c,cellComponent:f,onHeaderRow:o,index:h});return v}))};const J0=ci(SM);function Q0(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return typeof t=="number"?t:t.endsWith("%")?e*parseFloat(t)/100:null}function $M(e,t,r){return d.useMemo(function(){if(t&&t>0){var n=0,o=0;e.forEach(function(p){var h=Q0(t,p.width);h?n+=h:o+=1});var a=Math.max(t,r),i=Math.max(a-n,o),l=o,s=i/o,u=0,c=e.map(function(p){var h=L({},p),v=Q0(t,h.width);if(v)h.width=v;else{var g=Math.floor(s);h.width=l===1?i:g,i-=g,l-=1}return u+=h.width,h});if(u<a){var f=a/u;i=a,c.forEach(function(p,h){var v=Math.floor(p.width*f);p.width=h===c.length-1?i:v,i-=v})}return[c,Math.max(u,a)]}return[e,t]},[e,t,r])}var BM=["children"],OM=["fixed"];function km(e){return Ln(e).filter(function(t){return d.isValidElement(t)}).map(function(t){var r=t.key,n=t.props,o=n.children,a=bt(n,BM),i=L({key:r},a);return o&&(i.children=km(o)),i})}function Cw(e){return e.filter(function(t){return t&&at(t)==="object"&&!t.hidden}).map(function(t){var r=t.children;return r&&r.length>0?L(L({},t),{},{children:Cw(r)}):t})}function Kf(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"key";return e.filter(function(r){return r&&at(r)==="object"}).reduce(function(r,n,o){var a=n.fixed,i=a===!0?"left":a,l="".concat(t,"-").concat(o),s=n.children;return s&&s.length>0?[].concat(Ie(r),Ie(Kf(s,l).map(function(u){return L({fixed:i},u)}))):[].concat(Ie(r),[L(L({key:l},n),{},{fixed:i})])},[])}function AM(e){return e.map(function(t){var r=t.fixed,n=bt(t,OM),o=r;return r==="left"?o="right":r==="right"&&(o="left"),L({fixed:o},n)})}function FM(e,t){var r=e.prefixCls,n=e.columns,o=e.children,a=e.expandable,i=e.expandedKeys,l=e.columnTitle,s=e.getRowKey,u=e.onTriggerExpand,c=e.expandIcon,f=e.rowExpandable,p=e.expandIconColumnIndex,h=e.expandedRowOffset,v=h===void 0?0:h,g=e.direction,m=e.expandRowByClick,b=e.columnWidth,y=e.fixed,C=e.scrollWidth,D=e.clientWidth,w=d.useMemo(function(){var B=n||km(o)||[];return Cw(B.slice())},[n,o]),k=d.useMemo(function(){if(a){var B=w.slice();if(!B.includes(co)){var S=p||0;S>=0&&(S||y==="left"||!y)&&B.splice(S,0,co),y==="right"&&B.splice(w.length,0,co)}var I=B.indexOf(co);B=B.filter(function(_,X){return _!==co||X===I});var N=w[I],F;y?F=y:F=N?N.fixed:null;var M=T(T(T(T(T(T({},Hi,{className:"".concat(r,"-expand-icon-col"),columnType:"EXPAND_COLUMN"}),"title",l),"fixed",F),"className","".concat(r,"-row-expand-icon-cell")),"width",b),"render",function(_,X,H){var q=s(X,H),Z=i.has(q),te=f?f(X):!0,z=c({prefixCls:r,expanded:Z,expandable:te,record:X,onExpand:u});return m?d.createElement("span",{onClick:function(Y){return Y.stopPropagation()}},z):z});return B.map(function(_,X){var H=_===co?M:_;return X<v?L(L({},H),{},{fixed:H.fixed||"left"}):H})}return w.filter(function(_){return _!==co})},[a,w,s,i,c,g,v]),E=d.useMemo(function(){var B=k;return t&&(B=t(B)),B.length||(B=[{render:function(){return null}}]),B},[t,k,g]),x=d.useMemo(function(){return g==="rtl"?AM(Kf(E)):Kf(E)},[E,g,C]),O=d.useMemo(function(){for(var B=-1,S=x.length-1;S>=0;S-=1){var I=x[S].fixed;if(I==="left"||I===!0){B=S;break}}if(B>=0)for(var N=0;N<=B;N+=1){var F=x[N].fixed;if(F!=="left"&&F!==!0)return!0}var M=x.findIndex(function(H){var q=H.fixed;return q==="right"});if(M>=0)for(var _=M;_<x.length;_+=1){var X=x[_].fixed;if(X!=="right")return!0}return!1},[x]),j=$M(x,C,D),$=ce(j,2),P=$[0],A=$[1];return[E,P,A,O]}function NM(e,t,r){var n=yM(e),o=n.expandIcon,a=n.expandedRowKeys,i=n.defaultExpandedRowKeys,l=n.defaultExpandAllRows,s=n.expandedRowRender,u=n.onExpand,c=n.onExpandedRowsChange,f=n.childrenColumnName,p=o||cM,h=f||"children",v=d.useMemo(function(){return s?"row":e.expandable&&e.internalHooks===Ol&&e.expandable.__PARENT_RENDER_ICON__||t.some(function(w){return w&&at(w)==="object"&&w[h]})?"nest":!1},[!!s,t]),g=d.useState(function(){return i||(l?dM(t,r,h):[])}),m=ce(g,2),b=m[0],y=m[1],C=d.useMemo(function(){return new Set(a||b||[])},[a,b]),D=d.useCallback(function(w){var k=r(w,t.indexOf(w)),E,x=C.has(k);x?(C.delete(k),E=Ie(C)):E=[].concat(Ie(C),[k]),y(E),u&&u(!x,w),c&&c(E)},[r,C,t,u,c]);return[n,v,C,p,h,D]}function PM(e,t,r){var n=e.map(function(o,a){return Em(a,a,e,t,r)});return la(function(){return n},[n],function(o,a){return!Jn(o,a)})}function jM(e){var t=qe(e),r=yt({}),n=ce(r,2),o=n[1],a=qe(null),i=qe([]);function l(s){i.current.push(s);var u=Promise.resolve();a.current=u,u.then(function(){if(a.current===u){var c=i.current,f=t.current;i.current=[],c.forEach(function(p){t.current=p(t.current)}),a.current=null,f!==t.current&&o({})}})}return Ot(function(){return function(){a.current=null}},[]),[t.current,l]}function IM(e){var t=qe(null),r=qe();function n(){window.clearTimeout(r.current)}function o(i){t.current=i,n(),r.current=window.setTimeout(function(){t.current=null,r.current=void 0},100)}function a(){return t.current}return Ot(function(){return n},[]),[o,a]}function RM(){var e=d.useState(-1),t=ce(e,2),r=t[0],n=t[1],o=d.useState(-1),a=ce(o,2),i=a[0],l=a[1],s=d.useCallback(function(u,c){n(u),l(c)},[]);return[r,i,s]}var eb=Xr()?window:null;function MM(e,t){var r=at(e)==="object"?e:{},n=r.offsetHeader,o=n===void 0?0:n,a=r.offsetSummary,i=a===void 0?0:a,l=r.offsetScroll,s=l===void 0?0:l,u=r.getContainer,c=u===void 0?function(){return eb}:u,f=c()||eb,p=!!e;return d.useMemo(function(){return{isSticky:p,stickyClassName:p?"".concat(t,"-sticky-holder"):"",offsetHeader:o,offsetSummary:i,offsetScroll:s,container:f}},[p,s,o,i,t,f])}function TM(e,t,r){var n=xt(function(){var o=t.length,a=function(s,u,c){for(var f=[],p=0,h=s;h!==u;h+=c)f.push(p),t[h].fixed&&(p+=e[h]||0);return f},i=a(0,o,1),l=a(o-1,-1,-1).reverse();return r==="rtl"?{left:l,right:i}:{left:i,right:l}},[e,t,r]);return n}function tb(e){var t=e.className,r=e.children;return d.createElement("div",{className:t},r)}function rb(e){var t=gu(e),r=t.getBoundingClientRect(),n=document.documentElement;return{left:r.left+(window.pageXOffset||n.scrollLeft)-(n.clientLeft||document.body.clientLeft||0),top:r.top+(window.pageYOffset||n.scrollTop)-(n.clientTop||document.body.clientTop||0)}}var zM=function(e,t){var r,n,o=e.scrollBodyRef,a=e.onScroll,i=e.offsetScroll,l=e.container,s=e.direction,u=Lr(nn,"prefixCls"),c=((r=o.current)===null||r===void 0?void 0:r.scrollWidth)||0,f=((n=o.current)===null||n===void 0?void 0:n.clientWidth)||0,p=c&&f*(f/c),h=d.useRef(),v=jM({scrollLeft:0,isHiddenScrollBar:!0}),g=ce(v,2),m=g[0],b=g[1],y=d.useRef({delta:0,x:0}),C=d.useState(!1),D=ce(C,2),w=D[0],k=D[1],E=d.useRef(null);d.useEffect(function(){return function(){qt.cancel(E.current)}},[]);var x=function(){k(!1)},O=function(A){A.persist(),y.current.delta=A.pageX-m.scrollLeft,y.current.x=0,k(!0),A.preventDefault()},j=function(A){var B,S=A||((B=window)===null||B===void 0?void 0:B.event),I=S.buttons;if(!w||I===0){w&&k(!1);return}var N=y.current.x+A.pageX-y.current.x-y.current.delta,F=s==="rtl";N=Math.max(F?p-f:0,Math.min(F?0:f-p,N));var M=!F||Math.abs(N)+Math.abs(p)<f;M&&(a({scrollLeft:N/f*(c+2)}),y.current.x=A.pageX)},$=function(){qt.cancel(E.current),E.current=qt(function(){if(o.current){var A=rb(o.current).top,B=A+o.current.offsetHeight,S=l===window?document.documentElement.scrollTop+window.innerHeight:rb(l).top+l.clientHeight;B-Rv()<=S||A>=S-i?b(function(I){return L(L({},I),{},{isHiddenScrollBar:!0})}):b(function(I){return L(L({},I),{},{isHiddenScrollBar:!1})})}})},P=function(A){b(function(B){return L(L({},B),{},{scrollLeft:A/c*f||0})})};return d.useImperativeHandle(t,function(){return{setScrollLeft:P,checkScrollBarVisible:$}}),d.useEffect(function(){var A=H0(document.body,"mouseup",x,!1),B=H0(document.body,"mousemove",j,!1);return $(),function(){A.remove(),B.remove()}},[p,w]),d.useEffect(function(){if(o.current){for(var A=[],B=gu(o.current);B;)A.push(B),B=B.parentElement;return A.forEach(function(S){return S.addEventListener("scroll",$,!1)}),window.addEventListener("resize",$,!1),window.addEventListener("scroll",$,!1),l.addEventListener("scroll",$,!1),function(){A.forEach(function(S){return S.removeEventListener("scroll",$)}),window.removeEventListener("resize",$),window.removeEventListener("scroll",$),l.removeEventListener("scroll",$)}}},[l]),d.useEffect(function(){m.isHiddenScrollBar||b(function(A){var B=o.current;return B?L(L({},A),{},{scrollLeft:B.scrollLeft/B.scrollWidth*B.clientWidth}):A})},[m.isHiddenScrollBar]),c<=f||!p||m.isHiddenScrollBar?null:d.createElement("div",{style:{height:Rv(),width:f,bottom:i},className:"".concat(u,"-sticky-scroll")},d.createElement("div",{onMouseDown:O,ref:h,className:pe("".concat(u,"-sticky-scroll-bar"),T({},"".concat(u,"-sticky-scroll-bar-active"),w)),style:{width:"".concat(p,"px"),transform:"translate3d(".concat(m.scrollLeft,"px, 0, 0)")}}))};const _M=d.forwardRef(zM);var xw="rc-table",LM=[],HM={};function WM(){return"No Data"}function KM(e,t){var r=L({rowKey:"key",prefixCls:xw,emptyText:WM},e),n=r.prefixCls,o=r.className,a=r.rowClassName,i=r.style,l=r.data,s=r.rowKey,u=r.scroll,c=r.tableLayout,f=r.direction,p=r.title,h=r.footer,v=r.summary,g=r.caption,m=r.id,b=r.showHeader,y=r.components,C=r.emptyText,D=r.onRow,w=r.onHeaderRow,k=r.onScroll,E=r.internalHooks,x=r.transformColumns,O=r.internalRefs,j=r.tailor,$=r.getContainerWidth,P=r.sticky,A=r.rowHoverable,B=A===void 0?!0:A,S=l||LM,I=!!S.length,N=E===Ol,F=d.useCallback(function(ft,kt){return vn(y,ft)||kt},[y]),M=d.useMemo(function(){return typeof s=="function"?s:function(ft){var kt=ft&&ft[s];return kt}},[s]),_=F(["body"]),X=RM(),H=ce(X,3),q=H[0],Z=H[1],te=H[2],z=NM(r,S,M),Y=ce(z,6),V=Y[0],U=Y[1],K=Y[2],W=Y[3],re=Y[4],G=Y[5],J=u==null?void 0:u.x,oe=d.useState(0),se=ce(oe,2),ge=se[0],Ee=se[1],je=FM(L(L(L({},r),V),{},{expandable:!!V.expandedRowRender,columnTitle:V.columnTitle,expandedKeys:K,getRowKey:M,onTriggerExpand:G,expandIcon:W,expandIconColumnIndex:V.expandIconColumnIndex,direction:f,scrollWidth:N&&j&&typeof J=="number"?J:null,clientWidth:ge}),N?x:null),ve=ce(je,4),ye=ve[0],ke=ve[1],we=ve[2],De=ve[3],Ne=we??J,Oe=d.useMemo(function(){return{columns:ye,flattenColumns:ke}},[ye,ke]),Xe=d.useRef(),Le=d.useRef(),Fe=d.useRef(),fe=d.useRef();d.useImperativeHandle(t,function(){return{nativeElement:Xe.current,scrollTo:function(ft){var kt;if(Fe.current instanceof HTMLElement){var Sr=ft.index,hr=ft.top,ur=ft.key;if(Z8(hr)){var pn;(pn=Fe.current)===null||pn===void 0||pn.scrollTo({top:hr})}else{var Wr,Nn=ur??M(S[Sr]);(Wr=Fe.current.querySelector('[data-row-key="'.concat(Nn,'"]')))===null||Wr===void 0||Wr.scrollIntoView()}}else(kt=Fe.current)!==null&&kt!==void 0&&kt.scrollTo&&Fe.current.scrollTo(ft)}}});var Be=d.useRef(),We=d.useState(!1),Ye=ce(We,2),Ve=Ye[0],Te=Ye[1],it=d.useState(!1),Ue=ce(it,2),nt=Ue[0],pt=Ue[1],St=d.useState(new Map),dt=ce(St,2),ht=dt[0],Pt=dt[1],At=Hu(ke),ct=At.map(function(ft){return ht.get(ft)}),ut=d.useMemo(function(){return ct},[ct.join("_")]),ae=TM(ut,ke,f),he=u&&Wf(u.y),xe=u&&Wf(Ne)||!!V.fixed,be=xe&&ke.some(function(ft){var kt=ft.fixed;return kt}),Ce=d.useRef(),de=MM(P,n),Se=de.isSticky,le=de.offsetHeader,ie=de.offsetSummary,me=de.offsetScroll,ze=de.stickyClassName,_e=de.container,Ke=d.useMemo(function(){return v==null?void 0:v(S)},[v,S]),Pe=(he||Se)&&d.isValidElement(Ke)&&Ke.type===Wu&&Ke.props.fixed,Ze,wt,jt;he&&(wt={overflowY:I?"scroll":"auto",maxHeight:u.y}),xe&&(Ze={overflowX:"auto"},he||(wt={overflowY:"hidden"}),jt={width:Ne===!0?"auto":Ne,minWidth:"100%"});var It=d.useCallback(function(ft,kt){Pt(function(Sr){if(Sr.get(ft)!==kt){var hr=new Map(Sr);return hr.set(ft,kt),hr}return Sr})},[]),Et=IM(),Jt=ce(Et,2),pr=Jt[0],He=Jt[1];function Qe(ft,kt){kt&&(typeof kt=="function"?kt(ft):kt.scrollLeft!==ft&&(kt.scrollLeft=ft,kt.scrollLeft!==ft&&setTimeout(function(){kt.scrollLeft=ft},0)))}var gt=nr(function(ft){var kt=ft.currentTarget,Sr=ft.scrollLeft,hr=f==="rtl",ur=typeof Sr=="number"?Sr:kt.scrollLeft,pn=kt||HM;if(!He()||He()===pn){var Wr;pr(pn),Qe(ur,Le.current),Qe(ur,Fe.current),Qe(ur,Be.current),Qe(ur,(Wr=Ce.current)===null||Wr===void 0?void 0:Wr.setScrollLeft)}var Nn=kt||Le.current;if(Nn){var En=N&&j&&typeof Ne=="number"?Ne:Nn.scrollWidth,io=Nn.clientWidth;if(En===io){Te(!1),pt(!1);return}hr?(Te(-ur<En-io),pt(-ur>0)):(Te(ur>0),pt(ur<En-io))}}),Mt=nr(function(ft){gt(ft),k==null||k(ft)}),Ft=function(){if(xe&&Fe.current){var ft;gt({currentTarget:gu(Fe.current),scrollLeft:(ft=Fe.current)===null||ft===void 0?void 0:ft.scrollLeft})}else Te(!1),pt(!1)},yr=function(ft){var kt,Sr=ft.width;(kt=Ce.current)===null||kt===void 0||kt.checkScrollBarVisible();var hr=Xe.current?Xe.current.offsetWidth:Sr;N&&$&&Xe.current&&(hr=$(Xe.current,hr)||hr),hr!==ge&&(Ft(),Ee(hr))},Cr=d.useRef(!1);d.useEffect(function(){Cr.current&&Ft()},[xe,l,ye.length]),d.useEffect(function(){Cr.current=!0},[]);var st=d.useState(0),$t=ce(st,2),Bt=$t[0],Gt=$t[1],Mr=d.useState(!0),Zr=ce(Mr,2),xn=Zr[0],on=Zr[1];Wt(function(){(!j||!N)&&(Fe.current instanceof Element?Gt(bf(Fe.current).width):Gt(bf(fe.current).width)),on(BP("position","sticky"))},[]),d.useEffect(function(){N&&O&&(O.body.current=Fe.current)});var Tr=d.useCallback(function(ft){return d.createElement(d.Fragment,null,d.createElement(J0,ft),Pe==="top"&&d.createElement(Ql,ft,Ke))},[Pe,Ke]),an=d.useCallback(function(ft){return d.createElement(Ql,ft,Ke)},[Ke]),Jr=F(["table"],"table"),zr=d.useMemo(function(){return c||(be?Ne==="max-content"?"auto":"fixed":he||Se||ke.some(function(ft){var kt=ft.ellipsis;return kt})?"fixed":"auto")},[he,be,ke,c,Se]),ln,Ct={colWidths:ut,columCount:ke.length,stickyOffsets:ae,onHeaderRow:w,fixHeader:he,scroll:u},Je=d.useMemo(function(){return I?null:typeof C=="function"?C():C},[I,C]),vt=d.createElement(vM,{data:S,measureColumnWidth:he||xe||Se}),Lt=d.createElement(yw,{colWidths:ke.map(function(ft){var kt=ft.width;return kt}),columns:ke}),_t=g!=null?d.createElement("caption",{className:"".concat(n,"-caption")},g):void 0,tr=Qn(r,{data:!0}),Dr=Qn(r,{aria:!0});if(he||Se){var mr;typeof _=="function"?(mr=_(S,{scrollbarSize:Bt,ref:Fe,onScroll:gt}),Ct.colWidths=ke.map(function(ft,kt){var Sr=ft.width,hr=kt===ke.length-1?Sr-Bt:Sr;return typeof hr=="number"&&!Number.isNaN(hr)?hr:0})):mr=d.createElement("div",{style:L(L({},Ze),wt),onScroll:Mt,ref:Fe,className:pe("".concat(n,"-body"))},d.createElement(Jr,Me({style:L(L({},jt),{},{tableLayout:zr})},Dr),_t,Lt,vt,!Pe&&Ke&&d.createElement(Ql,{stickyOffsets:ae,flattenColumns:ke},Ke)));var _r=L(L(L({noData:!S.length,maxContentScroll:xe&&Ne==="max-content"},Ct),Oe),{},{direction:f,stickyClassName:ze,onScroll:gt});ln=d.createElement(d.Fragment,null,b!==!1&&d.createElement(Z0,Me({},_r,{stickyTopOffset:le,className:"".concat(n,"-header"),ref:Le}),Tr),mr,Pe&&Pe!=="top"&&d.createElement(Z0,Me({},_r,{stickyBottomOffset:ie,className:"".concat(n,"-summary"),ref:Be}),an),Se&&Fe.current&&Fe.current instanceof Element&&d.createElement(_M,{ref:Ce,offsetScroll:me,scrollBodyRef:Fe,onScroll:gt,container:_e,direction:f}))}else ln=d.createElement("div",{style:L(L({},Ze),wt),className:pe("".concat(n,"-content")),onScroll:gt,ref:Fe},d.createElement(Jr,Me({style:L(L({},jt),{},{tableLayout:zr})},Dr),_t,Lt,b!==!1&&d.createElement(J0,Me({},Ct,Oe)),vt,Ke&&d.createElement(Ql,{stickyOffsets:ae,flattenColumns:ke},Ke)));var xr=d.createElement("div",Me({className:pe(n,o,T(T(T(T(T(T(T(T(T(T({},"".concat(n,"-rtl"),f==="rtl"),"".concat(n,"-ping-left"),Ve),"".concat(n,"-ping-right"),nt),"".concat(n,"-layout-fixed"),c==="fixed"),"".concat(n,"-fixed-header"),he),"".concat(n,"-fixed-column"),be),"".concat(n,"-fixed-column-gapped"),be&&De),"".concat(n,"-scroll-horizontal"),xe),"".concat(n,"-has-fix-left"),ke[0]&&ke[0].fixed),"".concat(n,"-has-fix-right"),ke[ke.length-1]&&ke[ke.length-1].fixed==="right")),style:i,id:m,ref:Xe},tr),p&&d.createElement(tb,{className:"".concat(n,"-title")},p(S)),d.createElement("div",{ref:fe,className:"".concat(n,"-container")},ln),h&&d.createElement(tb,{className:"".concat(n,"-footer")},h(S)));xe&&(xr=d.createElement(ao,{onResize:yr},xr));var Ar=PM(ke,ae,f),wn=d.useMemo(function(){return{scrollX:Ne,prefixCls:n,getComponent:F,scrollbarSize:Bt,direction:f,fixedInfoList:Ar,isSticky:Se,supportSticky:xn,componentWidth:ge,fixHeader:he,fixColumn:be,horizonScroll:xe,tableLayout:zr,rowClassName:a,expandedRowClassName:V.expandedRowClassName,expandIcon:W,expandableType:U,expandRowByClick:V.expandRowByClick,expandedRowRender:V.expandedRowRender,expandedRowOffset:V.expandedRowOffset,onTriggerExpand:G,expandIconColumnIndex:V.expandIconColumnIndex,indentSize:V.indentSize,allColumnsFixedLeft:ke.every(function(ft){return ft.fixed==="left"}),emptyNode:Je,columns:ye,flattenColumns:ke,onColumnResize:It,colWidths:ut,hoverStartRow:q,hoverEndRow:Z,onHover:te,rowExpandable:V.rowExpandable,onRow:D,getRowKey:M,expandedKeys:K,childrenColumnName:re,rowHoverable:B}},[Ne,n,F,Bt,f,Ar,Se,xn,ge,he,be,xe,zr,a,V.expandedRowClassName,W,U,V.expandRowByClick,V.expandedRowRender,V.expandedRowOffset,G,V.expandIconColumnIndex,V.indentSize,Je,ye,ke,It,ut,q,Z,te,V.rowExpandable,D,M,K,re,B]);return d.createElement(nn.Provider,{value:wn},xr)}var qM=d.forwardRef(KM);function ww(e){return uw(qM,e)}var fi=ww();fi.EXPAND_COLUMN=co;fi.INTERNAL_HOOKS=Ol;fi.Column=sM;fi.ColumnGroup=uM;fi.Summary=fw;var Dm=xm(null),Ew=xm(null);function VM(e,t,r){var n=t||1;return r[e+n]-(r[e]||0)}function GM(e){var t=e.rowInfo,r=e.column,n=e.colIndex,o=e.indent,a=e.index,i=e.component,l=e.renderIndex,s=e.record,u=e.style,c=e.className,f=e.inverse,p=e.getHeight,h=r.render,v=r.dataIndex,g=r.className,m=r.width,b=Lr(Ew,["columnsOffset"]),y=b.columnsOffset,C=bw(t,r,n,o,a),D=C.key,w=C.fixedInfo,k=C.appendCellNode,E=C.additionalCellProps,x=E.style,O=E.colSpan,j=O===void 0?1:O,$=E.rowSpan,P=$===void 0?1:$,A=n-1,B=VM(A,j,y),S=j>1?m-B:0,I=L(L(L({},x),u),{},{flex:"0 0 ".concat(B,"px"),width:"".concat(B,"px"),marginRight:S,pointerEvents:"auto"}),N=d.useMemo(function(){return f?P<=1:j===0||P===0||P>1},[P,j,f]);N?I.visibility="hidden":f&&(I.height=p==null?void 0:p(P));var F=N?function(){return null}:h,M={};return(P===0||j===0)&&(M.rowSpan=1,M.colSpan=1),d.createElement(di,Me({className:pe(g,c),ellipsis:r.ellipsis,align:r.align,scope:r.rowScope,component:i,prefixCls:t.prefixCls,key:D,record:s,index:a,renderIndex:l,dataIndex:v,render:F,shouldCellUpdate:r.shouldCellUpdate},w,{appendNode:k,additionalProps:L(L({},E),{},{style:I},M)}))}var XM=["data","index","className","rowKey","style","extra","getHeight"],UM=d.forwardRef(function(e,t){var r=e.data,n=e.index,o=e.className,a=e.rowKey,i=e.style,l=e.extra,s=e.getHeight,u=bt(e,XM),c=r.record,f=r.indent,p=r.index,h=Lr(nn,["prefixCls","flattenColumns","fixColumn","componentWidth","scrollX"]),v=h.scrollX,g=h.flattenColumns,m=h.prefixCls,b=h.fixColumn,y=h.componentWidth,C=Lr(Dm,["getComponent"]),D=C.getComponent,w=hw(c,a,n,f),k=D(["body","row"],"div"),E=D(["body","cell"],"div"),x=w.rowSupportExpand,O=w.expanded,j=w.rowProps,$=w.expandedRowRender,P=w.expandedRowClassName,A;if(x&&O){var B=$(c,n,f+1,O),S=vw(P,c,n,f),I={};b&&(I={style:T({},"--virtual-width","".concat(y,"px"))});var N="".concat(m,"-expanded-row-cell");A=d.createElement(k,{className:pe("".concat(m,"-expanded-row"),"".concat(m,"-expanded-row-level-").concat(f+1),S)},d.createElement(di,{component:E,prefixCls:m,className:pe(N,T({},"".concat(N,"-fixed"),b)),additionalProps:I},B))}var F=L(L({},i),{},{width:v});l&&(F.position="absolute",F.pointerEvents="none");var M=d.createElement(k,Me({},j,u,{"data-row-key":a,ref:x?null:t,className:pe(o,"".concat(m,"-row"),j==null?void 0:j.className,T({},"".concat(m,"-row-extra"),l)),style:L(L({},F),j==null?void 0:j.style)}),g.map(function(_,X){return d.createElement(GM,{key:X,component:E,rowInfo:w,column:_,colIndex:X,indent:f,index:n,renderIndex:p,record:c,inverse:l,getHeight:s})}));return x?d.createElement("div",{ref:t},M,A):M}),nb=ci(UM),YM=d.forwardRef(function(e,t){var r=e.data,n=e.onScroll,o=Lr(nn,["flattenColumns","onColumnResize","getRowKey","prefixCls","expandedKeys","childrenColumnName","scrollX","direction"]),a=o.flattenColumns,i=o.onColumnResize,l=o.getRowKey,s=o.expandedKeys,u=o.prefixCls,c=o.childrenColumnName,f=o.scrollX,p=o.direction,h=Lr(Dm),v=h.sticky,g=h.scrollY,m=h.listItemHeight,b=h.getComponent,y=h.onScroll,C=d.useRef(),D=mw(r,c,s,l),w=d.useMemo(function(){var A=0;return a.map(function(B){var S=B.width,I=B.key;return A+=S,[I,S,A]})},[a]),k=d.useMemo(function(){return w.map(function(A){return A[2]})},[w]);d.useEffect(function(){w.forEach(function(A){var B=ce(A,2),S=B[0],I=B[1];i(S,I)})},[w]),d.useImperativeHandle(t,function(){var A,B={scrollTo:function(S){var I;(I=C.current)===null||I===void 0||I.scrollTo(S)},nativeElement:(A=C.current)===null||A===void 0?void 0:A.nativeElement};return Object.defineProperty(B,"scrollLeft",{get:function(){var S;return((S=C.current)===null||S===void 0?void 0:S.getScrollInfo().x)||0},set:function(S){var I;(I=C.current)===null||I===void 0||I.scrollTo({left:S})}}),B});var E=function(A,B){var S,I=(S=D[B])===null||S===void 0?void 0:S.record,N=A.onCell;if(N){var F,M=N(I,B);return(F=M==null?void 0:M.rowSpan)!==null&&F!==void 0?F:1}return 1},x=function(A){var B=A.start,S=A.end,I=A.getSize,N=A.offsetY;if(S<0)return null;for(var F=a.filter(function(K){return E(K,B)===0}),M=B,_=function(K){if(F=F.filter(function(W){return E(W,K)===0}),!F.length)return M=K,1},X=B;X>=0&&!_(X);X-=1);for(var H=a.filter(function(K){return E(K,S)!==1}),q=S,Z=function(K){if(H=H.filter(function(W){return E(W,K)!==1}),!H.length)return q=Math.max(K-1,S),1},te=S;te<D.length&&!Z(te);te+=1);for(var z=[],Y=function(K){var W=D[K];if(!W)return 1;a.some(function(re){return E(re,K)>1})&&z.push(K)},V=M;V<=q;V+=1)Y(V);var U=z.map(function(K){var W=D[K],re=l(W.record,K),G=function(oe){var se=K+oe-1,ge=l(D[se].record,se),Ee=I(re,ge);return Ee.bottom-Ee.top},J=I(re);return d.createElement(nb,{key:K,data:W,rowKey:re,index:K,style:{top:-N+J.top},extra:!0,getHeight:G})});return U},O=d.useMemo(function(){return{columnsOffset:k}},[k]),j="".concat(u,"-tbody"),$=b(["body","wrapper"]),P={};return v&&(P.position="sticky",P.bottom=0,at(v)==="object"&&v.offsetScroll&&(P.bottom=v.offsetScroll)),d.createElement(Ew.Provider,{value:O},d.createElement(Ru,{fullHeight:!1,ref:C,prefixCls:"".concat(j,"-virtual"),styles:{horizontalScrollBar:P},className:j,height:g,itemHeight:m||24,data:D,itemKey:function(A){return l(A.record)},component:$,scrollWidth:f,direction:p,onVirtualScroll:function(A){var B,S=A.x;n({currentTarget:(B=C.current)===null||B===void 0?void 0:B.nativeElement,scrollLeft:S})},onScroll:y,extraRender:x},function(A,B,S){var I=l(A.record,B);return d.createElement(nb,{data:A,rowKey:I,index:B,style:S.style})}))}),ZM=ci(YM),JM=function(e,t){var r=t.ref,n=t.onScroll;return d.createElement(ZM,{ref:r,data:e,onScroll:n})};function QM(e,t){var r=e.data,n=e.columns,o=e.scroll,a=e.sticky,i=e.prefixCls,l=i===void 0?xw:i,s=e.className,u=e.listItemHeight,c=e.components,f=e.onScroll,p=o||{},h=p.x,v=p.y;typeof h!="number"&&(h=1),typeof v!="number"&&(v=500);var g=nr(function(y,C){return vn(c,y)||C}),m=nr(f),b=d.useMemo(function(){return{sticky:a,scrollY:v,listItemHeight:u,getComponent:g,onScroll:m}},[a,v,u,g,m]);return d.createElement(Dm.Provider,{value:b},d.createElement(fi,Me({},e,{className:pe(s,"".concat(l,"-virtual")),scroll:L(L({},o),{},{x:h}),components:L(L({},c),{},{body:r!=null&&r.length?JM:void 0}),columns:n,internalHooks:Ol,tailor:!0,ref:t})))}var eT=d.forwardRef(QM);function kw(e){return uw(eT,e)}kw();const tT=e=>null,rT=e=>null;var Sm=d.createContext(null),nT=d.createContext({}),oT=function(e){for(var t=e.prefixCls,r=e.level,n=e.isStart,o=e.isEnd,a="".concat(t,"-indent-unit"),i=[],l=0;l<r;l+=1)i.push(d.createElement("span",{key:l,className:pe(a,T(T({},"".concat(a,"-start"),n[l]),"".concat(a,"-end"),o[l]))}));return d.createElement("span",{"aria-hidden":"true",className:"".concat(t,"-indent")},i)};const aT=d.memo(oT);var iT=["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","data","onMouseMove","selectable"],ob="open",ab="close",lT="---",gl=function(e){var t,r,n,o=e.eventKey,a=e.className,i=e.style,l=e.dragOver,s=e.dragOverGapTop,u=e.dragOverGapBottom,c=e.isLeaf,f=e.isStart,p=e.isEnd,h=e.expanded,v=e.selected,g=e.checked,m=e.halfChecked,b=e.loading,y=e.domRef,C=e.active,D=e.data,w=e.onMouseMove,k=e.selectable,E=bt(e,iT),x=ee.useContext(Sm),O=ee.useContext(nT),j=ee.useRef(null),$=ee.useState(!1),P=ce($,2),A=P[0],B=P[1],S=!!(x.disabled||e.disabled||(t=O.nodeDisabled)!==null&&t!==void 0&&t.call(O,D)),I=ee.useMemo(function(){return!x.checkable||e.checkable===!1?!1:x.checkable},[x.checkable,e.checkable]),N=function(fe){S||x.onNodeSelect(fe,wr(e))},F=function(fe){S||!I||e.disableCheckbox||x.onNodeCheck(fe,wr(e),!g)},M=ee.useMemo(function(){return typeof k=="boolean"?k:x.selectable},[k,x.selectable]),_=function(fe){x.onNodeClick(fe,wr(e)),M?N(fe):F(fe)},X=function(fe){x.onNodeDoubleClick(fe,wr(e))},H=function(fe){x.onNodeMouseEnter(fe,wr(e))},q=function(fe){x.onNodeMouseLeave(fe,wr(e))},Z=function(fe){x.onNodeContextMenu(fe,wr(e))},te=ee.useMemo(function(){return!!(x.draggable&&(!x.draggable.nodeDraggable||x.draggable.nodeDraggable(D)))},[x.draggable,D]),z=function(fe){fe.stopPropagation(),B(!0),x.onNodeDragStart(fe,e);try{fe.dataTransfer.setData("text/plain","")}catch{}},Y=function(fe){fe.preventDefault(),fe.stopPropagation(),x.onNodeDragEnter(fe,e)},V=function(fe){fe.preventDefault(),fe.stopPropagation(),x.onNodeDragOver(fe,e)},U=function(fe){fe.stopPropagation(),x.onNodeDragLeave(fe,e)},K=function(fe){fe.stopPropagation(),B(!1),x.onNodeDragEnd(fe,e)},W=function(fe){fe.preventDefault(),fe.stopPropagation(),B(!1),x.onNodeDrop(fe,e)},re=function(fe){b||x.onNodeExpand(fe,wr(e))},G=ee.useMemo(function(){var fe=un(x.keyEntities,o)||{},Be=fe.children;return!!(Be||[]).length},[x.keyEntities,o]),J=ee.useMemo(function(){return c===!1?!1:c||!x.loadData&&!G||x.loadData&&e.loaded&&!G},[c,x.loadData,G,e.loaded]);ee.useEffect(function(){b||typeof x.loadData=="function"&&h&&!J&&!e.loaded&&x.onNodeLoad(wr(e))},[b,x.loadData,x.onNodeLoad,h,J,e]);var oe=ee.useMemo(function(){var fe;return(fe=x.draggable)!==null&&fe!==void 0&&fe.icon?ee.createElement("span",{className:"".concat(x.prefixCls,"-draggable-icon")},x.draggable.icon):null},[x.draggable]),se=function(fe){var Be=e.switcherIcon||x.switcherIcon;return typeof Be=="function"?Be(L(L({},e),{},{isLeaf:fe})):Be},ge=function(){if(J){var fe=se(!0);return fe!==!1?ee.createElement("span",{className:pe("".concat(x.prefixCls,"-switcher"),"".concat(x.prefixCls,"-switcher-noop"))},fe):null}var Be=se(!1);return Be!==!1?ee.createElement("span",{onClick:re,className:pe("".concat(x.prefixCls,"-switcher"),"".concat(x.prefixCls,"-switcher_").concat(h?ob:ab))},Be):null},Ee=ee.useMemo(function(){if(!I)return null;var fe=typeof I!="boolean"?I:null;return ee.createElement("span",{className:pe("".concat(x.prefixCls,"-checkbox"),T(T(T({},"".concat(x.prefixCls,"-checkbox-checked"),g),"".concat(x.prefixCls,"-checkbox-indeterminate"),!g&&m),"".concat(x.prefixCls,"-checkbox-disabled"),S||e.disableCheckbox)),onClick:F,role:"checkbox","aria-checked":m?"mixed":g,"aria-disabled":S||e.disableCheckbox,"aria-label":"Select ".concat(typeof e.title=="string"?e.title:"tree node")},fe)},[I,g,m,S,e.disableCheckbox,e.title]),je=ee.useMemo(function(){return J?null:h?ob:ab},[J,h]),ve=ee.useMemo(function(){return ee.createElement("span",{className:pe("".concat(x.prefixCls,"-iconEle"),"".concat(x.prefixCls,"-icon__").concat(je||"docu"),T({},"".concat(x.prefixCls,"-icon_loading"),b))})},[x.prefixCls,je,b]),ye=ee.useMemo(function(){var fe=!!x.draggable,Be=!e.disabled&&fe&&x.dragOverNodeKey===o;return Be?x.dropIndicatorRender({dropPosition:x.dropPosition,dropLevelOffset:x.dropLevelOffset,indent:x.indent,prefixCls:x.prefixCls,direction:x.direction}):null},[x.dropPosition,x.dropLevelOffset,x.indent,x.prefixCls,x.direction,x.draggable,x.dragOverNodeKey,x.dropIndicatorRender]),ke=ee.useMemo(function(){var fe=e.title,Be=fe===void 0?lT:fe,We="".concat(x.prefixCls,"-node-content-wrapper"),Ye;if(x.showIcon){var Ve=e.icon||x.icon;Ye=Ve?ee.createElement("span",{className:pe("".concat(x.prefixCls,"-iconEle"),"".concat(x.prefixCls,"-icon__customize"))},typeof Ve=="function"?Ve(e):Ve):ve}else x.loadData&&b&&(Ye=ve);var Te;return typeof Be=="function"?Te=Be(D):x.titleRender?Te=x.titleRender(D):Te=Be,ee.createElement("span",{ref:j,title:typeof Be=="string"?Be:"",className:pe(We,"".concat(We,"-").concat(je||"normal"),T({},"".concat(x.prefixCls,"-node-selected"),!S&&(v||A))),onMouseEnter:H,onMouseLeave:q,onContextMenu:Z,onClick:_,onDoubleClick:X},Ye,ee.createElement("span",{className:"".concat(x.prefixCls,"-title")},Te),ye)},[x.prefixCls,x.showIcon,e,x.icon,ve,x.titleRender,D,je,H,q,Z,_,X]),we=Qn(E,{aria:!0,data:!0}),De=un(x.keyEntities,o)||{},Ne=De.level,Oe=p[p.length-1],Xe=!S&&te,Le=x.draggingNodeKey===o,Fe=k!==void 0?{"aria-selected":!!k}:void 0;return ee.createElement("div",Me({ref:y,role:"treeitem","aria-expanded":c?void 0:h,className:pe(a,"".concat(x.prefixCls,"-treenode"),(n={},T(T(T(T(T(T(T(T(T(T(n,"".concat(x.prefixCls,"-treenode-disabled"),S),"".concat(x.prefixCls,"-treenode-switcher-").concat(h?"open":"close"),!c),"".concat(x.prefixCls,"-treenode-checkbox-checked"),g),"".concat(x.prefixCls,"-treenode-checkbox-indeterminate"),m),"".concat(x.prefixCls,"-treenode-selected"),v),"".concat(x.prefixCls,"-treenode-loading"),b),"".concat(x.prefixCls,"-treenode-active"),C),"".concat(x.prefixCls,"-treenode-leaf-last"),Oe),"".concat(x.prefixCls,"-treenode-draggable"),te),"dragging",Le),T(T(T(T(T(T(T(n,"drop-target",x.dropTargetKey===o),"drop-container",x.dropContainerKey===o),"drag-over",!S&&l),"drag-over-gap-top",!S&&s),"drag-over-gap-bottom",!S&&u),"filter-node",(r=x.filterTreeNode)===null||r===void 0?void 0:r.call(x,wr(e))),"".concat(x.prefixCls,"-treenode-leaf"),J))),style:i,draggable:Xe,onDragStart:Xe?z:void 0,onDragEnter:te?Y:void 0,onDragOver:te?V:void 0,onDragLeave:te?U:void 0,onDrop:te?W:void 0,onDragEnd:te?K:void 0,onMouseMove:w},Fe,we),ee.createElement(aT,{prefixCls:x.prefixCls,level:Ne,isStart:f,isEnd:p}),oe,ge(),Ee,ke)};gl.isTreeNode=1;function Gn(e,t){if(!e)return[];var r=e.slice(),n=r.indexOf(t);return n>=0&&r.splice(n,1),r}function so(e,t){var r=(e||[]).slice();return r.indexOf(t)===-1&&r.push(t),r}function $m(e){return e.split("-")}function sT(e,t){var r=[],n=un(t,e);function o(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];a.forEach(function(i){var l=i.key,s=i.children;r.push(l),o(s)})}return o(n.children),r}function uT(e){if(e.parent){var t=$m(e.pos);return Number(t[t.length-1])===e.parent.children.length-1}return!1}function cT(e){var t=$m(e.pos);return Number(t[t.length-1])===0}function ib(e,t,r,n,o,a,i,l,s,u){var c,f=e.clientX,p=e.clientY,h=e.target.getBoundingClientRect(),v=h.top,g=h.height,m=(u==="rtl"?-1:1)*(((o==null?void 0:o.x)||0)-f),b=(m-12)/n,y=s.filter(function(I){var N;return(N=l[I])===null||N===void 0||(N=N.children)===null||N===void 0?void 0:N.length}),C=un(l,r.eventKey);if(p<v+g/2){var D=i.findIndex(function(I){return I.key===C.key}),w=D<=0?0:D-1,k=i[w].key;C=un(l,k)}var E=C.key,x=C,O=C.key,j=0,$=0;if(!y.includes(E))for(var P=0;P<b&&uT(C);P+=1)C=C.parent,$+=1;var A=t.data,B=C.node,S=!0;return cT(C)&&C.level===0&&p<v+g/2&&a({dragNode:A,dropNode:B,dropPosition:-1})&&C.key===r.eventKey?j=-1:(x.children||[]).length&&y.includes(O)?a({dragNode:A,dropNode:B,dropPosition:0})?j=0:S=!1:$===0?b>-1.5?a({dragNode:A,dropNode:B,dropPosition:1})?j=1:S=!1:a({dragNode:A,dropNode:B,dropPosition:0})?j=0:a({dragNode:A,dropNode:B,dropPosition:1})?j=1:S=!1:a({dragNode:A,dropNode:B,dropPosition:1})?j=1:S=!1,{dropPosition:j,dropLevelOffset:$,dropTargetKey:C.key,dropTargetPos:C.pos,dragOverNodeKey:O,dropContainerKey:j===0?null:((c=C.parent)===null||c===void 0?void 0:c.key)||null,dropAllowed:S}}function lb(e,t){if(e){var r=t.multiple;return r?e.slice():e.length?[e[0]]:e}}function td(e){if(!e)return null;var t;if(Array.isArray(e))t={checkedKeys:e,halfCheckedKeys:void 0};else if(at(e)==="object")t={checkedKeys:e.checked||void 0,halfCheckedKeys:e.halfChecked||void 0};else return lr(!1,"`checkedKeys` is not an array or an object"),null;return t}function qf(e,t){var r=new Set;function n(o){if(!r.has(o)){var a=un(t,o);if(a){r.add(o);var i=a.parent,l=a.node;l.disabled||i&&n(i.key)}}}return(e||[]).forEach(function(o){n(o)}),Ie(r)}function dT(e){const[t,r]=yt(null);return[mt((n,o,a)=>{const i=t??n,l=Math.min(i||0,n),s=Math.max(i||0,n),u=o.slice(l,s+1).map(p=>e(p)),c=u.some(p=>!a.has(p)),f=[];return u.forEach(p=>{c?(a.has(p)||f.push(p),a.add(p)):(a.delete(p),f.push(p))}),r(c?s:null),f},[t]),n=>{r(n)}]}const ko={},Vf="SELECT_ALL",Gf="SELECT_INVERT",Xf="SELECT_NONE",sb=[],Dw=(e,t,r=[])=>((t||[]).forEach(n=>{r.push(n),n&&typeof n=="object"&&e in n&&Dw(e,n[e],r)}),r),fT=(e,t)=>{const{preserveSelectedRowKeys:r,selectedRowKeys:n,defaultSelectedRowKeys:o,getCheckboxProps:a,getTitleCheckboxProps:i,onChange:l,onSelect:s,onSelectAll:u,onSelectInvert:c,onSelectNone:f,onSelectMultiple:p,columnWidth:h,type:v,selections:g,fixed:m,renderCell:b,hideSelectAll:y,checkStrictly:C=!0}=t||{},{prefixCls:D,data:w,pageData:k,getRecordByKey:E,getRowKey:x,expandType:O,childrenColumnName:j,locale:$,getPopupContainer:P}=e,A=oi(),[B,S]=dT(W=>W),[I,N]=Gr(n||o||sb,{value:n}),F=d.useRef(new Map),M=mt(W=>{if(r){const re=new Map;W.forEach(G=>{let J=E(G);!J&&F.current.has(G)&&(J=F.current.get(G)),re.set(G,J)}),F.current=re}},[E,r]);d.useEffect(()=>{M(I)},[I]);const _=xt(()=>Dw(j,k),[j,k]),{keyEntities:X}=xt(()=>{if(C)return{keyEntities:null};let W=w;if(r){const re=new Set(_.map((J,oe)=>x(J,oe))),G=Array.from(F.current).reduce((J,[oe,se])=>re.has(oe)?J:J.concat(se),[]);W=[].concat(Ie(W),Ie(G))}return bm(W,{externalGetKey:x,childrenPropName:j})},[w,x,C,j,r,_]),H=xt(()=>{const W=new Map;return _.forEach((re,G)=>{const J=x(re,G),oe=(a?a(re):null)||{};W.set(J,oe)}),W},[_,x,a]),q=mt(W=>{const re=x(W);let G;return H.has(re)?G=H.get(x(W)):G=a?a(W):void 0,!!(G!=null&&G.disabled)},[H,x]),[Z,te]=xt(()=>{if(C)return[I||[],[]];const{checkedKeys:W,halfCheckedKeys:re}=ja(I,!0,X,q);return[W||[],re]},[I,C,X,q]),z=xt(()=>{const W=v==="radio"?Z.slice(0,1):Z;return new Set(W)},[Z,v]),Y=xt(()=>v==="radio"?new Set:new Set(te),[te,v]);d.useEffect(()=>{t||N(sb)},[!!t]);const V=mt((W,re)=>{let G,J;M(W),r?(G=W,J=W.map(oe=>F.current.get(oe))):(G=[],J=[],W.forEach(oe=>{const se=E(oe);se!==void 0&&(G.push(oe),J.push(se))})),N(G),l==null||l(G,J,{type:re})},[N,E,l,r]),U=mt((W,re,G,J)=>{if(s){const oe=G.map(se=>E(se));s(E(W),re,oe,J)}V(G,"single")},[s,E,V]),K=xt(()=>!g||y?null:(g===!0?[Vf,Gf,Xf]:g).map(W=>W===Vf?{key:"all",text:$.selectionAll,onSelect(){V(w.map((re,G)=>x(re,G)).filter(re=>{const G=H.get(re);return!(G!=null&&G.disabled)||z.has(re)}),"all")}}:W===Gf?{key:"invert",text:$.selectInvert,onSelect(){const re=new Set(z);k.forEach((J,oe)=>{const se=x(J,oe),ge=H.get(se);ge!=null&&ge.disabled||(re.has(se)?re.delete(se):re.add(se))});const G=Array.from(re);c&&(A.deprecated(!1,"onSelectInvert","onChange"),c(G)),V(G,"invert")}}:W===Xf?{key:"none",text:$.selectNone,onSelect(){f==null||f(),V(Array.from(z).filter(re=>{const G=H.get(re);return G==null?void 0:G.disabled}),"none")}}:W).map(W=>Object.assign(Object.assign({},W),{onSelect:(...re)=>{var G,J;(J=W.onSelect)===null||J===void 0||(G=J).call.apply(G,[W].concat(re)),S(null)}})),[g,z,k,x,c,V]);return[mt(W=>{var re;if(!t)return W.filter(fe=>fe!==ko);let G=Ie(W);const J=new Set(z),oe=_.map(x).filter(fe=>!H.get(fe).disabled),se=oe.every(fe=>J.has(fe)),ge=oe.some(fe=>J.has(fe)),Ee=()=>{const fe=[];se?oe.forEach(We=>{J.delete(We),fe.push(We)}):oe.forEach(We=>{J.has(We)||(J.add(We),fe.push(We))});const Be=Array.from(J);u==null||u(!se,Be.map(We=>E(We)),fe.map(We=>E(We))),V(Be,"all"),S(null)};let je,ve;if(v!=="radio"){let fe;if(K){const nt={getPopupContainer:P,items:K.map((pt,St)=>{const{key:dt,text:ht,onSelect:Pt}=pt;return{key:dt??St,onClick:()=>{Pt==null||Pt(oe)},label:ht}})};fe=d.createElement("div",{className:`${D}-selection-extra`},d.createElement(ym,{menu:nt,getPopupContainer:P},d.createElement("span",null,d.createElement(lx,null))))}const Be=_.map((nt,pt)=>{const St=x(nt,pt),dt=H.get(St)||{};return Object.assign({checked:J.has(St)},dt)}).filter(({disabled:nt})=>nt),We=!!Be.length&&Be.length===_.length,Ye=We&&Be.every(({checked:nt})=>nt),Ve=We&&Be.some(({checked:nt})=>nt),Te=(i==null?void 0:i())||{},{onChange:it,disabled:Ue}=Te;ve=d.createElement(Qa,Object.assign({"aria-label":fe?"Custom selection":"Select all"},Te,{checked:We?Ye:!!_.length&&se,indeterminate:We?!Ye&&Ve:!se&&ge,onChange:nt=>{Ee(),it==null||it(nt)},disabled:Ue??(_.length===0||We),skipGroup:!0})),je=!y&&d.createElement("div",{className:`${D}-selection`},ve,fe)}let ye;v==="radio"?ye=(fe,Be,We)=>{const Ye=x(Be,We),Ve=J.has(Ye),Te=H.get(Ye);return{node:d.createElement($l,Object.assign({},Te,{checked:Ve,onClick:it=>{var Ue;it.stopPropagation(),(Ue=Te==null?void 0:Te.onClick)===null||Ue===void 0||Ue.call(Te,it)},onChange:it=>{var Ue;J.has(Ye)||U(Ye,!0,[Ye],it.nativeEvent),(Ue=Te==null?void 0:Te.onChange)===null||Ue===void 0||Ue.call(Te,it)}})),checked:Ve}}:ye=(fe,Be,We)=>{var Ye;const Ve=x(Be,We),Te=J.has(Ve),it=Y.has(Ve),Ue=H.get(Ve);let nt;return O==="nest"?nt=it:nt=(Ye=Ue==null?void 0:Ue.indeterminate)!==null&&Ye!==void 0?Ye:it,{node:d.createElement(Qa,Object.assign({},Ue,{indeterminate:nt,checked:Te,skipGroup:!0,onClick:pt=>{var St;pt.stopPropagation(),(St=Ue==null?void 0:Ue.onClick)===null||St===void 0||St.call(Ue,pt)},onChange:pt=>{var St;const{nativeEvent:dt}=pt,{shiftKey:ht}=dt,Pt=oe.findIndex(ct=>ct===Ve),At=Z.some(ct=>oe.includes(ct));if(ht&&C&&At){const ct=B(Pt,oe,J),ut=Array.from(J);p==null||p(!Te,ut.map(ae=>E(ae)),ct.map(ae=>E(ae))),V(ut,"multiple")}else{const ct=Z;if(C){const ut=Te?Gn(ct,Ve):so(ct,Ve);U(Ve,!Te,ut,dt)}else{const ut=ja([].concat(Ie(ct),[Ve]),!0,X,q),{checkedKeys:ae,halfCheckedKeys:he}=ut;let xe=ae;if(Te){const be=new Set(ae);be.delete(Ve),xe=ja(Array.from(be),{halfCheckedKeys:he},X,q).checkedKeys}U(Ve,!Te,xe,dt)}}S(Te?null:Pt),(St=Ue==null?void 0:Ue.onChange)===null||St===void 0||St.call(Ue,pt)}})),checked:Te}};const ke=(fe,Be,We)=>{const{node:Ye,checked:Ve}=ye(fe,Be,We);return b?b(Ve,Be,We,Ye):Ye};if(!G.includes(ko))if(G.findIndex(fe=>{var Be;return((Be=fe[Hi])===null||Be===void 0?void 0:Be.columnType)==="EXPAND_COLUMN"})===0){const[fe,...Be]=G;G=[fe,ko].concat(Ie(Be))}else G=[ko].concat(Ie(G));const we=G.indexOf(ko);G=G.filter((fe,Be)=>fe!==ko||Be===we);const De=G[we-1],Ne=G[we+1];let Oe=m;Oe===void 0&&((Ne==null?void 0:Ne.fixed)!==void 0?Oe=Ne.fixed:(De==null?void 0:De.fixed)!==void 0&&(Oe=De.fixed)),Oe&&De&&((re=De[Hi])===null||re===void 0?void 0:re.columnType)==="EXPAND_COLUMN"&&De.fixed===void 0&&(De.fixed=Oe);const Xe=pe(`${D}-selection-col`,{[`${D}-selection-col-with-dropdown`]:g&&v==="checkbox"}),Le=()=>t!=null&&t.columnTitle?typeof t.columnTitle=="function"?t.columnTitle(ve):t.columnTitle:je,Fe={fixed:Oe,width:h,className:`${D}-selection-column`,title:Le(),render:ke,onCell:t.onCell,align:t.align,[Hi]:{className:Xe}};return G.map(fe=>fe===ko?Fe:fe)},[x,_,t,Z,z,Y,h,K,O,H,p,U,q]),z]};function pT(e,t){return e._antProxy=e._antProxy||{},Object.keys(t).forEach(r=>{if(!(r in e._antProxy)){const n=e[r];e._antProxy[r]=n,e[r]=t[r]}}),e}function mT(e,t){return ei(e,()=>{const r=t(),{nativeElement:n}=r;return typeof Proxy<"u"?new Proxy(n,{get(o,a){return r[a]?r[a]:Reflect.get(o,a)}}):pT(n,r)})}function hT(e){return t=>{const{prefixCls:r,onExpand:n,record:o,expanded:a,expandable:i}=t,l=`${r}-row-expand-icon`;return d.createElement("button",{type:"button",onClick:s=>{n(o,s),s.stopPropagation()},className:pe(l,{[`${l}-spaced`]:!i,[`${l}-expanded`]:i&&a,[`${l}-collapsed`]:i&&!a}),"aria-label":a?e.collapse:e.expand,"aria-expanded":a})}}function gT(e){return(t,r)=>{const n=t.querySelector(`.${e}-container`);let o=r;if(n){const a=getComputedStyle(n),i=parseInt(a.borderLeftWidth,10),l=parseInt(a.borderRightWidth,10);o=r-i-l}return o}}const jo=(e,t)=>"key"in e&&e.key!==void 0&&e.key!==null?e.key:e.dataIndex?Array.isArray(e.dataIndex)?e.dataIndex.join("."):e.dataIndex:t;function pi(e,t){return t?`${t}-${e}`:`${e}`}const Ku=(e,t)=>typeof e=="function"?e(t):e,vT=(e,t)=>{const r=Ku(e,t);return Object.prototype.toString.call(r)==="[object Object]"?"":r};function bT(e){const t=d.useRef(e),r=cx();return[()=>t.current,n=>{t.current=n,r()}]}var yT=function(e){var t=e.dropPosition,r=e.dropLevelOffset,n=e.indent,o={pointerEvents:"none",position:"absolute",right:0,backgroundColor:"red",height:2};switch(t){case-1:o.top=0,o.left=-r*n;break;case 1:o.bottom=0,o.left=-r*n;break;case 0:o.bottom=0,o.left=n;break}return ee.createElement("div",{style:o})};function Sw(e){if(e==null)throw new TypeError("Cannot destructure "+e)}function CT(e,t){var r=d.useState(!1),n=ce(r,2),o=n[0],a=n[1];Wt(function(){if(o)return e(),function(){t()}},[o]),Wt(function(){return a(!0),function(){a(!1)}},[])}var xT=["className","style","motion","motionNodes","motionType","onMotionStart","onMotionEnd","active","treeNodeRequiredProps"],wT=d.forwardRef(function(e,t){var r=e.className,n=e.style,o=e.motion,a=e.motionNodes,i=e.motionType,l=e.onMotionStart,s=e.onMotionEnd,u=e.active,c=e.treeNodeRequiredProps,f=bt(e,xT),p=d.useState(!0),h=ce(p,2),v=h[0],g=h[1],m=d.useContext(Sm),b=m.prefixCls,y=a&&i!=="hide";Wt(function(){a&&y!==v&&g(y)},[a]);var C=function(){a&&l()},D=d.useRef(!1),w=function(){a&&!D.current&&(D.current=!0,s())};CT(C,w);var k=function(E){y===E&&w()};return a?d.createElement(ca,Me({ref:t,visible:v},o,{motionAppear:i==="show",onVisibleChanged:k}),function(E,x){var O=E.className,j=E.style;return d.createElement("div",{ref:x,className:pe("".concat(b,"-treenode-motion"),O),style:j},a.map(function($){var P=Object.assign({},(Sw($.data),$.data)),A=$.title,B=$.key,S=$.isStart,I=$.isEnd;delete P.children;var N=Li(B,c);return d.createElement(gl,Me({},P,N,{title:A,active:u,data:$.data,key:B,isStart:S,isEnd:I}))}))}):d.createElement(gl,Me({domRef:t,className:r,style:n},f,{active:u}))});function ET(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=e.length,n=t.length;if(Math.abs(r-n)!==1)return{add:!1,key:null};function o(a,i){var l=new Map;a.forEach(function(u){l.set(u,!0)});var s=i.filter(function(u){return!l.has(u)});return s.length===1?s[0]:null}return r<n?{add:!0,key:o(e,t)}:{add:!1,key:o(t,e)}}function ub(e,t,r){var n=e.findIndex(function(l){return l.key===r}),o=e[n+1],a=t.findIndex(function(l){return l.key===r});if(o){var i=t.findIndex(function(l){return l.key===o.key});return t.slice(a+1,i)}return t.slice(a+1)}var kT=["prefixCls","data","selectable","checkable","expandedKeys","selectedKeys","checkedKeys","loadedKeys","loadingKeys","halfCheckedKeys","keyEntities","disabled","dragging","dragOverNodeKey","dropPosition","motion","height","itemHeight","virtual","scrollWidth","focusable","activeItem","focused","tabIndex","onKeyDown","onFocus","onBlur","onActiveChange","onListChangeStart","onListChangeEnd"],cb={width:0,height:0,display:"flex",overflow:"hidden",opacity:0,border:0,padding:0,margin:0},DT=function(){},aa="RC_TREE_MOTION_".concat(Math.random()),Uf={key:aa},$w={key:aa,level:0,index:0,pos:"0",node:Uf,nodes:[Uf]},db={parent:null,children:[],pos:$w.pos,data:Uf,title:null,key:aa,isStart:[],isEnd:[]};function fb(e,t,r,n){return t===!1||!r?e:e.slice(0,Math.ceil(r/n)+1)}function pb(e){var t=e.key,r=e.pos;return Bl(t,r)}function ST(e){for(var t=String(e.data.key),r=e;r.parent;)r=r.parent,t="".concat(r.data.key," > ").concat(t);return t}var $T=d.forwardRef(function(e,t){var r=e.prefixCls,n=e.data;e.selectable,e.checkable;var o=e.expandedKeys,a=e.selectedKeys,i=e.checkedKeys,l=e.loadedKeys,s=e.loadingKeys,u=e.halfCheckedKeys,c=e.keyEntities,f=e.disabled,p=e.dragging,h=e.dragOverNodeKey,v=e.dropPosition,g=e.motion,m=e.height,b=e.itemHeight,y=e.virtual,C=e.scrollWidth,D=e.focusable,w=e.activeItem,k=e.focused,E=e.tabIndex,x=e.onKeyDown,O=e.onFocus,j=e.onBlur,$=e.onActiveChange,P=e.onListChangeStart,A=e.onListChangeEnd,B=bt(e,kT),S=d.useRef(null),I=d.useRef(null);d.useImperativeHandle(t,function(){return{scrollTo:function(ye){S.current.scrollTo(ye)},getIndentWidth:function(){return I.current.offsetWidth}}});var N=d.useState(o),F=ce(N,2),M=F[0],_=F[1],X=d.useState(n),H=ce(X,2),q=H[0],Z=H[1],te=d.useState(n),z=ce(te,2),Y=z[0],V=z[1],U=d.useState([]),K=ce(U,2),W=K[0],re=K[1],G=d.useState(null),J=ce(G,2),oe=J[0],se=J[1],ge=d.useRef(n);ge.current=n;function Ee(){var ye=ge.current;Z(ye),V(ye),re([]),se(null),A()}Wt(function(){_(o);var ye=ET(M,o);if(ye.key!==null)if(ye.add){var ke=q.findIndex(function(Le){var Fe=Le.key;return Fe===ye.key}),we=fb(ub(q,n,ye.key),y,m,b),De=q.slice();De.splice(ke+1,0,db),V(De),re(we),se("show")}else{var Ne=n.findIndex(function(Le){var Fe=Le.key;return Fe===ye.key}),Oe=fb(ub(n,q,ye.key),y,m,b),Xe=n.slice();Xe.splice(Ne+1,0,db),V(Xe),re(Oe),se("hide")}else q!==n&&(Z(n),V(n))},[o,n]),d.useEffect(function(){p||Ee()},[p]);var je=g?Y:n,ve={expandedKeys:o,selectedKeys:a,loadedKeys:l,loadingKeys:s,checkedKeys:i,halfCheckedKeys:u,dragOverNodeKey:h,dropPosition:v,keyEntities:c};return d.createElement(d.Fragment,null,k&&w&&d.createElement("span",{style:cb,"aria-live":"assertive"},ST(w)),d.createElement("div",null,d.createElement("input",{style:cb,disabled:D===!1||f,tabIndex:D!==!1?E:null,onKeyDown:x,onFocus:O,onBlur:j,value:"",onChange:DT,"aria-label":"for screen reader"})),d.createElement("div",{className:"".concat(r,"-treenode"),"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},d.createElement("div",{className:"".concat(r,"-indent")},d.createElement("div",{ref:I,className:"".concat(r,"-indent-unit")}))),d.createElement(Ru,Me({},B,{data:je,itemKey:pb,height:m,fullHeight:!1,virtual:y,itemHeight:b,scrollWidth:C,prefixCls:"".concat(r,"-list"),ref:S,role:"tree",onVisibleChange:function(ye){ye.every(function(ke){return pb(ke)!==aa})&&Ee()}}),function(ye){var ke=ye.pos,we=Object.assign({},(Sw(ye.data),ye.data)),De=ye.title,Ne=ye.key,Oe=ye.isStart,Xe=ye.isEnd,Le=Bl(Ne,ke);delete we.key,delete we.children;var Fe=Li(Le,ve);return d.createElement(wT,Me({},we,Fe,{title:De,active:!!w&&Ne===w.key,pos:ke,data:ye.data,isStart:Oe,isEnd:Xe,motion:g,motionNodes:Ne===aa?W:null,motionType:oe,onMotionStart:P,onMotionEnd:Ee,treeNodeRequiredProps:ve,onMouseMove:function(){$(null)}}))}))}),BT=10,Bm=(function(e){no(r,e);var t=oo(r);function r(){var n;vr(this,r);for(var o=arguments.length,a=new Array(o),i=0;i<o;i++)a[i]=arguments[i];return n=t.call.apply(t,[this].concat(a)),T(et(n),"destroyed",!1),T(et(n),"delayedDragEnterLogic",void 0),T(et(n),"loadingRetryTimes",{}),T(et(n),"state",{keyEntities:{},indent:null,selectedKeys:[],checkedKeys:[],halfCheckedKeys:[],loadedKeys:[],loadingKeys:[],expandedKeys:[],draggingNodeKey:null,dragChildrenKeys:[],dropTargetKey:null,dropPosition:null,dropContainerKey:null,dropLevelOffset:null,dropTargetPos:null,dropAllowed:!0,dragOverNodeKey:null,treeData:[],flattenNodes:[],focused:!1,activeKey:null,listChanging:!1,prevProps:null,fieldNames:Ja()}),T(et(n),"dragStartMousePosition",null),T(et(n),"dragNodeProps",null),T(et(n),"currentMouseOverDroppableNodeKey",null),T(et(n),"listRef",d.createRef()),T(et(n),"onNodeDragStart",function(l,s){var u=n.state,c=u.expandedKeys,f=u.keyEntities,p=n.props.onDragStart,h=s.eventKey;n.dragNodeProps=s,n.dragStartMousePosition={x:l.clientX,y:l.clientY};var v=Gn(c,h);n.setState({draggingNodeKey:h,dragChildrenKeys:sT(h,f),indent:n.listRef.current.getIndentWidth()}),n.setExpandedKeys(v),window.addEventListener("dragend",n.onWindowDragEnd),p==null||p({event:l,node:wr(s)})}),T(et(n),"onNodeDragEnter",function(l,s){var u=n.state,c=u.expandedKeys,f=u.keyEntities,p=u.dragChildrenKeys,h=u.flattenNodes,v=u.indent,g=n.props,m=g.onDragEnter,b=g.onExpand,y=g.allowDrop,C=g.direction,D=s.pos,w=s.eventKey;if(n.currentMouseOverDroppableNodeKey!==w&&(n.currentMouseOverDroppableNodeKey=w),!n.dragNodeProps){n.resetDragState();return}var k=ib(l,n.dragNodeProps,s,v,n.dragStartMousePosition,y,h,f,c,C),E=k.dropPosition,x=k.dropLevelOffset,O=k.dropTargetKey,j=k.dropContainerKey,$=k.dropTargetPos,P=k.dropAllowed,A=k.dragOverNodeKey;if(p.includes(O)||!P){n.resetDragState();return}if(n.delayedDragEnterLogic||(n.delayedDragEnterLogic={}),Object.keys(n.delayedDragEnterLogic).forEach(function(B){clearTimeout(n.delayedDragEnterLogic[B])}),n.dragNodeProps.eventKey!==s.eventKey&&(l.persist(),n.delayedDragEnterLogic[D]=window.setTimeout(function(){if(n.state.draggingNodeKey!==null){var B=Ie(c),S=un(f,s.eventKey);S&&(S.children||[]).length&&(B=so(c,s.eventKey)),n.props.hasOwnProperty("expandedKeys")||n.setExpandedKeys(B),b==null||b(B,{node:wr(s),expanded:!0,nativeEvent:l.nativeEvent})}},800)),n.dragNodeProps.eventKey===O&&x===0){n.resetDragState();return}n.setState({dragOverNodeKey:A,dropPosition:E,dropLevelOffset:x,dropTargetKey:O,dropContainerKey:j,dropTargetPos:$,dropAllowed:P}),m==null||m({event:l,node:wr(s),expandedKeys:c})}),T(et(n),"onNodeDragOver",function(l,s){var u=n.state,c=u.dragChildrenKeys,f=u.flattenNodes,p=u.keyEntities,h=u.expandedKeys,v=u.indent,g=n.props,m=g.onDragOver,b=g.allowDrop,y=g.direction;if(n.dragNodeProps){var C=ib(l,n.dragNodeProps,s,v,n.dragStartMousePosition,b,f,p,h,y),D=C.dropPosition,w=C.dropLevelOffset,k=C.dropTargetKey,E=C.dropContainerKey,x=C.dropTargetPos,O=C.dropAllowed,j=C.dragOverNodeKey;c.includes(k)||!O||(n.dragNodeProps.eventKey===k&&w===0?n.state.dropPosition===null&&n.state.dropLevelOffset===null&&n.state.dropTargetKey===null&&n.state.dropContainerKey===null&&n.state.dropTargetPos===null&&n.state.dropAllowed===!1&&n.state.dragOverNodeKey===null||n.resetDragState():D===n.state.dropPosition&&w===n.state.dropLevelOffset&&k===n.state.dropTargetKey&&E===n.state.dropContainerKey&&x===n.state.dropTargetPos&&O===n.state.dropAllowed&&j===n.state.dragOverNodeKey||n.setState({dropPosition:D,dropLevelOffset:w,dropTargetKey:k,dropContainerKey:E,dropTargetPos:x,dropAllowed:O,dragOverNodeKey:j}),m==null||m({event:l,node:wr(s)}))}}),T(et(n),"onNodeDragLeave",function(l,s){n.currentMouseOverDroppableNodeKey===s.eventKey&&!l.currentTarget.contains(l.relatedTarget)&&(n.resetDragState(),n.currentMouseOverDroppableNodeKey=null);var u=n.props.onDragLeave;u==null||u({event:l,node:wr(s)})}),T(et(n),"onWindowDragEnd",function(l){n.onNodeDragEnd(l,null,!0),window.removeEventListener("dragend",n.onWindowDragEnd)}),T(et(n),"onNodeDragEnd",function(l,s){var u=n.props.onDragEnd;n.setState({dragOverNodeKey:null}),n.cleanDragState(),u==null||u({event:l,node:wr(s)}),n.dragNodeProps=null,window.removeEventListener("dragend",n.onWindowDragEnd)}),T(et(n),"onNodeDrop",function(l,s){var u,c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,f=n.state,p=f.dragChildrenKeys,h=f.dropPosition,v=f.dropTargetKey,g=f.dropTargetPos,m=f.dropAllowed;if(m){var b=n.props.onDrop;if(n.setState({dragOverNodeKey:null}),n.cleanDragState(),v!==null){var y=L(L({},Li(v,n.getTreeNodeRequiredProps())),{},{active:((u=n.getActiveItem())===null||u===void 0?void 0:u.key)===v,data:un(n.state.keyEntities,v).node}),C=p.includes(v);lr(!C,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");var D=$m(g),w={event:l,node:wr(y),dragNode:n.dragNodeProps?wr(n.dragNodeProps):null,dragNodesKeys:[n.dragNodeProps.eventKey].concat(p),dropToGap:h!==0,dropPosition:h+Number(D[D.length-1])};c||(b==null||b(w)),n.dragNodeProps=null}}}),T(et(n),"cleanDragState",function(){var l=n.state.draggingNodeKey;l!==null&&n.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),n.dragStartMousePosition=null,n.currentMouseOverDroppableNodeKey=null}),T(et(n),"triggerExpandActionExpand",function(l,s){var u=n.state,c=u.expandedKeys,f=u.flattenNodes,p=s.expanded,h=s.key,v=s.isLeaf;if(!(v||l.shiftKey||l.metaKey||l.ctrlKey)){var g=f.filter(function(b){return b.key===h})[0],m=wr(L(L({},Li(h,n.getTreeNodeRequiredProps())),{},{data:g.data}));n.setExpandedKeys(p?Gn(c,h):so(c,h)),n.onNodeExpand(l,m)}}),T(et(n),"onNodeClick",function(l,s){var u=n.props,c=u.onClick,f=u.expandAction;f==="click"&&n.triggerExpandActionExpand(l,s),c==null||c(l,s)}),T(et(n),"onNodeDoubleClick",function(l,s){var u=n.props,c=u.onDoubleClick,f=u.expandAction;f==="doubleClick"&&n.triggerExpandActionExpand(l,s),c==null||c(l,s)}),T(et(n),"onNodeSelect",function(l,s){var u=n.state.selectedKeys,c=n.state,f=c.keyEntities,p=c.fieldNames,h=n.props,v=h.onSelect,g=h.multiple,m=s.selected,b=s[p.key],y=!m;y?g?u=so(u,b):u=[b]:u=Gn(u,b);var C=u.map(function(D){var w=un(f,D);return w?w.node:null}).filter(Boolean);n.setUncontrolledState({selectedKeys:u}),v==null||v(u,{event:"select",selected:y,node:s,selectedNodes:C,nativeEvent:l.nativeEvent})}),T(et(n),"onNodeCheck",function(l,s,u){var c=n.state,f=c.keyEntities,p=c.checkedKeys,h=c.halfCheckedKeys,v=n.props,g=v.checkStrictly,m=v.onCheck,b=s.key,y,C={event:"check",node:s,checked:u,nativeEvent:l.nativeEvent};if(g){var D=u?so(p,b):Gn(p,b),w=Gn(h,b);y={checked:D,halfChecked:w},C.checkedNodes=D.map(function($){return un(f,$)}).filter(Boolean).map(function($){return $.node}),n.setUncontrolledState({checkedKeys:D})}else{var k=ja([].concat(Ie(p),[b]),!0,f),E=k.checkedKeys,x=k.halfCheckedKeys;if(!u){var O=new Set(E);O.delete(b);var j=ja(Array.from(O),{halfCheckedKeys:x},f);E=j.checkedKeys,x=j.halfCheckedKeys}y=E,C.checkedNodes=[],C.checkedNodesPositions=[],C.halfCheckedKeys=x,E.forEach(function($){var P=un(f,$);if(P){var A=P.node,B=P.pos;C.checkedNodes.push(A),C.checkedNodesPositions.push({node:A,pos:B})}}),n.setUncontrolledState({checkedKeys:E},!1,{halfCheckedKeys:x})}m==null||m(y,C)}),T(et(n),"onNodeLoad",function(l){var s,u=l.key,c=n.state.keyEntities,f=un(c,u);if(!(f!=null&&(s=f.children)!==null&&s!==void 0&&s.length)){var p=new Promise(function(h,v){n.setState(function(g){var m=g.loadedKeys,b=m===void 0?[]:m,y=g.loadingKeys,C=y===void 0?[]:y,D=n.props,w=D.loadData,k=D.onLoad;if(!w||b.includes(u)||C.includes(u))return null;var E=w(l);return E.then(function(){var x=n.state.loadedKeys,O=so(x,u);k==null||k(O,{event:"load",node:l}),n.setUncontrolledState({loadedKeys:O}),n.setState(function(j){return{loadingKeys:Gn(j.loadingKeys,u)}}),h()}).catch(function(x){if(n.setState(function(j){return{loadingKeys:Gn(j.loadingKeys,u)}}),n.loadingRetryTimes[u]=(n.loadingRetryTimes[u]||0)+1,n.loadingRetryTimes[u]>=BT){var O=n.state.loadedKeys;lr(!1,"Retry for `loadData` many times but still failed. No more retry."),n.setUncontrolledState({loadedKeys:so(O,u)}),h()}v(x)}),{loadingKeys:so(C,u)}})});return p.catch(function(){}),p}}),T(et(n),"onNodeMouseEnter",function(l,s){var u=n.props.onMouseEnter;u==null||u({event:l,node:s})}),T(et(n),"onNodeMouseLeave",function(l,s){var u=n.props.onMouseLeave;u==null||u({event:l,node:s})}),T(et(n),"onNodeContextMenu",function(l,s){var u=n.props.onRightClick;u&&(l.preventDefault(),u({event:l,node:s}))}),T(et(n),"onFocus",function(){var l=n.props.onFocus;n.setState({focused:!0});for(var s=arguments.length,u=new Array(s),c=0;c<s;c++)u[c]=arguments[c];l==null||l.apply(void 0,u)}),T(et(n),"onBlur",function(){var l=n.props.onBlur;n.setState({focused:!1}),n.onActiveChange(null);for(var s=arguments.length,u=new Array(s),c=0;c<s;c++)u[c]=arguments[c];l==null||l.apply(void 0,u)}),T(et(n),"getTreeNodeRequiredProps",function(){var l=n.state,s=l.expandedKeys,u=l.selectedKeys,c=l.loadedKeys,f=l.loadingKeys,p=l.checkedKeys,h=l.halfCheckedKeys,v=l.dragOverNodeKey,g=l.dropPosition,m=l.keyEntities;return{expandedKeys:s||[],selectedKeys:u||[],loadedKeys:c||[],loadingKeys:f||[],checkedKeys:p||[],halfCheckedKeys:h||[],dragOverNodeKey:v,dropPosition:g,keyEntities:m}}),T(et(n),"setExpandedKeys",function(l){var s=n.state,u=s.treeData,c=s.fieldNames,f=Qc(u,l,c);n.setUncontrolledState({expandedKeys:l,flattenNodes:f},!0)}),T(et(n),"onNodeExpand",function(l,s){var u=n.state.expandedKeys,c=n.state,f=c.listChanging,p=c.fieldNames,h=n.props,v=h.onExpand,g=h.loadData,m=s.expanded,b=s[p.key];if(!f){var y=u.includes(b),C=!m;if(lr(m&&y||!m&&!y,"Expand state not sync with index check"),u=C?so(u,b):Gn(u,b),n.setExpandedKeys(u),v==null||v(u,{node:s,expanded:C,nativeEvent:l.nativeEvent}),C&&g){var D=n.onNodeLoad(s);D&&D.then(function(){var w=Qc(n.state.treeData,u,p);n.setUncontrolledState({flattenNodes:w})}).catch(function(){var w=n.state.expandedKeys,k=Gn(w,b);n.setExpandedKeys(k)})}}}),T(et(n),"onListChangeStart",function(){n.setUncontrolledState({listChanging:!0})}),T(et(n),"onListChangeEnd",function(){setTimeout(function(){n.setUncontrolledState({listChanging:!1})})}),T(et(n),"onActiveChange",function(l){var s=n.state.activeKey,u=n.props,c=u.onActiveChange,f=u.itemScrollOffset,p=f===void 0?0:f;s!==l&&(n.setState({activeKey:l}),l!==null&&n.scrollTo({key:l,offset:p}),c==null||c(l))}),T(et(n),"getActiveItem",function(){var l=n.state,s=l.activeKey,u=l.flattenNodes;return s===null?null:u.find(function(c){var f=c.key;return f===s})||null}),T(et(n),"offsetActiveKey",function(l){var s=n.state,u=s.flattenNodes,c=s.activeKey,f=u.findIndex(function(v){var g=v.key;return g===c});f===-1&&l<0&&(f=u.length),f=(f+l+u.length)%u.length;var p=u[f];if(p){var h=p.key;n.onActiveChange(h)}else n.onActiveChange(null)}),T(et(n),"onKeyDown",function(l){var s=n.state,u=s.activeKey,c=s.expandedKeys,f=s.checkedKeys,p=s.fieldNames,h=n.props,v=h.onKeyDown,g=h.checkable,m=h.selectable;switch(l.which){case rt.UP:{n.offsetActiveKey(-1),l.preventDefault();break}case rt.DOWN:{n.offsetActiveKey(1),l.preventDefault();break}}var b=n.getActiveItem();if(b&&b.data){var y=n.getTreeNodeRequiredProps(),C=b.data.isLeaf===!1||!!(b.data[p.children]||[]).length,D=wr(L(L({},Li(u,y)),{},{data:b.data,active:!0}));switch(l.which){case rt.LEFT:{C&&c.includes(u)?n.onNodeExpand({},D):b.parent&&n.onActiveChange(b.parent.key),l.preventDefault();break}case rt.RIGHT:{C&&!c.includes(u)?n.onNodeExpand({},D):b.children&&b.children.length&&n.onActiveChange(b.children[0].key),l.preventDefault();break}case rt.ENTER:case rt.SPACE:{g&&!D.disabled&&D.checkable!==!1&&!D.disableCheckbox?n.onNodeCheck({},D,!f.includes(u)):!g&&m&&!D.disabled&&D.selectable!==!1&&n.onNodeSelect({},D);break}}}v==null||v(l)}),T(et(n),"setUncontrolledState",function(l){var s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(!n.destroyed){var c=!1,f=!0,p={};Object.keys(l).forEach(function(h){if(n.props.hasOwnProperty(h)){f=!1;return}c=!0,p[h]=l[h]}),c&&(!s||f)&&n.setState(L(L({},p),u))}}),T(et(n),"scrollTo",function(l){n.listRef.current.scrollTo(l)}),n}return br(r,[{key:"componentDidMount",value:function(){this.destroyed=!1,this.onUpdated()}},{key:"componentDidUpdate",value:function(){this.onUpdated()}},{key:"onUpdated",value:function(){var n=this.props,o=n.activeKey,a=n.itemScrollOffset,i=a===void 0?0:a;o!==void 0&&o!==this.state.activeKey&&(this.setState({activeKey:o}),o!==null&&this.scrollTo({key:o,offset:i}))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("dragend",this.onWindowDragEnd),this.destroyed=!0}},{key:"resetDragState",value:function(){this.setState({dragOverNodeKey:null,dropPosition:null,dropLevelOffset:null,dropTargetKey:null,dropContainerKey:null,dropTargetPos:null,dropAllowed:!1})}},{key:"render",value:function(){var n=this.state,o=n.focused,a=n.flattenNodes,i=n.keyEntities,l=n.draggingNodeKey,s=n.activeKey,u=n.dropLevelOffset,c=n.dropContainerKey,f=n.dropTargetKey,p=n.dropPosition,h=n.dragOverNodeKey,v=n.indent,g=this.props,m=g.prefixCls,b=g.className,y=g.style,C=g.showLine,D=g.focusable,w=g.tabIndex,k=w===void 0?0:w,E=g.selectable,x=g.showIcon,O=g.icon,j=g.switcherIcon,$=g.draggable,P=g.checkable,A=g.checkStrictly,B=g.disabled,S=g.motion,I=g.loadData,N=g.filterTreeNode,F=g.height,M=g.itemHeight,_=g.scrollWidth,X=g.virtual,H=g.titleRender,q=g.dropIndicatorRender,Z=g.onContextMenu,te=g.onScroll,z=g.direction,Y=g.rootClassName,V=g.rootStyle,U=Qn(this.props,{aria:!0,data:!0}),K;$&&(at($)==="object"?K=$:typeof $=="function"?K={nodeDraggable:$}:K={});var W={prefixCls:m,selectable:E,showIcon:x,icon:O,switcherIcon:j,draggable:K,draggingNodeKey:l,checkable:P,checkStrictly:A,disabled:B,keyEntities:i,dropLevelOffset:u,dropContainerKey:c,dropTargetKey:f,dropPosition:p,dragOverNodeKey:h,indent:v,direction:z,dropIndicatorRender:q,loadData:I,filterTreeNode:N,titleRender:H,onNodeClick:this.onNodeClick,onNodeDoubleClick:this.onNodeDoubleClick,onNodeExpand:this.onNodeExpand,onNodeSelect:this.onNodeSelect,onNodeCheck:this.onNodeCheck,onNodeLoad:this.onNodeLoad,onNodeMouseEnter:this.onNodeMouseEnter,onNodeMouseLeave:this.onNodeMouseLeave,onNodeContextMenu:this.onNodeContextMenu,onNodeDragStart:this.onNodeDragStart,onNodeDragEnter:this.onNodeDragEnter,onNodeDragOver:this.onNodeDragOver,onNodeDragLeave:this.onNodeDragLeave,onNodeDragEnd:this.onNodeDragEnd,onNodeDrop:this.onNodeDrop};return d.createElement(Sm.Provider,{value:W},d.createElement("div",{className:pe(m,b,Y,T(T(T({},"".concat(m,"-show-line"),C),"".concat(m,"-focused"),o),"".concat(m,"-active-focused"),s!==null)),style:V},d.createElement($T,Me({ref:this.listRef,prefixCls:m,style:y,data:a,disabled:B,selectable:E,checkable:!!P,motion:S,dragging:l!==null,height:F,itemHeight:M,virtual:X,focusable:D,focused:o,tabIndex:k,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:Z,onScroll:te,scrollWidth:_},this.getTreeNodeRequiredProps(),U))))}}],[{key:"getDerivedStateFromProps",value:function(n,o){var a=o.prevProps,i={prevProps:n};function l(k){return!a&&n.hasOwnProperty(k)||a&&a[k]!==n[k]}var s,u=o.fieldNames;if(l("fieldNames")&&(u=Ja(n.fieldNames),i.fieldNames=u),l("treeData")?s=n.treeData:l("children")&&(lr(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),s=Gx(n.children)),s){i.treeData=s;var c=bm(s,{fieldNames:u});i.keyEntities=L(T({},aa,$w),c.keyEntities)}var f=i.keyEntities||o.keyEntities;if(l("expandedKeys")||a&&l("autoExpandParent"))i.expandedKeys=n.autoExpandParent||!a&&n.defaultExpandParent?qf(n.expandedKeys,f):n.expandedKeys;else if(!a&&n.defaultExpandAll){var p=L({},f);delete p[aa];var h=[];Object.keys(p).forEach(function(k){var E=p[k];E.children&&E.children.length&&h.push(E.key)}),i.expandedKeys=h}else!a&&n.defaultExpandedKeys&&(i.expandedKeys=n.autoExpandParent||n.defaultExpandParent?qf(n.defaultExpandedKeys,f):n.defaultExpandedKeys);if(i.expandedKeys||delete i.expandedKeys,s||i.expandedKeys){var v=Qc(s||o.treeData,i.expandedKeys||o.expandedKeys,u);i.flattenNodes=v}if(n.selectable&&(l("selectedKeys")?i.selectedKeys=lb(n.selectedKeys,n):!a&&n.defaultSelectedKeys&&(i.selectedKeys=lb(n.defaultSelectedKeys,n))),n.checkable){var g;if(l("checkedKeys")?g=td(n.checkedKeys)||{}:!a&&n.defaultCheckedKeys?g=td(n.defaultCheckedKeys)||{}:s&&(g=td(n.checkedKeys)||{checkedKeys:o.checkedKeys,halfCheckedKeys:o.halfCheckedKeys}),g){var m=g,b=m.checkedKeys,y=b===void 0?[]:b,C=m.halfCheckedKeys,D=C===void 0?[]:C;if(!n.checkStrictly){var w=ja(y,!0,f);y=w.checkedKeys,D=w.halfCheckedKeys}i.checkedKeys=y,i.halfCheckedKeys=D}}return l("loadedKeys")&&(i.loadedKeys=n.loadedKeys),i}}]),r})(d.Component);T(Bm,"defaultProps",{prefixCls:"rc-tree",showLine:!1,showIcon:!0,selectable:!0,multiple:!1,checkable:!1,disabled:!1,checkStrictly:!1,draggable:!1,defaultExpandParent:!0,autoExpandParent:!1,defaultExpandAll:!1,defaultExpandedKeys:[],defaultCheckedKeys:[],defaultSelectedKeys:[],dropIndicatorRender:yT,allowDrop:function(){return!0},expandAction:!1});T(Bm,"TreeNode",gl);const OT=({treeCls:e,treeNodeCls:t,directoryNodeSelectedBg:r,directoryNodeSelectedColor:n,motionDurationMid:o,borderRadius:a,controlItemBgHover:i})=>({[`${e}${e}-directory ${t}`]:{[`${e}-node-content-wrapper`]:{position:"static",[`&:has(${e}-drop-indicator)`]:{position:"relative"},[`> *:not(${e}-drop-indicator)`]:{position:"relative"},"&:hover":{background:"transparent"},"&:before":{position:"absolute",inset:0,transition:`background-color ${o}`,content:'""',borderRadius:a},"&:hover:before":{background:i}},[`${e}-switcher, ${e}-checkbox, ${e}-draggable-icon`]:{zIndex:1},"&-selected":{background:r,borderRadius:a,[`${e}-switcher, ${e}-draggable-icon`]:{color:n},[`${e}-node-content-wrapper`]:{color:n,background:"transparent","&:before, &:hover:before":{background:r}}}}}),AT=new Vt("ant-tree-node-fx-do-not-use",{"0%":{opacity:0},"100%":{opacity:1}}),FT=(e,t)=>({[`.${e}-switcher-icon`]:{display:"inline-block",fontSize:10,verticalAlign:"baseline",svg:{transition:`transform ${t.motionDurationSlow}`}}}),NT=(e,t)=>({[`.${e}-drop-indicator`]:{position:"absolute",zIndex:1,height:2,backgroundColor:t.colorPrimary,borderRadius:1,pointerEvents:"none","&:after":{position:"absolute",top:-3,insetInlineStart:-6,width:8,height:8,backgroundColor:"transparent",border:`${ue(t.lineWidthBold)} solid ${t.colorPrimary}`,borderRadius:"50%",content:'""'}}}),PT=(e,t)=>{const{treeCls:r,treeNodeCls:n,treeNodePadding:o,titleHeight:a,indentSize:i,nodeSelectedBg:l,nodeHoverBg:s,colorTextQuaternary:u,controlItemBgActiveDisabled:c}=t;return{[r]:Object.assign(Object.assign({},Br(t)),{"--rc-virtual-list-scrollbar-bg":t.colorSplit,background:t.colorBgContainer,borderRadius:t.borderRadius,transition:`background-color ${t.motionDurationSlow}`,"&-rtl":{direction:"rtl"},[`&${r}-rtl ${r}-switcher_close ${r}-switcher-icon svg`]:{transform:"rotate(90deg)"},[`&-focused:not(:hover):not(${r}-active-focused)`]:Po(t),[`${r}-list-holder-inner`]:{alignItems:"flex-start"},[`&${r}-block-node`]:{[`${r}-list-holder-inner`]:{alignItems:"stretch",[`${r}-node-content-wrapper`]:{flex:"auto"},[`${n}.dragging:after`]:{position:"absolute",inset:0,border:`1px solid ${t.colorPrimary}`,opacity:0,animationName:AT,animationDuration:t.motionDurationSlow,animationPlayState:"running",animationFillMode:"forwards",content:'""',pointerEvents:"none",borderRadius:t.borderRadius}}},[n]:{display:"flex",alignItems:"flex-start",marginBottom:o,lineHeight:ue(a),position:"relative","&:before":{content:'""',position:"absolute",zIndex:1,insetInlineStart:0,width:"100%",top:"100%",height:o},[`&-disabled ${r}-node-content-wrapper`]:{color:t.colorTextDisabled,cursor:"not-allowed","&:hover":{background:"transparent"}},[`${r}-checkbox-disabled + ${r}-node-selected,&${n}-disabled${n}-selected ${r}-node-content-wrapper`]:{backgroundColor:c},[`${r}-checkbox-disabled`]:{pointerEvents:"unset"},[`&:not(${n}-disabled)`]:{[`${r}-node-content-wrapper`]:{"&:hover":{color:t.nodeHoverColor}}},[`&-active ${r}-node-content-wrapper`]:{background:t.controlItemBgHover},[`&:not(${n}-disabled).filter-node ${r}-title`]:{color:t.colorPrimary,fontWeight:t.fontWeightStrong},"&-draggable":{cursor:"grab",[`${r}-draggable-icon`]:{flexShrink:0,width:a,textAlign:"center",visibility:"visible",color:u},[`&${n}-disabled ${r}-draggable-icon`]:{visibility:"hidden"}}},[`${r}-indent`]:{alignSelf:"stretch",whiteSpace:"nowrap",userSelect:"none","&-unit":{display:"inline-block",width:i}},[`${r}-draggable-icon`]:{visibility:"hidden"},[`${r}-switcher, ${r}-checkbox`]:{marginInlineEnd:t.calc(t.calc(a).sub(t.controlInteractiveSize)).div(2).equal()},[`${r}-switcher`]:Object.assign(Object.assign({},FT(e,t)),{position:"relative",flex:"none",alignSelf:"stretch",width:a,textAlign:"center",cursor:"pointer",userSelect:"none",transition:`all ${t.motionDurationSlow}`,"&-noop":{cursor:"unset"},"&:before":{pointerEvents:"none",content:'""',width:a,height:a,position:"absolute",left:{_skip_check_:!0,value:0},top:0,borderRadius:t.borderRadius,transition:`all ${t.motionDurationSlow}`},[`&:not(${r}-switcher-noop):hover:before`]:{backgroundColor:t.colorBgTextHover},[`&_close ${r}-switcher-icon svg`]:{transform:"rotate(-90deg)"},"&-loading-icon":{color:t.colorPrimary},"&-leaf-line":{position:"relative",zIndex:1,display:"inline-block",width:"100%",height:"100%","&:before":{position:"absolute",top:0,insetInlineEnd:t.calc(a).div(2).equal(),bottom:t.calc(o).mul(-1).equal(),marginInlineStart:-1,borderInlineEnd:`1px solid ${t.colorBorder}`,content:'""'},"&:after":{position:"absolute",width:t.calc(t.calc(a).div(2).equal()).mul(.8).equal(),height:t.calc(a).div(2).equal(),borderBottom:`1px solid ${t.colorBorder}`,content:'""'}}}),[`${r}-node-content-wrapper`]:Object.assign(Object.assign({position:"relative",minHeight:a,paddingBlock:0,paddingInline:t.paddingXS,background:"transparent",borderRadius:t.borderRadius,cursor:"pointer",transition:`all ${t.motionDurationMid}, border 0s, line-height 0s, box-shadow 0s`},NT(e,t)),{"&:hover":{backgroundColor:s},[`&${r}-node-selected`]:{color:t.nodeSelectedColor,backgroundColor:l},[`${r}-iconEle`]:{display:"inline-block",width:a,height:a,textAlign:"center",verticalAlign:"top","&:empty":{display:"none"}}}),[`${r}-unselectable ${r}-node-content-wrapper:hover`]:{backgroundColor:"transparent"},[`${n}.drop-container > [draggable]`]:{boxShadow:`0 0 0 2px ${t.colorPrimary}`},"&-show-line":{[`${r}-indent-unit`]:{position:"relative",height:"100%","&:before":{position:"absolute",top:0,insetInlineEnd:t.calc(a).div(2).equal(),bottom:t.calc(o).mul(-1).equal(),borderInlineEnd:`1px solid ${t.colorBorder}`,content:'""'},"&-end:before":{display:"none"}},[`${r}-switcher`]:{background:"transparent","&-line-icon":{verticalAlign:"-0.15em"}}},[`${n}-leaf-last ${r}-switcher-leaf-line:before`]:{top:"auto !important",bottom:"auto !important",height:`${ue(t.calc(a).div(2).equal())} !important`}})}},jT=(e,t,r=!0)=>{const n=`.${e}`,o=`${n}-treenode`,a=t.calc(t.paddingXS).div(2).equal(),i=er(t,{treeCls:n,treeNodeCls:o,treeNodePadding:a});return[PT(e,i),r&&OT(i)].filter(Boolean)},IT=e=>{const{controlHeightSM:t,controlItemBgHover:r,controlItemBgActive:n}=e,o=t;return{titleHeight:o,indentSize:o,nodeHoverBg:r,nodeHoverColor:e.colorText,nodeSelectedBg:n,nodeSelectedColor:e.colorText}},RT=e=>{const{colorTextLightSolid:t,colorPrimary:r}=e;return Object.assign(Object.assign({},IT(e)),{directoryNodeSelectedColor:t,directoryNodeSelectedBg:r})},MT=Hr("Tree",(e,{prefixCls:t})=>[{[e.componentCls]:Ux(`${t}-checkbox`,e)},jT(t,e),kC(e)],RT),mb=4;function TT(e){const{dropPosition:t,dropLevelOffset:r,prefixCls:n,indent:o,direction:a="ltr"}=e,i=a==="ltr"?"left":"right",l=a==="ltr"?"right":"left",s={[i]:-r*o+mb,[l]:0};switch(t){case-1:s.top=-3;break;case 1:s.bottom=-3;break;default:s.bottom=-3,s[i]=o+mb;break}return ee.createElement("div",{style:s,className:`${n}-drop-indicator`})}const zT=e=>{var t,r;const{prefixCls:n,switcherIcon:o,treeNodeProps:a,showLine:i,switcherLoadingIcon:l}=e,{isLeaf:s,expanded:u,loading:c}=a;if(c)return d.isValidElement(l)?l:d.createElement(Lp,{className:`${n}-switcher-loading-icon`});let f;if(i&&typeof i=="object"&&(f=i.showLeafIcon),s){if(!i)return null;if(typeof f!="boolean"&&f){const v=typeof f=="function"?f(a):f,g=`${n}-switcher-line-custom-icon`;return d.isValidElement(v)?eo(v,{className:pe((t=v.props)===null||t===void 0?void 0:t.className,g)}):v}return f?d.createElement(sw,{className:`${n}-switcher-line-icon`}):d.createElement("span",{className:`${n}-switcher-leaf-line`})}const p=`${n}-switcher-icon`,h=typeof o=="function"?o(a):o;return d.isValidElement(h)?eo(h,{className:pe((r=h.props)===null||r===void 0?void 0:r.className,p)}):h!==void 0?h:i?u?d.createElement(W8,{className:`${n}-switcher-line-icon`}):d.createElement(V8,{className:`${n}-switcher-line-icon`}):d.createElement(C8,{className:p})},Bw=ee.forwardRef((e,t)=>{var r;const{getPrefixCls:n,direction:o,virtual:a,tree:i}=ee.useContext(Zt),{prefixCls:l,className:s,showIcon:u=!1,showLine:c,switcherIcon:f,switcherLoadingIcon:p,blockNode:h=!1,children:v,checkable:g=!1,selectable:m=!0,draggable:b,motion:y,style:C}=e,D=n("tree",l),w=n(),k=y??Object.assign(Object.assign({},yC(w)),{motionAppear:!1}),E=Object.assign(Object.assign({},e),{checkable:g,selectable:m,showIcon:u,motion:k,blockNode:h,showLine:!!c,dropIndicatorRender:TT}),[x,O,j]=MT(D),[,$]=Yr(),P=$.paddingXS/2+(((r=$.Tree)===null||r===void 0?void 0:r.titleHeight)||$.controlHeightSM),A=ee.useMemo(()=>{if(!b)return!1;let S={};switch(typeof b){case"function":S.nodeDraggable=b;break;case"object":S=Object.assign({},b);break}return S.icon!==!1&&(S.icon=S.icon||ee.createElement(_8,null)),S},[b]),B=S=>ee.createElement(zT,{prefixCls:D,switcherIcon:f,switcherLoadingIcon:p,treeNodeProps:S,showLine:c});return x(ee.createElement(Bm,Object.assign({itemHeight:P,ref:t,virtual:a},E,{style:Object.assign(Object.assign({},i==null?void 0:i.style),C),prefixCls:D,className:pe({[`${D}-icon-hide`]:!u,[`${D}-block-node`]:h,[`${D}-unselectable`]:!m,[`${D}-rtl`]:o==="rtl"},i==null?void 0:i.className,s,O,j),direction:o,checkable:g&&ee.createElement("span",{className:`${D}-checkbox-inner`}),selectable:m,switcherIcon:B,draggable:A}),v))}),hb=0,rd=1,gb=2;function Om(e,t,r){const{key:n,children:o}=r;function a(i){const l=i[n],s=i[o];t(l,i)!==!1&&Om(s||[],t,r)}e.forEach(a)}function _T({treeData:e,expandedKeys:t,startKey:r,endKey:n,fieldNames:o}){const a=[];let i=hb;if(r&&r===n)return[r];if(!r||!n)return[];function l(s){return s===r||s===n}return Om(e,s=>{if(i===gb)return!1;if(l(s)){if(a.push(s),i===hb)i=rd;else if(i===rd)return i=gb,!1}else i===rd&&a.push(s);return t.includes(s)},Ja(o)),a}function nd(e,t,r){const n=Ie(t),o=[];return Om(e,(a,i)=>{const l=n.indexOf(a);return l!==-1&&(o.push(i),n.splice(l,1)),!!n.length},Ja(r)),o}var vb=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};function LT(e){const{isLeaf:t,expanded:r}=e;return t?d.createElement(sw,null):r?d.createElement(j8,null):d.createElement(M8,null)}function bb({treeData:e,children:t}){return e||Gx(t)}const HT=(e,t)=>{var{defaultExpandAll:r,defaultExpandParent:n,defaultExpandedKeys:o}=e,a=vb(e,["defaultExpandAll","defaultExpandParent","defaultExpandedKeys"]);const i=d.useRef(null),l=d.useRef(null),s=()=>{const{keyEntities:x}=bm(bb(a));let O;return r?O=Object.keys(x):n?O=qf(a.expandedKeys||o||[],x):O=a.expandedKeys||o||[],O},[u,c]=d.useState(a.selectedKeys||a.defaultSelectedKeys||[]),[f,p]=d.useState(()=>s());d.useEffect(()=>{"selectedKeys"in a&&c(a.selectedKeys)},[a.selectedKeys]),d.useEffect(()=>{"expandedKeys"in a&&p(a.expandedKeys)},[a.expandedKeys]);const h=(x,O)=>{var j;return"expandedKeys"in a||p(x),(j=a.onExpand)===null||j===void 0?void 0:j.call(a,x,O)},v=(x,O)=>{var j;const{multiple:$,fieldNames:P}=a,{node:A,nativeEvent:B}=O,{key:S=""}=A,I=bb(a),N=Object.assign(Object.assign({},O),{selected:!0}),F=(B==null?void 0:B.ctrlKey)||(B==null?void 0:B.metaKey),M=B==null?void 0:B.shiftKey;let _;$&&F?(_=x,i.current=S,l.current=_,N.selectedNodes=nd(I,_,P)):$&&M?(_=Array.from(new Set([].concat(Ie(l.current||[]),Ie(_T({treeData:I,expandedKeys:f,startKey:S,endKey:i.current,fieldNames:P}))))),N.selectedNodes=nd(I,_,P)):(_=[S],i.current=S,l.current=_,N.selectedNodes=nd(I,_,P)),(j=a.onSelect)===null||j===void 0||j.call(a,_,N),"selectedKeys"in a||c(_)},{getPrefixCls:g,direction:m}=d.useContext(Zt),{prefixCls:b,className:y,showIcon:C=!0,expandAction:D="click"}=a,w=vb(a,["prefixCls","className","showIcon","expandAction"]),k=g("tree",b),E=pe(`${k}-directory`,{[`${k}-directory-rtl`]:m==="rtl"},y);return d.createElement(Bw,Object.assign({icon:LT,ref:t,blockNode:!0},w,{showIcon:C,expandAction:D,prefixCls:k,className:E,expandedKeys:f,selectedKeys:u,onSelect:v,onExpand:h}))},WT=d.forwardRef(HT),Am=Bw;Am.DirectoryTree=WT;Am.TreeNode=gl;const yb=e=>{const{value:t,filterSearch:r,tablePrefixCls:n,locale:o,onChange:a}=e;return r?d.createElement("div",{className:`${n}-filter-dropdown-search`},d.createElement(jR,{prefix:d.createElement(sx,null),placeholder:o.filterSearchPlaceholder,onChange:a,value:t,htmlSize:1,className:`${n}-filter-dropdown-search-input`})):null},KT=e=>{const{keyCode:t}=e;t===rt.ENTER&&e.stopPropagation()},qT=d.forwardRef((e,t)=>d.createElement("div",{className:e.className,onClick:r=>r.stopPropagation(),onKeyDown:KT,ref:t},e.children));function Ia(e){let t=[];return(e||[]).forEach(({value:r,children:n})=>{t.push(r),n&&(t=[].concat(Ie(t),Ie(Ia(n))))}),t}function VT(e){return e.some(({children:t})=>t)}function Ow(e,t){return typeof t=="string"||typeof t=="number"?t==null?void 0:t.toString().toLowerCase().includes(e.trim().toLowerCase()):!1}function Aw({filters:e,prefixCls:t,filteredKeys:r,filterMultiple:n,searchValue:o,filterSearch:a}){return e.map((i,l)=>{const s=String(i.value);if(i.children)return{key:s||l,label:i.text,popupClassName:`${t}-dropdown-submenu`,children:Aw({filters:i.children,prefixCls:t,filteredKeys:r,filterMultiple:n,searchValue:o,filterSearch:a})};const u=n?Qa:$l,c={key:i.value!==void 0?s:l,label:d.createElement(d.Fragment,null,d.createElement(u,{checked:r.includes(s)}),d.createElement("span",null,i.text))};return o.trim()?typeof a=="function"?a(o,i)?c:null:Ow(o,i.text)?c:null:c})}function od(e){return e||[]}const GT=e=>{var t,r,n,o;const{tablePrefixCls:a,prefixCls:i,column:l,dropdownPrefixCls:s,columnKey:u,filterOnClose:c,filterMultiple:f,filterMode:p="menu",filterSearch:h=!1,filterState:v,triggerFilter:g,locale:m,children:b,getPopupContainer:y,rootClassName:C}=e,{filterResetToDefaultFilteredValue:D,defaultFilteredValue:w,filterDropdownProps:k={},filterDropdownOpen:E,filterDropdownVisible:x,onFilterDropdownVisibleChange:O,onFilterDropdownOpenChange:j}=l,[$,P]=d.useState(!1),A=!!(v&&(!((t=v.filteredKeys)===null||t===void 0)&&t.length||v.forceFiltered)),B=ve=>{var ye;P(ve),(ye=k.onOpenChange)===null||ye===void 0||ye.call(k,ve),j==null||j(ve),O==null||O(ve)},S=(o=(n=(r=k.open)!==null&&r!==void 0?r:E)!==null&&n!==void 0?n:x)!==null&&o!==void 0?o:$,I=v==null?void 0:v.filteredKeys,[N,F]=bT(od(I)),M=({selectedKeys:ve})=>{F(ve)},_=(ve,{node:ye,checked:ke})=>{M(f?{selectedKeys:ve}:{selectedKeys:ke&&ye.key?[ye.key]:[]})};d.useEffect(()=>{$&&M({selectedKeys:od(I)})},[I]);const[X,H]=d.useState([]),q=ve=>{H(ve)},[Z,te]=d.useState(""),z=ve=>{const{value:ye}=ve.target;te(ye)};d.useEffect(()=>{$||te("")},[$]);const Y=ve=>{const ye=ve!=null&&ve.length?ve:null;if(ye===null&&(!v||!v.filteredKeys)||Jn(ye,v==null?void 0:v.filteredKeys,!0))return null;g({column:l,key:u,filteredKeys:ye})},V=()=>{B(!1),Y(N())},U=({confirm:ve,closeDropdown:ye}={confirm:!1,closeDropdown:!1})=>{ve&&Y([]),ye&&B(!1),te(""),F(D?(w||[]).map(ke=>String(ke)):[])},K=({closeDropdown:ve}={closeDropdown:!0})=>{ve&&B(!1),Y(N())},W=(ve,ye)=>{ye.source==="trigger"&&(ve&&I!==void 0&&F(od(I)),B(ve),!ve&&!l.filterDropdown&&c&&V())},re=pe({[`${s}-menu-without-submenu`]:!VT(l.filters||[])}),G=ve=>{if(ve.target.checked){const ye=Ia(l==null?void 0:l.filters).map(ke=>String(ke));F(ye)}else F([])},J=({filters:ve})=>(ve||[]).map((ye,ke)=>{const we=String(ye.value),De={title:ye.text,key:ye.value!==void 0?we:String(ke)};return ye.children&&(De.children=J({filters:ye.children})),De}),oe=ve=>{var ye;return Object.assign(Object.assign({},ve),{text:ve.title,value:ve.key,children:((ye=ve.children)===null||ye===void 0?void 0:ye.map(ke=>oe(ke)))||[]})};let se;const{direction:ge,renderEmpty:Ee}=d.useContext(Zt);if(typeof l.filterDropdown=="function")se=l.filterDropdown({prefixCls:`${s}-custom`,setSelectedKeys:ve=>M({selectedKeys:ve}),selectedKeys:N(),confirm:K,clearFilters:U,filters:l.filters,visible:S,close:()=>{B(!1)}});else if(l.filterDropdown)se=l.filterDropdown;else{const ve=N()||[],ye=()=>{var we,De;const Ne=(we=Ee==null?void 0:Ee("Table.filter"))!==null&&we!==void 0?we:d.createElement(fo,{image:fo.PRESENTED_IMAGE_SIMPLE,description:m.filterEmptyText,styles:{image:{height:24}},style:{margin:0,padding:"16px 0"}});if((l.filters||[]).length===0)return Ne;if(p==="tree")return d.createElement(d.Fragment,null,d.createElement(yb,{filterSearch:h,value:Z,onChange:z,tablePrefixCls:a,locale:m}),d.createElement("div",{className:`${a}-filter-dropdown-tree`},f?d.createElement(Qa,{checked:ve.length===Ia(l.filters).length,indeterminate:ve.length>0&&ve.length<Ia(l.filters).length,className:`${a}-filter-dropdown-checkall`,onChange:G},(De=m==null?void 0:m.filterCheckall)!==null&&De!==void 0?De:m==null?void 0:m.filterCheckAll):null,d.createElement(Am,{checkable:!0,selectable:!1,blockNode:!0,multiple:f,checkStrictly:!f,className:`${s}-menu`,onCheck:_,checkedKeys:ve,selectedKeys:ve,showIcon:!1,treeData:J({filters:l.filters}),autoExpandParent:!0,defaultExpandAll:!0,filterTreeNode:Z.trim()?Le=>typeof h=="function"?h(Z,oe(Le)):Ow(Z,Le.title):void 0})));const Oe=Aw({filters:l.filters||[],filterSearch:h,prefixCls:i,filteredKeys:N(),filterMultiple:f,searchValue:Z}),Xe=Oe.every(Le=>Le===null);return d.createElement(d.Fragment,null,d.createElement(yb,{filterSearch:h,value:Z,onChange:z,tablePrefixCls:a,locale:m}),Xe?Ne:d.createElement(ui,{selectable:!0,multiple:f,prefixCls:`${s}-menu`,className:re,onSelect:M,onDeselect:M,selectedKeys:ve,getPopupContainer:y,openKeys:X,onOpenChange:q,items:Oe}))},ke=()=>D?Jn((w||[]).map(we=>String(we)),ve,!0):ve.length===0;se=d.createElement(d.Fragment,null,ye(),d.createElement("div",{className:`${i}-dropdown-btns`},d.createElement(Ya,{type:"link",size:"small",disabled:ke(),onClick:()=>U()},m.filterReset),d.createElement(Ya,{type:"primary",size:"small",onClick:V},m.filterConfirm)))}l.filterDropdown&&(se=d.createElement(Rx,{selectable:void 0},se)),se=d.createElement(qT,{className:`${i}-dropdown`},se);const je=MC({trigger:["click"],placement:ge==="rtl"?"bottomLeft":"bottomRight",children:(()=>{let ve;return typeof l.filterIcon=="function"?ve=l.filterIcon(A):l.filterIcon?ve=l.filterIcon:ve=d.createElement(F8,null),d.createElement("span",{role:"button",tabIndex:-1,className:pe(`${i}-trigger`,{active:A}),onClick:ye=>{ye.stopPropagation()}},ve)})(),getPopupContainer:y},Object.assign(Object.assign({},k),{rootClassName:pe(C,k.rootClassName),open:S,onOpenChange:W,popupRender:()=>typeof(k==null?void 0:k.dropdownRender)=="function"?k.dropdownRender(se):se}));return d.createElement("div",{className:`${i}-column`},d.createElement("span",{className:`${a}-column-title`},b),d.createElement(ym,Object.assign({},je)))},Yf=(e,t,r)=>{let n=[];return(e||[]).forEach((o,a)=>{var i;const l=pi(a,r),s=o.filterDropdown!==void 0;if(o.filters||s||"onFilter"in o)if("filteredValue"in o){let u=o.filteredValue;s||(u=(i=u==null?void 0:u.map(String))!==null&&i!==void 0?i:u),n.push({column:o,key:jo(o,l),filteredKeys:u,forceFiltered:o.filtered})}else n.push({column:o,key:jo(o,l),filteredKeys:t&&o.defaultFilteredValue?o.defaultFilteredValue:void 0,forceFiltered:o.filtered});"children"in o&&(n=[].concat(Ie(n),Ie(Yf(o.children,t,l))))}),n};function Fw(e,t,r,n,o,a,i,l,s){return r.map((u,c)=>{const f=pi(c,l),{filterOnClose:p=!0,filterMultiple:h=!0,filterMode:v,filterSearch:g}=u;let m=u;if(m.filters||m.filterDropdown){const b=jo(m,f),y=n.find(({key:C})=>b===C);m=Object.assign(Object.assign({},m),{title:C=>d.createElement(GT,{tablePrefixCls:e,prefixCls:`${e}-filter`,dropdownPrefixCls:t,column:m,columnKey:b,filterState:y,filterOnClose:p,filterMultiple:h,filterMode:v,filterSearch:g,triggerFilter:a,locale:o,getPopupContainer:i,rootClassName:s},Ku(u.title,C))})}return"children"in m&&(m=Object.assign(Object.assign({},m),{children:Fw(e,t,m.children,n,o,a,i,f,s)})),m})}const Cb=e=>{const t={};return e.forEach(({key:r,filteredKeys:n,column:o})=>{const a=r,{filters:i,filterDropdown:l}=o;if(l)t[a]=n||null;else if(Array.isArray(n)){const s=Ia(i);t[a]=s.filter(u=>n.includes(String(u)))}else t[a]=null}),t},Zf=(e,t,r)=>t.reduce((n,o)=>{const{column:{onFilter:a,filters:i},filteredKeys:l}=o;return a&&l&&l.length?n.map(s=>Object.assign({},s)).filter(s=>l.some(u=>{const c=Ia(i),f=c.findIndex(h=>String(h)===String(u)),p=f!==-1?c[f]:u;return s[r]&&(s[r]=Zf(s[r],t,r)),a(p,s)})):n},e),Nw=e=>e.flatMap(t=>"children"in t?[t].concat(Ie(Nw(t.children||[]))):[t]),XT=e=>{const{prefixCls:t,dropdownPrefixCls:r,mergedColumns:n,onFilterChange:o,getPopupContainer:a,locale:i,rootClassName:l}=e;oi();const s=d.useMemo(()=>Nw(n||[]),[n]),[u,c]=d.useState(()=>Yf(s,!0)),f=d.useMemo(()=>{const v=Yf(s,!1);if(v.length===0)return v;let g=!0;if(v.forEach(({filteredKeys:m})=>{m!==void 0&&(g=!1)}),g){const m=(s||[]).map((b,y)=>jo(b,pi(y)));return u.filter(({key:b})=>m.includes(b)).map(b=>{const y=s[m.findIndex(C=>C===b.key)];return Object.assign(Object.assign({},b),{column:Object.assign(Object.assign({},b.column),y),forceFiltered:y.filtered})})}return v},[s,u]),p=d.useMemo(()=>Cb(f),[f]),h=v=>{const g=f.filter(({key:m})=>m!==v.key);g.push(v),c(g),o(Cb(g),g)};return[v=>Fw(t,r,v,f,i,h,a,void 0,l),f,p]},UT=(e,t,r)=>{const n=d.useRef({});function o(a){var i;if(!n.current||n.current.data!==e||n.current.childrenColumnName!==t||n.current.getRowKey!==r){let l=function(u){u.forEach((c,f)=>{const p=r(c,f);s.set(p,c),c&&typeof c=="object"&&t in c&&l(c[t]||[])})};const s=new Map;l(e),n.current={data:e,childrenColumnName:t,kvMap:s,getRowKey:r}}return(i=n.current.kvMap)===null||i===void 0?void 0:i.get(a)}return[o]};var YT=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};const Pw=10;function ZT(e,t){const r={current:e.current,pageSize:e.pageSize};return Object.keys(t&&typeof t=="object"?t:{}).forEach(n=>{const o=e[n];typeof o!="function"&&(r[n]=o)}),r}function JT(e,t,r){const n=r&&typeof r=="object"?r:{},{total:o=0}=n,a=YT(n,["total"]),[i,l]=yt(()=>({current:"defaultCurrent"in a?a.defaultCurrent:1,pageSize:"defaultPageSize"in a?a.defaultPageSize:Pw})),s=MC(i,a,{total:o>0?o:e}),u=Math.ceil((o||e)/s.pageSize);s.current>u&&(s.current=u||1);const c=(p,h)=>{l({current:p??1,pageSize:h||s.pageSize})},f=(p,h)=>{var v;r&&((v=r.onChange)===null||v===void 0||v.call(r,p,h)),c(p,h),t(p,h||(s==null?void 0:s.pageSize))};return r===!1?[{},()=>{}]:[Object.assign(Object.assign({},s),{onChange:f}),c]}const Es="ascend",ad="descend",eu=e=>typeof e.sorter=="object"&&typeof e.sorter.multiple=="number"?e.sorter.multiple:!1,xb=e=>typeof e=="function"?e:e&&typeof e=="object"&&e.compare?e.compare:!1,QT=(e,t)=>t?e[e.indexOf(t)+1]:e[0],Jf=(e,t,r)=>{let n=[];const o=(a,i)=>{n.push({column:a,key:jo(a,i),multiplePriority:eu(a),sortOrder:a.sortOrder})};return(e||[]).forEach((a,i)=>{const l=pi(i,r);a.children?("sortOrder"in a&&o(a,l),n=[].concat(Ie(n),Ie(Jf(a.children,t,l)))):a.sorter&&("sortOrder"in a?o(a,l):t&&a.defaultSortOrder&&n.push({column:a,key:jo(a,l),multiplePriority:eu(a),sortOrder:a.defaultSortOrder}))}),n},jw=(e,t,r,n,o,a,i,l)=>(t||[]).map((s,u)=>{const c=pi(u,l);let f=s;if(f.sorter){const p=f.sortDirections||o,h=f.showSorterTooltip===void 0?i:f.showSorterTooltip,v=jo(f,c),g=r.find(({key:x})=>x===v),m=g?g.sortOrder:null,b=QT(p,m);let y;if(s.sortIcon)y=s.sortIcon({sortOrder:m});else{const x=p.includes(Es)&&d.createElement(S8,{className:pe(`${e}-column-sorter-up`,{active:m===Es})}),O=p.includes(ad)&&d.createElement(E8,{className:pe(`${e}-column-sorter-down`,{active:m===ad})});y=d.createElement("span",{className:pe(`${e}-column-sorter`,{[`${e}-column-sorter-full`]:!!(x&&O)})},d.createElement("span",{className:`${e}-column-sorter-inner`,"aria-hidden":"true"},x,O))}const{cancelSort:C,triggerAsc:D,triggerDesc:w}=a||{};let k=C;b===ad?k=w:b===Es&&(k=D);const E=typeof h=="object"?Object.assign({title:k},h):{title:k};f=Object.assign(Object.assign({},f),{className:pe(f.className,{[`${e}-column-sort`]:m}),title:x=>{const O=`${e}-column-sorters`,j=d.createElement("span",{className:`${e}-column-title`},Ku(s.title,x)),$=d.createElement("div",{className:O},j,y);return h?typeof h!="boolean"&&(h==null?void 0:h.target)==="sorter-icon"?d.createElement("div",{className:`${O} ${e}-column-sorters-tooltip-target-sorter`},j,d.createElement(ml,Object.assign({},E),y)):d.createElement(ml,Object.assign({},E),$):$},onHeaderCell:x=>{var O;const j=((O=s.onHeaderCell)===null||O===void 0?void 0:O.call(s,x))||{},$=j.onClick,P=j.onKeyDown;j.onClick=S=>{n({column:s,key:v,sortOrder:b,multiplePriority:eu(s)}),$==null||$(S)},j.onKeyDown=S=>{S.keyCode===rt.ENTER&&(n({column:s,key:v,sortOrder:b,multiplePriority:eu(s)}),P==null||P(S))};const A=vT(s.title,{}),B=A==null?void 0:A.toString();return m&&(j["aria-sort"]=m==="ascend"?"ascending":"descending"),j["aria-label"]=B||"",j.className=pe(j.className,`${e}-column-has-sorters`),j.tabIndex=0,s.ellipsis&&(j.title=(A??"").toString()),j}})}return"children"in f&&(f=Object.assign(Object.assign({},f),{children:jw(e,f.children,r,n,o,a,i,c)})),f}),wb=e=>{const{column:t,sortOrder:r}=e;return{column:t,order:r,field:t.dataIndex,columnKey:t.key}},Eb=e=>{const t=e.filter(({sortOrder:r})=>r).map(wb);if(t.length===0&&e.length){const r=e.length-1;return Object.assign(Object.assign({},wb(e[r])),{column:void 0,order:void 0,field:void 0,columnKey:void 0})}return t.length<=1?t[0]||{}:t},Qf=(e,t,r)=>{const n=t.slice().sort((i,l)=>l.multiplePriority-i.multiplePriority),o=e.slice(),a=n.filter(({column:{sorter:i},sortOrder:l})=>xb(i)&&l);return a.length?o.sort((i,l)=>{for(let s=0;s<a.length;s+=1){const u=a[s],{column:{sorter:c},sortOrder:f}=u,p=xb(c);if(p&&f){const h=p(i,l,f);if(h!==0)return f===Es?h:-h}}return 0}).map(i=>{const l=i[r];return l?Object.assign(Object.assign({},i),{[r]:Qf(l,t,r)}):i}):o},e9=e=>{const{prefixCls:t,mergedColumns:r,sortDirections:n,tableLocale:o,showSorterTooltip:a,onSorterChange:i}=e,[l,s]=d.useState(()=>Jf(r,!0)),u=(h,v)=>{const g=[];return h.forEach((m,b)=>{const y=pi(b,v);if(g.push(jo(m,y)),Array.isArray(m.children)){const C=u(m.children,y);g.push.apply(g,Ie(C))}}),g},c=d.useMemo(()=>{let h=!0;const v=Jf(r,!1);if(!v.length){const y=u(r);return l.filter(({key:C})=>y.includes(C))}const g=[];function m(y){h?g.push(y):g.push(Object.assign(Object.assign({},y),{sortOrder:null}))}let b=null;return v.forEach(y=>{b===null?(m(y),y.sortOrder&&(y.multiplePriority===!1?h=!1:b=!0)):(b&&y.multiplePriority!==!1||(h=!1),m(y))}),g},[r,l]),f=d.useMemo(()=>{var h,v;const g=c.map(({column:m,sortOrder:b})=>({column:m,order:b}));return{sortColumns:g,sortColumn:(h=g[0])===null||h===void 0?void 0:h.column,sortOrder:(v=g[0])===null||v===void 0?void 0:v.order}},[c]),p=h=>{let v;h.multiplePriority===!1||!c.length||c[0].multiplePriority===!1?v=[h]:v=[].concat(Ie(c.filter(({key:g})=>g!==h.key)),[h]),s(v),i(Eb(v),v)};return[h=>jw(t,h,c,p,n,o,a),c,f,()=>Eb(c)]},Iw=(e,t)=>e.map(r=>{const n=Object.assign({},r);return n.title=Ku(r.title,t),"children"in n&&(n.children=Iw(n.children,t)),n}),t9=e=>[d.useCallback(t=>Iw(t,e),[e])],r9=ww((e,t)=>{const{_renderTimes:r}=e,{_renderTimes:n}=t;return r!==n}),n9=kw((e,t)=>{const{_renderTimes:r}=e,{_renderTimes:n}=t;return r!==n}),o9=e=>{const{componentCls:t,lineWidth:r,lineType:n,tableBorderColor:o,tableHeaderBg:a,tablePaddingVertical:i,tablePaddingHorizontal:l,calc:s}=e,u=`${ue(r)} ${n} ${o}`,c=(f,p,h)=>({[`&${t}-${f}`]:{[`> ${t}-container`]:{[`> ${t}-content, > ${t}-body`]:{"\n > table > tbody > tr > th,\n > table > tbody > tr > td\n ":{[`> ${t}-expanded-row-fixed`]:{margin:`${ue(s(p).mul(-1).equal())}
|
|
387
|
+
${ue(s(s(h).add(r)).mul(-1).equal())}`}}}}}});return{[`${t}-wrapper`]:{[`${t}${t}-bordered`]:Object.assign(Object.assign(Object.assign({[`> ${t}-title`]:{border:u,borderBottom:0},[`> ${t}-container`]:{borderInlineStart:u,borderTop:u,[`
|
|
388
|
+
> ${t}-content,
|
|
389
|
+
> ${t}-header,
|
|
390
|
+
> ${t}-body,
|
|
391
|
+
> ${t}-summary
|
|
392
|
+
`]:{"> table":{"\n > thead > tr > th,\n > thead > tr > td,\n > tbody > tr > th,\n > tbody > tr > td,\n > tfoot > tr > th,\n > tfoot > tr > td\n ":{borderInlineEnd:u},"> thead":{"> tr:not(:last-child) > th":{borderBottom:u},"> tr > th::before":{backgroundColor:"transparent !important"}},"\n > thead > tr,\n > tbody > tr,\n > tfoot > tr\n ":{[`> ${t}-cell-fix-right-first::after`]:{borderInlineEnd:u}},"\n > tbody > tr > th,\n > tbody > tr > td\n ":{[`> ${t}-expanded-row-fixed`]:{margin:`${ue(s(i).mul(-1).equal())} ${ue(s(s(l).add(r)).mul(-1).equal())}`,"&::after":{position:"absolute",top:0,insetInlineEnd:r,bottom:0,borderInlineEnd:u,content:'""'}}}}}},[`&${t}-scroll-horizontal`]:{[`> ${t}-container > ${t}-body`]:{"> table > tbody":{[`
|
|
393
|
+
> tr${t}-expanded-row,
|
|
394
|
+
> tr${t}-placeholder
|
|
395
|
+
`]:{"> th, > td":{borderInlineEnd:0}}}}}},c("middle",e.tablePaddingVerticalMiddle,e.tablePaddingHorizontalMiddle)),c("small",e.tablePaddingVerticalSmall,e.tablePaddingHorizontalSmall)),{[`> ${t}-footer`]:{border:u,borderTop:0}}),[`${t}-cell`]:{[`${t}-container:first-child`]:{borderTop:0},"&-scrollbar:not([rowspan])":{boxShadow:`0 ${ue(r)} 0 ${ue(r)} ${a}`}},[`${t}-bordered ${t}-cell-scrollbar`]:{borderInlineEnd:u}}}},a9=e=>{const{componentCls:t}=e;return{[`${t}-wrapper`]:{[`${t}-cell-ellipsis`]:Object.assign(Object.assign({},ul),{wordBreak:"keep-all",[`
|
|
396
|
+
&${t}-cell-fix-left-last,
|
|
397
|
+
&${t}-cell-fix-right-first
|
|
398
|
+
`]:{overflow:"visible",[`${t}-cell-content`]:{display:"block",overflow:"hidden",textOverflow:"ellipsis"}},[`${t}-column-title`]:{overflow:"hidden",textOverflow:"ellipsis",wordBreak:"keep-all"}})}}},i9=e=>{const{componentCls:t}=e;return{[`${t}-wrapper`]:{[`${t}-tbody > tr${t}-placeholder`]:{textAlign:"center",color:e.colorTextDisabled,"\n &:hover > th,\n &:hover > td,\n ":{background:e.colorBgContainer}}}}},l9=e=>{const{componentCls:t,antCls:r,motionDurationSlow:n,lineWidth:o,paddingXS:a,lineType:i,tableBorderColor:l,tableExpandIconBg:s,tableExpandColumnWidth:u,borderRadius:c,tablePaddingVertical:f,tablePaddingHorizontal:p,tableExpandedRowBg:h,paddingXXS:v,expandIconMarginTop:g,expandIconSize:m,expandIconHalfInner:b,expandIconScale:y,calc:C}=e,D=`${ue(o)} ${i} ${l}`,w=C(v).sub(o).equal();return{[`${t}-wrapper`]:{[`${t}-expand-icon-col`]:{width:u},[`${t}-row-expand-icon-cell`]:{textAlign:"center",[`${t}-row-expand-icon`]:{display:"inline-flex",float:"none",verticalAlign:"sub"}},[`${t}-row-indent`]:{height:1,float:"left"},[`${t}-row-expand-icon`]:Object.assign(Object.assign({},xF(e)),{position:"relative",float:"left",width:m,height:m,color:"inherit",lineHeight:ue(m),background:s,border:D,borderRadius:c,transform:`scale(${y})`,"&:focus, &:hover, &:active":{borderColor:"currentcolor"},"&::before, &::after":{position:"absolute",background:"currentcolor",transition:`transform ${n} ease-out`,content:'""'},"&::before":{top:b,insetInlineEnd:w,insetInlineStart:w,height:o},"&::after":{top:w,bottom:w,insetInlineStart:b,width:o,transform:"rotate(90deg)"},"&-collapsed::before":{transform:"rotate(-180deg)"},"&-collapsed::after":{transform:"rotate(0deg)"},"&-spaced":{"&::before, &::after":{display:"none",content:"none"},background:"transparent",border:0,visibility:"hidden"}}),[`${t}-row-indent + ${t}-row-expand-icon`]:{marginTop:g,marginInlineEnd:a},[`tr${t}-expanded-row`]:{"&, &:hover":{"> th, > td":{background:h}},[`${r}-descriptions-view`]:{display:"flex",table:{flex:"auto",width:"100%"}}},[`${t}-expanded-row-fixed`]:{position:"relative",margin:`${ue(C(f).mul(-1).equal())} ${ue(C(p).mul(-1).equal())}`,padding:`${ue(f)} ${ue(p)}`}}}},s9=e=>{const{componentCls:t,antCls:r,iconCls:n,tableFilterDropdownWidth:o,tableFilterDropdownSearchWidth:a,paddingXXS:i,paddingXS:l,colorText:s,lineWidth:u,lineType:c,tableBorderColor:f,headerIconColor:p,fontSizeSM:h,tablePaddingHorizontal:v,borderRadius:g,motionDurationSlow:m,colorIcon:b,colorPrimary:y,tableHeaderFilterActiveBg:C,colorTextDisabled:D,tableFilterDropdownBg:w,tableFilterDropdownHeight:k,controlItemBgHover:E,controlItemBgActive:x,boxShadowSecondary:O,filterDropdownMenuBg:j,calc:$}=e,P=`${r}-dropdown`,A=`${t}-filter-dropdown`,B=`${r}-tree`,S=`${ue(u)} ${c} ${f}`;return[{[`${t}-wrapper`]:{[`${t}-filter-column`]:{display:"flex",justifyContent:"space-between"},[`${t}-filter-trigger`]:{position:"relative",display:"flex",alignItems:"center",marginBlock:$(i).mul(-1).equal(),marginInline:`${ue(i)} ${ue($(v).div(2).mul(-1).equal())}`,padding:`0 ${ue(i)}`,color:p,fontSize:h,borderRadius:g,cursor:"pointer",transition:`all ${m}`,"&:hover":{color:b,background:C},"&.active":{color:y}}}},{[`${r}-dropdown`]:{[A]:Object.assign(Object.assign({},Br(e)),{minWidth:o,backgroundColor:w,borderRadius:g,boxShadow:O,overflow:"hidden",[`${P}-menu`]:{maxHeight:k,overflowX:"hidden",border:0,boxShadow:"none",borderRadius:"unset",backgroundColor:j,"&:empty::after":{display:"block",padding:`${ue(l)} 0`,color:D,fontSize:h,textAlign:"center",content:'"Not Found"'}},[`${A}-tree`]:{paddingBlock:`${ue(l)} 0`,paddingInline:l,[B]:{padding:0},[`${B}-treenode ${B}-node-content-wrapper:hover`]:{backgroundColor:E},[`${B}-treenode-checkbox-checked ${B}-node-content-wrapper`]:{"&, &:hover":{backgroundColor:x}}},[`${A}-search`]:{padding:l,borderBottom:S,"&-input":{input:{minWidth:a},[n]:{color:D}}},[`${A}-checkall`]:{width:"100%",marginBottom:i,marginInlineStart:i},[`${A}-btns`]:{display:"flex",justifyContent:"space-between",padding:`${ue($(l).sub(u).equal())} ${ue(l)}`,overflow:"hidden",borderTop:S}})}},{[`${r}-dropdown ${A}, ${A}-submenu`]:{[`${r}-checkbox-wrapper + span`]:{paddingInlineStart:l,color:s},"> ul":{maxHeight:"calc(100vh - 130px)",overflowX:"hidden",overflowY:"auto"}}}]},u9=e=>{const{componentCls:t,lineWidth:r,colorSplit:n,motionDurationSlow:o,zIndexTableFixed:a,tableBg:i,zIndexTableSticky:l,calc:s}=e,u=n;return{[`${t}-wrapper`]:{[`
|
|
399
|
+
${t}-cell-fix-left,
|
|
400
|
+
${t}-cell-fix-right
|
|
401
|
+
`]:{position:"sticky !important",zIndex:a,background:i},[`
|
|
402
|
+
${t}-cell-fix-left-first::after,
|
|
403
|
+
${t}-cell-fix-left-last::after
|
|
404
|
+
`]:{position:"absolute",top:0,right:{_skip_check_:!0,value:0},bottom:s(r).mul(-1).equal(),width:30,transform:"translateX(100%)",transition:`box-shadow ${o}`,content:'""',pointerEvents:"none",willChange:"transform"},[`${t}-cell-fix-left-all::after`]:{display:"none"},[`
|
|
405
|
+
${t}-cell-fix-right-first::after,
|
|
406
|
+
${t}-cell-fix-right-last::after
|
|
407
|
+
`]:{position:"absolute",top:0,bottom:s(r).mul(-1).equal(),left:{_skip_check_:!0,value:0},width:30,transform:"translateX(-100%)",transition:`box-shadow ${o}`,content:'""',pointerEvents:"none"},[`${t}-container`]:{position:"relative","&::before, &::after":{position:"absolute",top:0,bottom:0,zIndex:s(l).add(1).equal({unit:!1}),width:30,transition:`box-shadow ${o}`,content:'""',pointerEvents:"none"},"&::before":{insetInlineStart:0},"&::after":{insetInlineEnd:0}},[`${t}-ping-left`]:{[`&:not(${t}-has-fix-left) ${t}-container::before`]:{boxShadow:`inset 10px 0 8px -8px ${u}`},[`
|
|
408
|
+
${t}-cell-fix-left-first::after,
|
|
409
|
+
${t}-cell-fix-left-last::after
|
|
410
|
+
`]:{boxShadow:`inset 10px 0 8px -8px ${u}`},[`${t}-cell-fix-left-last::before`]:{backgroundColor:"transparent !important"}},[`${t}-ping-right`]:{[`&:not(${t}-has-fix-right) ${t}-container::after`]:{boxShadow:`inset -10px 0 8px -8px ${u}`},[`
|
|
411
|
+
${t}-cell-fix-right-first::after,
|
|
412
|
+
${t}-cell-fix-right-last::after
|
|
413
|
+
`]:{boxShadow:`inset -10px 0 8px -8px ${u}`}},[`${t}-fixed-column-gapped`]:{[`
|
|
414
|
+
${t}-cell-fix-left-first::after,
|
|
415
|
+
${t}-cell-fix-left-last::after,
|
|
416
|
+
${t}-cell-fix-right-first::after,
|
|
417
|
+
${t}-cell-fix-right-last::after
|
|
418
|
+
`]:{boxShadow:"none"}}}}},c9=e=>{const{componentCls:t,antCls:r,margin:n}=e;return{[`${t}-wrapper`]:{[`${t}-pagination${r}-pagination`]:{margin:`${ue(n)} 0`},[`${t}-pagination`]:{display:"flex",flexWrap:"wrap",rowGap:e.paddingXS,"> *":{flex:"none"},"&-left":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-right":{justifyContent:"flex-end"}}}}},d9=e=>{const{componentCls:t,tableRadius:r}=e;return{[`${t}-wrapper`]:{[t]:{[`${t}-title, ${t}-header`]:{borderRadius:`${ue(r)} ${ue(r)} 0 0`},[`${t}-title + ${t}-container`]:{borderStartStartRadius:0,borderStartEndRadius:0,[`${t}-header, table`]:{borderRadius:0},"table > thead > tr:first-child":{"th:first-child, th:last-child, td:first-child, td:last-child":{borderRadius:0}}},"&-container":{borderStartStartRadius:r,borderStartEndRadius:r,"table > thead > tr:first-child":{"> *:first-child":{borderStartStartRadius:r},"> *:last-child":{borderStartEndRadius:r}}},"&-footer":{borderRadius:`0 0 ${ue(r)} ${ue(r)}`}}}}},f9=e=>{const{componentCls:t}=e;return{[`${t}-wrapper-rtl`]:{direction:"rtl",table:{direction:"rtl"},[`${t}-pagination-left`]:{justifyContent:"flex-end"},[`${t}-pagination-right`]:{justifyContent:"flex-start"},[`${t}-row-expand-icon`]:{float:"right","&::after":{transform:"rotate(-90deg)"},"&-collapsed::before":{transform:"rotate(180deg)"},"&-collapsed::after":{transform:"rotate(0deg)"}},[`${t}-container`]:{"&::before":{insetInlineStart:"unset",insetInlineEnd:0},"&::after":{insetInlineStart:0,insetInlineEnd:"unset"},[`${t}-row-indent`]:{float:"right"}}}}},p9=e=>{const{componentCls:t,antCls:r,iconCls:n,fontSizeIcon:o,padding:a,paddingXS:i,headerIconColor:l,headerIconHoverColor:s,tableSelectionColumnWidth:u,tableSelectedRowBg:c,tableSelectedRowHoverBg:f,tableRowHoverBg:p,tablePaddingHorizontal:h,calc:v}=e;return{[`${t}-wrapper`]:{[`${t}-selection-col`]:{width:u,[`&${t}-selection-col-with-dropdown`]:{width:v(u).add(o).add(v(a).div(4)).equal()}},[`${t}-bordered ${t}-selection-col`]:{width:v(u).add(v(i).mul(2)).equal(),[`&${t}-selection-col-with-dropdown`]:{width:v(u).add(o).add(v(a).div(4)).add(v(i).mul(2)).equal()}},[`
|
|
419
|
+
table tr th${t}-selection-column,
|
|
420
|
+
table tr td${t}-selection-column,
|
|
421
|
+
${t}-selection-column
|
|
422
|
+
`]:{paddingInlineEnd:e.paddingXS,paddingInlineStart:e.paddingXS,textAlign:"center",[`${r}-radio-wrapper`]:{marginInlineEnd:0}},[`table tr th${t}-selection-column${t}-cell-fix-left`]:{zIndex:v(e.zIndexTableFixed).add(1).equal({unit:!1})},[`table tr th${t}-selection-column::after`]:{backgroundColor:"transparent !important"},[`${t}-selection`]:{position:"relative",display:"inline-flex",flexDirection:"column"},[`${t}-selection-extra`]:{position:"absolute",top:0,zIndex:1,cursor:"pointer",transition:`all ${e.motionDurationSlow}`,marginInlineStart:"100%",paddingInlineStart:ue(v(h).div(4).equal()),[n]:{color:l,fontSize:o,verticalAlign:"baseline","&:hover":{color:s}}},[`${t}-tbody`]:{[`${t}-row`]:{[`&${t}-row-selected`]:{[`> ${t}-cell`]:{background:c,"&-row-hover":{background:f}}},[`> ${t}-cell-row-hover`]:{background:p}}}}}},m9=e=>{const{componentCls:t,tableExpandColumnWidth:r,calc:n}=e,o=(a,i,l,s)=>({[`${t}${t}-${a}`]:{fontSize:s,[`
|
|
423
|
+
${t}-title,
|
|
424
|
+
${t}-footer,
|
|
425
|
+
${t}-cell,
|
|
426
|
+
${t}-thead > tr > th,
|
|
427
|
+
${t}-tbody > tr > th,
|
|
428
|
+
${t}-tbody > tr > td,
|
|
429
|
+
tfoot > tr > th,
|
|
430
|
+
tfoot > tr > td
|
|
431
|
+
`]:{padding:`${ue(i)} ${ue(l)}`},[`${t}-filter-trigger`]:{marginInlineEnd:ue(n(l).div(2).mul(-1).equal())},[`${t}-expanded-row-fixed`]:{margin:`${ue(n(i).mul(-1).equal())} ${ue(n(l).mul(-1).equal())}`},[`${t}-tbody`]:{[`${t}-wrapper:only-child ${t}`]:{marginBlock:ue(n(i).mul(-1).equal()),marginInline:`${ue(n(r).sub(l).equal())} ${ue(n(l).mul(-1).equal())}`}},[`${t}-selection-extra`]:{paddingInlineStart:ue(n(l).div(4).equal())}}});return{[`${t}-wrapper`]:Object.assign(Object.assign({},o("middle",e.tablePaddingVerticalMiddle,e.tablePaddingHorizontalMiddle,e.tableFontSizeMiddle)),o("small",e.tablePaddingVerticalSmall,e.tablePaddingHorizontalSmall,e.tableFontSizeSmall))}},h9=e=>{const{componentCls:t,marginXXS:r,fontSizeIcon:n,headerIconColor:o,headerIconHoverColor:a}=e;return{[`${t}-wrapper`]:{[`${t}-thead th${t}-column-has-sorters`]:{outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}, left 0s`,"&:hover":{background:e.tableHeaderSortHoverBg,"&::before":{backgroundColor:"transparent !important"}},"&:focus-visible":{color:e.colorPrimary},[`
|
|
432
|
+
&${t}-cell-fix-left:hover,
|
|
433
|
+
&${t}-cell-fix-right:hover
|
|
434
|
+
`]:{background:e.tableFixedHeaderSortActiveBg}},[`${t}-thead th${t}-column-sort`]:{background:e.tableHeaderSortBg,"&::before":{backgroundColor:"transparent !important"}},[`td${t}-column-sort`]:{background:e.tableBodySortBg},[`${t}-column-title`]:{position:"relative",zIndex:1,flex:1,minWidth:0},[`${t}-column-sorters`]:{display:"flex",flex:"auto",alignItems:"center",justifyContent:"space-between","&::after":{position:"absolute",inset:0,width:"100%",height:"100%",content:'""'}},[`${t}-column-sorters-tooltip-target-sorter`]:{"&::after":{content:"none"}},[`${t}-column-sorter`]:{marginInlineStart:r,color:o,fontSize:0,transition:`color ${e.motionDurationSlow}`,"&-inner":{display:"inline-flex",flexDirection:"column",alignItems:"center"},"&-up, &-down":{fontSize:n,"&.active":{color:e.colorPrimary}},[`${t}-column-sorter-up + ${t}-column-sorter-down`]:{marginTop:"-0.3em"}},[`${t}-column-sorters:hover ${t}-column-sorter`]:{color:a}}}},g9=e=>{const{componentCls:t,opacityLoading:r,tableScrollThumbBg:n,tableScrollThumbBgHover:o,tableScrollThumbSize:a,tableScrollBg:i,zIndexTableSticky:l,stickyScrollBarBorderRadius:s,lineWidth:u,lineType:c,tableBorderColor:f}=e,p=`${ue(u)} ${c} ${f}`;return{[`${t}-wrapper`]:{[`${t}-sticky`]:{"&-holder":{position:"sticky",zIndex:l,background:e.colorBgContainer},"&-scroll":{position:"sticky",bottom:0,height:`${ue(a)} !important`,zIndex:l,display:"flex",alignItems:"center",background:i,borderTop:p,opacity:r,"&:hover":{transformOrigin:"center bottom"},"&-bar":{height:a,backgroundColor:n,borderRadius:s,transition:`all ${e.motionDurationSlow}, transform 0s`,position:"absolute",bottom:0,"&:hover, &-active":{backgroundColor:o}}}}}}},kb=e=>{const{componentCls:t,lineWidth:r,tableBorderColor:n,calc:o}=e,a=`${ue(r)} ${e.lineType} ${n}`;return{[`${t}-wrapper`]:{[`${t}-summary`]:{position:"relative",zIndex:e.zIndexTableFixed,background:e.tableBg,"> tr":{"> th, > td":{borderBottom:a}}},[`div${t}-summary`]:{boxShadow:`0 ${ue(o(r).mul(-1).equal())} 0 ${n}`}}}},v9=e=>{const{componentCls:t,motionDurationMid:r,lineWidth:n,lineType:o,tableBorderColor:a,calc:i}=e,l=`${ue(n)} ${o} ${a}`,s=`${t}-expanded-row-cell`;return{[`${t}-wrapper`]:{[`${t}-tbody-virtual`]:{[`${t}-tbody-virtual-holder-inner`]:{[`
|
|
435
|
+
& > ${t}-row,
|
|
436
|
+
& > div:not(${t}-row) > ${t}-row
|
|
437
|
+
`]:{display:"flex",boxSizing:"border-box",width:"100%"}},[`${t}-cell`]:{borderBottom:l,transition:`background ${r}`},[`${t}-expanded-row`]:{[`${s}${s}-fixed`]:{position:"sticky",insetInlineStart:0,overflow:"hidden",width:`calc(var(--virtual-width) - ${ue(n)})`,borderInlineEnd:"none"}}},[`${t}-bordered`]:{[`${t}-tbody-virtual`]:{"&:after":{content:'""',insetInline:0,bottom:0,borderBottom:l,position:"absolute"},[`${t}-cell`]:{borderInlineEnd:l,[`&${t}-cell-fix-right-first:before`]:{content:'""',position:"absolute",insetBlock:0,insetInlineStart:i(n).mul(-1).equal(),borderInlineStart:l}}},[`&${t}-virtual`]:{[`${t}-placeholder ${t}-cell`]:{borderInlineEnd:l,borderBottom:l}}}}}},b9=e=>{const{componentCls:t,fontWeightStrong:r,tablePaddingVertical:n,tablePaddingHorizontal:o,tableExpandColumnWidth:a,lineWidth:i,lineType:l,tableBorderColor:s,tableFontSize:u,tableBg:c,tableRadius:f,tableHeaderTextColor:p,motionDurationMid:h,tableHeaderBg:v,tableHeaderCellSplitColor:g,tableFooterTextColor:m,tableFooterBg:b,calc:y}=e,C=`${ue(i)} ${l} ${s}`;return{[`${t}-wrapper`]:Object.assign(Object.assign({clear:"both",maxWidth:"100%","--rc-virtual-list-scrollbar-bg":e.tableScrollBg},Hs()),{[t]:Object.assign(Object.assign({},Br(e)),{fontSize:u,background:c,borderRadius:`${ue(f)} ${ue(f)} 0 0`,scrollbarColor:`${e.tableScrollThumbBg} ${e.tableScrollBg}`}),table:{width:"100%",textAlign:"start",borderRadius:`${ue(f)} ${ue(f)} 0 0`,borderCollapse:"separate",borderSpacing:0},[`
|
|
438
|
+
${t}-cell,
|
|
439
|
+
${t}-thead > tr > th,
|
|
440
|
+
${t}-tbody > tr > th,
|
|
441
|
+
${t}-tbody > tr > td,
|
|
442
|
+
tfoot > tr > th,
|
|
443
|
+
tfoot > tr > td
|
|
444
|
+
`]:{position:"relative",padding:`${ue(n)} ${ue(o)}`,overflowWrap:"break-word"},[`${t}-title`]:{padding:`${ue(n)} ${ue(o)}`},[`${t}-thead`]:{"\n > tr > th,\n > tr > td\n ":{position:"relative",color:p,fontWeight:r,textAlign:"start",background:v,borderBottom:C,transition:`background ${h} ease`,"&[colspan]:not([colspan='1'])":{textAlign:"center"},[`&:not(:last-child):not(${t}-selection-column):not(${t}-row-expand-icon-cell):not([colspan])::before`]:{position:"absolute",top:"50%",insetInlineEnd:0,width:1,height:"1.6em",backgroundColor:g,transform:"translateY(-50%)",transition:`background-color ${h}`,content:'""'}},"> tr:not(:last-child) > th[colspan]":{borderBottom:0}},[`${t}-tbody`]:{"> tr":{"> th, > td":{transition:`background ${h}, border-color ${h}`,borderBottom:C,[`
|
|
445
|
+
> ${t}-wrapper:only-child,
|
|
446
|
+
> ${t}-expanded-row-fixed > ${t}-wrapper:only-child
|
|
447
|
+
`]:{[t]:{marginBlock:ue(y(n).mul(-1).equal()),marginInline:`${ue(y(a).sub(o).equal())}
|
|
448
|
+
${ue(y(o).mul(-1).equal())}`,[`${t}-tbody > tr:last-child > td`]:{borderBottomWidth:0,"&:first-child, &:last-child":{borderRadius:0}}}}},"> th":{position:"relative",color:p,fontWeight:r,textAlign:"start",background:v,borderBottom:C,transition:`background ${h} ease`}}},[`${t}-footer`]:{padding:`${ue(n)} ${ue(o)}`,color:m,background:b}})}},y9=e=>{const{colorFillAlter:t,colorBgContainer:r,colorTextHeading:n,colorFillSecondary:o,colorFillContent:a,controlItemBgActive:i,controlItemBgActiveHover:l,padding:s,paddingSM:u,paddingXS:c,colorBorderSecondary:f,borderRadiusLG:p,controlHeight:h,colorTextPlaceholder:v,fontSize:g,fontSizeSM:m,lineHeight:b,lineWidth:y,colorIcon:C,colorIconHover:D,opacityLoading:w,controlInteractiveSize:k}=e,E=new Ht(o).onBackground(r).toHexString(),x=new Ht(a).onBackground(r).toHexString(),O=new Ht(t).onBackground(r).toHexString(),j=new Ht(C),$=new Ht(D),P=k/2-y,A=P*2+y*3;return{headerBg:O,headerColor:n,headerSortActiveBg:E,headerSortHoverBg:x,bodySortBg:O,rowHoverBg:O,rowSelectedBg:i,rowSelectedHoverBg:l,rowExpandedBg:t,cellPaddingBlock:s,cellPaddingInline:s,cellPaddingBlockMD:u,cellPaddingInlineMD:c,cellPaddingBlockSM:c,cellPaddingInlineSM:c,borderColor:f,headerBorderRadius:p,footerBg:O,footerColor:n,cellFontSize:g,cellFontSizeMD:g,cellFontSizeSM:g,headerSplitColor:f,fixedHeaderSortActiveBg:E,headerFilterHoverBg:a,filterDropdownMenuBg:r,filterDropdownBg:r,expandIconBg:r,selectionColumnWidth:h,stickyScrollBarBg:v,stickyScrollBarBorderRadius:100,expandIconMarginTop:(g*b-y*3)/2-Math.ceil((m*1.4-y*3)/2),headerIconColor:j.clone().setA(j.a*w).toRgbString(),headerIconHoverColor:$.clone().setA($.a*w).toRgbString(),expandIconHalfInner:P,expandIconSize:A,expandIconScale:k/A}},Db=2,C9=Hr("Table",e=>{const{colorTextHeading:t,colorSplit:r,colorBgContainer:n,controlInteractiveSize:o,headerBg:a,headerColor:i,headerSortActiveBg:l,headerSortHoverBg:s,bodySortBg:u,rowHoverBg:c,rowSelectedBg:f,rowSelectedHoverBg:p,rowExpandedBg:h,cellPaddingBlock:v,cellPaddingInline:g,cellPaddingBlockMD:m,cellPaddingInlineMD:b,cellPaddingBlockSM:y,cellPaddingInlineSM:C,borderColor:D,footerBg:w,footerColor:k,headerBorderRadius:E,cellFontSize:x,cellFontSizeMD:O,cellFontSizeSM:j,headerSplitColor:$,fixedHeaderSortActiveBg:P,headerFilterHoverBg:A,filterDropdownBg:B,expandIconBg:S,selectionColumnWidth:I,stickyScrollBarBg:N,calc:F}=e,M=er(e,{tableFontSize:x,tableBg:n,tableRadius:E,tablePaddingVertical:v,tablePaddingHorizontal:g,tablePaddingVerticalMiddle:m,tablePaddingHorizontalMiddle:b,tablePaddingVerticalSmall:y,tablePaddingHorizontalSmall:C,tableBorderColor:D,tableHeaderTextColor:i,tableHeaderBg:a,tableFooterTextColor:k,tableFooterBg:w,tableHeaderCellSplitColor:$,tableHeaderSortBg:l,tableHeaderSortHoverBg:s,tableBodySortBg:u,tableFixedHeaderSortActiveBg:P,tableHeaderFilterActiveBg:A,tableFilterDropdownBg:B,tableRowHoverBg:c,tableSelectedRowBg:f,tableSelectedRowHoverBg:p,zIndexTableFixed:Db,zIndexTableSticky:F(Db).add(1).equal({unit:!1}),tableFontSizeMiddle:O,tableFontSizeSmall:j,tableSelectionColumnWidth:I,tableExpandIconBg:S,tableExpandColumnWidth:F(o).add(F(e.padding).mul(2)).equal(),tableExpandedRowBg:h,tableFilterDropdownWidth:120,tableFilterDropdownHeight:264,tableFilterDropdownSearchWidth:140,tableScrollThumbSize:8,tableScrollThumbBg:N,tableScrollThumbBgHover:t,tableScrollBg:r});return[b9(M),c9(M),kb(M),h9(M),s9(M),o9(M),d9(M),l9(M),kb(M),i9(M),p9(M),u9(M),g9(M),a9(M),m9(M),f9(M),v9(M)]},y9,{unitless:{expandIconScale:!0}}),x9=[],w9=(e,t)=>{var r,n;const{prefixCls:o,className:a,rootClassName:i,style:l,size:s,bordered:u,dropdownPrefixCls:c,dataSource:f,pagination:p,rowSelection:h,rowKey:v="key",rowClassName:g,columns:m,children:b,childrenColumnName:y,onChange:C,getPopupContainer:D,loading:w,expandIcon:k,expandable:E,expandedRowRender:x,expandIconColumnIndex:O,indentSize:j,scroll:$,sortDirections:P,locale:A,showSorterTooltip:B={target:"full-header"},virtual:S}=e;oi();const I=d.useMemo(()=>m||km(b),[m,b]),N=d.useMemo(()=>I.some(_e=>_e.responsive),[I]),F=dx(N),M=d.useMemo(()=>{const _e=new Set(Object.keys(F).filter(Ke=>F[Ke]));return I.filter(Ke=>!Ke.responsive||Ke.responsive.some(Pe=>_e.has(Pe)))},[I,F]),_=fn(e,["className","style","columns"]),{locale:X=ra,direction:H,table:q,renderEmpty:Z,getPrefixCls:te,getPopupContainer:z}=d.useContext(Zt),Y=fa(s),V=Object.assign(Object.assign({},X.Table),A),U=f||x9,K=te("table",o),W=te("dropdown",c),[,re]=Yr(),G=bo(K),[J,oe,se]=C9(K,G),ge=Object.assign(Object.assign({childrenColumnName:y,expandIconColumnIndex:O},E),{expandIcon:(r=E==null?void 0:E.expandIcon)!==null&&r!==void 0?r:(n=q==null?void 0:q.expandable)===null||n===void 0?void 0:n.expandIcon}),{childrenColumnName:Ee="children"}=ge,je=d.useMemo(()=>U.some(_e=>_e==null?void 0:_e[Ee])?"nest":x||E!=null&&E.expandedRowRender?"row":null,[U]),ve={body:d.useRef(null)},ye=gT(K),ke=d.useRef(null),we=d.useRef(null);mT(t,()=>Object.assign(Object.assign({},we.current),{nativeElement:ke.current}));const De=d.useMemo(()=>typeof v=="function"?v:_e=>_e==null?void 0:_e[v],[v]),[Ne]=UT(U,Ee,De),Oe={},Xe=(_e,Ke,Pe=!1)=>{var Ze,wt,jt,It;const Et=Object.assign(Object.assign({},Oe),_e);Pe&&((Ze=Oe.resetPagination)===null||Ze===void 0||Ze.call(Oe),!((wt=Et.pagination)===null||wt===void 0)&&wt.current&&(Et.pagination.current=1),p&&((jt=p.onChange)===null||jt===void 0||jt.call(p,1,(It=Et.pagination)===null||It===void 0?void 0:It.pageSize))),$&&$.scrollToFirstRowOnChange!==!1&&ve.body.current&&$3(0,{getContainer:()=>ve.body.current}),C==null||C(Et.pagination,Et.filters,Et.sorter,{currentDataSource:Zf(Qf(U,Et.sorterStates,Ee),Et.filterStates,Ee),action:Ke})},Le=(_e,Ke)=>{Xe({sorter:_e,sorterStates:Ke},"sort",!1)},[Fe,fe,Be,We]=e9({prefixCls:K,mergedColumns:M,onSorterChange:Le,sortDirections:P||["ascend","descend"],tableLocale:V,showSorterTooltip:B}),Ye=d.useMemo(()=>Qf(U,fe,Ee),[U,fe]);Oe.sorter=We(),Oe.sorterStates=fe;const Ve=(_e,Ke)=>{Xe({filters:_e,filterStates:Ke},"filter",!0)},[Te,it,Ue]=XT({prefixCls:K,locale:V,dropdownPrefixCls:W,mergedColumns:M,onFilterChange:Ve,getPopupContainer:D||z,rootClassName:pe(i,G)}),nt=Zf(Ye,it,Ee);Oe.filters=Ue,Oe.filterStates=it;const pt=d.useMemo(()=>{const _e={};return Object.keys(Ue).forEach(Ke=>{Ue[Ke]!==null&&(_e[Ke]=Ue[Ke])}),Object.assign(Object.assign({},Be),{filters:_e})},[Be,Ue]),[St]=t9(pt),dt=(_e,Ke)=>{Xe({pagination:Object.assign(Object.assign({},Oe.pagination),{current:_e,pageSize:Ke})},"paginate")},[ht,Pt]=JT(nt.length,dt,p);Oe.pagination=p===!1?{}:ZT(ht,p),Oe.resetPagination=Pt;const At=d.useMemo(()=>{if(p===!1||!ht.pageSize)return nt;const{current:_e=1,total:Ke,pageSize:Pe=Pw}=ht;return nt.length<Ke?nt.length>Pe?nt.slice((_e-1)*Pe,_e*Pe):nt:nt.slice((_e-1)*Pe,_e*Pe)},[!!p,nt,ht==null?void 0:ht.current,ht==null?void 0:ht.pageSize,ht==null?void 0:ht.total]),[ct,ut]=fT({prefixCls:K,data:nt,pageData:At,getRowKey:De,getRecordByKey:Ne,expandType:je,childrenColumnName:Ee,locale:V,getPopupContainer:D||z},h),ae=(_e,Ke,Pe)=>{let Ze;return typeof g=="function"?Ze=pe(g(_e,Ke,Pe)):Ze=pe(g),pe({[`${K}-row-selected`]:ut.has(De(_e,Ke))},Ze)};ge.__PARENT_RENDER_ICON__=ge.expandIcon,ge.expandIcon=ge.expandIcon||k||hT(V),je==="nest"&&ge.expandIconColumnIndex===void 0?ge.expandIconColumnIndex=h?1:0:ge.expandIconColumnIndex>0&&h&&(ge.expandIconColumnIndex-=1),typeof ge.indentSize!="number"&&(ge.indentSize=typeof j=="number"?j:15);const he=d.useCallback(_e=>St(ct(Te(Fe(_e)))),[Fe,Te,ct]);let xe,be;if(p!==!1&&(ht!=null&&ht.total)){let _e;ht.size?_e=ht.size:_e=Y==="small"||Y==="middle"?"small":void 0;const Ke=wt=>d.createElement(ow,Object.assign({},ht,{className:pe(`${K}-pagination ${K}-pagination-${wt}`,ht.className),size:_e})),Pe=H==="rtl"?"left":"right",{position:Ze}=ht;if(Ze!==null&&Array.isArray(Ze)){const wt=Ze.find(Et=>Et.includes("top")),jt=Ze.find(Et=>Et.includes("bottom")),It=Ze.every(Et=>`${Et}`=="none");!wt&&!jt&&!It&&(be=Ke(Pe)),wt&&(xe=Ke(wt.toLowerCase().replace("top",""))),jt&&(be=Ke(jt.toLowerCase().replace("bottom","")))}else be=Ke(Pe)}let Ce;typeof w=="boolean"?Ce={spinning:w}:typeof w=="object"&&(Ce=Object.assign({spinning:!0},w));const de=pe(se,G,`${K}-wrapper`,q==null?void 0:q.className,{[`${K}-wrapper-rtl`]:H==="rtl"},a,i,oe),Se=Object.assign(Object.assign({},q==null?void 0:q.style),l),le=typeof(A==null?void 0:A.emptyText)<"u"?A.emptyText:(Z==null?void 0:Z("Table"))||d.createElement(rx,{componentName:"Table"}),ie=S?n9:r9,me={},ze=d.useMemo(()=>{const{fontSize:_e,lineHeight:Ke,lineWidth:Pe,padding:Ze,paddingXS:wt,paddingSM:jt}=re,It=Math.floor(_e*Ke);switch(Y){case"middle":return jt*2+It+Pe;case"small":return wt*2+It+Pe;default:return Ze*2+It+Pe}},[re,Y]);return S&&(me.listItemHeight=ze),J(d.createElement("div",{ref:ke,className:de,style:Se},d.createElement(Cm,Object.assign({spinning:!1},Ce),xe,d.createElement(ie,Object.assign({},me,_,{ref:we,columns:M,direction:H,expandable:ge,prefixCls:K,className:pe({[`${K}-middle`]:Y==="middle",[`${K}-small`]:Y==="small",[`${K}-bordered`]:u,[`${K}-empty`]:U.length===0},se,G,oe),data:At,rowKey:De,rowClassName:ae,emptyText:le,internalHooks:Ol,internalRefs:ve,transformColumns:he,getContainerWidth:ye})),be)))},E9=d.forwardRef(w9),k9=(e,t)=>{const r=d.useRef(0);return r.current+=1,d.createElement(E9,Object.assign({},e,{ref:t,_renderTimes:r.current}))},yo=d.forwardRef(k9);yo.SELECTION_COLUMN=ko;yo.EXPAND_COLUMN=co;yo.SELECTION_ALL=Vf;yo.SELECTION_INVERT=Gf;yo.SELECTION_NONE=Xf;yo.Column=tT;yo.ColumnGroup=rT;yo.Summary=fw;const Rw=ee.forwardRef(({attributes:e,element:t,eventsEmit:r,onDataUpdate:n,dataSource:o,tagIndex:a},i)=>{var w;const[l,s]=yt(null),[u,c]=yt(!0),[f,p]=yt(1),[h,v]=yt(10);Ot(()=>{if(!l){if(!o){c(!0);try{const k=new CustomEvent("retrieve-sql-data:request-data",{detail:{id:t.id}});window.dispatchEvent(k)}catch{console.warn("Failed to dispatch retrieve-sql-data:request-data")}return}try{const k=(o==null?void 0:o.queryReplyPairList)||[];console.log("RetrieveSqlDataElement pairList:",k);let E=null,x=null,O;for(const P of k){const A=P==null?void 0:P.reply;if(!(A!=null&&A.databaseReference))continue;const B=A.databaseReference;console.log(B,"123123123jk123lk12j3l12jl3"),B!=null&&B.retrieveSqlData&&(console.log("Found source in raw12eku1h2lkjeh12ljkhelk12hejk:",B.retrieveSqlData.filePath),O=B.retrieveSqlData.filePath);let S=B;if(typeof B=="string")try{S=JSON.parse(B)}catch{}if(!S)continue;const I=Array.isArray(S)?S:[S],N=I.findIndex(_=>(_==null?void 0:_.id)===t.id),F=N>=0?I[N]:null;if(console.log("~~~~~~~~~~~~~~~",F),F){E=F,x=F.retrieveSqlData||F.retrieve_table_data||F.retrieveTableData;break}const M=I.find(_=>{var X,H;return(((H=(X=_==null?void 0:_.retrieveSqlData)==null?void 0:X.preData)==null?void 0:H.length)||0)>0});!E&&M&&(E=M,x=M.retrieveSqlData||M.retrieve_table_data||M.retrieveTableData)}if(!E||!x){console.warn("No databaseReference with preData found for id:",t.id),c(!1);return}const j=Array.isArray(x==null?void 0:x.preData)?x.preData[0]:null;if(!j){console.warn("Matched item has no preData"),c(!1);return}const $={columns:(j.columns||[]).map(P=>({key:P.key,title:P.title})),rows:j.data||j.rows||[],total:(x==null?void 0:x.total)||0,fetchUrl:(x==null?void 0:x.fetchUrl)||"/index/knowledgeBase/file/stream",source:O||(x==null?void 0:x.source)||(E==null?void 0:E.source)};s($),c(!1)}catch(k){console.error("Init preData parsing failed:",k),c(!1)}}},[t.id,l,o]),Ot(()=>{const k=E=>{try{const x=(E==null?void 0:E.detail)||{},O=x==null?void 0:x.id;if(!O||String(O)!==String(t.id))return;const j=x.databaseReference;if(!j)return;let $=j;if(typeof j=="string")try{$=JSON.parse(j)}catch{}if(!$)return;const P=Array.isArray($)?$:[$],A=P.findIndex(F=>String(F==null?void 0:F.id)===String(t.id)),B=A>=0?P[A]:null;if(!B)return;const S=(B==null?void 0:B.retrieveSqlData)||(B==null?void 0:B.retrieve_table_data)||(B==null?void 0:B.retrieveTableData),I=Array.isArray(S==null?void 0:S.preData)?S.preData[0]:null;if(!I)return;const N={columns:(I.columns||[]).map(F=>({key:F.key,title:F.title})),rows:I.data||I.rows||[],total:(S==null?void 0:S.total)||0,fetchUrl:(S==null?void 0:S.fetchUrl)||"/index/knowledgeBase/file/stream",source:(B==null?void 0:B.source)||(S==null?void 0:S.source)};s(N),c(!1)}catch{console.warn("Failed to handle retrieve-sql-data:data-response")}};return window.addEventListener("retrieve-sql-data:data-response",k),()=>{window.removeEventListener("retrieve-sql-data:data-response",k)}},[t.id]),Ot(()=>{n&&l&&n(l)},[l,n]);const g=k=>{if(!k||k.length===0)return[];const E=k.find(x=>x&&typeof x=="object")||{};return Object.keys(E).map(x=>({key:x,title:x}))},m=(k,E)=>{p(k),E&&v(E);const x=O=>{let j=null;if(O&&Array.isArray(O.columns)&&Array.isArray(O.rows))j={columns:O.columns,rows:O.rows,total:Number(O.total)||0,fetchUrl:O.fetchUrl||(l==null?void 0:l.fetchUrl)||"",source:O.source||(l==null?void 0:l.source)};else if(O&&Array.isArray(O.data)){const $=O.data;j={columns:l!=null&&l.columns&&l.columns.length>0?l.columns:g($),rows:$,total:Number(O.totalCount??O.total??(l==null?void 0:l.total)??$.length)||0,fetchUrl:(l==null?void 0:l.fetchUrl)||"",source:l==null?void 0:l.source},typeof O.currentPage=="number"&&p(O.currentPage),typeof O.pageSize=="number"&&v(O.pageSize)}else if(Array.isArray(O)){const $=O;j={columns:l!=null&&l.columns&&l.columns.length>0?l.columns:g($),rows:$,total:Number((l==null?void 0:l.total)??$.length)||0,fetchUrl:(l==null?void 0:l.fetchUrl)||"",source:l==null?void 0:l.source}}if(!j){console.warn("replacePredataFunction received unsupported data format:",O);return}console.log("Replacing table data with:",j),s(j)};r==null||r("retrieve-sql-data:pagingation_click",{id:t.id,page:k,pageSize:E||h,fetchUrl:l==null?void 0:l.fetchUrl,total:l==null?void 0:l.total,source:l==null?void 0:l.source,replacePredataFunction:x})},b=k=>l!=null&&l.rows?Math.max(...l.rows.map(E=>{const x=E[k];return x?String(x).length:0})):0,y=(((w=l==null?void 0:l.columns)==null?void 0:w.length)||0)===1,C=(l==null?void 0:l.columns.map((k,E)=>({title:k.title||k.key,dataIndex:k.key,key:k.key,render:x=>{const O=x==null||x===""?"-":x;return y?Q.jsx("div",{style:{whiteSpace:"normal",wordBreak:"break-word",overflowWrap:"anywhere",lineHeight:1.5},children:String(O)}):O},...y?{width:void 0}:{}})))||[],D=(l==null?void 0:l.rows.map((k,E)=>({key:E,...k})))||[];return Q.jsx("div",{...e,ref:i,className:"retrieve-sql-data-container my-4",children:u?Q.jsxs("div",{className:"flex items-center justify-center py-8",children:[Q.jsx(Cm,{size:"large"}),Q.jsx("span",{className:"ml-2 text-gray-500",children:"\u52A0\u8F7D\u6570\u636E\u4E2D..."})]}):l?Q.jsxs("div",{className:"retrieve-sql-data-content",children:[a!==null&&Q.jsxs("div",{className:"mb-2 flex items-center",children:[Q.jsx("span",{className:"w-6 h-6 bg-orange-100 text-orange-600 rounded text-xs font-medium flex items-center justify-center",children:a}),Q.jsx("span",{children:" \u6570\u636E\u8868\u67E5\u8BE2\u7ED3\u679C\uFF1A"})]}),Q.jsx("div",{className:"table-container",style:{border:"1px solid #d9d9d9",borderRadius:"6px",position:"relative"},children:Q.jsx(yo,{columns:C.map((k,E)=>({...k,...y?{width:void 0,minWidth:void 0,maxWidth:void 0,fixed:void 0,ellipsis:!1}:{width:E===0?160:void 0,minWidth:120,maxWidth:E===0?180:300,fixed:E===0?"left":void 0,ellipsis:{showTitle:!0}},render:x=>{if(x==null)return"-";const O=String(x);if(y)return Q.jsx("div",{style:{whiteSpace:"normal",wordBreak:"break-word",overflowWrap:"anywhere",lineHeight:1.5,cursor:"default"},title:O,children:O});const j=b(k.key);let $="200px";return E===0?$="80px":j<=8?$="100px":j<=15?$="150px":j<=25?$="200px":j<=40?$="250px":$="300px",Q.jsx("div",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:$,display:"inline-block",cursor:"default"},title:O,children:O})}})),dataSource:D,pagination:!1,size:"small",bordered:!1,className:"database-table",style:{minWidth:y?"100%":"1000px"},scroll:{x:y?void 0:"max-content",y:400}})}),l.total>h&&Q.jsx("div",{className:"flex justify-center mt-3",children:Q.jsx(ow,{current:f,pageSize:h,total:l.total,onChange:m,onShowSizeChange:m,showSizeChanger:!1,showQuickJumper:!1,size:"small"})})]}):Q.jsx("div",{className:"text-center py-4 text-gray-500",children:"\u6682\u65E0\u6570\u636E"})})});Rw.displayName="RetrieveSqlDataElement";const D9=e=>{var a,i,l,s,u,c,f,p;const{styles:t}=e,{element:r,children:n,attributes:o}=e;switch(r.type){case"paragraph":return Q.jsx("div",{...o,style:{letterSpacing:t==null?void 0:t.letterSpacing,lineHeight:t==null?void 0:t.lineHeight,color:`${(a=t==null?void 0:t.text)==null?void 0:a.color} !important`,margin:"0 0 0.75rem 0"},children:n});case"heading-one":return Q.jsx("h1",{...o,style:{letterSpacing:t==null?void 0:t.letterSpacing,lineHeight:t==null?void 0:t.lineHeight,color:`${(i=t==null?void 0:t.text)==null?void 0:i.color} !important`},children:n});case"heading-two":return Q.jsx("h2",{...o,style:{letterSpacing:t==null?void 0:t.letterSpacing,lineHeight:t==null?void 0:t.lineHeight,color:`${(l=t==null?void 0:t.text)==null?void 0:l.color} !important`},children:n});case"heading-three":return Q.jsx("h3",{...o,style:{letterSpacing:t==null?void 0:t.letterSpacing,lineHeight:t==null?void 0:t.lineHeight,color:`${(s=t==null?void 0:t.text)==null?void 0:s.color} !important`},children:n});case"bulleted-list":return Q.jsx("ul",{...o,children:n});case"numbered-list":return Q.jsx("ol",{...o,children:n});case"list-item":return Q.jsx("li",{...o,children:n});case"table":return Q.jsx("div",{className:"table-container",children:Q.jsx("table",{...o,children:Q.jsx("tbody",{children:n})})});case"table-row":return Q.jsx("tr",{...o,children:n});case"table-cell":return r.header?Q.jsx("th",{...o,children:n}):Q.jsx("td",{...o,children:n});case"block-quote":return Q.jsx("blockquote",{...o,style:{letterSpacing:t==null?void 0:t.letterSpacing,lineHeight:t==null?void 0:t.lineHeight,color:`${(u=t==null?void 0:t.text)==null?void 0:u.color} !important`},children:n});case"code-block":return Q.jsx("pre",{...o,children:Q.jsx("code",{style:{color:`${(c=t==null?void 0:t.text)==null?void 0:c.color} !important`},children:n})});case"think":const h=e.extraProps||{},v=h.isCollapsed!==void 0?h.isCollapsed:Object.values(h)[1]===!0,g={...h,isCollapsed:v};return console.log("renderElement think case - fixed extraProps:",g),Q.jsx(OB,{attributes:o,styles:t,extraProps:g,children:n});case"template":return Q.jsx(r1,{...o,element:r,children:n,styles:t});case"retrieve-sql-data":const m=(b=>{if(!b)return null;try{const y=typeof b=="string"?JSON.parse(b):b;return{queryReplyPairList:[{reply:{databaseReference:Array.isArray(y)?y[0]:y}}]}}catch(y){return console.error("Failed to parse databaseReference:",y),null}})(((f=e.extraProps)==null?void 0:f.databaseReference)||e.databaseReference);return Q.jsx(Rw,{...o,element:r,children:n,styles:t,eventsEmit:e.eventsEmit,dataSource:m||void 0,tagIndex:1,onDataUpdate:b=>{var y;(y=e.eventsEmit)==null||y.call(e,"rtext_table_data_updated",{id:r.id,data:b})}});default:return Q.jsx("div",{...o,className:"mb-4",style:{letterSpacing:t==null?void 0:t.letterSpacing,lineHeight:t==null?void 0:t.lineHeight,color:`${(p=t==null?void 0:t.text)==null?void 0:p.color} !important`},children:n})}},S9=e=>{var i,l,s,u,c,f;const{attributes:t,children:r,leaf:n,styles:o}=e;(i=o==null?void 0:o.text)!=null&&i.color&&console.log("renderLeaf - \u63A5\u6536\u5230\u7684\u6587\u672C\u989C\u8272:",o.text.color);let a=r;if(n.retrive){const p=n.fromtype==="0",h=n.fromtype==="1",v=n.fromtype==="2",g=n.text||"";let m=g,b="#e6f7ff",y="#1890ff",C="#bae7ff";return p?(m=`${g}`,b="#e6f7ff",y="#1890ff",C="#bae7ff"):h?(m=`${g}`,b="#f6ffed",y="#52c41a",C="#d9f7be"):v&&(m=`${g}`,b="#f9f0ff",y="#722ed1",C="#efdbff"),a=Q.jsx("span",{...t,style:{display:"inline-block",background:b,color:y,height:24,width:24,borderRadius:3,padding:"1px 9px",margin:"0 2px",fontWeight:600,fontSize:10,lineHeight:"22px",cursor:"pointer",verticalAlign:"middle"},onClick:()=>{e.onRetriveTagClick&&e.onRetriveTagClick(n,t)},onMouseEnter:D=>D.currentTarget.style.background=C,onMouseLeave:D=>D.currentTarget.style.background=b,children:m}),a}if(n.code)a=Q.jsx("code",{...t,style:{color:`${(l=o==null?void 0:o.text)==null?void 0:l.color} !important`},children:a});else{const p=[n.bold&&"bold",n.italic&&"italic",n.underline&&"underline",n.strikethrough&&"strikethrough"].filter(Boolean).join(" "),h={color:`${(s=o==null?void 0:o.text)==null?void 0:s.color} !important`,fontSize:(u=o==null?void 0:o.text)==null?void 0:u.fontSize,lineHeight:(c=o==null?void 0:o.text)==null?void 0:c.lineHeight,letterSpacing:o==null?void 0:o.letterSpacing};a=Q.jsx("span",{...t,className:p,style:h,children:a})}return n.link&&(a=Q.jsx("a",{href:n.link,target:"_blank",rel:"noopener noreferrer",className:"link",style:{color:`${(f=o==null?void 0:o.text)==null?void 0:f.color} !important`},children:a})),a},id=fr.div`
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
& > * + * {
|
|
452
|
+
margin-top: ${e=>{var t;return((t=e.theme)==null?void 0:t.margin)||"0.5rem"}};
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
/* 标题样式 */
|
|
456
|
+
& h1 {
|
|
457
|
+
font-size: ${e=>e.$size==="sm"?"20px":"32px"};
|
|
458
|
+
font-weight: 600;
|
|
459
|
+
margin: 24px 0 16px 0;
|
|
460
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#24292f"}};
|
|
461
|
+
border-bottom: 1px solid #d0d7de;
|
|
462
|
+
padding-bottom: 8px;
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
& h2 {
|
|
466
|
+
font-size: ${e=>e.$size==="sm"?"18px":"24px"};
|
|
467
|
+
font-weight: 600;
|
|
468
|
+
margin: 24px 0 16px 0;
|
|
469
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#24292f"}};
|
|
470
|
+
border-bottom: 1px solid #d0d7de;
|
|
471
|
+
padding-bottom: 6px;
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
& h3 {
|
|
475
|
+
font-size: ${e=>e.$size==="sm"?"16px":"20px"};
|
|
476
|
+
font-weight: 600;
|
|
477
|
+
margin: 24px 0 16px 0;
|
|
478
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#24292f"}};
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
/* 段落样式 */
|
|
482
|
+
& p {
|
|
483
|
+
font-size: ${e=>e.$size==="sm"?"14px":"16px"};
|
|
484
|
+
margin: 16px 0;
|
|
485
|
+
line-height: 1.6;
|
|
486
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#24292f"}};
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
/* 列表样式 - GitHub 风格简约设计 */
|
|
490
|
+
& ul, & ol {
|
|
491
|
+
margin: 16px 0;
|
|
492
|
+
padding-left: 24px;
|
|
493
|
+
line-height: 1.6;
|
|
494
|
+
}
|
|
495
|
+
|
|
496
|
+
& ul {
|
|
497
|
+
list-style-type: disc;
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
& ol {
|
|
501
|
+
list-style-type: decimal;
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
& li {
|
|
505
|
+
margin: 4px 0;
|
|
506
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#24292f"}};
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
/* 嵌套列表 */
|
|
510
|
+
& ul ul, & ol ol, & ul ol, & ol ul {
|
|
511
|
+
margin: 8px 0;
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
/* 引用块样式 */
|
|
515
|
+
& blockquote {
|
|
516
|
+
font-size: ${e=>e.$size==="sm"?"14px":"16px"};
|
|
517
|
+
border-left: 4px solid #d0d7de;
|
|
518
|
+
padding: 0 16px;
|
|
519
|
+
margin: 16px 0;
|
|
520
|
+
color: #656d76;
|
|
521
|
+
background-color: #f6f8fa;
|
|
522
|
+
}
|
|
523
|
+
|
|
524
|
+
/* 行内代码样式 */
|
|
525
|
+
& code {
|
|
526
|
+
font-size: 0.875em;
|
|
527
|
+
background-color: #f6f8fa;
|
|
528
|
+
padding: 0.125em 0.25em;
|
|
529
|
+
border-radius: 6px;
|
|
530
|
+
font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
|
|
531
|
+
color: #d73a49;
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
/* 代码块样式 */
|
|
535
|
+
& pre {
|
|
536
|
+
background-color: #f6f8fa;
|
|
537
|
+
padding: 16px;
|
|
538
|
+
border-radius: 6px;
|
|
539
|
+
overflow-x: auto;
|
|
540
|
+
margin: 16px 0;
|
|
541
|
+
border: 1px solid #d0d7de;
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
& pre code {
|
|
545
|
+
background-color: transparent;
|
|
546
|
+
padding: 0;
|
|
547
|
+
color: #24292f;
|
|
548
|
+
}
|
|
549
|
+
|
|
550
|
+
/* 表格样式 */
|
|
551
|
+
& table {
|
|
552
|
+
width: 100%;
|
|
553
|
+
border-collapse: collapse;
|
|
554
|
+
border: 1px solid #d0d7de;
|
|
555
|
+
margin: 16px 0;
|
|
556
|
+
}
|
|
557
|
+
|
|
558
|
+
& th, & td {
|
|
559
|
+
border: 1px solid #d0d7de;
|
|
560
|
+
padding: 8px 12px;
|
|
561
|
+
text-align: left;
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
& th {
|
|
565
|
+
background-color: #f6f8fa;
|
|
566
|
+
font-weight: 600;
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
& tr:nth-child(even) {
|
|
570
|
+
background-color: #f6f8fa;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
/* 图片样式 */
|
|
574
|
+
& img {
|
|
575
|
+
max-width: 100%;
|
|
576
|
+
height: auto;
|
|
577
|
+
border-radius: 6px;
|
|
578
|
+
margin: 16px 0;
|
|
579
|
+
}
|
|
580
|
+
|
|
581
|
+
/* 链接样式 */
|
|
582
|
+
& a {
|
|
583
|
+
color: #0969da;
|
|
584
|
+
text-decoration: none;
|
|
585
|
+
|
|
586
|
+
&:hover {
|
|
587
|
+
text-decoration: underline;
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
|
|
591
|
+
/* 文本样式 */
|
|
592
|
+
& strong {
|
|
593
|
+
font-weight: 600;
|
|
594
|
+
}
|
|
595
|
+
|
|
596
|
+
& em {
|
|
597
|
+
font-style: italic;
|
|
598
|
+
}
|
|
599
|
+
|
|
600
|
+
& u {
|
|
601
|
+
text-decoration: underline;
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
& s {
|
|
605
|
+
text-decoration: line-through;
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
/* 分割线样式 */
|
|
609
|
+
& hr {
|
|
610
|
+
border: none;
|
|
611
|
+
border-top: 1px solid #d0d7de;
|
|
612
|
+
margin: 24px 0;
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
/* 思考容器样式 */
|
|
616
|
+
& .think-container {
|
|
617
|
+
|
|
618
|
+
|
|
619
|
+
}
|
|
620
|
+
|
|
621
|
+
& .think-header {
|
|
622
|
+
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
& .think-icon {
|
|
626
|
+
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
& .think-title {
|
|
630
|
+
font-weight: 600;
|
|
631
|
+
color: #24292f;
|
|
632
|
+
font-size: 14px;
|
|
633
|
+
}
|
|
634
|
+
|
|
635
|
+
& .think-text {
|
|
636
|
+
color: #86909C;
|
|
637
|
+
font-size: 14px;
|
|
638
|
+
line-height: 1.6;
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
/* 召回标签样式 */
|
|
642
|
+
& .retrive-tag {
|
|
643
|
+
display: inline-block;
|
|
644
|
+
background: #e6f7ff;
|
|
645
|
+
color: #1890ff;
|
|
646
|
+
border: 1px solid rgba(114, 187, 255, 0.3);
|
|
647
|
+
border-radius: 6px;
|
|
648
|
+
padding: 2px 6px;
|
|
649
|
+
margin: 0 2px;
|
|
650
|
+
font-weight: 500;
|
|
651
|
+
font-size: 12px;
|
|
652
|
+
line-height: 1.4;
|
|
653
|
+
cursor: pointer;
|
|
654
|
+
vertical-align: middle;
|
|
655
|
+
transition: background-color 0.2s ease;
|
|
656
|
+
}
|
|
657
|
+
|
|
658
|
+
& .retrive-tag:hover {
|
|
659
|
+
background: #bae7ff;
|
|
660
|
+
}
|
|
661
|
+
`;function Mw(e){return e.map(t=>!t.children||t.children.length===0?{...t,children:[{text:""}]}:{...t,children:t.children.map(r=>typeof r=="object"&&"type"in r?Mw([r])[0]:r)})}function Tw(e,t){const r=[];function n(u){var c;if(u.indexOf("<think>")>-1)if(u.indexOf("</think>")>-1){const f=/<think>([\s\S]*?)<\/think>([\s\S]*)/s,p=u.match(f);return p?{thinkContent:p[1],content:p[2],finish:!0}:{thinkContent:"",content:u,finish:!0}}else{const f=/<think>(.*?)(?=<|\s*$)/s;return{thinkContent:((c=u.match(f))==null?void 0:c[1])||"",content:""}}else return{thinkContent:"",content:u}}const{thinkContent:o,content:a,finish:i}=n(e||"");let l=[],s=0;if(!r.includes("think")&&o){const u=o.split(/\n+/).map(c=>c.trim()).filter(Boolean).flatMap(c=>{if(/<retrive-tag/i.test(c)){const f=document.createElement("div");return f.innerHTML=c,Sb(f)}else return[{type:"paragraph",children:[{text:c}]}]});l.push({type:"think",id:`think-${s++}`,thinkContent:o,finish:i,children:u})}if(a){let u=a;r.includes("retrive")||(u=u.replace(/\[retrive-tag([^\]]*)\]\[([^\]]+)\]\[\/retrive-tag\]/g,(f,p,h)=>`<retrive-tag${p?" "+p.trim():""}>${h}</retrive-tag>`)),r.includes("retrieve-sql-data")||(u=u.replace(/<retrieve-sql-data\s+id="([^"]+)"\s*\/?>/g,(f,p)=>`<retrieve-sql-data id="${p}"></retrieve-sql-data>`)),Kt.setOptions({gfm:!0,breaks:!0,pedantic:!1});const c=Kt(u);if(typeof c=="string"){const f=document.createElement("div");f.innerHTML=c;const p=Sb(f);p&&p.length>0&&(l=l.concat(p))}}return!l||l.length===0?[{type:"paragraph",children:[{text:""}]}]:Mw(l)}function Sb(e){const t=[];return((r,n)=>(n.forEach(o=>{var a;if(o.nodeType===Node.ELEMENT_NODE){const i=o;switch(i.tagName.toLowerCase()){case"p":r.push({type:"paragraph",children:Pr(i)});break;case"h1":r.push({type:"heading-one",children:Pr(i)});break;case"h2":r.push({type:"heading-two",children:Pr(i)});break;case"h3":r.push({type:"heading-three",children:Pr(i)});break;case"ul":r.push({type:"bulleted-list",children:Array.from(i.children).map(s=>({type:"list-item",children:Pr(s)}))});break;case"ol":const l={type:"numbered-list",children:Array.from(i.children).map(s=>({type:"list-item",children:Pr(s)}))};r.push(l);break;case"li":r.push({type:"list-item",children:Pr(i)});break;case"pre":{const s=i.querySelector("code");s?r.push({type:"code-block",children:Pr(s)}):r.push({type:"code-block",children:Pr(i)});break}case"code":{i.closest("pre")||r.push({type:"paragraph",children:Pr(i)});break}case"retrive-tag":{const s=Pr(i);s.length>0&&r.push({type:"paragraph",children:s});break}case"retrieve-sql-data":{const s=i.getAttribute("id")||"";r.push({type:"retrieve-sql-data",id:s,children:[{text:""}]});break}case"blockquote":r.push({type:"block-quote",children:Pr(i)});break;case"table":r.push($9(i));break;case"think-block":r.push({type:"think",children:Pr(i)});break;default:r.push({type:"paragraph",children:Pr(i)});break}}else o.nodeType===Node.TEXT_NODE&&((a=o.textContent)!=null&&a.trim())&&r.push({type:"paragraph",children:[{text:o.textContent}]})}),r))(t,e.childNodes),t}function Pr(e){const t=[];function r(o){const a=[];let i="",l=!1,s=!1,u=0;for(;u<o.length;)o.startsWith("**",u)?(i&&(a.push({text:i,code:!0,bold:l,italic:s}),i=""),l=!l,u+=2):o.startsWith("*",u)?(i&&(a.push({text:i,code:!0,bold:l,italic:s}),i=""),s=!s,u+=1):(i+=o[u],u+=1);return i&&a.push({text:i,code:!0,bold:l,italic:s}),a}function n(o,a={}){var i,l;if(o.nodeType===Node.TEXT_NODE){const s=(i=o.textContent)==null?void 0:i.trim();return s?a.code?r(s):[{text:s,...a}]:[]}if(o.nodeType===Node.ELEMENT_NODE){const s=o,u={...a};switch(s.tagName.toLowerCase()){case"em":case"i":u.italic=!0;break;case"strong":case"b":u.bold=!0;break;case"code":s.closest("pre")||(u.code=!0);break;case"del":case"s":u.strikethrough=!0;break;case"u":u.underline=!0;break;case"a":u.link=s.getAttribute("href")||void 0;break;case"retrive-tag":{const f={};for(const{name:p,value:h}of Array.from(s.attributes))f[p]=h;return[{text:s.textContent||""||"[0]",retrive:!0,...f}]}case"retrieve-sql-data":return[{type:"retrieve-sql-data",id:s.getAttribute("id")||"",children:[{text:""}]}]}if(s.childNodes.length===0&&((l=s.textContent)!=null&&l.trim()))return u.code?r(s.textContent):[{text:s.textContent,...u}];let c=[];for(const f of Array.from(s.childNodes))c=c.concat(n(f,u));return c}return[]}for(const o of Array.from(e.childNodes))t.push(...n(o));return t}function $9(e){const t=[],r=e.querySelector("thead"),n=e.querySelector("tbody");if(!r&&!n){const o=Array.from(e.querySelectorAll("tr"));o.length>0&&(t.push({type:"table-row",children:Array.from(o[0].children).map(a=>({type:"table-cell",header:!0,children:Pr(a)}))}),o.slice(1).forEach(a=>{t.push({type:"table-row",children:Array.from(a.children).map(i=>({type:"table-cell",header:!1,children:Pr(i)}))})}))}else{if(r){const o=r.querySelector("tr");o&&t.push({type:"table-row",children:Array.from(o.querySelectorAll("th")).map(a=>({type:"table-cell",header:!0,children:Pr(a)}))})}n&&Array.from(n.querySelectorAll("tr")).forEach(o=>{t.push({type:"table-row",children:Array.from(o.querySelectorAll("td")).map(a=>({type:"table-cell",header:!1,children:Pr(a)}))})})}return{type:"table",children:t}}const B9=fr.div`
|
|
662
|
+
border: ${e=>e.$isEditing?"1px solid #dee2e6":"none"};
|
|
663
|
+
border-radius: ${e=>{var t;return((t=e.theme)==null?void 0:t.borderRadius)||"4px"}};
|
|
664
|
+
background-color: ${e=>{var t;return((t=e.theme)==null?void 0:t.backgroundColor)||"transparent"}};
|
|
665
|
+
min-height: ${e=>{var t;return((t=e.theme)==null?void 0:t.minHeight)||"200px"}};
|
|
666
|
+
overflow: hidden;
|
|
667
|
+
transition: all 0.2s ease-in-out;
|
|
668
|
+
|
|
669
|
+
${e=>{var t,r;return e.$isEditing&&`
|
|
670
|
+
&:focus-within {
|
|
671
|
+
border-color: ${((t=e.theme)==null?void 0:t.primaryColor)||"#007bff"};
|
|
672
|
+
box-shadow: 0 0 0 2px ${((r=e.theme)==null?void 0:r.primaryColor)||"#007bff"}20;
|
|
673
|
+
}
|
|
674
|
+
`}}
|
|
675
|
+
`,ld=fr.div`
|
|
676
|
+
padding: ${e=>{var t;return((t=e.theme)==null?void 0:t.padding)||"0rem 1rem"}};
|
|
677
|
+
min-height: inherit;
|
|
678
|
+
outline: none;
|
|
679
|
+
|
|
680
|
+
& > * + * {
|
|
681
|
+
margin-top: ${e=>{var t;return((t=e.theme)==null?void 0:t.margin)||"0.5rem"}};
|
|
682
|
+
}
|
|
683
|
+
`;var tu=(e=>(e.SLATE="slate",e.MARKDOWN="markdown",e.HTML="html",e.TEXT="text",e))(tu||{});const Fm=({dataSource:e,isEditing:t=!1,placeholder:r="\u5F00\u59CB\u8F93\u5165...",size:n="sm",theme:o={},onChange:a,onFocus:i,onBlur:l,renderElement:s,renderLeaf:u,onRetriveTagClick:c,eventsEmit:f,extraProps:p={},className:h,style:v,styles:g,enableTemplateInput:m=!1,disabledTags:b=[]})=>{const y=ru(),C=xt(()=>{var F,M,_,X,H,q,Z,te,z;return{primaryColor:((F=y==null?void 0:y.colors)==null?void 0:F.primary)||(o==null?void 0:o.primaryColor)||"#007bff",secondaryColor:((M=y==null?void 0:y.colors)==null?void 0:M.secondary)||(o==null?void 0:o.secondaryColor)||"#6c757d",backgroundColor:((_=y==null?void 0:y.colors)==null?void 0:_.background)||(o==null?void 0:o.backgroundColor)||"transparent",textColor:((X=y==null?void 0:y.colors)==null?void 0:X.text)||(o==null?void 0:o.textColor)||"#24292f",borderColor:((H=y==null?void 0:y.colors)==null?void 0:H.border)||(o==null?void 0:o.borderColor)||"#dee2e6",disabledBackground:((q=y==null?void 0:y.colors)==null?void 0:q.disabledBackground)||(o==null?void 0:o.disabledBackground)||"#f8f9fa",borderRadius:((Z=y==null?void 0:y.space)==null?void 0:Z.radius)||(o==null?void 0:o.borderRadius)||"4px",padding:((te=y==null?void 0:y.space)==null?void 0:te.padding)||(o==null?void 0:o.padding)||"0rem 1rem",margin:((z=y==null?void 0:y.space)==null?void 0:z.margin)||(o==null?void 0:o.margin)||"0.5rem",minHeight:(o==null?void 0:o.minHeight)||"200px",baseFontSize:(o==null?void 0:o.baseFontSize)||(n==="md"?14:12),...o}},[y,o,n]),D=qe();if(!D.current){const F=BD(),M=H$(F),{isInline:_}=M;M.isInline=q=>!b.includes("template")&&q.type==="template"?!0:_(q);const{isVoid:X}=M;M.isVoid=q=>!b.includes("template")&&q.type==="template"?!0:X(q);const H=q=>{if(!(m&&!b.includes("template")))return q;const{insertText:Z,insertData:te}=q,z=()=>{const Y=/<template>([^<]*)<\/template>/g,V=Array.from(R.nodes(q,{match:U=>ot.isText(U)&&Y.test(U.text)}));if(V.length!==0)for(const U of V){const[K,W]=U,re=K.text||"",G=[];let J=0,oe;for(Y.lastIndex=0;(oe=Y.exec(re))!==null;){if(oe.index>J){const se=re.slice(J,oe.index);se&&G.push({text:se})}G.push({type:"template",placeholder:(oe[1]||"").trim(),value:"",style:"blue",fieldId:`template-${Date.now()}-${Math.random().toString(36).slice(2,7)}`,children:[{text:""}],inline:!0}),J=oe.index+oe[0].length}if(J<re.length){const se=re.slice(J);se&&G.push({text:se})}Re.removeNodes(q,{at:W}),Re.insertNodes(q,G,{at:W})}};return q.insertText=Y=>{Z(Y),z()},q.insertData=Y=>{const V=Y.getData("text/plain");if(V&&/<template>[\s\S]*?<\/template>/.test(V)){Z(V),z();return}return te(Y)},q};D.current=H(M)}const w=D.current,[k,E]=yt(()=>e.type==="slate"?e.content||[{type:"paragraph",children:[{text:""}]}]:[{type:"paragraph",children:[{text:""}]}]),[x,O]=yt(0);Ot(()=>{if(e.type==="slate"){console.log("UnifiedRichText: dataSource.content \u53D8\u5316:",e.content);const F=e.content||[{type:"paragraph",children:[{text:""}]}];console.log("UnifiedRichText: \u8BBE\u7F6E\u65B0\u7684 value:",F),E(F),O(M=>M+1)}},[e.type,e.content]),Ot(()=>{e.type==="markdown"&&O(F=>F+1)},[e.type,e.content]),Ot(()=>{e.type==="markdown"&&O(F=>F+1)},[p]);const j=mt(F=>{console.log("UnifiedRichText: \u5185\u5BB9\u53D8\u5316:",F),F&&Array.isArray(F)?(E(F),a==null||a(F,"slate")):console.log("UnifiedRichText: \u5FFD\u7565\u65E0\u6548\u7684\u5185\u5BB9\u53D8\u5316:",F)},[a]),$=xt(()=>{const F=C==null?void 0:C.baseFontSize;return typeof F=="number"&&!Number.isNaN(F)?F:n==="md"?14:12},[C,n]),P=mt(F=>{const M={...F,size:n,styles:g,eventsEmit:f,extraProps:p};return s?s(M):D9(M)},[s,n,g,f,p]),A=mt(F=>{const M={...F,styles:g,onRetriveTagClick:c};return u?u(M):S9(M)},[u,g,c]);Ot(()=>(window.copyCodeFromData=F=>{const M=F.getAttribute("data-code");if(!M){console.error("No code content found");return}const _=M.replace(/\\n/g,`
|
|
684
|
+
`).replace(/\\r/g,"\r").replace(/\\t/g," ").replace(/\\'/g,"'").replace(/\\\\/g,"\\").replace(/"/g,'"');navigator.clipboard.writeText(_).then(()=>{const X=F.innerHTML;F.innerHTML='<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#2da44e" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="20,6 9,17 4,12"></polyline></svg>',F.classList.add("copied"),setTimeout(()=>{F.innerHTML=X,F.classList.remove("copied")},2e3)}).catch(X=>{console.error("\u590D\u5236\u5931\u8D25:",X);const H=F.innerHTML;F.innerHTML='<svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>',F.style.background="#d73a49",F.style.borderColor="#d73a49",F.style.color="white",setTimeout(()=>{F.innerHTML=H,F.style.background="",F.style.borderColor="",F.style.color=""},2e3)})},()=>{delete window.copyCodeFromData}),[]);const B=xt(()=>{if(e.type!=="markdown")return null;try{const F=Tw(e.content||"");if(F&&F.length>0)return Q.jsx(id,{theme:C,$size:n,children:Q.jsx(Cc,{editor:w,initialValue:F,onChange:()=>{},children:Q.jsx(ld,{theme:C,children:Q.jsx(yc,{renderElement:P,renderLeaf:A,readOnly:!0,style:{minHeight:"inherit",outline:"none",border:"none",background:"transparent",fontSize:`${$}px`}})})},x)});const M={breaks:!0,gfm:!0,headerIds:!0,mangle:!1,sanitize:!1,pedantic:!1,smartLists:!0,smartypants:!0};let _=Kt(e.content||"",M);return _=_.replace(/<table([^>]*)>/g,'<div class="table-container"><table$1>'),_=_.replace(/<\/table>/g,"</table></div>"),_=_.replace(/<pre><code([^>]*)>([\s\S]*?)<\/code><\/pre>/g,(X,H,q)=>{const Z=q.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t").replace(/"/g,""");return`<pre><code${H}>${q}</code><button class="code-copy-btn" data-code="${Z}" onclick="copyCodeFromData(this)" title="\u590D\u5236\u4EE3\u7801"><svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect width="14" height="14" x="8" y="8" rx="2" ry="2"></rect><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"></path></svg></button></pre>`}),Q.jsx("div",{style:{padding:(C==null?void 0:C.padding)||"1rem",fontSize:`${$}px`,lineHeight:1.6,color:(C==null?void 0:C.textColor)||"#24292f"},dangerouslySetInnerHTML:{__html:_}})}catch(F){return console.error("Markdown parsing error:",F),Q.jsx("div",{children:e.content})}},[e,C,w,x,P,A,$]),S=xt(()=>e.type!=="html"?null:Q.jsx("div",{style:{padding:(C==null?void 0:C.padding)||"1rem",fontSize:`${$}px`,lineHeight:1.6,color:(C==null?void 0:C.textColor)||"#24292f"},dangerouslySetInnerHTML:{__html:e.content||""}}),[e,C,$]),I=xt(()=>e.type!=="text"?null:Q.jsx("div",{style:{padding:(C==null?void 0:C.padding)||"1rem",fontSize:`${$}px`,lineHeight:1.6,color:(C==null?void 0:C.textColor)||"#24292f"},children:Q.jsx("span",{children:e.content||""})}),[e,C,$]),N=()=>{switch(e.type){case"markdown":return B;case"html":return S;case"text":return I;case"slate":default:return t?Q.jsx(id,{theme:C,$size:n,children:Q.jsx(Cc,{editor:w,initialValue:k,onChange:j,children:Q.jsx(ld,{theme:C,children:Q.jsx(yc,{renderElement:P,renderLeaf:A,placeholder:r,readOnly:!1,onFocus:i,onBlur:l,style:{minHeight:"inherit",outline:"none",fontSize:`${$}px`}})})},x)}):Q.jsx(id,{theme:C,$size:n,children:Q.jsx(Cc,{editor:w,initialValue:k,onChange:()=>{},children:Q.jsx(ld,{theme:C,children:Q.jsx(yc,{renderElement:P,renderLeaf:A,readOnly:!0,style:{minHeight:"inherit",outline:"none",border:"none",background:"transparent",fontSize:`${$}px`}})})},x)})}};return Q.jsx(B9,{theme:C,$isEditing:t,className:h,style:v,children:N()})};/**
|
|
685
|
+
* @license lucide-react v0.456.0 - ISC
|
|
686
|
+
*
|
|
687
|
+
* This source code is licensed under the ISC license.
|
|
688
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
689
|
+
*/const O9=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),zw=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).join(" ").trim();/**
|
|
690
|
+
* @license lucide-react v0.456.0 - ISC
|
|
691
|
+
*
|
|
692
|
+
* This source code is licensed under the ISC license.
|
|
693
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
694
|
+
*/var A9={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
|
|
695
|
+
* @license lucide-react v0.456.0 - ISC
|
|
696
|
+
*
|
|
697
|
+
* This source code is licensed under the ISC license.
|
|
698
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
699
|
+
*/const F9=dn(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:o="",children:a,iconNode:i,...l},s)=>ks("svg",{ref:s,...A9,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:zw("lucide",o),...l},[...i.map(([u,c])=>ks(u,c)),...Array.isArray(a)?a:[a]]));/**
|
|
700
|
+
* @license lucide-react v0.456.0 - ISC
|
|
701
|
+
*
|
|
702
|
+
* This source code is licensed under the ISC license.
|
|
703
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
704
|
+
*/const Wn=(e,t)=>{const r=dn(({className:n,...o},a)=>ks(F9,{ref:a,iconNode:t,className:zw(`lucide-${O9(e)}`,n),...o}));return r.displayName=`${e}`,r};/**
|
|
705
|
+
* @license lucide-react v0.456.0 - ISC
|
|
706
|
+
*
|
|
707
|
+
* This source code is licensed under the ISC license.
|
|
708
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
709
|
+
*/const es=Wn("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
|
|
710
|
+
* @license lucide-react v0.456.0 - ISC
|
|
711
|
+
*
|
|
712
|
+
* This source code is licensed under the ISC license.
|
|
713
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
714
|
+
*/const ts=Wn("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
|
|
715
|
+
* @license lucide-react v0.456.0 - ISC
|
|
716
|
+
*
|
|
717
|
+
* This source code is licensed under the ISC license.
|
|
718
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
719
|
+
*/const N9=Wn("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
|
|
720
|
+
* @license lucide-react v0.456.0 - ISC
|
|
721
|
+
*
|
|
722
|
+
* This source code is licensed under the ISC license.
|
|
723
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
724
|
+
*/const P9=Wn("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/**
|
|
725
|
+
* @license lucide-react v0.456.0 - ISC
|
|
726
|
+
*
|
|
727
|
+
* This source code is licensed under the ISC license.
|
|
728
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
729
|
+
*/const j9=Wn("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/**
|
|
730
|
+
* @license lucide-react v0.456.0 - ISC
|
|
731
|
+
*
|
|
732
|
+
* This source code is licensed under the ISC license.
|
|
733
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
734
|
+
*/const I9=Wn("PenLine",[["path",{d:"M12 20h9",key:"t2du7b"}],["path",{d:"M16.376 3.622a1 1 0 0 1 3.002 3.002L7.368 18.635a2 2 0 0 1-.855.506l-2.872.838a.5.5 0 0 1-.62-.62l.838-2.872a2 2 0 0 1 .506-.854z",key:"1ykcvy"}]]);/**
|
|
735
|
+
* @license lucide-react v0.456.0 - ISC
|
|
736
|
+
*
|
|
737
|
+
* This source code is licensed under the ISC license.
|
|
738
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
739
|
+
*/const R9=Wn("RotateCcw",[["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"}]]);/**
|
|
740
|
+
* @license lucide-react v0.456.0 - ISC
|
|
741
|
+
*
|
|
742
|
+
* This source code is licensed under the ISC license.
|
|
743
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
744
|
+
*/const M9=Wn("Share",[["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}],["polyline",{points:"16 6 12 2 8 6",key:"m901s6"}],["line",{x1:"12",x2:"12",y1:"2",y2:"15",key:"1p0rca"}]]);/**
|
|
745
|
+
* @license lucide-react v0.456.0 - ISC
|
|
746
|
+
*
|
|
747
|
+
* This source code is licensed under the ISC license.
|
|
748
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
749
|
+
*/const T9=Wn("ThumbsDown",[["path",{d:"M17 14V2",key:"8ymqnk"}],["path",{d:"M9 18.12 10 14H4.17a2 2 0 0 1-1.92-2.56l2.33-8A2 2 0 0 1 6.5 2H20a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2h-2.76a2 2 0 0 0-1.79 1.11L12 22a3.13 3.13 0 0 1-3-3.88Z",key:"m61m77"}]]);/**
|
|
750
|
+
* @license lucide-react v0.456.0 - ISC
|
|
751
|
+
*
|
|
752
|
+
* This source code is licensed under the ISC license.
|
|
753
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
754
|
+
*/const z9=Wn("ThumbsUp",[["path",{d:"M7 10v12",key:"1qc93n"}],["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z",key:"emmmcr"}]]);/**
|
|
755
|
+
* @license lucide-react v0.456.0 - ISC
|
|
756
|
+
*
|
|
757
|
+
* This source code is licensed under the ISC license.
|
|
758
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
759
|
+
*/const _9=Wn("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"}]]);function $b(e){const t=(e||"").toLowerCase();return["png","jpg","jpeg","gif","bmp","webp","svg"].includes(t)?"rag/pic":t==="pdf"?"rag/pdf":["doc","docx"].includes(t)?"rag/word":["xls","xlsx"].includes(t)?"rag/excel":["ppt","pptx"].includes(t)?"rag/ppt":t==="txt"||t==="md"?"rag/txt":t==="csv"?"rag/csv":t==="json"?"rag/json":["zip","rar","7z"].includes(t)?"rag/zip":["odt","ods","odp","odf"].includes(t)?"rag/odf":t==="wps"?"rag/wps":["html","htm","url"].includes(t)?"rag/url":"rag/file"}function Ai(e){let t=[];for(const r of e)r.retrive===!0&&t.push(r),Array.isArray(r.children)&&(t=t.concat(Ai(r.children)));return t}function L9(e){const t=/<retrive-tag[^>]*image_urls=['"]([^'"]+)['"][^>]*>/g,r=[];let n;for(;n=t.exec(e);){const o=n[1].split(";").map(a=>a.trim()).filter(Boolean);r.push(...o)}return Array.from(new Set(r))}const H9=fr.div`
|
|
760
|
+
display: flex;
|
|
761
|
+
flex-direction: column;
|
|
762
|
+
margin-bottom: 0.5rem;
|
|
763
|
+
animation: fadeIn 0.3s ease-in-out;
|
|
764
|
+
width: 100%;
|
|
765
|
+
text-wrap: wrap;
|
|
766
|
+
|
|
767
|
+
${e=>e.$align==="right"&&`
|
|
768
|
+
align-items: flex-end;
|
|
769
|
+
`}
|
|
770
|
+
|
|
771
|
+
${e=>e.$align==="center"&&`
|
|
772
|
+
align-items: center;
|
|
773
|
+
`}
|
|
774
|
+
|
|
775
|
+
@keyframes fadeIn {
|
|
776
|
+
from { opacity: 0; transform: translateY(10px); }
|
|
777
|
+
to { opacity: 1; transform: translateY(0); }
|
|
778
|
+
}
|
|
779
|
+
`,W9=fr.div`
|
|
780
|
+
display: flex;
|
|
781
|
+
align-items: center;
|
|
782
|
+
gap: 0.5rem;
|
|
783
|
+
margin-bottom: 0.5rem;
|
|
784
|
+
width: 100%;
|
|
785
|
+
|
|
786
|
+
${e=>e.$isUser&&`
|
|
787
|
+
flex-direction: row-reverse;
|
|
788
|
+
justify-content: end;
|
|
789
|
+
`}
|
|
790
|
+
`,K9=fr.div`
|
|
791
|
+
background: ${e=>e.$src?`url('${e.$src}') center/cover no-repeat`:"var(--avatar-bg, #e5e7eb)"};
|
|
792
|
+
border-radius: 50%;
|
|
793
|
+
width: 2rem;
|
|
794
|
+
height: 2rem;
|
|
795
|
+
|
|
796
|
+
flex-shrink: 0;
|
|
797
|
+
display: flex;
|
|
798
|
+
align-items: center;
|
|
799
|
+
justify-content: center;
|
|
800
|
+
font-size: 1rem;
|
|
801
|
+
`,q9=fr.div`
|
|
802
|
+
width: 100%;
|
|
803
|
+
margin-top: 0.5rem;
|
|
804
|
+
.message-time {
|
|
805
|
+
font-size: 0.75rem;
|
|
806
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.disabled)||"#6b7280"}};
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
.message-card {
|
|
810
|
+
background: ${e=>e.$isUser?"#E3ECFF":"#ffffff"};
|
|
811
|
+
border: 1px solid ${e=>(e.$isUser,"transparent")};
|
|
812
|
+
border-radius: 0.5rem;
|
|
813
|
+
|
|
814
|
+
overflow: hidden;
|
|
815
|
+
max-width: ${e=>e.$isUser?"fit-content":"100%"};
|
|
816
|
+
margin-left: ${e=>e.$isUser?"auto":"0"};
|
|
817
|
+
|
|
818
|
+
.message-text {
|
|
819
|
+
width: 100%;
|
|
820
|
+
line-height: 1.6;
|
|
821
|
+
padding: 0.75rem 1rem;
|
|
822
|
+
border-radius: 0.5rem;
|
|
823
|
+
min-height: ${e=>e.$isUser?"auto":"40px"};
|
|
824
|
+
font-size: 0.875rem;
|
|
825
|
+
}
|
|
826
|
+
}
|
|
827
|
+
`,V9=fr.div`
|
|
828
|
+
margin-top: 0.5rem;
|
|
829
|
+
display: flex;
|
|
830
|
+
padding: 0.5rem;
|
|
831
|
+
align-items: center;
|
|
832
|
+
|
|
833
|
+
gap: 0.75rem;
|
|
834
|
+
|
|
835
|
+
button {
|
|
836
|
+
display: flex;
|
|
837
|
+
align-items: center;
|
|
838
|
+
gap: 0.25rem;
|
|
839
|
+
font-size: 0.875rem;
|
|
840
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.disabled)||"#6b7280"}};
|
|
841
|
+
background: none;
|
|
842
|
+
border: none;
|
|
843
|
+
cursor: pointer;
|
|
844
|
+
transition: color 0.2s;
|
|
845
|
+
|
|
846
|
+
&:hover {
|
|
847
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.primary)||"#3b82f6"}};
|
|
848
|
+
}
|
|
849
|
+
|
|
850
|
+
&.active {
|
|
851
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.primary)||"#3b82f6"}} !important;
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
`,G9=fr.div`
|
|
855
|
+
margin-top: 1rem;
|
|
856
|
+
padding: 1rem;
|
|
857
|
+
|
|
858
|
+
border-radius: 0.5rem;
|
|
859
|
+
|
|
860
|
+
@keyframes followUpIn {
|
|
861
|
+
from {
|
|
862
|
+
opacity: 0;
|
|
863
|
+
transform: translateY(6px);
|
|
864
|
+
}
|
|
865
|
+
to {
|
|
866
|
+
opacity: 1;
|
|
867
|
+
transform: translateY(0);
|
|
868
|
+
}
|
|
869
|
+
}
|
|
870
|
+
|
|
871
|
+
.follow-up-title {
|
|
872
|
+
font-size: 0.875rem;
|
|
873
|
+
font-weight: 600;
|
|
874
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.text)||"#374151"}};
|
|
875
|
+
margin-bottom: 0.75rem;
|
|
876
|
+
}
|
|
877
|
+
|
|
878
|
+
.follow-up-list {
|
|
879
|
+
display: flex;
|
|
880
|
+
flex-direction: column;
|
|
881
|
+
gap: 0.5rem;
|
|
882
|
+
}
|
|
883
|
+
|
|
884
|
+
.follow-up-item {
|
|
885
|
+
width: fit-content;
|
|
886
|
+
background: #ffffff;
|
|
887
|
+
border: 1px solid #e5e7eb;
|
|
888
|
+
border-radius: 0.375rem;
|
|
889
|
+
padding: 0.75rem 1rem;
|
|
890
|
+
cursor: pointer;
|
|
891
|
+
transition: all 0.2s ease;
|
|
892
|
+
text-align: left;
|
|
893
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.text)||"#374151"}};
|
|
894
|
+
font-size: 0.875rem;
|
|
895
|
+
line-height: 1.4;
|
|
896
|
+
opacity: 0;
|
|
897
|
+
transform: translateY(6px);
|
|
898
|
+
animation: followUpIn 280ms ease forwards;
|
|
899
|
+
animation-play-state: running;
|
|
900
|
+
|
|
901
|
+
&:hover {
|
|
902
|
+
background: #e5e7eb;
|
|
903
|
+
border-color: #d1d5db;
|
|
904
|
+
}
|
|
905
|
+
|
|
906
|
+
&:active {
|
|
907
|
+
transform: translateY(1px);
|
|
908
|
+
}
|
|
909
|
+
}
|
|
910
|
+
`,rs=fr.div`
|
|
911
|
+
|
|
912
|
+
padding: 1rem;
|
|
913
|
+
background: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.background)||"#ffffff"}};
|
|
914
|
+
|
|
915
|
+
border-radius: 0.5rem;
|
|
916
|
+
|
|
917
|
+
|
|
918
|
+
.reference-title {
|
|
919
|
+
font-size: 0.875rem;
|
|
920
|
+
font-weight: 600;
|
|
921
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.text)||"#374151"}};
|
|
922
|
+
margin-bottom: 0.75rem;
|
|
923
|
+
}
|
|
924
|
+
|
|
925
|
+
.reference-list {
|
|
926
|
+
display: flex;
|
|
927
|
+
flex-direction: column;
|
|
928
|
+
gap: 0.5rem;
|
|
929
|
+
}
|
|
930
|
+
|
|
931
|
+
.reference-item {
|
|
932
|
+
background: #ffffff;
|
|
933
|
+
|
|
934
|
+
border-radius: 0.375rem;
|
|
935
|
+
padding: 0.75rem 0;
|
|
936
|
+
display: flex;
|
|
937
|
+
align-items: center;
|
|
938
|
+
gap: 0.5rem;
|
|
939
|
+
|
|
940
|
+
.file-icon {
|
|
941
|
+
width: 2rem;
|
|
942
|
+
height: 2rem;
|
|
943
|
+
background: #e2e8f0;
|
|
944
|
+
border-radius: 0.25rem;
|
|
945
|
+
display: flex;
|
|
946
|
+
align-items: center;
|
|
947
|
+
justify-content: center;
|
|
948
|
+
font-size: 0.75rem;
|
|
949
|
+
color: #64748b;
|
|
950
|
+
}
|
|
951
|
+
|
|
952
|
+
.file-info {
|
|
953
|
+
flex: 1;
|
|
954
|
+
|
|
955
|
+
.file-name {
|
|
956
|
+
font-size: 0.875rem;
|
|
957
|
+
font-weight: 500;
|
|
958
|
+
color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.text)||"#374151"}};
|
|
959
|
+
margin-bottom: 0.25rem;
|
|
960
|
+
}
|
|
961
|
+
|
|
962
|
+
.file-meta {
|
|
963
|
+
font-size: 0.75rem;
|
|
964
|
+
color: #64748b;
|
|
965
|
+
}
|
|
966
|
+
}
|
|
967
|
+
|
|
968
|
+
.file-score {
|
|
969
|
+
font-size: 0.75rem;
|
|
970
|
+
color: #059669;
|
|
971
|
+
font-weight: 500;
|
|
972
|
+
}
|
|
973
|
+
}
|
|
974
|
+
`,X9=fr.div`
|
|
975
|
+
position: fixed;
|
|
976
|
+
top: 0;
|
|
977
|
+
left: 0;
|
|
978
|
+
right: 0;
|
|
979
|
+
bottom: 0;
|
|
980
|
+
background: rgba(0, 0, 0, 0.8);
|
|
981
|
+
display: ${e=>e.$show?"flex":"none"};
|
|
982
|
+
align-items: center;
|
|
983
|
+
justify-content: center;
|
|
984
|
+
z-index: 1000;
|
|
985
|
+
cursor: pointer;
|
|
986
|
+
|
|
987
|
+
.modal-content {
|
|
988
|
+
max-width: 90vw;
|
|
989
|
+
max-height: 90vh;
|
|
990
|
+
position: relative;
|
|
991
|
+
cursor: default;
|
|
992
|
+
display: flex;
|
|
993
|
+
flex-direction: column;
|
|
994
|
+
align-items: center;
|
|
995
|
+
}
|
|
996
|
+
|
|
997
|
+
.modal-image {
|
|
998
|
+
max-width: 100%;
|
|
999
|
+
max-height: calc(90vh - 60px);
|
|
1000
|
+
object-fit: contain;
|
|
1001
|
+
border-radius: 8px;
|
|
1002
|
+
}
|
|
1003
|
+
|
|
1004
|
+
.modal-close {
|
|
1005
|
+
margin-top: 16px;
|
|
1006
|
+
background: rgba(255, 255, 255, 0.3);
|
|
1007
|
+
border: none;
|
|
1008
|
+
border-radius: 20px;
|
|
1009
|
+
padding: 8px 20px;
|
|
1010
|
+
display: flex;
|
|
1011
|
+
align-items: center;
|
|
1012
|
+
justify-content: center;
|
|
1013
|
+
cursor: pointer;
|
|
1014
|
+
font-size: 14px;
|
|
1015
|
+
color: #333;
|
|
1016
|
+
font-weight: 500;
|
|
1017
|
+
transition: all 0.2s ease;
|
|
1018
|
+
|
|
1019
|
+
&:hover {
|
|
1020
|
+
background: rgba(255, 255, 255, 1);
|
|
1021
|
+
transform: translateY(-1px);
|
|
1022
|
+
}
|
|
1023
|
+
}
|
|
1024
|
+
`,Bb=fr.div`
|
|
1025
|
+
|
|
1026
|
+
padding:0rem 1rem;
|
|
1027
|
+
background: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.background)||"#ffffff"}};
|
|
1028
|
+
|
|
1029
|
+
.gallery-grid {
|
|
1030
|
+
display: grid;
|
|
1031
|
+
grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
|
|
1032
|
+
gap: 0.75rem;
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
.gallery-item {
|
|
1036
|
+
position: relative;
|
|
1037
|
+
aspect-ratio: 1;
|
|
1038
|
+
border-radius: 0.375rem;
|
|
1039
|
+
overflow: hidden;
|
|
1040
|
+
cursor: pointer;
|
|
1041
|
+
transition: transform 0.2s ease, box-shadow 0.2s ease;
|
|
1042
|
+
border: 2px solid transparent;
|
|
1043
|
+
|
|
1044
|
+
&:hover {
|
|
1045
|
+
transform: translateY(-2px);
|
|
1046
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
|
|
1047
|
+
border-color: ${e=>{var t,r;return((r=(t=e.$theme)==null?void 0:t.colors)==null?void 0:r.primary)||"#3b82f6"}};
|
|
1048
|
+
}
|
|
1049
|
+
|
|
1050
|
+
.gallery-image {
|
|
1051
|
+
width: 100%;
|
|
1052
|
+
height: 100%;
|
|
1053
|
+
object-fit: cover;
|
|
1054
|
+
background: #f3f4f6;
|
|
1055
|
+
}
|
|
1056
|
+
|
|
1057
|
+
.gallery-overlay {
|
|
1058
|
+
position: absolute;
|
|
1059
|
+
bottom: 0;
|
|
1060
|
+
left: 0;
|
|
1061
|
+
right: 0;
|
|
1062
|
+
background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
|
|
1063
|
+
color: white;
|
|
1064
|
+
padding: 0.5rem;
|
|
1065
|
+
font-size: 0.75rem;
|
|
1066
|
+
text-align: center;
|
|
1067
|
+
opacity: 0;
|
|
1068
|
+
transition: opacity 0.2s ease;
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
&:hover .gallery-overlay {
|
|
1072
|
+
opacity: 1;
|
|
1073
|
+
}
|
|
1074
|
+
}
|
|
1075
|
+
`,lz=({is_download:e,content:t,contentType:r="plainText",align:n="left",displayStatus:o="ready",avatar:a,isUser:i=!1,userAvatar:l,aiAvatar:s,date:u,time:c,timestamp:f,showTime:p=!0,errorMessage:h,styles:v,reference:g,webReference:m,databaseReference:b,graphReference:y,filePaths:C,currentFiles:D,fileManagerData:w,audioUrl:k,feedbackResult:E,queryId:x,defaultAnswer:O,isWelcome:j=!1,isLast:$=!1,respTime:P,tokens:A,resultType:B,followUpQuestions:S=[],tools:I={},eventsEmit:N})=>{Ot(()=>{console.log("isUser",i),console.log("isLast",$)},[$,i]);const F=ru(),M=xt(()=>{var ae,he,xe,be,Ce,de,Se,le,ie,me,ze;return{colors:{primary:((ae=F==null?void 0:F.colors)==null?void 0:ae.primary)||"#3b82f6",background:((he=F==null?void 0:F.colors)==null?void 0:he.background)||"#ffffff",userBackground:((xe=F==null?void 0:F.colors)==null?void 0:xe.primary)||"#3b82f6",border:((be=F==null?void 0:F.colors)==null?void 0:be.border)||"#e5e7eb",text:((Ce=F==null?void 0:F.colors)==null?void 0:Ce.text)||"#374151",disabled:((de=F==null?void 0:F.colors)==null?void 0:de.disabled)||"#6b7280",info:((Se=F==null?void 0:F.colors)==null?void 0:Se.info)||"#3b82f6",warning:((le=F==null?void 0:F.colors)==null?void 0:le.warning)||"#f59e0b",error:((ie=F==null?void 0:F.colors)==null?void 0:ie.error)||"#ef4444",...(me=v==null?void 0:v.theme)==null?void 0:me.colors},icons:{aiAvatar:s||"/vite.svg",userAvatar:l||"/default-user-avatar.png",...(ze=v==null?void 0:v.theme)==null?void 0:ze.icons}}},[F,v,s,l]),_=xt(()=>{const ae=c||u||f;return!ae||!p?null:O4(ae).format("YY-MM-DD HH:mm:ss")},[c,u,f,p]),[X,H]=yt([]),[q,Z]=yt(null),[te,z]=yt(!1),[Y,V]=yt(!1),[U,K]=yt(!1),[W,re]=yt(!1),[G,J]=yt(!1),oe=()=>{const ae={processing:{text:"AI \u6B63\u5728\u601D\u8003...",icon:"\u{1F4AD}"},thinking:{text:"\u6DF1\u5EA6\u601D\u8003\u4E2D",icon:"\u{1F4AD}"},uploading:{text:"\u6587\u4EF6\u4E0A\u4F20\u4E2D...",icon:"\u{1F4E4}"},analyzing:{text:"\u77E5\u8BC6\u89E3\u6790\u4E2D...",icon:"\u{1F50D}"},error:{text:h||"\u62B1\u6B49\uFF0C\u672C\u6B21\u8BF7\u6C42\u51FA\u9519\u4E86\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5",icon:"\u274C"},initializing:{text:"\u6B63\u5728\u521D\u59CB\u5316...",icon:"\u2699\uFE0F"},ready:{text:"\u601D\u8003\u5B8C\u6210",icon:Q.jsx(Pl,{type:"rag/think",size:16})}}[o]||{text:"\u5904\u7406\u4E2D...",icon:"\u{1F4AD}"},he=P?`(\u7528\u65F6 ${Math.round(P/1e3)} \u79D2)`:"";return Q.jsx("div",{className:"think-header",children:Q.jsx("div",{className:"think-header-left ml-[16px]",children:Q.jsxs("div",{className:"flex items-center gap-x-1 bg-[#F5F7FA] p-2 rounded w-fit",children:[Q.jsx("div",{className:"think-icon",children:ae.icon}),Q.jsx("div",{className:"think-title",children:ae.text}),he&&Q.jsx("div",{className:"think-time",children:he}),Be&&Q.jsx("button",{className:"think-collapse-btn ml-2 cursor-pointer",title:"\u6536\u8D77/\u5C55\u5F00",onClick:()=>{J(!G)},children:Q.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",style:{transform:G?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"},children:Q.jsx("path",{d:"m18 15-6-6-6 6"})})})]})})})},[se,ge]=yt([]),[Ee,je]=yt(null),ve=xt(()=>{try{if(!g)return[];const ae=JSON.parse(g);return Array.isArray(ae)?ae:[]}catch{return[]}},[g]),ye=(ae,he)=>{var Se,le,ie;const xe=((Se=ae==null?void 0:ae.metadata)==null?void 0:Se.source)||(ae==null?void 0:ae.file_path)||(ae==null?void 0:ae.path)||(ae==null?void 0:ae.convertedFilePath)||(ae==null?void 0:ae.parsedFilePath)||"",be=((le=ae==null?void 0:ae.metadata)==null?void 0:le.title)||(ae==null?void 0:ae.file_name)||"",Ce=((ie=ae==null?void 0:ae.metadata)==null?void 0:ie.id)||(ae==null?void 0:ae.id)||(ae==null?void 0:ae.file_id)||"",de=ve.find(me=>{var Pe,Ze,wt;const ze=((Pe=me==null?void 0:me.metadata)==null?void 0:Pe.source)||(me==null?void 0:me.file_path)||(me==null?void 0:me.path)||(me==null?void 0:me.convertedFilePath)||(me==null?void 0:me.parsedFilePath)||"",_e=((Ze=me==null?void 0:me.metadata)==null?void 0:Ze.title)||(me==null?void 0:me.file_name)||"",Ke=((wt=me==null?void 0:me.metadata)==null?void 0:wt.id)||(me==null?void 0:me.id)||"";return Ce&&Ke&&String(Ce)===String(Ke)||xe&&ze&&ze===xe||be&&_e&&_e===be});if(de){const me=(de!=null&&de.references&&Array.isArray(de.references)?de.references:[de]).find(ze=>String(ze.order_num)===String(he)||String(ze.id)===String(he));if(me)return me}for(const me of ve){if(me!=null&&me.references&&Array.isArray(me.references)){const ze=me.references.find(_e=>String(_e.order_num)===String(he)||String(_e.id)===String(he));if(ze)return ze}if(String(me.order_num)===String(he)||String(me.id)===String(he))return me}return null},ke=(ae,he)=>{function xe(de,Se){for(const le of de){if(le.references&&Array.isArray(le.references)){const ie=le.references.find(me=>String(me.order_num)===String(Se)||String(me.id)===String(Se));if(ie)return ie}if(String(le.order_num)===String(Se)||String(le.id)===String(Se))return le}return null}let be=[];try{g&&(be=JSON.parse(g))}catch(de){console.error("Failed to parse reference:",de)}const Ce=xe(be,ae.id);N==null||N("action_retrive_tag",{tagInfo:Ce,fromtype:ae.fromtype,leaf:ae,attributes:he})},we=ae=>{if(console.log("ChatMessageAdapter received retrieve-sql-data:request-data:",ae),console.log("databaseReference available:",!!b),ae.id&&b){console.log("Sending retrieve-sql-data:data-response with databaseReference"),console.log("databaseReference data:",b);const he=new CustomEvent("retrieve-sql-data:data-response",{detail:{id:ae.id,databaseReference:b}});console.log("Dispatching event:",he),window.dispatchEvent(he)}else console.log("Cannot send response - missing id or databaseReference")};ee.useEffect(()=>{const ae=he=>{we(he.detail)};return window.addEventListener("retrieve-sql-data:request-data",ae),()=>{window.removeEventListener("retrieve-sql-data:request-data",ae)}},[b]),ee.useEffect(()=>{const ae=he=>{De(he.detail)};return window.addEventListener("rtext_pagination_click",ae),()=>{window.removeEventListener("rtext_pagination_click",ae)}},[Ee]);const De=ae=>{if(console.log("ChatMessageAdapter received rtext_pagination_click:",ae),ae.replacePredataFunction&&Ee){const he={...Ee,rows:Ee.rows};ae.replacePredataFunction(he)}N==null||N("rtext_pagination_click",ae)},Ne=qe(new Map),Oe=qe(1),Xe=qe(""),Le=qe({0:1,1:1}),Fe=xt(()=>{if(r==="stream"&&typeof t=="string"){let ae=t;const he=[];return x&&x!==Xe.current&&(Ne.current.clear(),Oe.current=1,Le.current={0:1,1:1},Xe.current=x),ae=ae.replace(/\[retrive-tag([^\]]*)\]\[([^\]]+)\]\[\/retrive-tag\]/g,(xe,be)=>{const Ce=be.match(/id=['"]([^'"]+)['"]/),de=be.match(/fromType=['"]([^'"]+)['"]/);if(Ce){const Se=Ce[1],le=de?de[1]:"0";if(!Ne.current.has(Se)){const me=Le.current,ze=le==="1"?"1":"0",_e=me[ze]??1;Ne.current.set(Se,_e),me[ze]=_e+1,Le.current=me}const ie=Ne.current.get(Se);return`[retrive-tag${be}][${ie}][/retrive-tag]`}return xe}),ae=ae.replace(/\[retrive-tag[^\]]*fromType=['"]0['"][^\]]*\]\[([^\]]+)\]\[\/retrive-tag\]/g,xe=>{const be=xe.match(/image_urls=['"]([^'"]+)['"]/);if(be){const Ce=be[1].split(";").map(de=>de.trim()).filter(Boolean);he.push(...Ce)}return xe}),H(he),ae}return t},[t,r,x]),fe=xt(()=>{if(r==="stream"&&typeof Fe=="string")try{return Tw(Fe)}catch(ae){return console.error("Failed to deserialize markdown:",ae),[]}return[]},[Fe,r]);Ot(()=>{try{r==="stream"&&b&&(ae=>{try{const he=typeof ae=="string"?JSON.parse(ae):ae;return he?Array.isArray(he)?he:[he]:[]}catch{return[]}})(b).forEach(ae=>{const he=ae==null?void 0:ae.id;if(!he)return;const xe=new CustomEvent("retrieve-sql-data:data-response",{detail:{id:he,databaseReference:ae}});window.dispatchEvent(xe)})}catch{}},[r,b]);const Be=xt(()=>{if(!Array.isArray(fe))return!1;const ae=xe=>{for(const be of xe)if(be.type==="think"||Array.isArray(be.children)&&ae(be.children))return!0;return!1},he=ae(fe);return console.log("Think detection:",{slateContent:fe,hasThinkElement:he,displayStatus:o,isUser:i}),he},[fe,o,i]),We=xt(()=>({databaseReference:b,...Be&&{isThinkCollapsed:G}}),[b,Be,G]),Ye=xt(()=>a||(i?M.icons.userAvatar:M.icons.aiAvatar),[a,i,M.icons]),Ve=xt(()=>typeof t=="string"?t:Array.isArray(t)?t.map(ae=>typeof ae=="string"?ae:ae.text||"").join(""):O||"",[t,O]),Te=()=>{if(j)return null;const ae=[{key:"copy",show:I.copy!==!1,icon:N9,label:"\u590D\u5236",onClick:()=>N==null?void 0:N("chatbox:copy",{content:Ve})},{key:"like",show:I.like!==!1,icon:z9,label:"\u8D5E",onClick:()=>N==null?void 0:N("chatbox:like",{result:E,queryId:x}),active:E===1},{key:"dislike",show:I.dislike!==!1,icon:T9,label:"\u8E29",onClick:()=>N==null?void 0:N("chatbox:dislike",{result:E,queryId:x}),active:E===0},{key:"repeat",show:!i&&$,icon:R9,label:"\u91CD\u590D",onClick:()=>N==null?void 0:N("chatbox:repeat",{content:t,queryId:x,filePaths:C,audioUrl:k})},{key:"forward",show:I.forward,icon:M9,label:"\u8F6C\u53D1",onClick:()=>N==null?void 0:N("chatbox:forward",{content:Ve,queryId:x})},{key:"delete",show:I.delete,icon:_9,label:"\u5220\u9664",onClick:()=>N==null?void 0:N("chatbox:delete",{queryId:x})},{key:"edit",show:I.edit,icon:I9,label:"\u7F16\u8F91",onClick:()=>N==null?void 0:N("chatbox:edit",{content:Ve,queryId:x})}];return Q.jsxs("div",{className:"flex justify-between items-center px-6",children:[Q.jsx(V9,{$theme:M,children:ae.filter(he=>he.show).map(he=>{const xe=he.icon;return Q.jsx(ml,{title:he.label,placement:"top",children:Q.jsx("button",{className:he.active?"active":"",onClick:he.onClick,children:Q.jsx(xe,{size:18})})},he.key)})}),!i&&o=="ready"&&!j&&Q.jsxs("div",{className:"text-[10px] text-[#888888]",children:["\u672C\u6B21\u56DE\u7B54\u603B\u8BA1\u6D88\u8017"," ",Q.jsx("span",{style:{color:M.colors.primary},children:A||0})," ","tokens, \u7B49\u5F85\u603B\u8BA1\u8017\u65F6"," ",Q.jsx("span",{style:{color:M.colors.primary},children:Math.round((P||0)/1e3)}),"\u79D2"]})]})},it=xt(()=>{if(!g)return[];let ae=[];try{const Ce=JSON.parse(g);ae=Array.isArray(Ce)?Ce:[]}catch{return[]}let he=ae.map(Ce=>{try{const de=Ce.metadata||{};let Se="";Ce.name&&typeof Ce.name=="string"?Se=Ce.name:Ce.file_name&&typeof Ce.file_name=="string"?Se=Ce.file_name:de.source&&typeof de.source=="string"?Se=de.source.split("/").pop()||"":Ce.order_num?Se=String(Ce.order_num):Se="\u672A\u77E5\u6587\u6863";let le="pdf";if(Ce.name&&typeof Ce.name=="string"){const me=Ce.name.split(".").pop();me&&(le=me.toLowerCase())}else if(de.source&&typeof de.source=="string"){const me=de.source.split(".").pop();me&&(le=me.toLowerCase())}else if(Ce.file_path&&typeof Ce.file_path=="string"){const me=Ce.file_path.split(".").pop();me&&(le=me.toLowerCase())}const ie=Ce.parsedFilePath||de.file_path||Ce.file_path||Ce.convertedFilePath||"";return{file_id:de.id||Ce.uid||"",file_name:Se,file_type:le,path:ie,score:Number(Ce.score)||0,tags:[],parsedFilePath:Ce.parsedFilePath,...Ce}}catch(de){return console.warn("\u89E3\u6790\u5F15\u7528\u6587\u6863\u65F6\u51FA\u9519:",de,Ce),{file_id:Ce.uid||"",file_name:Ce.name||"\u672A\u77E5\u6587\u6863",file_type:"unknown",path:Ce.convertedFilePath||Ce.file_path||"",score:0,tags:[],parsedFilePath:Ce.parsedFilePath,...Ce}}});const xe=Ai(fe||[]);if(xe&&xe.length){const Ce=xe.filter(de=>de.fromtype==="0");he=he.map(de=>{const Se=Ce.filter(le=>{var me,ze;const ie=ae.find(_e=>String(_e.order_num)===String(le.id));return((me=ie==null?void 0:ie.metadata)==null?void 0:me.source)&&((ze=de==null?void 0:de.metadata)==null?void 0:ze.source)&&ie.metadata.source===de.metadata.source}).map(le=>({id:le.id||"",index:le.indexId||"",image_urls:le.imageUrls?Array.isArray(le.imageUrls)?le.imageUrls:[le.imageUrls]:le.image_urls?le.image_urls.split(";").map(ie=>ie.trim()).filter(Boolean):[]}));return{...de,tags:Se}})}const be=new Map;return he.filter(Ce=>{var Se;const de=((Se=Ce==null?void 0:Ce.metadata)==null?void 0:Se.source)||Ce.file_name;return de?be.has(de)?!1:(be.set(de,!0),!0):!0}).sort((Ce,de)=>((de==null?void 0:de.score)||0)-((Ce==null?void 0:Ce.score)||0))},[g,fe]),Ue=xt(()=>{if(!m)return[];let ae=[];try{const be=JSON.parse(m);ae=Array.isArray(be)?be:[]}catch{return[]}if(!(ae!=null&&ae.length))return[];let he=ae.map(be=>{var Ce,de,Se;return{link:(Ce=be==null?void 0:be.metadata)==null?void 0:Ce.link,file_name:(de=be==null?void 0:be.metadata)==null?void 0:de.title,score:(Se=be==null?void 0:be.metadata)==null?void 0:Se.score,tags:[]}});const xe=Ai(fe||[]);if(xe&&xe.length){const be=xe.filter(Ce=>Ce.fromtype==="1");he=he.map(Ce=>{const de=be.filter(Se=>{var ie;const le=ae.find(me=>String(me.order_num)===String(Se.id));return((ie=le==null?void 0:le.metadata)==null?void 0:ie.title)&&le.metadata.title===Ce.file_name}).map(Se=>({id:Se.id||"",index:Se.indexId||"",image_urls:Se.imageUrls?Array.isArray(Se.imageUrls)?Se.imageUrls:[Se.imageUrls]:Se.image_urls?Se.image_urls.split(";").map(le=>le.trim()).filter(Boolean):[]}));return{...Ce,tags:de}})}return he.sort((be,Ce)=>((Ce==null?void 0:Ce.score)||0)-((be==null?void 0:be.score)||0))},[m,fe]),nt=xt(()=>{if(!y)return[];let ae=[];try{const be=JSON.parse(y);ae=Array.isArray(be)?be:[]}catch(be){return console.error("Failed to parse graphReference:",be),[]}let he=ae.map((be,Ce)=>({id:be.id||`graph-${Ce}`,graphName:be.graphName||`\u56FE\u8C31${Ce+1}`,tags:[],...be}));const xe=Ai(fe||[]);if(xe&&xe.length){const be=xe.filter(Ce=>Ce.fromtype==="2");he=he.map(Ce=>{const de=be.filter(Se=>String(Se.id)===String(Ce.id)).map(Se=>({id:Se.id||"",index:Se.indexId||"",image_urls:Se.imageUrls?Array.isArray(Se.imageUrls)?Se.imageUrls:[Se.imageUrls]:Se.image_urls?Se.image_urls.split(";").map(le=>le.trim()).filter(Boolean):[]}));return{...Ce,tags:de}})}return he},[y,fe]),pt=xt(()=>{const ae=[...Ai(fe||[]).filter(he=>he.imageUrls&&Array.isArray(he.imageUrls)).flatMap(he=>he.imageUrls),...X];return Array.from(new Set(ae))},[fe,X]),St=xt(()=>typeof t!="string"?[]:L9(t),[t]),dt=xt(()=>{var ae,he,xe,be,Ce,de,Se,le;if(!b)return null;try{const ie=typeof b=="string"?JSON.parse(b):b;if(Array.isArray(ie)&&ie.length>0){const me=ie[0];if(me.retrieveSqlData)return{dataFetchUrl:me.retrieveSqlData.fetchUrl||"/index/knowledgeBase/file/stream",databaseName:me.retrieveSqlData.databaseName||"\u6570\u636E\u5E93",tableName:me.retrieveSqlData.tableName||"\u6570\u636E\u8868",total:me.retrieveSqlData.total||0,type:me.retrieveSqlData.type||"COLLECTION",preData:{columns:((he=(ae=me.retrieveSqlData.preData)==null?void 0:ae[0])==null?void 0:he.columns)||[],rows:((be=(xe=me.retrieveSqlData.preData)==null?void 0:xe[0])==null?void 0:be.data)||[]}}}return ie.retrieveSqlData?{dataFetchUrl:ie.retrieveSqlData.fetchUrl||"/index/knowledgeBase/file/stream",databaseName:ie.retrieveSqlData.databaseName||"\u6570\u636E\u5E93",tableName:ie.retrieveSqlData.tableName||"\u6570\u636E\u8868",total:ie.retrieveSqlData.total||0,type:ie.retrieveSqlData.type||"COLLECTION",preData:{columns:((de=(Ce=ie.retrieveSqlData.preData)==null?void 0:Ce[0])==null?void 0:de.columns)||[],rows:((le=(Se=ie.retrieveSqlData.preData)==null?void 0:Se[0])==null?void 0:le.data)||[]}}:{dataFetchUrl:ie.dataFetchUrl||"/index/knowledgeBase/file/stream",databaseName:ie.databaseName||"\u6570\u636E\u5E93",tableName:ie.tableName||"\u6570\u636E\u8868",total:ie.total||0,type:ie.type||"COLLECTION",preData:ie.preData||{columns:[],rows:[]}}}catch(ie){return console.error("Failed to parse databaseReference:",ie),null}},[b]),ht=ae=>{const{dataSourceType:he,databaseName:xe,businessTableName:be,tableName:Ce}=ae;return he==="DataTable"?`${xe||"\u6570\u636E\u5E93"} - ${be||"\u6570\u636E\u8868"}`:he==="DirectDB"?`${xe||"\u6570\u636E\u5E93"} - ${Ce||"\u6570\u636E\u8868"}`:xe||be||Ce||"\u6570\u636E\u5E93"};ee.useEffect(()=>{var ae,he,xe,be,Ce,de,Se,le;if(b)try{const ie=typeof b=="string"?JSON.parse(b):b;if(Array.isArray(ie)&&ie.length>0){const me=ie[0];if(me.retrieveTableDataList&&Array.isArray(me.retrieveTableDataList)){ge(me.retrieveTableDataList);return}if((xe=(he=(ae=me.retrieveSqlData)==null?void 0:ae.preData)==null?void 0:he[0])!=null&&xe.data&&Array.isArray(me.retrieveSqlData.preData[0].data)){ge(me.retrieveSqlData.preData[0].data);return}}if(ie.retrieveTableDataList&&Array.isArray(ie.retrieveTableDataList)){ge(ie.retrieveTableDataList);return}if((de=(Ce=(be=ie.retrieveSqlData)==null?void 0:be.preData)==null?void 0:Ce[0])!=null&&de.data&&Array.isArray(ie.retrieveSqlData.preData[0].data)){ge(ie.retrieveSqlData.preData[0].data);return}(Se=dt==null?void 0:dt.preData)!=null&&Se.rows&&ge(dt.preData.rows)}catch(ie){console.error("Failed to parse databaseReference for retrieveTableDataList:",ie),(le=dt==null?void 0:dt.preData)!=null&&le.rows&&ge(dt.preData.rows)}},[b,dt]);const Pt=xt(()=>{if(!i)return[];if(Array.isArray(D))return D;if(typeof D=="string"&&D)try{return JSON.parse(D)}catch{return[]}return[]},[i,D]),At=()=>{if(!i||Pt.length===0)return null;const ae=le=>le!=null&&le.status&&(String(le.status).toLowerCase()==="uploading"||String(le.status).toLowerCase()==="parsing")?!1:!!(le!=null&&le.url||le!=null&&le.filePath||le!=null&&le.convertedFilePath),he=Pt.filter(le=>{const ie=(le.name||"").split(".").pop()||"";return["image","jpg","jpeg","png","gif","bmp","webp"].includes(ie.toLowerCase())}),xe=Pt.filter(le=>{const ie=(le.name||"").split(".").pop()||"";return!["image","jpg","jpeg","png","gif","bmp","webp"].includes(ie.toLowerCase())}),be=he.filter(ae),Ce=he.filter(le=>!ae(le)),de=xe.filter(ae),Se=xe.filter(le=>!ae(le));return Q.jsxs("div",{className:"w-full mt-4",children:[(be.length>0||Ce.length>0)&&Q.jsx(Bb,{$theme:M,children:Q.jsxs("div",{className:"gallery-grid",style:{direction:"rtl"},children:[Ce.map((le,ie)=>{var me;return Q.jsx("div",{className:"gallery-item",style:{background:"#f5f6fa",display:"flex",alignItems:"center",justifyContent:"center"},children:Q.jsx("div",{className:"animate-spin",style:{width:24,height:24,border:"2px solid #d1d5db",borderTopColor:((me=M.colors)==null?void 0:me.primary)||"#3b82f6",borderRadius:"9999px"}})},`pending-img-${ie}`)}),be.map(le=>Q.jsxs("div",{className:"gallery-item",onClick:()=>{Z(le.url||le.filePath||null),N==null||N("reference_file:click",{file:le.name,file_type:"image",url:le.url||le.filePath,parse_url:le.parseUrl||le.convertedFilePath,retrieve_tags:le.retrieveTags||[],file_id:le.uid,parsed_file_type:"image",references:le,type:"image",isUploadFile:!0,pdfPages:le.pdfPages||0})},children:[Q.jsx("img",{src:le.url||le.filePath,alt:le.name,className:"gallery-image",onError:ie=>{const me=ie.target;me.style.display="none"}}),Q.jsx("div",{className:"gallery-overlay",children:le.name})]},le.uid||le.name))]})}),(de.length>0||Se.length>0)&&Q.jsxs("div",{className:"w-full",children:[Q.jsxs("div",{className:"text-sm font-semibold text-gray-700 mb-3 px-4",children:["\u4E0A\u4F20\u6587\u6863 (",de.length,")"]}),Q.jsxs("div",{className:"flex flex-col gap-2 px-4",style:{direction:"ltr"},children:[Se.map((le,ie)=>{var me;return Q.jsxs("div",{className:"flex items-center gap-3 p-3 rounded-lg border border-gray-200 bg-gray-50/40",children:[Q.jsx("div",{className:"flex-shrink-0 w-6 h-6 rounded bg-gray-200"}),Q.jsx("div",{className:"flex-1 min-w-0",children:Q.jsx("div",{className:"h-3 rounded bg-gray-200 w-[60%]"})}),Q.jsx("div",{className:"w-6 h-6",children:Q.jsx("div",{className:"animate-spin",style:{width:18,height:18,border:"2px solid #d1d5db",borderTopColor:((me=M.colors)==null?void 0:me.primary)||"#3b82f6",borderRadius:"9999px"}})})]},`pending-doc-${ie}`)}),de.map(le=>{const ie=(le.name||"").split(".").pop()||"";return Q.jsxs("div",{className:"flex items-center gap-3 p-3 rounded-lg border border-gray-200 hover:border-blue-300 hover:bg-gray-50 transition-colors cursor-pointer",onClick:()=>{N==null||N("reference_file:click",{file:le.name,file_type:ie,url:le.url||le.filePath,parse_url:le.parseUrl||le.convertedFilePath,retrieve_tags:le.retrieveTags||[],file_id:le.uid,parsed_file_type:ie,references:le,type:"file",isUploadFile:!0,pdfPages:le.pdfPages||0})},children:[Q.jsx("div",{className:"flex-shrink-0",children:Q.jsx("div",{className:"w-6 h-6 rounded flex items-center justify-center ",children:Q.jsx(Pl,{type:$b(ie),size:16})})}),Q.jsx("div",{className:"flex-1 min-w-0",children:Q.jsx("div",{className:"text-sm font-medium text-gray-900 truncate hover:text-blue-600 cursor-pointer",onClick:me=>{me.stopPropagation(),N==null||N("referenceFile_question",{data:{...le,file_type:ie,file_name:le.name,metadata:le,parsedFilePath:le.url||le.filePath}})},children:le.name})}),le.size&&Q.jsx("div",{className:"text-sm text-gray-600",children:le.size})]},le.uid||le.name)})]})]})]})},ct=()=>{if(i)return null;const ae=Array.isArray(it)?it:[],he=Array.isArray(Ue)?Ue:[],xe=Array.isArray(nt)?nt:[],be=ae.length>0&&B!==5,Ce=he.length>0,de=xe.length>0,Se=((pt==null?void 0:pt.length)||0)>0||((St==null?void 0:St.length)||0)>0,le=se&&se.length>0;return!be&&!Ce&&!de&&!Se&&!le?null:Q.jsxs(Q.Fragment,{children:[Se&&Q.jsx(Bb,{$theme:M,children:Q.jsx("div",{className:"gallery-grid",children:[...pt,...St].map((ie,me)=>Q.jsxs("div",{className:"gallery-item",onClick:()=>{Z(ie),N==null||N("reference_file:click",{file:`\u56FE${me+1}`,file_type:"image",url:ie,parse_url:ie,retrieve_tags:[],references:{url:ie},type:"image",isUploadFile:!1})},children:[Q.jsx("img",{src:ie,alt:`\u56FE${me+1}`,className:"gallery-image",onError:ze=>{const _e=ze.target;_e.style.display="none"}}),Q.jsxs("div",{className:"gallery-overlay",children:["\u56FE",me+1]})]},ie+me))})}),be&&Q.jsxs(rs,{$theme:M,children:[Q.jsx("div",{className:"reference-title justify-between items-center flex",children:Q.jsxs("div",{className:"flex items-center gap-2",children:[Q.jsx("span",{className:"text-[#374151]",children:"\u77E5\u8BC6\u5E93\u6587\u6863\u5F15\u7528"}),Q.jsx("span",{className:"text-[#b4b4b4] text-xs",children:` (${ae.length})`}),ae.length>2&&Q.jsx("div",{onClick:()=>z(!te),className:"cursor-pointer hover:text-[#86909C] transition-colors",children:te?Q.jsx(ts,{size:16,className:"text-[#b4b4b4]"}):Q.jsx(es,{size:16,className:"text-[#b4b4b4]"})})]})}),Q.jsx("div",{className:"reference-list",children:(te?ae:ae.slice(0,2)).map((ie,me)=>ie&&Q.jsx("div",{className:"reference-item",children:Q.jsxs("div",{className:"file-info flex items-end gap-2",children:[Q.jsx("div",{className:"flex-shrink-0",children:(()=>{(ie.file_name||"").split(".").pop();const ze=(ie.file_name||"").split(".").pop()||"file";return Q.jsx("div",{className:"w-6 h-6 rounded flex items-end-safe justify-center",children:Q.jsx(Pl,{type:$b(ze),size:32})})})()}),Q.jsx("div",{className:"flex-1 min-w-0",children:Q.jsx("div",{className:"text-sm w-[250px] font-medium text-gray-900 truncate hover:text-blue-600 cursor-pointer",onClick:ze=>{ze.stopPropagation(),N==null||N("knowledge_referenceFile_title:click",{data:{...ie,file_type:ie.file_type,file_name:ie.file_name,metadata:ie.metadata,parsedFilePath:ie.parsedFilePath}})},children:ie.file_name})}),Q.jsx("div",{className:"flex items-center gap-1",children:(()=>{const ze=new Set,_e=(ie.tags||[]).filter(Pe=>ze.has(Pe.id)?!1:(ze.add(Pe.id),!0)).sort((Pe,Ze)=>Number(Pe.index)-Number(Ze.index)),Ke=Pe=>{if(typeof Fe!="string")return Pe;const Ze=new RegExp(`\\[retrive-tag[^\\]]*id=['"]${Pe}['"][^\\]]*\\]\\[([^\\]]+)\\]\\[\\/retrive-tag\\]`,"g").exec(Fe);return Ze?Ze[1]:Pe};return _e.slice(0,10).map(Pe=>Q.jsx("span",{className:"w-6 h-6 bg-[#e6f7ff] text-[#1890ff] rounded text-xs font-medium flex items-center justify-center cursor-pointer hover:bg-orange-200 transition-colors",onClick:Ze=>{Ze.stopPropagation();const wt=ye(ie,Pe.id);N==null||N("retrive_tag:click",{tagInfo:wt||ie,fromtype:"0",leaf:{id:Pe.id,fromtype:"0"},attributes:{}})},children:Ke(Pe.id)},Pe.id))})()}),Q.jsxs("div",{className:"text-sm text-gray-600",children:["\u5206\u6570: ",(ie.score*100).toFixed(0)]}),Q.jsx("div",{className:"flex items-center gap-2",children:Q.jsx(j9,{size:16,className:"text-gray-400 hover:text-blue-600 transition-colors",style:{cursor:e?"pointer":"not-allowed"},onClick:ze=>{e&&(ze.stopPropagation(),N==null||N("referenceFile_download",{data:{...ie,file_type:ie.file_type,file_name:ie.file_name,metadata:ie.metadata,parsedFilePath:ie.parsedFilePath}}))}})})]})},ie.file_id||me))})]}),le&&Q.jsxs(rs,{$theme:M,children:[Q.jsx("div",{className:"reference-title justify-between items-center flex",children:Q.jsxs("div",{className:"flex items-center gap-2",children:[Q.jsx("span",{className:"text-[#374151]",children:"\u6570\u636E\u5E93\u5F15\u7528"}),Q.jsx("span",{className:"text-[#b4b4b4] text-xs",children:` (${se.length||0})`}),se.length>2&&Q.jsx("div",{onClick:()=>K(!U),className:"cursor-pointer hover:text-[#86909C] transition-colors",children:U?Q.jsx(ts,{size:16,className:"text-[#b4b4b4]"}):Q.jsx(es,{size:16,className:"text-[#b4b4b4]"})})]})}),Q.jsx("div",{className:"reference-list",children:(U?se:se.slice(0,2)).map((ie,me)=>Q.jsx("div",{className:"reference-item",children:Q.jsxs("div",{className:"file-info flex items-end gap-2",children:[Q.jsx("div",{className:"flex-shrink-0",children:Q.jsx("div",{className:"w-6 h-6 rounded flex items-center justify-center",children:Q.jsx(P9,{size:20,className:"text-blue-600"})})}),Q.jsx("div",{className:"flex-1 min-w-0",children:Q.jsx("div",{className:"text-sm w-[250px] font-medium text-gray-900 truncate hover:text-blue-600 cursor-pointer",onClick:ze=>{ze.stopPropagation(),N==null||N("database_referenceFile_title:click",{data:{...ie,file_type:"database",file_name:ht(ie),metadata:ie,parsedFilePath:ie.fetchUrl||(dt==null?void 0:dt.dataFetchUrl)||""}})},children:ht(ie)})}),Q.jsx("div",{className:"flex items-center gap-1",children:Q.jsx("span",{className:"w-6 h-6 bg-orange-100 text-orange-600 rounded text-xs font-medium flex items-center justify-center cursor-pointer hover:bg-orange-200 transition-colors",children:me+1})})]})},ie.tableName||me))})]}),Ce&&Q.jsxs(rs,{$theme:M,children:[Q.jsx("div",{className:"reference-title justify-between items-center flex",children:Q.jsxs("div",{className:"flex items-center gap-2",children:[Q.jsx("span",{className:"text-[#374151]",children:"\u4E92\u8054\u7F51\u641C\u7D22\u5F15\u7528"}),Q.jsx("span",{className:"text-[#b4b4b4] text-xs",children:` (${he.length})`}),he.length>2&&Q.jsx("div",{onClick:()=>V(!Y),className:"cursor-pointer hover:text-[#86909C] transition-colors",children:Y?Q.jsx(ts,{size:16,className:"text-[#b4b4b4]"}):Q.jsx(es,{size:16,className:"text-[#b4b4b4]"})})]})}),Q.jsx("div",{className:"reference-list",children:(Y?he:he.slice(0,2)).map((ie,me)=>Q.jsx("div",{className:"reference-item",children:Q.jsxs("div",{className:"file-info flex items-end gap-2",children:[Q.jsx("div",{className:"flex-shrink-0",children:Q.jsx("div",{className:"w-6 h-6 rounded-full flex items-center justify-center",children:Q.jsx(Pl,{type:"rag/netretrive",size:32,className:"text-green-600"})})}),Q.jsx("div",{className:"flex-1 min-w-0",children:Q.jsx("div",{className:"text-sm w-[250px] font-medium text-gray-900 truncate hover:text-blue-600 cursor-pointer",onClick:ze=>{ze.stopPropagation(),N==null||N("web_referenceFile_title:click",{data:{...ie,file_type:ie.file_type,file_name:ie.file_name,metadata:ie.metadata,parsedFilePath:ie.parsedFilePath}})},children:ie.file_name})}),Q.jsx("div",{className:"flex items-center gap-1",children:(()=>{const ze=new Set,_e=(ie.tags||[]).filter(Pe=>ze.has(Pe.id)?!1:(ze.add(Pe.id),!0)).sort((Pe,Ze)=>Number(Pe.index)-Number(Ze.index)),Ke=Pe=>{if(typeof Fe!="string")return Pe;const Ze=new RegExp(`\\[retrive-tag[^\\]]*id=['"]${Pe}['"][^\\]]*\\]\\[([^\\]]+)\\]\\[\\/retrive-tag\\]`,"g").exec(Fe);return Ze?Ze[1]:Pe};return _e.slice(0,1).map(Pe=>Q.jsx("span",{className:"w-6 h-6 bg-[#f6ffed] text-[#52c41a] rounded text-xs font-medium flex items-center justify-center cursor-pointer hover:bg-orange-200 transition-colors",onClick:Ze=>{Ze.stopPropagation();const wt=ye(ie,Pe.id);N==null||N("retrive_tag:click",{tagInfo:wt||ie,fromtype:"1",leaf:{id:Pe.id,fromtype:"1"},attributes:{}})},children:Ke(Pe.id)},Pe.id))})()}),Q.jsxs("div",{className:"text-sm text-gray-600",children:["\u5206\u6570: ",ie.score?(ie.score*100).toFixed(0):"N/A"]})]})},(ie.link||"")+me))})]}),de&&Q.jsxs(rs,{$theme:M,children:[Q.jsx("div",{className:"reference-title justify-between items-center flex",children:Q.jsxs("div",{className:"flex items-center gap-2",children:[Q.jsx("span",{className:"text-[#374151]",children:"\u56FE\u8C31\u5F15\u7528"}),Q.jsx("span",{className:"text-[#b4b4b4] text-xs",children:` (${xe.length})`}),xe.length>2&&Q.jsx("div",{onClick:()=>re(!W),className:"cursor-pointer hover:text-[#86909C] transition-colors",children:W?Q.jsx(ts,{size:16,className:"text-[#b4b4b4]"}):Q.jsx(es,{size:16,className:"text-[#b4b4b4]"})})]})}),Q.jsx("div",{className:"reference-list",children:(W?xe:xe.slice(0,2)).map((ie,me)=>Q.jsx("div",{className:"reference-item",children:Q.jsxs("div",{className:"file-info flex items-end gap-2",children:[Q.jsx("div",{className:"flex-shrink-0",children:Q.jsx("div",{className:"w-6 h-6 rounded flex items-center justify-center",children:Q.jsx("div",{className:"w-6 h-6 bg-purple-100 text-purple-600 rounded text-xs font-medium flex items-center justify-center",children:"\u56FE"})})}),Q.jsx("div",{className:"flex-1 min-w-0",children:Q.jsx("div",{className:"text-sm w-[250px] font-medium text-gray-900 truncate hover:text-purple-600 cursor-pointer",onClick:ze=>{ze.stopPropagation(),N==null||N("graph_reference:click",{graphId:ie.id,graphName:ie.graphName})},children:ie.graphName||`\u56FE\u8C31${me+1}`})}),Q.jsx("div",{className:"flex items-center gap-1",children:(()=>{const ze=new Set,_e=(ie.tags||[]).filter(Pe=>ze.has(Pe.id)?!1:(ze.add(Pe.id),!0)).sort((Pe,Ze)=>Number(Pe.index)-Number(Ze.index)),Ke=Pe=>{if(typeof Fe!="string")return Pe;const Ze=new RegExp(`\\[retrive-tag[^\\]]*id=['"]${Pe}['"][^\\]]*\\]\\[([^\\]]+)\\]\\[\\/retrive-tag\\]`,"g").exec(Fe);return Ze?Ze[1]:Pe};return _e.slice(0,10).map(Pe=>Q.jsx("span",{className:"w-6 h-6 bg-purple-100 text-purple-600 rounded text-xs font-medium flex items-center justify-center cursor-pointer hover:bg-purple-200 transition-colors",onClick:Ze=>{Ze.stopPropagation(),N==null||N("retrive_tag:click",{tagInfo:{id:Pe.id,index:Pe.index,image_urls:Pe.image_urls||[]}})},children:Ke(Pe.id)},Pe.id))})()})]})},ie.id||me))})]})]})},ut=()=>i||!$||!S||S.length===0?null:Q.jsx(G9,{$theme:M,children:Q.jsx("div",{className:"follow-up-list",children:S.map((ae,he)=>Q.jsx("div",{className:"follow-up-item",style:{animationDelay:`${he*260}ms`},onClick:()=>{N==null||N("chatbox:follow_up_question_click",{question:ae,queryId:x})},children:ae},`${String(ae)}-${he}`))})});return Q.jsxs(H9,{$align:n,$isUser:i,children:[Q.jsxs(W9,{$isUser:i,children:[Q.jsx(K9,{$src:Ye,$isUser:i}),_&&Q.jsx("div",{className:"message-time px-2 text-sm text-[#888888]",children:_})]}),Q.jsx(q9,{$isUser:i,$theme:M,children:Q.jsx("div",{className:"message-card",children:Q.jsx("div",{className:"message-text",children:r==="stream"?Q.jsxs(Q.Fragment,{children:[!i&&oe(),Q.jsx(Fm,{dataSource:{type:tu.MARKDOWN,content:Fe},styles:{letterSpacing:v==null?void 0:v.letterSpacing,lineHeight:v==null?void 0:v.lineHeight,templateField:v==null?void 0:v.templateField,text:v==null?void 0:v.text},theme:{...v==null?void 0:v.theme,baseFontSize:16,minHeight:"60px"},onRetriveTagClick:ke,eventsEmit:N,extraProps:We},`md-${(Fe||"").length}-think-${G}`)]}):Q.jsx("div",{children:Ve})})})}),At(),ct(),!i&&Te(),ut(),typeof document<"u"&&Pb(Q.jsx(X9,{$show:q!==null,onClick:()=>Z(null),children:q&&Q.jsxs("div",{className:"modal-content",onClick:ae=>ae.stopPropagation(),children:[Q.jsx("img",{src:q,alt:"\u9884\u89C8\u56FE\u7247",className:"modal-image"}),Q.jsx("button",{className:"modal-close",onClick:()=>Z(null),children:"\u5173\u95ED"})]})}),document.body)]})},U9=fr.div`
|
|
1076
|
+
position: relative;
|
|
1077
|
+
width: 100%;
|
|
1078
|
+
height: 100%;
|
|
1079
|
+
overflow: ${e=>e.$isVirtualized?"hidden":"auto"};
|
|
1080
|
+
background-color: ${e=>{var t;return((t=e.theme)==null?void 0:t.backgroundColor)||"#ffffff"}};
|
|
1081
|
+
border-radius: ${e=>{var t;return((t=e.theme)==null?void 0:t.borderRadius)||"8px"}};
|
|
1082
|
+
|
|
1083
|
+
/* 自定义滚动条 */
|
|
1084
|
+
&::-webkit-scrollbar {
|
|
1085
|
+
width: 8px;
|
|
1086
|
+
}
|
|
1087
|
+
|
|
1088
|
+
&::-webkit-scrollbar-track {
|
|
1089
|
+
background: ${e=>{var t;return((t=e.theme)==null?void 0:t.scrollbarTrack)||"#f1f1f1"}};
|
|
1090
|
+
border-radius: 4px;
|
|
1091
|
+
}
|
|
1092
|
+
|
|
1093
|
+
&::-webkit-scrollbar-thumb {
|
|
1094
|
+
background: ${e=>{var t;return((t=e.theme)==null?void 0:t.scrollbarThumb)||"#c1c1c1"}};
|
|
1095
|
+
border-radius: 4px;
|
|
1096
|
+
|
|
1097
|
+
&:hover {
|
|
1098
|
+
background: ${e=>{var t;return((t=e.theme)==null?void 0:t.scrollbarThumbHover)||"#a8a8a8"}};
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
`,Y9=fr.div`
|
|
1102
|
+
position: relative;
|
|
1103
|
+
width: 100%;
|
|
1104
|
+
height: 100%;
|
|
1105
|
+
overflow: auto;
|
|
1106
|
+
background-color: ${e=>{var t;return((t=e.theme)==null?void 0:t.backgroundColor)||"#ffffff"}};
|
|
1107
|
+
|
|
1108
|
+
/* 自定义滚动条 */
|
|
1109
|
+
&::-webkit-scrollbar {
|
|
1110
|
+
width: 8px;
|
|
1111
|
+
}
|
|
1112
|
+
|
|
1113
|
+
&::-webkit-scrollbar-track {
|
|
1114
|
+
background: ${e=>{var t;return((t=e.theme)==null?void 0:t.scrollbarTrack)||"#f1f1f1"}};
|
|
1115
|
+
border-radius: 4px;
|
|
1116
|
+
}
|
|
1117
|
+
|
|
1118
|
+
&::-webkit-scrollbar-thumb {
|
|
1119
|
+
background: ${e=>{var t;return((t=e.theme)==null?void 0:t.scrollbarThumb)||"#c1c1c1"}};
|
|
1120
|
+
border-radius: 4px;
|
|
1121
|
+
|
|
1122
|
+
&:hover {
|
|
1123
|
+
background: ${e=>{var t;return((t=e.theme)==null?void 0:t.scrollbarThumbHover)||"#a8a8a8"}};
|
|
1124
|
+
}
|
|
1125
|
+
}
|
|
1126
|
+
`,Ob=fr.div`
|
|
1127
|
+
padding: ${e=>{var t;return((t=e.theme)==null?void 0:t.padding)||"1rem"}};
|
|
1128
|
+
min-height: ${e=>e.height||"auto"};
|
|
1129
|
+
|
|
1130
|
+
/* 富文本内容样式增强 */
|
|
1131
|
+
& h1, & h2, & h3, & h4, & h5, & h6 {
|
|
1132
|
+
scroll-margin-top: 2rem;
|
|
1133
|
+
}
|
|
1134
|
+
|
|
1135
|
+
& img {
|
|
1136
|
+
max-width: 100%;
|
|
1137
|
+
height: auto;
|
|
1138
|
+
border-radius: 0.5rem;
|
|
1139
|
+
margin: 1rem 0;
|
|
1140
|
+
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
|
1141
|
+
transition: transform 0.2s ease-in-out;
|
|
1142
|
+
|
|
1143
|
+
&:hover {
|
|
1144
|
+
transform: scale(1.02);
|
|
1145
|
+
}
|
|
1146
|
+
}
|
|
1147
|
+
|
|
1148
|
+
& pre {
|
|
1149
|
+
position: relative;
|
|
1150
|
+
|
|
1151
|
+
&::before {
|
|
1152
|
+
content: '';
|
|
1153
|
+
position: absolute;
|
|
1154
|
+
top: 0;
|
|
1155
|
+
left: 0;
|
|
1156
|
+
right: 0;
|
|
1157
|
+
height: 2px;
|
|
1158
|
+
background: linear-gradient(90deg, #007bff, #28a745, #ffc107, #dc3545);
|
|
1159
|
+
border-radius: 2px 2px 0 0;
|
|
1160
|
+
}
|
|
1161
|
+
}
|
|
1162
|
+
|
|
1163
|
+
& blockquote {
|
|
1164
|
+
position: relative;
|
|
1165
|
+
|
|
1166
|
+
&::before {
|
|
1167
|
+
content: '"';
|
|
1168
|
+
position: absolute;
|
|
1169
|
+
top: -0.5rem;
|
|
1170
|
+
left: -1rem;
|
|
1171
|
+
font-size: 3rem;
|
|
1172
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.primaryColor)||"#007bff"}};
|
|
1173
|
+
opacity: 0.3;
|
|
1174
|
+
}
|
|
1175
|
+
}
|
|
1176
|
+
|
|
1177
|
+
|
|
1178
|
+
`,Z9=fr.div`
|
|
1179
|
+
display: flex;
|
|
1180
|
+
align-items: center;
|
|
1181
|
+
justify-content: center;
|
|
1182
|
+
padding: 2rem;
|
|
1183
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#6c757d"}};
|
|
1184
|
+
font-size: 0.875rem;
|
|
1185
|
+
|
|
1186
|
+
&::before {
|
|
1187
|
+
content: '';
|
|
1188
|
+
width: 20px;
|
|
1189
|
+
height: 20px;
|
|
1190
|
+
border: 2px solid ${e=>{var t;return((t=e.theme)==null?void 0:t.borderColor)||"#dee2e6"}};
|
|
1191
|
+
border-top: 2px solid ${e=>{var t;return((t=e.theme)==null?void 0:t.primaryColor)||"#007bff"}};
|
|
1192
|
+
border-radius: 50%;
|
|
1193
|
+
animation: spin 1s linear infinite;
|
|
1194
|
+
margin-right: 0.5rem;
|
|
1195
|
+
}
|
|
1196
|
+
|
|
1197
|
+
@keyframes spin {
|
|
1198
|
+
0% { transform: rotate(0deg); }
|
|
1199
|
+
100% { transform: rotate(360deg); }
|
|
1200
|
+
}
|
|
1201
|
+
`,J9=fr.div`
|
|
1202
|
+
display: flex;
|
|
1203
|
+
flex-direction: column;
|
|
1204
|
+
align-items: center;
|
|
1205
|
+
justify-content: center;
|
|
1206
|
+
padding: 3rem;
|
|
1207
|
+
color: ${e=>{var t;return((t=e.theme)==null?void 0:t.textColor)||"#6c757d"}};
|
|
1208
|
+
text-align: center;
|
|
1209
|
+
|
|
1210
|
+
&::before {
|
|
1211
|
+
content: '📄';
|
|
1212
|
+
font-size: 3rem;
|
|
1213
|
+
margin-bottom: 1rem;
|
|
1214
|
+
}
|
|
1215
|
+
`,Q9=({dataSource:e,enableVirtualScroll:t=!1,itemHeight:r=200,preloadCount:n=5,enableSegmentedLoading:o=!1,onLoadMore:a,isLoadingMore:i=!1,size:l="sm",theme:s={},onChange:u,onScroll:c,onScrollToTop:f,onScrollToBottom:p,onSegmentClick:h,className:v,style:g,height:m="100%"})=>{const b=ru(),y=xt(()=>{var U,K,W,re,G,J,oe,se,ge;return{primaryColor:((U=b==null?void 0:b.colors)==null?void 0:U.primary)||(s==null?void 0:s.primaryColor)||"#007bff",secondaryColor:((K=b==null?void 0:b.colors)==null?void 0:K.secondary)||(s==null?void 0:s.secondaryColor)||"#6c757d",backgroundColor:((W=b==null?void 0:b.colors)==null?void 0:W.background)||(s==null?void 0:s.backgroundColor)||"#ffffff",textColor:((re=b==null?void 0:b.colors)==null?void 0:re.text)||(s==null?void 0:s.textColor)||"#24292f",borderColor:((G=b==null?void 0:b.colors)==null?void 0:G.border)||(s==null?void 0:s.borderColor)||"#dee2e6",disabledBackground:((J=b==null?void 0:b.colors)==null?void 0:J.disabledBackground)||(s==null?void 0:s.disabledBackground)||"#f8f9fa",hoverBackground:((oe=b==null?void 0:b.colors)==null?void 0:oe.hoverBackground)||(s==null?void 0:s.hoverBackground)||"#e9ecef",borderRadius:((se=b==null?void 0:b.space)==null?void 0:se.radius)||(s==null?void 0:s.borderRadius)||"8px",padding:((ge=b==null?void 0:b.space)==null?void 0:ge.padding)||(s==null?void 0:s.padding)||"1rem",scrollbarTrack:(s==null?void 0:s.scrollbarTrack)||"#f1f1f1",scrollbarThumb:(s==null?void 0:s.scrollbarThumb)||"#c1c1c1",scrollbarThumbHover:(s==null?void 0:s.scrollbarThumbHover)||"#a8a8a8",...s}},[b,s]),C=qe(0);C.current+=1,console.log("[Markdownit] render count:",C.current);const[D,w]=yt([]),[k,E]=yt({start:0,end:10}),[x,O]=yt(0),[j,$]=yt(0),[P,A]=yt(!1),[B,S]=yt(!1),[I,N]=yt(!1),F=qe(null),M=qe(null),_=qe(null),X=xt(()=>Array.isArray(e)?e:[{id:"single",content:e.content,type:e.type,timestamp:Date.now()}],[e]);Ot(()=>{console.log("[Markdownit] setSegments by processedData, len:",Array.isArray(X)?X.length:"n/a"),w(X)},[X]);const H=xt(()=>t?`${D.length*r}px`:"auto",[D.length,r,t]),q=xt(()=>{if(!t)return D;const U=Math.max(0,k.start-n),K=Math.min(D.length,k.end+n);return D.slice(U,K).map((W,re)=>({...W,virtualIndex:U+re}))},[D,k,t,n]),Z=mt(U=>{const{scrollTop:K,scrollHeight:W,clientHeight:re}=U.currentTarget;console.log("[Markdownit] onScroll fired",{newScrollTop:K,scrollHeight:W,clientHeight:re});const G=!t&&!c&&!f&&!p&&!o;if(console.log("[Markdownit] passiveOnly:",G),G||O(J=>J!==K?(console.log("[Markdownit] setScrollTop:",K),K):J),t&&!G){const J=Math.floor(K/r),oe=Math.min(D.length,J+Math.ceil(j/r)+1);E(se=>se.start!==J||se.end!==oe?(console.log("[Markdownit] setVisibleRange:",{start:J,end:oe}),{start:J,end:oe}):se)}if(!G){const J=K<=10;J!==B&&(console.log("[Markdownit] isAtTop ->",J),S(J),J&&f&&(console.log("[Markdownit] onScrollToTop callback"),f()))}if(!G){const J=K+re>=W-10;J!==I&&(console.log("[Markdownit] isAtBottom ->",J),N(J),J&&p&&(console.log("[Markdownit] onScrollToBottom callback"),p()))}c&&(console.log("[Markdownit] onScroll callback ->",{newScrollTop:K,scrollHeight:W}),c(K,W)),o&&a&&!P&&!i&&W-K-j<100&&te()},[t,r,D.length,j,o,a,P,i,B,I,f,p,c]),te=mt(async()=>{if(!(!a||P||i)){A(!0);try{const U=D[D.length-1],K=await a(U.id);w(W=>[...W,...K])}catch(U){console.error("Failed to load more segments:",U)}finally{A(!1)}}},[a,D,P,i]);Ot(()=>{const U=()=>{F.current&&$(F.current.clientHeight)};return U(),window.addEventListener("resize",U),()=>window.removeEventListener("resize",U)},[]);const z=mt((U,K)=>{const W={type:U.type,content:U.content},re=t?{position:"absolute",top:`${(U.virtualIndex||K)*r}px`,left:0,right:0,height:`${r}px`}:{};return Q.jsx("div",{style:re,onClick:()=>h==null?void 0:h(U.id,U),className:h?"cursor-pointer hover:bg-gray-50":"",children:Q.jsx(Fm,{dataSource:W,isEditing:!1,size:l,theme:y,onChange:u,style:{border:"none",background:"transparent",minHeight:t?`${r}px`:"auto",padding:"0.5rem"}})},U.id)},[t,r,y,u,h]),Y=()=>(console.log("[Markdownit] renderContent segments.len:",D.length,"enableVirtualScroll:",t),D.length===0?Q.jsxs(J9,{theme:y,children:[Q.jsx("h3",{children:"\u6682\u65E0\u5185\u5BB9"}),Q.jsx("p",{children:"\u8BF7\u6DFB\u52A0\u4E00\u4E9B\u5185\u5BB9\u6765\u5F00\u59CB"})]}):t?Q.jsx("div",{ref:_,style:{height:H,position:"relative"},children:q.map(z)}):Q.jsx("div",{ref:_,children:D.map(z)})),V=()=>!P&&!i?null:Q.jsx(Z9,{theme:y,children:i?"\u52A0\u8F7D\u66F4\u591A\u5185\u5BB9...":"\u52A0\u8F7D\u4E2D..."});return Q.jsx(U9,{ref:F,theme:y,$isVirtualized:t,className:v,style:{height:m,...g},children:t?Q.jsx(Y9,{ref:M,theme:y,onScroll:Z,children:Q.jsx(Ob,{theme:y,height:H,children:Y()})}):Q.jsxs(Ob,{theme:y,onScroll:Z,children:[Y(),V()]})})},sz=e=>{const{onRendered:t}=e;return Ot(()=>{if(!t)return;const r=requestAnimationFrame(()=>{const n=document.querySelector('[data-markdownit-root="1"]');n&&(console.log("[Markdownit _onRendered] fired"),t(n))});return()=>cancelAnimationFrame(r)},[e.dataSource,e.enableVirtualScroll,t]),Q.jsx("div",{"data-markdownit-root":"1",children:Q.jsx(Q9,{...e})})};fr.div`
|
|
1216
|
+
background: #f6f8fa;
|
|
1217
|
+
border: 1px solid #d0d7de;
|
|
1218
|
+
border-radius: 6px;
|
|
1219
|
+
padding: 16px;
|
|
1220
|
+
margin-bottom: 20px;
|
|
1221
|
+
`;fr.p`
|
|
1222
|
+
margin: 0 0 16px 0;
|
|
1223
|
+
color: #656d76;
|
|
1224
|
+
font-size: 14px;
|
|
1225
|
+
line-height: 1.5;
|
|
1226
|
+
`;const Ab=e=>{if(!e||e.trim()==="")return[{type:"paragraph",children:[{text:""}]}];const t=/<template\b([^>]*)>([\s\S]*?)<\/template>/g,r=[];let n=0,o,a=0;for(console.log("\u5F00\u59CB\u89E3\u6790\u6A21\u677F\u5B57\u7B26\u4E32:",e);(o=t.exec(e))!==null;){const i=o[0],l=o[1]||"",s=(o[2]||"").trim(),u=o.index,c=u+i.length;if(u>n){const b=e.slice(n,u);b.trim()!==""&&(r.push({text:b}),console.log("\u6DFB\u52A0\u6587\u672C\u5143\u7D20:",{text:b}))}const f=b=>{const y=new RegExp(`${b}\\s*=\\s*(["'])((?:\\\\.|[^\\
|
|
1227
|
+
])*?)\\1`,"i"),C=l.match(y);return C?C[2]:void 0},p=/\S/.test(l),h=f("key"),v=f("placeholder"),g=h||`template-${Date.now()}-${a++}`,m={type:"template",key:g,placeholder:p?v||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9":s||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9",value:p?s:"",style:"blue",fieldId:g,children:[{text:""}],inline:!0};r.push(m),console.log("\u6DFB\u52A0template\u5143\u7D20:",m),n=c}if(n<e.length){const i=e.slice(n);i.trim()!==""&&(r.push({text:i}),console.log("\u6DFB\u52A0\u6700\u540E\u6587\u672C\u5143\u7D20:",{text:i}))}return r.length===0&&(e.trim()===""?r.push({text:""}):r.push({text:e}),console.log("\u6CA1\u6709\u627E\u5230template\u6807\u7B7E\uFF0C\u8FD4\u56DE\u539F\u59CB\u6587\u672C")),r.length>0&&r[0].type!=="paragraph"?[{type:"paragraph",children:r}]:(console.log("\u89E3\u6790\u5B8C\u6210\uFF0C\u7ED3\u679C:",r),r)},sd=e=>{if(!e||e.length===0)return"";const t=e[0];if(!t.children)return t.text||"";let r="",n="";return console.log("\u8F6C\u6362Slate\u6570\u636E:",JSON.stringify(e,null,2)),t.children.forEach(o=>{if(console.log("\u5904\u7406\u5B50\u5143\u7D20:",o),o.type==="template"){const a=o.key||o.fieldId||"",i=o.placeholder||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9",l=o.value||"",s=` key="${String(a)}" placeholder="${String(i)}"`;r+=`<template${s}>${l}</template>`,n=l||i}else if(o.text!==void 0){const a=o.text||"";a.trim()!==""?a!==n?(console.log(`\u627E\u5230\u6587\u672C\u5143\u7D20: ${a}`),r+=a,n=a):console.log("\u8DF3\u8FC7\u91CD\u590D\u6587\u672C\u5143\u7D20"):console.log("\u8DF3\u8FC7\u7A7A\u6587\u672C\u5143\u7D20")}else{console.log("\u672A\u77E5\u5143\u7D20\u7C7B\u578B:",o);const a=o.text||"";a.trim()!==""&&a!==n&&(r+=a,n=a)}}),console.log("\u8F6C\u6362\u7ED3\u679C:",r),r},ez=e=>{if(!e||e.length===0)return"";const t=e[0];if(!t.children)return t.text||"";let r="";return t.children.forEach(n=>{n.text!==void 0?r+=n.text:n.type==="template"&&(r+=n.value||n.placeholder||"")}),r},tz=e=>{if(!e||e.length===0)return"";const t=e[0];if(!t.children)return t.text||"";let r="";return t.children.forEach(n=>{n.text!==void 0?r+=n.text:n.type==="template"&&(r+=`\`\`\`template\`\`\`
|
|
1228
|
+
${n.value||n.placeholder}\`\`\`
|
|
1229
|
+
\`\`\`
|
|
1230
|
+
`)}),r},rz=e=>{if(!e||e.length===0)return"";const t=e[0];if(!t.children)return t.text||"";let r="";return t.children.forEach(n=>{if(n.text!==void 0)r+=n.text;else if(n.type==="template"){const o=n.key||n.fieldId||"",a=n.placeholder||"\u6A21\u7248\u5B57\u7B26\u5185\u5BB9",i=n.value||"",l=` key="${String(o)}" placeholder="${String(a)}"`;r+=`<template${l}>${i}</template>`}}),r},uz=({data:e,onChange:t,size:r="sm",styles:n={},onGetData:o})=>{var h,v,g,m,b,y,C,D,w,k,E,x,O,j,$,P,A,B,S,I,N,F,M,_,X,H,q,Z,te,z,Y,V,U,K,W,re,G,J,oe,se,ge,Ee,je,ve,ye,ke,we,De,Ne,Oe,Xe,Le;const a=ru(),i={theme:{colors:{primary:((h=a==null?void 0:a.colors)==null?void 0:h.primary)||"#055AFF",secondary:((v=a==null?void 0:a.colors)==null?void 0:v.secondary)||"#84ADFF",background:((g=a==null?void 0:a.colors)==null?void 0:g.background)||"#E5EEFF",text:((m=a==null?void 0:a.colors)==null?void 0:m.text)||"#055AFF",border:((b=a==null?void 0:a.colors)==null?void 0:b.border)||"#84ADFF",success:((y=a==null?void 0:a.colors)==null?void 0:y.success)||"#008000",warning:((C=a==null?void 0:a.colors)==null?void 0:C.warning)||"#FFA500",error:((D=a==null?void 0:a.colors)==null?void 0:D.error)||"#FF0000",info:((w=a==null?void 0:a.colors)==null?void 0:w.info)||"#0000FF",disabled:((k=a==null?void 0:a.colors)==null?void 0:k.disabled)||"#808080",disabledBackground:((E=a==null?void 0:a.colors)==null?void 0:E.disabledBackground)||"#F5F5F5",disabledText:((x=a==null?void 0:a.colors)==null?void 0:x.disabledText)||"#808080",shadow:((O=a==null?void 0:a.colors)==null?void 0:O.shadow)||"0 1px 3px rgba(0, 0, 0, 0.12)",appBackground:((j=a==null?void 0:a.colors)==null?void 0:j.appBackground)||"transparent",listBackground:(($=a==null?void 0:a.colors)==null?void 0:$.listBackground)||"#f9f9f9",dashboardBackground:((P=a==null?void 0:a.colors)==null?void 0:P.dashboardBackground)||"#ffffff",textSecondary:((A=a==null?void 0:a.colors)==null?void 0:A.textSecondary)||"#6b7280"},space:{sidebar:((B=a==null?void 0:a.space)==null?void 0:B.sidebar)||"260px",size:((S=a==null?void 0:a.space)==null?void 0:S.size)||"12px",radius:((I=a==null?void 0:a.space)==null?void 0:I.radius)||"6px",padding:((N=a==null?void 0:a.space)==null?void 0:N.padding)||"16px",margin:((F=a==null?void 0:a.space)==null?void 0:F.margin)||"20px",shadow:((M=a==null?void 0:a.space)==null?void 0:M.shadow)||"0 2px 8px rgba(0,0,0,0.1)",lineHeight:((_=a==null?void 0:a.space)==null?void 0:_.lineHeight)||"1.6"},icons:(a==null?void 0:a.icons)||{},fonts:{body:{size:((H=(X=a==null?void 0:a.fonts)==null?void 0:X.body)==null?void 0:H.size)||"14px",weight:((Z=(q=a==null?void 0:a.fonts)==null?void 0:q.body)==null?void 0:Z.weight)||"normal",family:((z=(te=a==null?void 0:a.fonts)==null?void 0:te.body)==null?void 0:z.family)||"PingFang SC, Microsoft YaHei, Arial, sans-serif"},heading:{size:((V=(Y=a==null?void 0:a.fonts)==null?void 0:Y.heading)==null?void 0:V.size)||"16px",weight:((K=(U=a==null?void 0:a.fonts)==null?void 0:U.heading)==null?void 0:K.weight)||"600",family:((re=(W=a==null?void 0:a.fonts)==null?void 0:W.heading)==null?void 0:re.family)||"PingFang SC, Microsoft YaHei, Arial, sans-serif"}},others:{baseFontWeight:((G=a==null?void 0:a.others)==null?void 0:G.baseFontWeight)||"normal"}},mode:(a==null?void 0:a.mode)||"light"},l={backgroundColor:((J=a==null?void 0:a.colors)==null?void 0:J.background)||"#E5EEFF",borderColor:((oe=a==null?void 0:a.colors)==null?void 0:oe.border)||"#84ADFF",borderRadius:((se=a==null?void 0:a.space)==null?void 0:se.radius)||"6px",padding:((ge=a==null?void 0:a.space)==null?void 0:ge.padding)||"8px 12px",margin:"2px",fontSize:((je=(Ee=a==null?void 0:a.fonts)==null?void 0:Ee.body)==null?void 0:je.size)||"14px",fontWeight:((ye=(ve=a==null?void 0:a.fonts)==null?void 0:ve.body)==null?void 0:ye.weight)||"500",minWidth:"30px",textColor:((ke=a==null?void 0:a.colors)==null?void 0:ke.text)||"#84ADFF"},s={...i,...n,theme:{...i.theme,...n==null?void 0:n.theme,colors:{...(we=i.theme)==null?void 0:we.colors,...(De=n==null?void 0:n.theme)==null?void 0:De.colors},space:{...(Ne=i.theme)==null?void 0:Ne.space,...(Oe=n==null?void 0:n.theme)==null?void 0:Oe.space},fonts:{...(Xe=i.theme)==null?void 0:Xe.fonts,...(Le=n==null?void 0:n.theme)==null?void 0:Le.fonts}},templateField:{...l,...n==null?void 0:n.templateField}},[u,c]=yt(()=>Ab(e));Ot(()=>{console.log("\u6570\u636E\u53D8\u5316\uFF0C\u540C\u6B65\u5230\u5185\u90E8\u72B6\u6001:",e);const Fe=Ab(e);console.log("\u65B0\u7684Slate\u6570\u636E:",Fe),c(Fe)},[e]),Ot(()=>{console.log("slateData \u72B6\u6001\u53D8\u5316:",u)},[u]);const f=mt((Fe,fe)=>{if(fe===tu.SLATE&&Fe){console.log("\u7F16\u8F91\u5668\u5185\u5BB9\u53D8\u5316:",Fe),c(Fe);const Be=sd(Fe);console.log("\u8F6C\u6362\u540E\u7684\u6A21\u677F\u5B57\u7B26\u4E32:",Be),t==null||t(Be)}},[t]),p=mt(Fe=>{if(!u||u.length===0)return"";switch(Fe){case"pure_string":return ez(u);case"string":return sd(u);case"markdown":return tz(u);case"html":return rz(u);default:return sd(u)}},[u]);return Ot(()=>{o==null||o(p)},[p,o]),Q.jsx(Fm,{dataSource:{type:tu.SLATE,content:u},isEditing:!0,placeholder:"\u5F00\u59CB\u7F16\u8F91\u6A21\u7248...",onChange:f,size:"md",styles:s,enableTemplateInput:!0})};export{lz as A,sz as I,uz as T,tu as x};
|