@chamn/engine
Version:
81 lines (71 loc) • 2.63 MB
JavaScript
"use strict";var Ace=Object.defineProperty;var Rce=(e,t,n)=>t in e?Ace(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var He=(e,t,n)=>Rce(e,typeof t!="symbol"?t+"":t,n);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const M=require("react"),To=require("react-dom"),Me=require("antd"),yt=require("@chamn/model"),Co=require("@chamn/layout");function Pce(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const We=Pce(M);function Nl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function kW(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}var Iy={exports:{}},Gf={};/**
* @license React
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/var BI;function Mce(){if(BI)return Gf;BI=1;var e=M,t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function o(a,l,d){var h,f={},u=null,c=null;d!==void 0&&(u=""+d),l.key!==void 0&&(u=""+l.key),l.ref!==void 0&&(c=l.ref);for(h in l)r.call(l,h)&&!s.hasOwnProperty(h)&&(f[h]=l[h]);if(a&&a.defaultProps)for(h in l=a.defaultProps,l)f[h]===void 0&&(f[h]=l[h]);return{$$typeof:t,type:a,key:u,ref:c,props:f,_owner:i.current}}return Gf.Fragment=n,Gf.jsx=o,Gf.jsxs=o,Gf}var Jf={},zI;function jce(){if(zI)return Jf;zI=1;/**
* @license React
* react-jsx-runtime.development.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/return"{}".NODE_ENV!=="production"&&function(){var e=M,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),h=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),u=Symbol.for("react.lazy"),c=Symbol.for("react.offscreen"),p=Symbol.iterator,m="@@iterator";function g(be){if(be===null||typeof be!="object")return null;var Ge=p&&be[p]||be[m];return typeof Ge=="function"?Ge:null}var y=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function v(be){{for(var Ge=arguments.length,Qe=new Array(Ge>1?Ge-1:0),at=1;at<Ge;at++)Qe[at-1]=arguments[at];w("error",be,Qe)}}function w(be,Ge,Qe){{var at=y.ReactDebugCurrentFrame,bt=at.getStackAddendum();bt!==""&&(Ge+="%s",Qe=Qe.concat([bt]));var Pt=Qe.map(function(_t){return String(_t)});Pt.unshift("Warning: "+Ge),Function.prototype.apply.call(console[be],console,Pt)}}var b=!1,_=!1,N=!1,O=!1,T=!1,E;E=Symbol.for("react.module.reference");function L(be){return!!(typeof be=="string"||typeof be=="function"||be===r||be===s||T||be===i||be===d||be===h||O||be===c||b||_||N||typeof be=="object"&&be!==null&&(be.$$typeof===u||be.$$typeof===f||be.$$typeof===o||be.$$typeof===a||be.$$typeof===l||be.$$typeof===E||be.getModuleId!==void 0))}function P(be,Ge,Qe){var at=be.displayName;if(at)return at;var bt=Ge.displayName||Ge.name||"";return bt!==""?Qe+"("+bt+")":Qe}function U(be){return be.displayName||"Context"}function k(be){if(be==null)return null;if(typeof be.tag=="number"&&v("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof be=="function")return be.displayName||be.name||null;if(typeof be=="string")return be;switch(be){case r:return"Fragment";case n:return"Portal";case s:return"Profiler";case i:return"StrictMode";case d:return"Suspense";case h:return"SuspenseList"}if(typeof be=="object")switch(be.$$typeof){case a:var Ge=be;return U(Ge)+".Consumer";case o:var Qe=be;return U(Qe._context)+".Provider";case l:return P(be,be.render,"ForwardRef");case f:var at=be.displayName||null;return at!==null?at:k(be.type)||"Memo";case u:{var bt=be,Pt=bt._payload,_t=bt._init;try{return k(_t(Pt))}catch{return null}}}return null}var C=Object.assign,A=0,R,I,V,G,F,W,$;function D(){}D.__reactDisabledLog=!0;function H(){{if(A===0){R=console.log,I=console.info,V=console.warn,G=console.error,F=console.group,W=console.groupCollapsed,$=console.groupEnd;var be={configurable:!0,enumerable:!0,value:D,writable:!0};Object.defineProperties(console,{info:be,log:be,warn:be,error:be,group:be,groupCollapsed:be,groupEnd:be})}A++}}function B(){{if(A--,A===0){var be={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:C({},be,{value:R}),info:C({},be,{value:I}),warn:C({},be,{value:V}),error:C({},be,{value:G}),group:C({},be,{value:F}),groupCollapsed:C({},be,{value:W}),groupEnd:C({},be,{value:$})})}A<0&&v("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var X=y.ReactCurrentDispatcher,ee;function te(be,Ge,Qe){{if(ee===void 0)try{throw Error()}catch(bt){var at=bt.stack.trim().match(/\n( *(at )?)/);ee=at&&at[1]||""}return`
`+ee+be}}var ie=!1,me;{var Ce=typeof WeakMap=="function"?WeakMap:Map;me=new Ce}function he(be,Ge){if(!be||ie)return"";{var Qe=me.get(be);if(Qe!==void 0)return Qe}var at;ie=!0;var bt=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var Pt;Pt=X.current,X.current=null,H();try{if(Ge){var _t=function(){throw Error()};if(Object.defineProperty(_t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(_t,[])}catch(xi){at=xi}Reflect.construct(be,[],_t)}else{try{_t.call()}catch(xi){at=xi}be.call(_t.prototype)}}else{try{throw Error()}catch(xi){at=xi}be()}}catch(xi){if(xi&&at&&typeof xi.stack=="string"){for(var Nt=xi.stack.split(`
`),pn=at.stack.split(`
`),Yt=Nt.length-1,On=pn.length-1;Yt>=1&&On>=0&&Nt[Yt]!==pn[On];)On--;for(;Yt>=1&&On>=0;Yt--,On--)if(Nt[Yt]!==pn[On]){if(Yt!==1||On!==1)do if(Yt--,On--,On<0||Nt[Yt]!==pn[On]){var kr=`
`+Nt[Yt].replace(" at new "," at ");return be.displayName&&kr.includes("<anonymous>")&&(kr=kr.replace("<anonymous>",be.displayName)),typeof be=="function"&&me.set(be,kr),kr}while(Yt>=1&&On>=0);break}}}finally{ie=!1,X.current=Pt,B(),Error.prepareStackTrace=bt}var hr=be?be.displayName||be.name:"",co=hr?te(hr):"";return typeof be=="function"&&me.set(be,co),co}function se(be,Ge,Qe){return he(be,!1)}function ue(be){var Ge=be.prototype;return!!(Ge&&Ge.isReactComponent)}function oe(be,Ge,Qe){if(be==null)return"";if(typeof be=="function")return he(be,ue(be));if(typeof be=="string")return te(be);switch(be){case d:return te("Suspense");case h:return te("SuspenseList")}if(typeof be=="object")switch(be.$$typeof){case l:return se(be.render);case f:return oe(be.type,Ge,Qe);case u:{var at=be,bt=at._payload,Pt=at._init;try{return oe(Pt(bt),Ge,Qe)}catch{}}}return""}var _e=Object.prototype.hasOwnProperty,Se={},Re=y.ReactDebugCurrentFrame;function ge(be){if(be){var Ge=be._owner,Qe=oe(be.type,be._source,Ge?Ge.type:null);Re.setExtraStackFrame(Qe)}else Re.setExtraStackFrame(null)}function Pe(be,Ge,Qe,at,bt){{var Pt=Function.call.bind(_e);for(var _t in be)if(Pt(be,_t)){var Nt=void 0;try{if(typeof be[_t]!="function"){var pn=Error((at||"React class")+": "+Qe+" type `"+_t+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof be[_t]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw pn.name="Invariant Violation",pn}Nt=be[_t](Ge,_t,at,Qe,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(Yt){Nt=Yt}Nt&&!(Nt instanceof Error)&&(ge(bt),v("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",at||"React class",Qe,_t,typeof Nt),ge(null)),Nt instanceof Error&&!(Nt.message in Se)&&(Se[Nt.message]=!0,ge(bt),v("Failed %s type: %s",Qe,Nt.message),ge(null))}}}var De=Array.isArray;function Ne(be){return De(be)}function Je(be){{var Ge=typeof Symbol=="function"&&Symbol.toStringTag,Qe=Ge&&be[Symbol.toStringTag]||be.constructor.name||"Object";return Qe}}function rt(be){try{return ve(be),!1}catch{return!0}}function ve(be){return""+be}function Ee(be){if(rt(be))return v("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Je(be)),ve(be)}var Z=y.ReactCurrentOwner,q={key:!0,ref:!0,__self:!0,__source:!0},K,de;function Q(be){if(_e.call(be,"ref")){var Ge=Object.getOwnPropertyDescriptor(be,"ref").get;if(Ge&&Ge.isReactWarning)return!1}return be.ref!==void 0}function ye(be){if(_e.call(be,"key")){var Ge=Object.getOwnPropertyDescriptor(be,"key").get;if(Ge&&Ge.isReactWarning)return!1}return be.key!==void 0}function xe(be,Ge){typeof be.ref=="string"&&Z.current}function Ue(be,Ge){{var Qe=function(){K||(K=!0,v("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",Ge))};Qe.isReactWarning=!0,Object.defineProperty(be,"key",{get:Qe,configurable:!0})}}function ke(be,Ge){{var Qe=function(){de||(de=!0,v("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",Ge))};Qe.isReactWarning=!0,Object.defineProperty(be,"ref",{get:Qe,configurable:!0})}}var ze=function(be,Ge,Qe,at,bt,Pt,_t){var Nt={$$typeof:t,type:be,key:Ge,ref:Qe,props:_t,_owner:Pt};return Nt._store={},Object.defineProperty(Nt._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(Nt,"_self",{configurable:!1,enumerable:!1,writable:!1,value:at}),Object.defineProperty(Nt,"_source",{configurable:!1,enumerable:!1,writable:!1,value:bt}),Object.freeze&&(Object.freeze(Nt.props),Object.freeze(Nt)),Nt};function ne(be,Ge,Qe,at,bt){{var Pt,_t={},Nt=null,pn=null;Qe!==void 0&&(Ee(Qe),Nt=""+Qe),ye(Ge)&&(Ee(Ge.key),Nt=""+Ge.key),Q(Ge)&&(pn=Ge.ref,xe(Ge,bt));for(Pt in Ge)_e.call(Ge,Pt)&&!q.hasOwnProperty(Pt)&&(_t[Pt]=Ge[Pt]);if(be&&be.defaultProps){var Yt=be.defaultProps;for(Pt in Yt)_t[Pt]===void 0&&(_t[Pt]=Yt[Pt])}if(Nt||pn){var On=typeof be=="function"?be.displayName||be.name||"Unknown":be;Nt&&Ue(_t,On),pn&&ke(_t,On)}return ze(be,Nt,pn,bt,at,Z.current,_t)}}var Ae=y.ReactCurrentOwner,$e=y.ReactDebugCurrentFrame;function J(be){if(be){var Ge=be._owner,Qe=oe(be.type,be._source,Ge?Ge.type:null);$e.setExtraStackFrame(Qe)}else $e.setExtraStackFrame(null)}var Le;Le=!1;function je(be){return typeof be=="object"&&be!==null&&be.$$typeof===t}function ae(){{if(Ae.current){var be=k(Ae.current.type);if(be)return`
Check the render method of \``+be+"`."}return""}}function we(be){return""}var Ie={};function nt(be){{var Ge=ae();if(!Ge){var Qe=typeof be=="string"?be:be.displayName||be.name;Qe&&(Ge=`
Check the top-level render call using <`+Qe+">.")}return Ge}}function le(be,Ge){{if(!be._store||be._store.validated||be.key!=null)return;be._store.validated=!0;var Qe=nt(Ge);if(Ie[Qe])return;Ie[Qe]=!0;var at="";be&&be._owner&&be._owner!==Ae.current&&(at=" It was passed a child from "+k(be._owner.type)+"."),J(be),v('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',Qe,at),J(null)}}function fe(be,Ge){{if(typeof be!="object")return;if(Ne(be))for(var Qe=0;Qe<be.length;Qe++){var at=be[Qe];je(at)&&le(at,Ge)}else if(je(be))be._store&&(be._store.validated=!0);else if(be){var bt=g(be);if(typeof bt=="function"&&bt!==be.entries)for(var Pt=bt.call(be),_t;!(_t=Pt.next()).done;)je(_t.value)&&le(_t.value,Ge)}}}function Ve(be){{var Ge=be.type;if(Ge==null||typeof Ge=="string")return;var Qe;if(typeof Ge=="function")Qe=Ge.propTypes;else if(typeof Ge=="object"&&(Ge.$$typeof===l||Ge.$$typeof===f))Qe=Ge.propTypes;else return;if(Qe){var at=k(Ge);Pe(Qe,be.props,"prop",at,be)}else if(Ge.PropTypes!==void 0&&!Le){Le=!0;var bt=k(Ge);v("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",bt||"Unknown")}typeof Ge.getDefaultProps=="function"&&!Ge.getDefaultProps.isReactClassApproved&&v("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Xe(be){{for(var Ge=Object.keys(be.props),Qe=0;Qe<Ge.length;Qe++){var at=Ge[Qe];if(at!=="children"&&at!=="key"){J(be),v("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",at),J(null);break}}be.ref!==null&&(J(be),v("Invalid attribute `ref` supplied to `React.Fragment`."),J(null))}}function et(be,Ge,Qe,at,bt,Pt){{var _t=L(be);if(!_t){var Nt="";(be===void 0||typeof be=="object"&&be!==null&&Object.keys(be).length===0)&&(Nt+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var pn=we();pn?Nt+=pn:Nt+=ae();var Yt;be===null?Yt="null":Ne(be)?Yt="array":be!==void 0&&be.$$typeof===t?(Yt="<"+(k(be.type)||"Unknown")+" />",Nt=" Did you accidentally export a JSX literal instead of a component?"):Yt=typeof be,v("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Yt,Nt)}var On=ne(be,Ge,Qe,bt,Pt);if(On==null)return On;if(_t){var kr=Ge.children;if(kr!==void 0)if(at)if(Ne(kr)){for(var hr=0;hr<kr.length;hr++)fe(kr[hr],be);Object.freeze&&Object.freeze(kr)}else v("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else fe(kr,be)}return be===r?Xe(On):Ve(On),On}}function dt(be,Ge,Qe){return et(be,Ge,Qe,!0)}function ft(be,Ge,Qe){return et(be,Ge,Qe,!1)}var ln=ft,Qt=dt;Jf.Fragment=r,Jf.jsx=ln,Jf.jsxs=Qt}(),Jf}var UI;function Ice(){return UI||(UI=1,"{}".NODE_ENV==="production"?Iy.exports=Mce():Iy.exports=jce()),Iy.exports}var z=Ice(),pr=function(){return pr=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},pr.apply(this,arguments)},qI={width:"100%",height:"10px",top:"0px",left:"0px",cursor:"row-resize"},VI={width:"10px",height:"100%",top:"0px",left:"0px",cursor:"col-resize"},Fy={width:"20px",height:"20px",position:"absolute",zIndex:1},Fce={top:pr(pr({},qI),{top:"-5px"}),right:pr(pr({},VI),{left:void 0,right:"-5px"}),bottom:pr(pr({},qI),{top:void 0,bottom:"-5px"}),left:pr(pr({},VI),{left:"-5px"}),topRight:pr(pr({},Fy),{right:"-10px",top:"-10px",cursor:"ne-resize"}),bottomRight:pr(pr({},Fy),{right:"-10px",bottom:"-10px",cursor:"se-resize"}),bottomLeft:pr(pr({},Fy),{left:"-10px",bottom:"-10px",cursor:"sw-resize"}),topLeft:pr(pr({},Fy),{left:"-10px",top:"-10px",cursor:"nw-resize"})},Dce=M.memo(function(e){var t=e.onResizeStart,n=e.direction,r=e.children,i=e.replaceStyles,s=e.className,o=M.useCallback(function(d){t(d,n)},[t,n]),a=M.useCallback(function(d){t(d,n)},[t,n]),l=M.useMemo(function(){return pr(pr({position:"absolute",userSelect:"none"},Fce[n]),i??{})},[i,n]);return z.jsx("div",{className:s||void 0,style:l,onMouseDown:o,onTouchStart:a,children:r})}),Bce=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&(r[s]=i[s])},e(t,n)};return function(t,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function r(){this.constructor=t}t.prototype=n===null?Object.create(n):(r.prototype=n.prototype,new r)}}(),vo=function(){return vo=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},vo.apply(this,arguments)},zce={width:"auto",height:"auto"},Dy=function(e,t,n){return Math.max(Math.min(e,n),t)},HI=function(e,t,n){var r=Math.round(e/t);return r*t+n*(r-1)},kc=function(e,t){return new RegExp(e,"i").test(t)},By=function(e){return!!(e.touches&&e.touches.length)},Uce=function(e){return!!((e.clientX||e.clientX===0)&&(e.clientY||e.clientY===0))},WI=function(e,t,n){n===void 0&&(n=0);var r=t.reduce(function(s,o,a){return Math.abs(o-e)<Math.abs(t[s]-e)?a:s},0),i=Math.abs(t[r]-e);return n===0||i<n?t[r]:e},j1=function(e){return e=e.toString(),e==="auto"||e.endsWith("px")||e.endsWith("%")||e.endsWith("vh")||e.endsWith("vw")||e.endsWith("vmax")||e.endsWith("vmin")?e:"".concat(e,"px")},zy=function(e,t,n,r){if(e&&typeof e=="string"){if(e.endsWith("px"))return Number(e.replace("px",""));if(e.endsWith("%")){var i=Number(e.replace("%",""))/100;return t*i}if(e.endsWith("vw")){var i=Number(e.replace("vw",""))/100;return n*i}if(e.endsWith("vh")){var i=Number(e.replace("vh",""))/100;return r*i}}return e},qce=function(e,t,n,r,i,s,o){return r=zy(r,e.width,t,n),i=zy(i,e.height,t,n),s=zy(s,e.width,t,n),o=zy(o,e.height,t,n),{maxWidth:typeof r>"u"?void 0:Number(r),maxHeight:typeof i>"u"?void 0:Number(i),minWidth:typeof s>"u"?void 0:Number(s),minHeight:typeof o>"u"?void 0:Number(o)}},Vce=function(e){return Array.isArray(e)?e:[e,e]},Hce=["as","ref","style","className","grid","gridGap","snap","bounds","boundsByDirection","size","defaultSize","minWidth","minHeight","maxWidth","maxHeight","lockAspectRatio","lockAspectRatioExtraWidth","lockAspectRatioExtraHeight","enable","handleStyles","handleClasses","handleWrapperStyle","handleWrapperClass","children","onResizeStart","onResize","onResizeStop","handleComponent","scale","resizeRatio","snapGap"],GI="__resizable_base__",JI=function(e){Bce(t,e);function t(n){var r,i,s,o,a=e.call(this,n)||this;return a.ratio=1,a.resizable=null,a.parentLeft=0,a.parentTop=0,a.resizableLeft=0,a.resizableRight=0,a.resizableTop=0,a.resizableBottom=0,a.targetLeft=0,a.targetTop=0,a.delta={width:0,height:0},a.appendBase=function(){if(!a.resizable||!a.window)return null;var l=a.parentNode;if(!l)return null;var d=a.window.document.createElement("div");return d.style.width="100%",d.style.height="100%",d.style.position="absolute",d.style.transform="scale(0, 0)",d.style.left="0",d.style.flex="0 0 100%",d.classList?d.classList.add(GI):d.className+=GI,l.appendChild(d),d},a.removeBase=function(l){var d=a.parentNode;d&&d.removeChild(l)},a.state={isResizing:!1,width:(i=(r=a.propsSize)===null||r===void 0?void 0:r.width)!==null&&i!==void 0?i:"auto",height:(o=(s=a.propsSize)===null||s===void 0?void 0:s.height)!==null&&o!==void 0?o:"auto",direction:"right",original:{x:0,y:0,width:0,height:0},backgroundStyle:{height:"100%",width:"100%",backgroundColor:"rgba(0,0,0,0)",cursor:"auto",opacity:0,position:"fixed",zIndex:9999,top:"0",left:"0",bottom:"0",right:"0"},flexBasis:void 0},a.onResizeStart=a.onResizeStart.bind(a),a.onMouseMove=a.onMouseMove.bind(a),a.onMouseUp=a.onMouseUp.bind(a),a}return Object.defineProperty(t.prototype,"parentNode",{get:function(){return this.resizable?this.resizable.parentNode:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"window",{get:function(){return!this.resizable||!this.resizable.ownerDocument?null:this.resizable.ownerDocument.defaultView},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"propsSize",{get:function(){return this.props.size||this.props.defaultSize||zce},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"size",{get:function(){var n=0,r=0;if(this.resizable&&this.window){var i=this.resizable.offsetWidth,s=this.resizable.offsetHeight,o=this.resizable.style.position;o!=="relative"&&(this.resizable.style.position="relative"),n=this.resizable.style.width!=="auto"?this.resizable.offsetWidth:i,r=this.resizable.style.height!=="auto"?this.resizable.offsetHeight:s,this.resizable.style.position=o}return{width:n,height:r}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"sizeStyle",{get:function(){var n=this,r=this.props.size,i=function(a){var l;if(typeof n.state[a]>"u"||n.state[a]==="auto")return"auto";if(n.propsSize&&n.propsSize[a]&&(!((l=n.propsSize[a])===null||l===void 0)&&l.toString().endsWith("%"))){if(n.state[a].toString().endsWith("%"))return n.state[a].toString();var d=n.getParentSize(),h=Number(n.state[a].toString().replace("px","")),f=h/d[a]*100;return"".concat(f,"%")}return j1(n.state[a])},s=r&&typeof r.width<"u"&&!this.state.isResizing?j1(r.width):i("width"),o=r&&typeof r.height<"u"&&!this.state.isResizing?j1(r.height):i("height");return{width:s,height:o}},enumerable:!1,configurable:!0}),t.prototype.getParentSize=function(){if(!this.parentNode)return this.window?{width:this.window.innerWidth,height:this.window.innerHeight}:{width:0,height:0};var n=this.appendBase();if(!n)return{width:0,height:0};var r=!1,i=this.parentNode.style.flexWrap;i!=="wrap"&&(r=!0,this.parentNode.style.flexWrap="wrap"),n.style.position="relative",n.style.minWidth="100%",n.style.minHeight="100%";var s={width:n.offsetWidth,height:n.offsetHeight};return r&&(this.parentNode.style.flexWrap=i),this.removeBase(n),s},t.prototype.bindEvents=function(){this.window&&(this.window.addEventListener("mouseup",this.onMouseUp),this.window.addEventListener("mousemove",this.onMouseMove),this.window.addEventListener("mouseleave",this.onMouseUp),this.window.addEventListener("touchmove",this.onMouseMove,{capture:!0,passive:!1}),this.window.addEventListener("touchend",this.onMouseUp))},t.prototype.unbindEvents=function(){this.window&&(this.window.removeEventListener("mouseup",this.onMouseUp),this.window.removeEventListener("mousemove",this.onMouseMove),this.window.removeEventListener("mouseleave",this.onMouseUp),this.window.removeEventListener("touchmove",this.onMouseMove,!0),this.window.removeEventListener("touchend",this.onMouseUp))},t.prototype.componentDidMount=function(){if(!(!this.resizable||!this.window)){var n=this.window.getComputedStyle(this.resizable);this.setState({width:this.state.width||this.size.width,height:this.state.height||this.size.height,flexBasis:n.flexBasis!=="auto"?n.flexBasis:void 0})}},t.prototype.componentWillUnmount=function(){this.window&&this.unbindEvents()},t.prototype.createSizeForCssProperty=function(n,r){var i=this.propsSize&&this.propsSize[r];return this.state[r]==="auto"&&this.state.original[r]===n&&(typeof i>"u"||i==="auto")?"auto":n},t.prototype.calculateNewMaxFromBoundary=function(n,r){var i=this.props.boundsByDirection,s=this.state.direction,o=i&&kc("left",s),a=i&&kc("top",s),l,d;if(this.props.bounds==="parent"){var h=this.parentNode;h&&(l=o?this.resizableRight-this.parentLeft:h.offsetWidth+(this.parentLeft-this.resizableLeft),d=a?this.resizableBottom-this.parentTop:h.offsetHeight+(this.parentTop-this.resizableTop))}else this.props.bounds==="window"?this.window&&(l=o?this.resizableRight:this.window.innerWidth-this.resizableLeft,d=a?this.resizableBottom:this.window.innerHeight-this.resizableTop):this.props.bounds&&(l=o?this.resizableRight-this.targetLeft:this.props.bounds.offsetWidth+(this.targetLeft-this.resizableLeft),d=a?this.resizableBottom-this.targetTop:this.props.bounds.offsetHeight+(this.targetTop-this.resizableTop));return l&&Number.isFinite(l)&&(n=n&&n<l?n:l),d&&Number.isFinite(d)&&(r=r&&r<d?r:d),{maxWidth:n,maxHeight:r}},t.prototype.calculateNewSizeFromDirection=function(n,r){var i=this.props.scale||1,s=Vce(this.props.resizeRatio||1),o=s[0],a=s[1],l=this.state,d=l.direction,h=l.original,f=this.props,u=f.lockAspectRatio,c=f.lockAspectRatioExtraHeight,p=f.lockAspectRatioExtraWidth,m=h.width,g=h.height,y=c||0,v=p||0;return kc("right",d)&&(m=h.width+(n-h.x)*o/i,u&&(g=(m-v)/this.ratio+y)),kc("left",d)&&(m=h.width-(n-h.x)*o/i,u&&(g=(m-v)/this.ratio+y)),kc("bottom",d)&&(g=h.height+(r-h.y)*a/i,u&&(m=(g-y)*this.ratio+v)),kc("top",d)&&(g=h.height-(r-h.y)*a/i,u&&(m=(g-y)*this.ratio+v)),{newWidth:m,newHeight:g}},t.prototype.calculateNewSizeFromAspectRatio=function(n,r,i,s){var o=this.props,a=o.lockAspectRatio,l=o.lockAspectRatioExtraHeight,d=o.lockAspectRatioExtraWidth,h=typeof s.width>"u"?10:s.width,f=typeof i.width>"u"||i.width<0?n:i.width,u=typeof s.height>"u"?10:s.height,c=typeof i.height>"u"||i.height<0?r:i.height,p=l||0,m=d||0;if(a){var g=(u-p)*this.ratio+m,y=(c-p)*this.ratio+m,v=(h-m)/this.ratio+p,w=(f-m)/this.ratio+p,b=Math.max(h,g),_=Math.min(f,y),N=Math.max(u,v),O=Math.min(c,w);n=Dy(n,b,_),r=Dy(r,N,O)}else n=Dy(n,h,f),r=Dy(r,u,c);return{newWidth:n,newHeight:r}},t.prototype.setBoundingClientRect=function(){var n=1/(this.props.scale||1);if(this.props.bounds==="parent"){var r=this.parentNode;if(r){var i=r.getBoundingClientRect();this.parentLeft=i.left*n,this.parentTop=i.top*n}}if(this.props.bounds&&typeof this.props.bounds!="string"){var s=this.props.bounds.getBoundingClientRect();this.targetLeft=s.left*n,this.targetTop=s.top*n}if(this.resizable){var o=this.resizable.getBoundingClientRect(),a=o.left,l=o.top,d=o.right,h=o.bottom;this.resizableLeft=a*n,this.resizableRight=d*n,this.resizableTop=l*n,this.resizableBottom=h*n}},t.prototype.onResizeStart=function(n,r){if(!(!this.resizable||!this.window)){var i=0,s=0;if(n.nativeEvent&&Uce(n.nativeEvent)?(i=n.nativeEvent.clientX,s=n.nativeEvent.clientY):n.nativeEvent&&By(n.nativeEvent)&&(i=n.nativeEvent.touches[0].clientX,s=n.nativeEvent.touches[0].clientY),this.props.onResizeStart&&this.resizable){var o=this.props.onResizeStart(n,r,this.resizable);if(o===!1)return}this.props.size&&(typeof this.props.size.height<"u"&&this.props.size.height!==this.state.height&&this.setState({height:this.props.size.height}),typeof this.props.size.width<"u"&&this.props.size.width!==this.state.width&&this.setState({width:this.props.size.width})),this.ratio=typeof this.props.lockAspectRatio=="number"?this.props.lockAspectRatio:this.size.width/this.size.height;var a,l=this.window.getComputedStyle(this.resizable);if(l.flexBasis!=="auto"){var d=this.parentNode;if(d){var h=this.window.getComputedStyle(d).flexDirection;this.flexDir=h.startsWith("row")?"row":"column",a=l.flexBasis}}this.setBoundingClientRect(),this.bindEvents();var f={original:{x:i,y:s,width:this.size.width,height:this.size.height},isResizing:!0,backgroundStyle:vo(vo({},this.state.backgroundStyle),{cursor:this.window.getComputedStyle(n.target).cursor||"auto"}),direction:r,flexBasis:a};this.setState(f)}},t.prototype.onMouseMove=function(n){var r=this;if(!(!this.state.isResizing||!this.resizable||!this.window)){if(this.window.TouchEvent&&By(n))try{n.preventDefault(),n.stopPropagation()}catch{}var i=this.props,s=i.maxWidth,o=i.maxHeight,a=i.minWidth,l=i.minHeight,d=By(n)?n.touches[0].clientX:n.clientX,h=By(n)?n.touches[0].clientY:n.clientY,f=this.state,u=f.direction,c=f.original,p=f.width,m=f.height,g=this.getParentSize(),y=qce(g,this.window.innerWidth,this.window.innerHeight,s,o,a,l);s=y.maxWidth,o=y.maxHeight,a=y.minWidth,l=y.minHeight;var v=this.calculateNewSizeFromDirection(d,h),w=v.newHeight,b=v.newWidth,_=this.calculateNewMaxFromBoundary(s,o);this.props.snap&&this.props.snap.x&&(b=WI(b,this.props.snap.x,this.props.snapGap)),this.props.snap&&this.props.snap.y&&(w=WI(w,this.props.snap.y,this.props.snapGap));var N=this.calculateNewSizeFromAspectRatio(b,w,{width:_.maxWidth,height:_.maxHeight},{width:a,height:l});if(b=N.newWidth,w=N.newHeight,this.props.grid){var O=HI(b,this.props.grid[0],this.props.gridGap?this.props.gridGap[0]:0),T=HI(w,this.props.grid[1],this.props.gridGap?this.props.gridGap[1]:0),E=this.props.snapGap||0,L=E===0||Math.abs(O-b)<=E?O:b,P=E===0||Math.abs(T-w)<=E?T:w;b=L,w=P}var U={width:b-c.width,height:w-c.height};if(this.delta=U,p&&typeof p=="string"){if(p.endsWith("%")){var k=b/g.width*100;b="".concat(k,"%")}else if(p.endsWith("vw")){var C=b/this.window.innerWidth*100;b="".concat(C,"vw")}else if(p.endsWith("vh")){var A=b/this.window.innerHeight*100;b="".concat(A,"vh")}}if(m&&typeof m=="string"){if(m.endsWith("%")){var k=w/g.height*100;w="".concat(k,"%")}else if(m.endsWith("vw")){var C=w/this.window.innerWidth*100;w="".concat(C,"vw")}else if(m.endsWith("vh")){var A=w/this.window.innerHeight*100;w="".concat(A,"vh")}}var R={width:this.createSizeForCssProperty(b,"width"),height:this.createSizeForCssProperty(w,"height")};this.flexDir==="row"?R.flexBasis=R.width:this.flexDir==="column"&&(R.flexBasis=R.height);var I=this.state.width!==R.width,V=this.state.height!==R.height,G=this.state.flexBasis!==R.flexBasis,F=I||V||G;F&&To.flushSync(function(){r.setState(R)}),this.props.onResize&&F&&this.props.onResize(n,u,this.resizable,U)}},t.prototype.onMouseUp=function(n){var r,i,s=this.state,o=s.isResizing,a=s.direction;s.original,!(!o||!this.resizable)&&(this.props.onResizeStop&&this.props.onResizeStop(n,a,this.resizable,this.delta),this.props.size&&this.setState({width:(r=this.props.size.width)!==null&&r!==void 0?r:"auto",height:(i=this.props.size.height)!==null&&i!==void 0?i:"auto"}),this.unbindEvents(),this.setState({isResizing:!1,backgroundStyle:vo(vo({},this.state.backgroundStyle),{cursor:"auto"})}))},t.prototype.updateSize=function(n){var r,i;this.setState({width:(r=n.width)!==null&&r!==void 0?r:"auto",height:(i=n.height)!==null&&i!==void 0?i:"auto"})},t.prototype.renderResizer=function(){var n=this,r=this.props,i=r.enable,s=r.handleStyles,o=r.handleClasses,a=r.handleWrapperStyle,l=r.handleWrapperClass,d=r.handleComponent;if(!i)return null;var h=Object.keys(i).map(function(f){return i[f]!==!1?z.jsx(Dce,{direction:f,onResizeStart:n.onResizeStart,replaceStyles:s&&s[f],className:o&&o[f],children:d&&d[f]?d[f]:null},f):null});return z.jsx("div",{className:l,style:a,children:h})},t.prototype.render=function(){var n=this,r=Object.keys(this.props).reduce(function(o,a){return Hce.indexOf(a)!==-1||(o[a]=n.props[a]),o},{}),i=vo(vo(vo({position:"relative",userSelect:this.state.isResizing?"none":"auto"},this.props.style),this.sizeStyle),{maxWidth:this.props.maxWidth,maxHeight:this.props.maxHeight,minWidth:this.props.minWidth,minHeight:this.props.minHeight,boxSizing:"border-box",flexShrink:0});this.state.flexBasis&&(i.flexBasis=this.state.flexBasis);var s=this.props.as||"div";return z.jsxs(s,vo({style:i,className:this.props.className},r,{ref:function(o){o&&(n.resizable=o)},children:[this.state.isResizing&&z.jsx("div",{style:this.state.backgroundStyle}),this.props.children,this.renderResizer()]}))},t.defaultProps={as:"div",onResizeStart:function(){},onResize:function(){},onResizeStop:function(){},enable:{top:!0,right:!0,bottom:!0,left:!0,topRight:!0,bottomRight:!0,bottomLeft:!0,topLeft:!0},style:{},grid:[1,1],gridGap:[0,0],lockAspectRatio:!1,lockAspectRatioExtraWidth:0,lockAspectRatioExtraHeight:0,scale:1,resizeRatio:1,snapGap:0},t}(M.PureComponent);const Wce="_workbenchContainer_1z0k5_2",Gce="_topToolBarBox_1z0k5_9",Jce="_topToolBarView_1z0k5_15",Kce="_bodyContent_1z0k5_18",Xce="_leftBox_1z0k5_24",Yce="_pluginIconBar_1z0k5_31",Zce="_pluginIconItem_1z0k5_36",Qce="_active_1z0k5_46",$ce="_pluginPanelBoxResizeBox_1z0k5_62",ede="_pluginHeader_1z0k5_69",tde="_pluginNameText_1z0k5_77",nde="_closeBtn_1z0k5_84",rde="_fixedBtn_1z0k5_85",ide="_pluginPanelBox_1z0k5_62",sde="_hiddenLeftPanel_1z0k5_101",ode="_rightResizeBox_1z0k5_104",ade="_arrowCursor_1z0k5_108",lde="_rightBox_1z0k5_123",ude="_hiddenRightPanel_1z0k5_130",cde="_centerBox_1z0k5_134",dde="_subTopToolbarBox_1z0k5_141",fde="_canvasBox_1z0k5_146",hde="_scrollBox_1z0k5_153",pde="_canvasBoxPadding_1z0k5_157",mde="_customViewBox_1z0k5_161",En={workbenchContainer:Wce,topToolBarBox:Gce,topToolBarView:Jce,bodyContent:Kce,leftBox:Xce,pluginIconBar:Yce,pluginIconItem:Zce,active:Qce,pluginPanelBoxResizeBox:$ce,pluginHeader:ede,pluginNameText:tde,closeBtn:nde,fixedBtn:rde,pluginPanelBox:ide,hiddenLeftPanel:sde,rightResizeBox:ode,arrowCursor:ade,rightBox:lde,hiddenRightPanel:ude,centerBox:cde,subTopToolbarBox:dde,canvasBox:fde,scrollBox:hde,canvasBoxPadding:pde,customViewBox:mde};var NW=M.createContext({});function In(){return In=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},In.apply(null,arguments)}function EW(e){if(Array.isArray(e))return e}function gde(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,s,o,a=[],l=!0,d=!1;try{if(s=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=s.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(h){d=!0,i=h}finally{try{if(!l&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(d)throw i}}return a}}function CO(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function KA(e,t){if(e){if(typeof e=="string")return CO(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?CO(e,t):void 0}}function OW(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Gt(e,t){return EW(e)||gde(e,t)||KA(e,t)||OW()}function an(e){"@babel/helpers - typeof";return an=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},an(e)}function yde(e,t){if(an(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(an(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function LW(e){var t=yde(e,"string");return an(t)=="symbol"?t:t+""}function mt(e,t,n){return(t=LW(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vde(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function jd(e,t){if(e==null)return{};var n,r,i=vde(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)n=s[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}var I1={exports:{}};/*!
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
*/var KI;function bde(){return KI||(KI=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var s="",o=0;o<arguments.length;o++){var a=arguments[o];a&&(s=i(s,r(a)))}return s}function r(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return n.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var o="";for(var a in s)t.call(s,a)&&s[a]&&(o=i(o,a));return o}function i(s,o){return o?s?s+" "+o:s+o:s}e.exports?(n.default=n,e.exports=n):window.classNames=n})()}(I1)),I1.exports}var Sde=bde();const XA=Nl(Sde),Er=Math.round;function F1(e,t){const n=e.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],r=n.map(i=>parseFloat(i));for(let i=0;i<3;i+=1)r[i]=t(r[i]||0,n[i]||"",i);return n[3]?r[3]=n[3].includes("%")?r[3]/100:r[3]:r[3]=1,r}const XI=(e,t,n)=>n===0?e:e/100;function Kf(e,t){const n=t||255;return e>n?n:e<0?0:e}class sr{constructor(t){mt(this,"isValid",!0),mt(this,"r",0),mt(this,"g",0),mt(this,"b",0),mt(this,"a",1),mt(this,"_h",void 0),mt(this,"_s",void 0),mt(this,"_l",void 0),mt(this,"_v",void 0),mt(this,"_max",void 0),mt(this,"_min",void 0),mt(this,"_brightness",void 0);function n(r){return r[0]in t&&r[1]in t&&r[2]in t}if(t)if(typeof t=="string"){let i=function(s){return r.startsWith(s)};const r=t.trim();/^#?[A-F\d]{3,8}$/i.test(r)?this.fromHexString(r):i("rgb")?this.fromRgbString(r):i("hsl")?this.fromHslString(r):(i("hsv")||i("hsb"))&&this.fromHsvString(r)}else if(t instanceof sr)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(n("rgb"))this.r=Kf(t.r),this.g=Kf(t.g),this.b=Kf(t.b),this.a=typeof t.a=="number"?Kf(t.a,1):1;else if(n("hsl"))this.fromHsl(t);else if(n("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 n=this.toHsv();return n.h=t,this._c(n)}getLuminance(){function t(s){const o=s/255;return o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4)}const n=t(this.r),r=t(this.g),i=t(this.b);return .2126*n+.7152*r+.0722*i}getHue(){if(typeof this._h>"u"){const t=this.getMax()-this.getMin();t===0?this._h=0:this._h=Er(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 n=this.getHue(),r=this.getSaturation();let i=this.getLightness()-t/100;return i<0&&(i=0),this._c({h:n,s:r,l:i,a:this.a})}lighten(t=10){const n=this.getHue(),r=this.getSaturation();let i=this.getLightness()+t/100;return i>1&&(i=1),this._c({h:n,s:r,l:i,a:this.a})}mix(t,n=50){const r=this._c(t),i=n/100,s=a=>(r[a]-this[a])*i+this[a],o={r:Er(s("r")),g:Er(s("g")),b:Er(s("b")),a:Er(s("a")*100)/100};return this._c(o)}tint(t=10){return this.mix({r:255,g:255,b:255,a:1},t)}shade(t=10){return this.mix({r:0,g:0,b:0,a:1},t)}onBackground(t){const n=this._c(t),r=this.a+n.a*(1-this.a),i=s=>Er((this[s]*this.a+n[s]*n.a*(1-this.a))/r);return this._c({r:i("r"),g:i("g"),b:i("b"),a:r})}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 n=(this.r||0).toString(16);t+=n.length===2?n:"0"+n;const r=(this.g||0).toString(16);t+=r.length===2?r:"0"+r;const i=(this.b||0).toString(16);if(t+=i.length===2?i:"0"+i,typeof this.a=="number"&&this.a>=0&&this.a<1){const s=Er(this.a*255).toString(16);t+=s.length===2?s:"0"+s}return t}toHsl(){return{h:this.getHue(),s:this.getSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const t=this.getHue(),n=Er(this.getSaturation()*100),r=Er(this.getLightness()*100);return this.a!==1?`hsla(${t},${n}%,${r}%,${this.a})`:`hsl(${t},${n}%,${r}%)`}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,n,r){const i=this.clone();return i[t]=Kf(n,r),i}_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 n=t.replace("#","");function r(i,s){return parseInt(n[i]+n[s||i],16)}n.length<6?(this.r=r(0),this.g=r(1),this.b=r(2),this.a=n[3]?r(3)/255:1):(this.r=r(0,1),this.g=r(2,3),this.b=r(4,5),this.a=n[6]?r(6,7)/255:1)}fromHsl({h:t,s:n,l:r,a:i}){if(this._h=t%360,this._s=n,this._l=r,this.a=typeof i=="number"?i:1,n<=0){const u=Er(r*255);this.r=u,this.g=u,this.b=u}let s=0,o=0,a=0;const l=t/60,d=(1-Math.abs(2*r-1))*n,h=d*(1-Math.abs(l%2-1));l>=0&&l<1?(s=d,o=h):l>=1&&l<2?(s=h,o=d):l>=2&&l<3?(o=d,a=h):l>=3&&l<4?(o=h,a=d):l>=4&&l<5?(s=h,a=d):l>=5&&l<6&&(s=d,a=h);const f=r-d/2;this.r=Er((s+f)*255),this.g=Er((o+f)*255),this.b=Er((a+f)*255)}fromHsv({h:t,s:n,v:r,a:i}){this._h=t%360,this._s=n,this._v=r,this.a=typeof i=="number"?i:1;const s=Er(r*255);if(this.r=s,this.g=s,this.b=s,n<=0)return;const o=t/60,a=Math.floor(o),l=o-a,d=Er(r*(1-n)*255),h=Er(r*(1-n*l)*255),f=Er(r*(1-n*(1-l))*255);switch(a){case 0:this.g=f,this.b=d;break;case 1:this.r=h,this.b=d;break;case 2:this.r=d,this.b=f;break;case 3:this.r=d,this.g=h;break;case 4:this.r=f,this.g=d;break;case 5:default:this.g=d,this.b=h;break}}fromHsvString(t){const n=F1(t,XI);this.fromHsv({h:n[0],s:n[1],v:n[2],a:n[3]})}fromHslString(t){const n=F1(t,XI);this.fromHsl({h:n[0],s:n[1],l:n[2],a:n[3]})}fromRgbString(t){const n=F1(t,(r,i)=>i.includes("%")?Er(r/100*255):r);this.r=n[0],this.g=n[1],this.b=n[2],this.a=n[3]}}var Uy=2,YI=.16,wde=.05,Tde=.05,_de=.15,AW=5,RW=4,xde=[{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 ZI(e,t,n){var r;return Math.round(e.h)>=60&&Math.round(e.h)<=240?r=n?Math.round(e.h)-Uy*t:Math.round(e.h)+Uy*t:r=n?Math.round(e.h)+Uy*t:Math.round(e.h)-Uy*t,r<0?r+=360:r>=360&&(r-=360),r}function QI(e,t,n){if(e.h===0&&e.s===0)return e.s;var r;return n?r=e.s-YI*t:t===RW?r=e.s+YI:r=e.s+wde*t,r>1&&(r=1),n&&t===AW&&r>.1&&(r=.1),r<.06&&(r=.06),Math.round(r*100)/100}function $I(e,t,n){var r;return n?r=e.v+Tde*t:r=e.v-_de*t,r=Math.max(0,Math.min(1,r)),Math.round(r*100)/100}function mm(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=[],r=new sr(e),i=r.toHsv(),s=AW;s>0;s-=1){var o=new sr({h:ZI(i,s,!0),s:QI(i,s,!0),v:$I(i,s,!0)});n.push(o)}n.push(r);for(var a=1;a<=RW;a+=1){var l=new sr({h:ZI(i,a),s:QI(i,a),v:$I(i,a)});n.push(l)}return t.theme==="dark"?xde.map(function(d){var h=d.index,f=d.amount;return new sr(t.backgroundColor||"#141414").mix(n[h],f).toHexString()}):n.map(function(d){return d.toHexString()})}var D1={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"},kO=["#fff1f0","#ffccc7","#ffa39e","#ff7875","#ff4d4f","#f5222d","#cf1322","#a8071a","#820014","#5c0011"];kO.primary=kO[5];var NO=["#fff2e8","#ffd8bf","#ffbb96","#ff9c6e","#ff7a45","#fa541c","#d4380d","#ad2102","#871400","#610b00"];NO.primary=NO[5];var EO=["#fff7e6","#ffe7ba","#ffd591","#ffc069","#ffa940","#fa8c16","#d46b08","#ad4e00","#873800","#612500"];EO.primary=EO[5];var OO=["#fffbe6","#fff1b8","#ffe58f","#ffd666","#ffc53d","#faad14","#d48806","#ad6800","#874d00","#613400"];OO.primary=OO[5];var LO=["#feffe6","#ffffb8","#fffb8f","#fff566","#ffec3d","#fadb14","#d4b106","#ad8b00","#876800","#614700"];LO.primary=LO[5];var AO=["#fcffe6","#f4ffb8","#eaff8f","#d3f261","#bae637","#a0d911","#7cb305","#5b8c00","#3f6600","#254000"];AO.primary=AO[5];var RO=["#f6ffed","#d9f7be","#b7eb8f","#95de64","#73d13d","#52c41a","#389e0d","#237804","#135200","#092b00"];RO.primary=RO[5];var PO=["#e6fffb","#b5f5ec","#87e8de","#5cdbd3","#36cfc9","#13c2c2","#08979c","#006d75","#00474f","#002329"];PO.primary=PO[5];var Nb=["#e6f4ff","#bae0ff","#91caff","#69b1ff","#4096ff","#1677ff","#0958d9","#003eb3","#002c8c","#001d66"];Nb.primary=Nb[5];var MO=["#f0f5ff","#d6e4ff","#adc6ff","#85a5ff","#597ef7","#2f54eb","#1d39c4","#10239e","#061178","#030852"];MO.primary=MO[5];var jO=["#f9f0ff","#efdbff","#d3adf7","#b37feb","#9254de","#722ed1","#531dab","#391085","#22075e","#120338"];jO.primary=jO[5];var IO=["#fff0f6","#ffd6e7","#ffadd2","#ff85c0","#f759ab","#eb2f96","#c41d7f","#9e1068","#780650","#520339"];IO.primary=IO[5];var FO=["#a6a6a6","#999999","#8c8c8c","#808080","#737373","#666666","#404040","#1a1a1a","#000000","#000000"];FO.primary=FO[5];var B1={red:kO,volcano:NO,orange:EO,gold:OO,yellow:LO,lime:AO,green:RO,cyan:PO,blue:Nb,geekblue:MO,purple:jO,magenta:IO,grey:FO};function eF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function wt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?eF(Object(n),!0).forEach(function(r){mt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ra(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function Cde(e,t){if(!e)return!1;if(e.contains)return e.contains(t);for(var n=t;n;){if(n===e)return!0;n=n.parentNode}return!1}var tF="data-rc-order",nF="data-rc-priority",kde="rc-util-key",DO=new Map;function PW(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=e.mark;return t?t.startsWith("data-")?t:"data-".concat(t):kde}function L0(e){if(e.attachTo)return e.attachTo;var t=document.querySelector("head");return t||document.body}function Nde(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function YA(e){return Array.from((DO.get(e)||e).children).filter(function(t){return t.tagName==="STYLE"})}function MW(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!Ra())return null;var n=t.csp,r=t.prepend,i=t.priority,s=i===void 0?0:i,o=Nde(r),a=o==="prependQueue",l=document.createElement("style");l.setAttribute(tF,o),a&&s&&l.setAttribute(nF,"".concat(s)),n!=null&&n.nonce&&(l.nonce=n==null?void 0:n.nonce),l.innerHTML=e;var d=L0(t),h=d.firstChild;if(r){if(a){var f=(t.styles||YA(d)).filter(function(u){if(!["prepend","prependQueue"].includes(u.getAttribute(tF)))return!1;var c=Number(u.getAttribute(nF)||0);return s>=c});if(f.length)return d.insertBefore(l,f[f.length-1].nextSibling),l}d.insertBefore(l,h)}else d.appendChild(l);return l}function jW(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=L0(t);return(t.styles||YA(n)).find(function(r){return r.getAttribute(PW(t))===e})}function IW(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=jW(e,t);if(n){var r=L0(t);r.removeChild(n)}}function Ede(e,t){var n=DO.get(e);if(!n||!Cde(document,n)){var r=MW("",t),i=r.parentNode;DO.set(e,i),e.removeChild(r)}}function xu(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=L0(n),i=YA(r),s=wt(wt({},n),{},{styles:i});Ede(r,s);var o=jW(t,s);if(o){var a,l;if((a=s.csp)!==null&&a!==void 0&&a.nonce&&o.nonce!==((l=s.csp)===null||l===void 0?void 0:l.nonce)){var d;o.nonce=(d=s.csp)===null||d===void 0?void 0:d.nonce}return o.innerHTML!==e&&(o.innerHTML=e),o}var h=MW(e,s);return h.setAttribute(PW(s),t),h}function FW(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}function Ode(e){return FW(e)instanceof ShadowRoot}function Lde(e){return Ode(e)?FW(e):null}var BO={},ZA=[],Ade=function(t){ZA.push(t)};function QA(e,t){if("{}".NODE_ENV!=="production"&&!e&&console!==void 0){var n=ZA.reduce(function(r,i){return i(r??"","warning")},t);n&&console.error("Warning: ".concat(n))}}function Rde(e,t){if("{}".NODE_ENV!=="production"&&!e&&console!==void 0){var n=ZA.reduce(function(r,i){return i(r??"","note")},t);n&&console.warn("Note: ".concat(n))}}function DW(){BO={}}function BW(e,t,n){!t&&!BO[n]&&(e(!1,n),BO[n]=!0)}function El(e,t){BW(QA,e,t)}function Pde(e,t){BW(Rde,e,t)}El.preMessage=Ade;El.resetWarned=DW;El.noteOnce=Pde;function Mde(e){return e.replace(/-(.)/g,function(t,n){return n.toUpperCase()})}function jde(e,t){El(e,"[@ant-design/icons] ".concat(t))}function rF(e){return an(e)==="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(an(e.icon)==="object"||typeof e.icon=="function")}function iF(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(e).reduce(function(t,n){var r=e[n];switch(n){case"class":t.className=r,delete t.class;break;default:delete t[n],t[Mde(n)]=r}return t},{})}function zO(e,t,n){return n?M.createElement(e.tag,wt(wt({key:t},iF(e.attrs)),n),(e.children||[]).map(function(r,i){return zO(r,"".concat(t,"-").concat(e.tag,"-").concat(i))})):M.createElement(e.tag,wt({key:t},iF(e.attrs)),(e.children||[]).map(function(r,i){return zO(r,"".concat(t,"-").concat(e.tag,"-").concat(i))}))}function zW(e){return mm(e)[0]}function UW(e){return e?Array.isArray(e)?e:[e]:[]}var Ide=`
.anticon {
display: inline-flex;
align-items: center;
color: inherit;
font-style: normal;
line-height: 0;
text-align: center;
text-transform: none;
vertical-align: -0.125em;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.anticon > * {
line-height: 1;
}
.anticon svg {
display: inline-block;
}
.anticon::before {
display: none;
}
.anticon .anticon-icon {
display: block;
}
.anticon[tabindex] {
cursor: pointer;
}
.anticon-spin::before,
.anticon-spin {
display: inline-block;
-webkit-animation: loadingCircle 1s infinite linear;
animation: loadingCircle 1s infinite linear;
}
@-webkit-keyframes loadingCircle {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes loadingCircle {
100% {
-webkit-transform: