251 lines
1.9 MiB
JavaScript
251 lines
1.9 MiB
JavaScript
|
|
var p$=Object.defineProperty;var h$=(t,e,n)=>e in t?p$(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var hl=(t,e,n)=>h$(t,typeof e!="symbol"?e+"":e,n);import{dr as kg,eP as ed,dn as zo,eQ as IN,db as tm,eR as z_,eS as lp,eT as nm,eU as Qy,eV as Ku,ef as qd,dc as qa,eW as v$,dd as Kd,ea as hj,eX as m$,eY as H_,eZ as Qu,e6 as S1,e8 as N2,dk as rm,au as Zd,e_ as om,e$ as im,eg as Kg,f0 as k2,di as Yo,f1 as A1,dM as M1,ee as sp,dS as Ri,f2 as Pg,dj as Nh,f3 as Zg,f4 as X_,dR as Jd,dh as Es,df as _i,f5 as g$,f6 as vj,eE as ec,ed as Ll,f7 as y$,f8 as _$,f9 as Jg,fa as T1,fb as mj,dL as am,fc as gj,bL as tc,dg as Y_,at as kh,dQ as w_,dO as Hv,e9 as b$,ec as FN,eb as w$,as as yj,fd as _j,fe as E$,dm as C1,de as x$,ei as uw,ff as O$,fg as bj,fh as wj,fi as S$,fj as Ej,fk as A$,dp as M$,fl as T$,fm as C$,fn as N$,fo as cw,fp as k$,el as P$,fq as xj,dN as Oj,eh as P2,fr as Sj,fs as R2,ft as R$,dl as q_,fu as Aj,fv as D$,fw as Mj,fx as Tj,fy as j$,fz as L$,fA as I$,em as E_,eC as F$,fB as B$,fC as $$,aw as U$,fD as V$,fE as W$,fF as D2,fG as G$,fH as Cj,fI as z$,fJ as H$,ai as X$,eF as to,fK as Y$,ax as dw,fL as uA,fM as q$,fN as K$,fO as ws,fP as Z$,fQ as J$,av as Xv,fR as Q$,eG as Yv,fS as e9,eD as Vv,fT as Nj,fU as t9,fV as n9,fW as r9,ay as _r,aB as He,aV as K_,aD as ne,aE as Ne,aW as mn,aX as Ir,aH as k,aI as ee,aY as No,aF as bt,aG as j,b2 as Wn,c$ as cA,bX as mh,dw as BN,aJ as _e,bY as j2,aK as ft,b1 as Bn,aS as gn,cf as Ph,fX as ml,aQ as ja,aA as kj,aO as hr,aP as Pj,b6 as bo,b8 as Ql,bc as Rj,ch as Eh,cq as fw,fY as pw,bW as u0,aT as oi,aN as nc,aZ as Me,b7 as Rg,ce as Gs,cF as Dj,cj as x_,c1 as Xi,aC as Pt,c0 as L2,aM as kr,fZ as O_,ci as bs,d5 as Z_,bB as Dg,aU as Rh,f_ as o9,f$ as i9,g0 as jj,g1 as Lj,g2 as a9,g3 as l9,g4 as s9,g5 as u9,g6 as c9,g7 as Go,du as I2,dv as d9,cu as f9,bD as xh,dJ as p9,b3 as Oh,g8 as yu,cJ as h9,g9 as $N,ga as Lv,gb as v9,gc as F2,gd as B2,ge as m9,gf as g9,b4 as Ij,bZ as dA,az as y9,er as UN,cY as _9,bG as Qf,bH as Vs,bI as Bc,bK as Yl,bJ as sh}from"./admin-DBW881Vd.js";import{t as VN,a as WN,g as b9,i as Qd,n as w9,c as $2,l as c0,d as E9}from"./data-DQPbDZPO.js";import{_ as dp}from"./AIModeParamSettingDialog.vue_vue_type_script_setup_true_lang-CeMFmgi0.js";import{G as U2,d as x9,e as O9,f as S9,_ as Fj,c as Bj,b as A9,a as M9}from"./ToolDialog.vue_vue_type_style_index_0_lang-BnK4Bpqe.js";import{d as $j,c as lm,v as J_,e as T9,g as Uj,f as C9,a as ri,r as Vj}from"./reduce-DUOz4PWt.js";import{c as N9,a as k9,b as P9,e as Wj,f as Sh,m as R9,d as D9,h as hw}from"./min-C3Ljkllm.js";import{c as V2,b as N1,i as W2,p as Gj,n as G2,a as j9,d as z2,e as L9,f as I9,g as F9,h as B9,u as $9,j as U9,k as V9,l as zj,m as W9,r as G9,o as z9,q as H9,s as X9,t as Xo}from"./uniqBy-DYd3ZOQf.js";import{d as Hj,e as Y9,g as q9,h as K9,i as Z9,z as J9,s as Q9,m as e7,a as t7,b as n7,f as r7,c as o7,r as i7,u as a7}from"./zipObject-Qzmklie6.js";import{l as Xj,_ as Yj}from"./vue-draggable-plus-C7R4ksW6.js";import{_ as l7}from"./FieldFormDialog.vue_vue_type_script_setup_true_lang-DifCv9YD.js";import{_ as Fn}from"./defineProperty-DbXIQDXj.js";import"./typeof-QjJsDpFa.js";const qj=Object.freeze(Object.defineProperty({__proto__:null,get default(){return Kme}},Symbol.toStringTag,{value:"Module"}));var s7=NaN;function GN(t){return typeof t=="number"?t:kg(t)?s7:+t}function k1(t,e){return function(n,o){var r;if(n===void 0&&o===void 0)return e;if(n!==void 0&&(r=n),o!==void 0){if(r===void 0)return o;typeof n=="string"||typeof o=="string"?(n=ed(n),o=ed(o)):(n=GN(n),o=GN(o)),r=t(n,o)}return r}}var u7=k1(function(t,e){return t+e},0),c7="Expected a function";function d7(t,e){if(typeof e!="function")throw new TypeError(c7);return t=zo(t),function(){if(--t<1)return e.apply(this,arguments)}}var vw=IN&&new IN,Kj=vw?function(t,e){return vw.set(t,e),t}:tm;function S_(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4
|
|||
|
|
/* [wrapped with `+e+`] */
|
|||
|
|
`)}var M7=1,T7=2,C7=8,N7=16,k7=32,P7=64,R7=128,D7=256,j7=512,L7=[["ary",R7],["bind",M7],["bindKey",T7],["curry",C7],["curryRight",N7],["flip",j7],["partial",k7],["partialRight",P7],["rearg",D7]];function I7(t,e){return Kd(L7,function(n){var o="_."+n[0];e&n[1]&&!hj(t,o)&&t.push(o)}),t.sort()}function tL(t,e,n){var o=e+"";return m$(t,A7(o,I7(O7(o),n)))}var F7=4,B7=8,zN=32,HN=64;function nL(t,e,n,o,r,i,a,s,l,f){var h=e&B7,v=h?a:void 0,b=h?void 0:a,E=h?i:void 0,O=h?void 0:i;e|=h?zN:HN,e&=~(h?HN:zN),e&F7||(e&=-4);var w=[t,e,r,E,v,O,b,s,l,f],S=n.apply(void 0,w);return fA(t)&&eL(S,w),S.placeholder=o,tL(S,t,e)}function Qg(t){var e=t;return e.placeholder}var $7=Math.min;function U7(t,e){for(var n=t.length,o=$7(e.length,n),r=Ku(t);o--;){var i=e[o];t[o]=H_(i,n)?r[i]:void 0}return t}var XN="__lodash_placeholder__";function Ah(t,e){for(var n=-1,o=t.length,r=0,i=[];++n<o;){var a=t[n];(a===e||a===XN)&&(t[n]=XN,i[r++]=n)}return i}var V7=1,W7=2,G7=8,z7=16,H7=128,X7=512;function R1(t,e,n,o,r,i,a,s,l,f){var h=e&H7,v=e&V7,b=e&W7,E=e&(G7|z7),O=e&X7,w=b?void 0:S_(t);function S(){for(var M=arguments.length,T=Array(M),$=M;$--;)T[$]=arguments[$];if(E)var D=Qg(S),P=m7(T,D);if(o&&(T=Zj(T,o,r,E)),i&&(T=Jj(T,i,a,E)),M-=P,E&&M<f){var B=Ah(T,D);return nL(t,e,R1,S.placeholder,n,T,B,s,l,f-M)}var F=v?n:this,I=b?F[t]:t;return M=T.length,s?T=U7(T,s):O&&M>1&&T.reverse(),h&&l<M&&(T.length=l),this&&this!==nm&&this instanceof S&&(I=w||S_(I)),I.apply(F,T)}return S}function Y7(t,e,n){var o=S_(t);function r(){for(var i=arguments.length,a=Array(i),s=i,l=Qg(r);s--;)a[s]=arguments[s];var f=i<3&&a[0]!==l&&a[i-1]!==l?[]:Ah(a,l);if(i-=f.length,i<n)return nL(t,e,R1,r.placeholder,void 0,a,f,void 0,void 0,n-i);var h=this&&this!==nm&&this instanceof r?o:t;return Qu(h,this,a)}return r}var q7=1;function K7(t,e,n,o){var r=e&q7,i=S_(t);function a(){for(var s=-1,l=arguments.length,f=-1,h=o.length,v=Array(h+l),b=this&&this!==nm&&this instanceof a?i:t;++f<h;)v[f]=o[f];for(;l--;)v[f++]=arguments[++s];return Qu(b,r?n:this,v)}return a}var YN="__lodash_placeholder__",YO=1,Z7=2,J7=4,qN=8,jy=128,KN=256,Q7=Math.min;function eU(t,e){var n=t[1],o=e[1],r=n|o,i=r<(YO|Z7|jy),a=o==jy&&n==qN||o==jy&&n==KN&&t[7].length<=e[8]||o==(jy|KN)&&e[7].length<=e[8]&&n==qN;if(!(i||a))return t;o&YO&&(t[2]=e[2],r|=n&YO?0:J7);var s=e[3];if(s){var l=t[3];t[3]=l?Zj(l,s,e[4]):s,t[4]=l?Ah(t[3],YN):e[4]}return s=e[5],s&&(l=t[5],t[5]=l?Jj(l,s,e[6]):s,t[6]=l?Ah(t[5],YN):e[6]),s=e[7],s&&(t[7]=s),o&jy&&(t[8]=t[8]==null?e[8]:Q7(t[8],e[8])),t[9]==null&&(t[9]=e[9]),t[0]=e[0],t[1]=r,t}var tU="Expected a function",ZN=1,nU=2,JN=8,QN=16,ek=32,rU=64,tk=Math.max;function fp(t,e,n,o,r,i,a,s){var l=e&nU;if(!l&&typeof t!="function")throw new TypeError(tU);var f=o?o.length:0;if(f||(e&=-97,o=r=void 0),a=a===void 0?a:tk(zo(a),0),s=s===void 0?s:zo(s),f-=r?r.length:0,e&rU){var h=o,v=r;o=r=void 0}var b=l?void 0:H2(t),E=[t,e,n,o,r,h,v,i,a,s];if(b&&eU(E,b),t=E[0],e=E[1],n=E[2],o=E[3],r=E[4],s=E[9]=E[9]===void 0?l?0:t.length:tk(E[9]-f,0),!s&&e&(JN|QN)&&(e&=-25),!e||e==ZN)var O=p7(t,e,n);else e==JN||e==QN?O=Y7(t,e,s):(e==ek||e==(ZN|ek))&&!r.length?O=K7(t,e,n,o):O=R1.apply(void 0,E);var w=b?Kj:eL;return tL(w(O,E),t,e)}var oU=128;function rL(t,e,n){return e=n?void 0:e,e=t&&e==null?t.length:e,fp(t,oU,void 0,void 0,void 0,void 0,e)}var iU=S1(function(t,e){N2(e,rm(e),t)}),pA=S1(function(t,e,n,o){N2(e,rm(e),t,o)}),aU=S1(function(t,e,n,o){N2(e,Zd(e),t,o)});function X2(t,e){for(var n=-1,o=e.length,r=Array(o),i=t==null;++n<o;)r[n]=i?void 0:om(t,e[n]);return r}var lU=im(X2),sU="[object DOMException]",uU="[object Error]";function Y2(t){if(!qd(t))return!1;var e=Kg(t);return e==uU||e==sU||typeof t.message=="string"&&typeof t.name=="string"&&!k2(t)}var oL=Yo(function(t,e){try{return Qu(t,void 0,e)}catch(n){return Y2(n)?n:new Error(n)}}),cU="Expected a function";function iL(t,e){var n;if(typeof e!="function")throw new TypeError(cU);return t=zo(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=void 0),n}}var dU=1,fU=32,D1=Yo(function(t,e,n){var o=dU;if(n.length){var r=Ah(n,Qg(D1));o|=fU}return fp(t,o,e,n,r)});D1.placeholder={};var pU=im(fu
|
|||
|
|
`:"";t.replace(b,function(S,M,T,$,D,P){return T||(T=$),v+=t.slice(f,P).replace(AX,gX),M&&(s=!0,v+=`' +
|
|||
|
|
__e(`+M+`) +
|
|||
|
|
'`),D&&(l=!0,v+=`';
|
|||
|
|
`+D+`;
|
|||
|
|
__p += '`),T&&(v+=`' +
|
|||
|
|
((__t = (`+T+`)) == null ? '' : __t) +
|
|||
|
|
'`),f=P+S.length,S}),v+=`';
|
|||
|
|
`;var O=fk.call(e,"variable")&&e.variable;if(!O)v=`with (obj) {
|
|||
|
|
`+v+`
|
|||
|
|
}
|
|||
|
|
`;else if(OX.test(O))throw new Error(bX);v=(l?v.replace(wX,""):v).replace(EX,"$1").replace(xX,"$1;"),v="function("+(O||"obj")+`) {
|
|||
|
|
`+(O?"":`obj || (obj = {});
|
|||
|
|
`)+"var __t, __p = ''"+(s?", __e = _.escape":"")+(l?`, __j = Array.prototype.join;
|
|||
|
|
function print() { __p += __j.call(arguments, '') }
|
|||
|
|
`:`;
|
|||
|
|
`)+v+`return __p
|
|||
|
|
}`;var w=oL(function(){return Function(i,E+"return "+v).apply(void 0,a)});if(w.source=v,Y2(w))throw w;return w}function U1(t,e){return e(t)}var CX=9007199254740991,KO=4294967295,NX=Math.min;function kX(t,e){if(t=zo(t),t<1||t>CX)return[];var n=KO,o=NX(t,KO);e=lm(e),t-=KO;for(var r=Aj(o,e);++n<t;)e(n);return r}function PX(){return this}function u3(t,e){var n=t;return n instanceof $o&&(n=n.value()),$j(e,function(o,r){return r.func.apply(r.thisArg,X_([o],r.args))},n)}function RX(){return u3(this.__wrapped__,this.__actions__)}function DX(t){return Ri(t).toLowerCase()}function jX(t){return qa(t)?Es(t,A1):kg(t)?[t]:Ku(D$(Ri(t)))}var pk=9007199254740991;function LX(t){return t?Jg(zo(t),-pk,pk):t===0?t:0}function IX(t){return Ri(t).toUpperCase()}function FX(t,e,n){var o=qa(t),r=o||Mj(t)||Tj(t);if(e=_i(e),n==null){var i=t&&t.constructor;r?n=o?new i:[]:lp(t)?n=kh(i)?z_(j$(t)):{}:n={}}return(r?Kd:am)(t,function(a,s,l){return e(n,a,s,l)}),n}function c3(t,e){for(var n=t.length;n--&&P2(e,t[n],0)>-1;);return n}function d3(t,e){for(var n=-1,o=t.length;++n<o&&P2(e,t[n],0)>-1;);return n}function BX(t,e,n){if(t=Ri(t),t&&(n||e===void 0))return L$(t);if(!t||!(e=ed(e)))return t;var o=td(t),r=td(e),i=d3(o,r),a=c3(o,r)+1;return Dh(o,i,a).join("")}function $X(t,e,n){if(t=Ri(t),t&&(n||e===void 0))return t.slice(0,I$(t)+1);if(!t||!(e=ed(e)))return t;var o=td(t),r=c3(o,td(e))+1;return Dh(o,0,r).join("")}var UX=/^\s+/;function VX(t,e,n){if(t=Ri(t),t&&(n||e===void 0))return t.replace(UX,"");if(!t||!(e=ed(e)))return t;var o=td(t),r=d3(o,td(e));return Dh(o,r).join("")}var WX=30,GX="...",zX=/\w*$/;function HX(t,e){var n=WX,o=GX;if(lp(e)){var r="separator"in e?e.separator:r;n="length"in e?zo(e.length):n,o="omission"in e?ed(e.omission):o}t=Ri(t);var i=t.length;if(ey(t)){var a=td(t);i=a.length}if(n>=i)return t;var s=n-ny(o);if(s<1)return o;var l=a?Dh(a,0,s).join(""):t.slice(0,s);if(r===void 0)return l+o;if(a&&(s+=l.length-s),z2(r)){if(t.slice(s).search(r)){var f,h=l;for(r.global||(r=RegExp(r.source,Ri(zX.exec(r))+"g")),r.lastIndex=0;f=r.exec(h);)var v=f.index;l=l.slice(0,v===void 0?s:v)}}else if(t.indexOf(ed(r),s)!=s){var b=l.lastIndexOf(r);b>-1&&(l=l.slice(0,b))}return l+o}function XX(t){return rL(t,1)}var YX={"&":"&","<":"<",">":">",""":'"',"'":"'"},qX=Z2(YX),f3=/&(?:amp|lt|gt|quot|#39);/g,KX=RegExp(f3.source);function ZX(t){return t=Ri(t),t&&KX.test(t)?t.replace(f3,qX):t}var JX=Yo(function(t){var e=ec(t);return Ll(e)&&(e=void 0),E_(Jd(t,1,Ll,!0),_i(e))}),QX=Yo(function(t){var e=ec(t);return e=typeof e=="function"?e:void 0,E_(Jd(t,1,Ll,!0),void 0,e)});function eY(t,e){return e=typeof e=="function"?e:void 0,t&&t.length?E_(t,void 0,e):[]}function tY(t,e){return t==null?!0:Sj(t,e)}var nY=Math.max;function cM(t){if(!(t&&t.length))return[];var e=0;return t=Y_(t,function(n){if(Ll(n))return e=nY(n.length,e),!0}),Aj(e,function(n){return Es(t,xj(n))})}function p3(t,e){if(!(t&&t.length))return[];var n=cM(t);return e==null?n:Es(n,function(o){return Qu(e,void 0,o)})}function h3(t,e,n,o){return R2(t,e,n(Oj(t,e)),o)}function rY(t,e,n){return t==null?t:h3(t,e,lm(n))}function oY(t,e,n,o){return o=typeof o=="function"?o:void 0,t==null?t:h3(t,e,lm(n),o)}var iY=ty(function(t,e,n){return t+(n?" ":"")+e.toUpperCase()});function aY(t){return t==null?[]:Uj(t,rm(t))}var lY=Yo(function(t,e){return Ll(t)?N1(t,e):[]});function sY(t,e){return F1(lm(e),t)}var uY=im(function(t){var e=t.length,n=e?t[0]:0,o=this.__wrapped__,r=function(i){return X2(i,t)};return e>1||this.__actions__.length||!(o instanceof $o)||!H_(n)?this.thru(r):(o=o.slice(n,+n+(e?1:0)),o.__actions__.push({func:U1,args:[r],thisArg:void 0}),new rc(o,this.__chain__).thru(function(i){return e&&!i.length&&i.push(void 0),i}))});function cY(){return CL(this)}function dY(){var t=this.__wrapped__;if(t instanceof $o){var e=t;return this.__actions__.length&&(e=new $o(this)),e=e.reverse(),e.__actions__.push({func:U1,args:[_A],thisArg:void 0}),new rc(e,this.__chain__)}return this.thru(_A)}function dM(t,e,n){var o=t.length;if(o<2)return o?E_(t[0]):[];for(var r=-1,i=Array(o);++r<o;)for(var a=t[r],s=-1;++s<o;)s!=r&
|
|||
|
|
* @license
|
|||
|
|
* Lodash (Custom Build) <https://lodash.com/>
|
|||
|
|
* Build: `lodash modularize exports="es" -o ./`
|
|||
|
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|||
|
|
* Released under MIT license <https://lodash.com/license>
|
|||
|
|
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|||
|
|
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|||
|
|
*/var TY="4.17.23",CY=2,NY=1,kY=3,v3=4294967295,PY=Array.prototype,RY=Object.prototype,m3=RY.hasOwnProperty,hk=cw?cw.iterator:void 0,DY=Math.max,vk=Math.min,pM=(function(t){return function(e,n,o){if(o==null){var r=lp(n),i=r&&Zd(n),a=i&&i.length&&L1(n,i);(a?a.length:r)||(o=n,n=e,e=this)}return t(e,n,o)}})(nz);ge.after=Ta.after;ge.ary=Ta.ary;ge.assign=io.assign;ge.assignIn=io.assignIn;ge.assignInWith=io.assignInWith;ge.assignWith=io.assignWith;ge.at=io.at;ge.before=Ta.before;ge.bind=Ta.bind;ge.bindAll=bi.bindAll;ge.bindKey=Ta.bindKey;ge.castArray=Vr.castArray;ge.chain=ef.chain;ge.chunk=mr.chunk;ge.compact=mr.compact;ge.concat=mr.concat;ge.cond=bi.cond;ge.conforms=bi.conforms;ge.constant=bi.constant;ge.countBy=Di.countBy;ge.create=io.create;ge.curry=Ta.curry;ge.curryRight=Ta.curryRight;ge.debounce=Ta.debounce;ge.defaults=io.defaults;ge.defaultsDeep=io.defaultsDeep;ge.defer=Ta.defer;ge.delay=Ta.delay;ge.difference=mr.difference;ge.differenceBy=mr.differenceBy;ge.differenceWith=mr.differenceWith;ge.drop=mr.drop;ge.dropRight=mr.dropRight;ge.dropRightWhile=mr.dropRightWhile;ge.dropWhile=mr.dropWhile;ge.fill=mr.fill;ge.filter=Di.filter;ge.flatMap=Di.flatMap;ge.flatMapDeep=Di.flatMapDeep;ge.flatMapDepth=Di.flatMapDepth;ge.flatten=mr.flatten;ge.flattenDeep=mr.flattenDeep;ge.flattenDepth=mr.flattenDepth;ge.flip=Ta.flip;ge.flow=bi.flow;ge.flowRight=bi.flowRight;ge.fromPairs=mr.fromPairs;ge.functions=io.functions;ge.functionsIn=io.functionsIn;ge.groupBy=Di.groupBy;ge.initial=mr.initial;ge.intersection=mr.intersection;ge.intersectionBy=mr.intersectionBy;ge.intersectionWith=mr.intersectionWith;ge.invert=io.invert;ge.invertBy=io.invertBy;ge.invokeMap=Di.invokeMap;ge.iteratee=bi.iteratee;ge.keyBy=Di.keyBy;ge.keys=Zd;ge.keysIn=io.keysIn;ge.map=Di.map;ge.mapKeys=io.mapKeys;ge.mapValues=io.mapValues;ge.matches=bi.matches;ge.matchesProperty=bi.matchesProperty;ge.memoize=Ta.memoize;ge.merge=io.merge;ge.mergeWith=io.mergeWith;ge.method=bi.method;ge.methodOf=bi.methodOf;ge.mixin=pM;ge.negate=G2;ge.nthArg=bi.nthArg;ge.omit=io.omit;ge.omitBy=io.omitBy;ge.once=Ta.once;ge.orderBy=Di.orderBy;ge.over=bi.over;ge.overArgs=Ta.overArgs;ge.overEvery=bi.overEvery;ge.overSome=bi.overSome;ge.partial=Ta.partial;ge.partialRight=Ta.partialRight;ge.partition=Di.partition;ge.pick=io.pick;ge.pickBy=io.pickBy;ge.property=bi.property;ge.propertyOf=bi.propertyOf;ge.pull=mr.pull;ge.pullAll=mr.pullAll;ge.pullAllBy=mr.pullAllBy;ge.pullAllWith=mr.pullAllWith;ge.pullAt=mr.pullAt;ge.range=bi.range;ge.rangeRight=bi.rangeRight;ge.rearg=Ta.rearg;ge.reject=Di.reject;ge.remove=mr.remove;ge.rest=Ta.rest;ge.reverse=mr.reverse;ge.sampleSize=Di.sampleSize;ge.set=io.set;ge.setWith=io.setWith;ge.shuffle=Di.shuffle;ge.slice=mr.slice;ge.sortBy=Di.sortBy;ge.sortedUniq=mr.sortedUniq;ge.sortedUniqBy=mr.sortedUniqBy;ge.split=pi.split;ge.spread=Ta.spread;ge.tail=mr.tail;ge.take=mr.take;ge.takeRight=mr.takeRight;ge.takeRightWhile=mr.takeRightWhile;ge.takeWhile=mr.takeWhile;ge.tap=ef.tap;ge.throttle=Ta.throttle;ge.thru=U1;ge.toArray=Vr.toArray;ge.toPairs=io.toPairs;ge.toPairsIn=io.toPairsIn;ge.toPath=bi.toPath;ge.toPlainObject=Vr.toPlainObject;ge.transform=io.transform;ge.unary=Ta.unary;ge.union=mr.union;ge.unionBy=mr.unionBy;ge.unionWith=mr.unionWith;ge.uniq=mr.uniq;ge.uniqBy=mr.uniqBy;ge.uniqWith=mr.uniqWith;ge.unset=io.unset;ge.unzip=mr.unzip;ge.unzipWith=mr.unzipWith;ge.update=io.update;ge.updateWith=io.updateWith;ge.values=io.values;ge.valuesIn=io.valuesIn;ge.without=mr.without;ge.words=pi.words;ge.wrap=Ta.wrap;ge.xor=mr.xor;ge.xorBy=mr.xorBy;ge.xorWith=mr.xorWith;ge.zip=mr.zip;ge.zipObject=mr.zipObject;ge.zipObjectDeep=mr.zipObjectDeep;ge.zipWith=mr.zipWith;ge.entries=io.toPairs;ge.entriesIn=io.toPairsIn;ge.extend=io.assignIn;ge.extendWith=io.assignInWith;pM(ge,ge);ge.add=Ss.add;ge.attempt=bi.attempt;ge.camelCase=pi.camelCase;ge.capitalize=pi.capitalize;ge.ceil=Ss.ceil;ge.clamp=fM.clamp;ge.clone=Vr.clone;ge.cloneDeep=Vr.cloneDeep;ge.cloneDeepWith=Vr.cloneDeepWith;ge.cloneWith=Vr.cloneWith;ge.conformsTo=Vr.conformsTo;ge.deburr=pi.deburr;ge.defaultTo=bi.defaultTo;ge.divide=Ss.divide;ge.
|
|||
|
|
{{${Pt("views.applicationWorkflow.nodes.searchKnowledgeNode.label")}.data}}
|
|||
|
|
${Pt("views.problem.title")}:
|
|||
|
|
{{${Pt("views.applicationWorkflow.nodes.startNode.label")}.question}}`,dialogue_number:1,is_result:!0,temperature:null,max_tokens:null,dialogue_type:"WORKFLOW",model_setting:{reasoning_content_start:"<think>",reasoning_content_end:"</think>",reasoning_content_enable:!1}},v=hr({get:()=>b.nodeModel.properties.node_data?(b.nodeModel.properties.node_data.model_setting||Me.set(b.nodeModel.properties.node_data,"model_setting",{reasoning_content_start:"<think>",reasoning_content_end:"</think>",reasoning_content_enable:!1}),b.nodeModel.properties.node_data):(Me.set(b.nodeModel.properties,"node_data",h),b.nodeModel.properties.node_data),set:Be=>{Me.set(b.nodeModel.properties,"node_data",Be)}}),b=t,E=He(),O=He(null),w=He(),S=He(),M=()=>{var Be;return(Be=E.value)==null?void 0:Be.validate().catch(Je=>Promise.reject({node:b.nodeModel,errMessage:Je}))},T=e();function $(){var Je;const Be=r.value==="systemManage"?{model_type:"LLM",workspace_id:(Je=T.value)==null?void 0:Je.workspace_id}:{model_type:"LLM"};oi({type:"model",systemType:r.value}).getSelectModelList(Be).then(gt=>{O.value=Me.groupBy(gt==null?void 0:gt.data,"provider")})}const D=Be=>{var Je;Be&&((Je=w.value)==null||Je.open(Be,o,v.value.model_params_setting))},P=He(),B=Be=>{var Je;Be&&((Je=P.value)==null||Je.open(Be,o))},F=Be=>{Me.set(b.nodeModel.properties.node_data,"system",Be)},I=()=>{var Be;(Be=S.value)==null||Be.open(v.value.model_setting)};function V(Be){Me.set(b.nodeModel.properties.node_data,"model_params_setting",Be)}function z(Be){let Je=Me.cloneDeep(b.nodeModel.properties.node_data.model_setting);Je={...Je,...Be},Me.set(b.nodeModel.properties.node_data,"model_setting",Je)}const X=He();function Y(){const Be={mcp_servers:v.value.mcp_servers,mcp_tool_ids:v.value.mcp_tool_ids,mcp_source:v.value.mcp_source};X.value.open(Be,ze.value)}function W(Be){Me.set(b.nodeModel.properties.node_data,"mcp_servers",Be.mcp_servers),Me.set(b.nodeModel.properties.node_data,"mcp_tool_ids",Be.mcp_tool_ids),Me.set(b.nodeModel.properties.node_data,"mcp_source",Be.mcp_source)}const Q=He();function J(){Q.value.open(v.value.tool_ids)}function ie(Be){Me.set(b.nodeModel.properties.node_data,"tool_ids",Be.tool_ids)}function Se(Be){const Je=b.nodeModel.properties.node_data.tool_ids.filter(gt=>gt!==Be);Me.set(b.nodeModel.properties.node_data,"tool_ids",Je)}function Ae(Be){const Je=b.nodeModel.properties.node_data.mcp_tool_ids.filter(gt=>gt!==Be);Me.set(b.nodeModel.properties.node_data,"mcp_tool_ids",Je)}const Pe=He([]);function De(){var Je;const Be=r.value==="systemManage"?{scope:"WORKSPACE",tool_type:"CUSTOM",workspace_id:(Je=T.value)==null?void 0:Je.workspace_id}:{scope:"WORKSPACE",tool_type:"CUSTOM"};oi({type:"tool",systemType:r.value}).getAllToolList(Be).then(gt=>{Pe.value=[...gt.data.shared_tools,...gt.data.tools].filter(le=>le.is_active)})}const ze=He([]);function Ye(){var Je;const Be=r.value==="systemManage"?{scope:"WORKSPACE",tool_type:"MCP",workspace_id:(Je=T.value)==null?void 0:Je.workspace_id}:{scope:"WORKSPACE",tool_type:"MCP"};oi({type:"tool",systemType:r.value}).getAllToolList(Be).then(gt=>{ze.value=[...gt.data.shared_tools,...gt.data.tools].filter(le=>le.is_active)})}return bo(()=>{var Be,Je,gt,le;$(),typeof((Be=b.nodeModel.properties.node_data)==null?void 0:Be.is_result)>"u"&&Qd(b.nodeModel)&&Me.set(b.nodeModel.properties.node_data,"is_result",!0),Me.set(b.nodeModel,"validate",M),v.value.dialogue_type||(v.value.dialogue_type="WORKFLOW"),(Je=b.nodeModel.properties.node_data)!=null&&Je.mcp_tool_id&&(Me.set(b.nodeModel.properties.node_data,"mcp_tool_ids",[(gt=b.nodeModel.properties.node_data)==null?void 0:gt.mcp_tool_id]),Me.set(b.nodeModel.properties.node_data,"mcp_tool_id",void 0)),((le=b.nodeModel.properties.node_data)==null?void 0:le.mcp_output_enable)===void 0&&Me.set(b.nodeModel.properties.node_data,"mcp_output_enable",!0),De(),Ye()}),(Be,Je)=>{const gt=ne("AppIcon"),le=ne("el-button"),Ze=ne("ModelSelect"),pe=ne("el-form-item"),se=ne("el-tooltip"),we=ne("MdEditorMagnify"),$e=ne("el-option"),rt=ne("el-select"),pt=ne("el-input-number"),Lt=ne("el-switch"),Jt=ne("el-avatar"),en=ne("Tool
|
|||
|
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|||
|
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|||
|
|
this file except in compliance with the License. You may obtain a copy of the
|
|||
|
|
License at http://www.apache.org/licenses/LICENSE-2.0
|
|||
|
|
|
|||
|
|
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|||
|
|
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|||
|
|
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|||
|
|
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|||
|
|
|
|||
|
|
See the Apache Version 2.0 License for specific language governing permissions
|
|||
|
|
and limitations under the License.
|
|||
|
|
***************************************************************************** */var OA=function(t,e){return OA=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var r in o)o.hasOwnProperty(r)&&(n[r]=o[r])},OA(t,e)};function rK(t,e){OA(t,e);function n(){this.constructor=t}t.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}var xw=function(){return xw=Object.assign||function(e){for(var n,o=1,r=arguments.length;o<r;o++){n=arguments[o];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},xw.apply(this,arguments)};function Vd(t){var e=typeof Symbol=="function"&&t[Symbol.iterator],n=0;return e?e.call(t):{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}}}function _g(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i}function EM(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(_g(arguments[e]));return t}var Ow=Symbol("mobx did run lazy initializers"),Gy=Symbol("mobx pending decorators"),oK={},iK={};function aK(t,e){var n=e?oK:iK;return n[t]||(n[t]={configurable:!0,enumerable:e,get:function(){return qv(this),this[t]},set:function(o){qv(this),this[t]=o}})}function qv(t){var e,n;if(t[Ow]!==!0){var o=t[Gy];if(o){oy(t,Ow,!0);var r=EM(Object.getOwnPropertySymbols(o),Object.keys(o));try{for(var i=Vd(r),a=i.next();!a.done;a=i.next()){var s=a.value,l=o[s];l.propertyCreator(t,l.prop,l.descriptor,l.decoratorTarget,l.decoratorArguments)}}catch(f){e={error:f}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(e)throw e.error}}}}}function k3(t,e){return function(){var o,r=function(a,s,l,f){if(f===!0)return e(a,s,l,a,o),null;if(!Object.prototype.hasOwnProperty.call(a,Gy)){var h=a[Gy];oy(a,Gy,xw({},h))}return a[Gy][s]={prop:s,propertyCreator:e,descriptor:l,decoratorTarget:a,decoratorArguments:o},aK(s,t)};return lK(arguments)?(o=Ew,r.apply(null,arguments)):(o=Array.prototype.slice.call(arguments),r)}}function lK(t){return(t.length===2||t.length===3)&&(typeof t[1]=="string"||typeof t[1]=="symbol")||t.length===4&&t[3]===!0}function nb(t,e,n){return Ug(t)?t:Array.isArray(t)?Ut.array(t,{name:n}):ry(t)?Ut.object(t,void 0,{name:n}):iy(t)?Ut.map(t,{name:n}):tb(t)?Ut.set(t,{name:n}):t}function sK(t,e,n){return t==null||rd(t)||tf(t)||Ys(t)||oc(t)?t:Array.isArray(t)?Ut.array(t,{name:n,deep:!1}):ry(t)?Ut.object(t,void 0,{name:n,deep:!1}):iy(t)?Ut.map(t,{name:n,deep:!1}):tb(t)?Ut.set(t,{name:n,deep:!1}):Qo(!1)}function G1(t){return t}function uK(t,e,n){return rI(t,e)?e:t}function z1(t){Wv(t);var e=k3(!0,function(o,r,i,a,s){var l=i?i.initializer?i.initializer.call(o):i.value:void 0;MM(o).addObservableProp(r,l,t)}),n=e;return n.enhancer=t,n}var P3={deep:!0,name:void 0,defaultDecorator:void 0,proxy:!0};Object.freeze(P3);function pg(t){return t==null?P3:typeof t=="string"?{name:t,deep:!0,proxy:!0}:t}var xM=z1(nb),cK=z1(sK),R3=z1(G1),dK=z1(uK);function h0(t){return t.defaultDecorator?t.defaultDecorator.enhancer:t.deep===!1?G1:nb}function fK(t,e,n){if(typeof arguments[1]=="string"||typeof arguments[1]=="symbol")return xM.apply(null,arguments);if(Ug(t))return t;var o=ry(t)?Ut.object(t,e,n):Array.isArray(t)?Ut.array(t,e):iy(t)?Ut.map(t,e):tb(t)?Ut.set(t,e):t;if(o!==t)return o;Qo(!1)}var Ak={box:function(t,e){arguments.length>2&&Ly("box");var n=pg(e);return new zv(t,h0(n),n.name,!0,n.equals)},array:function(t,e){arguments.length>2&&Ly("array");var n=pg(e);return KK(t,h0(n),n.name)},map:function(t,e){arguments.length>2&&Ly("map");var n=pg(e);return new AM(t,h0(n),n.name)},set:function(t,e){arguments.length>2&&Ly("set");var n=pg(e);return new tI(t,h0(n),n.name)},object:function(t,e,n){typeof arguments[1]=="string"&&Ly("object");var o=pg(n);if(o.proxy===!1)return NA({},t,e,o);var r=q3(o),i=NA({},void 0,void 0,o),a=XK(i);return K3(a,t,e,r),a},ref:R3,shallow:cK,deep:xM,struct:dK},Ut=fK;Object.keys(Ak).forEach(function(t
|
|||
|
|
/*
|
|||
|
|
Tracing '`+t.name+`'
|
|||
|
|
|
|||
|
|
You are entering this break point because derivation '`+t.name+"' is being traced and '"+e.name+`' is now forcing it to update.
|
|||
|
|
Just follow the stacktrace you should now see in the devtools to see precisely what piece of your code is causing this update
|
|||
|
|
The stackframe you are looking for is at least ~6-8 stack-frames up.
|
|||
|
|
|
|||
|
|
`+(t instanceof Bg?t.derivation.toString().replace(/[*]\//g,"/"):"")+`
|
|||
|
|
|
|||
|
|
The dependencies for this derivation are:
|
|||
|
|
|
|||
|
|
`+n.join(`
|
|||
|
|
`)+`
|
|||
|
|
*/
|
|||
|
|
`)()}}function W3(t,e,n){if(e.length>=1e3){e.push("(and many more)");return}e.push(""+new Array(n).join(" ")+t.name),t.dependencies&&t.dependencies.forEach(function(o){return W3(o,e,n+1)})}var A_=(function(){function t(e,n,o,r){e===void 0&&(e="Reaction@"+Hs()),r===void 0&&(r=!1),this.name=e,this.onInvalidate=n,this.errorHandler=o,this.requiresObservable=r,this.observing=[],this.newObserving=[],this.dependenciesState=ii.NOT_TRACKING,this.diffValue=0,this.runId=0,this.unboundDepsCount=0,this.__mapid="#"+Hs(),this.isDisposed=!1,this._isScheduled=!1,this._isTrackPending=!1,this._isRunning=!1,this.isTracing=Wd.NONE}return t.prototype.onBecomeStale=function(){this.schedule()},t.prototype.schedule=function(){this._isScheduled||(this._isScheduled=!0,yr.pendingReactions.push(this),G3())},t.prototype.isScheduled=function(){return this._isScheduled},t.prototype.runReaction=function(){if(!this.isDisposed){if(Kc(),this._isScheduled=!1,SA(this)){this._isTrackPending=!0;try{this.onInvalidate(),this._isTrackPending&&Zu()}catch(e){this.reportExceptionInDerivation(e)}}Zc()}},t.prototype.track=function(e){if(!this.isDisposed){Kc(),this._isRunning=!0;var n=D3(this,e,void 0);this._isRunning=!1,this._isTrackPending=!1,this.isDisposed&&AA(this),zy(n)&&this.reportExceptionInDerivation(n.cause),Zc()}},t.prototype.reportExceptionInDerivation=function(e){var n=this;if(this.errorHandler){this.errorHandler(e,this);return}if(yr.disableErrorBoundaries)throw e;var o="[mobx] Encountered an uncaught exception that was thrown by a reaction or observer component, in: '"+this+"'";yr.suppressReactionErrors?console.warn("[mobx] (error in reaction '"+this.name+"' suppressed, fix error of causing action below)"):console.error(o,e),yr.globalReactionErrorHandlers.forEach(function(r){return r(e,n)})},t.prototype.dispose=function(){this.isDisposed||(this.isDisposed=!0,this._isRunning||(Kc(),AA(this),Zc()))},t.prototype.getDisposer=function(){var e=this.dispose.bind(this);return e[eo]=this,e},t.prototype.toString=function(){return"Reaction["+this.name+"]"},t.prototype.trace=function(e){e===void 0&&(e=!1),GK(this,e)},t})(),Tk=100,CA=function(t){return t()};function G3(){yr.inBatch>0||yr.isRunningReactions||CA(SK)}function SK(){yr.isRunningReactions=!0;for(var t=yr.pendingReactions,e=0;t.length>0;){++e===Tk&&(console.error("Reaction doesn't converge to a stable state after "+Tk+" iterations."+(" Probably there is a cycle in the reactive function: "+t[0])),t.splice(0));for(var n=t.splice(0),o=0,r=n.length;o<r;o++)n[o].runReaction()}yr.isRunningReactions=!1}var Tw=jh("Reaction",A_);function AK(t){var e=CA;CA=function(n){return t(function(){return e(n)})}}function Zu(){return!1}function MK(t){return console.warn("[mobx.spy] Is a no-op in production builds"),function(){}}function TK(){Qo(!1)}function Ck(t){return function(e,n,o){if(o){if(o.value)return{value:Gv(t,o.value),enumerable:!1,configurable:!0,writable:!0};var r=o.initializer;return{enumerable:!1,configurable:!0,writable:!0,initializer:function(){return Gv(t,r.call(this))}}}return CK(t).apply(this,arguments)}}function CK(t){return function(e,n,o){Object.defineProperty(e,n,{configurable:!0,enumerable:!1,get:function(){},set:function(r){oy(this,n,Bt(t,r))}})}}function NK(t,e,n,o){return o===!0?(ZO(t,e,n.value),null):n?{configurable:!0,enumerable:!1,get:function(){return ZO(this,e,n.value||n.initializer.call(this)),this[e]},set:TK}:{enumerable:!1,configurable:!0,set:function(r){ZO(this,e,r)},get:function(){}}}var Bt=function(e,n,o,r){if(arguments.length===1&&typeof e=="function")return Gv(e.name||"<unnamed action>",e);if(arguments.length===2&&typeof n=="function")return Gv(e,n);if(arguments.length===1&&typeof e=="string")return Ck(e);if(r===!0)oy(e,n,Gv(e.name||n,o.value,this));else return Ck(n).apply(null,arguments)};Bt.bound=NK;function kK(t,e){var n=typeof t=="string"?t:t.name||"<unnamed action>",o=typeof t=="function"?t:e;return I3(n,o,this,void 0)}function ZO(t,e,n){oy(t,e,Gv(e,n.bind(t)))}function PK(t,e){e===void 0&&(e=yM);var n=e&&e.name||t.name||"Autorun@"+Hs(),o=!e.scheduler&&!e.delay,r;if(o)r=new A_(n
|
|||
|
|
L`).concat(i.rightX," ").concat(i.rightY,`
|
|||
|
|
L`).concat(a.rightX," ").concat(a.rightY,`
|
|||
|
|
L`).concat(a.leftX," ").concat(a.leftY," z")}return{d:o,fill:"transparent",stroke:"transparent",strokeWidth:1,strokeDasharray:"4, 4"}},yP=function(t){var e=t.start,n=t.end,o=t.sourceNode,r=t.targetNode,i=t.offset,a=gu(o),s=gu(r),l=Nw(a,i),f=Nw(s,i),h=kw(l,a,e),v=kw(f,s,n);return{sNext:h,ePre:v}},CM=function(t){var e=t.replace(/M/g,"").replace(/C/g,",").split(","),n=b0(e[0]),o=b0(e[1]),r=b0(e[2]),i=b0(e[3]);return[n,o,r,i]},b0=function(t){var e=Yu(t.replace(/(^\s*)/g,"").split(" "),2),n=e[0],o=e[1];return{x:+n,y:+o}},_P=function(t,e){var n=Yu(t,4),o=n[0],r=n[1],i=n[2],a=n[3],s=WJ(o,r,i,a,e);return[s,t[3]]},gI=function(t,e){for(var n=t.x,o=t.y,r=Kv(e),i=Number.MAX_SAFE_INTEGER,a,s=[],l=0;l<r.length;l++)s.push({start:r[l],end:r[(l+1)%r.length]});if(s.forEach(function(b){var E=b.start,O=b.end;if(E.x===O.x){var w={x:E.x,y:o},S=T_(w,E,O);if(S){var M=Math.abs(E.x-n);M<i&&(i=M,a=w)}}else if(E.y===O.y){var w={x:n,y:E.y},S=T_(w,E,O);if(S){var M=Math.abs(E.y-o);M<i&&(i=M,a=w)}}}),!a){var f=s[0],h=f.start,v=f.end;a={x:h.x+(v.x-h.x)/2,y:h.y+(v.y-h.y)/2}}return a},eJ=function(t){return Vv(t,["id","type","sourceNodeId","sourceAnchorId","targetNodeId","targetAnchorId","pointsList","startPoint","endPoint","properties"])},bP=function(t,e){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))};function tJ(t,e){return typeof e!="function"?function(n,o,r){return Object.assign({type:t.edgeType},r)}:function(n,o,r){var i=e(n,o,r);return i?typeof i=="string"?Object.assign({},r,{type:i}):Object.assign({type:i},r):{type:t.edgeType}}}var nJ=function(t){var e=t.rows,n=t.rowsLength,o=t.fontSize,r=0;return ri(e,function(i){var a=mI(i);r=a>r?a:r}),{width:Math.ceil(r/2)*o+o/4,height:n*(o+2)+o/4}},ng=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},w0=function(t,e,n){if(n||arguments.length===2)for(var o=0,r=e.length,i;o<r;o++)(i||!(o in e))&&(i||(i=Array.prototype.slice.call(e,0,o)),i[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))};function Wg(t,e,n){return n&&e*Math.round(t/e)||t}function rJ(t,e,n){if(!t)return[];var o=Math.min.apply(Math,w0([],ng(t.map(function(w){return w[0]})),!1)),r=Math.max.apply(Math,w0([],ng(t.map(function(w){return w[0]})),!1)),i=Math.min.apply(Math,w0([],ng(t.map(function(w){return w[1]})),!1)),a=Math.max.apply(Math,w0([],ng(t.map(function(w){return w[1]})),!1)),s=-o,l=-i,f=t.map(function(w){var S=ng(w,2),M=S[0],T=S[1];return[M+s,T+l]}),h=r-o,v=a-i,b=e?e/h:1,E=n?n/v:1,O=Math.min(b,E);return f.map(function(w){var S=ng(w,2),M=S[0],T=S[1];return[M*O,T*O]})}var eS=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},tS=function(t,e,n){var o=eS(t,2),r=o[0],i=o[1],a=eS(e,2),s=a[0],l=a[1],f=eS(n,2),h=f[0],v=f[1];return r>s&&r<h&&i>l&&i<v},yI=function(t,e){var n=e.multipleSelectKey,o=!1;switch(n){case"meta":o=t.metaKey;break;case"alt":o=t.altKey;break;case"shift":o=t.shiftKey;break;case"ctrl":o=t.ctrlKey;break;default:o=!1;break}return o},NM=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})();function wP(t,e){return t instanceof Il&&e instanceof Il}var _I=(function(t){NM(e,t);function e(n,o,r){var i=t.call(this,3)||this;return i[0]=n,i[1]=o,i[2]=r,i.x=n,i.y=o,i.z=r,Object.setPrototypeOf(i,e.prototype),i}return e.prototype.add=function(n){if(wP(this,n)
|
|||
|
|
C `).concat(i.x," ").concat(i.y,`,
|
|||
|
|
`).concat(a.x," ").concat(a.y,`,
|
|||
|
|
`).concat(s.x," ").concat(s.y)},e.prototype.initPoints=function(){this.pointsList.length>0?this.path=this.getPath(this.pointsList):this.updatePoints()},e.prototype.updatePoints=function(){var n=this.getControls(),o=n.sNext,r=n.ePre;this.updatePath(o,r)},e.prototype.updatePath=function(n,o){n=to(n),o=to(o);var r={x:this.startPoint.x,y:this.startPoint.y},i={x:this.endPoint.x,y:this.endPoint.y};if(!n||!o){var a=this.getControls();n=a.sNext,o=a.ePre}this.pointsList=[r,n,o,i],this.path=this.getPath(this.pointsList)},e.prototype.updateStartPoint=function(n){this.startPoint=Object.assign({},n),this.updatePoints()},e.prototype.updateEndPoint=function(n){this.endPoint=Object.assign({},n),this.updatePoints()},e.prototype.moveStartPoint=function(n,o){this.startPoint.x+=n,this.startPoint.y+=o;var r=rS(this.pointsList,3),i=r[1],a=r[2];i.x+=n,i.y+=o,this.updatePath(i,a)},e.prototype.moveEndPoint=function(n,o){this.endPoint.x+=n,this.endPoint.y+=o;var r=rS(this.pointsList,3),i=r[1],a=r[2];a.x+=n,a.y+=o,this.updatePath(i,a)},e.prototype.updateAdjustAnchor=function(n,o){var r;o==="sNext"?this.pointsList[1]=n:o==="ePre"&&(this.pointsList[2]=n),this.path=this.getPath(this.pointsList),!((r=this.text)===null||r===void 0)&&r.value&&this.setText(Xo({},this.text,this.textPosition))},e.prototype.getAdjustStart=function(){return this.pointsList[0]||this.startPoint},e.prototype.getAdjustEnd=function(){var n=this.pointsList;return n[n.length-1]||this.endPoint},e.prototype.updateAfterAdjustStartAndEnd=function(n){var o=n.startPoint,r=n.endPoint,i=n.sourceNode,a=n.targetNode,s=yP({start:o,end:r,sourceNode:i,targetNode:a,offset:this.offset}),l=s.sNext,f=s.ePre;this.pointsList=[o,l,f,r],this.initPoints()},Uu([Ut],e.prototype,"offset",void 0),Uu([Ut],e.prototype,"path",void 0),Uu([Bt],e.prototype,"initPoints",null),Uu([Bt],e.prototype,"updatePoints",null),Uu([Bt],e.prototype,"updateStartPoint",null),Uu([Bt],e.prototype,"updateEndPoint",null),Uu([Bt],e.prototype,"moveStartPoint",null),Uu([Bt],e.prototype,"moveEndPoint",null),Uu([Bt],e.prototype,"updateAdjustAnchor",null),Uu([Bt],e.prototype,"getAdjustStart",null),Uu([Bt],e.prototype,"getAdjustEnd",null),Uu([Bt],e.prototype,"updateAfterAdjustStartAndEnd",null),e})(K1),cQ=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),n_=function(){return n_=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},n_.apply(this,arguments)},NP=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},dQ=function(t,e,n){if(n||arguments.length===2)for(var o=0,r=e.length,i;o<r;o++)(i||!(o in e))&&(i||(i=Array.prototype.slice.call(e,0,o)),i[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))},kP=(function(t){cQ(e,t);function e(){var n=t.apply(this,dQ([],NP(arguments),!1))||this;return n.modelType=_o.LINE_EDGE,n}return e.prototype.getEdgeStyle=function(){var n=this.graphModel.theme.line,o=t.prototype.getEdgeStyle.call(this),r=this.properties.style,i=r===void 0?{}:r;return n_(n_(n_({},o),to(n)),to(i))},e.prototype.initEdgeData=function(n){t.prototype.initEdgeData.call(this,n),this.points=this.getPath([this.startPoint,this.endPoint])},e.prototype.getPath=function(n){var o=NP(n,2),r=o[0],i=o[1];return"".concat(r.x,",").concat(r.y," ").concat(i.x,",").concat(i.y)},e.prototype.getTextPosition=function(){return{x:(this.startPoint.x+this.endPoint.x)/2,y:(this.startPoint.y+this.endPo
|
|||
|
|
Copyright (c) 2018 Jed Watson.
|
|||
|
|
Licensed under the MIT License (MIT), see
|
|||
|
|
http://jedwatson.github.io/classnames
|
|||
|
|
*/var IP;function vee(){return IP||(IP=1,(function(t){(function(){var e={}.hasOwnProperty;function n(){for(var i="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(i=r(i,o(s)))}return i}function o(i){if(typeof i=="string"||typeof i=="number")return i;if(typeof i!="object")return"";if(Array.isArray(i))return n.apply(null,i);if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]"))return i.toString();var a="";for(var s in i)e.call(i,s)&&i[s]&&(a=r(a,s));return a}function r(i,a){return a?i?i+" "+a:i+a:i}t.exports?(n.default=n,t.exports=n):window.classNames=n})()})(aS)),aS.exports}var mee=vee();const ZA=Z_(mee);var gee=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),JA=function(){return JA=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},JA.apply(this,arguments)},yee=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},TI=(function(t){gee(e,t);function e(n){var o=t.call(this)||this;o.mouseDownHandler=function(i){var a=o.props,s=a.draggable,l=a.model,f=a.graphModel,h=f.editConfigModel.nodeTextDraggable;(s??h)&&(i.stopPropagation(),o.stepperDrag.model=l,o.stepperDrag.handleMouseDown(i))},o.onDragging=function(i){var a=i.deltaX,s=i.deltaY,l=o.props,f=l.model,h=l.graphModel.transformModel;if(a||s){var v=yee(h.fixDeltaXY(a,s),2),b=v[0],E=v[1];f.moveText(b,E)}},o.dbClickHandler=function(){var i=o.props,a=i.editable,s=i.graphModel.eventCenter,l=i.model;a&&l.setElementState(Wo.TEXT_EDIT),s.emit(pr.TEXT_DBCLICK,{data:l.text,model:l})};var r=n.draggable;return o.stepperDrag=new ac({onDragging:o.onDragging,step:1,eventType:"TEXT",isStopPropagation:r}),o}return e.prototype.getShape=function(){var n=this.props,o=n.model,r=n.graphModel,i=r.editConfigModel,a=o.text,s=a.value,l=a.x,f=a.y,h=a.editable,v=a.draggable,b={x:l,y:f,className:"",value:s},E=o.getTextStyle(),O=i.nodeTextDraggable||v;return $t(EI,JA({},b,E,{className:ZA({"lf-element-text":h,"lf-text-draggable":!h&&O,"lf-text-disabled":!h&&!O}),model:o}))},e.prototype.render=function(){var n=this.props.model.text;if(n)return $t("g",{onMouseDown:this.mouseDownHandler,onDblClick:this.dbClickHandler,children:this.getShape()})},e})(ko),_ee=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),Wc=function(){return Wc=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},Wc.apply(this,arguments)},C0=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},bee=(function(t){_ee(e,t);function e(n){var o=t.call(this,n)||this;return o.setHoverOn=function(){o.setState({isHovered:!0})},o.setHoverOff=function(){o.setState({isHovered:!1})},o.state={isHovered:!1},o}return
|
|||
|
|
L`).concat(s.rightX," ").concat(s.rightY,`
|
|||
|
|
L`).concat(l.rightX," ").concat(l.rightY,`
|
|||
|
|
L`).concat(l.leftX," ").concat(l.leftY," z")}return{d:i,fill:"transparent",stroke:"transparent",strokeWidth:1,strokeDasharray:"4, 4"}},e.prototype.getAppendShape=function(n){var o=this.getAppendAttributes(n),r=o.d,i=o.strokeWidth,a=o.fill,s=o.strokeDasharray,l=o.stroke;return $t(P_,{d:r,fill:a,strokeWidth:i,stroke:l,strokeDasharray:s})},e.prototype.getAppendWidth=function(){for(var n=this,o=this.props,r=o.model,i=o.graphModel,a=r.pointsList,s=r.draggable,l=[],f=a.length,h=function(E){var O="lf-polyline-append",w={start:{x:a[E].x,y:a[E].y},end:{x:a[E+1].x,y:a[E+1].y},startIndex:E,endIndex:E+1,direction:ni.HORIZONTAL,draggable:!0},S=$t("g",{className:O,children:v.getAppendShape(w)}),M=i.editConfigModel,T=M.adjustEdge,$=M.adjustEdgeMiddle;if(T&&s){var D=w.startIndex,P=w.endIndex,B=$&&(D===0||P===f-1);w.draggable=!B,w.start.x===w.end.x?(w.draggable&&(O+="-ew-resize"),w.direction=ni.VERTICAL):w.start.y===w.end.y&&(w.draggable&&(O+="-ns-resize"),w.direction=ni.HORIZONTAL),S=$t("g",{className:v.isDragging?"lf-dragging":"lf-drag-able",onMouseDown:function(F){return n.beforeDragStart(F,w)},children:$t("g",{className:O,children:v.getAppendShape(w)})})}l.push(S)},v=this,b=0;b<f-1;b++)h(b);return $t("g",{children:l})},e})(Z1),wg=function(){return wg=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},wg.apply(this,arguments)},Wee=(function(){function t(e){var n=this;this.nodeConfig=null,this.fakeNode=null,this.stopDrag=function(){n.nodeConfig=null,window.document.removeEventListener("mouseup",n.stopDrag)},this.dragEnter=function(r){!n.nodeConfig||n.fakeNode||(n.fakeNode=n.lf.createFakeNode(wg(wg({},n.nodeConfig),n.clientToLocalPoint({x:r.clientX,y:r.clientY}))))},this.onDragOver=function(r){if(n.lf.graphModel.eventCenter.emit(pr.BLANK_CANVAS_MOUSEMOVE,{e:r}),r.preventDefault(),n.fakeNode){var i=n.clientToLocalPoint({x:r.clientX,y:r.clientY}),a=i.x,s=i.y;n.fakeNode.moveTo(a,s);var l=n.fakeNode.getData();n.lf.setNodeSnapLine(l),n.lf.graphModel.eventCenter.emit(pr.NODE_DND_DRAG,{data:l,e:r})}return!1},this.onDragLeave=function(){n.fakeNode&&(n.lf.removeNodeSnapLine(),n.lf.graphModel.removeFakeNode(),n.fakeNode=null)},this.onDrop=function(r){!n.lf.graphModel||!r||!n.nodeConfig||(n.lf.addNode(wg(wg({},n.nodeConfig),n.clientToLocalPoint({x:r.clientX,y:r.clientY})),pr.NODE_DND_ADD,r),r.preventDefault(),r.stopPropagation(),n.nodeConfig=null,n.lf.removeNodeSnapLine(),n.lf.graphModel.removeFakeNode(),n.fakeNode=null)};var o=e.lf;this.lf=o}return t.prototype.clientToLocalPoint=function(e){var n=e.x,o=e.y,r=om(this.lf.options,["grid","size"]),i=this.lf.graphModel.getPointByClient({x:n,y:o}),a=i.canvasOverlayPosition,s=a.x,l=a.y,f=this.lf.graphModel.editConfigModel.snapGrid;return{x:Wg(s,r,f),y:Wg(l,r,f)}},t.prototype.startDrag=function(e){var n=this.lf.graphModel.editConfigModel;n!=null&&n.isSilentMode||(this.nodeConfig=e,window.document.addEventListener("mouseup",this.stopDrag))},t.prototype.eventMap=function(){return{onMouseEnter:this.dragEnter,onMouseOver:this.dragEnter,onMouseMove:this.onDragOver,onMouseLeave:this.onDragLeave,onMouseUp:this.onDrop}},t})();function Gee(t,e){t.on("node:mousemove",function(n){var o=n.data;e.setNodeSnapLine(o)}),t.on("node:mouseup",function(){e.clearSnapline()})}var zee=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),np=function(){return np=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},np.apply(this,arguments)},Hee=function(t,e,n,o){var r=arguments.length,i=r<3
|
|||
|
|
`;function Z0(t,e,n){var o=yte(n);if(t!==0&&t!==!1&&!t)return Tv+o+"<".concat(e," />");var r="";if(e==="#text")return Tv+o+Jw(String(t));if(e==="#cdata-section")return Tv+o+"<![CDATA["+t+"]]>";if(e==="#comment")return Tv+o+"<!--"+t+"-->";if("".concat(e).charAt(0)==="-")return" "+e.substring(1)+'="'+_te(t)+'"';if(Array.isArray(t))t.forEach(function(l){r+=Z0(l,e,n+1)});else if(II(t)==="[object Object]"){var i=Object.keys(t),a="",s="";r+=(n===0?"":Tv+o)+"<"+e,i.forEach(function(l){l.charAt(0)==="-"?a+=Z0(t[l],l,n+1):s+=Z0(t[l],l,n+1)}),r+=a+(s!==""?">".concat(s).concat(Tv+o,"</").concat(e,">"):" />")}else r+=Tv+o+"<".concat(e,">").concat(Jw(String(t)),"</").concat(e,">");return r}function bte(t){var e="";for(var n in t)e+=Z0(t[n],n,0);return e}var As=function(){};As.ObjTree=function(){return this};As.ObjTree.VERSION="0.23";As.ObjTree.prototype.xmlDecl=`<?xml version="1.0" encoding="UTF-8" ?>
|
|||
|
|
`;As.ObjTree.prototype.attr_prefix="-";As.ObjTree.prototype.parseXML=function(t){var e;if(window.DOMParser){var n=new DOMParser,o=n.parseFromString(t,"application/xml");if(!o)return;e=o.documentElement}else window.ActiveXObject&&(n=new ActiveXObject("Microsoft.XMLDOM"),n.async=!1,n.loadXML(t),e=n.documentElement);if(e)return this.parseDOM(e)};As.ObjTree.prototype.parseHTTP=function(t,e,n){var o={};for(var r in e)o[r]=e[r];if(o.method||(typeof o.postBody>"u"&&typeof o.postbody>"u"&&typeof o.parameters>"u"?o.method="get":o.method="post"),n){o.asynchronous=!0;var i=this,a=n,s=o.onComplete;o.onComplete=function(h){var v;h&&h.responseXML&&h.responseXML.documentElement&&(v=i.parseDOM(h.responseXML.documentElement)),a(v,h),s&&s(h)}}else o.asynchronous=!1;var l;if(typeof HTTP<"u"&&HTTP.Request){o.uri=t;var f=new HTTP.Request(o);f&&(l=f.transport)}else if(typeof Ajax<"u"&&Ajax.Request){var f=new Ajax.Request(t,o);f&&(l=f.transport)}if(n)return l;if(l&&l.responseXML&&l.responseXML.documentElement)return this.parseDOM(l.responseXML.documentElement)};As.ObjTree.prototype.parseDOM=function(t){if(t){if(this.__force_array={},this.force_array)for(var e=0;e<this.force_array.length;e++)this.__force_array[this.force_array[e]]=1;var n=this.parseElement(t);if(this.__force_array[t.nodeName]&&(n=[n]),t.nodeType!=11){var o={};o[t.nodeName]=n,n=o}return n}};As.ObjTree.prototype.parseElement=function(t){if(t.nodeType!=7){if(t.nodeType==3||t.nodeType==4||t.nodeType==8){var e=t.nodeValue.match(/[^\x00-\x20]/);return e==null?void 0:t.nodeValue}var n=null,o={};if(t.attributes&&t.attributes.length){n={};for(var r=0;r<t.attributes.length;r++){var i=t.attributes[r].nodeName;if(typeof i=="string"){var a=t.attributes[r].nodeValue;try{a=JSON.parse(t.attributes[r].nodeValue.replace(/'/g,'"'))}catch{a=t.attributes[r].nodeValue}a&&(i=this.attr_prefix+i,typeof o[i]>"u"&&(o[i]=0),o[i]++,this.addNode(n,i,o[i],a))}}}if(t.childNodes&&t.childNodes.length){var s=!0;n&&(s=!1);for(var r=0;r<t.childNodes.length&&s;r++){var l=t.childNodes[r].nodeType;l==3||l==4||l==8||(s=!1)}if(s){n||(n="");for(var r=0;r<t.childNodes.length;r++)n+=t.childNodes[r].nodeValue}else{n||(n={});for(var r=0;r<t.childNodes.length;r++){var i=t.childNodes[r].nodeName;if(typeof i=="string"){var a=this.parseElement(t.childNodes[r]);a&&(typeof o[i]>"u"&&(o[i]=0),o[i]++,this.addNode(n,i,o[i],a))}}}}else n===null&&(n={});return n}};As.ObjTree.prototype.addNode=function(t,e,n,o){this.__force_array[e]?(n==1&&(t[e]=[]),t[e][t[e].length]=o):n==1?t[e]=o:n==2?t[e]=[t[e],o]:t[e][t[e].length]=o};As.ObjTree.prototype.writeXML=function(t){var e=this.hash_to_xml(null,t);return this.xmlDecl+e};As.ObjTree.prototype.hash_to_xml=function(t,e){var n=[],o=[];for(var r in e)if(e.hasOwnProperty(r)){var i=e[r];r.charAt(0)!=this.attr_prefix?typeof i>"u"||i==null?n[n.length]="<"+r+" />":typeof i=="object"&&i.constructor==Array?n[n.length]=this.array_to_xml(r,i):typeof i=="object"?n[n.length]=this.hash_to_xml(r,i):n[n.length]=this.scalar_to_xml(r,i):o[o.length]=" "+r.substring(1)+'="'+this.xml_escape(i)+'"'}var a=o.join(""),s=n.join("");return typeof t>"u"||t==null||(n.length>0?s.match(/\n/)?s="<"+t+a+`>
|
|||
|
|
`+s+"</"+t+`>
|
|||
|
|
`:s="<"+t+a+">"+s+"</"+t+`>
|
|||
|
|
`:s="<"+t+a+` />
|
|||
|
|
`),s};As.ObjTree.prototype.array_to_xml=function(t,e){for(var n=[],o=0;o<e.length;o++){var r=e[o];typeof r>"u"||r==null?n[n.length]="<"+t+" />":typeof r=="object"&&r.constructor==Array?n[n.length]=this.array_to_xml(t,r):typeof r=="object"?n[n.length]=this.hash_to_xml(t,r):n[n.length]=this.scalar_to_xml(t,r)}return n.join("")};As.ObjTree.prototype.scalar_to_xml=function(t,e){return t=="#text"?this.xml_escape(e):"<"+t+">"+this.xml_escape(e)+"</"+t+`>
|
|||
|
|
`};As.ObjTree.prototype.xml_escape=Jw;var wte=function(t){return new As.ObjTree().parseXML(t)},Ete=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),f2=function(){return f2=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},f2.apply(this,arguments)},J1=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},Xd;(function(t){t.START="bpmn:startEvent",t.END="bpmn:endEvent",t.GATEWAY="bpmn:exclusiveGateway",t.USER="bpmn:userTask",t.SYSTEM="bpmn:serviceTask",t.FLOW="bpmn:sequenceFlow"})(Xd||(Xd={}));var FI=["-name","-id","bpmn:incoming","bpmn:outgoing","-sourceRef","-targetRef"],YP=["properties","startPoint","endPoint","pointsList"],BI=function(t){return String(t||"").replace(/</g,"<").replace(/>/g,">").replace(/&/g,"&").replace(/"/g,'"').replace(/'/g,"'")};function qP(t){var e=t?YP.concat(t):YP;return function(n){function o(r){var i={};return typeof r=="string"?r:Array.isArray(r)?r.map(function(a){return o(a)}):(Object.entries(r).forEach(function(a){var s=J1(a,2),l=s[0],f=s[1];typeof f!="object"?l.indexOf("-")===0||["#text","#cdata-section","#comment"].includes(l)?i[l]=f:i["-".concat(l)]=f:e.includes(l)?i["-".concat(l)]=o(f):i[l]=o(f)}),i)}return o(n)}}function Qw(t){var e={};return Object.entries(t).forEach(function(n){var o=J1(n,2),r=o[0],i=o[1];r.indexOf("-")===0?e[r.substring(1)]=Zw(i):typeof i=="string"?e[r]=i:Object.prototype.toString.call(i)==="[object Object]"?e[r]=Qw(i):Array.isArray(i)?e[r]=i.map(function(a){return Qw(a)}):e[r]=i}),e}function xte(t,e,n){var o=new Map;e.nodes.forEach(function(i){var a,s={"-id":i.id};if(!((a=i.text)===null||a===void 0)&&a.value&&(s["-name"]=i.text.value),i.properties){var l=qP(n)(i.properties);Object.assign(s,l)}o.set(i.id,s),t[i.type]?Array.isArray(t[i.type])?t[i.type].push(s):t[i.type]=[t[i.type],s]:t[i.type]=s});var r=e.edges.map(function(i){var a,s,l=o.get(i.targetNodeId);l["bpmn:incoming"]?Array.isArray(l["bpmn:incoming"])?l["bpmn:incoming"].push(i.id):l["bpmn:incoming"]=[l["bpmn:incoming"],i.id]:l["bpmn:incoming"]=i.id;var f={"-id":i.id,"-sourceRef":i.sourceNodeId,"-targetRef":i.targetNodeId};if(!((a=i.text)===null||a===void 0)&&a.value&&(f["-name"]=(s=i.text)===null||s===void 0?void 0:s.value),i.properties){var h=qP(n)(i.properties);Object.assign(f,h)}return f});e.edges.forEach(function(i){var a=o.get(i.sourceNodeId);a["bpmn:outgoing"]?Array.isArray(a["bpmn:outgoing"])?a["bpmn:outgoing"].push(i.id):a["bpmn:outgoing"]=[a["bpmn:outgoing"],i.id]:a["bpmn:outgoing"]=i.id}),t[Xd.FLOW]=r}function Ote(t,e){t["bpmndi:BPMNEdge"]=e.edges.map(function(n){var o,r=n.id,i=n.pointsList.map(function(s){var l=s.x,f=s.y;return{"-x":l,"-y":f}}),a={"-id":"".concat(r,"_di"),"-bpmnElement":r,"di:waypoint":i};return!((o=n.text)===null||o===void 0)&&o.value&&(a["bpmndi:BPMNLabel"]={"dc:Bounds":{"-x":n.text.x-n.text.value.length*10/2,"-y":n.text.y-7,"-width":n.text.value.length*10,"-height":14}}),a}),t["bpmndi:BPMNShape"]=e.nodes.map(function(n){var o,r=n.id,i=100,a=80,s=n.x,l=n.y,f=Fh.shapeConfigMap.get(n.type);f&&(i=f.width,a=f.height),s-=i/2,l-=a/2;var h={"-id":"".concat(r,"_di"),"-bpmnElement":r,"dc:Bounds":{"-x":s,"-y":l,"-width":i,"-height":a}};return!((o=n.text)===null||o===void 0)&&o.value&&(h["bpmndi:BPMNLabel"]={"dc:Bounds":{"-x":n.text.x-n.text.value.length*10/2,"-y":n.text.y-7,"-width":n.text.value.length*10,"-height":14}})
|
|||
|
|
`).forEach(function(E){i<E.length&&(i=E.length)}),r)n={value:o,x:Number(r["-x"])+i*10/2,y:Number(r["-y"])+7};else{var a=t["di:waypoint"]||[],s=a[0],l=a[a.length-1]||s,f=(Number((s==null?void 0:s["-x"])||0)+Number((l==null?void 0:l["-x"])||0))/2,h=(Number((s==null?void 0:s["-y"])||0)+Number((l==null?void 0:l["-y"])||0))/2;n={value:o,x:f,y:h}}}var v;Object.entries(e).forEach(function(E){var O=J1(E,2),w=O[0],S=O[1];FI.indexOf(w)===-1&&(v||(v={}),v[w]=S)}),v&&(v=Qw(v));var b={id:e["-id"],type:Xd.FLOW,pointsList:t["di:waypoint"].map(function(E){return{x:Number(E["-x"]),y:Number(E["-y"])}}),sourceNodeId:e["-sourceRef"],targetNodeId:e["-targetRef"],properties:v};return n&&(b.text=n),b}var Fh=(function(){function t(e){var n=e.lf,o=this;this.adapterOut=function(r,i){var a=f2({},o.processAttributes);xte(a,r,i);var s={"-id":"BPMNPlane_1","-bpmnElement":a["-id"]};Ote(s,r);var l=o.definitionAttributes;l["bpmn:process"]=a,l["bpmndi:BPMNDiagram"]={"-id":"BPMNDiagram_1","bpmndi:BPMNPlane":s};var f={"bpmn:definitions":l};return f},this.adapterIn=function(r){if(r)return Ste(r)},n.adapterIn=function(r){return o.adapterIn(r)},n.adapterOut=function(r,i){return o.adapterOut(r,i)},this.processAttributes={"-isExecutable":"true","-id":"Process_".concat(XP())},this.definitionAttributes={"-id":"Definitions_".concat(XP()),"-xmlns:xsi":"http://www.w3.org/2001/XMLSchema-instance","-xmlns:bpmn":"http://www.omg.org/spec/BPMN/20100524/MODEL","-xmlns:bpmndi":"http://www.omg.org/spec/BPMN/20100524/DI","-xmlns:dc":"http://www.omg.org/spec/DD/20100524/DC","-xmlns:di":"http://www.omg.org/spec/DD/20100524/DI","-targetNamespace":"http://logic-flow.org","-exporter":"logicflow","-exporterVersion":"1.2.0"}}return t.prototype.setCustomShape=function(e,n){t.shapeConfigMap.set(e,n)},t.pluginName="bpmn-adapter",t.shapeConfigMap=new Map,t})();Fh.shapeConfigMap.set(Xd.START,{width:gk.width,height:gk.height});Fh.shapeConfigMap.set(Xd.END,{width:yk.width,height:yk.height});Fh.shapeConfigMap.set(Xd.GATEWAY,{width:_k.width,height:_k.height});Fh.shapeConfigMap.set(Xd.SYSTEM,{width:bk.width,height:bk.height});Fh.shapeConfigMap.set(Xd.USER,{width:wk.width,height:wk.height});(function(t){Ete(e,t);function e(n){var o=t.call(this,n)||this;o.adapterXmlIn=function(i){var a=typeof i=="string"?o.sanitizeNameAttributes(i):i,s=wte(a);return o.adapterIn(s)},o.adapterXmlOut=function(i,a){var s=o.adapterOut(i,a);return bte(s)};var r=n.lf;return r.adapterIn=o.adapterXmlIn,r.adapterOut=o.adapterXmlOut,o}return e.prototype.sanitizeNameAttributes=function(n){return n.replace(/name="([^"]*)"/g,function(o,r){var i=r.replace(/&(?!#?\w+;)/g,"&").replace(/</g,"<").replace(/>/g,">");return'name="'.concat(i,'"')})},e.pluginName="bpmnXmlAdapter",e})(Fh);var Tte=(function(){function t(){globalThis._ids=this,this._ids=new Set}return t.prototype.generateId=function(){var e="xxxxxxx".replace(/[x]/g,function(n){var o=Math.random()*16|0,r=n==="x"?o:o&3|8;return r.toString(16)});return e},t.prototype.next=function(){for(var e=this.generateId();this._ids.has(e);)e=this.generateId();return this._ids.add(e),e},t})(),Cte=(globalThis==null?void 0:globalThis._ids)||new Tte;function Nte(){return Cte.next()}Lr("circle",{cx:18,cy:18,r:11,style:"stroke-linecap: round;stroke-linejoin: round;stroke: rgb(34, 36, 42);stroke-width: 2px;fill: white"}),Lr("path",{d:"M 18,18 l 2.25,-7.5 m -2.25,7.5 l 5.25,1.5",style:"fill: none; stroke-linecap: round; stroke-linejoin: round; stroke: rgb(34, 36, 42); stroke-width: 2px;"}),Lr("path",{d:"M 18,18 m 0,7.5 l -0,2.25",transform:"rotate(0,18,18)",style:"fill: none; stroke-linecap: round; stroke-linejoin: round; stroke: rgb(34, 36, 42); stroke-width: 1px;"}),Lr("path",{d:"M 18,18 m 0,7.5 l -0,2.25",transform:"rotate(30,18,18)",style:"fill: none; stroke-linecap: round; stroke-linejoin: round; stroke: rgb(34, 36, 42); stroke-width: 1px;"}),Lr("path",{d:"M 18,18 m 0,7.5 l -0,2.25",transform:"rotate(60,18,18)",style:"fill: none; stroke-linecap: round; stroke-linejoin: round; stroke: rgb(34, 36, 42); stroke-width: 1px;"}),Lr("path",{d:"M 18,18 m 0,7.5 l -0,2.25",transform:"rot
|
|||
|
|
`;function J0(t,e,n){var o=cR(n),r="",i=dR+o;if(e==="-json")return"";if(e==="#text")return i+o1(String(t));if(e==="#cdata-section")return"".concat(i,"<![CDATA[").concat(t,"]]>");if(e==="#comment")return"".concat(i,"<!--").concat(t,"-->");if(t!==0&&t!==!1&&!t)return"".concat(i,"<").concat(e," />");if("".concat(e).charAt(0)==="-")return" ".concat(e.substring(1),'="').concat(Vte(t),'"');if(Array.isArray(t))r+=t.map(function(f){return J0(f,e,n+1)}).join("");else if(HI(t)==="[object Object]"){var a=Object.keys(t),s="",l=t["-json"]?dR+cR(n+1)+t["-json"]:"";r+="".concat(n===0?"":i,"<").concat(e),a.forEach(function(f){f.charAt(0)==="-"?s+=J0(t[f],f,n+1):l+=J0(t[f],f,n+1)}),r+=s+(l!==""?">".concat(l).concat(i,"</").concat(e,">"):" />")}else r+="".concat(i,"<").concat(e,">").concat(o1(String(t)),"</").concat(e,">");return r}function Wte(t){var e="";for(var n in t)e+=J0(t[n],n,0);return e}var Ms=function(){};Ms.ObjTree=function(){return this};Ms.ObjTree.VERSION="0.23";Ms.ObjTree.prototype.xmlDecl=`<?xml version="1.0" encoding="UTF-8" ?>
|
|||
|
|
`;Ms.ObjTree.prototype.attr_prefix="-";Ms.ObjTree.prototype.parseXML=function(t){var e;if(window.DOMParser){var n=new DOMParser,o=n.parseFromString(t,"application/xml");if(!o)return;e=o.documentElement}else window.ActiveXObject&&(n=new ActiveXObject("Microsoft.XMLDOM"),n.async=!1,n.loadXML(t),e=n.documentElement);if(e){var r=this.parseDOM(e);return r}};Ms.ObjTree.prototype.parseHTTP=function(t,e,n){var o={};for(var r in e)o[r]=e[r];if(o.method||(typeof o.postBody>"u"&&typeof o.postbody>"u"&&typeof o.parameters>"u"?o.method="get":o.method="post"),n){o.asynchronous=!0;var i=this,a=n,s=o.onComplete;o.onComplete=function(h){var v;h&&h.responseXML&&h.responseXML.documentElement&&(v=i.parseDOM(h.responseXML.documentElement)),a(v,h),s&&s(h)}}else o.asynchronous=!1;var l;if(typeof HTTP<"u"&&HTTP.Request){o.uri=t;var f=new HTTP.Request(o);f&&(l=f.transport)}else if(typeof Ajax<"u"&&Ajax.Request){var f=new Ajax.Request(t,o);f&&(l=f.transport)}if(n)return l;if(l&&l.responseXML&&l.responseXML.documentElement)return this.parseDOM(l.responseXML.documentElement)};Ms.ObjTree.prototype.parseDOM=function(t){if(t){if(this.__force_array={},this.force_array)for(var e=0;e<this.force_array.length;e++)this.__force_array[this.force_array[e]]=1;var n=this.parseElement(t);if(this.__force_array[t.nodeName]&&(n=[n]),t.nodeType!==11){var o={};o[t.nodeName]=n,n=o}return n}};Ms.ObjTree.prototype.parseElement=function(t){if(t.nodeType!==7){if(t.nodeType===3||t.nodeType===4||t.nodeType===8){var e=t.nodeValue.match(/[^\x00-\x20]/);return e==null?void 0:t.nodeValue}var n=null,o={};if(t.attributes&&t.attributes.length){n={};for(var r=0;r<t.attributes.length;r++){var i=t.attributes[r].nodeName;if(typeof i=="string"){var a=t.attributes[r].nodeValue;try{a=JSON.parse(t.attributes[r].nodeValue.replace(/'/g,'"'))}catch{a=t.attributes[r].nodeValue}a!=null&&(i=this.attr_prefix+i,typeof o[i]>"u"&&(o[i]=0),o[i]++,this.addNode(n,i,o[i],a))}}}if(t.childNodes&&t.childNodes.length){var s=!0;n&&(s=!1);for(var r=0;r<t.childNodes.length&&s;r++){var l=t.childNodes[r].nodeType;l===3||l===4||l===8||(s=!1)}if(s){n||(n="");for(var r=0;r<t.childNodes.length;r++)n+=t.childNodes[r].nodeValue}else{n||(n={});for(var r=0;r<t.childNodes.length;r++){var i=t.childNodes[r].nodeName;if(typeof i=="string"){var a=this.parseElement(t.childNodes[r]);a&&(typeof o[i]>"u"&&(o[i]=0),o[i]++,this.addNode(n,i,o[i],a))}}}}else n===null&&(n={});return n}};Ms.ObjTree.prototype.addNode=function(t,e,n,o){this.__force_array[e]?(n===1&&(t[e]=[]),t[e][t[e].length]=o):n===1?t[e]=o:n===2?t[e]=[t[e],o]:t[e][t[e].length]=o};Ms.ObjTree.prototype.writeXML=function(t){var e=this.hash_to_xml(null,t);return this.xmlDecl+e};Ms.ObjTree.prototype.hash_to_xml=function(t,e){var n=[],o=[];for(var r in e)if(hw(e,r)){var i=e[r];r.charAt(0)!==this.attr_prefix?typeof i>"u"||i==null?n[n.length]="<".concat(r," />"):typeof i=="object"&&i.constructor===Array?n[n.length]=this.array_to_xml(r,i):typeof i=="object"?n[n.length]=this.hash_to_xml(r,i):n[n.length]=this.scalar_to_xml(r,i):o[o.length]=" ".concat(r.substring(1),'="').concat(this.xml_escape(i),'"')}var a=o.join(""),s=n.join("");return typeof t>"u"||t==null||(n.length>0?s.match(/\n/)?s="<".concat(t).concat(a,`>
|
|||
|
|
`).concat(s,"</").concat(t,`>
|
|||
|
|
`):s="<".concat(t).concat(a,">").concat(s,"</").concat(t,`>
|
|||
|
|
`):s="<".concat(t).concat(a,` />
|
|||
|
|
`)),s};Ms.ObjTree.prototype.array_to_xml=function(t,e){for(var n=[],o=0;o<e.length;o++){var r=e[o];typeof r>"u"||r==null?n[n.length]="<".concat(t," />"):typeof r=="object"&&r.constructor===Array?n[n.length]=this.array_to_xml(t,r):typeof r=="object"?n[n.length]=this.hash_to_xml(t,r):n[n.length]=this.scalar_to_xml(t,r)}return n.join("")};Ms.ObjTree.prototype.scalar_to_xml=function(t,e){return t==="#text"?this.xml_escape(e):"<".concat(t,">").concat(this.xml_escape(e),"</").concat(t,`>
|
|||
|
|
`)};Ms.ObjTree.prototype.xml_escape=o1;var Gte=function(t){return new Ms.ObjTree().parseXML(t)},zte=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),h2=function(){return h2=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},h2.apply(this,arguments)},fR=function(t,e){var n={};for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&e.indexOf(o)<0&&(n[o]=t[o]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,o=Object.getOwnPropertySymbols(t);r<o.length;r++)e.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(t,o[r])&&(n[o[r]]=t[o[r]]);return n},RM=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,n=e&&t[e],o=0;if(n)return n.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&o>=t.length&&(t=void 0),{value:t&&t[o++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Zl=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},Xc=function(t,e,n){if(n||arguments.length===2)for(var o=0,r=e.length,i;o<r;o++)(i||!(o in e))&&(i||(i=Array.prototype.slice.call(e,0,o)),i[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))},Os;(function(t){t.START="bpmn:startEvent",t.END="bpmn:endEvent",t.INTERMEDIATE_CATCH="bpmn:intermediateCatchEvent",t.INTERMEDIATE_THROW="bpmn:intermediateThrowEvent",t.BOUNDARY="bpmn:boundaryEvent",t.PARALLEL_GATEWAY="bpmn:parallelGateway",t.INCLUSIVE_GATEWAY="bpmn:inclusiveGateway",t.EXCLUSIVE_GATEWAY="bpmn:exclusiveGateway",t.USER="bpmn:userTask",t.SYSTEM="bpmn:serviceTask",t.FLOW="bpmn:sequenceFlow",t.SUBPROCESS="bpmn:subProcess"})(Os||(Os={}));var XI=["-name","-id","bpmn:incoming","bpmn:outgoing","-sourceRef","-targetRef","-children"],Hte=["properties","startPoint","endPoint","pointsList"],i1={in:[],out:["properties.panels","properties.nodeSize","properties.definitionId","properties.timerValue","properties.timerType","properties.definitionType","properties.parent","properties.isBoundaryEventTouchingTask"]},YI=function(t,e){var n=Object.keys(e||{});return n.forEach(function(o){if(t[o]){var r=e[o],i=r.in,a=r.out;i&&(t[o].in=i),a&&(t[o].out=a)}else t[o]=e[o]}),t},Xu={"bpmn:startEvent":{out:function(t){var e,n,o=t.properties;return((n=(e=Xu[o.definitionType])===null||e===void 0?void 0:e.out)===null||n===void 0?void 0:n.call(e,t))||{}}},"bpmn:intermediateCatchEvent":{out:function(t){var e,n,o=t.properties;return((n=(e=Xu[o.definitionType])===null||e===void 0?void 0:e.out)===null||n===void 0?void 0:n.call(e,t))||{}}},"bpmn:intermediateThrowEvent":{out:function(t){var e,n,o=t.properties;return((n=(e=Xu[o.definitionType])===null||e===void 0?void 0:e.out)===null||n===void 0?void 0:n.call(e,t))||{}}},"bpmn:boundaryEvent":{out:function(t){var e,n,o=t.properties;return((n=(e=Xu[o.definitionType])===null||e===void 0?void 0:e.out)===null||n===void 0?void 0:n.call(e,t))||{}}},"bpmn:sequenceFlow":{out:function(t){var e=t.properties,n=e.expressionType,o=e.condition;return o?n==="cdata"?{json:'<bpmn:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[${'.concat(o,"}]]></bpmn:conditionExpression>")}:{json:'<bpmn:conditionExpression xsi:type="bpmn2:tFormalExpression">'.concat(o,"</bpmn:conditionExpression>")}:{json:""}}},"bpmn:timerEventDefinition":{out:function(t){var e=t.properties,n=e.timerType,o=e.timerValue,r=e.definitionId,i=function(){return"<bpmn:".c
|
|||
|
|
`).forEach(function(f){i<f.length&&(i=f.length)}),n={value:o,x:Number(r["-x"])+i*10/2,y:Number(r["-y"])+7}}var a={};Object.entries(e).forEach(function(f){var h=Zl(f,2),v=h[0],b=h[1];XI.includes(v)||(a[v]=b)}),a=a1(a);var s=t["di:waypoint"].map(function(f){return{x:Number(f["-x"]),y:Number(f["-y"])}}),l={id:e["-id"],type:Os.FLOW,pointsList:s,sourceNodeId:e["-sourceRef"],targetNodeId:e["-targetRef"],properties:a};return n&&(l.text=n),l}var qs=(function(){function t(e){var n=e.lf,o=this;this.adapterOut=function(r,i){var a,s,l=h2({},o.processAttributes);Yte(l,r,i);var f={"-id":"BPMNPlane_1","-bpmnElement":l["-id"]};qte(f,r);var h=o.definitionAttributes;h["bpmn:process"]=l,h["bpmndi:BPMNDiagram"]={"-id":"BPMNDiagram_1","bpmndi:BPMNPlane":f};var v={"bpmn:definitions":h};if(!((a=i==null?void 0:i.mapping)===null||a===void 0)&&a.out){var b=(s=i==null?void 0:i.mapping)===null||s===void 0?void 0:s.out,E=function(O){Array.isArray(O)&&O.forEach(function(w){return E(w)}),typeof O=="object"&&Object.keys(O).forEach(function(w){var S;(S=b[w])?(O[S]=ge.cloneDeep(O[w]),delete O[w],E(O[S])):E(O[w])})};E(v)}return v},this.adapterIn=function(r,i){if(r)return Zte(r,i)},n.adapterIn=this.adapterIn,n.adapterOut=this.adapterOut,this.processAttributes={"-isExecutable":"true","-id":"Process"},this.definitionAttributes={"-id":"Definitions","-xmlns:xsi":"http://www.w3.org/2001/XMLSchema-instance","-xmlns:bpmn":"http://www.omg.org/spec/BPMN/20100524/MODEL","-xmlns:bpmndi":"http://www.omg.org/spec/BPMN/20100524/DI","-xmlns:dc":"http://www.omg.org/spec/DD/20100524/DC","-xmlns:di":"http://www.omg.org/spec/DD/20100524/DI","-targetNamespace":"http://logic-flow.org","-exporter":"logicflow","-exporterVersion":"1.2.10"}}return t.prototype.setCustomShape=function(e,n){t.shapeConfigMap.set(e,n)},t.pluginName="bpmn-adapter",t.shapeConfigMap=new Map,t})();qs.shapeConfigMap.set(Os.START,{width:tR.width,height:tR.height});qs.shapeConfigMap.set(Os.END,{width:nR.width,height:nR.height});qs.shapeConfigMap.set(Os.INTERMEDIATE_CATCH,{width:n1.width,height:n1.height});qs.shapeConfigMap.set(Os.INTERMEDIATE_THROW,{width:n1.width,height:n1.height});qs.shapeConfigMap.set(Os.BOUNDARY,{width:rR.width,height:rR.height});qs.shapeConfigMap.set(Os.PARALLEL_GATEWAY,{width:oR.width,height:oR.height});qs.shapeConfigMap.set(Os.INCLUSIVE_GATEWAY,{width:iR.width,height:iR.height});qs.shapeConfigMap.set(Os.EXCLUSIVE_GATEWAY,{width:aR.width,height:aR.height});qs.shapeConfigMap.set(Os.SYSTEM,{width:lR.width,height:lR.height});qs.shapeConfigMap.set(Os.USER,{width:sR.width,height:sR.height});qs.shapeConfigMap.set(Os.SUBPROCESS,{width:uR.width,height:uR.height});(function(t){zte(e,t);function e(n){var o=t.call(this,n)||this;o.adapterXmlIn=function(a){var s=Gte(a);return o.adapterIn(s,o.props)},o.adapterXmlOut=function(a){var s=o.adapterOut(a,o.props);return Wte(s)};var r=n.lf,i=n.props;return r.adapterIn=o.adapterXmlIn,r.adapterOut=o.adapterXmlOut,o.props=i,o}return e.pluginName="BPMNAdapter",e})(qs);function ene(t,e,n){var o=e.x,r=e.y,i=t.x,a=t.y,s=i-o,l=a-r,f=s*Math.cos(n)-l*Math.sin(n),h=s*Math.sin(n)+l*Math.cos(n),v=f+o,b=h+r;return{x:v,y:b}}var tne=(function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,r){o.__proto__=r}||function(o,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(o[i]=r[i])},t(e,n)};return function(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");t(e,n);function o(){this.constructor=e}e.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}})(),l1=function(){return l1=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++){e=arguments[n];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])}return t},l1.apply(this,arguments)},nne=function(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var o=n.call(t),r,i=[],a;try{for(;(e===void 0||e-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.er
|
|||
|
|
`,"\r"," "," "," "," "," ","\u2028","\u2029"],o="com|net|org|edu|gov|mil|aero|asia|biz|cat|coop|info|int|jobs|mobi|museum|name|post|pro|tel|travel|xxx|ac|ad|ae|af|ag|ai|al|am|an|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cs|cu|cv|cx|cy|cz|dd|de|dj|dk|dm|do|dz|ec|ee|eg|eh|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|sj|ja|sk|sl|sm|sn|so|sr|ss|st|su|sv|sx|sy|sz|tc|td|tf|tg|th|tj|tk|tl|tm|tn|to|tp|tr|tt|tv|tw|tz|ua|ug|uk|us|uy|uz|va|vc|ve|vg|vi|vn|vu|wf|ws|ye|yt|yu|za|zm|zw",r="(((?:(https?://|ftps?://|nntp://)|www\\d{0,3}[.]|[a-z0-9.\\-]+[.]("+o+")\\/)\\S+(?:[^\\s`!\\[\\]{};:'\".,?«»“”‘’])))|(([a-z0-9\\-]+\\.)?[a-z0-9\\-]+\\.("+o+"))",i=new RegExp("^("+o+")$","i"),a=new RegExp(r,"gi");function s(f){return!e.util.getClosestTag(f,"a")}var l=e.Extension.extend({init:function(){e.Extension.prototype.init.apply(this,arguments),this.disableEventHandling=!1,this.subscribe("editableKeypress",this.onKeypress.bind(this)),this.subscribe("editableBlur",this.onBlur.bind(this)),this.document.execCommand("AutoUrlDetect",!1,!1)},isLastInstance:function(){for(var f=0,h=0;h<this.window._mediumEditors.length;h++){var v=this.window._mediumEditors[h];v!==null&&v.getExtensionByName("autoLink")!==void 0&&f++}return f===1},destroy:function(){this.document.queryCommandSupported("AutoUrlDetect")&&this.isLastInstance()&&this.document.execCommand("AutoUrlDetect",!1,!0)},onBlur:function(f,h){this.performLinking(h)},onKeypress:function(f){this.disableEventHandling||e.util.isKey(f,[e.util.keyCode.SPACE,e.util.keyCode.ENTER])&&(clearTimeout(this.performLinkingTimeout),this.performLinkingTimeout=setTimeout((function(){try{var h=this.base.exportSelection();this.performLinking(f.target)&&this.base.importSelection(h,!0)}catch(v){window.console&&window.console.error("Failed to perform linking",v),this.disableEventHandling=!0}}).bind(this),0))},performLinking:function(f){var h=e.util.splitByBlockElements(f),v=!1;h.length===0&&(h=[f]);for(var b=0;b<h.length;b++)v=this.removeObsoleteAutoLinkSpans(h[b])||v,v=this.performLinkingWithinElement(h[b])||v;return this.base.events.updateInput(f,{target:f,currentTarget:f}),v},removeObsoleteAutoLinkSpans:function(f){if(!f||f.nodeType===3)return!1;for(var h=f.querySelectorAll('span[data-auto-link="true"]'),v=!1,b=0;b<h.length;b++){var E=h[b].textContent;if(E.indexOf("://")===-1&&(E=e.util.ensureUrlHasProtocol(E)),h[b].getAttribute("data-href")!==E&&s(h[b])){v=!0;var O=E.replace(/\s+$/,"");if(h[b].getAttribute("data-href")===O){var w=E.length-O.length,S=e.util.splitOffDOMTree(h[b],this.splitTextBeforeEnd(h[b],w));h[b].parentNode.insertBefore(S,h[b].nextSibling)}else e.util.unwrap(h[b],this.document)}}return v},splitTextBeforeEnd:function(f,h){for(var v=this.document.createTreeWalker(f,NodeFilter.SHOW_TEXT,null,!1),b=!0;b;)b=v.lastChild()!==null;for(var E,O,w;h>0&&w!==null;)E=v.currentNode,O=E.nodeValue,O.length>h?(w=E.splitText(O.length-h),h=0):(w=v.previousNode(),h-=O.length);return w},performLinkingWithinElement:function(f){for(var h=this.findLinkableText(f),v=!1,b=0;b<h.length;b++){var E=e.util.findOrCreateMatchingTextNodes(this.document,f,h[b]);this.shouldNotLink(E)||this.createAutoLink(E,h[b].href)}return v},shouldNotLink:function(f){for(var h=!1,v=0;v<f.length&&h===!1;v++)h=!!e.util.traverseUp(f[v],function(b){return b.nodeName.toLowerCase()==="a"||b.getAttribute&&b.getAttribute("data-auto-link")==="true"});return h},findLinkableText:function(f){for(var h=f.textContent,v=null,b=[];(v=a.exec(h))!==null;){var E=!0,O=v.index+v[0].length;E=(v.index===0||n.indexOf(h[v.index-1])!==-1)&&(O===h.length||n.indexOf(h[O])!==-1),E=E&&(v[0].indexOf("/")!==-1||i.test(v[0].split(".").po
|
|||
|
|
* vanilla-picker v2.12.3
|
|||
|
|
* https://vanilla-picker.js.org
|
|||
|
|
*
|
|||
|
|
* Copyright 2017-2024 Andreas Borgen (https://github.com/Sphinxxxx), Adam Brooks (https://github.com/dissimulate)
|
|||
|
|
* Released under the ISC license.
|
|||
|
|
*/var DM=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},jM=(function(){function t(e,n){for(var o=0;o<n.length;o++){var r=n[o];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,n,o){return n&&t(e.prototype,n),o&&t(e,o),e}})(),j0=(function(){function t(e,n){var o=[],r=!0,i=!1,a=void 0;try{for(var s=e[Symbol.iterator](),l;!(r=(l=s.next()).done)&&(o.push(l.value),!(n&&o.length===n));r=!0);}catch(f){i=!0,a=f}finally{try{!r&&s.return&&s.return()}finally{if(i)throw a}}return o}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})();String.prototype.startsWith=String.prototype.startsWith||function(t){return this.indexOf(t)===0};String.prototype.padStart=String.prototype.padStart||function(t,e){for(var n=this;n.length<t;)n=e+n;return n};var yne={cb:"0f8ff",tqw:"aebd7",q:"-ffff",qmrn:"7fffd4",zr:"0ffff",bg:"5f5dc",bsq:"e4c4",bck:"---",nch:"ebcd",b:"--ff",bvt:"8a2be2",brwn:"a52a2a",brw:"deb887",ctb:"5f9ea0",hrt:"7fff-",chcT:"d2691e",cr:"7f50",rnw:"6495ed",crns:"8dc",crms:"dc143c",cn:"-ffff",Db:"--8b",Dcn:"-8b8b",Dgnr:"b8860b",Dgr:"a9a9a9",Dgrn:"-64-",Dkhk:"bdb76b",Dmgn:"8b-8b",Dvgr:"556b2f",Drng:"8c-",Drch:"9932cc",Dr:"8b--",Dsmn:"e9967a",Dsgr:"8fbc8f",DsTb:"483d8b",DsTg:"2f4f4f",Dtrq:"-ced1",Dvt:"94-d3",ppnk:"1493",pskb:"-bfff",mgr:"696969",grb:"1e90ff",rbrc:"b22222",rwht:"af0",stg:"228b22",chs:"-ff",gnsb:"dcdcdc",st:"8f8ff",g:"d7-",gnr:"daa520",gr:"808080",grn:"-8-0",grnw:"adff2f",hnw:"0fff0",htpn:"69b4",nnr:"cd5c5c",ng:"4b-82",vr:"0",khk:"0e68c",vnr:"e6e6fa",nrb:"0f5",wngr:"7cfc-",mnch:"acd",Lb:"add8e6",Lcr:"08080",Lcn:"e0ffff",Lgnr:"afad2",Lgr:"d3d3d3",Lgrn:"90ee90",Lpnk:"b6c1",Lsmn:"a07a",Lsgr:"20b2aa",Lskb:"87cefa",LsTg:"778899",Lstb:"b0c4de",Lw:"e0",m:"-ff-",mgrn:"32cd32",nn:"af0e6",mgnt:"-ff",mrn:"8--0",mqm:"66cdaa",mmb:"--cd",mmrc:"ba55d3",mmpr:"9370db",msg:"3cb371",mmsT:"7b68ee","":"-fa9a",mtr:"48d1cc",mmvt:"c71585",mnLb:"191970",ntc:"5fffa",mstr:"e4e1",mccs:"e4b5",vjw:"dead",nv:"--80",c:"df5e6",v:"808-0",vrb:"6b8e23",rng:"a5-",rngr:"45-",rch:"da70d6",pgnr:"eee8aa",pgrn:"98fb98",ptrq:"afeeee",pvtr:"db7093",ppwh:"efd5",pchp:"dab9",pr:"cd853f",pnk:"c0cb",pm:"dda0dd",pwrb:"b0e0e6",prp:"8-080",cc:"663399",r:"--",sbr:"bc8f8f",rb:"4169e1",sbrw:"8b4513",smn:"a8072",nbr:"4a460",sgrn:"2e8b57",ssh:"5ee",snn:"a0522d",svr:"c0c0c0",skb:"87ceeb",sTb:"6a5acd",sTgr:"708090",snw:"afa",n:"-ff7f",stb:"4682b4",tn:"d2b48c",t:"-8080",thst:"d8bfd8",tmT:"6347",trqs:"40e0d0",vt:"ee82ee",whT:"5deb3",wht:"",hts:"5f5f5",w:"-",wgrn:"9acd32"};function gR(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,n=e>0?t.toFixed(e).replace(/0+$/,"").replace(/\.$/,""):t.toString();return n||"0"}var _ne=(function(){function t(e,n,o,r){DM(this,t);var i=this;function a(l){if(l.startsWith("hsl")){var f=l.match(/([\-\d\.e]+)/g).map(Number),h=j0(f,4),v=h[0],b=h[1],E=h[2],O=h[3];O===void 0&&(O=1),v/=360,b/=100,E/=100,i.hsla=[v,b,E,O]}else if(l.startsWith("rgb")){var w=l.match(/([\-\d\.e]+)/g).map(Number),S=j0(w,4),M=S[0],T=S[1],$=S[2],D=S[3];D===void 0&&(D=1),i.rgba=[M,T,$,D]}else l.startsWith("#")?i.rgba=t.hexToRgb(l):i.rgba=t.nameToRgb(l)||t.hexToRgb(l)}if(e!==void 0)if(Array.isArray(e))this.rgba=e;else if(o===void 0){var s=e&&""+e;s&&a(s.toLowerCase())}else this.rgba=[e,n,o,r===void 0?1:r]}return jM(t,[{key:"printRGB",value:function(n){var o=n?this.rgba:this.rgba.slice(0,3),r=o.map(function(i,a){return gR(i,a===3?3:0)});return n?"rgba("+r+")":"rgb("+r+")"}},{key:"printHSL",value:function(n){var o=[360,100,100,1],r=["","%","%",""],i=n?this.hsla:this.hsla.slice(0,3),a=i.map(function(s,l){return gR(s*o[l],l===3?3:1)+r[l]});return n?"hsla("+a+")":"hsl("+a+")"}},{key:"printHex",value:function(n){var o=this.hex;return n?o:o.substring(0,7)}},{key:"rgba",get:function(){if(this._rgba)return this._rgba;if(!this._hsla)throw new Error("No color is set");return this._rgba=t.hslToRgb(this._hsla)},set:function(n){n.length
|
|||
|
|
linear-gradient(45deg, lightgrey 25%, white 25%, white 75%, lightgrey 75%) 1em 1em / 2em 2em`,xne=360,qI="keydown",L0="mousedown",gS="focusin";function Dd(t,e){return(e||document).querySelector(t)}function One(t){t.preventDefault(),t.stopPropagation()}function yS(t,e,n,o,r){t.add(e,qI,function(i){n.indexOf(i.key)>=0&&o(i)})}var KI=(function(){function t(e){DM(this,t),this.settings={popup:"right",layout:"default",alpha:!0,editor:!0,editorFormat:"hex",cancelButton:!1,defaultColor:"#0cf"},this._events=new bne,this.onChange=null,this.onDone=null,this.onOpen=null,this.onClose=null,this.setOptions(e)}return jM(t,[{key:"setOptions",value:function(n){var o=this;if(!n)return;var r=this.settings;function i(f,h,v){for(var b in f)h[b]=f[b]}if(n instanceof HTMLElement)r.parent=n;else{r.parent&&n.parent&&r.parent!==n.parent&&(this._events.remove(r.parent),this._popupInited=!1),i(n,r),n.onChange&&(this.onChange=n.onChange),n.onDone&&(this.onDone=n.onDone),n.onOpen&&(this.onOpen=n.onOpen),n.onClose&&(this.onClose=n.onClose);var a=n.color||n.colour;a&&this._setColor(a)}var s=r.parent;if(s&&r.popup&&!this._popupInited){var l=function(h){return o.openHandler(h)};this._events.add(s,"click",l),yS(this._events,s,[" ","Spacebar","Enter"],l),this._popupInited=!0}else n.parent&&!r.popup&&this.show()}},{key:"openHandler",value:function(n){if(this.show()){n&&n.preventDefault(),this.settings.parent.style.pointerEvents="none";var o=n&&n.type===qI?this._domEdit:this.domElement;setTimeout(function(){return o.focus()},100),this.onOpen&&this.onOpen(this.colour)}}},{key:"closeHandler",value:function(n){var o=n&&n.type,r=!1;if(!n)r=!0;else if(o===L0||o===gS){var i=(this.__containedEvent||0)+100;n.timeStamp>i&&(r=!0)}else One(n),r=!0;r&&this.hide()&&(this.settings.parent.style.pointerEvents="",o!==L0&&this.settings.parent.focus(),this.onClose&&this.onClose(this.colour))}},{key:"movePopup",value:function(n,o){this.closeHandler(),this.setOptions(n),o&&this.openHandler()}},{key:"setColor",value:function(n,o){this._setColor(n,{silent:o})}},{key:"_setColor",value:function(n,o){if(typeof n=="string"&&(n=n.trim()),!!n){o=o||{};var r=void 0;try{r=new _ne(n)}catch(a){if(o.failSilently)return;throw a}if(!this.settings.alpha){var i=r.hsla;i[3]=1,r.hsla=i}this.colour=this.color=r,this._setHSLA(null,null,null,null,o)}}},{key:"setColour",value:function(n,o){this.setColor(n,o)}},{key:"show",value:function(){var n=this.settings.parent;if(!n)return!1;if(this.domElement){var o=this._toggleDOM(!0);return this._setPosition(),o}var r=this.settings.template||'<div class="picker_wrapper" tabindex="-1"><div class="picker_arrow"></div><div class="picker_hue picker_slider"><div class="picker_selector"></div></div><div class="picker_sl"><div class="picker_selector"></div></div><div class="picker_alpha picker_slider"><div class="picker_selector"></div></div><div class="picker_editor"><input aria-label="Type a color name or hex value"/></div><div class="picker_sample"></div><div class="picker_done"><button>Ok</button></div><div class="picker_cancel"><button>Cancel</button></div></div>',i=wne(r);return this.domElement=i,this._domH=Dd(".picker_hue",i),this._domSL=Dd(".picker_sl",i),this._domA=Dd(".picker_alpha",i),this._domEdit=Dd(".picker_editor input",i),this._domSample=Dd(".picker_sample",i),this._domOkay=Dd(".picker_done button",i),this._domCancel=Dd(".picker_cancel button",i),i.classList.add("layout_"+this.settings.layout),this.settings.alpha||i.classList.add("no_alpha"),this.settings.editor||i.classList.add("no_editor"),this.settings.cancelButton||i.classList.add("no_cancel"),this._ifPopup(function(){return i.classList.add("popup")}),this._setPosition(),this.colour?this._updateUI():this._setColor(this.settings.defaultColor),this._bindEvents(),!0}},{key:"hide",value:function(){return this._toggleDOM(!1)}},{key:"destroy",value:function(){this._events.destroy(),this.domElement&&this.settings.parent.removeChild(this.domElement)}},{key:"_bindEvents",value:function(){var n=this,o=this,r=this.domElement,i=this._events;function a(f,h,v){i.add(f,h,v)}a(r,"cl
|
|||
|
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|||
|
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|||
|
|
this file except in compliance with the License. You may obtain a copy of the
|
|||
|
|
License at http://www.apache.org/licenses/LICENSE-2.0
|
|||
|
|
|
|||
|
|
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|||
|
|
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|||
|
|
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|||
|
|
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|||
|
|
|
|||
|
|
See the Apache Version 2.0 License for specific language governing permissions
|
|||
|
|
and limitations under the License.
|
|||
|
|
***************************************************************************** */var Q=function(){return Q=Object.assign||function(R){for(var L,Z=1,fe=arguments.length;Z<fe;Z++)for(var Re in L=arguments[Z])Object.prototype.hasOwnProperty.call(L,Re)&&(R[Re]=L[Re]);return R},Q.apply(this,arguments)};function J(R){var L=typeof Symbol=="function"&&R[Symbol.iterator],Z=0;return L?L.call(R):{next:function(){return R&&Z>=R.length&&(R=void 0),{value:R&&R[Z++],done:!R}}}}function ie(R,L){var Z=typeof Symbol=="function"&&R[Symbol.iterator];if(!Z)return R;var fe,Re,lt=Z.call(R),It=[];try{for(;(L===void 0||L-- >0)&&!(fe=lt.next()).done;)It.push(fe.value)}catch(bn){Re={error:bn}}finally{try{fe&&!fe.done&&(Z=lt.return)&&Z.call(lt)}finally{if(Re)throw Re.error}}return It}function Se(){for(var R=[],L=0;L<arguments.length;L++)R=R.concat(ie(arguments[L]));return R}var Ae=Symbol("mobx did run lazy initializers"),Pe=Symbol("mobx pending decorators"),De={},ze={};function Ye(R,L){var Z=L?De:ze;return Z[R]||(Z[R]={configurable:!0,enumerable:L,get:function(){return Be(this),this[R]},set:function(fe){Be(this),this[R]=fe}})}function Be(R){var L,Z;if(R[Ae]!==!0){var fe=R[Pe];if(fe){S(R,Ae,!0);var Re=Se(Object.getOwnPropertySymbols(fe),Object.keys(fe));try{for(var lt=J(Re),It=lt.next();!It.done;It=lt.next()){var bn=fe[It.value];bn.propertyCreator(R,bn.prop,bn.descriptor,bn.decoratorTarget,bn.decoratorArguments)}}catch(Jn){L={error:Jn}}finally{try{It&&!It.done&&(Z=lt.return)&&Z.call(lt)}finally{if(L)throw L.error}}}}}function Je(R,L){return function(){var Z,fe=function(Re,lt,It,bn){if(bn===!0)return L(Re,lt,It,Re,Z),null;if(!Object.prototype.hasOwnProperty.call(Re,Pe)){var Jn=Re[Pe];S(Re,Pe,Q({},Jn))}return Re[Pe][lt]={prop:lt,propertyCreator:L,descriptor:It,decoratorTarget:Re,decoratorArguments:Z},Ye(lt,R)};return gt(arguments)?(Z=s,fe.apply(null,arguments)):(Z=Array.prototype.slice.call(arguments),fe)}}function gt(R){return(R.length===2||R.length===3)&&(typeof R[1]=="string"||typeof R[1]=="symbol")||R.length===4&&R[3]===!0}function le(R,L,Z){return ra(R)?R:Array.isArray(R)?zt.array(R,{name:Z}):w(R)?zt.object(R,void 0,{name:Z}):T(R)?zt.map(R,{name:Z}):$(R)?zt.set(R,{name:Z}):R}function Ze(R){return R}function pe(R){v(R);var L=Je(!0,(function(fe,Re,lt,It,bn){var Jn=lt?lt.initializer?lt.initializer.call(fe):lt.value:void 0;ll(fe).addObservableProp(Re,Jn,R)})),Z=(i!==void 0&&i.env,L);return Z.enhancer=R,Z}var se={deep:!0,name:void 0,defaultDecorator:void 0,proxy:!0};function we(R){return R==null?se:typeof R=="string"?{name:R,deep:!0,proxy:!0}:R}Object.freeze(se);var $e=pe(le),rt=pe((function(R,L,Z){return R==null||ia(R)||xl(R)||Wi(R)||Ki(R)?R:Array.isArray(R)?zt.array(R,{name:Z,deep:!1}):w(R)?zt.object(R,void 0,{name:Z,deep:!1}):T(R)?zt.map(R,{name:Z,deep:!1}):$(R)?zt.set(R,{name:Z,deep:!1}):h(!1)})),pt=pe(Ze),Lt=pe((function(R,L,Z){return un(R,L)?L:R}));function Jt(R){return R.defaultDecorator?R.defaultDecorator.enhancer:R.deep===!1?Ze:le}var en={box:function(R,L){arguments.length>2&&it("box");var Z=we(L);return new In(R,Jt(Z),Z.name,!0,Z.equals)},array:function(R,L){arguments.length>2&&it("array");var Z=we(L);return Ks(R,Jt(Z),Z.name)},map:function(R,L){arguments.length>2&&it("map");var Z=we(L);return new lf(R,Jt(Z),Z.name)},set:function(R,L){arguments.length>2&&it("set");var Z=we(L);return new os(R,Jt(Z),Z.name)},object:function(R,L,Z){typeof arguments[1]=="string"&&it("object");var fe=we(Z);if(fe.proxy===!1)return lr({},R,L,fe);var Re=qr(fe),lt=lr({},void 0,void 0,fe),It=bu(lt);return na(It,R,L,Re),It},ref:pt,shallow:rt,deep:$e,struct:Lt},zt=function(R,L,Z){if(typeof arguments[1]=="string"||typeof arguments[1]=="symbol")return $e.apply(null,arguments);if(ra(R))return R;var fe=w(R)?zt.object(R,L,Z):Array.isArray(R)?zt.array(R,L):T(R)?zt.map(R,L):$(R)?zt.set(R,L):R;if(fe!==R)return fe;h(!1)};function it(R){h("Expected one or two arguments to observable."+R+". Did you accidentally try to use observable."+R+" as decorator?")}Object.keys(en).forEach((function(R){return zt[R]=en[R]}));var ae,re,je=Je(!1,(function(R,L,Z,fe,Re){var lt=Z.get,It=Z.set,bn=
|
|||
|
|
/*
|
|||
|
|
Tracing '`+R.name+`'
|
|||
|
|
|
|||
|
|
You are entering this break point because derivation '`+R.name+"' is being traced and '"+L.name+`' is now forcing it to update.
|
|||
|
|
Just follow the stacktrace you should now see in the devtools to see precisely what piece of your code is causing this update
|
|||
|
|
The stackframe you are looking for is at least ~6-8 stack-frames up.
|
|||
|
|
|
|||
|
|
`+(R instanceof wo?R.derivation.toString().replace(/[*]\//g,"/"):"")+`
|
|||
|
|
|
|||
|
|
The dependencies for this derivation are:
|
|||
|
|
|
|||
|
|
`+Z.join(`
|
|||
|
|
`)+`
|
|||
|
|
*/
|
|||
|
|
`)()}}function qi(R,L,Z){L.length>=1e3?L.push("(and many more)"):(L.push(""+new Array(Z).join(" ")+R.name),R.dependencies&&R.dependencies.forEach((function(fe){return qi(fe,L,Z+1)})))}var Na=(function(){function R(L,Z,fe,Re){L===void 0&&(L="Reaction@"+f()),Re===void 0&&(Re=!1),this.name=L,this.onInvalidate=Z,this.errorHandler=fe,this.requiresObservable=Re,this.observing=[],this.newObserving=[],this.dependenciesState=ae.NOT_TRACKING,this.diffValue=0,this.runId=0,this.unboundDepsCount=0,this.__mapid="#"+f(),this.isDisposed=!1,this._isScheduled=!1,this._isTrackPending=!1,this._isRunning=!1,this.isTracing=re.NONE}return R.prototype.onBecomeStale=function(){this.schedule()},R.prototype.schedule=function(){this._isScheduled||(this._isScheduled=!0,Sn.pendingReactions.push(this),yl())},R.prototype.isScheduled=function(){return this._isScheduled},R.prototype.runReaction=function(){if(!this.isDisposed){if(Ui(),this._isScheduled=!1,Gt(this)){this._isTrackPending=!0;try{this.onInvalidate(),this._isTrackPending}catch(L){this.reportExceptionInDerivation(L)}}gr()}},R.prototype.track=function(L){if(!this.isDisposed){Ui(),this._isRunning=!0;var Z=On(this,L,void 0);this._isRunning=!1,this._isTrackPending=!1,this.isDisposed&&ke(this),Rt(Z)&&this.reportExceptionInDerivation(Z.cause),gr()}},R.prototype.reportExceptionInDerivation=function(L){var Z=this;if(this.errorHandler)this.errorHandler(L,this);else{if(Sn.disableErrorBoundaries)throw L;Sn.suppressReactionErrors,Sn.globalReactionErrorHandlers.forEach((function(fe){return fe(L,Z)}))}},R.prototype.dispose=function(){this.isDisposed||(this.isDisposed=!0,this._isRunning||(Ui(),ke(this),gr()))},R.prototype.getDisposer=function(){var L=this.dispose.bind(this);return L[I]=this,L},R.prototype.toString=function(){return"Reaction["+this.name+"]"},R.prototype.trace=function(L){L===void 0&&(L=!1),(function(){for(var Z=[],fe=0;fe<arguments.length;fe++)Z[fe]=arguments[fe];var Re=!1;typeof Z[Z.length-1]=="boolean"&&(Re=Z.pop());var lt=Mo(Z);if(!lt)return h(!1);lt.isTracing,re.NONE,lt.isTracing=Re?re.BREAK:re.LOG})(this,L)},R})(),al=function(R){return R()};function yl(){Sn.inBatch>0||Sn.isRunningReactions||al(Cs)}function Cs(){Sn.isRunningReactions=!0;for(var R=Sn.pendingReactions,L=0;R.length>0;){++L==100&&R.splice(0);for(var Z=R.splice(0),fe=0,Re=Z.length;fe<Re;fe++)Z[fe].runReaction()}Sn.isRunningReactions=!1}var _l=M("Reaction",Na);function ts(R){var L=al;al=function(Z){return R((function(){return L(Z)}))}}function ve(R){return function(){}}function mt(){h(!1)}function cn(R){return function(L,Z,fe){if(fe){if(fe.value)return{value:yo(R,fe.value),enumerable:!1,configurable:!0,writable:!0};var Re=fe.initializer;return{enumerable:!1,configurable:!0,writable:!0,initializer:function(){return yo(R,Re.call(this))}}}return Kn(R).apply(this,arguments)}}function Kn(R){return function(L,Z,fe){Object.defineProperty(L,Z,{configurable:!0,enumerable:!1,get:function(){},set:function(Re){S(this,Z,br(R,Re))}})}}var br=function(R,L,Z,fe){return arguments.length===1&&typeof R=="function"?yo(R.name||"<unnamed action>",R):arguments.length===2&&typeof L=="function"?yo(R,L):arguments.length===1&&typeof R=="string"?cn(R):fe!==!0?cn(L).apply(null,arguments):void S(R,L,yo(R.name||L,Z.value,this))};function so(R,L){return ho(typeof R=="string"?R:R.name||"<unnamed action>",typeof R=="function"?R:L,this,void 0)}function si(R){return typeof R=="function"&&R.isMobxAction===!0}function ye(R,L,Z){S(R,L,yo(L,Z.bind(R)))}function ht(R,L){L===void 0&&(L=l);var Z,fe=L&&L.name||R.name||"Autorun@"+f();if(!L.scheduler&&!L.delay)Z=new Na(fe,(function(){this.track(It)}),L.onError,L.requiresObservable);else{var Re=Rn(L),lt=!1;Z=new Na(fe,(function(){lt||(lt=!0,Re((function(){lt=!1,Z.isDisposed||Z.track(It)})))}),L.onError,L.requiresObservable)}function It(){R(Z)}return Z.schedule(),Z.getDisposer()}br.bound=function(R,L,Z,fe){return fe===!0?(ye(R,L,Z.value),null):Z?{configurable:!0,enumerable:!1,get:function(){return ye(this,L,Z.value||Z.initializer.call(this)),this[L]},set:mt}:{enumerable:!1,configurable:!0,set:function(Re){ye(this,L,Re)},
|
|||
|
|
`)&&(le="(?: "+le+")",pe=" "+pe,Ze++),W=new RegExp("^(?:"+le+")",gt)),z&&(W=new RegExp("^"+le+"$(?!\\s)",gt)),I&&(Q=Pe.lastIndex),J=s(T,Je?W:Pe,pe),Je?J?(J.input=F(J.input,Ze),J[0]=F(J[0],Ze),J.index=Pe.lastIndex,Pe.lastIndex+=J[0].length):Pe.lastIndex=0:I&&J&&(Pe.lastIndex=Pe.global?J.index+J[0].length:Q),z&&J&&J.length>1&&s(M,J[0],W,(function(){for(ie=1;ie<arguments.length-2;ie++)arguments[ie]===void 0&&(J[ie]=void 0)})),J&&Be)for(J.groups=Se=E(null),ie=0;ie<Be.length;ie++)Se[(Ae=Be[ie])[0]]=J[Ae[1]];return J}),n.exports=$},function(n,o,r){var i=r(16),a=r(7),s=r(75),l=r(59),f=r(45),h=r(40),v=r(115),b=r(63),E=r(81)("splice"),O=a.TypeError,w=Math.max,S=Math.min,M=9007199254740991,T="Maximum allowed length exceeded";i({target:"Array",proto:!0,forced:!E},{splice:function($,D){var P,B,F,I,V,z,X=h(this),Y=f(X),W=s($,Y),Q=arguments.length;if(Q===0?P=B=0:Q===1?(P=0,B=Y-W):(P=Q-2,B=S(w(l(D),0),Y-W)),Y+P-B>M)throw O(T);for(F=v(X,B),I=0;I<B;I++)(V=W+I)in X&&b(F,I,X[V]);if(F.length=B,P<B){for(I=W;I<Y-B;I++)z=I+P,(V=I+B)in X?X[z]=X[V]:delete X[z];for(I=Y;I>Y-B+P;I--)delete X[I-1]}else if(P>B)for(I=Y-B;I>W;I--)z=I+P-1,(V=I+B-1)in X?X[z]=X[V]:delete X[z];for(I=0;I<P;I++)X[I+W]=arguments[I+2];return X.length=Y-B+P,F}})},function(n,o,r){var i=r(16),a=r(205);i({target:"String",proto:!0,forced:r(206)("anchor")},{anchor:function(s){return a(this,"a","name",s)}})},function(n,o,r){(function(i){var a=typeof i=="object"&&i&&i.Object===Object&&i;o.a=a}).call(this,r(68))},function(n,o,r){(function(i){var a=r(31),s=e&&!e.nodeType&&e,l=s&&typeof i=="object"&&i&&!i.nodeType&&i,f=l&&l.exports===s?a.a.Buffer:void 0,h=f?f.allocUnsafe:void 0;o.a=function(v,b){if(b)return v.slice();var E=v.length,O=h?h(E):new v.constructor(E);return v.copy(O),O}}).call(this,r(122)(n))},function(n,o,r){var i=r(70),a=r(18);n.exports=!!Object.getOwnPropertySymbols&&!a((function(){var s=Symbol();return!String(s)||!(Object(s)instanceof Symbol)||!Symbol.sham&&i&&i<41}))},function(n,o,r){var i=r(7),a=r(110),s="__core-js_shared__",l=i[s]||a(s,{});n.exports=l},function(n,o,r){var i=r(7),a=Object.defineProperty;n.exports=function(s,l){try{a(i,s,{value:l,configurable:!0,writable:!0})}catch{i[s]=l}return l}},function(n,o){n.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(n,o){o.f=Object.getOwnPropertySymbols},function(n,o,r){var i={};i[r(28)("toStringTag")]="z",n.exports=String(i)==="[object z]"},function(n,o,r){var i=r(7),a=r(75),s=r(45),l=r(63),f=i.Array,h=Math.max;n.exports=function(v,b,E){for(var O=s(v),w=a(b,O),S=a(E===void 0?O:E,O),M=f(h(S-w,0)),T=0;w<S;w++,T++)l(M,T,v[w]);return M.length=T,M}},function(n,o,r){var i=r(178);n.exports=function(a,s){return new(i(a))(s===0?0:s)}},function(n,o,r){var i=r(16),a=r(34),s=r(71),l=r(73),f=r(30),h=r(180),v=r(101),b=r(102),E=r(78),O=r(57),w=r(42),S=r(28),M=r(80),T=r(142),$=l.PROPER,D=l.CONFIGURABLE,P=T.IteratorPrototype,B=T.BUGGY_SAFARI_ITERATORS,F=S("iterator"),I="keys",V="values",z="entries",X=function(){return this};n.exports=function(Y,W,Q,J,ie,Se,Ae){h(Q,W,J);var Pe,De,ze,Ye=function(se){if(se===ie&&Ze)return Ze;if(!B&&se in gt)return gt[se];switch(se){case I:case V:case z:return function(){return new Q(this,se)}}return function(){return new Q(this)}},Be=W+" Iterator",Je=!1,gt=Y.prototype,le=gt[F]||gt["@@iterator"]||ie&>[ie],Ze=!B&&le||Ye(ie),pe=W=="Array"&>.entries||le;if(pe&&(Pe=v(pe.call(new Y)))!==Object.prototype&&Pe.next&&(s||v(Pe)===P||(b?b(Pe,P):f(Pe[F])||w(Pe,F,X)),E(Pe,Be,!0,!0),s&&(M[Be]=X)),$&&ie==V&&le&&le.name!==V&&(!s&&D?O(gt,"name",V):(Je=!0,Ze=function(){return a(le,this)})),ie)if(De={values:Ye(V),keys:Se?Ze:Ye(I),entries:Ye(z)},Ae)for(ze in De)(B||Je||!(ze in gt))&&w(gt,ze,De[ze]);else i({target:W,proto:!0,forced:B||Je},De);return s&&!Ae||gt[F]===Ze||w(gt,F,Ze,{name:ie}),M[W]=Ze,De}},function(n,o,r){var i=r(7),a=r(64),s=r(34),l=r(32),f=r(88),h=r(145),v=r(45),b=r(54),E=r(146),O=r(118),w=r(147),S=i.TypeError,M=function($,D){this.stopped=$,this.result=D},T=M.prototype;n.exports=function($,D,P){var B,F,I,V,z,X,Y,W=P&&P.that,Q=!(!P||!P
|
|||
|
|
* @license
|
|||
|
|
* Lodash <https://lodash.com/>
|
|||
|
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|||
|
|
* Released under MIT license <https://lodash.com/license>
|
|||
|
|
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|||
|
|
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|||
|
|
*/(function(){var l,f="Expected a function",h="__lodash_hash_undefined__",v="__lodash_placeholder__",b=16,E=32,O=64,w=128,S=256,M=1/0,T=9007199254740991,$=NaN,D=4294967295,P=[["ary",w],["bind",1],["bindKey",2],["curry",8],["curryRight",b],["flip",512],["partial",E],["partialRight",O],["rearg",S]],B="[object Arguments]",F="[object Array]",I="[object Boolean]",V="[object Date]",z="[object Error]",X="[object Function]",Y="[object GeneratorFunction]",W="[object Map]",Q="[object Number]",J="[object Object]",ie="[object Promise]",Se="[object RegExp]",Ae="[object Set]",Pe="[object String]",De="[object Symbol]",ze="[object WeakMap]",Ye="[object ArrayBuffer]",Be="[object DataView]",Je="[object Float32Array]",gt="[object Float64Array]",le="[object Int8Array]",Ze="[object Int16Array]",pe="[object Int32Array]",se="[object Uint8Array]",we="[object Uint8ClampedArray]",$e="[object Uint16Array]",rt="[object Uint32Array]",pt=/\b__p \+= '';/g,Lt=/\b(__p \+=) '' \+/g,Jt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,en=/&(?:amp|lt|gt|quot|#39);/g,zt=/[&<>"']/g,it=RegExp(en.source),ae=RegExp(zt.source),re=/<%-([\s\S]+?)%>/g,je=/<%([\s\S]+?)%>/g,vt=/<%=([\s\S]+?)%>/g,q=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,kt=/^\w*$/,Rt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Gt=/[\\^$.*+?()[\]{}|]/g,Pn=RegExp(Gt.source),qt=/^\s+/,On=/\s/,ke=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Ke=/\{\n\/\* \[wrapped with (.+)\] \*/,Le=/,? & /,dt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,At=/[()=,{}\[\]\/\s]/,Tt=/\\(\\)?/g,En=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Zn=/\w*$/,ao=/^[-+]0x[0-9a-f]+$/i,Lo=/^0b[01]+$/i,yo=/^\[object .+?Constructor\]$/,ho=/^0o[0-7]+$/i,Nn=/^(?:0|[1-9]\d*)$/,qn=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,rr=/($^)/,ut=/['\n\r\u2028\u2029\\]/g,vn="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",In="\\u2700-\\u27bf",sr="a-z\\xdf-\\xf6\\xf8-\\xff",wo="A-Z\\xc0-\\xd6\\xd8-\\xde",oo="\\ufe0e\\ufe0f",ta="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ca="['’]",Yi="[\\ud800-\\udfff]",fa="["+ta+"]",Ka="["+vn+"]",Sn="\\d+",Ts="[\\u2700-\\u27bf]",Oo="["+sr+"]",es="[^\\ud800-\\udfff"+ta+Sn+In+sr+wo+"]",Ui="\\ud83c[\\udffb-\\udfff]",gr="[^\\ud800-\\udfff]",gl="(?:\\ud83c[\\udde6-\\uddff]){2}",pa="[\\ud800-\\udbff][\\udc00-\\udfff]",qi="["+wo+"]",Na="(?:"+Oo+"|"+es+")",al="(?:"+qi+"|"+es+")",yl="(?:['’](?:d|ll|m|re|s|t|ve))?",Cs="(?:['’](?:D|LL|M|RE|S|T|VE))?",_l="(?:"+Ka+"|"+Ui+")?",ts="[\\ufe0e\\ufe0f]?",ve=ts+_l+("(?:\\u200d(?:"+[gr,gl,pa].join("|")+")"+ts+_l+")*"),mt="(?:"+[Ts,gl,pa].join("|")+")"+ve,cn="(?:"+[gr+Ka+"?",Ka,gl,pa,Yi].join("|")+")",Kn=RegExp(Ca,"g"),br=RegExp(Ka,"g"),so=RegExp(Ui+"(?="+Ui+")|"+cn+ve,"g"),si=RegExp([qi+"?"+Oo+"+"+yl+"(?="+[fa,qi,"$"].join("|")+")",al+"+"+Cs+"(?="+[fa,qi+Na,"$"].join("|")+")",qi+"?"+Na+"+"+yl,qi+"+"+Cs,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Sn,mt].join("|"),"g"),ye=RegExp("[\\u200d\\ud800-\\udfff"+vn+oo+"]"),ht=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,fn=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Rn=-1,Cn={};Cn[Je]=Cn[gt]=Cn[le]=Cn[Ze]=Cn[pe]=Cn[se]=Cn[we]=Cn[$e]=Cn[rt]=!0,Cn[B]=Cn[F]=Cn[Ye]=Cn[I]=Cn[Be]=Cn[V]=Cn[z]=Cn[X]=Cn[W]=Cn[Q]=Cn[J]=Cn[Se]=Cn[Ae]=Cn[Pe]=Cn[ze]=!1;var nr={};nr[B]=nr[F]=nr[Ye]=nr[Be]=nr[I]=nr[V]=nr[Je]=nr[gt]=nr[le]=nr[Ze]=nr[pe]=nr[W]=nr[Q]=nr[J]=nr[Se]=nr[Ae]=nr[Pe]=nr[De]=nr[se]=nr[we]=nr[$e]=nr[rt]=!0,nr[z]=nr[X]=nr[ze]=!1;var Mn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},or=parseFloat,lr=parseInt,qr=typeof i=="object"&&i&&i.Object===Obj
|
|||
|
|
/* [wrapped with `+ce+`] */
|
|||
|
|
`)})(G,(function(te,ce){return Fa(P,(function(Oe){var Fe="_."+Oe[0];ce&Oe[1]&&!Za(te,Fe)&&te.push(Fe)})),te.sort()})((function(te){var ce=te.match(Ke);return ce?ce[1].split(Le):[]})(G),C)))}function cv(g){var x=0,C=0;return function(){var G=Ep(),te=16-(G-C);if(C=G,te>0){if(++x>=800)return arguments[0]}else x=0;return g.apply(l,arguments)}}function Bs(g,x){var C=-1,G=g.length,te=G-1;for(x=x===l?G:x;++C<x;){var ce=ev(C,te),Oe=g[ce];g[ce]=g[C],g[C]=Oe}return g.length=x,g}var dv=(function(g){var x=su(g,(function(G){return C.size===500&&C.clear(),G})),C=x.cache;return x})((function(g){var x=[];return g.charCodeAt(0)===46&&x.push(""),g.replace(Rt,(function(C,G,te,ce){x.push(te?ce.replace(Tt,"$1"):G||C)})),x}));function vs(g){if(typeof g=="string"||Dt(g))return g;var x=g+"";return x=="0"&&1/g==-1/0?"-0":x}function Ru(g){if(g!=null){try{return no.call(g)}catch{}try{return g+""}catch{}}return""}function Xp(g){if(g instanceof go)return g.clone();var x=new Ul(g.__wrapped__,g.__chain__);return x.__actions__=va(g.__actions__),x.__index__=g.__index__,x.__values__=g.__values__,x}var Cm=uo((function(g,x){return Oi(g)?cs(g,Ji(x,1,Oi,!0)):[]})),Nm=uo((function(g,x){var C=gi(x);return Oi(C)&&(C=l),Oi(g)?cs(g,Ji(x,1,Oi,!0),Rr(C,2)):[]})),km=uo((function(g,x){var C=gi(x);return Oi(C)&&(C=l),Oi(g)?cs(g,Ji(x,1,Oi,!0),l,C):[]}));function fv(g,x,C){var G=g==null?0:g.length;if(!G)return-1;var te=C==null?0:Mt(C);return te<0&&(te=ji(G+te,0)),$a(g,Rr(x,3),te)}function Yp(g,x,C){var G=g==null?0:g.length;if(!G)return-1;var te=G-1;return C!==l&&(te=Mt(C),te=C<0?ji(G+te,0):Wa(te,G-1)),$a(g,Rr(x,3),te,!0)}function Cf(g){return g!=null&&g.length?Ji(g,1):[]}function Pm(g){return g&&g.length?g[0]:l}var ms=uo((function(g){var x=Mo(g,jp);return x.length&&x[0]===g[0]?mf(x):[]})),Du=uo((function(g){var x=gi(g),C=Mo(g,jp);return x===gi(C)?x=l:C.pop(),C.length&&C[0]===g[0]?mf(C,Rr(x,2)):[]})),_y=uo((function(g){var x=gi(g),C=Mo(g,jp);return(x=typeof x=="function"?x:l)&&C.pop(),C.length&&C[0]===g[0]?mf(C,l,x):[]}));function gi(g){var x=g==null?0:g.length;return x?g[x-1]:l}var Nf=uo(Ac);function Ac(g,x){return g&&g.length&&x&&x.length?Np(g,x):g}var kf=Ls((function(g,x){var C=g==null?0:g.length,G=hf(g,x);return Qh(g,Mo(x,(function(te){return Ra(te,C)?+te:te})).sort(vd)),G}));function Ed(g){return g==null?g:dy.call(g)}var Pf=uo((function(g){return Tu(Ji(g,1,Oi,!0))})),Rf=uo((function(g){var x=gi(g);return Oi(x)&&(x=l),Tu(Ji(g,1,Oi,!0),Rr(x,2))})),Df=uo((function(g){var x=gi(g);return x=typeof x=="function"?x:l,Tu(Ji(g,1,Oi,!0),l,x)}));function Mc(g){if(!g||!g.length)return[];var x=0;return g=Ba(g,(function(C){if(Oi(C))return x=ji(C.length,x),!0})),Ks(x,(function(C){return Mo(g,Ua(C))}))}function au(g,x){if(!g||!g.length)return[];var C=Mc(g);return x==null?C:Mo(C,(function(G){return qo(x,l,G)}))}var ma=uo((function(g,x){return Oi(g)?cs(g,x):[]})),qp=uo((function(g){return Dp(Ba(g,Oi))})),jf=uo((function(g){var x=gi(g);return Oi(x)&&(x=l),Dp(Ba(g,Oi),Rr(x,2))})),Tc=uo((function(g){var x=gi(g);return x=typeof x=="function"?x:l,Dp(Ba(g,Oi),l,x)})),xd=uo(Mc),wa=uo((function(g){var x=g.length,C=x>1?g[x-1]:l;return C=typeof C=="function"?(g.pop(),C):l,au(g,C)}));function xi(g){var x=he(g);return x.__chain__=!0,x}function Lf(g,x){return x(g)}var za=Ls((function(g){var x=g.length,C=x?g[0]:0,G=this.__wrapped__,te=function(ce){return hf(ce,g)};return!(x>1||this.__actions__.length)&&G instanceof go&&Ra(C)?((G=G.slice(C,+C+(x?1:0))).__actions__.push({func:Lf,args:[te],thisArg:l}),new Ul(G,this.__chain__).thru((function(ce){return x&&!ce.length&&ce.push(l),ce}))):this.thru(te)})),wr=ou((function(g,x,C){$n.call(g,C)?++g[C]:us(g,C,1)})),Kp=Bp(fv),If=Bp(Yp);function Zp(g,x){return(Jr(g)?Fa:mi)(g,Rr(x,3))}function pv(g,x){return(Jr(g)?gp:ym)(g,Rr(x,3))}var Rm=ou((function(g,x,C){$n.call(g,C)?g[C].push(x):us(g,C,[x])})),ju=uo((function(g,x,C){var G=-1,te=typeof x=="function",ce=fl(g)?Gn(g.length):[];return mi(g,(function(Oe){ce[++G]=te?qo(x,Oe,C):Ga(Oe,x,C)})),ce})),Dm=ou((function(g,x,C){us(g,C,x)}));function Cc(g,x){return(Jr(g)?Mo:Ml)(g,Rr(x,3))}var jm=ou((function(g,x,C){g[C?0:1].
|
|||
|
|
`;g.replace(Yn,(function(Tn,Br,ir,at,Yr,Ao){return ir||(ir=at),yn+=g.slice(jt,Ao).replace(ut,sc),Br&&(te=!0,yn+=`' +
|
|||
|
|
__e(`+Br+`) +
|
|||
|
|
'`),Yr&&(ce=!0,yn+=`';
|
|||
|
|
`+Yr+`;
|
|||
|
|
__p += '`),ir&&(yn+=`' +
|
|||
|
|
((__t = (`+ir+`)) == null ? '' : __t) +
|
|||
|
|
'`),jt=Ao+Tn.length,Tn})),yn+=`';
|
|||
|
|
`;var Sr=$n.call(x,"variable")&&x.variable;if(Sr){if(At.test(Sr))throw new mo("Invalid `variable` option passed into `_.template`")}else yn=`with (obj) {
|
|||
|
|
`+yn+`
|
|||
|
|
}
|
|||
|
|
`;yn=(ce?yn.replace(pt,""):yn).replace(Lt,"$1").replace(Jt,"$1;"),yn="function("+(Sr||"obj")+`) {
|
|||
|
|
`+(Sr?"":`obj || (obj = {});
|
|||
|
|
`)+"var __t, __p = ''"+(te?", __e = _.escape":"")+(ce?`, __j = Array.prototype.join;
|
|||
|
|
function print() { __p += __j.call(arguments, '') }
|
|||
|
|
`:`;
|
|||
|
|
`)+yn+`return __p
|
|||
|
|
}`;var an=Cr((function(){return ci(Fe,Qn+"return "+yn).apply(l,et)}));if(an.source=yn,Ea(an))throw an;return an},he.times=function(g,x){if((g=Mt(g))<1||g>T)return[];var C=D,G=Wa(g,D);x=Rr(x),g-=D;for(var te=Ks(G,x);++C<g;)x(C);return te},he.toFinite=nn,he.toInteger=Mt,he.toLength=wn,he.toLower=function(g){return Wt(g).toLowerCase()},he.toNumber=pn,he.toSafeInteger=function(g){return g?Au(Mt(g),-9007199254740991,T):g===0?g:0},he.toString=Wt,he.toUpper=function(g){return Wt(g).toUpperCase()},he.trim=function(g,x,C){if((g=Wt(g))&&(C||x===l))return $l(g);if(!g||!(x=cl(x)))return g;var G=Qa(g),te=Qa(x);return Uo(G,xl(G,te),af(G,te)+1).join("")},he.trimEnd=function(g,x,C){if((g=Wt(g))&&(C||x===l))return g.slice(0,ia(g)+1);if(!g||!(x=cl(x)))return g;var G=Qa(g);return Uo(G,0,af(G,Qa(x))+1).join("")},he.trimStart=function(g,x,C){if((g=Wt(g))&&(C||x===l))return g.replace(qt,"");if(!g||!(x=cl(x)))return g;var G=Qa(g);return Uo(G,xl(G,Qa(x))).join("")},he.truncate=function(g,x){var C=30,G="...";if(Ni(x)){var te="separator"in x?x.separator:te;C="length"in x?Mt(x.length):C,G="omission"in x?cl(x.omission):G}var ce=(g=Wt(g)).length;if(os(g)){var Oe=Qa(g);ce=Oe.length}if(C>=ce)return g;var Fe=C-Va(G);if(Fe<1)return G;var et=Oe?Uo(Oe,0,Fe).join(""):g.slice(0,Fe);if(te===l)return et+G;if(Oe&&(Fe+=et.length-Fe),me(te)){if(g.slice(Fe).search(te)){var jt,Vt=et;for(te.global||(te=Z(te.source,Wt(Zn.exec(te))+"g")),te.lastIndex=0;jt=te.exec(Vt);)var yn=jt.index;et=et.slice(0,yn===l?Fe:yn)}}else if(g.indexOf(cl(te),Fe)!=Fe){var Yn=et.lastIndexOf(te);Yn>-1&&(et=et.slice(0,Yn))}return et+G},he.unescape=function(g){return(g=Wt(g))&&it.test(g)?g.replace(en,sl):g},he.uniqueId=function(g){var x=++Do;return Wt(g)+x},he.upperCase=la,he.upperFirst=zi,he.each=Zp,he.eachRight=pv,he.first=Pm,Te(he,(Ue={},ur(he,(function(g,x){$n.call(he.prototype,x)||(Ue[x]=g)})),Ue),{chain:!1}),he.VERSION="4.17.21",Fa(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(g){he[g].placeholder=he})),Fa(["drop","take"],(function(g,x){go.prototype[g]=function(C){C=C===l?1:ji(Mt(C),0);var G=this.__filtered__&&!x?new go(this):this.clone();return G.__filtered__?G.__takeCount__=Wa(C,G.__takeCount__):G.__views__.push({size:Wa(C,D),type:g+(G.__dir__<0?"Right":"")}),G},go.prototype[g+"Right"]=function(C){return this.reverse()[g](C).reverse()}})),Fa(["filter","map","takeWhile"],(function(g,x){var C=x+1,G=C==1||C==3;go.prototype[g]=function(te){var ce=this.clone();return ce.__iteratees__.push({iteratee:Rr(te,3),type:C}),ce.__filtered__=ce.__filtered__||G,ce}})),Fa(["head","last"],(function(g,x){var C="take"+(x?"Right":"");go.prototype[g]=function(){return this[C](1).value()[0]}})),Fa(["initial","tail"],(function(g,x){var C="drop"+(x?"":"Right");go.prototype[g]=function(){return this.__filtered__?new go(this):this[C](1)}})),go.prototype.compact=function(){return this.filter(Nr)},go.prototype.find=function(g){return this.filter(g).head()},go.prototype.findLast=function(g){return this.reverse().find(g)},go.prototype.invokeMap=uo((function(g,x){return typeof g=="function"?new go(this):this.map((function(C){return Ga(C,g,x)}))})),go.prototype.reject=function(g){return this.filter(Bf(Rr(g)))},go.prototype.slice=function(g,x){g=Mt(g);var C=this;return C.__filtered__&&(g>0||x<0)?new go(C):(g<0?C=C.takeRight(-g):g&&(C=C.drop(g)),x!==l&&(C=(x=Mt(x))<0?C.dropRight(-x):C.take(x-g)),C)},go.prototype.takeRightWhile=function(g){return this.reverse().takeWhile(g).reverse()},go.prototype.toArray=function(){return this.take(D)},ur(go.prototype,(function(g,x){var C=/^(?:filter|find|map|reject)|While$/.test(x),G=/^(?:head|last)$/.test(x),te=he[G?"take"+(x=="last"?"Right":""):x],ce=G||/^find/.test(x);te&&(he.prototype[x]=function(){var Oe=this.__wrapped__,Fe=G?[1]:arguments,et=Oe instanceof go,jt=Fe[0],Vt=et||Jr(Oe),yn=function(Br){var ir=te.apply(he,oa([Br],Fe));return G&&Yn?ir[0]:ir};Vt&&C&&typeof jt=="function"&&jt.length!=1&&(et=Vt=!1);var Yn=this.__chain__,Qn=!!this.__actions__.length,Sr=ce&&!Yn,an=et&&!Qn;if(!ce&&Vt){Oe=an?Oe:new go(this);var Tn=g.apply(Oe,Fe);return Tn.__actions
|
|||
|
|
\v\f\r \u2028\u2029\uFEFF`},function(n,o){var r,i,a=n.exports={};function s(){throw new Error("setTimeout has not been defined")}function l(){throw new Error("clearTimeout has not been defined")}function f(T){if(r===setTimeout)return setTimeout(T,0);if((r===s||!r)&&setTimeout)return r=setTimeout,setTimeout(T,0);try{return r(T,0)}catch{try{return r.call(null,T,0)}catch{return r.call(this,T,0)}}}(function(){try{r=typeof setTimeout=="function"?setTimeout:s}catch{r=s}try{i=typeof clearTimeout=="function"?clearTimeout:l}catch{i=l}})();var h,v=[],b=!1,E=-1;function O(){b&&h&&(b=!1,h.length?v=h.concat(v):E=-1,v.length&&w())}function w(){if(!b){var T=f(O);b=!0;for(var $=v.length;$;){for(h=v,v=[];++E<$;)h&&h[E].run();E=-1,$=v.length}h=null,b=!1,(function(D){if(i===clearTimeout)return clearTimeout(D);if((i===l||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(D);try{i(D)}catch{try{return i.call(null,D)}catch{return i.call(this,D)}}})(T)}}function S(T,$){this.fun=T,this.array=$}function M(){}a.nextTick=function(T){var $=new Array(arguments.length-1);if(arguments.length>1)for(var D=1;D<arguments.length;D++)$[D-1]=arguments[D];v.push(new S(T,$)),v.length!==1||b||f(w)},S.prototype.run=function(){this.fun.apply(null,this.array)},a.title="browser",a.browser=!0,a.env={},a.argv=[],a.version="",a.versions={},a.on=M,a.addListener=M,a.once=M,a.off=M,a.removeListener=M,a.removeAllListeners=M,a.emit=M,a.prependListener=M,a.prependOnceListener=M,a.listeners=function(T){return[]},a.binding=function(T){throw new Error("process.binding is not supported")},a.cwd=function(){return"/"},a.chdir=function(T){throw new Error("process.chdir is not supported")},a.umask=function(){return 0}},function(n,o,r){var i=r(32),a=r(165),s=r(28)("species");n.exports=function(l,f){var h,v=i(l).constructor;return v===void 0||(h=i(v)[s])==null?f:a(h)}},function(n,o,r){var i=r(7),a=r(99),s=r(88),l=i.TypeError;n.exports=function(f){if(a(f))return f;throw l(s(f)+" is not a constructor")}},function(n,o,r){var i=r(16),a=r(161).trim;i({target:"String",proto:!0,forced:r(200)("trim")},{trim:function(){return a(this)}})},function(n,o,r){var i=r(34),a=r(123),s=r(32),l=r(94),f=r(39),h=r(44),v=r(62),b=r(124),E=r(125);a("match",(function(O,w,S){return[function(M){var T=h(this),$=M==null?void 0:v(M,O);return $?i($,M,T):new RegExp(M)[O](f(T))},function(M){var T=s(this),$=f(M),D=S(w,T,$);if(D.done)return D.value;if(!T.global)return E(T,$);var P=T.unicode;T.lastIndex=0;for(var B,F=[],I=0;(B=E(T,$))!==null;){var V=f(B[0]);F[I]=V,V===""&&(T.lastIndex=b($,l(T.lastIndex),P)),I++}return I===0?null:F}]}))},function(n,o,r){var i,a,s,l,f=r(7),h=r(76),v=r(64),b=r(30),E=r(35),O=r(18),w=r(138),S=r(98),M=r(91),T=r(169),$=r(128),D=f.setImmediate,P=f.clearImmediate,B=f.process,F=f.Dispatch,I=f.Function,V=f.MessageChannel,z=f.String,X=0,Y={},W="onreadystatechange";try{i=f.location}catch{}var Q=function(Ae){if(E(Y,Ae)){var Pe=Y[Ae];delete Y[Ae],Pe()}},J=function(Ae){return function(){Q(Ae)}},ie=function(Ae){Q(Ae.data)},Se=function(Ae){f.postMessage(z(Ae),i.protocol+"//"+i.host)};D&&P||(D=function(Ae){var Pe=S(arguments,1);return Y[++X]=function(){h(b(Ae)?Ae:I(Ae),void 0,Pe)},a(X),X},P=function(Ae){delete Y[Ae]},$?a=function(Ae){B.nextTick(J(Ae))}:F&&F.now?a=function(Ae){F.now(J(Ae))}:V&&!T?(l=(s=new V).port2,s.port1.onmessage=ie,a=v(l.postMessage,l)):f.addEventListener&&b(f.postMessage)&&!f.importScripts&&i&&i.protocol!=="file:"&&!O(Se)?(a=Se,f.addEventListener("message",ie,!1)):a=W in M("script")?function(Ae){w.appendChild(M("script")).onreadystatechange=function(){w.removeChild(this),Q(Ae)}}:function(Ae){setTimeout(J(Ae),0)}),n.exports={set:D,clear:P}},function(n,o,r){var i=r(55);n.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(i)},function(n,o,r){var i=r(56),a=function(s){var l,f;this.promise=new s((function(h,v){if(l!==void 0||f!==void 0)throw TypeError("Bad Promise constructor");l=h,f=v})),this.resolve=i(l),this.reject=i(f)};n.exports.f=function(s){return new a(s)}},function(n,o,r){o.a=function(){return!1}},function(n,o,r){(function(i){r.d(o,"
|
|||
|
|
`)&&s.flags==="s")}))},function(n,o,r){var i=r(18),a=r(7).RegExp;n.exports=i((function(){var s=a("(?<a>b)","g");return s.exec("b").groups.a!=="b"||"b".replace(s,"$<a>c")!=="bc"}))},function(n,o,r){var i=r(16),a=r(15),s=r(56),l=r(40),f=r(45),h=r(39),v=r(18),b=r(193),E=r(121),O=r(194),w=r(195),S=r(70),M=r(196),T=[],$=a(T.sort),D=a(T.push),P=v((function(){T.sort(void 0)})),B=v((function(){T.sort(null)})),F=E("sort"),I=!v((function(){if(S)return S<70;if(!(O&&O>3)){if(w)return!0;if(M)return M<603;var V,z,X,Y,W="";for(V=65;V<76;V++){switch(z=String.fromCharCode(V),V){case 66:case 69:case 70:case 72:X=3;break;case 68:case 71:X=4;break;default:X=2}for(Y=0;Y<47;Y++)T.push({k:z+Y,v:X})}for(T.sort((function(Q,J){return J.v-Q.v})),Y=0;Y<T.length;Y++)z=T[Y].k.charAt(0),W.charAt(W.length-1)!==z&&(W+=z);return W!=="DGBEFHACIJK"}}));i({target:"Array",proto:!0,forced:P||!B||!F||!I},{sort:function(V){V!==void 0&&s(V);var z=l(this);if(I)return V===void 0?$(z):$(z,V);var X,Y,W=[],Q=f(z);for(Y=0;Y<Q;Y++)Y in z&&D(W,z[Y]);for(b(W,(function(J){return function(ie,Se){return Se===void 0?-1:ie===void 0?1:J!==void 0?+J(ie,Se)||0:h(ie)>h(Se)?1:-1}})(V)),X=W.length,Y=0;Y<X;)z[Y]=W[Y++];for(;Y<Q;)delete z[Y++];return z}})},function(n,o,r){var i=r(114),a=Math.floor,s=function(h,v){var b=h.length,E=a(b/2);return b<8?l(h,v):f(h,s(i(h,0,E),v),s(i(h,E),v),v)},l=function(h,v){for(var b,E,O=h.length,w=1;w<O;){for(E=w,b=h[w];E&&v(h[E-1],b)>0;)h[E]=h[--E];E!==w++&&(h[E]=b)}return h},f=function(h,v,b,E){for(var O=v.length,w=b.length,S=0,M=0;S<O||M<w;)h[S+M]=S<O&&M<w?E(v[S],b[M])<=0?v[S++]:b[M++]:S<O?v[S++]:b[M++];return h};n.exports=s},function(n,o,r){var i=r(55).match(/firefox\/(\d+)/i);n.exports=!!i&&+i[1]},function(n,o,r){var i=r(55);n.exports=/MSIE|Trident/.test(i)},function(n,o,r){var i=r(55).match(/AppleWebKit\/(\d+)\./);n.exports=!!i&&+i[1]},function(n,o,r){var i=r(7),a=r(159),s=i.TypeError;n.exports=function(l){if(a(l))throw s("The method doesn't accept regular expressions");return l}},function(n,o,r){var i=r(28)("match");n.exports=function(a){var s=/./;try{"/./"[a](s)}catch{try{return s[i]=!1,"/./"[a](s)}catch{}}return!1}},function(n,o,r){r(16)({target:"Number",stat:!0},{isNaN:function(i){return i!=i}})},function(n,o,r){var i=r(73).PROPER,a=r(18),s=r(162);n.exports=function(l){return a((function(){return!!s[l]()||"
"[l]()!=="
"||i&&s[l].name!==l}))}},function(n,o,r){var i=r(15),a=r(40),s=Math.floor,l=i("".charAt),f=i("".replace),h=i("".slice),v=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,b=/\$([$&'`]|\d{1,2})/g;n.exports=function(E,O,w,S,M,T){var $=w+E.length,D=S.length,P=b;return M!==void 0&&(M=a(M),P=v),f(T,P,(function(B,F){var I;switch(l(F,0)){case"$":return"$";case"&":return E;case"`":return h(O,0,w);case"'":return h(O,$);case"<":I=M[h(F,1,-1)];break;default:var V=+F;if(V===0)return B;if(V>D){var z=s(V/10);return z===0?B:z<=D?S[z-1]===void 0?l(F,1):S[z-1]+l(F,1):B}I=S[V-1]}return I===void 0?"":I}))}},function(n,o,r){var i=r(36),a=r(15),s=r(34),l=r(18),f=r(77),h=r(112),v=r(84),b=r(40),E=r(85),O=Object.assign,w=Object.defineProperty,S=a([].concat);n.exports=!O||l((function(){if(i&&O({b:1},O(w({},"a",{enumerable:!0,get:function(){w(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var M={},T={},$=Symbol(),D="abcdefghijklmnopqrst";return M[$]=7,D.split("").forEach((function(P){T[P]=P})),O({},M)[$]!=7||f(O({},T)).join("")!=D}))?function(M,T){for(var $=b(M),D=arguments.length,P=1,B=h.f,F=v.f;D>P;)for(var I,V=E(arguments[P++]),z=B?S(f(V),B(V)):f(V),X=z.length,Y=0;X>Y;)I=z[Y++],i&&!s(F,V,I)||($[I]=V[I]);return $}:O},function(n,o,r){var i=r(7),a=r(15),s=r(56),l=r(33),f=r(35),h=r(98),v=i.Function,b=a([].concat),E=a([].join),O={},w=function(S,M,T){if(!f(O,M)){for(var $=[],D=0;D<M;D++)$[D]="a["+D+"]";O[M]=v("C,a","return new C("+E($,",")+")")}return O[M](S,T)};n.exports=v.bind||function(S){var M=s(this),T=M.prototype,$=h(arguments,1),D=function(){var P=b($,h(arguments));return this instanceof D?w(M,P.length,P):M.apply(S,P)};return l(T)&&(D.prototype=T),D}},function(n,o,r){var i=r(35);n.exports=function(a){return a!==void 0&&(i(a,"value")||i(a,"writ
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function ru(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function Wl(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function _m(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function js(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function Ml(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}(function(c){c[c.DEFAULT=0]="DEFAULT",c[c.INCREASE=1]="INCREASE"})(Ei||(Ei={}));var Zh={false:[-1/0,-1/0,1/0,1/0],true:[0,0,0,0],vertical:[-1/0,0,1/0,0],horizontal:[0,-1/0,0,1/0]},Jh=(Mi=(function(){function c(p,y){(function(A,N){if(!(A instanceof N))throw new TypeError("Cannot call a class as a function")})(this,c),js(this,"MINI_SCALE_SIZE",.2),js(this,"MAX_SCALE_SIZE",16),Wl(this,"SCALE_X",qh,this),Wl(this,"SKEW_Y",Kh,this),Wl(this,"SKEW_X",mf,this),Wl(this,"SCALE_Y",Ga,this),Wl(this,"TRANSLATE_X",Tp,this),Wl(this,"TRANSLATE_Y",hd,this),Wl(this,"ZOOM_SIZE",Vl,this),js(this,"eventCenter",void 0),js(this,"translateLimitMinX",void 0),js(this,"translateLimitMinY",void 0),js(this,"translateLimitMaxX",void 0),js(this,"translateLimitMaxY",void 0),this.eventCenter=p;var m=y.stopMoveGraph,_=m!==void 0&&m;this.updateTranslateLimits(_)}var u,d;return u=c,d=[{key:"setZoomMiniSize",value:function(p){this.MINI_SCALE_SIZE=p}},{key:"setZoomMaxSize",value:function(p){this.MAX_SCALE_SIZE=p}},{key:"HtmlPointToCanvasPoint",value:function(p){var y=Mu(p,2),m=y[0],_=y[1];return[(m-this.TRANSLATE_X)/this.SCALE_X,(_-this.TRANSLATE_Y)/this.SCALE_Y]}},{key:"CanvasPointToHtmlPoint",value:function(p){var y=Mu(p,2),m=y[0],_=y[1];return[m*this.SCALE_X+this.TRANSLATE_X,_*this.SCALE_Y+this.TRANSLATE_Y]}},{key:"moveCanvasPointByHtml",value:function(p,y,m){var _=Mu(p,2),A=_[0],N=_[1];return[A+y/this.SCALE_X,N+m/this.SCALE_Y]}},{key:"fixDeltaXY",value:function(p,y){return[p/this.SCALE_X,y/this.SCALE_Y]}},{key:"getTransformStyle",value:function(){var p=[this.SCALE_X,this.SKEW_Y,this.SKEW_X,this.SCALE_Y,this.TRANSLATE_X,this.TRANSLATE_Y].join(",");return{transform:"matrix(".concat(p,")")}}},{key:"zoom",value:function(){var p=arguments.length>0&&arguments[0]!==void 0&&arguments[0],y=arguments.length>1?arguments[1]:void 0,m=this.SCALE_X,_=this.SCALE_Y;return p===!0?(m+=this.ZOOM_SIZE,_+=this.ZOOM_SIZE):p===!1?(m-=this.ZOOM_SIZE,_-=this.ZOOM_SIZE):typeof p=="number"&&(m=p,_=p),m<this.MINI_SCALE_SIZE||m>this.MAX_SCALE_SIZE||(y&&(this.TRANSLATE_X-=(m-this.SCALE_X)*y[0],this.TRANSLATE_Y-=(_-this.SCALE_Y)*y[1]),this.SCALE_X=m,this.SCALE_Y=_,this.emitGraphTransform("zoom")),"".concat(100*this.SCALE_X,"%")}},{key:"emitGraphTransform",value:function(p){this.eventCenter.emit(ur.GRAPH_TRANSFORM,{type:p,transform:{SCALE_X:this.SCALE_X,SKEW_Y:this.SKEW_Y,SKEW_X:this.SKEW_X,SCALE_Y:this.SCALE_Y,TRANSLATE_X:this.TRANSLATE_X,TRANSLATE_Y:this.TRANSLATE_Y}})}},{key:"resetZoom",value:function(){this.SCALE_X=1,this.SCALE_Y=1,this.emitGraphTransform("resetZoom")}},{key:"translate",value:function(p,y){this.TRANSLATE_X+p<=this.translateLimitMaxX&&this.TRANSLATE_X+p>=this.translateLimitMinX&&(this.TRANSLATE_X+=p),this.TRANSLATE_Y+y<=this.translateLimitMaxY&&this.TRANSLATE_Y+y>=this.translateLimitMinY&&(this.TRANSLATE_Y+=y),this.emitGraphTransform("translate")}},{key:"focusOn",value:function(p,y,m,_){var A=Mu(this.CanvasPointToHtmlPoint([p,y]),2),N=m/2-A[0],U=_/2-A[1];this.TRANSLATE_X+=N,this.TRANSLATE_Y+=U,this.emit
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function md(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}var gd=function(c,u,d){var p=Ef(c,2),y=p[0],m=p[1],_=Ef(u,2),A=_[0],N=_[1],U=Ef(d,2),H=U[0],oe=U[1];return y>A&&y<H&&m>N&&m<oe},yd=function(c,u){var d=!1;switch(u.multipleSelectKey){case"meta":d=c.metaKey;break;case"alt":d=c.altKey;break;case"shift":d=c.shiftKey;break;case"ctrl":d=c.ctrlKey;break;default:d=!1}return d};r(167),r(126),r(83),r(29),r(12),r(13),r(14),r(47);var $p=function(c){return function(u,d,p){var y=Object(u);if(!Wi(u)){var m=cf(d);u=sc(u),d=function(A){return m(y[A],A,y)}}var _=c(u,d,p);return _>-1?y[m?u[_]:_]:void 0}},_d=function(c,u,d,p){for(var y=c.length,m=d+-1;++m<y;)if(u(c[m],m,c))return m;return-1},ov=/\s/,Up=function(c){for(var u=c.length;u--&&ov.test(c.charAt(u)););return u},Tm=/^\s+/,iv=function(c){return c&&c.slice(0,Up(c)+1).replace(Tm,"")},ps=/^[-+]0x[0-9a-f]+$/i,av=/^0b[01]+$/i,lv=/^0o[0-7]+$/i,sv=parseInt,bd=function(c){if(typeof c=="number")return c;if(Kr(c))return NaN;if(In(c)){var u=typeof c.valueOf=="function"?c.valueOf():c;c=In(u)?u+"":u}if(typeof c!="string")return c===0?c:+c;c=iv(c);var d=av.test(c);return d||lv.test(c)?sv(c.slice(2),d?2:8):ps.test(c)?NaN:+c},Ls=1/0,xf=function(c){return c?(c=bd(c))===Ls||c===-1/0?17976931348623157e292*(c<0?-1:1):c==c?c:0:c===0?c:0},Vp=function(c){var u=xf(c),d=u%1;return u==u?d?u-d:u:0},Wp=Math.max,Cu,Nu=$p((function(c,u,d){var p=c==null?0:c.length;if(!p)return-1;var y=d==null?0:Vp(d);return y<0&&(y=Wp(p+y,0)),_d(c,cf(u),y)})),Rr=new Uint8Array(16);function wd(){if(!Cu&&!(Cu=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Cu(Rr)}for(var Of=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,hs=function(c){return typeof c=="string"&&Of.test(c)},aa=[],Ec=0;Ec<256;++Ec)aa.push((Ec+256).toString(16).substr(1));var Ti=function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,d=(aa[c[u+0]]+aa[c[u+1]]+aa[c[u+2]]+aa[c[u+3]]+"-"+aa[c[u+4]]+aa[c[u+5]]+"-"+aa[c[u+6]]+aa[c[u+7]]+"-"+aa[c[u+8]]+aa[c[u+9]]+"-"+aa[c[u+10]]+aa[c[u+11]]+aa[c[u+12]]+aa[c[u+13]]+aa[c[u+14]]+aa[c[u+15]]).toLowerCase();if(!hs(d))throw TypeError("Stringified UUID is invalid");return d},ku=function(c,u,d){var p=(c=c||{}).random||(c.rng||wd)();return p[6]=15&p[6]|64,p[8]=63&p[8]|128,Ti(p)},tl=function(){return ku()},Sf=function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",d=c.nodes.reduce((function(p,y){return p[y.id]=u+ku(),y.id=p[y.id],p}),{});return c.edges.forEach((function(p){p.id=u+ku(),p.sourceNodeId=d[p.sourceNodeId],p.targetNodeId=d[p.targetNodeId]})),c},Ra=(r(105),r(127),r(207),function(c,u,d){var p=c.x,y=c.y,m=u.x,_=u.y,A=d.x,N=d.y,U=(N-_)/(A-m),H=_-U*m;return p>=m&&p<=A&&y>=_&&y<=N&&Math.abs(y-U*p+H)<Number.EPSILON});function Fi(c){return Fi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Fi(c)}function Is(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function Fs(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?Is(Object(d),!0).forEach((function(p){Gp(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):Is(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function Gp(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writa
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function Ha(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function gs(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function Ci(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?gs(Object(d),!0).forEach((function(p){mv(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):gs(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function dl(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function zl(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function by(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function $f(){return $f=typeof Reflect<"u"&&Reflect.get?Reflect.get:function(c,u,d){var p=Nc(c,u);if(p){var y=Object.getOwnPropertyDescriptor(p,u);return y.get?y.get.call(arguments.length<3?c:d):y.value}},$f.apply(this,arguments)}function Nc(c,u){for(;!Object.prototype.hasOwnProperty.call(c,u)&&(c=nl(c))!==null;);return c}function Jr(c,u){return Jr=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Jr(c,u)}function Im(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=nl(c);if(u){var y=nl(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return fl(this,d)}}function fl(c,u){if(u&&(su(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Oi(c)}function Oi(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function nl(c){return nl=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},nl(c)}function mv(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function Ea(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}var Cl=(Er=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&Jr(m,_)})(y,c);var u,d,p=Im(y);function y(){var m;zl(this,y);for(var _=arguments.length,A=new Array(_),N=0;N<_;N++)A[N]=arguments[N];return mv(Oi(m=p.call.apply(p,[this].concat(A))),"modelType",lo.POLYLINE_EDGE),mv(Oi(m),"draggingPointList",void 0),dl(Oi(m),"dbClickPosition",vv,Oi(m)),m}return u=y,(d=[{key:"initEdgeData",value:function(m){this.offset=30,$f(nl(y.prototype),"initEdgeData",this).call(this,m)}},{key:"getEdgeStyle",value:function(){var m=this.graphModel.theme.polyline;return Ci(Ci({},$f(nl(y.prototype),"getEdgeStyle",this).call(this)),Uo(m))}},{key:"getTextPosition",value:function(){var m,_=(m=this.text)===null||m===void 0?void 0:m.value;if(this.dbClickPosition&&!_){var A=this.dbClickPosition;return{x:A.x,y:A.y}}var N=jr(this.points),U=Bf(Or(N),2),H=U[0],oe=U[1];return{x:(H.x+oe.x)/2,y:(H.y+oe.y)/2}}},{ke
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function Dt(c){return Dt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Dt(c)}function yt(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||Nt(c,u)||(function(){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 Nt(c,u){if(c){if(typeof c=="string")return tn(c,u);var d=Object.prototype.toString.call(c).slice(8,-1);return d==="Object"&&c.constructor&&(d=c.constructor.name),d==="Map"||d==="Set"?Array.from(c):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?tn(c,u):void 0}}function tn(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}var sn=function(c,u){var d;switch(c.type){case"line":default:d=new Od(c,u);break;case"polyline":d=new Cl(c,u)}return d},nn=function(c,u){return 2*Math.abs(c.centerX-u.centerX)<c.width+u.width&&2*Math.abs(c.centerY-u.centerY)<c.height+u.height},Mt=function(c){var u=[],d={};return c.forEach((function(p){var y="".concat(p.x,"-").concat(p.y);p.id=y,d[y]=p})),Object.keys(d).forEach((function(p){u.push(d[p])})),u},wn=function(c,u){var d=[c,{x:c.x,y:u.y},u];return Mt(d)},pn=function(c,u){return c.width===0&&c.height===0?c:{centerX:c.centerX,centerY:c.centerY,minX:c.minX-u,minY:c.minY-u,maxX:c.maxX+u,maxY:c.maxY+u,height:c.height+2*u,width:c.width+2*u}},rn=function(c,u){var d=Math.abs(c.x-u.centerX),p=Math.abs(c.y-u.centerY);return d/u.width>p/u.height?ti.HORIZONTAL:ti.VERTICAL},Wt=function(c,u,d){return rn(d,u)===ti.HORIZONTAL?{x:d.x>c.centerX?c.maxX:c.minX,y:d.y}:{x:d.x,y:d.y>c.centerY?c.maxY:c.minY}},st=function(c,u){var d=Math.min(c.minX,u.minX),p=Math.min(c.minY,u.minY),y=Math.max(c.maxX,u.maxX),m=Math.max(c.maxY,u.maxY);return{centerX:(d+y)/2,centerY:(p+m)/2,minX:d,minY:p,maxX:y,maxY:m,height:m-p,width:y-d}},St=function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=arguments.length>1?arguments[1]:void 0,d=[],p=[];c.forEach((function(H){d.push(H.x),p.push(H.y)}));var y=Math.min.apply(Math,d),m=Math.max.apply(Math,d),_=Math.min.apply(Math,p),A=Math.max.apply(Math,p),N=m-y,U=A-_;return u&&(N+=u,U+=u),{centerX:(y+m)/2,centerY:(_+A)/2,maxX:m,maxY:A,minX:y,minY:_,x:(y+m)/2,y:(_+A)/2,height:U,width:N}},ln=function(c){var u=c.minX,d=c.minY,p=c.maxX,y=c.maxY;return[{x:u,y:d},{x:p,y:d},{x:p,y},{x:u,y}]},An=function(c,u){var d=c.x,p=c.y;return d<u.minX||d>u.maxX||p<u.minY||p>u.maxY},Xt=function(c,u){return u<c.minX||u>c.maxX?[]:[{x:u,y:c.minY},{x:u,y:c.maxY}]},kn=function(c,u){return u<c.minY||u>c.maxY?[]:[{x:c.minX,y:u},{x:c.maxX,y:u}]},Kt=function(c,u){return Xt(c,u.x).concat(kn(c,u.y))},_n=function(c,u){return Math.abs(c.x-u.x)+Math.abs(c.y-u.y)},Yt=function(c,u){var d=0;return u.forEach((function(p){p&&(c.x===p.x&&(d+=-2),c.y===p.y&&(d+=-2))})),d},xn=function(c,u,d,p,y){return _n(c,u)+_n(c,d)+Yt(c,[u,d,p,y])},ar=function c(u,d,p,y,m){m||(m=0),u.unshift(d[y]),p[y]&&p[y]!==y&&m<=100&&c(u,d,p,p[y],m+1)},xr=function(c,u){var d=c.indexOf(u);d>-1&&c.splice(d,1)},on=function(c,u,d,p){var y=u.x-c.x,m=u.y-c.y,_=p.x-d.x,A=p.y-d.y,N=(-m*(c.x-d.x)+y*(c.y-d.y))/(-_*m+y*A),U=(_*(c.y-d.y)-A*(c.x-d.x))/(-_*m+y*A);return N>=0&&N<=1&&U>=0&&U<=1},Zt=function(c,u,d){if(d.width===0&&d.height===0)return!1;var p=yt(ln(d),4),y=p[0],m=p[1],_=p[2],A=p[3];return on(c,u,y,m)||on(c,u,y,A)||on(c,u,m,_)||on(c,u,_,A)},Ht=function(c,u,d,p){var y=[];return c.forEach((function(m){m!==u&&(m.x!==u.x&&m.y!==u.y||Zt(m,u,d)||Zt(m,u,p)||y.push(m))})),Mt(y)},fr=function(c,u,d,p,y,m,_){var A=[],N=[u],U={},H={},oe={};H[u.id]=0,oe[u.id]=xn(u,d,u);var ue={};c.forEach((function(qe){ue[qe.id]=qe}));for(var Ce=function(){var qe=void 0,Ot=1/0;if(N.forEach((function(Ft){oe[Ft.id]<Ot&&(Ot=oe[Ft.id],qe=Ft)})),qe===d){var xt=[];return ar(xt,ue,U,d.id),{v:xt}}xr(N,qe),A.push(qe),Ht(c,qe,p,y).forEach((function(Ft){if(A.indexOf(Ft)===-1){N.indexOf(Ft)===-1&&N.push(Ft);var hn=oe[qe.id]+_n(qe,Ft);H[Ft.id]&&hn>=H[Ft.id]||(U[Ft.id]=qe.id,H[Ft.id]=hn,oe[Ft.id]=H[Ft.id]+xn(Ft,d,u,m,_))}}))};N.length;){var Ve=Ce();if(Dt(Ve)==="object")return Ve.v}return[u,d]},Dr=function(c){return gi(c)},Un=function(c){for(var u=1;u<c.length-1;){var d=c[u-1],p=c[u],y=c[u+1];d.x===p.x&&p.x===y.x||d.y===p.y&&p.y===y.y?c.splice(u,1):u++}return c},$r=function(c,u,d,p,y){var m=Dr(d),_=Dr(p),A=pn(m,y),N=pn(_,y),U=Wt
|
|||
|
|
L`).concat(m.rightX," ").concat(m.rightY,`
|
|||
|
|
L`).concat(_.rightX," ").concat(_.rightY,`
|
|||
|
|
L`).concat(_.leftX," ").concat(_.leftY," z")}return{d:u,fill:"transparent",stroke:"transparent",strokeWidth:1,strokeDasharray:"4, 4"}},zi=function(c){var u=c.start,d=c.end,p=c.sourceNode,y=c.targetNode,m=c.offset,_=gi(p),A=gi(y),N=pn(_,m),U=pn(A,m);return{sNext:Wt(N,_,u),ePre:Wt(U,A,d)}},di=function(c){var u=c.replace(/M/g,"").replace(/C/g,",").split(",");return[Cr(u[0]),Cr(u[1]),Cr(u[2]),Cr(u[3])]},Cr=function(c){var u=yt(c.replace(/(^\s*)/g,"").split(" "),2);return{x:+u[0],y:+u[1]}},sa=function(c,u){var d=yt(c,4);return[Ni(d[0],d[1],d[2],d[3],u),c[3]]},co=function(c,u){for(var d,p=c.x,y=c.y,m=jr(u),_=Number.MAX_SAFE_INTEGER,A=[],N=0;N<m.length;N++)A.push({start:m[N],end:m[(N+1)%m.length]});if(A.forEach((function(ue){var Ce=ue.start,Ve=ue.end;if(Ce.x===Ve.x){var qe={x:Ce.x,y};if(Ra(qe,Ce,Ve)){var Ot=Math.abs(Ce.x-p);Ot<_&&(_=Ot,d=qe)}}else if(Ce.y===Ve.y){var xt={x:p,y:Ce.y};if(Ra(xt,Ce,Ve)){var Ft=Math.abs(Ce.y-y);Ft<_&&(_=Ft,d=xt)}}})),!d){var U=A[0],H=U.start,oe=U.end;d={x:H.x+(oe.x-H.x)/2,y:H.y+(oe.y-H.y)/2}}return d},cr=function(c){return cs(c,["id","type","sourceNodeId","sourceAnchorId","targetNodeId","targetAnchorId","pointsList","startPoint","endPoint","properties"])},Xr=function(c,u){return Math.sqrt(Math.pow(c.x-u.x,2)+Math.pow(c.y-u.y,2))};function Nr(c,u){return typeof u!="function"?function(d,p,y){return Object.assign({type:c.edgeType},y)}:function(d,p,y){var m=u(d,p,y);return m?typeof m=="string"?Object.assign({},y,{type:m}):Object.assign({type:m},y):{type:c.edgeType}}}r(208);var fi=function(){};function $s(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function yi(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var Te=(function(){function c(p){var y=this,m=p.onDragStart,_=m===void 0?fi:m,A=p.onDragging,N=A===void 0?fi:A,U=p.onDragEnd,H=U===void 0?fi:U,oe=p.eventType,ue=oe===void 0?"":oe,Ce=p.eventCenter,Ve=Ce===void 0?null:Ce,qe=p.step,Ot=qe===void 0?1:qe,xt=p.isStopPropagation,Ft=xt===void 0||xt,hn=p.model,Hn=hn===void 0?null:hn,zn=p.data,Ar=zn===void 0?null:zn;(function(Vn,vr){if(!(Vn instanceof vr))throw new TypeError("Cannot call a class as a function")})(this,c),yi(this,"onDragStart",void 0),yi(this,"onDragging",void 0),yi(this,"onDragEnd",void 0),yi(this,"step",void 0),yi(this,"isStopPropagation",void 0),yi(this,"isDragging",!1),yi(this,"isStartDragging",!1),yi(this,"startX",0),yi(this,"startY",0),yi(this,"sumDeltaX",0),yi(this,"sumDeltaY",0),yi(this,"eventType",void 0),yi(this,"eventCenter",void 0),yi(this,"model",void 0),yi(this,"data",void 0),yi(this,"startTime",void 0),yi(this,"handleMouseDown",(function(Vn){var vr,er,Eo,Co=(vr=window)===null||vr===void 0?void 0:vr.document;if(Vn.button===0){y.isStopPropagation&&Vn.stopPropagation(),y.isStartDragging=!0,y.startX=Vn.clientX,y.startY=Vn.clientY,Co.addEventListener("mousemove",y.handleMouseMove,!1),Co.addEventListener("mouseup",y.handleMouseUp,!1);var zr=(er=y.model)===null||er===void 0?void 0:er.getData();(Eo=y.eventCenter)===null||Eo===void 0||Eo.emit(ur["".concat(y.eventType,"_MOUSEDOWN")],{e:Vn,data:y.data||zr}),y.startTime=new Date().getTime()}})),yi(this,"handleMouseMove",(function(Vn){if(y.isStopPropagation&&Vn.stopPropagation(),y.isStartDragging&&(y.sumDeltaX+=Vn.clientX-y.startX,y.sumDeltaY+=Vn.clientY-y.startY,y.startX=Vn.clientX,y.startY=Vn.clientY,y.step<=1||Math.abs(y.sumDeltaX)>y.step||Math.abs(y.sumDeltaY)>y.step)){var vr,er=y.sumDeltaX%y.step,Eo=y.sumDeltaY%y.step,Co=y.sumDeltaX-er,zr=y.sumDeltaY-Eo;y.sumDeltaX=er,y.sumDeltaY=Eo;var Fo,ga=(vr=y.model)===null||vr===void 0?void 0:vr.getData();y.isDragging||((Fo=y.eventCenter)===null||Fo===void 0||Fo.emit(ur["".concat(y.eventType,"_DRAGSTART")],{e:Vn,data:y.data||ga}),y.onDragStart({event:Vn})),y.isDragging=!0,Promise.resolve().then((function(){var ya,Nl;y.onDragging({deltaX:Co,deltaY:zr,event:Vn}),(ya=y.eventCenter)===null||ya===void 0||ya.emit(ur["".concat(y.eventType,"_MOUSEMOVE")],{e:Vn,data:y.data||ga}),(Nl=y.
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function G(c){return(function(u){if(Array.isArray(u))return ce(u)})(c)||(function(u){if(typeof Symbol<"u"&&u[Symbol.iterator]!=null||u["@@iterator"]!=null)return Array.from(u)})(c)||te(c)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function te(c,u){if(c){if(typeof c=="string")return ce(c,u);var d=Object.prototype.toString.call(c).slice(8,-1);return d==="Object"&&c.constructor&&(d=c.constructor.name),d==="Map"||d==="Set"?Array.from(c):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?ce(c,u):void 0}}function ce(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function Oe(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function Fe(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function et(c,u,d){return u&&Fe(c.prototype,u),c}function jt(c,u){if(typeof u!="function"&&u!==null)throw new TypeError("Super expression must either be null or a function");c.prototype=Object.create(u&&u.prototype,{constructor:{value:c,writable:!0,configurable:!0}}),u&&Tn(c,u)}function Vt(c){var u=an();return function(){var d,p=Br(c);if(u){var y=Br(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return yn(this,d)}}function yn(c,u){if(u&&(x(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Yn(c)}function Yn(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Qn(c){var u=typeof Map=="function"?new Map:void 0;return Qn=function(d){if(d===null||(p=d,Function.toString.call(p).indexOf("[native code]")===-1))return d;var p;if(typeof d!="function")throw new TypeError("Super expression must either be null or a function");if(u!==void 0){if(u.has(d))return u.get(d);u.set(d,y)}function y(){return Sr(d,arguments,Br(this).constructor)}return y.prototype=Object.create(d.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),Tn(y,d)},Qn(c)}function Sr(c,u,d){return Sr=an()?Reflect.construct:function(p,y,m){var _=[null];_.push.apply(_,y);var A=new(Function.bind.apply(p,_));return m&&Tn(A,m.prototype),A},Sr.apply(null,arguments)}function an(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}}function Tn(c,u){return Tn=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Tn(c,u)}function Br(c){return Br=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Br(c)}function ir(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var at,Yr,Ao,Mr,Ur,xa,Hl,uu,Oa,Iu,Pc,Qp,yv,Fu=(function(c){jt(d,c);var u=Vt(d);function d(){var p;Oe(this,d);for(var y=arguments.length,m=new Array(y),_=0;_<y;_++)m[_]=arguments[_];return ir(Yn(p=u.call(this,m.length)),"rows",void 0),ir(Yn(p),"columns",void 0),p.fill(new Array(3)),m.forEach((function(A,N){p[N]=A})),p.columns=m[0].length,p.rows=m.length,Object.setPrototypeOf(Yn(p),d.prototype),p}return et(d,[{key:"getRow",value:function(p){return this[p]}},{key:"getColumn",value:function(p){return G(this.map((function(y){return y[p]})))}},{key:"transpose",value:function(){for(var p=[],y=0;y<this.columns;y++)p.push(this.getColumn(y));return Sr(d,p)}},{key:"cross",value:function(p){var y=new Array(this.rows).fill("").map((function(){return[]}));if(this.columns===p.rows)for(var m=0;m<this.rows;m++)for(var _=this.getRow(m),A=function(U){var H=p.getColumn(U);y[m][U]=_.reduce((function(oe,ue,Ce){return oe+ue*H[Ce]}),0)},N=0;N<p.columns;N++)A(N);return Sr(d,G(y))}},{key:"to2D",value:function(){return this.map((function(p){return[p[0],p[1]]}))}},{key:"toPoints",value:function(){return this.map((function(p){return new g(p[0],p[1])}))}},{key:"toString",value:function(){var p=C(this[0],2),y=p[0],m=p[1],_=C(this[1],2),A=_[0],N=_[1],U=C(this[2],2),H=U[0],oe=U[1];return"matrix(".concat(y," ").concat(m,
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function Rc(c){return(function(u){if(Array.isArray(u))return mE(u)})(c)||(function(u){if(typeof Symbol<"u"&&u[Symbol.iterator]!=null||u["@@iterator"]!=null)return Array.from(u)})(c)||wv(c)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function wv(c,u){if(c){if(typeof c=="string")return mE(c,u);var d=Object.prototype.toString.call(c).slice(8,-1);return d==="Object"&&c.constructor&&(d=c.constructor.name),d==="Map"||d==="Set"?Array.from(c):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?mE(c,u):void 0}}function mE(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function pb(c){return pb=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},pb(c)}function Bu(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function h5(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Dc(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function Tr(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}var iT,aT=200,lT=(at=(function(){function c(p){(function(Ce,Ve){if(!(Ce instanceof Ve))throw new TypeError("Cannot call a class as a function")})(this,c),Dc(this,"rootEl",void 0),Bu(this,"width",Yr,this),Bu(this,"height",Ao,this),Dc(this,"theme",void 0),Dc(this,"eventCenter",void 0),Dc(this,"modelMap",new Map),Dc(this,"topElement",void 0),Dc(this,"animation",void 0),Dc(this,"idGenerator",void 0),Dc(this,"edgeGenerator",void 0),Dc(this,"nodeMoveRules",[]),Dc(this,"customTrajectory",void 0),Bu(this,"edgeType",Mr,this),Bu(this,"nodes",Ur,this),Bu(this,"edges",xa,this),Bu(this,"overlapMode",Hl,this),Bu(this,"background",uu,this),Bu(this,"transformModel",Oa,this),Bu(this,"editConfigModel",Iu,this),Bu(this,"gridSize",Pc,this),Bu(this,"partial",Qp,this),Bu(this,"fakerNode",yv,this);var y,m=p.container,_=p.background,A=_===void 0?{}:_,N=p.grid,U=p.idGenerator,H=p.edgeGenerator,oe=p.animation,ue=p.customTrajectory;this.background=A,pb(N)==="object"&&(this.gridSize=N.size),this.rootEl=m,this.editConfigModel=new Mp(p),this.eventCenter=new Bp,this.transformModel=new Jh(this.eventCenter,p),this.theme=iu(p.style),this.edgeType=p.edgeType||"polyline",this.width=p.width,this.height=p.height,this.animation=(y=oe)&&typeof y!="boolean"?bc(Uo(_v),y):Uo(y===!0?Ey:_v),this.partial=p.partial,this.overlapMode=p.overlapMode||0,this.idGenerator=U,this.customTrajectory=ue,this.edgeGenerator=Nr(this,H),this.width=p.width||this.rootEl.getBoundingClientRect().width,this.height=p.height||this.rootEl.getBoundingClientRect().height,this.flowId=tl()}var u,d;return u=c,d=[{key:"nodesMap",get:function(){return this.nodes.reduce((function(p,y,m){return p[y.id]={index:m,model:y},p}),{})}},{key:"edgesMap",get:function(){return this.edges.reduce((function(p,y,m){return p[y.id]={index:m,model:y},p}),{})}},{key:"modelsMap",get:function(){return[].concat(Rc(this.nodes),Rc(this.edges)).reduce((function(p,y){return p[y.id]=y,p}),{})}},{key:"sortElements",get:function(){var p=[];this.nodes.forEach((function(U){return p.push(U)})),this.edges.forEach((function(U){return p.push(U)})),p=p.sort((function(U,H){return U.zIndex-H.zIndex}));for(var y=[],m=[-200,-200],_=[this.width+aT,this.height+aT],A=0;A<p.length;A++){var N=p[A];N.visible&&(!this.partial||N.isSelected||this.isElementInArea(N,m,_,!1,!1))&&y.push(N)}return y}},{key:"textEditElement",get:function(){var p=this.nodes.find((function(m){return m.state===Io.TEXT_EDIT})),y=this.edges.find((function(m){return m.state===Io.TEXT_EDIT}));retu
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function fT(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}var pT,Fm=function(c){var u={x1:10,y1:10,x2:20,y2:20,stroke:"black"};return Object.entries(c).forEach((function(d){var p=j5(d,2),y=p[0],m=p[1];(y==="style"||AE(m)!=="object")&&(u[y]=m)})),Object(re.g)("line",u)};function ME(c){return ME=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},ME(c)}function hT(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function yb(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?hT(Object(d),!0).forEach((function(p){L5(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):hT(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function L5(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function I5(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function F5(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function TE(c,u){return TE=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},TE(c,u)}function B5(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=_b(c);if(u){var y=_b(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return $5(this,d)}}function $5(c,u){if(u&&(ME(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d})(c)}function _b(c){return _b=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},_b(c)}var vT,U5=Fc(pT=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&TE(m,_)})(y,c);var u,d,p=B5(y);function y(){return I5(this,y),p.apply(this,arguments)}return u=y,(d=[{key:"render",value:function(){var m=this.props.snaplineModel,_=m.position,A=m.isShowHorizontal,N=m.isShowVertical,U=m.getStyle(),H=_.x,oe=H===void 0?0:H,ue=_.y,Ce=ue===void 0?0:ue,Ve=yb(yb({x1:-1e5,y1:Ce,x2:1e5,y2:Ce},U),{},{stroke:A?U.stroke:"none"}),qe=yb(yb({x1:oe,y1:-1e5,x2:oe,y2:1e5},U),{},{stroke:N?U.stroke:"none"});return Object(re.g)("g",{className:"lf-snapline"},Object(re.g)(Fm,Ve),Object(re.g)(Fm,qe))}}])&&F5(u.prototype,d),y})(re.a))||pT;function CE(c){return CE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},CE(c)}function V5(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||(function(d,p){if(d){if(typeof d=="string")return mT(d,p);var y=Object.prototype.toString.call(d).slice(8,-1);if(y==="Object"&&d.construct
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function mT(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function th(c){var u=c.x,d=c.y,p=c.width,y=c.height,m=c.className,_=c.radius,A=u-p/2,N=d-y/2,U={};return Object.entries(c).forEach((function(H){var oe=V5(H,2),ue=oe[0],Ce=oe[1];CE(Ce)!=="object"&&(U[ue]=Ce)})),U.className=m?"lf-basic-shape ".concat(m):"lf-basic-shape",_&&(U.rx=_,U.ry=_),U.x=A,U.y=N,Object(re.g)("rect",U)}function NE(c){return NE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},NE(c)}function Bm(){return Bm=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},Bm.apply(this,arguments)}function gT(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function yT(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?gT(Object(d),!0).forEach((function(p){W5(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):gT(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function W5(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function G5(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function z5(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function kE(c,u){return kE=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},kE(c,u)}function H5(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=bb(c);if(u){var y=bb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return X5(this,d)}}function X5(c,u){if(u&&(NE(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d})(c)}function bb(c){return bb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},bb(c)}th.defaultProps={className:"",radius:""};var _T,Y5=Fc(vT=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&kE(m,_)})(y,c);var u,d,p=H5(y);function y(){return G5(this,y),p.apply(this,arguments)}return u=y,(d=[{key:"getNodesOutline",value:function(){var m=this.props.graphModel,_=m.nodes,A=m.editConfigModel,N=A.hoverOutline,U=A.nodeSelectedOutline,H=[];return _.forEach((function(oe){if(oe.isHovered||oe.isSelected){var ue=oe.isHovered,Ce=oe.isSelected,Ve=oe.x,qe=oe.y,Ot=oe.width,xt=oe.height;if(U&&Ce||N&&ue){var Ft=oe.getOutlineStyle(),hn={};if(Object.keys(Ft).forEach((function(zn){zn!=="hover"&&(hn[zn]=Ft[zn])})),ue){var Hn=Ft.hover;hn=yT(yT({},hn),Hn)}H.push(Object(re.g)(th,Bm({transform:oe.transform,className:"lf-outline-node",x:Ve,y:qe,width:Ot+10,height:xt+10},hn)))}}})),H}},{key:"getEdgeOutline",value:function(){for(var m=this.props.graphModel,_=m.edges,A=m.editConfigModel,N=A.edgeSelectedOutline,U=A.hoverOutline,H=[],oe=0;oe<_.length;oe++){var ue=_[oe];(N&&ue.isSelected||U&&ue.isHovered)&&(ue.modelType===lo.LINE_EDGE?H.push(this.get
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function bT(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function $m(c){var u=c.x,d=u===void 0?0:u,p=c.y,y=p===void 0?0:p,m=c.r,_=m===void 0?4:m,A=c.className,N={cx:d,cy:y,r:_,fill:"transparent",fillOpacity:1,strokeWidth:"1",stroke:"#000",strokeOpacity:1};return Object.entries(c).forEach((function(U){var H=q5(U,2),oe=H[0],ue=H[1];PE(ue)!=="object"&&(N[oe]=ue)})),N.className=A?"lf-basic-shape ".concat(A):"lf-basic-shape",Object(re.g)("circle",N)}function RE(c){return RE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},RE(c)}function K5(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||(function(d,p){if(d){if(typeof d=="string")return wT(d,p);var y=Object.prototype.toString.call(d).slice(8,-1);if(y==="Object"&&d.constructor&&(y=d.constructor.name),y==="Map"||y==="Set")return Array.from(d);if(y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(y))return wT(d,p)}})(c,u)||(function(){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 wT(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function xy(){return xy=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},xy.apply(this,arguments)}function ET(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function Z5(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function xT(c,u,d){return u&&Z5(c.prototype,u),c}function OT(c,u){if(typeof u!="function"&&u!==null)throw new TypeError("Super expression must either be null or a function");c.prototype=Object.create(u&&u.prototype,{constructor:{value:c,writable:!0,configurable:!0}}),u&&DE(c,u)}function DE(c,u){return DE=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},DE(c,u)}function ST(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Eb(c);if(u){var y=Eb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return J5(this,d)}}function J5(c,u){if(u&&(RE(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return wb(c)}function wb(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Eb(c){return Eb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Eb(c)}function jE(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var AT,MT=(function(c){OT(d,c);var u=ST(d);function d(){var p;return ET(this,d),jE(wb(p=u.call(this)),"dragHandler",void 0),jE(wb(p),"onDragging",(function(y){var m=y.event,_=p.props,A=_.graphModel,N=_.bezierModel,U=_.type,H=A.getPointByClient({x:m.clientX,y:m.clientY}).canvasOverlayPosition,oe=H.x,ue=H.y;N.updateAdjustAnchor({x:oe,y:ue},U),A.eventCenter.emit(ur.EDGE_ADJUST,{data:N.getData()})})),jE(wb(p),"onDragEnd",(function(){p.props.bezierModel.isDragging=!1})),p.dragHandler=new Te({onDragging:p.onDragging,onDragEnd:p.onDragEnd}),p}return xT(d,[{key:"render",value:function(){var p=this,y=this.props.position,m=y.x,_=y.y,A=this.props.bezierModel.getEdgeStyle().adjustAnchor;return Object(re.g)($m,xy({className:"lf-bezier-adjust-anchor",x:m,y:_},A,{onMouseDown:function(N){p.dragHandler.handleMouseDown(N)}}))}}]),d})(re.a),Q5=Fc(_T=(function(c){OT(d,c);var u=ST(d);function d(){return ET(this,d),u.apply(this,arguments)}return xT(d,[{key:"getBezierAdjust",value:function(p,y){var m=p.path,_=p.id,A=K5(di(m),4),N=A[0],U=A[1],H=A[2],oe=A[3],ue=p.getEdgeStyle().adjustLine,Ce=[];return Ce.push(Object(re.g)(Fm,xy({x1:N.x,y1:N.y,x2:U.x,y2:U.y},ue))),Ce.push(Object(re.g)(MT,{position:U,bezierModel:p,graphModel:y,key:"".concat(_,"_ePre"),type:"sNext"})),Ce.push(Object(re.g)(Fm,xy({x1:oe.x,y1:oe.y,x2:H.x,y2:H.y},ue))),Ce.push(Object(re.g)(MT,{position:H,bezierModel:p,graphModel:y,key:"".concat(_,"_sNext"),type:"ePre"})),Ce}},{key:"selectedBezierEdge",value:function(){for(var p=this.props.graphModel,y=p.edges,m=[],_=0;_<y.length;_++){var A=y[_];A.isSelected&&A.modelType===lo.BEZIER_EDGE&&A.draggable&&m.push(this.getBezierAdjust(A,p))}return m}},{key:"render",value:function(){return Object(re.g)("g",{className:"lf-bezier-adjust"},this.selectedBezierEdge())}}]),d})(re.a))||_T;function LE(c){return LE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},LE(c)}function e6(c,u){if(!(c instanceof u))throw new TypeError("Canno
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function RT(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function DT(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function Ab(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?DT(Object(d),!0).forEach((function(p){jT(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):DT(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function p6(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function h6(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function v6(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Oy(){return Oy=typeof Reflect<"u"&&Reflect.get?Reflect.get:function(c,u,d){var p=m6(c,u);if(p){var y=Object.getOwnPropertyDescriptor(p,u);return y.get?y.get.call(arguments.length<3?c:d):y.value}},Oy.apply(this,arguments)}function m6(c,u){for(;!Object.prototype.hasOwnProperty.call(c,u)&&(c=nh(c))!==null;);return c}function WE(c,u){return WE=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},WE(c,u)}function g6(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=nh(c);if(u){var y=nh(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return y6(this,d)}}function y6(c,u){if(u&&(UE(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Mb(c)}function Mb(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function nh(c){return nh=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},nh(c)}function jT(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function jc(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}var GE=(Zo=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&WE(m,_)})(y,c);var u,d,p=g6(y);function y(){var m;h6(this,y);for(var _=arguments.length,A=new Array(_),N=0;N<_;N++)A[N]=arguments[N];return jT(Mb(m=p.call.apply(p,[this].concat(A))),"modelType",lo.BEZIER_EDGE),p6(Mb(m),"path",kT,Mb(m)),m}return u=y,(d=[{key:"initEdgeData",value:function(m){this.offset=100,Oy(nh(y.prototype),"initEdgeData",this).call(this,m)}},{key:"getEdgeStyle",value:function(){var m=this.graphModel.theme.bezier;return Ab(Ab({},Oy(nh(y.prototype),"getEdgeStyle",this).call(this)),Uo(m))}},{key:"getTextPosition",value:function(){if(this.pointsList&&this.pointsList.length>0){var m=0,_=0;return this.pointsList.forEach((function(A){var N=A.x,U=A.y;m+=N,_+=U})),{x:m/this.pointsList.length,y:_/this.pointsList.length}}return{x:(this.startPoint.x+this.endPoint.x)/2,y:(this.startPoint.y+this.endPoint.y)/2}}},
|
|||
|
|
C `).concat(N.x," ").concat(N.y,`,
|
|||
|
|
`).concat(U.x," ").concat(U.y,`,
|
|||
|
|
`).concat(H.x," ").concat(H.y)}},{key:"initPoints",value:function(){this.pointsList.length>0?this.path=this.getPath(this.pointsList):this.updatePoints()}},{key:"updatePoints",value:function(){var m=this.getControls(),_=m.sNext,A=m.ePre;this.updatePath(_,A)}},{key:"updatePath",value:function(m,_){m=Uo(m),_=Uo(_);var A={x:this.startPoint.x,y:this.startPoint.y},N={x:this.endPoint.x,y:this.endPoint.y};if(!m||!_){var U=this.getControls();m=U.sNext,_=U.ePre}this.pointsList=[A,m,_,N],this.path=this.getPath(this.pointsList)}},{key:"updateStartPoint",value:function(m){this.startPoint=Object.assign({},m),this.updatePoints()}},{key:"updateEndPoint",value:function(m){this.endPoint=Object.assign({},m),this.updatePoints()}},{key:"moveStartPoint",value:function(m,_){this.startPoint.x+=m,this.startPoint.y+=_;var A=VE(this.pointsList,3),N=A[1],U=A[2];N.x+=m,N.y+=_,this.updatePath(N,U)}},{key:"moveEndPoint",value:function(m,_){this.endPoint.x+=m,this.endPoint.y+=_;var A=VE(this.pointsList,3),N=A[1],U=A[2];U.x+=m,U.y+=_,this.updatePath(N,U)}},{key:"updateAdjustAnchor",value:function(m,_){_==="sNext"?this.pointsList[1]=m:_==="ePre"&&(this.pointsList[2]=m),this.path=this.getPath(this.pointsList),this.setText(Object.assign({},this.text,this.textPosition))}},{key:"getAdjustStart",value:function(){return this.pointsList[0]||this.startPoint}},{key:"getAdjustEnd",value:function(){var m=this.pointsList;return m[m.length-1]||this.endPoint}},{key:"updateAfterAdjustStartAndEnd",value:function(m){var _=m.startPoint,A=m.endPoint,N=m.sourceNode,U=m.targetNode,H=zi({start:_,end:A,sourceNode:N,targetNode:U,offset:this.offset}),oe=H.sNext,ue=H.ePre;this.pointsList=[_,oe,ue,A],this.initPoints()}}])&&v6(u.prototype,d),y})(If),kT=jc(Zo.prototype,"path",[a.C],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return""}}),jc(Zo.prototype,"initPoints",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"initPoints"),Zo.prototype),jc(Zo.prototype,"updatePoints",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"updatePoints"),Zo.prototype),jc(Zo.prototype,"updateStartPoint",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"updateStartPoint"),Zo.prototype),jc(Zo.prototype,"updateEndPoint",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"updateEndPoint"),Zo.prototype),jc(Zo.prototype,"moveStartPoint",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"moveStartPoint"),Zo.prototype),jc(Zo.prototype,"moveEndPoint",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"moveEndPoint"),Zo.prototype),jc(Zo.prototype,"updateAdjustAnchor",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"updateAdjustAnchor"),Zo.prototype),jc(Zo.prototype,"getAdjustStart",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"getAdjustStart"),Zo.prototype),jc(Zo.prototype,"getAdjustEnd",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"getAdjustEnd"),Zo.prototype),jc(Zo.prototype,"updateAfterAdjustStartAndEnd",[a.k],Object.getOwnPropertyDescriptor(Zo.prototype,"updateAfterAdjustStartAndEnd"),Zo.prototype),Zo),Dn,LT,IT,FT,BT,$T,UT,VT,WT,GT,zT,HT,XT,YT,qT,KT,ZT,JT,QT,eC,tC,nC,rC,_6=function(c){return c==null};function b6(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||oC(c,u)||(function(){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 zE(c){return zE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},zE(c)}function oC(c,u){if(c){if(typeof c=="string")return iC(c,u);var d=Object.prototype.toString.call(c).slice(8,-1);return d==="Object"&&c.constructor&&(d=c.constructor.name),d==="Map"||d==="Set"?Array.from(c):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?iC(c,u):void 0}}function iC(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function aC(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function ys(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?aC(Object(d),!0).forEach((function(p){Us(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):aC(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function Sa(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function w6(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Us(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function fo(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}var Hf,lC,Xf=(Dn=(function(){function c(p,y){(function(m,_){if(!(m instanceof _))throw new TypeError("Cannot call a class as a function")})(this,c),Us(this,"id",""),Sa(this,"type",LT,this),Sa(this,"x",IT,this),Sa(this,"y",FT,this),Sa(this,"text",BT,this),Sa(this,"properties",$T,this),Sa(this,"_width",UT,this),Sa(this,"_height",VT,this),Sa(this,"anchorsOffset",WT,this),Sa(this,"isSelected",GT,this),Sa(this,"isHovered",zT,this),Sa(this,"isShowAnchor",HT,this),Sa(this,"isDragging",XT,this),Sa(this,"isHitable",YT,this),Sa(this,"draggable",qT,this),Sa(this,"visible",KT,this),Sa(this,"enableRotate",ZT,this),Us(this,"virtual",!1),Us(this,"graphModel",void 0),Sa(this,"zIndex",JT,this),Sa(this,"state",QT,this),Sa(this,"autoToFront",eC,this),Sa(this,"style",tC,this),Sa(this,"transform",nC,this),Sa(this,"_rotate",rC,this),Us(this,"BaseType",ei.NODE),Us(this,"modelType",lo.NODE),Us(this,"additionStateData",void 0),Us(this,"targetRules",[]),Us(this,"sourceRules",[]),Us(this,"moveRules",[]),Us(this,"hasSetTargetRules",!1),Us(this,"hasSetSourceRules",!1),this.graphModel=y,this.initNodeData(p),this.setAttributes()}var u,d;return u=c,d=[{key:"width",get:function(){return this._width},set:function(p){this._width=p}},{key:"height",get:function(){return this._height},set:function(p){this._height=p}},{key:"rotate",get:function(){return this._rotate},set:function(p){this._rotate=p;var y=this.x,m=y===void 0?0:y,_=this.y,A=_===void 0?0:_;this.transform=new eh(-m,-A).rotate(p).translate(m,A).toString()}},{key:"incoming",get:function(){return{nodes:this.graphModel.getNodeIncomingNode(this.id),edges:this.graphModel.getNodeIncomingEdge(this.id)}}},{key:"outgoing",get:function(){return{nodes:this.graphModel.getNodeOutgoingNode(this.id),edges:this.graphModel.getNodeOutgoingEdge(this.id)}}},{key:"initNodeData",value:function(p){if(p.properties||(p.properties={}),!p.id){var y=this.graphModel.idGenerator,m=
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Ot,xt=!0,Ft=!1;return{s:function(){Ce=Ce.call(oe)},n:function(){var hn=Ce.next();return xt=hn.done,hn},e:function(hn){Ft=!0,Ot=hn},f:function(){try{xt||Ce.return==null||Ce.return()}finally{if(Ft)throw Ot}}}})(this.moveRules.concat(this.graphModel.nodeMoveRules));try{for(N.s();!(m=N.n()).done;){var U=(0,m.value)(this,p,y);if(!U)return!1;if(zE(U)==="object"){var H=U;if(H.x===!1&&H.y===!1)return!1;_=_&&H.x,A=A&&H.y}}}catch(oe){N.e(oe)}finally{N.f()}return{x:_,y:A}}},{key:"getConnectedTargetRules",value:function(){return this.targetRules}},{key:"getAnchorsByOffset",value:function(){var p=this.anchorsOffset,y=this.id,m=this.x,_=this.y;return p&&p.length>0?p.map((function(A,N){return A.length?(A=A,{id:"".concat(y,"_").concat(N),x:m+A[0],y:_+A[1]}):ys(ys({},A=A),{},{x:m+A.x,y:_+A.y,id:A.id||"".concat(y,"_").concat(N)})})):this.getDefaultAnchor()}},{key:"getDefaultAnchor",value:function(){return[]}},{key:"getTargetAnchor",value:function(p){return(function(y,m){for(var _,A=Yp(m),N=Number.MAX_SAFE_INTEGER,U=0;U<A.length;U++){var H=ms(y.x,y.y,A[U].x,A[U].y);H<N&&(N=H,_={index:U,anchor:Fs(Fs({},A[U]),{},{x:A[U].x,y:A[U].y,id:A[U].id})})}return _})(p,this)}},{key:"getBounds",value:function(){return{x1:this.x-this.width/2,y1:this.y-this.height/2,x2:this.x+this.width/2,y2:this.y+this.height/2}}},{key:"anchors",get:function(){var p=this.getAnchorsByOffset(),y=this.x,m=this.y,_=this.rotate;return p.forEach((function(A){var N=A.x,U=A.y,H=b6(new Fu([N,U,1]).translate(-y,-m).rotate(_).translate(y,m)[0],2),oe=H[0],ue=H[1];A.x=oe,A.y=ue})),p}},{key:"getAnchorInfo",value:function(p){if(!_6(p))for(var y=0;y<this.anchors.length;y++){var m=this.anchors[y];if(m.id===p)return m}}},{key:"addNodeMoveRules",value:function(p){this.moveRules.includes(p)||this.moveRules.push(p)}},{key:"move",value:function(p,y){var m=arguments.length>2&&arguments[2]!==void 0&&arguments[2],_=!1,A=!1;if(m)_=!0,A=!0;else{var N=this.isAllowMoveNode(p,y);typeof N=="boolean"?(_=N,A=N):(_=N.x,A=N.y)}if(_){var U=this.x+p;this.x=U,this.text&&this.moveText(p,0)}if(A){var H=this.y+y;this.y=H,this.text&&this.moveText(0,y)}return _||A}},{key:"getMoveDistance",value:function(p,y){var m=arguments.length>2&&arguments[2]!==void 0&&arguments[2],_=!1,A=!1,N=0,U=0;if(m)_=!0,A=!0;else{var H=this.isAllowMoveNode(p,y);typeof H=="boolean"?(_=H,A=H):(_=H.x,A=H.y)}if(_&&p){var oe=this.x+p;this.x=oe,this.text&&this.moveText(p,0),N=p}if(A&&y){var ue=this.y+y;this.y=ue,this.text&&this.moveText(0,y),U=y}return[N,U]}},{key:"moveTo",value:function(p,y){var m=arguments.length>2&&arguments[2]!==void 0&&arguments[2],_=p-this.x,A=y-this.y;return!(!m&&!this.isAllowMoveNode(_,A)||(this.text&&this.text&&this.moveText(_,A),this.x=p,this.y=y,0))}},{key:"moveText",value:function(p,y){var m=this.text,_=m.x,A=m.y,N=m.value,U=m.draggable,H=m.editable;this.text={value:N,editable:H,draggable:U,x:_+p,y:A+y}}},{key:"updateText",value:function(p){this.text=ys(ys({},Object(a.I)(this.text)),{},{value:p})}},{key:"setSelected",value:function(){var p=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];this.isSelected=p}},{key:"setHovered",value:function(){var p=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];this.isHovered=p,this.setIsShowAnchor(p)}},{key:"setIsShowAnchor",value:function(){var p=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];this.isShowAnchor=p}},{key:"setEnableRotate",value:function(){var p=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];this.enableRotate=p}},{key:"setHitable",value:function(){var p=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];this.isHitable=p}},{key:"setElementState",value:function(p,y){this.state=p,this.additionStateData=y}},{key:"setProperty",value:function(p,y){this.properties=ys(ys({},Object(a.I)(this.properties)),{},Us({},p,ma(y))),this.setAttributes()}},{key:"setProperties",value:function(p){this.properties=ys(ys({},Object(a.I)(this.properties)),ma(p)),this.setAttributes()}},{key:"deleteProperty",value:function(p){delete this.properties[p],t
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function pC(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function hC(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function vC(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?hC(Object(d),!0).forEach((function(p){gC(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):hC(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function mC(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function T6(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function C6(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function QE(){return QE=typeof Reflect<"u"&&Reflect.get?Reflect.get:function(c,u,d){var p=N6(c,u);if(p){var y=Object.getOwnPropertyDescriptor(p,u);return y.get?y.get.call(arguments.length<3?c:d):y.value}},QE.apply(this,arguments)}function N6(c,u){for(;!Object.prototype.hasOwnProperty.call(c,u)&&(c=Wm(c))!==null;);return c}function ex(c,u){return ex=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},ex(c,u)}function k6(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Wm(c);if(u){var y=Wm(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return P6(this,d)}}function P6(c,u){if(u&&(ZE(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Vm(c)}function Vm(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Wm(c){return Wm=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Wm(c)}function gC(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function Gm(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}var Md,yC,_C,tx=(Xl=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&ex(m,_)})(y,c);var u,d,p=k6(y);function y(){var m;T6(this,y);for(var _=arguments.length,A=new Array(_),N=0;N<_;N++)A[N]=arguments[N];return gC(Vm(m=p.call.apply(p,[this].concat(A))),"modelType",lo.DIAMOND_NODE),mC(Vm(m),"rx",dC,Vm(m)),mC(Vm(m),"ry",fC,Vm(m)),m}return u=y,(d=[{key:"getNodeStyle",value:function(){var m=QE(Wm(y.prototype),"getNodeStyle",this).call(this),_=this.graphModel.theme.diamond;return vC(vC({},m),Uo(_))}},{key:"points",get:function(){var m=this.x,_=this.y,A=this.rx,N=this.ry;return[[m,_-N],[m+A,_],[m,_+N],[m-A,_]]}},{key:"pointsPosition",get:function(){return this.points.map((function(m){return{x:m[0],y:m[1]}}))}},{key:"width",get:function(){var m=Number.MAX_SAFE_INTEGER,_=Number.MIN_SAFE_INTEGER;return this.points.forEach((function(A){var N=JE(A,1)[0];N<m&&(m=N),N>_&&(_=N)})),_-m}},{key
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function SC(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function AC(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function MC(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?AC(Object(d),!0).forEach((function(p){TC(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):AC(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function F6(c,u,d,p){d&&Object.defineProperty(c,u,{enumerable:d.enumerable,configurable:d.configurable,writable:d.writable,value:d.initializer?d.initializer.call(p):void 0})}function B6(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function $6(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function sx(){return sx=typeof Reflect<"u"&&Reflect.get?Reflect.get:function(c,u,d){var p=U6(c,u);if(p){var y=Object.getOwnPropertyDescriptor(p,u);return y.get?y.get.call(arguments.length<3?c:d):y.value}},sx.apply(this,arguments)}function U6(c,u){for(;!Object.prototype.hasOwnProperty.call(c,u)&&(c=Xm(c))!==null;);return c}function ux(c,u){return ux=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},ux(c,u)}function V6(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Xm(c);if(u){var y=Xm(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return W6(this,d)}}function W6(c,u){if(u&&(ax(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Nb(c)}function Nb(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Xm(c){return Xm=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Xm(c)}function TC(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function kb(c,u,d,p,y){var m={};return Object.keys(p).forEach((function(_){m[_]=p[_]})),m.enumerable=!!m.enumerable,m.configurable=!!m.configurable,("value"in m||m.initializer)&&(m.writable=!0),m=d.slice().reverse().reduce((function(_,A){return A(c,u,_)||_}),m),y&&m.initializer!==void 0&&(m.value=m.initializer?m.initializer.call(y):void 0,m.initializer=void 0),m.initializer===void 0&&(Object.defineProperty(c,u,m),m=null),m}var cx,CC,dx=($u=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&ux(m,_)})(y,c);var u,d,p=V6(y);function y(){var m;B6(this,y);for(var _=arguments.length,A=new Array(_),N=0;N<_;N++)A[N]=arguments[N];return TC(Nb(m=p.call.apply(p,[this].concat(A))),"modelType",lo.POLYGON_NODE),F6(Nb(m),"points",OC,Nb(m)),m}return u=y,(d=[{key:"getNodeStyle",value:function(){var m=sx(Xm(y.prototype),"getNodeStyle",this).call(this),_=this.graphModel.theme.polygon;return MC(MC({},m),Uo(_))}},{key:"pointsPosition",get:function(){var m=this.x,_=this.y,A=this.width,N=this.height;return this.points.map((function(U){return{x:U[0]+m-A/2,y:U[1]+_-N/2}}))}},{key:"width",get:function(){var m=Number.MAX_SAFE_INTEGER,_=Number.MIN_SAFE_INTEGER;return this.points.forEach((function(A){var N=lx(A,1)[0];N<m&&(m=N),N>_&&(_=N)})),_-m}},{key:"height",get:function(){var m=Number.MAX_SAFE_INTEGER,_=Number.MIN_SAFE_IN
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function XC(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function sF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Sx(c,u){return Sx=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Sx(c,u)}function uF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=jb(c);if(u){var y=jb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return cF(this,d)}}function cF(c,u){if(u&&(Ox(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Td(c)}function Td(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function jb(c){return jb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},jb(c)}function Cd(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var dF=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&Sx(m,_)})(y,c);var u,d,p=uF(y);function y(){var m;return(function(_,A){if(!(_ instanceof A))throw new TypeError("Cannot call a class as a function")})(this,y),Cd(Td(m=p.call(this)),"preTargetNode",void 0),Cd(Td(m),"sourceRuleResults",void 0),Cd(Td(m),"targetRuleResults",void 0),Cd(Td(m),"dragHandler",void 0),Cd(Td(m),"t",void 0),Cd(Td(m),"onDragStart",(function(_){var A=_.event,N=m.props,U=N.anchorData,H=N.nodeModel,oe=N.graphModel;oe.overlapMode,oe.selectNodeById(H.id),H.autoToFront&&oe.toFront(H.id),oe.eventCenter.emit(ur.ANCHOR_DRAGSTART,{data:U,e:A,nodeModel:H}),m.setState({startX:U.x,startY:U.y,endX:U.x,endY:U.y})})),Cd(Td(m),"onDragging",(function(_){var A=_.event,N=m.props,U=N.graphModel,H=N.nodeModel,oe=N.anchorData,ue=U.transformModel,Ce=U.eventCenter,Ve=U.width,qe=U.height,Ot=U.editConfigModel,xt=Ot.autoExpand,Ft=Ot.stopMoveGraph,hn=A.clientX,Hn=A.clientY,zn=U.getPointByClient({x:hn,y:Hn}),Ar=zn.domOverlayPosition,Vn=Ar.x,vr=Ar.y,er=zn.canvasOverlayPosition,Eo=er.x,Co=er.y;m.t&&Db(m.t);var zr=[];Vn<10?zr=[10,0]:Vn+10>Ve?zr=[-10,0]:vr<10?zr=[0,10]:vr+10>qe&&(zr=[0,-10]),m.setState({endX:Eo,endY:Co,dragging:!0}),m.moveAnchorEnd(Eo,Co),zr.length>0&&!Ft&&xt&&(m.t=zC((function(){var Fo=lF(zr,2),ga=Fo[0],ya=Fo[1];ue.translate(ga,ya);var Nl=m.state,fu=Nl.endX,pu=Nl.endY;m.setState({endX:fu-ga,endY:pu-ya}),m.moveAnchorEnd(fu-ga,pu-ya)}))),Ce.emit(ur.ANCHOR_DRAG,{data:oe,e:A,nodeModel:H})})),Cd(Td(m),"onDragEnd",(function(_){var A=_.event;m.t&&Db(m.t);var N=m.checkEnd(A);m.setState({startX:0,startY:0,endX:0,endY:0,dragging:!1}),m.sourceRuleResults.clear(),m.targetRuleResults.clear();var U=m.props,H=U.graphModel,oe=U.nodeModel,ue=U.anchorData;H.eventCenter.emit(ur.ANCHOR_DRAGEND,{data:ue,e:A,nodeModel:oe,edgeModel:N})})),Cd(Td(m),"checkEnd",(function(_){var A=m.props,N=A.graphModel,U=A.nodeModel,H=A.anchorData,oe=H.x,ue=H.y,Ce=H.id,Ve=(N.edgeType,m.state),qe=Ve.endX,Ot=Ve.endY,xt=Ve.dragging,Ft=Cf({x:qe,y:Ot},N);if(m.preTargetNode&&m.preTargetNode.state!==Io.DEFAULT&&m.preTargetNode.setElementState(Io.DEFAULT),xt&&Ft&&Ft.node){var hn=Ft.node,Hn=Ft.anchor.id,zn="".concat(U.id,"_").concat(hn.id,"_").concat(Hn,"_").concat(Ce),Ar=m.sourceRuleResults.get(zn)||{},Vn=Ar.isAllPass,vr=Ar.msg,er=m.targetRuleResults.get(zn)||{},Eo=er.isAllPass,Co=er.msg;if(Vn&&Eo){hn.setElementState(Io.DEFAULT);var zr=N.edgeGenerator(U.getData(),N.getNodeModelById(Ft.node.id).getData()),Fo=N.addEdge(Ty(Ty({},zr),{},{
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function qC(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function KC(c){var u=c.x,d=u===void 0?0:u,p=c.y,y=p===void 0?0:p,m=c.value,_=c.fontSize,A=c.fill,N=A===void 0?"currentColor":A,U=c.overflowMode,H=U===void 0?"default":U,oe=c.textWidth,ue=oe===void 0?"":oe,Ce=c.model,Ve={textAnchor:"middle","dominant-baseline":"middle",x:d,y,fill:N};if(Object.entries(c).forEach((function(Hn){var zn=hF(Hn,2),Ar=zn[0],Vn=zn[1];Ax(Vn)!=="object"&&(Ve[Ar]=Vn)})),m){var qe=String(m).split(/[\r\n]/g),Ot=qe.length;if(H!=="default"){var xt=Ce.BaseType,Ft=Ce.modelType;if(xt===ei.NODE&&Ft!==lo.TEXT_NODE||xt===ei.EDGE&&ue)return(function(Hn){var zn=Hn.value,Ar=Hn.fontSize,Vn=Hn.model,vr=Hn.fontFamily,er=vr===void 0?"":vr,Eo=Hn.lineHeight,Co=Hn.wrapPadding,zr=Co===void 0?"0, 0":Co,Fo=Hn.overflowMode,ga=Hn.x,ya=Hn.y,Nl=Vn.width,fu=Vn.textHeight,pu=Hn.textWidth||Nl,Pd=String(zn).split(/[\r\n]/g),Av=Pd.length,a0=Df({rows:Pd,style:{fontSize:"".concat(Ar,"px"),width:"".concat(pu,"px"),fontFamily:er,lineHeight:Eo,padding:zr},rowsLength:Av,className:"lf-get-text-height"}),Mv=Vn.height>a0?Vn.height:a0;fu&&(Mv=fu);var ah=Fo==="ellipsis";return ah&&(Mv=Ar+2),Object(re.g)("g",null,Object(re.g)("foreignObject",{width:pu,height:Mv,x:ga-pu/2,y:ya-Mv/2},Object(re.g)("div",{className:"lf-node-text-auto-wrap",style:{minHeight:Mv,width:pu,padding:zr}},Object(re.g)("div",{className:ah?"lf-node-text-ellipsis-content":"lf-node-text-auto-wrap-content",title:ah?Pd.join(""):"",style:fF({},Hn)},Pd.map((function(lh){return Object(re.g)("div",{className:"lf-node-text--auto-wrap-inner"},lh)}))))))})(c)}if(Ot>1){var hn=qe.map((function(Hn,zn){var Ar=(zn-(Ot-1)/2)*(_+2);return Object(re.g)("tspan",{className:"lf-text-tspan",x:d,y:y+Ar},Hn)}));return Object(re.g)("text",Ve,hn)}return Object(re.g)("text",Ve,m)}}function Mx(c){return Mx=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Mx(c)}function Tx(){return Tx=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},Tx.apply(this,arguments)}function vF(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||(function(d,p){if(d){if(typeof d=="string")return ZC(d,p);var y=Object.prototype.toString.call(d).slice(8,-1);if(y==="Object"&&d.constructor&&(y=d.constructor.name),y==="Map"||y==="Set")return Array.from(d);if(y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(y))return ZC(d,p)}})(c,u)||(function(){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 ZC(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function mF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Cx(c,u){return Cx=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Cx(c,u)}function gF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Lb(c);if(u){var y=Lb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return yF(this,d)}}function yF(c,u){if(u&&(Mx(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return oh(c)}function oh(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Lb(c){return Lb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Lb(c)}function Ev(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var JC=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&Cx(m,_)})(y,c);var u,d,p=gF(y);function y(m){var _;(function(N,U){if(!(N instanceof U))throw new TypeError("Cannot call a class as a function")})(this,y),Ev(oh(_=p.call(this)),"dragHandler",void 0),Ev(oh(_),"sumDeltaX",0),Ev(oh(_),"sumDeltaY",0),Ev(oh(_),"stepDrag",void 0),Ev(oh(_),"onDragging",(function(N){var U=N.deltaX,H=N.deltaY,oe=_.props,ue=oe.model,Ce=vF(oe.graphModel.transformModel.fixDeltaXY(U,H),2),Ve=Ce[0],qe=Ce[1];ue.moveText(Ve,qe)})),Ev(oh(_),"dblClickHandler",(function(){_.props.editable&&_.props.model.setElementState(Io.TEXT_EDIT)})),Ev(oh(_),"mouseDownHandle",(function(N){var U=_.props,H=U.draggable,oe=U.model,ue=U.graphModel.editConfigModel.nodeTextDraggable;(H||ue)&&(_.stepDrag.model=oe,_.stepDrag.handleMouseDown(N))})),m.model;var A=m.draggable;return _.stepDrag=new Te({onDragging:_.onDragging,step:1,isStopPropagation:A}),_}return u=y,(d=[{key:"getShape",value:function(){var m=this.props,_=m.model,A=m.graphModel,N=_.text,U=A.editConfigModel,H=N.value,oe=N.x,ue=N.y,Ce=N.editable,Ve=N.draggable,qe={x:oe,y:ue,className:"",value:H};Ce?qe.className="lf-element-text":Ve||U.nodeTextDraggable?qe.className="lf-text-draggable":qe.className="lf-text-disabled";var Ot=_.getTextStyle();return Object(re.g)(KC,Tx({},qe,Ot,{model:_}))}},{key:"render",value:function(){if(this.props.model.text)return Object(re.g)("g",{onMouseDown:this.mouseDownHandle,onDblClick:this.dblClickHandler},this.getShape())}}])&&mF(u.prototype,d),y})(re.a),_F=uc(window,"navigator.userAgent","").match(/MSIE|Trident/)!==null,QC=r(130);function Nx(c){return Nx=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Nx(c)}function kx(){return kx=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},kx.apply(this,arguments)}function bF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Px(c,u){return Px=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Px(c,u)}function wF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Ref
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function eN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function tN(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Dx(c,u){return Dx=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Dx(c,u)}function AF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=$b(c);if(u){var y=$b(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return MF(this,d)}}function MF(c,u){if(u&&(Rx(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return rl(c)}function rl(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function $b(c){return $b=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},$b(c)}function pl(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var Yf=(function(c){(function(_,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function");_.prototype=Object.create(A&&A.prototype,{constructor:{value:_,writable:!0,configurable:!0}}),A&&Dx(_,A)})(m,c);var u,d,p,y=AF(m);function m(_){var A;(function(ue,Ce){if(!(ue instanceof Ce))throw new TypeError("Cannot call a class as a function")})(this,m),pl(rl(A=y.call(this)),"t",void 0),pl(rl(A),"moveOffset",void 0),pl(rl(A),"stepDrag",void 0),pl(rl(A),"contextMenuTime",void 0),pl(rl(A),"mouseUpDrag",void 0),pl(rl(A),"startTime",void 0),pl(rl(A),"clickTimer",void 0),pl(rl(A),"modelDisposer",void 0),pl(rl(A),"onDragStart",(function(ue){var Ce=ue.event,Ve=Ce.clientX,qe=Ce.clientY,Ot=A.props,xt=Ot.model,Ft=Ot.graphModel.getPointByClient({x:Ve,y:qe}).canvasOverlayPosition,hn=Ft.x,Hn=Ft.y;A.moveOffset={x:xt.x-hn,y:xt.y-Hn}})),pl(rl(A),"onDragging",(function(ue){var Ce=ue.event,Ve=A.props,qe=Ve.model,Ot=Ve.graphModel,xt=Ot.editConfigModel,Ft=xt.stopMoveGraph,hn=xt.autoExpand,Hn=Ot.transformModel,zn=Ot.selectNodes,Ar=Ot.width,Vn=Ot.height,vr=Ot.gridSize;qe.isDragging=!0;var er=Ce.clientX,Eo=Ce.clientY,Co=Ot.getPointByClient({x:er,y:Eo}).canvasOverlayPosition,zr=Co.x,Fo=Co.y,ga=Bb(Hn.CanvasPointToHtmlPoint([zr,Fo]),2),ya=ga[0],Nl=ga[1];if(zr+=A.moveOffset.x,Fo+=A.moveOffset.y,zr=fs(zr,vr),Fo=fs(Fo,vr),Ar&&Vn){if(!hn||Ft||!(ya<0||Nl<0||ya>Ar||Nl>Vn)){var fu=Bb(Hn.CanvasPointToHtmlPoint([zr-qe.width/2,Fo-qe.height/2]),2),pu=fu[0],Pd=fu[1],Av=Bb(Hn.CanvasPointToHtmlPoint([zr+qe.width/2,Fo+qe.height/2]),2),a0=Av[0],Mv=Av[1],ah=Math.max(vr,20),lh=[];pu<0?lh=[ah,0]:a0>Ot.width?lh=[-ah,0]:Pd<0?lh=[0,ah]:Mv>Ot.height&&(lh=[0,-ah]),A.t&&Db(A.t);var c$=new eh(-zr,-Fo).rotate(qe.rotate).translate(zr,Fo).toString();qe.transform=c$;var l0=zn.map((function(s0){return s0.id}));l0.indexOf(qe.id)===-1&&(l0=[qe.id]),lh.length>0&&!Ft&&hn?A.t=zC((function(){var s0=Bb(lh,2),jN=s0[0],LN=s0[1];Hn.translate(jN,LN);var d$=-jN/Hn.SCALE_X,f$=-LN/Hn.SCALE_X;Ot.moveNodes(l0,d$,f$)})):Ot.moveNodes(l0,zr-qe.x,Fo-qe.y)}}else Ot.moveNode2Coordinate(qe.id,zr,Fo)})),pl(rl(A),"onDragEnd",(function(){A.t&&Db(A.t),A.props.model.isDragging=!1})),pl(rl(A),"handleMouseUp",(function(){var ue=A.props.model;A.mouseUpDrag=ue.isDragging})),pl(rl(A),"handleClick",(function(ue){var Ce=A.mouseUpDrag===!1;if(A.startTime){var Ve=A.props,qe=Ve.model,Ot=Ve.graphModel;if(Ce){var xt={data:qe.getData(),e:ue,position:Ot.getPointByClient({x:ue.clientX,y:ue.clientY}),isSelected:!1,isMultiple:!1},Ft=ue.button===2,hn=ue.detail===2;if(!Ft){var Hn=Ot.editConfigModel,zn=yd(ue,Hn);xt.isMultiple=zn,qe.isSelected&&!hn&&zn?(xt.isSelected=!1,qe.setSelected(
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function nN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function rN(c){var u=c.points,d=c.className,p={fill:"transparent",fillOpacity:1,strokeWidth:1,stroke:"#000",strokeOpacity:1,points:""};return Object.entries(c).forEach((function(y){var m=LF(y,2),_=m[0],A=m[1];Wx(A)!=="object"&&(p[_]=A)})),p.className=d?"lf-basic-shape ".concat(d):"lf-basic-shape",p.points=u.map((function(y){return y.join(",")})).join(" "),Object(re.g)("polygon",p)}function Gx(c){return Gx=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Gx(c)}function zx(){return zx=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},zx.apply(this,arguments)}function IF(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function FF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Hx(c,u){return Hx=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Hx(c,u)}function BF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Wb(c);if(u){var y=Wb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return $F(this,d)}}function $F(c,u){if(u&&(Gx(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d})(c)}function Wb(c){return Wb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Wb(c)}var Xx=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&Hx(m,_)})(y,c);var u,d,p=BF(y);function y(){return IF(this,y),p.apply(this,arguments)}return u=y,(d=[{key:"getShape",value:function(){var m=this.props.model,_=m.x,A=m.y,N=m.width,U=m.height,H=m.points,oe=m.getNodeStyle(),ue={transform:"matrix(1 0 0 1 ".concat(_-N/2," ").concat(A-U/2,")")};return Object(re.g)("g",ue,Object(re.g)(rN,zx({},oe,{points:H,x:_,y:A})))}}])&&FF(u.prototype,d),y})(Yf);function Yx(c){return Yx=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Yx(c)}function qx(){return qx=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},qx.apply(this,arguments)}function UF(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function VF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function Kx(c,u){return Kx=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},Kx(c,u)}function WF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Gb(c);if(u){var y=Gb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return GF(this,d)}}function GF(c,u){if(u&&(Yx(u)==
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function oN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function HF(c){var u=c.x,d=u===void 0?0:u,p=c.y,y=p===void 0?0:p,m=c.rx,_=m===void 0?4:m,A=c.ry,N=A===void 0?4:A,U=c.className,H={cx:d,cy:y,rx:_,ry:N,fill:"transparent",fillOpacity:1,strokeWidth:"1",stroke:"#000",strokeOpacity:1};return Object.entries(c).forEach((function(oe){var ue=zF(oe,2),Ce=ue[0],Ve=ue[1];Jx(Ve)!=="object"&&(H[Ce]=Ve)})),H.className=U?"lf-basic-shape ".concat(U):"lf-basic-shape",Object(re.g)("ellipse",H)}function Qx(c){return Qx=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},Qx(c)}function eO(){return eO=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},eO.apply(this,arguments)}function XF(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function YF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function tO(c,u){return tO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},tO(c,u)}function qF(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=zb(c);if(u){var y=zb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return KF(this,d)}}function KF(c,u){if(u&&(Qx(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d})(c)}function zb(c){return zb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},zb(c)}var nO=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&tO(m,_)})(y,c);var u,d,p=qF(y);function y(){return XF(this,y),p.apply(this,arguments)}return u=y,(d=[{key:"getShape",value:function(){var m=this.props.model,_=m.getNodeStyle();return Object(re.g)(HF,eO({},_,{x:m.x,y:m.y,rx:m.rx,ry:m.ry}))}}])&&YF(u.prototype,d),y})(Yf);function rO(c){return rO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},rO(c)}function iN(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function aN(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?iN(Object(d),!0).forEach((function(p){ZF(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):iN(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function ZF(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function JF(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function QF(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function oO(c,u){return oO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},oO(c,u)}function eB(c){var u=(funct
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function uN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function pB(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function mO(c,u){return mO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},mO(c,u)}function hB(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Kb(c);if(u){var y=Kb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return vB(this,d)}}function vB(c,u){if(u&&(vO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return cu(c)}function cu(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Kb(c){return Kb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Kb(c)}function du(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}(function(c){c.SOURCE="SOURCE",c.TARGET="TARGET"})(Nd||(Nd={}));var cN=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&mO(m,_)})(y,c);var u,d,p=hB(y);function y(m){var _;(function(H,oe){if(!(H instanceof oe))throw new TypeError("Cannot call a class as a function")})(this,y),du(cu(_=p.call(this)),"stepDragData",void 0),du(cu(_),"stepDrag",void 0),du(cu(_),"oldEdge",void 0),du(cu(_),"preTargetNode",void 0),du(cu(_),"targetRuleResults",void 0),du(cu(_),"sourceRuleResults",void 0),du(cu(_),"handleMouseDown",(function(H){_.stepDrag&&_.stepDrag.handleMouseDown(H)})),du(cu(_),"onDragStart",(function(){var H=_.props,oe=H.x,ue=H.y,Ce=H.edgeModel,Ve=Ce.startPoint,qe=Ce.endPoint,Ot=Ce.pointsList;_.oldEdge={startPoint:Ve,endPoint:qe,pointsList:Ot},_.setState({endX:oe,endY:ue,dragging:!0})})),du(cu(_),"onDragging",(function(H){var oe=H.deltaX,ue=H.deltaY,Ce=_.state,Ve=Ce.endX,qe=Ce.endY,Ot=_.props,xt=Ot.graphModel,Ft=Ot.type,hn=xt.transformModel,Hn=xt.editConfigModel,zn=fB(hn.moveCanvasPointByHtml([Ve,qe],oe,ue),2),Ar=zn[0],Vn=zn[1];_.setState({endX:Ar,endY:Vn,dragging:!0});var vr=_.props.edgeModel,er=Cf({x:Ve,y:qe},xt);if(er&&er.node&&_.isAllowAdjust(er).pass){var Eo,Co=vr.startPoint,zr=vr.endPoint,Fo=vr.sourceNode,ga=vr.targetNode;Ft===Nd.SOURCE?Eo={startPoint:{x:er.anchor.x,y:er.anchor.y},endPoint:{x:zr.x,y:zr.y},sourceNode:er.node,targetNode:ga}:Ft===Nd.TARGET&&(Eo={startPoint:{x:Co.x,y:Co.y},endPoint:{x:er.anchor.x,y:er.anchor.y},sourceNode:Fo,targetNode:er.node}),vr.updateAfterAdjustStartAndEnd(Eo)}else Ft===Nd.SOURCE?vr.updateStartPoint({x:Ar,y:Vn}):Ft===Nd.TARGET&&vr.updateEndPoint({x:Ar,y:Vn});vr.text.value&&Hn.adjustEdge&&vr.setText(Object.assign({},vr.text,vr.textPosition))})),du(cu(_),"onDragEnd",(function(H){var oe=H.event;try{var ue;_.setState({dragging:!1});var Ce=_.props,Ve=Ce.graphModel,qe=Ce.edgeModel,Ot=Ce.type,xt=_.state,Ft=xt.endX,hn=xt.endY,Hn=xt.dragging,zn=Cf({x:Ft,y:hn},Ve);if(!Hn)return;var Ar,Vn=!1;if(zn&&zn.node){var vr=_.isAllowAdjust(zn),er=vr.pass,Eo=vr.msg,Co=vr.newTargetNode;if(er){var zr=qe.getData(),Fo=zr.text,ga=zr.sourceAnchorId,ya=ga===void 0?"":ga,Nl=zr.targetAnchorId;Ar=qf(qf({sourceAnchorId:ya,targetAnchorId:Nl===void 0?"":Nl},dB(zr,cB)),{},{text:(Fo==null?void 0:Fo.value)||""}),Ot===Nd.SOURCE?(Ar=qf(qf({},Ve.edgeGenerator(Ve.getNodeModelById(zn.node.id).getData(),Ve.getNodeModelById(qe.targetNodeId).getData(),Ar)),{},{sourceNodeId:zn.node.id,sourceAnchorId:zn.anchor.id,startPoint:{x:zn.anchor.x,y:zn.anchor.y},targe
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function dN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function gB(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function yB(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function yO(c,u){return yO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},yO(c,u)}function _B(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Zb(c);if(u){var y=Zb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return bB(this,d)}}function bB(c,u){if(u&&(gO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ic(c)}function Ic(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function Zb(c){return Zb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Zb(c)}function kd(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var Py=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&yO(m,_)})(y,c);var u,d,p=_B(y);function y(){var m;gB(this,y);for(var _=arguments.length,A=new Array(_),N=0;N<_;N++)A[N]=arguments[N];return kd(Ic(m=p.call.apply(p,[this].concat(A))),"startTime",void 0),kd(Ic(m),"contextMenuTime",void 0),kd(Ic(m),"clickTimer",void 0),kd(Ic(m),"textRef",Object(re.f)()),kd(Ic(m),"handleHover",(function(U,H){var oe=m.props,ue=oe.model,Ce=oe.graphModel.eventCenter;ue.setHovered(U);var Ve=U?ur.EDGE_MOUSEENTER:ur.EDGE_MOUSELEAVE,qe=ue.getData();Ce.emit(Ve,{data:qe,e:H})})),kd(Ic(m),"setHoverON",(function(U){m.props.model.isHovered||(m.textRef&&m.textRef.current&&m.textRef.current.setHoverON(),m.handleHover(!0,U))})),kd(Ic(m),"setHoverOFF",(function(U){m.props.model.isHovered&&(m.textRef&&m.textRef.current&&m.textRef.current.setHoverOFF(),m.handleHover(!1,U))})),kd(Ic(m),"handleContextMenu",(function(U){U.preventDefault(),m.contextMenuTime=new Date().getTime(),m.clickTimer&&clearTimeout(m.clickTimer);var H=m.props,oe=H.model,ue=H.graphModel,Ce=ue.getPointByClient({x:U.clientX,y:U.clientY});ue.setElementStateById(oe.id,Io.SHOW_MENU,Ce.domOverlayPosition),m.toFront(),oe.isSelected||ue.selectEdgeById(oe.id);var Ve=oe==null?void 0:oe.getData();ue.eventCenter.emit(ur.EDGE_CONTEXTMENU,{data:Ve,e:U,position:Ce})})),kd(Ic(m),"handleMouseDown",(function(U){U.stopPropagation(),m.startTime=new Date().getTime()})),kd(Ic(m),"handleMouseUp",(function(U){if(m.startTime&&!(new Date().getTime()-m.startTime>200||U.button===2)){var H=U.detail===2,oe=m.props,ue=oe.model,Ce=oe.graphModel,Ve=ue==null?void 0:ue.getData(),qe=Ce.getPointByClient({x:U.clientX,y:U.clientY});if(H){var Ot=Ce.editConfigModel,xt=Ce.textEditElement;if(xt&&xt.id===ue.id&&Ce.setElementStateById(ue.id,Io.DEFAULT),Ot.edgeTextEdit&&ue.text.editable&&Ce.setElementStateById(ue.id,Io.TEXT_EDIT),ue.modelType===lo.POLYLINE_EDGE){var Ft=ue,hn=Ce.getPointByClient({x:U.x,y:U.y}).canvasOverlayPosition,Hn=hn.x,zn=hn.y,Ar=co({x:Hn,y:zn},Ft.points);Ft.dbClickPosition=Ar}Ce.eventCenter.emit(ur.EDGE_DBCLICK,{data:Ve,e:U,position:qe})}else Ce.eventCenter.emit(ur.ELEMENT_CLICK,{data:Ve,e:U,position:qe}),Ce.eventCenter.emit(ur.EDGE_CLICK,{data:Ve,e:U,position:qe});var Vn=Ce.editConfigModel;Ce.selectEdgeById(ue.id,yd(U,Vn)),m.toFront()}})),m}return u=y,(d=[{key:"getShape",value:function(){return Object(re.g)("g",null,this.getEdge())}},{key:"
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function fN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}var Ry=function(c){var u={d:""};return Object.entries(c).forEach((function(d){var p=wB(d,2),y=p[0],m=p[1],_=_O(m);y!=="style"&&_==="object"||(u[y]=m)})),Object(re.g)("path",u)};function bO(c){return bO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},bO(c)}function wO(){return wO=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},wO.apply(this,arguments)}function EB(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function xB(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function EO(c,u){return EO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},EO(c,u)}function OB(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=Jb(c);if(u){var y=Jb(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return SB(this,d)}}function SB(c,u){if(u&&(bO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d})(c)}function Jb(c){return Jb=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},Jb(c)}var xO=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&EO(m,_)})(y,c);var u,d,p=OB(y);function y(){return EB(this,y),p.apply(this,arguments)}return u=y,(d=[{key:"getEdge",value:function(){var m=this.props.model,_=m.startPoint,A=m.endPoint,N=m.isAnimation,U=m.arrowConfig,H=m.getEdgeStyle(),oe=m.getEdgeAnimationStyle(),ue=oe.strokeDasharray,Ce=oe.stroke,Ve=oe.strokeDashoffset,qe=oe.animationName,Ot=oe.animationDuration,xt=oe.animationIterationCount,Ft=oe.animationTimingFunction,hn=oe.animationDirection;return Object(re.g)(Fm,wO({},H,{x1:_.x,y1:_.y,x2:A.x,y2:A.y},U,N?{strokeDasharray:ue,stroke:Ce,style:{strokeDashoffset:Ve,animationName:qe,animationDuration:Ot,animationIterationCount:xt,animationTimingFunction:Ft,animationDirection:hn}}:{}))}},{key:"getAppendWidth",value:function(){var m=this.props.model,_=m.startPoint,A=m.endPoint,N=la({start:_,end:A}),U=N.d,H=N.strokeWidth,oe=N.fill,ue=N.strokeDasharray,Ce=N.stroke;return Object(re.g)(Ry,{d:U,fill:oe,strokeWidth:H,stroke:Ce,strokeDasharray:ue})}}])&&xB(u.prototype,d),y})(Py);function OO(c){return OO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},OO(c)}function AB(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||(function(d,p){if(d){if(typeof d=="string")return pN(d,p);var y=Object.prototype.toString.call(d).slice(8,-1);if(y==="Object"&&d.constructor&&(y=d.constructor.name),y==="Map"||y==="Set")return Array.from(d);if(y==="Arguments"||/^(?:Ui|I)nt(?:
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function pN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}var MB=function(c){var u={points:"",fill:"none"};return Object.entries(c).forEach((function(d){var p=AB(d,2),y=p[0],m=p[1];(y==="style"||OO(m)!=="object")&&(u[y]=m)})),Object(re.g)("polyline",u)};function SO(c){return SO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},SO(c)}function hN(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function Qb(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?hN(Object(d),!0).forEach((function(p){Zf(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):hN(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function AO(){return AO=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},AO.apply(this,arguments)}function TB(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||(function(d,p){if(d){if(typeof d=="string")return vN(d,p);var y=Object.prototype.toString.call(d).slice(8,-1);if(y==="Object"&&d.constructor&&(y=d.constructor.name),y==="Map"||y==="Set")return Array.from(d);if(y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(y))return vN(d,p)}})(c,u)||(function(){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 vN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function CB(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function MO(c,u){return MO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},MO(c,u)}function NB(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=e0(c);if(u){var y=e0(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return kB(this,d)}}function kB(c,u){if(u&&(SO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Kf(c)}function Kf(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function e0(c){return e0=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},e0(c)}function Zf(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var TO=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&MO(m,_)})(y,c);var u,d,p=NB(y);function y(){var m;return(function(_,A){if(!(_ instanceof A))throw new TypeError("Cannot call a class as a function")})(this,y),Zf(Kf(m=p.call(this)),"drag",void 0),Zf(Kf(m),"isDragging",void 0),Zf(Kf(m),"isShowAdjustPointTemp",void 0),Zf(Kf(m),"appendInfo",void 0),Zf(Kf(m),"onDragStart",(function(){var _=m.props.model;_.dragAppendStart(),m.isShowAdjustPointTemp=_.isShowAdjustPoint,_.isShowAdjustPoint=!1})),Zf(Kf(m),"onDragging",(function(_){var A=_.deltaX,N=_.deltaY,U=m.props,H=U.model,oe=U.graphModel;m.isDragging=!0;var ue=oe.transformModel,Ce=oe.editConfigModel,Ve=TB(ue.fixDeltaXY(A,N),2),qe=Ve[0],Ot=Ve[1],xt=H,Ft=Ce.adjustEdgeMiddle;m.appendInfo=Ft?xt.dragAppendSimple(m.appendInfo,{x:qe,y:Ot}):xt.dragAppend(m.appendInfo,{x:qe,y:Ot})})),Zf(Kf(m),"onDragEnd",(function(){var _=m.props,A=_.model,N=_.graphModel.eventCenter,U=A;U.dragAppendEnd(),m.isDragging=!1,U.isShowAdjustPoint=m.isShowAdjustPointTemp,m.appendInfo=void 0,N.emit(ur.EDGE_ADJUST,{data:U.getData()})})),Zf(Kf(m),"beforeDragStart",(function(_,A){A.dragAble&&m.drag.handleMouseDown(_),m.appendInfo=A})),m.drag=new Te({onDragStart:m.onDragStart,onDragging:m.onDragging,onDragEnd:m.onDragEnd,isStopPropagation:!1}),m}return u=y,(d=[{key:"getEdge",value:function(){var m=this.props.model,_=m.points,A=m.isAnimation,N=m.arrowConfig,U=m.getEdgeStyle(),H=m.getEdgeAnimationStyle(),oe=H.strokeDasharray,ue=H.stroke,Ce=H.strokeDashoffset,Ve=H.animationName,qe=H.animationDuration,Ot=H.animationIterationCount,xt=H.animationTimingFunction,Ft=H.animationDirection;return Object(re.g)(MB,AO({points:_},U,N,A?{strokeDasharray:oe,stroke:ue,style:{strokeDashoffset:Ce,animationName:Ve,animationDuration:qe,animationIterationCount:Ot,animationTimingFunction:xt,animationDirection:Ft}}:{}))}},{key:"getArrowInfo",value:function(){var m=this.props.model,_=m.points,A=m.isSelected,N={start:null,end:null,hover:this.state.hover,isSelected:A},U=jr(_);return U.length>=2&&(N.start=U[U.length-2],N.end=U[U.length-1]),N}},{key:"getLastTwoPoints",value:function(){var m=this.props.model.points,_=jr(m);return _.length>=2?[_[_.length-2],_[_.length-1]]:[null,null]}},{key:"getAppendAttributes",value:function(m){var _,A=m.start,N=m.end;if(A.x===N.x&&A.y===N.y)_="";else{var U={start:A,end:N,offset:10,verticalLength:5},H=kc(Qb(Qb({},U),{},{type:"start"})),oe=kc(Qb(Qb({},U),{},{type:"end"}));_="M".concat(H.leftX," ").concat(H.leftY,`
|
|||
|
|
L`).concat(H.rightX," ").concat(H.rightY,`
|
|||
|
|
L`).concat(oe.rightX," ").concat(oe.rightY,`
|
|||
|
|
L`).concat(oe.leftX," ").concat(oe.leftY," z")}return{d:_,fill:"transparent",stroke:"transparent",strokeWidth:1,strokeDasharray:"4, 4"}}},{key:"getAppendShape",value:function(m){var _=this.getAppendAttributes(m),A=_.d,N=_.strokeWidth,U=_.fill,H=_.strokeDasharray,oe=_.stroke;return Object(re.g)(Ry,{d:A,fill:U,strokeWidth:N,stroke:oe,strokeDasharray:H})}},{key:"getAppendWidth",value:function(){for(var m=this,_=this.props,A=_.model,N=_.graphModel,U=A.pointsList,H=A.draggable,oe=[],ue=U.length,Ce=function(qe){var Ot="lf-polyline-append",xt={start:{x:U[qe].x,y:U[qe].y},end:{x:U[qe+1].x,y:U[qe+1].y},startIndex:qe,endIndex:qe+1,direction:"",dragAble:!0},Ft=Object(re.g)("g",{className:Ot},m.getAppendShape(xt)),hn=N.editConfigModel,Hn=hn.adjustEdge,zn=hn.adjustEdgeMiddle;if(Hn&&H){var Ar=xt.startIndex,Vn=xt.endIndex,vr=zn&&(Ar===0||Vn===ue-1);xt.dragAble=!vr,xt.start.x===xt.end.x?(xt.dragAble&&(Ot+="-ew-resize"),xt.direction=ti.VERTICAL):xt.start.y===xt.end.y&&(xt.dragAble&&(Ot+="-ns-resize"),xt.direction=ti.HORIZONTAL),Ft=Object(re.g)("g",{className:m.isDragging?"lf-dragging":"lf-drag-able",onMouseDown:function(er){return m.beforeDragStart(er,xt)}},Object(re.g)("g",{className:Ot},m.getAppendShape(xt)))}oe.push(Ft)},Ve=0;Ve<ue-1;Ve++)Ce(Ve);return Object(re.g)("g",null,oe)}}])&&CB(u.prototype,d),y})(Py);function CO(c){return CO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},CO(c)}function PB(c,u){return(function(d){if(Array.isArray(d))return d})(c)||(function(d,p){var y=d==null?null:typeof Symbol<"u"&&d[Symbol.iterator]||d["@@iterator"];if(y!=null){var m,_,A=[],N=!0,U=!1;try{for(y=y.call(d);!(N=(m=y.next()).done)&&(A.push(m.value),!p||A.length!==p);N=!0);}catch(H){U=!0,_=H}finally{try{N||y.return==null||y.return()}finally{if(U)throw _}}return A}})(c,u)||(function(d,p){if(d){if(typeof d=="string")return mN(d,p);var y=Object.prototype.toString.call(d).slice(8,-1);if(y==="Object"&&d.constructor&&(y=d.constructor.name),y==="Map"||y==="Set")return Array.from(d);if(y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(y))return mN(d,p)}})(c,u)||(function(){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 mN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function NO(){return NO=Object.assign||function(c){for(var u=1;u<arguments.length;u++){var d=arguments[u];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},NO.apply(this,arguments)}function RB(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function DB(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function kO(c,u){return kO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},kO(c,u)}function jB(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=t0(c);if(u){var y=t0(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return LB(this,d)}}function LB(c,u){if(u&&(CO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d})(c)}function t0(c){return t0=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},t0(c)}var PO=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&kO(m,_)})(y,c);var u,d,p=jB(y);function y(){return RB(this,y),p.apply(this,arguments)}return u=y,(d=[{key:"getEdge",value:function(){var m=this.props.model,_=m.getEdgeStyle(),A=m.path,N=m.isAnimation,U=m.arrowConfig,H=m.getEdgeAnimationStyle(),oe=H.strokeDasharray,ue=H.stroke,Ce=H.strokeDashoffset,Ve=H.animationName,qe=H.animationDuration,Ot=H.animationIterationCount,xt=H.animationTimingFunction,Ft=H.animationDirection;return Object(re.g)(Ry,NO({d:A},_,U,N?{strokeDasharray:oe,stroke:ue,style:{strokeDashoffset:Ce,animationName:Ve,animationDuration:qe,animationIterationCount:Ot,animationTimingFunction:xt,animationDirection:Ft}}:{}))}},{key:"getAppendWidth",value:function(){var m=this.props.model.path;return Object(re.g)(Ry,{d:m,strokeWidth:10,stroke:"transparent",fill:"none"})}},{key:"getArrowInfo",value:function(){var m=this.props.model,_=this.state.hover,A=m.isSelected,N=m.getArrowStyle().offset,U=m.pointsList.map((function(oe){return{x:oe.x,y:oe.y}})),H=PB(sa(U,N),2);return{start:H[0],end:H[1],hover:_,isSelected:A}}},{key:"getLastTwoPoints",value:function(){var m=this.props.model,_=m.getArrowStyle().offset,A=m.pointsList.map((function(N){return{x:N.x,y:N.y}}));return sa(A,_)}}])&&DB(u.prototype,d),y})(Py);function RO(c){return RO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(u){return typeof u}:function(u){return u&&typeof Symbol=="function"&&u.constructor===Symbol&&u!==Symbol.prototype?"symbol":typeof u},RO(c)}function gN(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function IB(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}function FB(c,u){if(!(c instanceof u))throw new TypeError("Cannot call a class as a function")}function BB(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function DO(c,u){return DO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},DO(c,u)}function $B(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.constr
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function EN(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function xN(c,u){var d=Object.keys(c);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(c);u&&(p=p.filter((function(y){return Object.getOwnPropertyDescriptor(c,y).enumerable}))),d.push.apply(d,p)}return d}function Ov(c){for(var u=1;u<arguments.length;u++){var d=arguments[u]!=null?arguments[u]:{};u%2?xN(Object(d),!0).forEach((function(p){Sv(c,p,d[p])})):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(d)):xN(Object(d)).forEach((function(p){Object.defineProperty(c,p,Object.getOwnPropertyDescriptor(d,p))}))}return c}function ON(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function IO(c,u){return IO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},IO(c,u)}function ZB(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=r0(c);if(u){var y=r0(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return JB(this,d)}}function JB(c,u){if(u&&(LO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Zm(c)}function Zm(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function r0(c){return r0=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},r0(c)}function Sv(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var SN,AN,MN,FO=Fc((wN=bN=(function(c){(function(_,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function");_.prototype=Object.create(A&&A.prototype,{constructor:{value:_,writable:!0,configurable:!0}}),A&&IO(_,A)})(m,c);var u,d,p,y=ZB(m);function m(){var _;return(function(A,N){if(!(A instanceof N))throw new TypeError("Cannot call a class as a function")})(this,m),Sv(Zm(_=y.call(this)),"ref",Object(re.f)()),Sv(Zm(_),"__prevText",{type:"",text:"",id:""}),Sv(Zm(_),"keyupHandler",(function(A){var N=_.props.graphModel.textEditElement;A.key==="Enter"&&A.altKey&&N.setElementState(0)})),Sv(Zm(_),"inputHandler",(function(A){var N=A.target.innerText,U=_.props.graphModel.textEditElement;_.__prevText={type:U.type,text:N.replace(/(\r\n)+$|(\n)+$/,""),id:U.id}})),Sv(Zm(_),"keydownHandler",(function(A){A.stopPropagation()})),_.state={style:{left:0,top:0}},_}return u=m,p=[{key:"getDerivedStateFromProps",value:function(_){var A,N=_.graphModel,U=N.transformModel,H=N.theme,oe=H.inputText,ue=N.textEditElement;if(ue){var Ce;if((Ce=ue.text)===null||Ce===void 0||!Ce.value)if(ue.BaseType===ei.EDGE){var Ve=(ue=ue).text,qe=ue.textPosition,Ot=qe.x,xt=qe.y;Ve.x=Ot,Ve.y=xt,ue.setText(Ve)}else ue=ue;var Ft={resize:"auto",whiteSpace:"normal",wordBreak:"break-all"};if(ue.BaseType===ei.EDGE){var hn=H.edgeText,Hn=hn.overflowMode,zn=hn.lineHeight,Ar=hn.wrapPadding,Vn=hn.textWidth;Vn&&Hn==="autoWrap"&&(A=Ov(Ov({},Ft),{},{width:Vn,minWidth:Vn,lineHeight:zn,padding:Ar}))}else if(ue.BaseType===ei.NODE){var vr=H.nodeText,er=vr.overflowMode,Eo=vr.lineHeight,Co=vr.wrapPadding,zr=vr.textWidth,Fo=ue,ga=Fo.width,ya=Fo.modelType,Nl=Fo.textWidth||zr||ga;(ya!==lo.TEXT_NODE&&er==="autoWrap"||ya===lo.TEXT_NODE&&zr)&&(A=Ov(Ov({},Ft),{},{width:Nl,minWidth:Nl,lineHeight:Eo,padding:Co}))}var fu=ue.text,pu=fu.x,Pd=fu.y,Av=KB(U.CanvasPointToHtmlPoint([pu,Pd]),2);return{style:Ov(Ov({left:Av[0],top:Av[1]},A),oe)}}}}],(d=[{key:"componentDidUpdate",value:function(){var _=this.props.graphModel;if(this.ref.current&&(this.ref.current.focus(),this.placeCaretAtEnd(th
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function e$(c){return(function(u){if(Array.isArray(u))return $O(u)})(c)||(function(u){if(typeof Symbol<"u"&&u[Symbol.iterator]!=null||u["@@iterator"]!=null)return Array.from(u)})(c)||CN(c)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function CN(c,u){if(c){if(typeof c=="string")return $O(c,u);var d=Object.prototype.toString.call(c).slice(8,-1);return d==="Object"&&c.constructor&&(d=c.constructor.name),d==="Map"||d==="Set"?Array.from(c):d==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(d)?$O(c,u):void 0}}function $O(c,u){(u==null||u>c.length)&&(u=c.length);for(var d=0,p=new Array(u);d<u;d++)p[d]=c[d];return p}function t$(c,u){for(var d=0;d<u.length;d++){var p=u[d];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(c,p.key,p)}}function UO(c,u){return UO=Object.setPrototypeOf||function(d,p){return d.__proto__=p,d},UO(c,u)}function n$(c){var u=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})();return function(){var d,p=o0(c);if(u){var y=o0(this).constructor;d=Reflect.construct(p,arguments,y)}else d=p.apply(this,arguments);return r$(this,d)}}function r$(c,u){if(u&&(BO(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Jm(c)}function Jm(c){if(c===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c}function o0(c){return o0=Object.setPrototypeOf?Object.getPrototypeOf:function(u){return u.__proto__||Object.getPrototypeOf(u)},o0(c)}function Qm(c,u,d){return u in c?Object.defineProperty(c,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):c[u]=d,c}var VO=Fc((MN=AN=(function(c){(function(m,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function");m.prototype=Object.create(_&&_.prototype,{constructor:{value:m,writable:!0,configurable:!0}}),_&&UO(m,_)})(y,c);var u,d,p=n$(y);function y(m){var _;(function(H,oe){if(!(H instanceof oe))throw new TypeError("Cannot call a class as a function")})(this,y),Qm(Jm(_=p.call(this)),"stepDrag",void 0),Qm(Jm(_),"handleMouseDown",(function(H){_.stepDrag.handleMouseDown(H)})),Qm(Jm(_),"handleWheelEvent",(function(H){var oe,ue;H.preventDefault();var Ce=H.deltaX,Ve=H.deltaY,qe=H.clientX,Ot=H.clientY,xt=H.ctrlKey,Ft=new WheelEvent("wheel",{deltaX:Ce,deltaY:Ve,clientX:qe,clientY:Ot,ctrlKey:xt});(oe=_.props.logicFlow.container)===null||oe===void 0||(ue=oe.querySelector('.lf-canvas-overlay[name="canvas-overlay"]'))===null||ue===void 0||ue.dispatchEvent(Ft)})),Qm(Jm(_),"onDragging",(function(H){var oe=H.deltaX,ue=H.deltaY,Ce=_.props.graphModel,Ve=Ce.getSelectElements(!0);Ce.moveNodes(Ve.nodes.map((function(qe){return qe.id})),oe,ue)})),Qm(Jm(_),"handleContextMenu",(function(H){H.preventDefault();var oe=_.props,ue=oe.graphModel,Ce=oe.graphModel,Ve=Ce.eventCenter,qe=Ce.selectElements,Ot=ue.getPointByClient({x:H.clientX,y:H.clientY}),xt={nodes:[],edges:[]};e$(qe.values()).forEach((function(Ft){Ft.BaseType===ei.NODE&&xt.nodes.push(Ft.getData()),Ft.BaseType===ei.EDGE&&xt.edges.push(Ft.getData())})),Ve.emit(ur.SELECTION_CONTEXTMENU,{data:xt,e:H,position:Ot})}));var A=m.graphModel,N=A.gridSize,U=A.eventCenter;return _.stepDrag=new Te({onDragging:_.onDragging,step:N,eventType:"SELECTION",eventCenter:U}),_}return u=y,(d=[{key:"render",value:function(){var m=this.props.graphModel,_=m.selectElements,A=m.transformModel;if(!(_.size<=1)){var N=Number.MAX_SAFE_INTEGER,U=Number.MAX_SAFE_INTEGER,H=Number.MIN_SAFE_INTEGER,oe=Number.MIN_SAFE_INTEGER;_.forEach((function(qe){var Ot={x:0,y:0,x1:0,y1:0};qe.BaseType===ei.NODE&&(Ot=(function(xt){var Ft=xt.x,hn=xt.y,Hn=xt.width,zn=xt.height;return{x:Ft-Hn/2,y:hn-zn/2,x1:Ft+Hn/2,y1:hn+zn/2}})(qe)),qe.BaseType===ei.EDGE&&(Ot=QB(qe)),N=Math.min(N,Ot.x),U=Math.min(U,Ot.y),H=Math.max(H,Ot.x1),oe=Math.max(oe,Ot.y1)}));var ue=TN(A.CanvasPointToHtmlPoint([N,U]),2);N=ue[0],U=ue[1];var Ce=TN(A.CanvasPointToHtmlPoint([H,oe]),2);H=Ce[0],oe=Ce[1];var Ve={left:"".concat(N-10,"px"),top:"".concat(U-1
|
|||
|
|
<g filter="url(#filter0_d_5119_232585)">
|
|||
|
|
<path d="M20.9998 29.8333C28.0875 29.8333 33.8332 24.0876 33.8332 17C33.8332 9.91231 28.0875 4.16663 20.9998 4.16663C13.9122 4.16663 8.1665 9.91231 8.1665 17C8.1665 24.0876 13.9122 29.8333 20.9998 29.8333Z" fill="white"/>
|
|||
|
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M20.9998 27.5C26.7988 27.5 31.4998 22.799 31.4998 17C31.4998 11.201 26.7988 6.49996 20.9998 6.49996C15.2008 6.49996 10.4998 11.201 10.4998 17C10.4998 22.799 15.2008 27.5 20.9998 27.5ZM33.8332 17C33.8332 24.0876 28.0875 29.8333 20.9998 29.8333C13.9122 29.8333 8.1665 24.0876 8.1665 17C8.1665 9.91231 13.9122 4.16663 20.9998 4.16663C28.0875 4.16663 33.8332 9.91231 33.8332 17Z" fill="#3370FF"/>
|
|||
|
|
</g>
|
|||
|
|
<defs>
|
|||
|
|
<filter id="filter0_d_5119_232585" x="-1" y="-1" width="44" height="44" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
|||
|
|
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
|||
|
|
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
|
|||
|
|
<feOffset dy="4"/>
|
|||
|
|
<feGaussianBlur stdDeviation="4"/>
|
|||
|
|
<feComposite in2="hardAlpha" operator="out"/>
|
|||
|
|
<feColorMatrix type="matrix" values="0 0 0 0 0.2 0 0 0 0 0.439216 0 0 0 0 1 0 0 0 0.1 0"/>
|
|||
|
|
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_5119_232585"/>
|
|||
|
|
<feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_5119_232585" result="shape"/>
|
|||
|
|
</filter>
|
|||
|
|
</defs>
|
|||
|
|
</svg>
|
|||
|
|
`:`<svg width="100%" height="100%" viewBox="0 0 42 42" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|||
|
|
<g filter="url(#filter0_d_5199_166905)">
|
|||
|
|
<path d="M20.9998 29.8333C28.0875 29.8333 33.8332 24.0876 33.8332 17C33.8332 9.91231 28.0875 4.16663 20.9998 4.16663C13.9122 4.16663 8.1665 9.91231 8.1665 17C8.1665 24.0876 13.9122 29.8333 20.9998 29.8333Z" fill="#3370FF"/>
|
|||
|
|
<path d="M19.8332 11.75C19.8332 11.4278 20.0943 11.1666 20.4165 11.1666H21.5832C21.9053 11.1666 22.1665 11.4278 22.1665 11.75V15.8333H26.2498C26.572 15.8333 26.8332 16.0945 26.8332 16.4166V17.5833C26.8332 17.9055 26.572 18.1666 26.2498 18.1666H22.1665V22.25C22.1665 22.5721 21.9053 22.8333 21.5832 22.8333H20.4165C20.0943 22.8333 19.8332 22.5721 19.8332 22.25V18.1666H15.7498C15.4277 18.1666 15.1665 17.9055 15.1665 17.5833V16.4166C15.1665 16.0945 15.4277 15.8333 15.7498 15.8333H19.8332V11.75Z" fill="white"/>
|
|||
|
|
</g>
|
|||
|
|
<defs>
|
|||
|
|
<filter id="filter0_d_5199_166905" x="-1" y="-1" width="44" height="44" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
|||
|
|
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
|||
|
|
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
|
|||
|
|
<feOffset dy="4"/>
|
|||
|
|
<feGaussianBlur stdDeviation="4"/>
|
|||
|
|
<feComposite in2="hardAlpha" operator="out"/>
|
|||
|
|
<feColorMatrix type="matrix" values="0 0 0 0 0.2 0 0 0 0 0.439216 0 0 0 0 1 0 0 0 0.1 0"/>
|
|||
|
|
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_5199_166905"/>
|
|||
|
|
<feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_5199_166905" result="shape"/>
|
|||
|
|
</filter>
|
|||
|
|
</defs>
|
|||
|
|
</svg>`}})])}setHtml(n){if(this.isMounted)this.r&&this.r.component&&(this.r.component.props.properties=this.props.model.getProperties());else{this.isMounted=!0;const o=document.createElement("div");n.appendChild(o),this.renderVueComponent(o)}}componentWillUnmount(){super.componentWillUnmount(),this.unmount()}getComponentContainer(){return this.root}targetId(){return`${this.props.graphModel.flowId}:${this.props.model.id}`}renderVueComponent(n){var i;this.unmountVueComponent(),this.root=n;const{model:o,graphModel:r}=this.props;if(n)if(d1())t8(this.targetId(),this.component,n,o,r,void 0,this.props.graphModel.get_provide);else{this.r=Dg(this.component,{properties:this.props.model.properties,nodeModel:this.props.model}),this.app=Lj({render(){return this.r},provide(){return{getNode:()=>o,getGraph:()=>r,workflowMode:nc.Application}}}),this.app.use(a9,{locale:l9}),this.app.use(s9),this.app.use(u9),this.app.use(jj);for(const[a,s]of Object.entries(c9))this.app.component(a,s);(i=this.app)==null||i.mount(n)}}unmountVueComponent(){return this.app&&(this.app.unmount(),this.app=null),this.root&&(this.root.innerHTML=""),this.root}unmount(){d1()&&n8(this.targetId()),this.unmountVueComponent()}}class li extends WI.model{refreshDeges(){this.incoming.edges.forEach(e=>{e.updatePathByAnchor()}),this.outgoing.edges.forEach(e=>{e.updatePathByAnchor()})}set_position(e){const{x:n,y:o}=e;n&&(this.x=n),o&&(this.y=o),this.refreshDeges()}getResizeOutlineStyle(){const e=super.getResizeOutlineStyle();return e.stroke="none",e}getControlPointStyle(){const e=super.getControlPointStyle();return e.stroke="none",e.fill="none",e}getNodeStyle(){return{overflow:"visible"}}getOutlineStyle(){const e=super.getOutlineStyle();return e.stroke="#e0e0e0",e.strokeWidth=1,e.hover&&(e.hover.stroke="#3370FF",e.hover.strokeWidth=2),e}getAnchorStyle(e){return super.getAnchorStyle(e)}setHeight(e){const n=this.height,o=e+100;this.height=o,this.properties.height=o,this.move(0,(o-n)/2),this.outgoing.edges.forEach(r=>{r.updatePathByAnchor()}),this.incoming.edges.forEach(r=>{r.updatePathByAnchor()})}get_width(){var e;return((e=this.properties)==null?void 0:e.width)||340}setAttributes(){const{t:e}=jj.global;this.width=this.get_width();const n=(r,i)=>{const a=this.graphModel.getNodeIncomingNode(r);for(const s in a){const l=a[s];if(l.id===i)return!0;if(n(l.id,i))return!0}return!1},o={message:e("views.applicationWorkflow.tip.onlyRight"),validate:(r,i,a)=>a.type==="right"};this.sourceRules.push({message:e("views.applicationWorkflow.tip.notRecyclable"),validate:(r,i,a,s)=>i.id==r.id?!1:!this.graphModel.getNodeIncomingEdge(i.id).find(h=>h.targetAnchorId==s.id&&h.sourceAnchorId==a.id)&&!n(r.id,i.id)}),this.sourceRules.push(o),this.targetRules.push({message:e("views.applicationWorkflow.tip.onlyLeft"),validate:(r,i,a,s)=>s.type==="left"})}getDefaultAnchor(){const{id:e,x:n,y:o,width:r}=this,i=this.properties.showNode===void 0?!0:this.properties.showNode,a=[];return this.type&&this.type!==kr.Base.toString()&&([kr.Start.toString(),kr.LoopStartNode.toString()].includes(this.type)||a.push({x:n-r/2+10,y:i?o:o-15,id:`${e}_left`,edgeAddable:!1,type:"left"}),a.push({x:n+r/2-10,y:i?o:o-15,id:`${e}_right`,type:"right"})),a}}let Vne=class extends ai{constructor(e){super(e,Uq)}};const Wne={type:"ai-chat-node",model:li,view:Vne},r8=Object.freeze(Object.defineProperty({__proto__:null,default:Wne},Symbol.toStringTag,{value:"Module"})),Gne={class:"title-decoration-1 mb-8"},zne={class:"flex align-center"},Hne={class:"mr-4"},Xne=_r({__name:"index",props:{nodeModel:{}},setup(t){const e=ja(),n=hr(()=>e.path.includes("resource-management")?"systemManage":"workspace"),o={question_reference_address:["start-node","question"],api_input_field_list:[],user_input_field_list:[],document_list:["start-node","document"],image_list:["start-node","image"],audio_list:["start-node","audio"],video_list:["start-node","video"]},r=He(),i=hr({get:()=>(l.nodeModel.properties.node_data||Me.set(l.nodeModel.properties,"node_data",o),l.nodeModel.properties.node_data),set:h=>{Me.set(l.nodeModel.properties,"node_data",h)}});funct
|
|||
|
|
* Sortable 1.15.6
|
|||
|
|
* @author RubaXa <trash@rubaxa.org>
|
|||
|
|
* @author owenm <owen23355@gmail.com>
|
|||
|
|
* @license MIT
|
|||
|
|
*/function NR(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),n.push.apply(n,o)}return n}function Yd(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?NR(Object(n),!0).forEach(function(o){Kne(t,o,n[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):NR(Object(n)).forEach(function(o){Object.defineProperty(t,o,Object.getOwnPropertyDescriptor(n,o))})}return t}function tw(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?tw=function(e){return typeof e}:tw=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},tw(t)}function Kne(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function up(){return up=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},up.apply(this,arguments)}function Zne(t,e){if(t==null)return{};var n={},o=Object.keys(t),r,i;for(i=0;i<o.length;i++)r=o[i],!(e.indexOf(r)>=0)&&(n[r]=t[r]);return n}function Jne(t,e){if(t==null)return{};var n=Zne(t,e),o,r;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(r=0;r<i.length;r++)o=i[r],!(e.indexOf(o)>=0)&&Object.prototype.propertyIsEnumerable.call(t,o)&&(n[o]=t[o])}return n}var Qne="1.15.6";function ap(t){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(t)}var hp=ap(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),ab=ap(/Edge/i),kR=ap(/firefox/i),m_=ap(/safari/i)&&!ap(/chrome/i)&&!ap(/android/i),LM=ap(/iP(ad|od|hone)/i),i8=ap(/chrome/i)&&ap(/android/i),a8={capture:!1,passive:!1};function Vo(t,e,n){t.addEventListener(e,n,!hp&&a8)}function Bo(t,e,n){t.removeEventListener(e,n,!hp&&a8)}function f1(t,e){if(e){if(e[0]===">"&&(e=e.substring(1)),t)try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch{return!1}return!1}}function l8(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function zc(t,e,n,o){if(t){n=n||document;do{if(e!=null&&(e[0]===">"?t.parentNode===n&&f1(t,e):f1(t,e))||o&&t===n)return t;if(t===n)break}while(t=l8(t))}return null}var PR=/\s+/g;function vu(t,e,n){if(t&&e)if(t.classList)t.classList[n?"add":"remove"](e);else{var o=(" "+t.className+" ").replace(PR," ").replace(" "+e+" "," ");t.className=(o+(n?" "+e:"")).replace(PR," ")}}function ro(t,e,n){var o=t&&t.style;if(o){if(n===void 0)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(n=t.currentStyle),e===void 0?n:n[e];!(e in o)&&e.indexOf("webkit")===-1&&(e="-webkit-"+e),o[e]=n+(typeof n=="string"?"":"px")}}function Ag(t,e){var n="";if(typeof t=="string")n=t;else do{var o=ro(t,"transform");o&&o!=="none"&&(n=o+" "+n)}while(!e&&(t=t.parentNode));var r=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return r&&new r(n)}function s8(t,e,n){if(t){var o=t.getElementsByTagName(e),r=0,i=o.length;if(n)for(;r<i;r++)n(o[r],r);return o}return[]}function Hd(){var t=document.scrollingElement;return t||document.documentElement}function Ya(t,e,n,o,r){if(!(!t.getBoundingClientRect&&t!==window)){var i,a,s,l,f,h,v;if(t!==window&&t.parentNode&&t!==Hd()?(i=t.getBoundingClientRect(),a=i.top,s=i.left,l=i.bottom,f=i.right,h=i.height,v=i.width):(a=0,s=0,l=window.innerHeight,f=window.innerWidth,h=window.innerHeight,v=window.innerWidth),(e||n)&&t!==window&&(r=r||t.parentNode,!hp))do if(r&&r.getBoundingClientRect&&(ro(r,"transform")!=="none"||n&&ro(r,"position")!=="static")){var b=r.getBoundingClientRect();a-=b.top+parseInt(ro(r,"border-top-width")),s-=b.left+parseInt(ro(r,"border-left-width")),l=a+i.height,f=s+i.width;break}while(r=r.parentNode);if(o&&t!==window){var E=Ag(
|
|||
|
|
{{form}}
|
|||
|
|
${Pt("views.applicationWorkflow.nodes.formNode.form_content_format2")}`,form_field_list:[]}),E=hr({get:()=>(e.nodeModel.properties.node_data||Me.set(e.nodeModel.properties,"node_data",b.value),e.nodeModel.properties.node_data),set:T=>{Me.set(e.nodeModel.properties,"node_data",T)}}),O=T=>{var $;if(T.default_value){const D=($=T.option_list)==null?void 0:$.filter(P=>T.default_value.indexOf(P.value)>-1).map(P=>P.label).join(",");return D||T.default_value}if(T.default_value!==void 0)return T.default_value},w=()=>{var T;return(T=n.value)==null?void 0:T.validate()};function S(T){Me.set(e.nodeModel.properties.node_data,"form_content_format",T)}function M(){if(!o.value)return;const $=o.value.$el.querySelector(".el-table__body-wrapper tbody");$&&Zr.create($,{animation:150,ghostClass:"ghost-row",onEnd:D=>{if(D.oldIndex===void 0||D.newIndex===void 0)return;const P=Me.cloneDeep([...E.value.form_field_list]),[B]=P.splice(D.oldIndex,1);P.splice(D.newIndex,0,B),E.value.form_field_list=P,a()}})}return bo(()=>{Me.set(e.nodeModel,"validate",w),a(),e.nodeModel.graphModel.eventCenter.emit("refresh_incoming_node_field")}),(T,$)=>{const D=ne("AppIcon"),P=ne("el-tooltip"),B=ne("MdEditorMagnify"),F=ne("el-form-item"),I=ne("el-button"),V=ne("el-table-column"),z=ne("el-tag"),X=ne("el-switch"),Y=ne("el-table"),W=ne("el-form"),Q=ne("el-card");return Ne(),bt(hi,{nodeModel:t.nodeModel},{default:j(()=>[ee("h5",nie,_e(T.$t("views.applicationWorkflow.nodeSetting")),1),k(Q,{shadow:"never",class:"card-never",style:{"--el-card-padding":"12px"}},{default:j(()=>[k(W,{onSubmit:$[4]||($[4]=gn(()=>{},["prevent"])),model:E.value,"label-position":"top","require-asterisk-position":"right","label-width":"auto",ref_key:"formNodeFormRef",ref:n,"hide-required-asterisk":""},{default:j(()=>[k(F,{label:T.$t("views.applicationWorkflow.nodes.formNode.formContent.label"),prop:"form_content_format",rules:{required:!0,message:T.$t("views.applicationWorkflow.nodes.formNode.formContent.requiredMessage"),trigger:"blur"}},{label:j(()=>[ee("div",rie,[ee("div",oie,[ee("span",null,[ft(_e(T.$t("views.applicationWorkflow.nodes.formNode.formContent.label")),1),$[5]||($[5]=ee("span",{class:"color-danger"},"*",-1))])]),k(P,{effect:"dark",placement:"right","popper-class":"max-w-200"},{content:j(()=>[ft(_e(T.$t("views.applicationWorkflow.nodes.formNode.formContent.tooltip",{form:"{ form }"})),1)]),default:j(()=>[k(D,{iconName:"app-warning",class:"app-warning-icon"})]),_:1})])]),default:j(()=>[k(B,{title:T.$t("views.applicationWorkflow.nodes.formNode.formContent.label"),modelValue:E.value.form_content_format,"onUpdate:modelValue":$[0]||($[0]=J=>E.value.form_content_format=J),style:{height:"150px"},onSubmitDialog:S},null,8,["title","modelValue"])]),_:1},8,["label","rules"]),k(F,{label:T.$t("views.applicationWorkflow.nodes.formNode.formSetting"),onClick:$[3]||($[3]=gn(()=>{},["prevent"]))},{label:j(()=>[ee("div",iie,[ee("h5",aie,_e(T.$t("views.applicationWorkflow.nodes.formNode.formSetting")),1),k(I,{link:"",type:"primary",onClick:$[1]||($[1]=J=>f())},{default:j(()=>[k(D,{iconName:"app-add-outlined",class:"mr-4"}),ft(" "+_e(T.$t("common.add")),1)]),_:1})])]),default:j(()=>[E.value.form_field_list.length>0?(Ne(),bt(Y,{key:0,class:"border",data:E.value.form_field_list,ref_key:"tableRef",ref:o,"row-key":"field"},{default:j(()=>[k(V,{prop:"field",label:T.$t("dynamicsForm.paramForm.field.label"),width:"95"},{default:j(({row:J})=>[ee("span",{title:J.field,class:"ellipsis-1"},_e(J.field),9,lie)]),_:1},8,["label"]),k(V,{prop:"label",label:T.$t("dynamicsForm.paramForm.name.label")},{default:j(({row:J})=>[J.label&&J.label.input_type==="TooltipLabel"?(Ne(),mn("span",sie,[ee("span",{title:J.label.label,class:"ellipsis-1"},_e(J.label.label),9,uie)])):(Ne(),mn("span",cie,[ee("span",{title:J.label,class:"ellipsis-1"},_e(J.label),9,die)]))]),_:1},8,["label"]),k(V,{label:T.$t("dynamicsForm.paramForm.input_type.label"),width:"110px"},{default:j(({row:J})=>[k(z,{type:"info",class:"info-tag"},{default:j(()=>{var ie;return[ft(_e((ie=Wn(h9).find(Se=>Se.value===J.input_type))==null?void 0:ie.label),1)]}),_:2},1024)
|
|||
|
|
"math": {
|
|||
|
|
"url": "your_server",
|
|||
|
|
"transport": "sse"
|
|||
|
|
}
|
|||
|
|
}`,tle=_r({__name:"index",props:{nodeModel:{}},setup(t){const e=t,n=ja(),{params:{id:o}}=n,i=ml("getApplicationDetail")(),a=hr(()=>n.path.includes("resource-management")?"systemManage":"workspace"),s=He(),l=He(!1),f=I=>I.ctrlKey===!0?(I.preventDefault(),!0):(I.stopPropagation(),!0),h={mcp_tool:"",mcp_tools:[],mcp_servers:"",mcp_server:"",mcp_source:"referencing",mcp_tool_id:"",tool_params:{},tool_form_field:[],params_nested:""},v=He([]);function b(I){Me.set(e.nodeModel.properties.node_data,"mcp_servers",I)}async function E(){const I=await oi({type:"tool",systemType:a.value}).getToolById(D.value.mcp_tool_id,l);D.value.mcp_servers=I.data.code}function O(){if(D.value.mcp_source==="referencing"&&!D.value.mcp_tool_id){Xi(Pt("views.applicationWorkflow.nodes.mcpNode.mcpToolTip"));return}if(D.value.mcp_source==="referencing"&&D.value.mcp_tool_id&&!v.value.find(I=>I.id===D.value.mcp_tool_id)){Xi(Pt("views.applicationWorkflow.nodes.mcpNode.mcpToolTip"));return}if(D.value.mcp_source==="custom"&&!D.value.mcp_servers){Xi(Pt("views.applicationWorkflow.nodes.mcpNode.mcpServerTip"));return}try{JSON.parse(D.value.mcp_servers);const I=M(D.value.mcp_servers);if(I.length>0){S.value.open(I);return}}catch{Xi(Pt("views.applicationWorkflow.nodes.mcpNode.mcpServerTip"));return}w(D.value.mcp_servers)}function w(I){oi({type:"application",systemType:a.value}).getMcpTools(o,I,l).then(V=>{var z;D.value.mcp_tools=V.data,Oh(Pt("views.applicationWorkflow.nodes.mcpNode.getToolsSuccess")),D.value.mcp_server=(z=D.value.mcp_tools.find(X=>X.name===D.value.mcp_tool))==null?void 0:z.server})}const S=He();function M(I){const V=/\{\{\s*([a-zA-Z_][\w.]*)\s*\}\}/g,z=new Set,X=Y=>{if(typeof Y=="string"){let W;for(;(W=V.exec(Y))!==null;)z.add(W[1])}else Array.isArray(Y)?Y.forEach(X):Y&&typeof Y=="object"&&Object.values(Y).forEach(X)};if(typeof I=="string")try{X(JSON.parse(I))}catch{X(I)}else X(I);return[...z]}function T(I){let V=D.value.mcp_servers;for(const z in I)V=V.replace(`{{${z}}}`,I[z]);w(V)}function $(){var V,z,X,Y,W,Q;D.value.mcp_server=(V=D.value.mcp_tools.find(J=>J.name===D.value.mcp_tool))==null?void 0:V.server;const I=(z=D.value.mcp_tools.find(J=>J.name===D.value.mcp_tool))==null?void 0:z.args_schema;D.value.tool_form_field=[];for(const J in I==null?void 0:I.properties){const ie=I==null?void 0:I.properties[J].properties;if(ie){D.value.params_nested=J;for(const Se in ie){let Ae="TextInput";ie[Se].type==="string"?Ae="TextInput":ie[Se].type==="number"?Ae="NumberInput":ie[Se].type==="boolean"?Ae="SwitchInput":(ie[Se].type==="array"||ie[Se].type==="object")&&(Ae="JsonInput"),D.value.tool_form_field.push({field:Se,label:{input_type:"TooltipLabel",label:Se,attrs:{tooltip:ie[Se].description},props_info:{}},input_type:Ae,source:"referencing",required:((X=I.properties[J].required)==null?void 0:X.indexOf(Se))!==-1,props_info:{rules:[{required:((Y=I.properties[J].required)==null?void 0:Y.indexOf(Se))!==-1,message:Pt("dynamicsForm.tip.requiredMessage"),trigger:"blur"}]}})}}else{D.value.params_nested="";let Se="TextInput";I.properties[J].type==="string"?Se="TextInput":I.properties[J].type==="number"?Se="NumberInput":I.properties[J].type==="boolean"?Se="SwitchInput":(I.properties[J].type==="array"||I.properties[J].type==="object")&&(Se="JsonInput"),D.value.tool_form_field.push({field:J,label:{input_type:"TooltipLabel",label:J,attrs:{tooltip:I.properties[J].description},props_info:{}},input_type:Se,source:"referencing",required:((W=I.required)==null?void 0:W.indexOf(J))!==-1,props_info:{rules:[{required:((Q=I.required)==null?void 0:Q.indexOf(J))!==-1,message:Pt("dynamicsForm.tip.requiredMessage"),trigger:"blur"}]}})}}D.value.params_nested?D.value.tool_params={[D.value.params_nested]:{}}:D.value.tool_params={}}const D=hr({get:()=>(e.nodeModel.properties.node_data||Me.set(e.nodeModel.properties,"node_data",h),e.nodeModel.properties.node_data),set:I=>{Me.set(e.nodeModel.properties,"node_data",I)}}),P=He(),B=async()=>{if(s.value){const I=D.value.tool_form_field.filter(V=>V.required).map(V=>V.label.label);if(I.length>0){for(const V of I)if(D.value.params_nested){if(!D.valu
|
|||
|
|
`,r);return}throw r}n(" updateInputGraph",()=>{Efe(t,o)})})},bfe=(t,e,n)=>{e(" removeSelfEdges",()=>{Bfe(t)}),e(" acyclic",()=>{qR.run(t)}),e(" nestingGraph.run",()=>{tD.run(t)}),e(" rank",()=>{Mde(Z8(t))}),e(" injectEdgeLabelProxies",()=>{kfe(t)}),e(" removeEmptyRanks",()=>{lde(t)}),e(" nestingGraph.cleanup",()=>{tD.cleanup(t)}),e(" normalizeRanks",()=>{ade(t)}),e(" assignRankMinMax",()=>{Pfe(t)}),e(" removeEdgeLabelProxies",()=>{Rfe(t)}),e(" normalize.run",()=>{JR.run(t)}),e(" parentDummyChains",()=>{Pde(t)}),e(" addBorderSegments",()=>{Ide(t)}),n&&n.keepNodeOrder&&e(" initDataOrder",()=>{yfe(t,n.nodeOrder)}),e(" order",()=>{tfe(t,n==null?void 0:n.keepNodeOrder)}),e(" insertSelfEdges",()=>{$fe(t)}),e(" adjustCoordinateSystem",()=>{oD.adjust(t)}),e(" position",()=>{gfe(t)}),e(" positionSelfEdges",()=>{Ufe(t)}),e(" removeBorderNodes",()=>{Ffe(t)}),e(" normalize.undo",()=>{JR.undo(t)}),e(" fixupEdgeLabelCoords",()=>{Lfe(t)}),e(" undoCoordinateSystem",()=>{oD.undo(t)}),e(" translateGraph",()=>{Dfe(t)}),e(" assignNodeIntersects",()=>{jfe(t)}),e(" reversePoints",()=>{Ife(t)}),e(" acyclic.undo",()=>{qR.undo(t)})},wfe=(t,e)=>{t.nodes().forEach(n=>{const o=t.node(n),r=e.node(n);r!==void 0?(o.fixorder=r._order,delete r._order):delete o.fixorder})},Efe=(t,e)=>{t.nodes().forEach(n=>{var o;const r=t.node(n);if(r){const i=e.node(n);r.x=i.x,r.y=i.y,r._order=i.order,r._rank=i.rank,!((o=e.children(n))===null||o===void 0)&&o.length&&(r.width=i.width,r.height=i.height)}}),t.edges().forEach(n=>{const o=t.edge(n),r=e.edge(n);o.points=r?r.points:[],r&&r.hasOwnProperty("x")&&(o.x=r.x,o.y=r.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height},xfe=["nodesep","edgesep","ranksep","marginx","marginy"],Ofe={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},LS=["acyclicer","ranker","rankdir","align"],Sfe=["width","height","layer","fixorder"],Afe={width:0,height:0},Mfe=["minlen","weight","width","height","labeloffset"],Tfe={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},IS=["labelpos"],Cfe=t=>{const e=new cp({multigraph:!0,compound:!0}),n=BS(t.graph()),o={};return LS==null||LS.forEach(r=>{n[r]!==void 0&&(o[r]=n[r])}),e.setGraph(Object.assign({},Ofe,FS(n,xfe),o)),t.nodes().forEach(r=>{const i=BS(t.node(r)),a=Object.assign(Object.assign({},Afe),i),s=FS(a,Sfe);e.setNode(r,s),e.setParent(r,t.parent(r))}),t.edges().forEach(r=>{const i=BS(t.edge(r)),a={};IS==null||IS.forEach(s=>{i[s]!==void 0&&(a[s]=i[s])}),e.setEdgeObj(r,Object.assign({},Tfe,FS(i,Mfe),a))}),e},Nfe=t=>{const e=t.graph();e.ranksep||(e.ranksep=0),e.ranksep/=2,t.nodes().forEach(n=>{const o=t.node(n);isNaN(o.layer)||o.layer||(o.layer=0)}),t.edges().forEach(n=>{var o;const r=t.edge(n);r.minlen*=2,((o=r.labelpos)===null||o===void 0?void 0:o.toLowerCase())!=="c"&&(e.rankdir==="TB"||e.rankdir==="BT"?r.width+=r.labeloffset:r.height+=r.labeloffset)})},kfe=t=>{t.edges().forEach(e=>{const n=t.edge(e);if(n.width&&n.height){const o=t.node(e.v),r=t.node(e.w),i={e,rank:(r.rank-o.rank)/2+o.rank};uy(t,"edge-proxy",i,"_ep")}})},Pfe=t=>{let e=0;t.nodes().forEach(n=>{var o,r;const i=t.node(n);i.borderTop&&(i.minRank=(o=t.node(i.borderTop))===null||o===void 0?void 0:o.rank,i.maxRank=(r=t.node(i.borderBottom))===null||r===void 0?void 0:r.rank,e=Math.max(e,i.maxRank||-1/0))}),t.graph().maxRank=e},Rfe=t=>{t.nodes().forEach(e=>{const n=t.node(e);n.dummy==="edge-proxy"&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})},Dfe=t=>{let e,n=0,o,r=0;const i=t.graph(),a=i.marginx||0,s=i.marginy||0,l=f=>{if(!f)return;const h=f.x,v=f.y,b=f.width,E=f.height;!isNaN(h)&&!isNaN(b)&&(e===void 0&&(e=h-b/2),e=Math.min(e,h-b/2),n=Math.max(n,h+b/2)),!isNaN(v)&&!isNaN(E)&&(o===void 0&&(o=v-E/2),o=Math.min(o,v-E/2),r=Math.max(r,v+E/2))};t.nodes().forEach(f=>{l(t.node(f))}),t.edges().forEach(f=>{const h=t.edge(f);h!=null&&h.hasOwnProperty("x")&&l(h)}),e-=a,o-=s,t.nodes().forEach(f=>{const h=t.node(f);h&&(h.x-=e,h.y-=o)}),t.edges().forEach(f=>{var h;const v=t.edge(f);(h=v.points)===null||h===void 0||h.forEach(b=>{b.x-=e,b.y
|
|||
|
|
`;function i(K){return typeof atob<"u"?atob(K):"base64:"+K}function a(K){var me=new Error("(regl) "+K);throw console.error(me),me}function s(K,me){K||a(me)}function l(K){return K?": "+K:""}function f(K,me,Ie){K in me||a("unknown parameter ("+K+")"+l(Ie)+". possible values: "+Object.keys(me).join())}function h(K,me){n(K)||a("invalid parameter type"+l(me)+". must be a typed array")}function v(K,me){switch(me){case"number":return typeof K=="number";case"object":return typeof K=="object";case"string":return typeof K=="string";case"boolean":return typeof K=="boolean";case"function":return typeof K=="function";case"undefined":return typeof K>"u";case"symbol":return typeof K=="symbol"}}function b(K,me,Ie){v(K,me)||a("invalid parameter type"+l(Ie)+". expected "+me+", got "+typeof K)}function E(K,me){K>=0&&(K|0)===K||a("invalid parameter type, ("+K+")"+l(me)+". must be a nonnegative integer")}function O(K,me,Ie){me.indexOf(K)<0&&a("invalid value"+l(Ie)+". must be one of: "+me)}var w=["gl","canvas","container","attributes","pixelRatio","extensions","optionalExtensions","profile","onDone"];function S(K){Object.keys(K).forEach(function(me){w.indexOf(me)<0&&a('invalid regl constructor argument "'+me+'". must be one of '+w)})}function M(K,me){for(K=K+"";K.length<me;)K=" "+K;return K}function T(){this.name="unknown",this.lines=[],this.index={},this.hasErrors=!1}function $(K,me){this.number=K,this.line=me,this.errors=[]}function D(K,me,Ie){this.file=K,this.line=me,this.message=Ie}function P(){var K=new Error,me=(K.stack||K).toString(),Ie=/compileProcedure.*\n\s*at.*\((.*)\)/.exec(me);if(Ie)return Ie[1];var wt=/compileProcedure.*\n\s*at\s+(.*)(\n|$)/.exec(me);return wt?wt[1]:"unknown"}function B(){var K=new Error,me=(K.stack||K).toString(),Ie=/at REGLCommand.*\n\s+at.*\((.*)\)/.exec(me);if(Ie)return Ie[1];var wt=/at REGLCommand.*\n\s+at\s+(.*)\n/.exec(me);return wt?wt[1]:"unknown"}function F(K,me){var Ie=K.split(`
|
|||
|
|
`),wt=1,Dt=0,yt={unknown:new T,0:new T};yt.unknown.name=yt[0].name=me||P(),yt.unknown.lines.push(new $(0,""));for(var Nt=0;Nt<Ie.length;++Nt){var tn=Ie[Nt],sn=/^\s*#\s*(\w+)\s+(.+)\s*$/.exec(tn);if(sn)switch(sn[1]){case"line":var nn=/(\d+)(\s+\d+)?/.exec(sn[2]);nn&&(wt=nn[1]|0,nn[2]&&(Dt=nn[2]|0,Dt in yt||(yt[Dt]=new T)));break;case"define":var Mt=/SHADER_NAME(_B64)?\s+(.*)$/.exec(sn[2]);Mt&&(yt[Dt].name=Mt[1]?i(Mt[2]):Mt[2]);break}yt[Dt].lines.push(new $(wt++,tn))}return Object.keys(yt).forEach(function(wn){var pn=yt[wn];pn.lines.forEach(function(rn){pn.index[rn.number]=rn})}),yt}function I(K){var me=[];return K.split(`
|
|||
|
|
`).forEach(function(Ie){if(!(Ie.length<5)){var wt=/^ERROR:\s+(\d+):(\d+):\s*(.*)$/.exec(Ie);wt?me.push(new D(wt[1]|0,wt[2]|0,wt[3].trim())):Ie.length>0&&me.push(new D("unknown",0,Ie))}}),me}function V(K,me){me.forEach(function(Ie){var wt=K[Ie.file];if(wt){var Dt=wt.index[Ie.line];if(Dt){Dt.errors.push(Ie),wt.hasErrors=!0;return}}K.unknown.hasErrors=!0,K.unknown.lines[0].errors.push(Ie)})}function z(K,me,Ie,wt,Dt){if(!K.getShaderParameter(me,K.COMPILE_STATUS)){var yt=K.getShaderInfoLog(me),Nt=wt===K.FRAGMENT_SHADER?"fragment":"vertex";Se(Ie,"string",Nt+" shader source must be a string",Dt);var tn=F(Ie,Dt),sn=I(yt);V(tn,sn),Object.keys(tn).forEach(function(nn){var Mt=tn[nn];if(!Mt.hasErrors)return;var wn=[""],pn=[""];function rn(Wt,st){wn.push(Wt),pn.push(st||"")}rn("file number "+nn+": "+Mt.name+`
|
|||
|
|
`,"color:red;text-decoration:underline;font-weight:bold"),Mt.lines.forEach(function(Wt){if(Wt.errors.length>0){rn(M(Wt.number,4)+"| ","background-color:yellow; font-weight:bold"),rn(Wt.line+r,"color:red; background-color:yellow; font-weight:bold");var st=0;Wt.errors.forEach(function(St){var ln=St.message,An=/^\s*'(.*)'\s*:\s*(.*)$/.exec(ln);if(An){var Xt=An[1];switch(ln=An[2],Xt){case"assign":Xt="=";break}st=Math.max(Wt.line.indexOf(Xt,st),0)}else st=0;rn(M("| ",6)),rn(M("^^^",st+3)+r,"font-weight:bold"),rn(M("| ",6)),rn(ln+r,"font-weight:bold")}),rn(M("| ",6)+r)}else rn(M(Wt.number,4)+"| "),rn(Wt.line+r,"color:red")}),typeof document<"u"&&!window.chrome?(pn[0]=wn.join("%c"),console.log.apply(console,pn)):console.log(wn.join(""))}),s.raise("Error compiling "+Nt+" shader, "+tn[0].name)}}function X(K,me,Ie,wt,Dt){if(!K.getProgramParameter(me,K.LINK_STATUS)){var yt=K.getProgramInfoLog(me),Nt=F(Ie,Dt),tn=F(wt,Dt),sn='Error linking program with vertex shader, "'+tn[0].name+'", and fragment shader "'+Nt[0].name+'"';typeof document<"u"?console.log("%c"+sn+r+"%c"+yt,"color:red;text-decoration:underline;font-weight:bold","color:red"):console.log(sn+r+yt),s.raise(sn)}}function Y(K){K._commandRef=P()}function W(K,me,Ie,wt){Y(K);function Dt(sn){return sn?wt.id(sn):0}K._fragId=Dt(K.static.frag),K._vertId=Dt(K.static.vert);function yt(sn,nn){Object.keys(nn).forEach(function(Mt){sn[wt.id(Mt)]=!0})}var Nt=K._uniformSet={};yt(Nt,me.static),yt(Nt,me.dynamic);var tn=K._attributeSet={};yt(tn,Ie.static),yt(tn,Ie.dynamic),K._hasCount="count"in K.static||"count"in K.dynamic||"elements"in K.static||"elements"in K.dynamic}function Q(K,me){var Ie=B();a(K+" in command "+(me||P())+(Ie==="unknown"?"":" called from "+Ie))}function J(K,me,Ie){K||Q(me,Ie||P())}function ie(K,me,Ie,wt){K in me||Q("unknown parameter ("+K+")"+l(Ie)+". possible values: "+Object.keys(me).join(),wt||P())}function Se(K,me,Ie,wt){v(K,me)||Q("invalid parameter type"+l(Ie)+". expected "+me+", got "+typeof K,wt||P())}function Ae(K){K()}function Pe(K,me,Ie){K.texture?O(K.texture._texture.internalformat,me,"unsupported texture format for attachment"):O(K.renderbuffer._renderbuffer.format,Ie,"unsupported renderbuffer format for attachment")}var De=33071,ze=9728,Ye=9984,Be=9985,Je=9986,gt=9987,le=5120,Ze=5121,pe=5122,se=5123,we=5124,$e=5125,rt=5126,pt=32819,Lt=32820,Jt=33635,en=34042,zt=36193,it={};it[le]=it[Ze]=1,it[pe]=it[se]=it[zt]=it[Jt]=it[pt]=it[Lt]=2,it[we]=it[$e]=it[rt]=it[en]=4;function ae(K,me){return K===Lt||K===pt||K===Jt?2:K===en?4:it[K]*me}function re(K){return!(K&K-1)&&!!K}function je(K,me,Ie){var wt,Dt=me.width,yt=me.height,Nt=me.channels;s(Dt>0&&Dt<=Ie.maxTextureSize&&yt>0&&yt<=Ie.maxTextureSize,"invalid texture shape"),(K.wrapS!==De||K.wrapT!==De)&&s(re(Dt)&&re(yt),"incompatible wrap mode for texture, both width and height must be power of 2"),me.mipmask===1?Dt!==1&&yt!==1&&s(K.minFilter!==Ye&&K.minFilter!==Je&&K.minFilter!==Be&&K.minFilter!==gt,"min filter requires mipmap"):(s(re(Dt)&&re(yt),"texture must be a square power of 2 to support mipmapping"),s(me.mipmask===(Dt<<1)-1,"missing or incomplete mipmap data")),me.type===rt&&(Ie.extensions.indexOf("oes_texture_float_linear")<0&&s(K.minFilter===ze&&K.magFilter===ze,"filter not supported, must enable oes_texture_float_linear"),s(!K.genMipmaps,"mipmap generation not supported with float textures"));var tn=me.images;for(wt=0;wt<16;++wt)if(tn[wt]){var sn=Dt>>wt,nn=yt>>wt;s(me.mipmask&1<<wt,"missing mipmap data");var Mt=tn[wt];if(s(Mt.width===sn&&Mt.height===nn,"invalid shape for mip images"),s(Mt.format===me.format&&Mt.internalformat===me.internalformat&&Mt.type===me.type,"incompatible type for mip image"),!Mt.compressed)if(Mt.data){var wn=Math.ceil(ae(Mt.type,Nt)*sn/Mt.unpackAlignment)*Mt.unpackAlignment;s(Mt.data.byteLength===wn*nn,"invalid data for image, buffer size is inconsistent with image format")}else Mt.element||Mt.copy}else K.genMipmaps||s((me.mipmask&1<<wt)===0,"extra mipmap data");me.compressed&&s(!K.genMipmaps,"mipmap generation for compressed images not supported")}function vt(K,me,Ie,wt){var Dt=K.wid
|
|||
|
|
`).replace(/}/g,`}
|
|||
|
|
`).replace(/{/g,`{
|
|||
|
|
`),rn=Function.apply(null,me.concat(pn));return rn.apply(null,Ie)}return{global:tn,link:wt,block:Dt,proc:nn,scope:yt,cond:Nt,compile:Mt}}var ou="xyzw".split(""),yc=5121,_c=1,bc=2,Fp=0,iu=1,wc=2,Bp=3,fs=4,wf=5,Ef=6,md="dither",gd="blend.enable",yd="blend.color",$p="blend.equation",_d="blend.func",ov="depth.enable",Up="depth.func",Tm="depth.range",iv="depth.mask",ps="colorMask",av="cull.enable",lv="cull.face",sv="frontFace",bd="lineWidth",Ls="polygonOffset.enable",xf="polygonOffset.offset",Vp="sample.alpha",Wp="sample.enable",Cu="sample.coverage",Nu="stencil.enable",Rr="stencil.mask",wd="stencil.func",Of="stencil.opFront",hs="stencil.opBack",aa="scissor.enable",Ec="scissor.box",Ti="viewport",ku="profile",tl="framebuffer",Sf="vert",Ra="frag",Fi="elements",Is="primitive",Fs="count",Gp="offset",Qt="instances",xc="vao",Af="Width",Mf="Height",Pu=tl+Af,Oc=tl+Mf,zp=Ti+Af,uv=Ti+Mf,Sc="drawingBuffer",Tf=Sc+Af,Hp=Sc+Mf,cv=[_d,$p,wd,Of,hs,Cu,Ti,Ec,xf],Bs=34962,dv=34963,vs=35632,Ru=35633,Xp=3553,Cm=34067,Nm=2884,km=3042,fv=3024,Yp=2960,Cf=2929,Pm=3089,ms=32823,Du=32926,_y=32928,gi=5126,Nf=35664,Ac=35665,kf=35666,Ed=5124,Pf=35667,Rf=35668,Df=35669,Mc=35670,au=35671,ma=35672,qp=35673,jf=35674,Tc=35675,xd=35676,wa=35678,xi=35680,Lf=4,za=1028,wr=1029,Kp=2304,If=2305,Zp=32775,pv=32776,Rm=519,ju=7680,Dm=0,Cc=1,jm=32774,hv=513,Ff=36160,Lm=36064,Gl={0:0,1:1,zero:0,one:1,"src color":768,"one minus src color":769,"src alpha":770,"one minus src alpha":771,"dst color":774,"one minus dst color":775,"dst alpha":772,"one minus dst alpha":773,"constant color":32769,"one minus constant color":32770,"constant alpha":32771,"one minus constant alpha":32772,"src alpha saturate":776},lu=["constant color, constant alpha","one minus constant color, constant alpha","constant color, one minus constant alpha","one minus constant color, one minus constant alpha","constant alpha, constant color","constant alpha, one minus constant color","one minus constant alpha, constant color","one minus constant alpha, one minus constant color"],Lu={never:512,less:513,"<":513,equal:514,"=":514,"==":514,"===":514,lequal:515,"<=":515,greater:516,">":516,notequal:517,"!=":517,"!==":517,gequal:518,">=":518,always:519},Er={0:0,zero:0,keep:7680,replace:7681,increment:7682,decrement:7683,"increment wrap":34055,"decrement wrap":34056,invert:5386},vv={frag:vs,vert:Ru},Od={cw:Kp,ccw:If};function su(K){return Array.isArray(K)||n(K)||Ia(K)}function Bf(K){return K.sort(function(me,Ie){return me===Ti?-1:Ie===Ti?1:me<Ie?-1:1})}function Ha(K,me,Ie,wt){this.thisDep=K,this.contextDep=me,this.propDep=Ie,this.append=wt}function gs(K){return K&&!(K.thisDep||K.contextDep||K.propDep)}function Ci(K){return new Ha(!1,!1,!1,K)}function dl(K,me){var Ie=K.type;if(Ie===Fp){var wt=K.data.length;return new Ha(!0,wt>=1,wt>=2,me)}else if(Ie===fs){var Dt=K.data;return new Ha(Dt.thisDep,Dt.contextDep,Dt.propDep,me)}else{if(Ie===wf)return new Ha(!1,!1,!1,me);if(Ie===Ef){for(var yt=!1,Nt=!1,tn=!1,sn=0;sn<K.data.length;++sn){var nn=K.data[sn];if(nn.type===iu)tn=!0;else if(nn.type===wc)Nt=!0;else if(nn.type===Bp)yt=!0;else if(nn.type===Fp){yt=!0;var Mt=nn.data;Mt>=1&&(Nt=!0),Mt>=2&&(tn=!0)}else nn.type===fs&&(yt=yt||nn.data.thisDep,Nt=Nt||nn.data.contextDep,tn=tn||nn.data.propDep)}return new Ha(yt,Nt,tn,me)}else return new Ha(Ie===Bp,Ie===wc,Ie===iu,me)}}var zl=new Ha(!1,!1,!1,function(){});function by(K,me,Ie,wt,Dt,yt,Nt,tn,sn,nn,Mt,wn,pn,rn,Wt){var st=nn.Record,St={add:32774,subtract:32778,"reverse subtract":32779};Ie.ext_blend_minmax&&(St.min=Zp,St.max=pv);var ln=Ie.angle_instanced_arrays,An=Ie.webgl_draw_buffers,Xt={dirty:!0,profile:Wt.profile},kn={},Kt=[],_n={},Yt={};function xn(xe){return xe.replace(".","_")}function ar(xe,de,We){var tt=xn(xe);Kt.push(xe),kn[tt]=Xt[tt]=!!We,_n[tt]=de}function xr(xe,de,We){var tt=xn(xe);Kt.push(xe),Array.isArray(We)?(Xt[tt]=We.slice(),kn[tt]=We.slice()):Xt[tt]=kn[tt]=We,Yt[tt]=de}ar(md,fv),ar(gd,km),xr(yd,"blendColor",[0,0,0,0]),xr($p,"blendEquationSeparate",[jm,jm]),xr(_d,"blendFuncSeparate",[Cc,Dm,Cc,Dm]),ar(ov,Cf,!0),xr(Up,"depthFunc",hv),xr(Tm,"depthRange",[0,1]),xr(iv,"
|