zen-gitsync 2.17.47 → 2.17.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -2
- package/package.json +2 -1
- package/src/cli/ai/mcp.js +323 -27
- package/src/cli/ai/mcp.test.js +202 -2
- package/src/ui/public/assets/{AgentEngineSelector-CKiVaqrY.js → AgentEngineSelector-Bm_wrfGT.js} +1 -1
- package/src/ui/public/assets/AgentView-BwqOHAs3.js +1 -0
- package/src/ui/public/assets/{AgentView-CRqQYAzh.css → AgentView-uHf-KMCH.css} +1 -1
- package/src/ui/public/assets/{AppVersionBadge-IWS9XBUV.js → AppVersionBadge-DyhIkbbF.js} +2 -2
- package/src/ui/public/assets/{BranchSelector-C_mK2mkS.js → BranchSelector-CDQZlH-y.js} +1 -1
- package/src/ui/public/assets/{CommitForm-C6I9rQXn.js → CommitForm-DpIXE8z1.js} +1 -1
- package/src/ui/public/assets/{CommonDialog-2zVHBuqT.js → CommonDialog-NqZURH2F.js} +1 -1
- package/src/ui/public/assets/EditorView-0T5LR5Hz.css +1 -0
- package/src/ui/public/assets/EditorView-BC6V8V5_.js +1 -0
- package/src/ui/public/assets/{FlowExecutionViewer-0Xw0oDen.js → FlowExecutionViewer-DxDKzmaP.js} +1 -1
- package/src/ui/public/assets/{FlowOrchestrationWorkspace-BKUspY-s.js → FlowOrchestrationWorkspace-BHASB5iW.js} +1 -1
- package/src/ui/public/assets/{LogList-pbwn5n2S.js → LogList-CdtFyrLd.js} +1 -1
- package/src/ui/public/assets/{MindmapView-DYh6nuuF.js → MindmapView-2tt7W7A3.js} +1 -1
- package/src/ui/public/assets/{MonitorView-CsJyUL9v.js → MonitorView--IW5ll8A.js} +1 -1
- package/src/ui/public/assets/{ProjectStartupButton-BhFQfAX1.js → ProjectStartupButton-CWKSZVGw.js} +1 -1
- package/src/ui/public/assets/RecentDirectoriesChat-DINPN4ju.js +1 -0
- package/src/ui/public/assets/RecentDirectoriesChat-THkqWEtO.css +1 -0
- package/src/ui/public/assets/{RemoteManagerDialog-CIZagKkC.js → RemoteManagerDialog-BVwpcCAu.js} +1 -1
- package/src/ui/public/assets/{RemoteRepoCard-Dj-B-6WU.js → RemoteRepoCard-Dy3AF_XZ.js} +1 -1
- package/src/ui/public/assets/{SourceMapView-pIlmQzYw.js → SourceMapView-BnHeu5wE.js} +1 -1
- package/src/ui/public/assets/{SvgIcon-CaefOO1F.js → SvgIcon-DcVasCdo.js} +1 -1
- package/src/ui/public/assets/{UserInputNode-1--I25vm.js → UserInputNode-B313MadX.js} +1 -1
- package/src/ui/public/assets/WorkbenchView-0cY9WHPM.js +20 -0
- package/src/ui/public/assets/WorkbenchView-rscs76HF.css +1 -0
- package/src/ui/public/assets/{_plugin-vue_export-helper-UTW98kcD.js → _plugin-vue_export-helper-Bsx6Zj3t.js} +5 -5
- package/src/ui/public/assets/agentConversations-BnG4a1oH.js +8 -0
- package/src/ui/public/assets/{configStore-H-n3ukZ_.js → configStore-DQSKV2_Y.js} +1 -1
- package/src/ui/public/assets/{dagre-Br4Eexe7.js → dagre-BmYeUlEa.js} +3 -3
- package/src/ui/public/assets/{element-plus-CZdvD4lq.js → element-plus-DTtm3XCd.js} +1 -1
- package/src/ui/public/assets/{flow-mindmap-4kZ-2J2Y.js → flow-mindmap-JxOspgwx.js} +1 -1
- package/src/ui/public/assets/{index-CD7otmb_.js → index-BApctCNq.js} +7 -7
- package/src/ui/public/assets/{monaco-CoYCcK3Q.js → monaco-D3R9OM26.js} +1 -1
- package/src/ui/public/assets/{office-docx-DndLP6GO.js → office-docx-CO7mIaWO.js} +1 -1
- package/src/ui/public/assets/{office-excel-Jt5zzo6D.js → office-excel-gA4KEkK4.js} +1 -1
- package/src/ui/public/assets/{office-pptx-J8tzRTjU.js → office-pptx-CQK4l_1Q.js} +1 -1
- package/src/ui/public/assets/{vendor-BD09UDuP.js → vendor-O17eRefg.js} +497 -497
- package/src/ui/public/assets/vendor-U3ZXMgeO.css +1 -0
- package/src/ui/public/assets/{vue-flow-CkM05TWt.js → vue-flow-BG6ZF1It.js} +1 -1
- package/src/ui/public/index.html +12 -12
- package/src/ui/server/routes/workbench/agentMarketplace.js +65 -30
- package/src/ui/server/routes/workbench/agentMarketplace.test.js +28 -4
- package/src/ui/server/routes/workbench/liveJobs.js +4 -0
- package/src/ui/server/routes/workbench/liveJobs.test.js +11 -0
- package/src/ui/server/routes/workbench/taskRunner.js +44 -7
- package/src/ui/server/routes/workbench/taskRunner.thinking.test.js +115 -0
- package/src/ui/public/assets/AgentView-c1frCBc3.js +0 -1
- package/src/ui/public/assets/EditorView-DUJrWJgh.js +0 -1
- package/src/ui/public/assets/EditorView-DqagGedH.css +0 -1
- package/src/ui/public/assets/RecentDirectoriesChat-BxbpKrXc.css +0 -1
- package/src/ui/public/assets/RecentDirectoriesChat-DM6sRO9L.js +0 -1
- package/src/ui/public/assets/WorkbenchView-BLzcZqy0.css +0 -1
- package/src/ui/public/assets/WorkbenchView-bpzL6m84.js +0 -20
- package/src/ui/public/assets/agentConversations-B9LNft3v.js +0 -8
- package/src/ui/public/assets/vendor-DNiTBOIX.css +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/vendor-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/vendor-O17eRefg.js","assets/rolldown-runtime-C0FnF6B9.js","assets/element-plus-DTtm3XCd.js","assets/element-plus-D-6gla1z.css","assets/vendor-U3ZXMgeO.css"])))=>i.map(i=>d[i]);
|
|
2
2
|
import{i as e,o as t,r as n,t as r}from"./rolldown-runtime-C0FnF6B9.js";var i=typeof global==`object`&&global&&global.Object===Object&&global,a=typeof self==`object`&&self&&self.Object===Object&&self,o=i||a||Function(`return this`)(),s=o.Symbol,c=Object.prototype,l=c.hasOwnProperty,u=c.toString,d=s?s.toStringTag:void 0;function f(e){var t=l.call(e,d),n=e[d];try{e[d]=void 0;var r=!0}catch{}var i=u.call(e);return r&&(t?e[d]=n:delete e[d]),i}var p=Object.prototype.toString;function m(e){return p.call(e)}var h=`[object Null]`,g=`[object Undefined]`,_=s?s.toStringTag:void 0;function v(e){return e==null?e===void 0?g:h:_&&_ in Object(e)?f(e):m(e)}function y(e){return typeof e==`object`&&!!e}var b=`[object Symbol]`;function x(e){return typeof e==`symbol`||y(e)&&v(e)==b}function S(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var C=Array.isArray,w=1/0,T=s?s.prototype:void 0,E=T?T.toString:void 0;function D(e){if(typeof e==`string`)return e;if(C(e))return S(e,D)+``;if(x(e))return E?E.call(e):``;var t=e+``;return t==`0`&&1/e==-w?`-0`:t}var O=/\s/;function k(e){for(var t=e.length;t--&&O.test(e.charAt(t)););return t}var ee=/^\s+/;function te(e){return e&&e.slice(0,k(e)+1).replace(ee,``)}function ne(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}var re=NaN,ie=/^[-+]0x[0-9a-f]+$/i,ae=/^0b[01]+$/i,oe=/^0o[0-7]+$/i,se=parseInt;function ce(e){if(typeof e==`number`)return e;if(x(e))return re;if(ne(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=ne(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=te(e);var n=ae.test(e);return n||oe.test(e)?se(e.slice(2),n?2:8):ie.test(e)?re:+e}var le=1/0,A=17976931348623157e292;function ue(e){return e?(e=ce(e),e===le||e===-le?(e<0?-1:1)*A:e===e?e:0):e===0?e:0}function de(e){var t=ue(e),n=t%1;return t===t?n?t-n:t:0}function fe(e){return e}var pe=`[object AsyncFunction]`,me=`[object Function]`,he=`[object GeneratorFunction]`,ge=`[object Proxy]`;function _e(e){if(!ne(e))return!1;var t=v(e);return t==me||t==he||t==pe||t==ge}var ve=o[`__core-js_shared__`],ye=function(){var e=/[^.]+$/.exec(ve&&ve.keys&&ve.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function be(e){return!!ye&&ye in e}var xe=Function.prototype.toString;function j(e){if(e!=null){try{return xe.call(e)}catch{}try{return e+``}catch{}}return``}var Se=/[\\^$.*+?()[\]{}|]/g,Ce=/^\[object .+?Constructor\]$/,we=Function.prototype,Te=Object.prototype,Ee=we.toString,De=Te.hasOwnProperty,Oe=RegExp(`^`+Ee.call(De).replace(Se,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function ke(e){return!ne(e)||be(e)?!1:(_e(e)?Oe:Ce).test(j(e))}function Ae(e,t){return e?.[t]}function je(e,t){var n=Ae(e,t);return ke(n)?n:void 0}var Me=je(o,`WeakMap`),Ne=Object.create,Pe=function(){function e(){}return function(t){if(!ne(t))return{};if(Ne)return Ne(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Fe(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function Ie(){}function Le(e,t){var n=-1,r=e.length;for(t||=Array(r);++n<r;)t[n]=e[n];return t}var Re=800,ze=16,Be=Date.now;function Ve(e){var t=0,n=0;return function(){var r=Be(),i=ze-(r-n);if(n=r,i>0){if(++t>=Re)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function He(e){return function(){return e}}var Ue=function(){try{var e=je(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),We=Ve(Ue?function(e,t){return Ue(e,`toString`,{configurable:!0,enumerable:!1,value:He(t),writable:!0})}:fe);function Ge(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}function Ke(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}function qe(e){return e!==e}function Je(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function Ye(e,t,n){return t===t?Je(e,t,n):Ke(e,qe,n)}function Xe(e,t){return!!(e!=null&&e.length)&&Ye(e,t,0)>-1}var Ze=9007199254740991,Qe=/^(?:0|[1-9]\d*)$/;function $e(e,t){var n=typeof e;return t??=Ze,!!t&&(n==`number`||n!=`symbol`&&Qe.test(e))&&e>-1&&e%1==0&&e<t}function et(e,t,n){t==`__proto__`&&Ue?Ue(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function tt(e,t){return e===t||e!==e&&t!==t}var nt=Object.prototype.hasOwnProperty;function rt(e,t,n){var r=e[t];(!(nt.call(e,t)&&tt(r,n))||n===void 0&&!(t in e))&&et(e,t,n)}function it(e,t,n,r){var i=!n;n||={};for(var a=-1,o=t.length;++a<o;){var s=t[a],c=r?r(n[s],e[s],s,n,e):void 0;c===void 0&&(c=e[s]),i?et(n,s,c):rt(n,s,c)}return n}var at=Math.max;function ot(e,t,n){return t=at(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,a=at(r.length-t,0),o=Array(a);++i<a;)o[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(o),Fe(e,this,s)}}function st(e,t){return We(ot(e,t,fe),e+``)}var ct=9007199254740991;function lt(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=ct}function ut(e){return e!=null&<(e.length)&&!_e(e)}function dt(e,t,n){if(!ne(n))return!1;var r=typeof t;return(r==`number`?ut(n)&&$e(t,n.length):r==`string`&&t in n)?tt(n[t],e):!1}function ft(e){return st(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&dt(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var s=n[r];s&&e(t,s,r,a)}return t})}var pt=Object.prototype;function mt(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||pt)}function ht(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var gt=`[object Arguments]`;function _t(e){return y(e)&&v(e)==gt}var vt=Object.prototype,yt=vt.hasOwnProperty,bt=vt.propertyIsEnumerable,xt=_t(function(){return arguments}())?_t:function(e){return y(e)&&yt.call(e,`callee`)&&!bt.call(e,`callee`)};function St(){return!1}var Ct=typeof exports==`object`&&exports&&!exports.nodeType&&exports,wt=Ct&&typeof module==`object`&&module&&!module.nodeType&&module,Tt=wt&&wt.exports===Ct?o.Buffer:void 0,Et=(Tt?Tt.isBuffer:void 0)||St,Dt=`[object Arguments]`,Ot=`[object Array]`,kt=`[object Boolean]`,At=`[object Date]`,jt=`[object Error]`,Mt=`[object Function]`,Nt=`[object Map]`,Pt=`[object Number]`,Ft=`[object Object]`,It=`[object RegExp]`,Lt=`[object Set]`,Rt=`[object String]`,zt=`[object WeakMap]`,Bt=`[object ArrayBuffer]`,Vt=`[object DataView]`,Ht=`[object Float32Array]`,Ut=`[object Float64Array]`,Wt=`[object Int8Array]`,Gt=`[object Int16Array]`,Kt=`[object Int32Array]`,qt=`[object Uint8Array]`,Jt=`[object Uint8ClampedArray]`,Yt=`[object Uint16Array]`,Xt=`[object Uint32Array]`,Zt={};Zt[Ht]=Zt[Ut]=Zt[Wt]=Zt[Gt]=Zt[Kt]=Zt[qt]=Zt[Jt]=Zt[Yt]=Zt[Xt]=!0,Zt[Dt]=Zt[Ot]=Zt[Bt]=Zt[kt]=Zt[Vt]=Zt[At]=Zt[jt]=Zt[Mt]=Zt[Nt]=Zt[Pt]=Zt[Ft]=Zt[It]=Zt[Lt]=Zt[Rt]=Zt[zt]=!1;function Qt(e){return y(e)&<(e.length)&&!!Zt[v(e)]}function $t(e){return function(t){return e(t)}}var en=typeof exports==`object`&&exports&&!exports.nodeType&&exports,tn=en&&typeof module==`object`&&module&&!module.nodeType&&module,nn=tn&&tn.exports===en&&i.process,rn=function(){try{return tn&&tn.require&&tn.require(`util`).types||nn&&nn.binding&&nn.binding(`util`)}catch{}}(),an=rn&&rn.isTypedArray,on=an?$t(an):Qt,sn=Object.prototype.hasOwnProperty;function cn(e,t){var n=C(e),r=!n&&xt(e),i=!n&&!r&&Et(e),a=!n&&!r&&!i&&on(e),o=n||r||i||a,s=o?ht(e.length,String):[],c=s.length;for(var l in e)(t||sn.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||$e(l,c)))&&s.push(l);return s}function ln(e,t){return function(n){return e(t(n))}}var un=ln(Object.keys,Object),dn=Object.prototype.hasOwnProperty;function fn(e){if(!mt(e))return un(e);var t=[];for(var n in Object(e))dn.call(e,n)&&n!=`constructor`&&t.push(n);return t}function pn(e){return ut(e)?cn(e):fn(e)}function mn(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var hn=Object.prototype.hasOwnProperty;function gn(e){if(!ne(e))return mn(e);var t=mt(e),n=[];for(var r in e)(r!=`constructor`||!t&&hn.call(e,r))&&n.push(r);return n}function _n(e){return ut(e)?cn(e,!0):gn(e)}var vn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,yn=/^\w*$/;function bn(e,t){if(C(e))return!1;var n=typeof e;return n==`number`||n==`symbol`||n==`boolean`||e==null||x(e)?!0:yn.test(e)||!vn.test(e)||t!=null&&e in Object(t)}var xn=je(Object,`create`);function Sn(){this.__data__=xn?xn(null):{},this.size=0}function Cn(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}var wn=`__lodash_hash_undefined__`,Tn=Object.prototype.hasOwnProperty;function En(e){var t=this.__data__;if(xn){var n=t[e];return n===wn?void 0:n}return Tn.call(t,e)?t[e]:void 0}var Dn=Object.prototype.hasOwnProperty;function On(e){var t=this.__data__;return xn?t[e]!==void 0:Dn.call(t,e)}var kn=`__lodash_hash_undefined__`;function An(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=xn&&t===void 0?kn:t,this}function jn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}jn.prototype.clear=Sn,jn.prototype.delete=Cn,jn.prototype.get=En,jn.prototype.has=On,jn.prototype.set=An;function Mn(){this.__data__=[],this.size=0}function Nn(e,t){for(var n=e.length;n--;)if(tt(e[n][0],t))return n;return-1}var Pn=Array.prototype.splice;function Fn(e){var t=this.__data__,n=Nn(t,e);return n<0?!1:(n==t.length-1?t.pop():Pn.call(t,n,1),--this.size,!0)}function In(e){var t=this.__data__,n=Nn(t,e);return n<0?void 0:t[n][1]}function Ln(e){return Nn(this.__data__,e)>-1}function Rn(e,t){var n=this.__data__,r=Nn(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function zn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}zn.prototype.clear=Mn,zn.prototype.delete=Fn,zn.prototype.get=In,zn.prototype.has=Ln,zn.prototype.set=Rn;var Bn=je(o,`Map`);function Vn(){this.size=0,this.__data__={hash:new jn,map:new(Bn||zn),string:new jn}}function Hn(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}function Un(e,t){var n=e.__data__;return Hn(t)?n[typeof t==`string`?`string`:`hash`]:n.map}function Wn(e){var t=Un(this,e).delete(e);return this.size-=+!!t,t}function Gn(e){return Un(this,e).get(e)}function Kn(e){return Un(this,e).has(e)}function qn(e,t){var n=Un(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function Jn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Jn.prototype.clear=Vn,Jn.prototype.delete=Wn,Jn.prototype.get=Gn,Jn.prototype.has=Kn,Jn.prototype.set=qn;var Yn=`Expected a function`;function Xn(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(Yn);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(Xn.Cache||Jn),n}Xn.Cache=Jn;var Zn=500;function Qn(e){var t=Xn(e,function(e){return n.size===Zn&&n.clear(),e}),n=t.cache;return t}var $n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,er=/\\(\\)?/g,tr=Qn(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace($n,function(e,n,r,i){t.push(r?i.replace(er,`$1`):n||e)}),t});function nr(e){return e==null?``:D(e)}function rr(e,t){return C(e)?e:bn(e,t)?[e]:tr(nr(e))}var ir=1/0;function ar(e){if(typeof e==`string`||x(e))return e;var t=e+``;return t==`0`&&1/e==-ir?`-0`:t}function or(e,t){t=rr(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[ar(t[n++])];return n&&n==r?e:void 0}function sr(e,t,n){var r=e==null?void 0:or(e,t);return r===void 0?n:r}function cr(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var lr=s?s.isConcatSpreadable:void 0;function ur(e){return C(e)||xt(e)||!!(lr&&e&&e[lr])}function dr(e,t,n,r,i){var a=-1,o=e.length;for(n||=ur,i||=[];++a<o;){var s=e[a];t>0&&n(s)?t>1?dr(s,t-1,n,r,i):cr(i,s):r||(i[i.length]=s)}return i}function fr(e){return e!=null&&e.length?dr(e,1):[]}function pr(e){return We(ot(e,void 0,fr),e+``)}var mr=ln(Object.getPrototypeOf,Object),hr=`[object Object]`,gr=Function.prototype,_r=Object.prototype,vr=gr.toString,yr=_r.hasOwnProperty,br=vr.call(Object);function xr(e){if(!y(e)||v(e)!=hr)return!1;var t=mr(e);if(t===null)return!0;var n=yr.call(t,`constructor`)&&t.constructor;return typeof n==`function`&&n instanceof n&&vr.call(n)==br}var Sr=RegExp(`[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]`);function Cr(e){return Sr.test(e)}function wr(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}function Tr(){this.__data__=new zn,this.size=0}function Er(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function Dr(e){return this.__data__.get(e)}function Or(e){return this.__data__.has(e)}var kr=200;function Ar(e,t){var n=this.__data__;if(n instanceof zn){var r=n.__data__;if(!Bn||r.length<kr-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new Jn(r)}return n.set(e,t),this.size=n.size,this}function jr(e){var t=this.__data__=new zn(e);this.size=t.size}jr.prototype.clear=Tr,jr.prototype.delete=Er,jr.prototype.get=Dr,jr.prototype.has=Or,jr.prototype.set=Ar;function Mr(e,t){return e&&it(t,pn(t),e)}function Nr(e,t){return e&&it(t,_n(t),e)}var Pr=typeof exports==`object`&&exports&&!exports.nodeType&&exports,Fr=Pr&&typeof module==`object`&&module&&!module.nodeType&&module,Ir=Fr&&Fr.exports===Pr?o.Buffer:void 0,Lr=Ir?Ir.allocUnsafe:void 0;function Rr(e,t){if(t)return e.slice();var n=e.length,r=Lr?Lr(n):new e.constructor(n);return e.copy(r),r}function zr(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}function Br(){return[]}var Vr=Object.prototype.propertyIsEnumerable,Hr=Object.getOwnPropertySymbols,Ur=Hr?function(e){return e==null?[]:(e=Object(e),zr(Hr(e),function(t){return Vr.call(e,t)}))}:Br;function Wr(e,t){return it(e,Ur(e),t)}var Gr=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)cr(t,Ur(e)),e=mr(e);return t}:Br;function Kr(e,t){return it(e,Gr(e),t)}function qr(e,t,n){var r=t(e);return C(e)?r:cr(r,n(e))}function Jr(e){return qr(e,pn,Ur)}function Yr(e){return qr(e,_n,Gr)}var Xr=je(o,`DataView`),Zr=je(o,`Promise`),Qr=je(o,`Set`),$r=`[object Map]`,ei=`[object Object]`,ti=`[object Promise]`,ni=`[object Set]`,ri=`[object WeakMap]`,ii=`[object DataView]`,ai=j(Xr),oi=j(Bn),si=j(Zr),ci=j(Qr),li=j(Me),ui=v;(Xr&&ui(new Xr(new ArrayBuffer(1)))!=ii||Bn&&ui(new Bn)!=$r||Zr&&ui(Zr.resolve())!=ti||Qr&&ui(new Qr)!=ni||Me&&ui(new Me)!=ri)&&(ui=function(e){var t=v(e),n=t==ei?e.constructor:void 0,r=n?j(n):``;if(r)switch(r){case ai:return ii;case oi:return $r;case si:return ti;case ci:return ni;case li:return ri}return t});var di=ui,fi=Object.prototype.hasOwnProperty;function pi(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]==`string`&&fi.call(e,`index`)&&(n.index=e.index,n.input=e.input),n}var mi=o.Uint8Array;function hi(e){var t=new e.constructor(e.byteLength);return new mi(t).set(new mi(e)),t}function gi(e,t){var n=t?hi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var _i=/\w*$/;function vi(e){var t=new e.constructor(e.source,_i.exec(e));return t.lastIndex=e.lastIndex,t}var yi=s?s.prototype:void 0,bi=yi?yi.valueOf:void 0;function xi(e){return bi?Object(bi.call(e)):{}}function Si(e,t){var n=t?hi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var Ci=`[object Boolean]`,wi=`[object Date]`,Ti=`[object Map]`,Ei=`[object Number]`,Di=`[object RegExp]`,Oi=`[object Set]`,ki=`[object String]`,Ai=`[object Symbol]`,ji=`[object ArrayBuffer]`,Mi=`[object DataView]`,Ni=`[object Float32Array]`,Pi=`[object Float64Array]`,Fi=`[object Int8Array]`,Ii=`[object Int16Array]`,Li=`[object Int32Array]`,Ri=`[object Uint8Array]`,zi=`[object Uint8ClampedArray]`,Bi=`[object Uint16Array]`,Vi=`[object Uint32Array]`;function Hi(e,t,n){var r=e.constructor;switch(t){case ji:return hi(e);case Ci:case wi:return new r(+e);case Mi:return gi(e,n);case Ni:case Pi:case Fi:case Ii:case Li:case Ri:case zi:case Bi:case Vi:return Si(e,n);case Ti:return new r;case Ei:case ki:return new r(e);case Di:return vi(e);case Oi:return new r;case Ai:return xi(e)}}function Ui(e){return typeof e.constructor==`function`&&!mt(e)?Pe(mr(e)):{}}var Wi=`[object Map]`;function Gi(e){return y(e)&&di(e)==Wi}var Ki=rn&&rn.isMap,qi=Ki?$t(Ki):Gi,Ji=`[object Set]`;function Yi(e){return y(e)&&di(e)==Ji}var Xi=rn&&rn.isSet,Zi=Xi?$t(Xi):Yi,Qi=1,$i=2,ea=4,ta=`[object Arguments]`,na=`[object Array]`,ra=`[object Boolean]`,ia=`[object Date]`,aa=`[object Error]`,oa=`[object Function]`,sa=`[object GeneratorFunction]`,ca=`[object Map]`,la=`[object Number]`,ua=`[object Object]`,da=`[object RegExp]`,fa=`[object Set]`,pa=`[object String]`,ma=`[object Symbol]`,ha=`[object WeakMap]`,ga=`[object ArrayBuffer]`,_a=`[object DataView]`,va=`[object Float32Array]`,ya=`[object Float64Array]`,ba=`[object Int8Array]`,xa=`[object Int16Array]`,Sa=`[object Int32Array]`,Ca=`[object Uint8Array]`,wa=`[object Uint8ClampedArray]`,Ta=`[object Uint16Array]`,Ea=`[object Uint32Array]`,Da={};Da[ta]=Da[na]=Da[ga]=Da[_a]=Da[ra]=Da[ia]=Da[va]=Da[ya]=Da[ba]=Da[xa]=Da[Sa]=Da[ca]=Da[la]=Da[ua]=Da[da]=Da[fa]=Da[pa]=Da[ma]=Da[Ca]=Da[wa]=Da[Ta]=Da[Ea]=!0,Da[aa]=Da[oa]=Da[ha]=!1;function Oa(e,t,n,r,i,a){var o,s=t&Qi,c=t&$i,l=t&ea;if(n&&(o=i?n(e,r,i,a):n(e)),o!==void 0)return o;if(!ne(e))return e;var u=C(e);if(u){if(o=pi(e),!s)return Le(e,o)}else{var d=di(e),f=d==oa||d==sa;if(Et(e))return Rr(e,s);if(d==ua||d==ta||f&&!i){if(o=c||f?{}:Ui(e),!s)return c?Kr(e,Nr(o,e)):Wr(e,Mr(o,e))}else{if(!Da[d])return i?e:{};o=Hi(e,d,s)}}a||=new jr;var p=a.get(e);if(p)return p;a.set(e,o),Zi(e)?e.forEach(function(r){o.add(Oa(r,t,n,r,e,a))}):qi(e)&&e.forEach(function(r,i){o.set(i,Oa(r,t,n,i,e,a))});var m=u?void 0:(l?c?Yr:Jr:c?_n:pn)(e);return Ge(m||e,function(r,i){m&&(i=r,r=e[i]),rt(o,i,Oa(r,t,n,i,e,a))}),o}var ka=1,Aa=4;function ja(e){return Oa(e,ka|Aa)}var Ma=`__lodash_hash_undefined__`;function Na(e){return this.__data__.set(e,Ma),this}function Pa(e){return this.__data__.has(e)}function Fa(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new Jn;++t<n;)this.add(e[t])}Fa.prototype.add=Fa.prototype.push=Na,Fa.prototype.has=Pa;function Ia(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function La(e,t){return e.has(t)}var Ra=1,za=2;function Ba(e,t,n,r,i,a){var o=n&Ra,s=e.length,c=t.length;if(s!=c&&!(o&&c>s))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&za?new Fa:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],h=t[d];if(r)var g=o?r(h,m,d,t,e,a):r(m,h,d,e,t,a);if(g!==void 0){if(g)continue;f=!1;break}if(p){if(!Ia(t,function(e,t){if(!La(p,t)&&(m===e||i(m,e,n,r,a)))return p.push(t)})){f=!1;break}}else if(!(m===h||i(m,h,n,r,a))){f=!1;break}}return a.delete(e),a.delete(t),f}function Va(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function Ha(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var Ua=1,Wa=2,Ga=`[object Boolean]`,Ka=`[object Date]`,qa=`[object Error]`,Ja=`[object Map]`,Ya=`[object Number]`,Xa=`[object RegExp]`,Za=`[object Set]`,Qa=`[object String]`,$a=`[object Symbol]`,eo=`[object ArrayBuffer]`,to=`[object DataView]`,no=s?s.prototype:void 0,ro=no?no.valueOf:void 0;function io(e,t,n,r,i,a,o){switch(n){case to:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case eo:return!(e.byteLength!=t.byteLength||!a(new mi(e),new mi(t)));case Ga:case Ka:case Ya:return tt(+e,+t);case qa:return e.name==t.name&&e.message==t.message;case Xa:case Qa:return e==t+``;case Ja:var s=Va;case Za:var c=r&Ua;if(s||=Ha,e.size!=t.size&&!c)return!1;var l=o.get(e);if(l)return l==t;r|=Wa,o.set(e,t);var u=Ba(s(e),s(t),r,i,a,o);return o.delete(e),u;case $a:if(ro)return ro.call(e)==ro.call(t)}return!1}var ao=1,oo=Object.prototype.hasOwnProperty;function so(e,t,n,r,i,a){var o=n&ao,s=Jr(e),c=s.length;if(c!=Jr(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:oo.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++l<c;){u=s[l];var h=e[u],g=t[u];if(r)var _=o?r(g,h,u,t,e,a):r(h,g,u,e,t,a);if(!(_===void 0?h===g||i(h,g,n,r,a):_)){p=!1;break}m||=u==`constructor`}if(p&&!m){var v=e.constructor,y=t.constructor;v!=y&&`constructor`in e&&`constructor`in t&&!(typeof v==`function`&&v instanceof v&&typeof y==`function`&&y instanceof y)&&(p=!1)}return a.delete(e),a.delete(t),p}var co=1,lo=`[object Arguments]`,uo=`[object Array]`,fo=`[object Object]`,po=Object.prototype.hasOwnProperty;function mo(e,t,n,r,i,a){var o=C(e),s=C(t),c=o?uo:di(e),l=s?uo:di(t);c=c==lo?fo:c,l=l==lo?fo:l;var u=c==fo,d=l==fo,f=c==l;if(f&&Et(e)){if(!Et(t))return!1;o=!0,u=!1}if(f&&!u)return a||=new jr,o||on(e)?Ba(e,t,n,r,i,a):io(e,t,c,n,r,i,a);if(!(n&co)){var p=u&&po.call(e,`__wrapped__`),m=d&&po.call(t,`__wrapped__`);if(p||m){var h=p?e.value():e,g=m?t.value():t;return a||=new jr,i(h,g,n,r,a)}}return f?(a||=new jr,so(e,t,n,r,i,a)):!1}function ho(e,t,n,r,i){return e===t?!0:e==null||t==null||!y(e)&&!y(t)?e!==e&&t!==t:mo(e,t,n,r,ho,i)}var go=1,_o=2;function vo(e,t,n,r){var i=n.length,a=i,o=!r;if(e==null)return!a;for(e=Object(e);i--;){var s=n[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=n[i];var c=s[0],l=e[c],u=s[1];if(o&&s[2]){if(l===void 0&&!(c in e))return!1}else{var d=new jr;if(r)var f=r(l,u,c,e,t,d);if(!(f===void 0?ho(u,l,go|_o,r,d):f))return!1}}return!0}function yo(e){return e===e&&!ne(e)}function bo(e){for(var t=pn(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,yo(i)]}return t}function xo(e,t){return function(n){return n!=null&&n[e]===t&&(t!==void 0||e in Object(n))}}function So(e){var t=bo(e);return t.length==1&&t[0][2]?xo(t[0][0],t[0][1]):function(n){return n===e||vo(n,e,t)}}function Co(e,t){return e!=null&&t in Object(e)}function wo(e,t,n){t=rr(t,e);for(var r=-1,i=t.length,a=!1;++r<i;){var o=ar(t[r]);if(!(a=e!=null&&n(e,o)))break;e=e[o]}return a||++r!=i?a:(i=e==null?0:e.length,!!i&<(i)&&$e(o,i)&&(C(e)||xt(e)))}function To(e,t){return e!=null&&wo(e,t,Co)}var Eo=1,Do=2;function Oo(e,t){return bn(e)&&yo(t)?xo(ar(e),t):function(n){var r=sr(n,e);return r===void 0&&r===t?To(n,e):ho(t,r,Eo|Do)}}function ko(e){return function(t){return t?.[e]}}function Ao(e){return function(t){return or(t,e)}}function jo(e){return bn(e)?ko(ar(e)):Ao(e)}function Mo(e){return typeof e==`function`?e:e==null?fe:typeof e==`object`?C(e)?Oo(e[0],e[1]):So(e):jo(e)}function No(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}var Po=No();function Fo(e,t){return e&&Po(e,t,pn)}function Io(e,t){return function(n,r){if(n==null)return n;if(!ut(n))return e(n,r);for(var i=n.length,a=t?i:-1,o=Object(n);(t?a--:++a<i)&&r(o[a],a,o)!==!1;);return n}}var Lo=Io(Fo),Ro=function(){return o.Date.now()},zo=Object.prototype,Bo=zo.hasOwnProperty,Vo=st(function(e,t){e=Object(e);var n=-1,r=t.length,i=r>2?t[2]:void 0;for(i&&dt(t[0],t[1],i)&&(r=1);++n<r;)for(var a=t[n],o=_n(a),s=-1,c=o.length;++s<c;){var l=o[s],u=e[l];(u===void 0||tt(u,zo[l])&&!Bo.call(e,l))&&(e[l]=a[l])}return e});function Ho(e,t,n){(n!==void 0&&!tt(e[t],n)||n===void 0&&!(t in e))&&et(e,t,n)}function Uo(e){return y(e)&&ut(e)}function Wo(e,t){if((t!==`constructor`||typeof e[t]!=`function`)&&t!=`__proto__`)return e[t]}function Go(e){return it(e,_n(e))}function Ko(e,t,n,r,i,a,o){var s=Wo(e,n),c=Wo(t,n),l=o.get(c);if(l){Ho(e,n,l);return}var u=a?a(s,c,n+``,e,t,o):void 0,d=u===void 0;if(d){var f=C(c),p=!f&&Et(c),m=!f&&!p&&on(c);u=c,f||p||m?C(s)?u=s:Uo(s)?u=Le(s):p?(d=!1,u=Rr(c,!0)):m?(d=!1,u=Si(c,!0)):u=[]:xr(c)||xt(c)?(u=s,xt(s)?u=Go(s):(!ne(s)||_e(s))&&(u=Ui(c))):d=!1}d&&(o.set(c,u),i(u,c,r,a,o),o.delete(c)),Ho(e,n,u)}function qo(e,t,n,r,i){e!==t&&Po(t,function(a,o){if(i||=new jr,ne(a))Ko(e,t,o,n,qo,r,i);else{var s=r?r(Wo(e,o),a,o+``,e,t,i):void 0;s===void 0&&(s=a),Ho(e,o,s)}},_n)}function Jo(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function Yo(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}function Xo(e){return typeof e==`function`?e:fe}function M(e,t){return(C(e)?Ge:Lo)(e,Xo(t))}function Zo(e,t){var n=[];return Lo(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}function Qo(e,t){return(C(e)?zr:Zo)(e,Mo(t,3))}function $o(e){return function(t,n,r){var i=Object(t);if(!ut(t)){var a=Mo(n,3);t=pn(t),n=function(e){return a(i[e],e,i)}}var o=e(t,n,r);return o>-1?i[a?t[o]:o]:void 0}}var es=Math.max;function ts(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:de(n);return i<0&&(i=es(r+i,0)),Ke(e,Mo(t,3),i)}var ns=$o(ts);function rs(e,t){var n=-1,r=ut(e)?Array(e.length):[];return Lo(e,function(e,i,a){r[++n]=t(e,i,a)}),r}function is(e,t){return(C(e)?S:rs)(e,Mo(t,3))}function as(e,t){return e==null?e:Po(e,Xo(t),_n)}function os(e,t){return e&&Fo(e,Xo(t))}function ss(e,t){return e>t}var cs=Object.prototype.hasOwnProperty;function ls(e,t){return e!=null&&cs.call(e,t)}function us(e,t){return e!=null&&wo(e,t,ls)}var ds=`[object String]`;function fs(e){return typeof e==`string`||!C(e)&&y(e)&&v(e)==ds}function ps(e,t){return S(t,function(t){return e[t]})}function ms(e){return e==null?[]:ps(e,pn(e))}var hs=`[object Map]`,gs=`[object Set]`,_s=Object.prototype.hasOwnProperty;function vs(e){if(e==null)return!0;if(ut(e)&&(C(e)||typeof e==`string`||typeof e.splice==`function`||Et(e)||on(e)||xt(e)))return!e.length;var t=di(e);if(t==hs||t==gs)return!e.size;if(mt(e))return!fn(e).length;for(var n in e)if(_s.call(e,n))return!1;return!0}function ys(e){return e===void 0}function bs(e,t){return e<t}function xs(e,t){var n={};return t=Mo(t,3),Fo(e,function(e,r,i){et(n,r,t(e,r,i))}),n}function Ss(e,t,n){for(var r=-1,i=e.length;++r<i;){var a=e[r],o=t(a);if(o!=null&&(s===void 0?o===o&&!x(o):n(o,s)))var s=o,c=a}return c}function Cs(e){return e&&e.length?Ss(e,fe,ss):void 0}var ws=ft(function(e,t,n){qo(e,t,n)});function Ts(e){return e&&e.length?Ss(e,fe,bs):void 0}function Es(e,t){return e&&e.length?Ss(e,Mo(t,2),bs):void 0}function Ds(e,t,n,r){if(!ne(e))return e;t=rr(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i<a;){var c=ar(t[i]),l=n;if(c===`__proto__`||c===`constructor`||c===`prototype`)return e;if(i!=o){var u=s[c];l=r?r(u,c,s):void 0,l===void 0&&(l=ne(u)?u:$e(t[i+1])?[]:{})}rt(s,c,l),s=s[c]}return e}function Os(e,t,n){for(var r=-1,i=t.length,a={};++r<i;){var o=t[r],s=or(e,o);n(s,o)&&Ds(a,rr(o,e),s)}return a}function ks(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}function As(e,t){if(e!==t){var n=e!==void 0,r=e===null,i=e===e,a=x(e),o=t!==void 0,s=t===null,c=t===t,l=x(t);if(!s&&!l&&!a&&e>t||a&&o&&c&&!s&&!l||r&&o&&c||!n&&c||!i)return 1;if(!r&&!a&&!l&&e<t||l&&n&&i&&!r&&!a||s&&n&&i||!o&&i||!c)return-1}return 0}function js(e,t,n){for(var r=-1,i=e.criteria,a=t.criteria,o=i.length,s=n.length;++r<o;){var c=As(i[r],a[r]);if(c)return r>=s?c:c*(n[r]==`desc`?-1:1)}return e.index-t.index}function Ms(e,t,n){t=t.length?S(t,function(e){return C(e)?function(t){return or(t,e.length===1?e[0]:e)}:e}):[fe];var r=-1;return t=S(t,$t(Mo)),ks(rs(e,function(e,n,i){return{criteria:S(t,function(t){return t(e)}),index:++r,value:e}}),function(e,t){return js(e,t,n)})}var Ns=ko(`length`),Ps=`\\ud800-\\udfff`,Fs=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,Is=`\\ufe0e\\ufe0f`,Ls=`[`+Ps+`]`,Rs=`[`+Fs+`]`,zs=`\\ud83c[\\udffb-\\udfff]`,Bs=`(?:`+Rs+`|`+zs+`)`,Vs=`[^`+Ps+`]`,Hs=`(?:\\ud83c[\\udde6-\\uddff]){2}`,Us=`[\\ud800-\\udbff][\\udc00-\\udfff]`,Ws=`\\u200d`,Gs=Bs+`?`,Ks=`[`+Is+`]?`,qs=`(?:`+Ws+`(?:`+[Vs,Hs,Us].join(`|`)+`)`+Ks+Gs+`)*`,Js=Ks+Gs+qs,Ys=`(?:`+[Vs+Rs+`?`,Rs,Hs,Us,Ls].join(`|`)+`)`,Xs=RegExp(zs+`(?=`+zs+`)|`+Ys+Js,`g`);function Zs(e){for(var t=Xs.lastIndex=0;Xs.test(e);)++t;return t}function Qs(e){return Cr(e)?Zs(e):Ns(e)}function $s(e,t){return Os(e,t,function(t,n){return To(e,n)})}var ec=pr(function(e,t){return e==null?{}:$s(e,t)}),tc=Math.ceil,nc=Math.max;function rc(e,t,n,r){for(var i=-1,a=nc(tc((t-e)/(n||1)),0),o=Array(a);a--;)o[r?a:++i]=e,e+=n;return o}function ic(e){return function(t,n,r){return r&&typeof r!=`number`&&dt(t,n,r)&&(n=r=void 0),t=ue(t),n===void 0?(n=t,t=0):n=ue(n),r=r===void 0?t<n?1:-1:ue(r),rc(t,n,r,e)}}var ac=ic();function oc(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}function sc(e,t,n){var r=C(e)?wr:oc,i=arguments.length<3;return r(e,Mo(t,4),n,i,Lo)}var cc=`[object Map]`,lc=`[object Set]`;function uc(e){if(e==null)return 0;if(ut(e))return fs(e)?Qs(e):e.length;var t=di(e);return t==cc||t==lc?e.size:fn(e).length}var dc=st(function(e,t){if(e==null)return[];var n=t.length;return n>1&&dt(e,t[0],t[1])?t=[]:n>2&&dt(t[0],t[1],t[2])&&(t=[t[0]]),Ms(e,dr(t,1),[])}),fc=Qr&&1/Ha(new Qr([,-0]))[1]==1/0?function(e){return new Qr(e)}:Ie,pc=200;function mc(e,t,n){var r=-1,i=Xe,a=e.length,o=!0,s=[],c=s;if(n)o=!1,i=Jo;else if(a>=pc){var l=t?null:fc(e);if(l)return Ha(l);o=!1,i=La,c=new Fa}else c=t?[]:s;outer:for(;++r<a;){var u=e[r],d=t?t(u):u;if(u=n||u!==0?u:0,o&&d===d){for(var f=c.length;f--;)if(c[f]===d)continue outer;t&&c.push(d),s.push(u)}else i(c,d,n)||(c!==s&&c.push(d),s.push(u))}return s}var hc=st(function(e){return mc(dr(e,1,Uo,!0))}),gc=0;function _c(e){var t=++gc;return nr(e)+t}function vc(e,t,n){for(var r=-1,i=e.length,a=t.length,o={};++r<i;){var s=r<a?t[r]:void 0;n(o,e[r],s)}return o}function yc(e,t){return vc(e||[],t||[],rt)}var bc=r(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs=r()})(e,(function(){var e=1e3,t=6e4,n=36e5,r=`millisecond`,i=`second`,a=`minute`,o=`hour`,s=`day`,c=`week`,l=`month`,u=`quarter`,d=`year`,f=`date`,p=`Invalid Date`,m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:`en`,weekdays:`Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday`.split(`_`),months:`January_February_March_April_May_June_July_August_September_October_November_December`.split(`_`),ordinal:function(e){var t=[`th`,`st`,`nd`,`rd`],n=e%100;return`[`+e+(t[(n-20)%10]||t[n]||t[0])+`]`}},_=function(e,t,n){var r=String(e);return!r||r.length>=t?e:``+Array(t+1-r.length).join(n)+e},v={s:_,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),i=n%60;return(t<=0?`+`:`-`)+_(r,2,`0`)+`:`+_(i,2,`0`)},m:function e(t,n){if(t.date()<n.date())return-e(n,t);var r=12*(n.year()-t.year())+(n.month()-t.month()),i=t.clone().add(r,l),a=n-i<0,o=t.clone().add(r+(a?-1:1),l);return+(-(r+(n-i)/(a?i-o:o-i))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:l,y:d,w:c,d:s,D:f,h:o,m:a,s:i,ms:r,Q:u}[e]||String(e||``).toLowerCase().replace(/s$/,``)},u:function(e){return e===void 0}},y=`en`,b={};b[y]=g;var x=`$isDayjsObject`,S=function(e){return e instanceof E||!(!e||!e[x])},C=function e(t,n,r){var i;if(!t)return y;if(typeof t==`string`){var a=t.toLowerCase();b[a]&&(i=a),n&&(b[a]=n,i=a);var o=t.split(`-`);if(!i&&o.length>1)return e(o[0])}else{var s=t.name;b[s]=t,i=s}return!r&&i&&(y=i),i||!r&&y},w=function(e,t){if(S(e))return e.clone();var n=typeof t==`object`?t:{};return n.date=e,n.args=arguments,new E(n)},T=v;T.l=C,T.i=S,T.w=function(e,t){return w(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var E=function(){function g(e){this.$L=C(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[x]=!0}var _=g.prototype;return _.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(t===null)return new Date(NaN);if(T.u(t))return new Date;if(t instanceof Date)return new Date(t);if(typeof t==`string`&&!/Z$/i.test(t)){var r=t.match(m);if(r){var i=r[2]-1||0,a=(r[7]||`0`).substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(t)}(e),this.init()},_.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},_.$utils=function(){return T},_.isValid=function(){return this.$d.toString()!==p},_.isSame=function(e,t){var n=w(e);return this.startOf(t)<=n&&n<=this.endOf(t)},_.isAfter=function(e,t){return w(e)<this.startOf(t)},_.isBefore=function(e,t){return this.endOf(t)<w(e)},_.$g=function(e,t,n){return T.u(e)?this[t]:this.set(n,e)},_.unix=function(){return Math.floor(this.valueOf()/1e3)},_.valueOf=function(){return this.$d.getTime()},_.startOf=function(e,t){var n=this,r=!!T.u(t)||t,u=T.p(e),p=function(e,t){var i=T.w(n.$u?Date.UTC(n.$y,t,e):new Date(n.$y,t,e),n);return r?i:i.endOf(s)},m=function(e,t){return T.w(n.toDate()[e].apply(n.toDate(`s`),(r?[0,0,0,0]:[23,59,59,999]).slice(t)),n)},h=this.$W,g=this.$M,_=this.$D,v=`set`+(this.$u?`UTC`:``);switch(u){case d:return r?p(1,0):p(31,11);case l:return r?p(1,g):p(0,g+1);case c:var y=this.$locale().weekStart||0,b=(h<y?h+7:h)-y;return p(r?_-b:_+(6-b),g);case s:case f:return m(v+`Hours`,0);case o:return m(v+`Minutes`,1);case a:return m(v+`Seconds`,2);case i:return m(v+`Milliseconds`,3);default:return this.clone()}},_.endOf=function(e){return this.startOf(e,!1)},_.$set=function(e,t){var n,c=T.p(e),u=`set`+(this.$u?`UTC`:``),p=(n={},n[s]=u+`Date`,n[f]=u+`Date`,n[l]=u+`Month`,n[d]=u+`FullYear`,n[o]=u+`Hours`,n[a]=u+`Minutes`,n[i]=u+`Seconds`,n[r]=u+`Milliseconds`,n)[c],m=c===s?this.$D+(t-this.$W):t;if(c===l||c===d){var h=this.clone().set(f,1);h.$d[p](m),h.init(),this.$d=h.set(f,Math.min(this.$D,h.daysInMonth())).$d}else p&&this.$d[p](m);return this.init(),this},_.set=function(e,t){return this.clone().$set(e,t)},_.get=function(e){return this[T.p(e)]()},_.add=function(r,u){var f,p=this;r=Number(r);var m=T.p(u),h=function(e){var t=w(p);return T.w(t.date(t.date()+Math.round(e*r)),p)};if(m===l)return this.set(l,this.$M+r);if(m===d)return this.set(d,this.$y+r);if(m===s)return h(1);if(m===c)return h(7);var g=(f={},f[a]=t,f[o]=n,f[i]=e,f)[m]||1,_=this.$d.getTime()+r*g;return T.w(_,this)},_.subtract=function(e,t){return this.add(-1*e,t)},_.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return n.invalidDate||p;var r=e||`YYYY-MM-DDTHH:mm:ssZ`,i=T.z(this),a=this.$H,o=this.$m,s=this.$M,c=n.weekdays,l=n.months,u=n.meridiem,d=function(e,n,i,a){return e&&(e[n]||e(t,r))||i[n].slice(0,a)},f=function(e){return T.s(a%12||12,e,`0`)},m=u||function(e,t,n){var r=e<12?`AM`:`PM`;return n?r.toLowerCase():r};return r.replace(h,(function(e,r){return r||function(e){switch(e){case`YY`:return String(t.$y).slice(-2);case`YYYY`:return T.s(t.$y,4,`0`);case`M`:return s+1;case`MM`:return T.s(s+1,2,`0`);case`MMM`:return d(n.monthsShort,s,l,3);case`MMMM`:return d(l,s);case`D`:return t.$D;case`DD`:return T.s(t.$D,2,`0`);case`d`:return String(t.$W);case`dd`:return d(n.weekdaysMin,t.$W,c,2);case`ddd`:return d(n.weekdaysShort,t.$W,c,3);case`dddd`:return c[t.$W];case`H`:return String(a);case`HH`:return T.s(a,2,`0`);case`h`:return f(1);case`hh`:return f(2);case`a`:return m(a,o,!0);case`A`:return m(a,o,!1);case`m`:return String(o);case`mm`:return T.s(o,2,`0`);case`s`:return String(t.$s);case`ss`:return T.s(t.$s,2,`0`);case`SSS`:return T.s(t.$ms,3,`0`);case`Z`:return i}return null}(e)||i.replace(`:`,``)}))},_.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},_.diff=function(r,f,p){var m,h=this,g=T.p(f),_=w(r),v=(_.utcOffset()-this.utcOffset())*t,y=this-_,b=function(){return T.m(h,_)};switch(g){case d:m=b()/12;break;case l:m=b();break;case u:m=b()/3;break;case c:m=(y-v)/6048e5;break;case s:m=(y-v)/864e5;break;case o:m=y/n;break;case a:m=y/t;break;case i:m=y/e;break;default:m=y}return p?m:T.a(m)},_.daysInMonth=function(){return this.endOf(l).$D},_.$locale=function(){return b[this.$L]},_.locale=function(e,t){if(!e)return this.$L;var n=this.clone(),r=C(e,t,!0);return r&&(n.$L=r),n},_.clone=function(){return T.w(this.$d,this)},_.toDate=function(){return new Date(this.valueOf())},_.toJSON=function(){return this.isValid()?this.toISOString():null},_.toISOString=function(){return this.$d.toISOString()},_.toString=function(){return this.$d.toUTCString()},g}(),D=E.prototype;return w.prototype=D,[[`$ms`,r],[`$s`,i],[`$m`,a],[`$H`,o],[`$W`,s],[`$M`,l],[`$y`,d],[`$D`,f]].forEach((function(e){D[e[1]]=function(t){return this.$g(t,e[0],e[1])}})),w.extend=function(e,t){return e.$i||=(e(t,E,w),!0),w},w.locale=C,w.isDayjs=S,w.unix=function(e){return w(1e3*e)},w.en=b[y],w.Ls=b,w.p={},w}))})),xc=t(bc(),1),Sc=`modulepreload`,Cc=function(e){return`/`+e},wc={},Tc=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?import.meta.resolve(e):new URL(e,import.meta.url).href}r=o(t.map(t=>{if(t=Cc(t,n),t=s(t),t in wc)return;wc[t]=!0;let r=t.endsWith(`.css`);for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}let i=document.createElement(`link`);if(i.rel=r?`stylesheet`:Sc,r||(i.as=`script`),i.crossOrigin=``,i.href=t,a&&i.setAttribute(`nonce`,a),document.head.appendChild(i),r)return new Promise((e,n)=>{i.addEventListener(`load`,e),i.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},Ec=Object.defineProperty,N=(e,t)=>Ec(e,`name`,{value:t,configurable:!0}),Dc=(e,t)=>{for(var n in t)Ec(e,n,{get:t[n],enumerable:!0})},Oc={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},P={trace:N((...e)=>{},`trace`),debug:N((...e)=>{},`debug`),info:N((...e)=>{},`info`),warn:N((...e)=>{},`warn`),error:N((...e)=>{},`error`),fatal:N((...e)=>{},`fatal`)},kc=N(function(e=`fatal`){let t=Oc.fatal;typeof e==`string`?e.toLowerCase()in Oc&&(t=Oc[e]):typeof e==`number`&&(t=e),P.trace=()=>{},P.debug=()=>{},P.info=()=>{},P.warn=()=>{},P.error=()=>{},P.fatal=()=>{},t<=Oc.fatal&&(P.fatal=console.error?console.error.bind(console,Ac(`FATAL`),`color: orange`):console.log.bind(console,`\x1B[35m`,Ac(`FATAL`))),t<=Oc.error&&(P.error=console.error?console.error.bind(console,Ac(`ERROR`),`color: orange`):console.log.bind(console,`\x1B[31m`,Ac(`ERROR`))),t<=Oc.warn&&(P.warn=console.warn?console.warn.bind(console,Ac(`WARN`),`color: orange`):console.log.bind(console,`\x1B[33m`,Ac(`WARN`))),t<=Oc.info&&(P.info=console.info?console.info.bind(console,Ac(`INFO`),`color: lightblue`):console.log.bind(console,`\x1B[34m`,Ac(`INFO`))),t<=Oc.debug&&(P.debug=console.debug?console.debug.bind(console,Ac(`DEBUG`),`color: lightgreen`):console.log.bind(console,`\x1B[32m`,Ac(`DEBUG`))),t<=Oc.trace&&(P.trace=console.debug?console.debug.bind(console,Ac(`TRACE`),`color: lightgreen`):console.log.bind(console,`\x1B[32m`,Ac(`TRACE`)))},`setLogLevel`),Ac=N(e=>`%c${(0,xc.default)().format(`ss.SSS`)} : ${e} : `,`format`),jc={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:e=>e>=255?255:e<0?0:e,g:e=>e>=255?255:e<0?0:e,b:e=>e>=255?255:e<0?0:e,h:e=>e%360,s:e=>e>=100?100:e<0?0:e,l:e=>e>=100?100:e<0?0:e,a:e=>e>=1?1:e<0?0:e},toLinear:e=>{let t=e/255;return e>.03928?((t+.055)/1.055)**2.4:t/12.92},hue2rgb:(e,t,n)=>(n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e),hsl2rgb:({h:e,s:t,l:n},r)=>{if(!t)return n*2.55;e/=360,t/=100,n/=100;let i=n<.5?n*(1+t):n+t-n*t,a=2*n-i;switch(r){case`r`:return jc.hue2rgb(a,i,e+1/3)*255;case`g`:return jc.hue2rgb(a,i,e)*255;case`b`:return jc.hue2rgb(a,i,e-1/3)*255}},rgb2hsl:({r:e,g:t,b:n},r)=>{e/=255,t/=255,n/=255;let i=Math.max(e,t,n),a=Math.min(e,t,n),o=(i+a)/2;if(r===`l`)return o*100;if(i===a)return 0;let s=i-a,c=o>.5?s/(2-i-a):s/(i+a);if(r===`s`)return c*100;switch(i){case e:return((t-n)/s+(t<n?6:0))*60;case t:return((n-e)/s+2)*60;case n:return((e-t)/s+4)*60;default:return-1}}},F={channel:jc,lang:{clamp:(e,t,n)=>t>n?Math.min(t,Math.max(n,e)):Math.min(n,Math.max(t,e)),round:e=>Math.round(e*1e10)/1e10},unit:{dec2hex:e=>{let t=Math.round(e).toString(16);return t.length>1?t:`0${t}`}}},Mc={};for(let e=0;e<=255;e++)Mc[e]=F.unit.dec2hex(e);var Nc={ALL:0,RGB:1,HSL:2},Pc=class{constructor(){this.type=Nc.ALL}get(){return this.type}set(e){if(this.type&&this.type!==e)throw Error(`Cannot change both RGB and HSL channels at the same time`);this.type=e}reset(){this.type=Nc.ALL}is(e){return this.type===e}},Fc=new class{constructor(e,t){this.color=t,this.changed=!1,this.data=e,this.type=new Pc}set(e,t){return this.color=t,this.changed=!1,this.data=e,this.type.type=Nc.ALL,this}_ensureHSL(){let e=this.data,{h:t,s:n,l:r}=e;t===void 0&&(e.h=F.channel.rgb2hsl(e,`h`)),n===void 0&&(e.s=F.channel.rgb2hsl(e,`s`)),r===void 0&&(e.l=F.channel.rgb2hsl(e,`l`))}_ensureRGB(){let e=this.data,{r:t,g:n,b:r}=e;t===void 0&&(e.r=F.channel.hsl2rgb(e,`r`)),n===void 0&&(e.g=F.channel.hsl2rgb(e,`g`)),r===void 0&&(e.b=F.channel.hsl2rgb(e,`b`))}get r(){let e=this.data,t=e.r;return!this.type.is(Nc.HSL)&&t!==void 0?t:(this._ensureHSL(),F.channel.hsl2rgb(e,`r`))}get g(){let e=this.data,t=e.g;return!this.type.is(Nc.HSL)&&t!==void 0?t:(this._ensureHSL(),F.channel.hsl2rgb(e,`g`))}get b(){let e=this.data,t=e.b;return!this.type.is(Nc.HSL)&&t!==void 0?t:(this._ensureHSL(),F.channel.hsl2rgb(e,`b`))}get h(){let e=this.data,t=e.h;return!this.type.is(Nc.RGB)&&t!==void 0?t:(this._ensureRGB(),F.channel.rgb2hsl(e,`h`))}get s(){let e=this.data,t=e.s;return!this.type.is(Nc.RGB)&&t!==void 0?t:(this._ensureRGB(),F.channel.rgb2hsl(e,`s`))}get l(){let e=this.data,t=e.l;return!this.type.is(Nc.RGB)&&t!==void 0?t:(this._ensureRGB(),F.channel.rgb2hsl(e,`l`))}get a(){return this.data.a}set r(e){this.type.set(Nc.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(Nc.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(Nc.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(Nc.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(Nc.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(Nc.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}({r:0,g:0,b:0,a:0},`transparent`),Ic={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:e=>{if(e.charCodeAt(0)!==35)return;let t=e.match(Ic.re);if(!t)return;let n=t[1],r=parseInt(n,16),i=n.length,a=i%4==0,o=i>4,s=o?1:17,c=o?8:4,l=a?0:-1,u=o?255:15;return Fc.set({r:(r>>c*(l+3)&u)*s,g:(r>>c*(l+2)&u)*s,b:(r>>c*(l+1)&u)*s,a:a?(r&u)*s/255:1},e)},stringify:e=>{let{r:t,g:n,b:r,a:i}=e;return i<1?`#${Mc[Math.round(t)]}${Mc[Math.round(n)]}${Mc[Math.round(r)]}${Mc[Math.round(i*255)]}`:`#${Mc[Math.round(t)]}${Mc[Math.round(n)]}${Mc[Math.round(r)]}`}},Lc={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:e=>{let t=e.match(Lc.hueRe);if(t){let[,e,n]=t;switch(n){case`grad`:return F.channel.clamp.h(parseFloat(e)*.9);case`rad`:return F.channel.clamp.h(parseFloat(e)*180/Math.PI);case`turn`:return F.channel.clamp.h(parseFloat(e)*360)}}return F.channel.clamp.h(parseFloat(e))},parse:e=>{let t=e.charCodeAt(0);if(t!==104&&t!==72)return;let n=e.match(Lc.re);if(!n)return;let[,r,i,a,o,s]=n;return Fc.set({h:Lc._hue2deg(r),s:F.channel.clamp.s(parseFloat(i)),l:F.channel.clamp.l(parseFloat(a)),a:o?F.channel.clamp.a(s?parseFloat(o)/100:parseFloat(o)):1},e)},stringify:e=>{let{h:t,s:n,l:r,a:i}=e;return i<1?`hsla(${F.lang.round(t)}, ${F.lang.round(n)}%, ${F.lang.round(r)}%, ${i})`:`hsl(${F.lang.round(t)}, ${F.lang.round(n)}%, ${F.lang.round(r)}%)`}},Rc={colors:{aliceblue:`#f0f8ff`,antiquewhite:`#faebd7`,aqua:`#00ffff`,aquamarine:`#7fffd4`,azure:`#f0ffff`,beige:`#f5f5dc`,bisque:`#ffe4c4`,black:`#000000`,blanchedalmond:`#ffebcd`,blue:`#0000ff`,blueviolet:`#8a2be2`,brown:`#a52a2a`,burlywood:`#deb887`,cadetblue:`#5f9ea0`,chartreuse:`#7fff00`,chocolate:`#d2691e`,coral:`#ff7f50`,cornflowerblue:`#6495ed`,cornsilk:`#fff8dc`,crimson:`#dc143c`,cyanaqua:`#00ffff`,darkblue:`#00008b`,darkcyan:`#008b8b`,darkgoldenrod:`#b8860b`,darkgray:`#a9a9a9`,darkgreen:`#006400`,darkgrey:`#a9a9a9`,darkkhaki:`#bdb76b`,darkmagenta:`#8b008b`,darkolivegreen:`#556b2f`,darkorange:`#ff8c00`,darkorchid:`#9932cc`,darkred:`#8b0000`,darksalmon:`#e9967a`,darkseagreen:`#8fbc8f`,darkslateblue:`#483d8b`,darkslategray:`#2f4f4f`,darkslategrey:`#2f4f4f`,darkturquoise:`#00ced1`,darkviolet:`#9400d3`,deeppink:`#ff1493`,deepskyblue:`#00bfff`,dimgray:`#696969`,dimgrey:`#696969`,dodgerblue:`#1e90ff`,firebrick:`#b22222`,floralwhite:`#fffaf0`,forestgreen:`#228b22`,fuchsia:`#ff00ff`,gainsboro:`#dcdcdc`,ghostwhite:`#f8f8ff`,gold:`#ffd700`,goldenrod:`#daa520`,gray:`#808080`,green:`#008000`,greenyellow:`#adff2f`,grey:`#808080`,honeydew:`#f0fff0`,hotpink:`#ff69b4`,indianred:`#cd5c5c`,indigo:`#4b0082`,ivory:`#fffff0`,khaki:`#f0e68c`,lavender:`#e6e6fa`,lavenderblush:`#fff0f5`,lawngreen:`#7cfc00`,lemonchiffon:`#fffacd`,lightblue:`#add8e6`,lightcoral:`#f08080`,lightcyan:`#e0ffff`,lightgoldenrodyellow:`#fafad2`,lightgray:`#d3d3d3`,lightgreen:`#90ee90`,lightgrey:`#d3d3d3`,lightpink:`#ffb6c1`,lightsalmon:`#ffa07a`,lightseagreen:`#20b2aa`,lightskyblue:`#87cefa`,lightslategray:`#778899`,lightslategrey:`#778899`,lightsteelblue:`#b0c4de`,lightyellow:`#ffffe0`,lime:`#00ff00`,limegreen:`#32cd32`,linen:`#faf0e6`,magenta:`#ff00ff`,maroon:`#800000`,mediumaquamarine:`#66cdaa`,mediumblue:`#0000cd`,mediumorchid:`#ba55d3`,mediumpurple:`#9370db`,mediumseagreen:`#3cb371`,mediumslateblue:`#7b68ee`,mediumspringgreen:`#00fa9a`,mediumturquoise:`#48d1cc`,mediumvioletred:`#c71585`,midnightblue:`#191970`,mintcream:`#f5fffa`,mistyrose:`#ffe4e1`,moccasin:`#ffe4b5`,navajowhite:`#ffdead`,navy:`#000080`,oldlace:`#fdf5e6`,olive:`#808000`,olivedrab:`#6b8e23`,orange:`#ffa500`,orangered:`#ff4500`,orchid:`#da70d6`,palegoldenrod:`#eee8aa`,palegreen:`#98fb98`,paleturquoise:`#afeeee`,palevioletred:`#db7093`,papayawhip:`#ffefd5`,peachpuff:`#ffdab9`,peru:`#cd853f`,pink:`#ffc0cb`,plum:`#dda0dd`,powderblue:`#b0e0e6`,purple:`#800080`,rebeccapurple:`#663399`,red:`#ff0000`,rosybrown:`#bc8f8f`,royalblue:`#4169e1`,saddlebrown:`#8b4513`,salmon:`#fa8072`,sandybrown:`#f4a460`,seagreen:`#2e8b57`,seashell:`#fff5ee`,sienna:`#a0522d`,silver:`#c0c0c0`,skyblue:`#87ceeb`,slateblue:`#6a5acd`,slategray:`#708090`,slategrey:`#708090`,snow:`#fffafa`,springgreen:`#00ff7f`,tan:`#d2b48c`,teal:`#008080`,thistle:`#d8bfd8`,transparent:`#00000000`,turquoise:`#40e0d0`,violet:`#ee82ee`,wheat:`#f5deb3`,white:`#ffffff`,whitesmoke:`#f5f5f5`,yellow:`#ffff00`,yellowgreen:`#9acd32`},parse:e=>{e=e.toLowerCase();let t=Rc.colors[e];if(t)return Ic.parse(t)},stringify:e=>{let t=Ic.stringify(e);for(let e in Rc.colors)if(Rc.colors[e]===t)return e}},zc={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:e=>{let t=e.charCodeAt(0);if(t!==114&&t!==82)return;let n=e.match(zc.re);if(!n)return;let[,r,i,a,o,s,c,l,u]=n;return Fc.set({r:F.channel.clamp.r(i?parseFloat(r)*2.55:parseFloat(r)),g:F.channel.clamp.g(o?parseFloat(a)*2.55:parseFloat(a)),b:F.channel.clamp.b(c?parseFloat(s)*2.55:parseFloat(s)),a:l?F.channel.clamp.a(u?parseFloat(l)/100:parseFloat(l)):1},e)},stringify:e=>{let{r:t,g:n,b:r,a:i}=e;return i<1?`rgba(${F.lang.round(t)}, ${F.lang.round(n)}, ${F.lang.round(r)}, ${F.lang.round(i)})`:`rgb(${F.lang.round(t)}, ${F.lang.round(n)}, ${F.lang.round(r)})`}},Bc={format:{keyword:Rc,hex:Ic,rgb:zc,rgba:zc,hsl:Lc,hsla:Lc},parse:e=>{if(typeof e!=`string`)return e;let t=Ic.parse(e)||zc.parse(e)||Lc.parse(e)||Rc.parse(e);if(t)return t;throw Error(`Unsupported color format: "${e}"`)},stringify:e=>!e.changed&&e.color?e.color:e.type.is(Nc.HSL)||e.data.r===void 0?Lc.stringify(e):e.a<1||!Number.isInteger(e.r)||!Number.isInteger(e.g)||!Number.isInteger(e.b)?zc.stringify(e):Ic.stringify(e)},Vc=(e,t)=>{let n=Bc.parse(e);for(let e in t)n[e]=F.channel.clamp[e](t[e]);return Bc.stringify(n)},Hc=(e,t,n=0,r=1)=>{if(typeof e!=`number`)return Vc(e,{a:t});let i=Fc.set({r:F.channel.clamp.r(e),g:F.channel.clamp.g(t),b:F.channel.clamp.b(n),a:F.channel.clamp.a(r)});return Bc.stringify(i)},Uc=e=>{let{r:t,g:n,b:r}=Bc.parse(e),i=.2126*F.channel.toLinear(t)+.7152*F.channel.toLinear(n)+.0722*F.channel.toLinear(r);return F.lang.round(i)},Wc=e=>Uc(e)>=.5,Gc=e=>!Wc(e),Kc=(e,t,n)=>{let r=Bc.parse(e),i=r[t],a=F.channel.clamp[t](i+n);return i!==a&&(r[t]=a),Bc.stringify(r)},I=(e,t)=>Kc(e,`l`,t),L=(e,t)=>Kc(e,`l`,-t),R=(e,t)=>{let n=Bc.parse(e),r={};for(let e in t)t[e]&&(r[e]=n[e]+t[e]);return Vc(e,r)},qc=(e,t,n=50)=>{let{r,g:i,b:a,a:o}=Bc.parse(e),{r:s,g:c,b:l,a:u}=Bc.parse(t),d=n/100,f=d*2-1,p=o-u,m=((f*p===-1?f:(f+p)/(1+f*p))+1)/2,h=1-m;return Hc(r*m+s*h,i*m+c*h,a*m+l*h,o*d+u*(1-d))},z=(e,t=100)=>{let n=Bc.parse(e);return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,qc(n,e,t)};function Jc(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Yc(e){if(Array.isArray(e))return e}function Xc(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function Zc(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3
3
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Qc(e,t){return Yc(e)||Xc(e,t)||$c(e,t)||Zc()}function $c(e,t){if(e){if(typeof e==`string`)return Jc(e,t);var n={}.toString.call(e).slice(8,-1);return n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`?Array.from(e):n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Jc(e,t):void 0}}var el=Object.entries,tl=Object.setPrototypeOf,nl=Object.isFrozen,rl=Object.getPrototypeOf,il=Object.getOwnPropertyDescriptor,al=Object.freeze,ol=Object.seal,sl=Object.create,cl=typeof Reflect<`u`&&Reflect,ll=cl.apply,ul=cl.construct;al||=function(e){return e},ol||=function(e){return e},ll||=function(e,t){var n=[...arguments].slice(2);return e.apply(t,n)},ul||=function(e){return new e(...[...arguments].slice(1))};var dl=jl(Array.prototype.forEach),fl=jl(Array.prototype.lastIndexOf),pl=jl(Array.prototype.pop),ml=jl(Array.prototype.push),hl=jl(Array.prototype.splice),gl=Array.isArray,_l=jl(String.prototype.toLowerCase),vl=jl(String.prototype.toString),yl=jl(String.prototype.match),bl=jl(String.prototype.replace),xl=jl(String.prototype.indexOf),Sl=jl(String.prototype.trim),Cl=jl(Number.prototype.toString),wl=jl(Boolean.prototype.toString),Tl=typeof BigInt>`u`?null:jl(BigInt.prototype.toString),El=typeof Symbol>`u`?null:jl(Symbol.prototype.toString),Dl=jl(Object.prototype.hasOwnProperty),Ol=jl(Object.prototype.toString),kl=jl(RegExp.prototype.test),Al=Ml(TypeError);function jl(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return ll(e,t,n)}}function Ml(e){return function(){return ul(e,[...arguments])}}function B(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:_l;if(tl&&tl(e,null),!gl(t))return e;let r=t.length;for(;r--;){let i=t[r];if(typeof i==`string`){let e=n(i);e!==i&&(nl(t)||(t[r]=e),i=e)}e[i]=!0}return e}function Nl(e){for(let t=0;t<e.length;t++)Dl(e,t)||(e[t]=null);return e}function Pl(e){let t=sl(null);for(let r of el(e)){var n=Qc(r,2);let i=n[0],a=n[1];Dl(e,i)&&(t[i]=gl(a)?Nl(a):a&&typeof a==`object`&&a.constructor===Object?Pl(a):a)}return t}function Fl(e){switch(typeof e){case`string`:return e;case`number`:return Cl(e);case`boolean`:return wl(e);case`bigint`:return Tl?Tl(e):`0`;case`symbol`:return El?El(e):`Symbol()`;case`undefined`:return Ol(e);case`function`:case`object`:{if(e===null)return Ol(e);let t=e,n=Il(t,`toString`);if(typeof n==`function`){let e=n(t);return typeof e==`string`?e:Ol(e)}return Ol(e)}default:return Ol(e)}}function Il(e,t){for(;e!==null;){let n=il(e,t);if(n){if(n.get)return jl(n.get);if(typeof n.value==`function`)return jl(n.value)}e=rl(e)}function n(){return null}return n}function Ll(e){try{return kl(e,``),!0}catch{return!1}}var Rl=al(`a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr`.split(`.`)),zl=al(`svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern`.split(`.`)),Bl=al([`feBlend`,`feColorMatrix`,`feComponentTransfer`,`feComposite`,`feConvolveMatrix`,`feDiffuseLighting`,`feDisplacementMap`,`feDistantLight`,`feDropShadow`,`feFlood`,`feFuncA`,`feFuncB`,`feFuncG`,`feFuncR`,`feGaussianBlur`,`feImage`,`feMerge`,`feMergeNode`,`feMorphology`,`feOffset`,`fePointLight`,`feSpecularLighting`,`feSpotLight`,`feTile`,`feTurbulence`]),Vl=al([`animate`,`color-profile`,`cursor`,`discard`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`foreignobject`,`hatch`,`hatchpath`,`mesh`,`meshgradient`,`meshpatch`,`meshrow`,`missing-glyph`,`script`,`set`,`solidcolor`,`unknown`,`use`]),Hl=al(`math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts`.split(`.`)),Ul=al([`maction`,`maligngroup`,`malignmark`,`mlongdiv`,`mscarries`,`mscarry`,`msgroup`,`mstack`,`msline`,`msrow`,`semantics`,`annotation`,`annotation-xml`,`mprescripts`,`none`]),Wl=al([`#text`]),Gl=al(`accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns`.split(`.`)),Kl=al(`accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dominant-baseline.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.pointer-events.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-orientation.text-rendering.textlength.type.u1.u2.unicode.values.vector-effect.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan`.split(`.`)),ql=al(`accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns`.split(`.`)),Jl=al([`xlink:href`,`xml:id`,`xlink:title`,`xml:space`,`xmlns:xlink`]),Yl=ol(/{{[\w\W]*|^[\w\W]*}}/g),Xl=ol(/<%[\w\W]*|^[\w\W]*%>/g),Zl=ol(/\${[\w\W]*/g),Ql=ol(/^data-[\-\w.\u00B7-\uFFFF]+$/),$l=ol(/^aria-[\-\w]+$/),eu=ol(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),tu=ol(/^(?:\w+script|data):/i),nu=ol(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ru=ol(/^html$/i),iu=ol(/^[a-z][.\w]*(-[.\w]+)+$/i),au=ol(/<[/\w!]/g),ou=ol(/<[/\w]/g),su=ol(/<\/no(script|embed|frames)/i),cu=ol(/\/>/i),lu={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},uu=[`style`,`script`,`xmp`,`iframe`,`noembed`,`noframes`,`plaintext`,`noscript`],du=al(B({},uu)),fu=function(){let e={};return dl(uu,t=>{e[t]=ol(RegExp(`</`+t+`(?=[\\t\\n\\f\\r />])`,`i`))}),al(e)}(),pu=function(){return typeof window>`u`?null:window},mu=function(e,t){if(typeof e!=`object`||typeof e.createPolicy!=`function`)return null;let n=null,r=`data-tt-policy-suffix`;t&&t.hasAttribute(r)&&(n=t.getAttribute(r));let i=`dompurify`+(n?`#`+n:``);try{return e.createPolicy(i,{createHTML(e){return e},createScriptURL(e){return e}})}catch{return console.warn(`TrustedTypes policy `+i+` could not be created.`),null}},hu=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},gu=function(e,t,n,r){return Dl(e,t)&&gl(e[t])?B(r.base?Pl(r.base):{},e[t],r.transform):n},_u=function(e,t,n){let r=Dl(e,t)?e[t]:void 0;return r&&typeof r==`object`?Pl(r):n()};function vu(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:pu(),t=e=>vu(e);if(t.version=`3.4.15`,t.removed=[],!e||!e.document||e.document.nodeType!==lu.document||!e.Element)return t.isSupported=!1,t;let n=e.document,r=n,i=r.currentScript;e.DocumentFragment;let a=e.HTMLTemplateElement,o=e.Node,s=e.Element,c=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let l=e.DOMParser,u=e.trustedTypes,d=s.prototype,f=Il(d,`cloneNode`),p=Il(d,`remove`),m=Il(d,`removeAttributeNode`),h=Il(d,`nextSibling`),g=Il(d,`childNodes`),_=Il(d,`parentNode`),v=Il(d,`shadowRoot`),y=Il(d,`attributes`),b=o&&o.prototype?Il(o.prototype,`nodeType`):null,x=o&&o.prototype?Il(o.prototype,`nodeName`):null,S=o&&o.prototype?Il(o.prototype,`ownerDocument`):null,C=function(e){return b?b(e):e.nodeType},w=function(e){return x?x(e):e.nodeName};if(typeof a==`function`){let e=n.createElement(`template`);e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let T,E=``,D,O=!1,k=0,ee=function(){if(k>0)throw Al(`A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.`)},te=function(e){ee(),k++;try{return T.createHTML(e)}finally{k--}},ne=function(e){ee(),k++;try{return T.createScriptURL(e)}finally{k--}},re=function(){return O||=(D=mu(u,i),!0),D},ie=n,ae=ie.implementation,oe=ie.createNodeIterator,se=ie.createDocumentFragment,ce=ie.getElementsByTagName,le=r.importNode,A=hu();t.isSupported=typeof el==`function`&&typeof _==`function`&&ae&&ae.createHTMLDocument!==void 0;let ue=Yl,de=Xl,fe=Zl,pe=Ql,me=$l,he=tu,ge=nu,_e=iu,ve=eu,ye=null,be=B({},[...Rl,...zl,...Bl,...Hl,...Wl]),xe=null,j=B({},[...Gl,...Kl,...ql,...Jl]),Se=Object.seal(sl(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Ce=null,we=null,Te=Object.seal(sl(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),Ee=!0,De=!0,Oe=!1,ke=!0,Ae=!1,je=!0,Me=!1,Ne=!1,Pe=null,Fe=null,Ie=!1,Le=!1,Re=!1,ze=!1,Be=!0,Ve=!1,He=`user-content-`,Ue=!0,We=!1,Ge={},Ke=null,qe=B({},`annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp`.split(`.`)),Je=null,Ye=B({},[`audio`,`video`,`img`,`source`,`image`,`track`]),Xe=null,Ze=B({},[`alt`,`class`,`for`,`id`,`label`,`name`,`pattern`,`placeholder`,`role`,`summary`,`title`,`value`,`style`,`xmlns`]),Qe=`http://www.w3.org/1998/Math/MathML`,$e=`http://www.w3.org/2000/svg`,et=`http://www.w3.org/1999/xhtml`,tt=et,nt=!1,rt=null,it=B({},[Qe,$e,et],vl),at=al([`mi`,`mo`,`mn`,`ms`,`mtext`]),ot=B({},at),st=al([`annotation-xml`]),ct=B({},st),lt=B({},[`title`,`style`,`font`,`a`,`script`]),ut=null,dt=[`application/xhtml+xml`,`text/html`],ft=null,pt=null,mt=n.createElement(`form`),ht=function(e){return e instanceof RegExp||e instanceof Function},gt=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(pt&&pt===e)return;(!e||typeof e!=`object`)&&(e={}),e=Pl(e),ut=dt.indexOf(e.PARSER_MEDIA_TYPE)===-1?`text/html`:e.PARSER_MEDIA_TYPE,ft=ut===`application/xhtml+xml`?vl:_l,ye=gu(e,`ALLOWED_TAGS`,be,{transform:ft}),xe=gu(e,`ALLOWED_ATTR`,j,{transform:ft}),rt=gu(e,`ALLOWED_NAMESPACES`,it,{transform:vl}),Xe=gu(e,`ADD_URI_SAFE_ATTR`,Ze,{transform:ft,base:Ze}),Je=gu(e,`ADD_DATA_URI_TAGS`,Ye,{transform:ft,base:Ye}),Ke=gu(e,`FORBID_CONTENTS`,qe,{transform:ft}),Ce=gu(e,`FORBID_TAGS`,Pl({}),{transform:ft}),we=gu(e,`FORBID_ATTR`,Pl({}),{transform:ft}),Ge=Dl(e,`USE_PROFILES`)?e.USE_PROFILES&&typeof e.USE_PROFILES==`object`?Pl(e.USE_PROFILES):e.USE_PROFILES:!1,Ee=e.ALLOW_ARIA_ATTR!==!1,De=e.ALLOW_DATA_ATTR!==!1,Oe=e.ALLOW_UNKNOWN_PROTOCOLS||!1,ke=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Ae=e.SAFE_FOR_TEMPLATES||!1,je=e.SAFE_FOR_XML!==!1,Me=e.WHOLE_DOCUMENT||!1,Le=e.RETURN_DOM||!1,Re=e.RETURN_DOM_FRAGMENT||!1,ze=e.RETURN_TRUSTED_TYPE||!1,Ie=e.FORCE_BODY||!1,Be=e.SANITIZE_DOM!==!1,Ve=e.SANITIZE_NAMED_PROPS||!1,Ue=e.KEEP_CONTENT!==!1,We=e.IN_PLACE||!1,ve=Ll(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:eu,tt=typeof e.NAMESPACE==`string`?e.NAMESPACE:et,ot=_u(e,`MATHML_TEXT_INTEGRATION_POINTS`,()=>B({},at)),ct=_u(e,`HTML_INTEGRATION_POINTS`,()=>B({},st));let t=_u(e,`CUSTOM_ELEMENT_HANDLING`,()=>sl(null));if(Se=sl(null),Dl(t,`tagNameCheck`)&&ht(t.tagNameCheck)&&(Se.tagNameCheck=t.tagNameCheck),Dl(t,`attributeNameCheck`)&&ht(t.attributeNameCheck)&&(Se.attributeNameCheck=t.attributeNameCheck),Dl(t,`allowCustomizedBuiltInElements`)&&typeof t.allowCustomizedBuiltInElements==`boolean`&&(Se.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),ol(Se),Ae&&(De=!1),Re&&(Le=!0),Ge&&(ye=B({},Wl),xe=sl(null),Ge.html===!0&&(B(ye,Rl),B(xe,Gl)),Ge.svg===!0&&(B(ye,zl),B(xe,Kl),B(xe,Jl)),Ge.svgFilters===!0&&(B(ye,Bl),B(xe,Kl),B(xe,Jl)),Ge.mathMl===!0&&(B(ye,Hl),B(xe,ql),B(xe,Jl))),Te.tagCheck=null,Te.attributeCheck=null,Dl(e,`ADD_TAGS`)&&(typeof e.ADD_TAGS==`function`?Te.tagCheck=e.ADD_TAGS:gl(e.ADD_TAGS)&&(ye===be&&(ye=Pl(ye)),B(ye,e.ADD_TAGS,ft))),Dl(e,`ADD_ATTR`)&&(typeof e.ADD_ATTR==`function`?Te.attributeCheck=e.ADD_ATTR:gl(e.ADD_ATTR)&&(xe===j&&(xe=Pl(xe)),B(xe,e.ADD_ATTR,ft))),Dl(e,`ADD_FORBID_CONTENTS`)&&gl(e.ADD_FORBID_CONTENTS)&&(Ke===qe&&(Ke=Pl(Ke)),B(Ke,e.ADD_FORBID_CONTENTS,ft)),Ue&&(ye[`#text`]=!0),Me&&B(ye,[`html`,`head`,`body`]),ye.table&&(B(ye,[`tbody`]),delete Ce.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!=`function`)throw Al(`TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.`);if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!=`function`)throw Al(`TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.`);let t=T;T=e.TRUSTED_TYPES_POLICY;try{E=te(``)}catch(e){throw T=t,e}}else e.TRUSTED_TYPES_POLICY===null?(T=void 0,E=``):(T===void 0&&(T=re()),T&&typeof E==`string`&&(E=te(``)));al&&al(e),pt=e},_t=B({},[...zl,...Bl,...Vl]),vt=B({},[...Hl,...Ul]),yt=function(e,t,n){return t.namespaceURI===et?e===`svg`:t.namespaceURI===Qe?e===`svg`&&(n===`annotation-xml`||ot[n]):!!_t[e]},bt=function(e,t,n){return t.namespaceURI===et?e===`math`:t.namespaceURI===$e?e===`math`&&ct[n]:!!vt[e]},xt=function(e,t,n){return t.namespaceURI===$e&&!ct[n]||t.namespaceURI===Qe&&!ot[n]?!1:!vt[e]&&(lt[e]||!_t[e])},St=function(e){let t=_(e);(!t||!t.tagName)&&(t={namespaceURI:tt,tagName:`template`});let n=_l(e.tagName),r=_l(t.tagName);return rt[e.namespaceURI]?e.namespaceURI===$e?yt(n,t,r):e.namespaceURI===Qe?bt(n,t,r):e.namespaceURI===et?xt(n,t,r):!!(ut===`application/xhtml+xml`&&rt[e.namespaceURI]):!1},Ct=function(e){ml(t.removed,{element:e});try{_(e).removeChild(e)}catch{if(p(e),!_(e))throw Al(`a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place`)}},wt=function(e,t,n){try{m(e,t)}catch{try{e.removeAttribute(n)}catch{}}},Tt=function(e){Ot(e);let t=g(e);if(t){let e=[];dl(t,t=>{ml(e,t)}),dl(e,e=>{try{p(e)}catch{}})}let n=y(e);if(n)for(let t=n.length-1;t>=0;--t){let r=n[t],i=r&&r.name;typeof i==`string`&&wt(e,r,i)}},Et=function(e,n,r){if(!r)try{r=n.getAttributeNode(e)}catch{r=null}ml(t.removed,{attribute:r||null,from:n});try{r?m(n,r):n.removeAttribute(e)}catch{try{n.removeAttribute(e)}catch{}}if(e===`is`){if(Le||Re)try{Ct(n)}catch{}else try{n.setAttribute(e,``)}catch{}}},Dt=function(e){let t=y(e);if(t)for(let n=t.length-1;n>=0;--n){let r=t[n],i=r&&r.name;typeof i!=`string`||xe[ft(i)]||wt(e,r,i)}},Ot=function(e){let t=[e];for(;t.length>0;){let e=t.pop();C(e)===lu.element&&Dt(e);let n=g(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},kt=function(e,t){return je?e===`patchsrc`||e===`for`&&t!==`label`&&t!==`output`:!1},At=function(e){if(!je)return;let t=[e];for(;t.length>0;){let e=t.pop(),n=C(e);if(n===lu.processingInstruction||n===lu.comment&&kl(ou,e.data)){try{p(e)}catch{}continue}if(n===lu.element){let t=e,n=ft(w(e));try{t.hasAttribute&&t.hasAttribute(`patchsrc`)&&t.removeAttribute(`patchsrc`),t.hasAttribute&&t.hasAttribute(`for`)&&kt(`for`,n)&&t.removeAttribute(`for`)}catch{}}let r=g(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}},jt=function(e){let t=null,r=null;if(Ie)e=`<remove></remove>`+e;else{let t=yl(e,/^[\r\n\t ]+/);r=t&&t[0]}ut===`application/xhtml+xml`&&tt===et&&(e=`<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>`+e+`</body></html>`);let i=T?te(e):e;if(tt===et)try{t=new l().parseFromString(i,ut)}catch{}if(!t||!t.documentElement){t=ae.createDocument(tt,`template`,null);try{t.documentElement.innerHTML=nt?E:i}catch{}}let a=t.body||t.documentElement;return e&&r&&a.insertBefore(n.createTextNode(r),a.childNodes[0]||null),tt===et?ce.call(t,Me?`html`:`body`)[0]:Me?t.documentElement:a},Mt=function(e){let t=S?S(e):e.ownerDocument;return oe.call(t||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},Nt=function(e){return e=bl(e,ue,` `),e=bl(e,de,` `),e=bl(e,fe,` `),e},Pt=function(e){e.normalize();let t=S?S(e):e.ownerDocument,n=oe.call(t||e,e,c.SHOW_TEXT|c.SHOW_COMMENT|c.SHOW_CDATA_SECTION|c.SHOW_PROCESSING_INSTRUCTION,null),r=n.nextNode();for(;r;)r.data=Nt(r.data),r=n.nextNode();let i=e.querySelectorAll?.call(e,`template`);i&&dl(i,e=>{It(e.content)&&Pt(e.content)})},Ft=function(e){let t=x?x(e):null;return typeof t!=`string`||ft(t)!==`form`?!1:typeof e.nodeName!=`string`||typeof e.textContent!=`string`||typeof e.removeChild!=`function`||e.attributes!==y(e)||typeof e.removeAttribute!=`function`||typeof e.removeAttributeNode!=`function`||typeof e.getAttributeNode!=`function`||typeof e.setAttribute!=`function`||typeof e.namespaceURI!=`string`||typeof e.insertBefore!=`function`||typeof e.hasChildNodes!=`function`||e.nodeType!==b(e)||e.childNodes!==g(e)},It=function(e){if(!b||typeof e!=`object`||!e)return!1;try{return b(e)===lu.documentFragment}catch{return!1}},Lt=function(e){if(!b||typeof e!=`object`||!e)return!1;try{return typeof b(e)==`number`}catch{return!1}};function Rt(e,n,r){e.length!==0&&dl(e,e=>{e.call(t,n,r,pt)})}let zt=function(e,t){return!!(je&&e.hasChildNodes()&&!Lt(e.firstElementChild)&&kl(au,e.textContent)&&kl(au,e.innerHTML)||je&&e.namespaceURI===et&&du[t]&&(Lt(e.firstElementChild)||typeof e.textContent==`string`&&kl(fu[t],e.textContent))||e.nodeType===lu.processingInstruction||je&&e.nodeType===lu.comment&&kl(ou,e.data))},Bt=function(e,t){return e instanceof RegExp?kl(e,t):e instanceof Function&&!!e(t,...[...arguments].slice(2))},Vt=function(e,t,n){if(!Ce[t]&&qt(t)&&Bt(Se.tagNameCheck,t))return!1;if(Ue&&!Ke[t]){let t=_(e),r=g(e);if(r&&t){let i=r.length;for(let a=i-1;a>=0;--a){let i=e===n?f(r[a],!0):r[a];t.insertBefore(i,h(e))}}}return Ct(e),!0},Ht=function(e,t,n,r){return e.length===0?t:t===n||t===r?Pl(t):t},Ut=function(e,t){return e===t||_(e)!==null?!1:(We&&Ot(e),!0)},Wt=function(e,n){if(Rt(A.beforeSanitizeElements,e,null),Ut(e,n))return!0;if(Ft(e))return Ct(e),!0;let r=ft(w(e));if(ye=Ht(A.uponSanitizeElement,ye,be,Pe),Rt(A.uponSanitizeElement,e,{tagName:r,allowedTags:ye}),Ut(e,n))return!0;if(zt(e,r))return Ct(e),!0;if(Ce[r]||!(Te.tagCheck instanceof Function&&Te.tagCheck(r))&&!ye[r]){let t=Vt(e,r,n);return t===!1&&Rt(A.afterSanitizeElements,e,null),t}if(C(e)===lu.element&&!St(e)||(r===`noscript`||r===`noembed`||r===`noframes`)&&kl(su,e.innerHTML))return Ct(e),!0;if(Ae&&e.nodeType===lu.text){let n=Nt(e.textContent);e.textContent!==n&&(ml(t.removed,{element:e.cloneNode()}),e.textContent=n)}return Rt(A.afterSanitizeElements,e,null),!1},Gt=function(e,t,r){if(we[t]||kt(t,e)||Be&&(t===`id`||t===`name`)&&(r in n||r in mt))return!1;let i=xe[t]||Te.attributeCheck instanceof Function&&Te.attributeCheck(t,e);return De&&kl(pe,t)||Ee&&kl(me,t)?!0:i?Xe[t]||kl(ve,bl(r,ge,``))||(t===`src`||t===`xlink:href`||t===`href`)&&e!==`script`&&xl(r,`data:`)===0&&Je[e]||Oe&&!kl(he,bl(r,ge,``))?!0:!r:qt(e)&&Bt(Se.tagNameCheck,e)&&Bt(Se.attributeNameCheck,t,e)||t===`is`&&Se.allowCustomizedBuiltInElements&&Bt(Se.tagNameCheck,r)},Kt=B({},[`annotation-xml`,`color-profile`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`missing-glyph`]),qt=function(e){return!Kt[_l(e)]&&kl(_e,e)},Jt=function(e,t,n,r){if(T&&typeof u==`object`&&typeof u.getAttributeType==`function`&&!n)switch(u.getAttributeType(e,t)){case`TrustedHTML`:return te(r);case`TrustedScriptURL`:return ne(r)}return r},Yt=function(e,t,n,r){try{return n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),!Ft(e)||(Ct(e),!1)}catch{return Et(t,e),!1}},Xt=function(e){Rt(A.beforeSanitizeAttributes,e,null);let n=e.attributes;if(!n||Ft(e))return;xe=Ht(A.uponSanitizeAttribute,xe,j,Fe);let r={attrName:``,attrValue:``,keepAttr:!0,allowedAttributes:xe,forceKeepAttr:void 0},i=n.length,a=ft(e.nodeName);for(;i--;){let o=n[i],s=o.name,c=o.namespaceURI,l=o.value,u=ft(s),d=l,f=s===`value`?d:Sl(d),p=!1;if(r.attrName=u,r.attrValue=f,r.keepAttr=!0,r.forceKeepAttr=void 0,Rt(A.uponSanitizeAttribute,e,r),f=r.attrValue,Ve&&(u===`id`||u===`name`)&&xl(f,He)!==0&&(Et(s,e,o),f=He+f,p=!0),je&&kl(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)){Et(s,e,o);continue}if(u===`attributename`&&yl(f,`href`)){Et(s,e,o);continue}if(!r.forceKeepAttr){if(!r.keepAttr){Et(s,e,o);continue}if(!ke&&kl(cu,f)){Et(s,e,o);continue}if(Ae&&(f=Nt(f)),!Gt(a,u,f)){Et(s,e,o);continue}f=Jt(a,u,c,f),f!==d&&Yt(e,s,c,f)&&p&&pl(t.removed)}}Rt(A.afterSanitizeAttributes,e,null)},Zt=function(e){let t=null,n=Mt(e);for(Rt(A.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(Rt(A.uponSanitizeShadowNode,t,null),Wt(t,e),Xt(t),It(t.content)&&Zt(t.content),C(t)===lu.element){let e=v(t);It(e)&&(Qt(e),Zt(e))}Rt(A.afterSanitizeShadowDOM,e,null)},Qt=function(e){let t=[{node:e,shadow:null}];for(;t.length>0;){let e=t.pop();if(e.shadow){Zt(e.shadow);continue}let n=e.node,r=C(n)===lu.element,i=g(n);if(i)for(let e=i.length-1;e>=0;--e)t.push({node:i[e],shadow:null});if(r){let e=x?x(n):null;if(typeof e==`string`&&ft(e)===`template`){let e=n.content;It(e)&&t.push({node:e,shadow:null})}}if(r){let e=v(n);It(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=null,a=null,o=null,s=null;if(nt=!e,nt&&(e=`<!-->`),typeof e!=`string`&&!Lt(e)&&(e=Fl(e),typeof e!=`string`))throw Al(`dirty is not a string, aborting`);if(!t.isSupported)return e;Ne?(ye=Pe,xe=Fe):gt(n),(A.uponSanitizeElement.length>0||A.uponSanitizeAttribute.length>0)&&(ye=Pl(ye)),A.uponSanitizeAttribute.length>0&&(xe=Pl(xe)),t.removed=[];let c=We&&typeof e!=`string`&&Lt(e);if(c){At(e);let t=w(e);if(typeof t==`string`){let n=ft(t);if(!ye[n]||Ce[n])throw Tt(e),Al(`root node is forbidden and cannot be sanitized in-place`)}if(Ft(e))throw Tt(e),Al(`root node is clobbered and cannot be sanitized in-place`);try{Qt(e)}catch(t){throw Tt(e),t}}else if(Lt(e))i=jt(`<!---->`),a=i.ownerDocument.importNode(e,!0),a.nodeType===lu.element&&a.nodeName===`BODY`||a.nodeName===`HTML`?i=a:i.appendChild(a),Qt(i);else{if(!Le&&!Ae&&!Me&&e.indexOf(`<`)===-1)return T&&ze?te(e):e;if(i=jt(e),!i)return Le?null:ze?E:``}i&&Ie&&Ct(i.firstChild);let l=c?e:i;try{let e=Mt(l);for(;o=e.nextNode();)Wt(o,l),Xt(o),It(o.content)&&Zt(o.content)}catch(n){throw c&&(Tt(e),dl(t.removed,e=>{e.element&&Ot(e.element)})),n}if(c)return dl(t.removed,e=>{e.element&&Ot(e.element)}),Ae&&Pt(e),e;if(Le){if(Ae&&Pt(i),Re)for(s=se.call(i.ownerDocument);i.firstChild;)s.appendChild(i.firstChild);else s=i;return(xe.shadowroot||xe.shadowrootmode)&&(s=le.call(r,s,!0)),s}let u=Me?i.outerHTML:i.innerHTML;return Me&&ye[`!doctype`]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&kl(ru,i.ownerDocument.doctype.name)&&(u=`<!DOCTYPE `+i.ownerDocument.doctype.name+`>
|
|
4
4
|
`+u),Ae&&(u=Nt(u)),T&&ze?te(u):u},t.setConfig=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};gt(e),Ne=!0,Pe=ye,Fe=xe},t.clearConfig=function(){pt=null,Ne=!1,Pe=null,Fe=null,T=D,E=``},t.isValidAttribute=function(e,t,n){pt||gt({});let r=ft(e),i=ft(t);return Gt(r,i,n)},t.addHook=function(e,t){typeof t==`function`&&Dl(A,e)&&ml(A[e],t)},t.removeHook=function(e,t){if(Dl(A,e)){if(t!==void 0){let n=fl(A[e],t);return n===-1?void 0:hl(A[e],n,1)[0]}return pl(A[e])}},t.removeHooks=function(e){Dl(A,e)&&(A[e]=[])},t.removeAllHooks=function(){A=hu()},t}var yu=vu(),bu=N((e,t,{depth:n=2}={})=>{let r={depth:n};if(Array.isArray(t)&&!Array.isArray(e))return t.forEach(t=>bu(e,t,r)),e;if(Array.isArray(t)&&Array.isArray(e))return t.forEach(t=>{e.includes(t)||e.push(t)}),e;if(e==null||n<=0)return typeof e==`object`&&e&&typeof t==`object`?Object.assign(e,t):t;if(t!=null&&typeof e==`object`&&typeof t==`object`){let r=e;Object.entries(t).forEach(([t,i])=>{if(typeof i==`object`){if(i===null)return;Object.hasOwn(e,t)||Object.defineProperty(e,t,{value:void 0,writable:!0,enumerable:!0,configurable:!0}),r[t]===void 0&&(r[t]=Array.isArray(i)?[]:{}),typeof r[t]==`object`&&(r[t]=bu(r[t],i,{depth:n-1}))}else typeof r[t]!=`object`&&(Object.hasOwn(e,t)?r[t]=i:Object.defineProperty(e,t,{value:i,writable:!0,enumerable:!0,configurable:!0}))})}return e},`assignWithDepth`),xu=bu,Su=`#ffffff`,Cu=`#f2f2f2`,V=N((e,t)=>t?R(e,{s:-40,l:10}):R(e,{s:-40,l:-10}),`mkBorder`),wu=class{static{N(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#fff4dd`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.useGradient=!0,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||I(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.vertLineColor=this.vertLineColor||`navy`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||L(this.mainBkg,5)||`#ffffff`,this.rowEven=this.rowEven||L(this.mainBkg,10)):(this.rowOdd=this.rowOdd||I(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||I(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||R(this.primaryColor,{h:30}),this.cScale4=this.cScale4||R(this.primaryColor,{h:60}),this.cScale5=this.cScale5||R(this.primaryColor,{h:90}),this.cScale6=this.cScale6||R(this.primaryColor,{h:120}),this.cScale7=this.cScale7||R(this.primaryColor,{h:150}),this.cScale8=this.cScale8||R(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||R(this.primaryColor,{h:270}),this.cScale10=this.cScale10||R(this.primaryColor,{h:300}),this.cScale11=this.cScale11||R(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;let e=this.darkMode?-4:-1;for(let t=0;t<5;t++)this[`surface`+t]=this[`surface`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(5+t*3)}),this[`surfacePeer`+t]=this[`surfacePeer`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(8+t*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||R(this.primaryColor,{h:64}),this.fillType3=this.fillType3||R(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||R(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||R(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||R(this.primaryColor,{h:128}),this.fillType7=this.fillType7||R(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||R(this.primaryColor,{l:-10}),this.pie5=this.pie5||R(this.secondaryColor,{l:-10}),this.pie6=this.pie6||R(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||R(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||R(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||R(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||R(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||R(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||R(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.venn1=this.venn1??R(this.primaryColor,{l:-30}),this.venn2=this.venn2??R(this.secondaryColor,{l:-30}),this.venn3=this.venn3??R(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??R(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??R(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??R(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??R(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??R(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||`#8B0000`,cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||`#E8F5E9`,complicatedBg:this.cynefin?.complicatedBg||`#E3F2FD`,chaoticBg:this.cynefin?.chaoticBg||`#FBE9E7`,clearBg:this.cynefin?.clearBg||`#FFF8E1`,confusionBg:this.cynefin?.confusionBg||`#F3E5F5`,textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||`#DEDEDE`,graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||`#dc3545`,this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.archEdgeColor=this.archEdgeColor||`#777`,this.archEdgeArrowColor=this.archEdgeArrowColor||`#777`,this.archEdgeWidth=this.archEdgeWidth||`3`,this.archGroupBorderColor=this.archGroupBorderColor||`#000`,this.archGroupBorderWidth=this.archGroupBorderWidth||`2px`,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||R(this.primaryColor,{h:-30}),this.git4=this.git4||R(this.primaryColor,{h:-60}),this.git5=this.git5||R(this.primaryColor,{h:-90}),this.git6=this.git6||R(this.primaryColor,{h:60}),this.git7=this.git7||R(this.primaryColor,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.emUiFill=this.emUiFill||`white`,this.emUiStroke=this.emUiStroke||`#dbdada`,this.emProcessorFill=this.emProcessorFill||`#edb3f6`,this.emProcessorStroke=this.emProcessorStroke||`#b88cbf`,this.emReadModelFill=this.emReadModelFill||`#d3f1a2`,this.emReadModelStroke=this.emReadModelStroke||`#a3b732`,this.emCommandFill=this.emCommandFill||`#bcd6fe`,this.emCommandStroke=this.emCommandStroke||`#679ac3`,this.emEventFill=this.emEventFill||`#ffb778`,this.emEventStroke=this.emEventStroke||`#c19a0f`,this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||`rgb(250,250,250)`,this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||`rgb(240,240,240)`,this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Tu=N(e=>{let t=new wu;return t.calculate(e),t},`getThemeVariables`),Eu=class{static{N(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=I(this.primaryColor,16),this.tertiaryColor=R(this.primaryColor,{h:-160}),this.primaryBorderColor=z(this.background),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.tertiaryColor),this.lineColor=z(this.background),this.textColor=z(this.background),this.mainBkg=`#1f2020`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=I(z(`#323D47`),10),this.lineColor=`calculated`,this.border1=`#ccc`,this.border2=Hc(255,255,255,.25),this.arrowheadColor=`calculated`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.labelBackground=`#181818`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`#F9FFFE`,this.edgeLabelBackground=`calculated`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`calculated`,this.actorLineColor=`calculated`,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`calculated`,this.activationBkgColor=`calculated`,this.sequenceNumberColor=`black`,this.clusterBkg=`#302F3D`,this.sectionBkgColor=L(`#EAE8D9`,30),this.altSectionBkgColor=`calculated`,this.sectionBkgColor2=`#EAE8D9`,this.excludeBkgColor=L(this.sectionBkgColor,10),this.taskBorderColor=Hc(255,255,255,70),this.taskBkgColor=`calculated`,this.taskTextColor=`calculated`,this.taskTextLightColor=`calculated`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=Hc(255,255,255,50),this.activeTaskBkgColor=`#81B1DB`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#E83737`,this.critBkgColor=`#E83737`,this.taskTextDarkColor=`calculated`,this.todayLineColor=`#DB5757`,this.vertLineColor=`#00BFFF`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.rowOdd=this.rowOdd||I(this.mainBkg,5)||`#ffffff`,this.rowEven=this.rowEven||L(this.mainBkg,10),this.labelColor=`calculated`,this.errorBkgColor=`#a44141`,this.errorTextColor=`#ddd`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`}updateColors(){this.secondBkg=I(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=I(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.background,this.taskBkgColor=I(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=z(this.doneTaskBkgColor),this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#555`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=`#f4f4f4`,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=R(this.primaryColor,{h:64}),this.fillType3=R(this.secondaryColor,{h:64}),this.fillType4=R(this.primaryColor,{h:-64}),this.fillType5=R(this.secondaryColor,{h:-64}),this.fillType6=R(this.primaryColor,{h:128}),this.fillType7=R(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||`#0b0000`,this.cScale2=this.cScale2||`#4d1037`,this.cScale3=this.cScale3||`#3f5258`,this.cScale4=this.cScale4||`#4f2f1b`,this.cScale5=this.cScale5||`#6e0a0a`,this.cScale6=this.cScale6||`#3b0048`,this.cScale7=this.cScale7||`#995a01`,this.cScale8=this.cScale8||`#154706`,this.cScale9=this.cScale9||`#161722`,this.cScale10=this.cScale10||`#00296f`,this.cScale11=this.cScale11||`#01629c`,this.cScale12=this.cScale12||`#010029`,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||R(this.primaryColor,{h:30}),this.cScale4=this.cScale4||R(this.primaryColor,{h:60}),this.cScale5=this.cScale5||R(this.primaryColor,{h:90}),this.cScale6=this.cScale6||R(this.primaryColor,{h:120}),this.cScale7=this.cScale7||R(this.primaryColor,{h:150}),this.cScale8=this.cScale8||R(this.primaryColor,{h:210}),this.cScale9=this.cScale9||R(this.primaryColor,{h:270}),this.cScale10=this.cScale10||R(this.primaryColor,{h:300}),this.cScale11=this.cScale11||R(this.primaryColor,{h:330});for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10);for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{h:30,s:-30,l:-(-10+e*4)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{h:30,s:-30,l:-(-7+e*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?`black`:this.labelTextColor);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`pie`+e]=this[`cScale`+e];this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.mainContrastColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.mainContrastColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`;for(let e=0;e<8;e++)this[`venn`+(e+1)]=this[`venn`+(e+1)]??I(this[`cScale`+e],30);this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||`#FF6B6B`,cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||`#1B5E20`,complicatedBg:this.cynefin?.complicatedBg||`#0D47A1`,chaoticBg:this.cynefin?.chaoticBg||`#BF360C`,clearBg:this.cynefin?.clearBg||`#F57F17`,confusionBg:this.cynefin?.confusionBg||`#4A148C`,textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22`},this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.background},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||`#DEDEDE`,graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||`#ff6b6b`,this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.mainBkg,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.mainBkg},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=I(this.secondaryColor,20),this.git1=I(this.pie2||this.secondaryColor,20),this.git2=I(this.pie3||this.tertiaryColor,20),this.git3=I(this.pie4||R(this.primaryColor,{h:-30}),20),this.git4=I(this.pie5||R(this.primaryColor,{h:-60}),20),this.git5=I(this.pie6||R(this.primaryColor,{h:-90}),10),this.git6=I(this.pie7||R(this.primaryColor,{h:60}),10),this.git7=I(this.pie8||R(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||z(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||z(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.emUiFill=this.emUiFill||`#2d2d2d`,this.emUiStroke=this.emUiStroke||`#555`,this.emProcessorFill=this.emProcessorFill||I(`#5a3d5c`,10),this.emProcessorStroke=this.emProcessorStroke||`#8a6d8c`,this.emReadModelFill=this.emReadModelFill||I(`#3d5a2d`,10),this.emReadModelStroke=this.emReadModelStroke||`#6d8c5c`,this.emCommandFill=this.emCommandFill||I(`#2d3d5a`,10),this.emCommandStroke=this.emCommandStroke||`#5c6d8c`,this.emEventFill=this.emEventFill||I(`#5a452d`,10),this.emEventStroke=this.emEventStroke||`#8c755c`,this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||I(this.background,5),this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||I(this.background,12),this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||I(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||I(this.background,2),this.nodeBorder=this.nodeBorder||`#999`}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Du=N(e=>{let t=new Eu;return t.calculate(e),t},`getThemeVariables`),Ou=class{static{N(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#ECECFF`,this.secondaryColor=R(this.primaryColor,{h:120}),this.secondaryColor=`#ffffde`,this.tertiaryColor=R(this.primaryColor,{h:-160}),this.primaryBorderColor=V(this.primaryColor,this.darkMode),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.tertiaryColor),this.lineColor=z(this.background),this.textColor=z(this.background),this.background=`white`,this.mainBkg=`#ECECFF`,this.secondBkg=`#ffffde`,this.lineColor=`#333333`,this.border1=`#9370DB`,this.primaryBorderColor=V(this.primaryColor,this.darkMode),this.border2=`#aaaa33`,this.arrowheadColor=`#333333`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.labelBackground=`rgba(232,232,232, 0.8)`,this.textColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`calculated`,this.edgeLabelBackground=`calculated`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`black`,this.actorLineColor=`calculated`,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.clusterBkg=`#FBFBFF`,this.sectionBkgColor=`calculated`,this.altSectionBkgColor=`calculated`,this.sectionBkgColor2=`calculated`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`calculated`,this.taskTextLightColor=`calculated`,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=`calculated`,this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor=`calculated`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`calculated`,this.critBorderColor=`calculated`,this.critBkgColor=`calculated`,this.todayLineColor=`calculated`,this.vertLineColor=`calculated`,this.sectionBkgColor=Hc(102,102,255,.49),this.altSectionBkgColor=`white`,this.sectionBkgColor2=`#fff400`,this.taskBorderColor=`#534fbc`,this.taskBkgColor=`#8a90dd`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`black`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`#534fbc`,this.activeTaskBkgColor=`#bfc7ff`,this.gridColor=`lightgrey`,this.doneTaskBkgColor=`lightgrey`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#ff8888`,this.critBkgColor=`red`,this.todayLineColor=`red`,this.vertLineColor=`navy`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.rowOdd=`calculated`,this.rowEven=`calculated`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!1,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow(1px 2px 2px rgba(185, 185, 185, 1))`,this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||R(this.primaryColor,{h:30}),this.cScale4=this.cScale4||R(this.primaryColor,{h:60}),this.cScale5=this.cScale5||R(this.primaryColor,{h:90}),this.cScale6=this.cScale6||R(this.primaryColor,{h:120}),this.cScale7=this.cScale7||R(this.primaryColor,{h:150}),this.cScale8=this.cScale8||R(this.primaryColor,{h:210}),this.cScale9=this.cScale9||R(this.primaryColor,{h:270}),this.cScale10=this.cScale10||R(this.primaryColor,{h:300}),this.cScale11=this.cScale11||R(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||L(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||L(this.tertiaryColor,40);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],10),this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||R(this[`cScale`+e],{h:180});for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{h:30,l:-(5+e*5)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{h:30,l:-(7+e*5)});if(this.scaleLabelColor=this.scaleLabelColor!==`calculated`&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!==`calculated`){this.cScaleLabel0=this.cScaleLabel0||z(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||z(this.labelTextColor);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.labelTextColor}this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||I(this.primaryColor,75)||`#ffffff`,this.rowEven=this.rowEven||I(this.primaryColor,1),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=R(this.primaryColor,{h:64}),this.fillType3=R(this.secondaryColor,{h:64}),this.fillType4=R(this.primaryColor,{h:-64}),this.fillType5=R(this.secondaryColor,{h:-64}),this.fillType6=R(this.primaryColor,{h:128}),this.fillType7=R(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||R(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||R(this.primaryColor,{l:-10}),this.pie5=this.pie5||R(this.secondaryColor,{l:-30}),this.pie6=this.pie6||R(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||R(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||R(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||R(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||R(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||R(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||R(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.venn1=this.venn1??R(this.primaryColor,{l:-30}),this.venn2=this.venn2??R(this.secondaryColor,{l:-30}),this.venn3=this.venn3??R(this.tertiaryColor,{l:-40}),this.venn4=this.venn4??R(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??R(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??R(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??R(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??R(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||`#8B0000`,cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||`#E8F5E9`,complicatedBg:this.cynefin?.complicatedBg||`#E3F2FD`,chaoticBg:this.cynefin?.chaoticBg||`#FBE9E7`,clearBg:this.cynefin?.clearBg||`#FFF8E1`,confusionBg:this.cynefin?.confusionBg||`#F3E5F5`,textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||`#DEDEDE`,graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||`#dc3545`,this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3`},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||R(this.primaryColor,{h:-30}),this.git4=this.git4||R(this.primaryColor,{h:-60}),this.git5=this.git5||R(this.primaryColor,{h:-90}),this.git6=this.git6||R(this.primaryColor,{h:60}),this.git7=this.git7||R(this.primaryColor,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||L(z(this.git0),25),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||z(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||z(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.emUiFill=this.emUiFill||`white`,this.emUiStroke=this.emUiStroke||`#dbdada`,this.emProcessorFill=this.emProcessorFill||`#edb3f6`,this.emProcessorStroke=this.emProcessorStroke||`#b88cbf`,this.emReadModelFill=this.emReadModelFill||`#d3f1a2`,this.emReadModelStroke=this.emReadModelStroke||`#a3b732`,this.emCommandFill=this.emCommandFill||`#bcd6fe`,this.emCommandStroke=this.emCommandStroke||`#679ac3`,this.emEventFill=this.emEventFill||`#ffb778`,this.emEventStroke=this.emEventStroke||`#c19a0f`,this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||`rgb(250,250,250)`,this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||`rgb(240,240,240)`,this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(Object.keys(this).forEach(e=>{this[e]===`calculated`&&(this[e]=void 0)}),typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},ku=N(e=>{let t=new Ou;return t.calculate(e),t},`getThemeVariables`),Au=class{static{N(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#cde498`,this.secondaryColor=`#cdffb2`,this.background=`white`,this.mainBkg=`#cde498`,this.secondBkg=`#cdffb2`,this.lineColor=`green`,this.border1=`#13540c`,this.border2=`#6eaa49`,this.arrowheadColor=`green`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.tertiaryColor=I(`#cde498`,10),this.primaryBorderColor=V(this.primaryColor,this.darkMode),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.primaryColor),this.lineColor=z(this.background),this.textColor=z(this.background),this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`#333`,this.edgeLabelBackground=`#e8e8e8`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`black`,this.actorLineColor=`calculated`,this.signalColor=`#333`,this.signalTextColor=`#333`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`#326932`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.sectionBkgColor=`#6eaa49`,this.altSectionBkgColor=`white`,this.sectionBkgColor2=`#6eaa49`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`#487e3a`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`black`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`lightgrey`,this.doneTaskBkgColor=`lightgrey`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#ff8888`,this.critBkgColor=`red`,this.todayLineColor=`red`,this.vertLineColor=`#00BFFF`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,0.5))`}updateColors(){this.actorBorder=L(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||R(this.primaryColor,{h:30}),this.cScale4=this.cScale4||R(this.primaryColor,{h:60}),this.cScale5=this.cScale5||R(this.primaryColor,{h:90}),this.cScale6=this.cScale6||R(this.primaryColor,{h:120}),this.cScale7=this.cScale7||R(this.primaryColor,{h:150}),this.cScale8=this.cScale8||R(this.primaryColor,{h:210}),this.cScale9=this.cScale9||R(this.primaryColor,{h:270}),this.cScale10=this.cScale10||R(this.primaryColor,{h:300}),this.cScale11=this.cScale11||R(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||L(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||L(this.tertiaryColor,40);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],10),this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||R(this[`cScale`+e],{h:180});this.scaleLabelColor=this.scaleLabelColor!==`calculated`&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{h:30,s:-30,l:-(5+e*5)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{h:30,s:-30,l:-(8+e*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||I(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||I(this.mainBkg,20),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=R(this.primaryColor,{h:64}),this.fillType3=R(this.secondaryColor,{h:64}),this.fillType4=R(this.primaryColor,{h:-64}),this.fillType5=R(this.secondaryColor,{h:-64}),this.fillType6=R(this.primaryColor,{h:128}),this.fillType7=R(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||R(this.primaryColor,{l:-30}),this.pie5=this.pie5||R(this.secondaryColor,{l:-30}),this.pie6=this.pie6||R(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||R(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||R(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||R(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||R(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||R(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||R(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.venn1=this.venn1??R(this.primaryColor,{l:-30}),this.venn2=this.venn2??R(this.secondaryColor,{l:-30}),this.venn3=this.venn3??R(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??R(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??R(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??R(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??R(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??R(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||`#8B4513`,cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||`#C8E6C9`,complicatedBg:this.cynefin?.complicatedBg||`#DCEDC8`,chaoticBg:this.cynefin?.chaoticBg||`#FFE0B2`,clearBg:this.cynefin?.clearBg||`#FFF9C4`,confusionBg:this.cynefin?.confusionBg||`#D7CCC8`,textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.mainBkg},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||`#DEDEDE`,graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||`#dc3545`,this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176`},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||R(this.primaryColor,{h:-30}),this.git4=this.git4||R(this.primaryColor,{h:-60}),this.git5=this.git5||R(this.primaryColor,{h:-90}),this.git6=this.git6||R(this.primaryColor,{h:60}),this.git7=this.git7||R(this.primaryColor,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||z(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||z(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.emUiFill=this.emUiFill||`white`,this.emUiStroke=this.emUiStroke||`#dbdada`,this.emProcessorFill=this.emProcessorFill||`#edb3f6`,this.emProcessorStroke=this.emProcessorStroke||`#b88cbf`,this.emReadModelFill=this.emReadModelFill||`#d3f1a2`,this.emReadModelStroke=this.emReadModelStroke||`#a3b732`,this.emCommandFill=this.emCommandFill||`#bcd6fe`,this.emCommandStroke=this.emCommandStroke||`#679ac3`,this.emEventFill=this.emEventFill||`#ffb778`,this.emEventStroke=this.emEventStroke||`#c19a0f`,this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||`rgb(250,250,250)`,this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||`rgb(240,240,240)`,this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},ju=N(e=>{let t=new Au;return t.calculate(e),t},`getThemeVariables`),Mu=class{static{N(this,`Theme`)}constructor(){this.primaryColor=`#eee`,this.contrast=`#707070`,this.secondaryColor=I(this.contrast,55),this.background=`#ffffff`,this.tertiaryColor=R(this.primaryColor,{h:-160}),this.primaryBorderColor=V(this.primaryColor,this.darkMode),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.tertiaryColor),this.lineColor=z(this.background),this.textColor=z(this.background),this.mainBkg=`#eee`,this.secondBkg=`calculated`,this.lineColor=`#666`,this.border1=`#999`,this.border2=`calculated`,this.note=`#ffa`,this.text=`#333`,this.critical=`#d42`,this.done=`#bbb`,this.arrowheadColor=`#333333`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`calculated`,this.edgeLabelBackground=`white`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`calculated`,this.actorLineColor=this.actorBorder,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`calculated`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.sectionBkgColor=`calculated`,this.altSectionBkgColor=`white`,this.sectionBkgColor2=`calculated`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`calculated`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`calculated`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`calculated`,this.critBkgColor=`calculated`,this.critBorderColor=`calculated`,this.todayLineColor=`calculated`,this.vertLineColor=`calculated`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`,this.rowOdd=this.rowOdd||I(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||`#f4f4f4`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`}updateColors(){this.secondBkg=I(this.contrast,55),this.border2=this.contrast,this.actorBorder=I(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor=`#999`,this.noteBkgColor=`#666`,this.noteTextColor=`#fff`,this.cScale0=this.cScale0||`#555`,this.cScale1=this.cScale1||`#F4F4F4`,this.cScale2=this.cScale2||`#555`,this.cScale3=this.cScale3||`#BBB`,this.cScale4=this.cScale4||`#777`,this.cScale5=this.cScale5||`#999`,this.cScale6=this.cScale6||`#DDD`,this.cScale7=this.cScale7||`#FFF`,this.cScale8=this.cScale8||`#DDD`,this.cScale9=this.cScale9||`#BBB`,this.cScale10=this.cScale10||`#999`,this.cScale11=this.cScale11||`#777`;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?`black`:this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{l:-(5+e*5)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{l:-(8+e*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.sectionBkgColor=I(this.contrast,30),this.sectionBkgColor2=I(this.contrast,30),this.taskBorderColor=L(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=I(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=L(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.vertLineColor=this.critBkgColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||`#000`,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f4f4f4`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||`#000`,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=`#222`,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=R(this.primaryColor,{h:64}),this.fillType3=R(this.secondaryColor,{h:64}),this.fillType4=R(this.primaryColor,{h:-64}),this.fillType5=R(this.secondaryColor,{h:-64}),this.fillType6=R(this.primaryColor,{h:128}),this.fillType7=R(this.secondaryColor,{h:128});for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`pie`+e]=this[`cScale`+e];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`;for(let e=0;e<8;e++)this[`venn`+(e+1)]=this[`venn`+(e+1)]??this[`cScale`+e];this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||`#8B0000`,cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||`#E8F5E9`,complicatedBg:this.cynefin?.complicatedBg||`#E3F2FD`,chaoticBg:this.cynefin?.chaoticBg||`#FBE9E7`,clearBg:this.cynefin?.clearBg||`#FFF8E1`,confusionBg:this.cynefin?.confusionBg||`#F3E5F5`,textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0`},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||`#DEDEDE`,graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||`#dc3545`,this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=L(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||R(this.primaryColor,{h:-30}),this.git4=this.pie5||R(this.primaryColor,{h:-60}),this.git5=this.pie6||R(this.primaryColor,{h:-90}),this.git6=this.pie7||R(this.primaryColor,{h:60}),this.git7=this.pie8||R(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1=`white`,this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3=`white`,this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.emUiFill=this.emUiFill||`white`,this.emUiStroke=this.emUiStroke||`#dbdada`,this.emProcessorFill=this.emProcessorFill||`#edb3f6`,this.emProcessorStroke=this.emProcessorStroke||`#b88cbf`,this.emReadModelFill=this.emReadModelFill||`#d3f1a2`,this.emReadModelStroke=this.emReadModelStroke||`#a3b732`,this.emCommandFill=this.emCommandFill||`#bcd6fe`,this.emCommandStroke=this.emCommandStroke||`#679ac3`,this.emEventFill=this.emEventFill||`#ffb778`,this.emEventStroke=this.emEventStroke||`#c19a0f`,this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||`rgb(250,250,250)`,this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||`rgb(240,240,240)`,this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Nu=N(e=>{let t=new Mu;return t.calculate(e),t},`getThemeVariables`),Pu=class{static{N(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=2,this.primaryBorderColor=V(this.primaryColor,this.darkMode),this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#000000`,this.stateBorder=`#000000`,this.useGradient=!0,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`drop-shadow( 0px 1px 2px rgba(0, 0, 0, 0.25));`,this.tertiaryColor=`#ffffff`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor;let e=`#ECECFE`,t=`#E9E9F1`,n=R(e,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||I(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||e,this.cScale1=this.cScale1||t,this.cScale2=this.cScale2||n,this.cScale3=this.cScale3||R(e,{h:30}),this.cScale4=this.cScale4||R(e,{h:60}),this.cScale5=this.cScale5||R(e,{h:90}),this.cScale6=this.cScale6||R(e,{h:120}),this.cScale7=this.cScale7||R(e,{h:150}),this.cScale8=this.cScale8||R(e,{h:210,l:150}),this.cScale9=this.cScale9||R(e,{h:270}),this.cScale10=this.cScale10||R(e,{h:300}),this.cScale11=this.cScale11||R(e,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||e,this.fillType1=this.fillType1||t,this.fillType2=this.fillType2||R(e,{h:64}),this.fillType3=this.fillType3||R(t,{h:64}),this.fillType4=this.fillType4||R(e,{h:-64}),this.fillType5=this.fillType5||R(t,{h:-64}),this.fillType6=this.fillType6||R(e,{h:128}),this.fillType7=this.fillType7||R(t,{h:128}),this.pie1=this.pie1||e,this.pie2=this.pie2||t,this.pie3=this.pie3||n,this.pie4=this.pie4||R(e,{l:-10}),this.pie5=this.pie5||R(t,{l:-10}),this.pie6=this.pie6||R(n,{l:-10}),this.pie7=this.pie7||R(e,{h:60,l:-10}),this.pie8=this.pie8||R(e,{h:-60,l:-10}),this.pie9=this.pie9||R(e,{h:120,l:0}),this.pie10=this.pie10||R(e,{h:60,l:-20}),this.pie11=this.pie11||R(e,{h:-60,l:-20}),this.pie12=this.pie12||R(e,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||e,this.quadrant2Fill=this.quadrant2Fill||R(e,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(e,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(e,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||e,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||e,this.git1=this.git1||t,this.git2=this.git2||n,this.git3=this.git3||R(e,{h:-30}),this.git4=this.git4||R(e,{h:-60}),this.git5=this.git5||R(e,{h:-90}),this.git6=this.git6||R(e,{h:60}),this.git7=this.git7||R(e,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Fu=N(e=>{let t=new Pu;return t.calculate(e),t},`getThemeVariables`),Iu=class{static{N(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=I(this.primaryColor,16),this.tertiaryColor=R(this.primaryColor,{h:-160}),this.primaryBorderColor=z(this.background),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.tertiaryColor),this.mainBkg=`#2a2020`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=I(z(`#323D47`),10),this.border1=`#ccc`,this.border2=Hc(255,255,255,.25),this.arrowheadColor=z(this.background),this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#181818`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=1,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.useGradient=!0,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,0.2))`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||I(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||R(this.primaryColor,{h:30}),this.cScale4=this.cScale4||R(this.primaryColor,{h:60}),this.cScale5=this.cScale5||R(this.primaryColor,{h:90}),this.cScale6=this.cScale6||R(this.primaryColor,{h:120}),this.cScale7=this.cScale7||R(this.primaryColor,{h:150}),this.cScale8=this.cScale8||R(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||R(this.primaryColor,{h:270}),this.cScale10=this.cScale10||R(this.primaryColor,{h:300}),this.cScale11=this.cScale11||R(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;let e=this.darkMode?-4:-1;for(let t=0;t<5;t++)this[`surface`+t]=this[`surface`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(5+t*3)}),this[`surfacePeer`+t]=this[`surfacePeer`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(8+t*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||R(this.primaryColor,{h:64}),this.fillType3=this.fillType3||R(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||R(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||R(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||R(this.primaryColor,{h:128}),this.fillType7=this.fillType7||R(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||R(this.primaryColor,{l:-10}),this.pie5=this.pie5||R(this.secondaryColor,{l:-10}),this.pie6=this.pie6||R(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||R(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||R(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||R(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||R(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||R(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||R(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||`#0b0000`,this.git1=this.git1||`#4d1037`,this.git2=this.git2||`#3f5258`,this.git3=this.git3||`#4f2f1b`,this.git4=this.git4||`#6e0a0a`,this.git5=this.git5||`#3b0048`,this.git6=this.git6||`#995a01`,this.git7=this.git7||`#154706`,this.gitDarkMode=!0,this.gitDarkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Lu=N(e=>{let t=new Iu;return t.calculate(e),t},`getThemeVariables`),Ru=class{static{N(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#28253D`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=V(`#28253D`,this.darkMode),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#28253D`,this.stateBorder=`#28253D`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.tertiaryColor=`#ffffff`,this.clusterBkg=`#F9F9FB`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.actorBorder=`#28253D`,this.filterColor=`#000000`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#28253D`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#FEF9C3`,this.noteTextColor=this.noteTextColor||`#28253D`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.noteFontWeight=600,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor;let e=`#ECECFE`,t=`#E9E9F1`,n=R(e,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||I(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.compositeTitleBackground=`#F9F9FB`,this.altBackground=`#F9F9FB`,this.stateEdgeLabelBackground=`#FFFFFF`,this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=this.mainBkg;if(this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||e,this.fillType1=this.fillType1||t,this.fillType2=this.fillType2||R(e,{h:64}),this.fillType3=this.fillType3||R(t,{h:64}),this.fillType4=this.fillType4||R(e,{h:-64}),this.fillType5=this.fillType5||R(t,{h:-64}),this.fillType6=this.fillType6||R(e,{h:128}),this.fillType7=this.fillType7||R(t,{h:128}),this.pie1=this.pie1||e,this.pie2=this.pie2||t,this.pie3=this.pie3||n,this.pie4=this.pie4||R(e,{l:-10}),this.pie5=this.pie5||R(t,{l:-10}),this.pie6=this.pie6||R(n,{l:-10}),this.pie7=this.pie7||R(e,{h:60,l:-10}),this.pie8=this.pie8||R(e,{h:-60,l:-10}),this.pie9=this.pie9||R(e,{h:120,l:0}),this.pie10=this.pie10||R(e,{h:60,l:-20}),this.pie11=this.pie11||R(e,{h:-60,l:-20}),this.pie12=this.pie12||R(e,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||e,this.quadrant2Fill=this.quadrant2Fill||R(e,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(e,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(e,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||e,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground=`#FFFFFF`,this.git0=this.git0||e,this.git1=this.git1||t,this.git2=this.git2||n,this.git3=this.git3||R(e,{h:-30}),this.git4=this.git4||R(e,{h:-60}),this.git5=this.git5||R(e,{h:-90}),this.git6=this.git6||R(e,{h:60}),this.git7=this.git7||R(e,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.commitLineColor=this.commitLineColor??`#BDBCCC`,this.erEdgeLabelBackground=`#FFFFFF`,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},zu=N(e=>{let t=new Ru;return t.calculate(e),t},`getThemeVariables`),Bu=class{static{N(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=I(this.primaryColor,16),this.tertiaryColor=R(this.primaryColor,{h:-160}),this.primaryBorderColor=z(this.background),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.tertiaryColor),this.mainBkg=`#111113`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=I(z(`#323D47`),10),this.border1=`#ccc`,this.border2=Hc(255,255,255,.25),this.arrowheadColor=z(this.background),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#111113`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??`#FEF9C3`,this.noteTextColor=this.noteTextColor??`#28253D`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#FFFFFF`,this.stateBorder=`#FFFFFF`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.clusterBkg=`#1E1A2E`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.filterColor=`#FFFFFF`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#FFFFFF`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#FFFFFF`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=`#FFFFFF`,this.signalColor=`#FFFFFF`,this.labelBoxBorderColor=`#BDBCCC`,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||I(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.compositeBackground=`#16141F`,this.altBackground=`#16141F`,this.compositeTitleBackground=`#16141F`,this.stateEdgeLabelBackground=`#16141F`,this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||R(this.primaryColor,{h:30}),this.cScale4=this.cScale4||R(this.primaryColor,{h:60}),this.cScale5=this.cScale5||R(this.primaryColor,{h:90}),this.cScale6=this.cScale6||R(this.primaryColor,{h:120}),this.cScale7=this.cScale7||R(this.primaryColor,{h:150}),this.cScale8=this.cScale8||R(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||R(this.primaryColor,{h:270}),this.cScale10=this.cScale10||R(this.primaryColor,{h:300}),this.cScale11=this.cScale11||R(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScale`+e]=L(this[`cScale`+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;let e=this.darkMode?-4:-1;for(let t=0;t<5;t++)this[`surface`+t]=this[`surface`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(5+t*3)}),this[`surfacePeer`+t]=this[`surfacePeer`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(8+t*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||R(this.primaryColor,{h:64}),this.fillType3=this.fillType3||R(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||R(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||R(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||R(this.primaryColor,{h:128}),this.fillType7=this.fillType7||R(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||R(this.primaryColor,{l:-10}),this.pie5=this.pie5||R(this.secondaryColor,{l:-10}),this.pie6=this.pie6||R(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||R(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||R(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||R(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||R(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||R(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||R(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground=`#16141F`,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||R(this.primaryColor,{h:-30}),this.git4=this.git4||R(this.primaryColor,{h:-60}),this.git5=this.git5||R(this.primaryColor,{h:-90}),this.git6=this.git6||R(this.primaryColor,{h:60}),this.git7=this.git7||R(this.primaryColor,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.commitLineColor=this.commitLineColor??`#BDBCCC`,this.erEdgeLabelBackground=`#16141F`,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Vu=N(e=>{let t=new Bu;return t.calculate(e),t},`getThemeVariables`),Hu=class{static{N(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#28253D`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=V(this.primaryColor,this.darkMode),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#28253D`,this.stateBorder=`#28253D`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.tertiaryColor=`#ffffff`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.actorBorder=`#28253D`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.borderColorArray=[`#E879F9`,`#2DD4BF`,`#FB923C`,`#22D3EE`,`#4ADE80`,`#A78BFA`,`#F87171`,`#FACC15`,`#818CF8`,`#A3E635 `,`#38BDF8`,`#FB7185`],this.bkgColorArray=[`#FDF4FF`,`#F0FDFA`,`#FFF7ED`,`#ECFEFF`,`#F0FDF4`,`#F5F3FF`,`#FEF2F2`,`#FEFCE8`,`#EEF2FF`,`#F7FEE7`,`#F0F9FF`,`#FFF1F2`],this.filterColor=`#000000`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#28253D`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#28253D`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor;let e=`#ECECFE`,t=`#E9E9F1`,n=R(e,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||I(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||`#f4a8ff`,this.cScale1=this.cScale1||`#46ecd5`,this.cScale2=this.cScale2||`#ffb86a`,this.cScale3=this.cScale3||`#dab2ff`,this.cScale4=this.cScale4||`#7bf1a8`,this.cScale5=this.cScale5||`#c4b4ff`,this.cScale6=this.cScale6||`#ffa2a2`,this.cScale7=this.cScale7||`#ffdf20`,this.cScale8=this.cScale8||`#a3b3ff`,this.cScale9=this.cScale9||`#bbf451`,this.cScale10=this.cScale10||`#74d4ff`,this.cScale11=this.cScale11||`#ffa1ad`;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=this[`cScaleLabel`+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this[`surface`+e]=this[`surface`+e]||R(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this[`surfacePeer`+e]=this[`surfacePeer`+e]||R(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||e,this.fillType1=this.fillType1||t,this.fillType2=this.fillType2||R(e,{h:64}),this.fillType3=this.fillType3||R(t,{h:64}),this.fillType4=this.fillType4||R(e,{h:-64}),this.fillType5=this.fillType5||R(t,{h:-64}),this.fillType6=this.fillType6||R(e,{h:128}),this.fillType7=this.fillType7||R(t,{h:128}),this.pie1=this.pie1||e,this.pie2=this.pie2||t,this.pie3=this.pie3||n,this.pie4=this.pie4||R(e,{l:-10}),this.pie5=this.pie5||R(t,{l:-10}),this.pie6=this.pie6||R(n,{l:-10}),this.pie7=this.pie7||R(e,{h:60,l:-10}),this.pie8=this.pie8||R(e,{h:-60,l:-10}),this.pie9=this.pie9||R(e,{h:120,l:0}),this.pie10=this.pie10||R(e,{h:60,l:-20}),this.pie11=this.pie11||R(e,{h:-60,l:-20}),this.pie12=this.pie12||R(e,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||e,this.quadrant2Fill=this.quadrant2Fill||R(e,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(e,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(e,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||e,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||e,this.git1=this.git1||t,this.git2=this.git2||n,this.git3=this.git3||R(e,{h:-30}),this.git4=this.git4||R(e,{h:-60}),this.git5=this.git5||R(e,{h:-90}),this.git6=this.git6||R(e,{h:60}),this.git7=this.git7||R(e,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLineColor=this.commitLineColor??`#BDBCCC`,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.fontWeight=600,this.erEdgeLabelBackground=`#FFFFFF`,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Uu=N(e=>{let t=new Hu;return t.calculate(e),t},`getThemeVariables`),Wu=class{static{N(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=I(this.primaryColor,16),this.tertiaryColor=R(this.primaryColor,{h:-160}),this.primaryBorderColor=z(this.background),this.secondaryBorderColor=V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=V(this.tertiaryColor,this.darkMode),this.primaryTextColor=z(this.primaryColor),this.secondaryTextColor=z(this.secondaryColor),this.tertiaryTextColor=z(this.tertiaryColor),this.mainBkg=`#111113`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=I(z(`#323D47`),10),this.border1=`#ccc`,this.border2=Hc(255,255,255,.25),this.arrowheadColor=z(this.background),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#111113`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??`#FEF9C3`,this.noteTextColor=this.noteTextColor??`#28253D`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#FFFFFF`,this.stateBorder=`#FFFFFF`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.clusterBkg=`#1E1A2E`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.borderColorArray=[`#E879F9`,`#2DD4BF`,`#FB923C`,`#22D3EE`,`#4ADE80`,`#A78BFA`,`#F87171`,`#FACC15`,`#818CF8`,`#A3E635 `,`#38BDF8`,`#FB7185`],this.bkgColorArray=[],this.filterColor=`#FFFFFF`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#FFFFFF`),this.secondaryColor=this.secondaryColor||R(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||R(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||V(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||V(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||V(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||V(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#FFFFFF`,this.secondaryTextColor=this.secondaryTextColor||z(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||z(this.tertiaryColor),this.lineColor=this.lineColor||z(this.background),this.arrowheadColor=this.arrowheadColor||z(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=`#FFFFFF`,this.signalColor=`#FFFFFF`,this.labelBoxBorderColor=`#BDBCCC`,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||L(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||z(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.rootLabelColor=`#FFFFFF`,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||I(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||`#f4a8ff`,this.cScale1=this.cScale1||`#46ecd5`,this.cScale2=this.cScale2||`#ffb86a`,this.cScale3=this.cScale3||`#dab2ff`,this.cScale4=this.cScale4||`#7bf1a8`,this.cScale5=this.cScale5||`#c4b4ff`,this.cScale6=this.cScale6||`#ffa2a2`,this.cScale7=this.cScale7||`#ffdf20`,this.cScale8=this.cScale8||`#a3b3ff`,this.cScale9=this.cScale9||`#bbf451`,this.cScale10=this.cScale10||`#74d4ff`,this.cScale11=this.cScale11||`#ffa1ad`;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleInv`+e]=this[`cScaleInv`+e]||z(this[`cScale`+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this.darkMode?this[`cScalePeer`+e]=this[`cScalePeer`+e]||I(this[`cScale`+e],10):this[`cScalePeer`+e]=this[`cScalePeer`+e]||L(this[`cScale`+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this[`cScaleLabel`+e]=L(this[`cScale`+e],75);let e=this.darkMode?-4:-1;for(let t=0;t<5;t++)this[`surface`+t]=this[`surface`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(5+t*3)}),this[`surfacePeer`+t]=this[`surfacePeer`+t]||R(this.mainBkg,{h:180,s:-15,l:e*(8+t*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||R(this.primaryColor,{h:64}),this.fillType3=this.fillType3||R(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||R(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||R(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||R(this.primaryColor,{h:128}),this.fillType7=this.fillType7||R(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||R(this.primaryColor,{l:-10}),this.pie5=this.pie5||R(this.secondaryColor,{l:-10}),this.pie6=this.pie6||R(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||R(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||R(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||R(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||R(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||R(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||R(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||`25px`,this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||`17px`,this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||`17px`,this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||`black`,this.pieStrokeWidth=this.pieStrokeWidth||`2px`,this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||`2px`,this.pieOuterStrokeColor=this.pieOuterStrokeColor||`black`,this.pieOpacity=this.pieOpacity||`0.7`,this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||R(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||R(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||R(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||R(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||R(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||R(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Gc(this.quadrant1Fill)?I(this.quadrant1Fill):L(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||`#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0`},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||`1`,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?L(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||R(this.primaryColor,{h:-30}),this.git4=this.git4||R(this.primaryColor,{h:-60}),this.git5=this.git5||R(this.primaryColor,{h:-90}),this.git6=this.git6||R(this.primaryColor,{h:60}),this.git7=this.git7||R(this.primaryColor,{h:120}),this.darkMode?(this.git0=I(this.git0,25),this.git1=I(this.git1,25),this.git2=I(this.git2,25),this.git3=I(this.git3,25),this.git4=I(this.git4,25),this.git5=I(this.git5,25),this.git6=I(this.git6,25),this.git7=I(this.git7,25)):(this.git0=L(this.git0,25),this.git1=L(this.git1,25),this.git2=L(this.git2,25),this.git3=L(this.git3,25),this.git4=L(this.git4,25),this.git5=L(this.git5,25),this.git6=L(this.git6,25),this.git7=L(this.git7,25)),this.gitInv0=this.gitInv0||z(this.git0),this.gitInv1=this.gitInv1||z(this.git1),this.gitInv2=this.gitInv2||z(this.git2),this.gitInv3=this.gitInv3||z(this.git3),this.gitInv4=this.gitInv4||z(this.git4),this.gitInv5=this.gitInv5||z(this.git5),this.gitInv6=this.gitInv6||z(this.git6),this.gitInv7=this.gitInv7||z(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?`black`:this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||`10px`,this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||`10px`,this.commitLineColor=this.commitLineColor??`#BDBCCC`,this.fontWeight=600,this.erEdgeLabelBackground=`#16141F`,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Su,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Cu}calculate(e){if(typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Gu={base:{getThemeVariables:Tu},dark:{getThemeVariables:Du},default:{getThemeVariables:ku},forest:{getThemeVariables:ju},neutral:{getThemeVariables:Nu},neo:{getThemeVariables:Fu},"neo-dark":{getThemeVariables:Lu},redux:{getThemeVariables:zu},"redux-dark":{getThemeVariables:Vu},"redux-color":{getThemeVariables:Uu},"redux-dark-color":{getThemeVariables:N(e=>{let t=new Wu;return t.calculate(e),t},`getThemeVariables`)}},Ku={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:null,nodeSpacing:50,rankSpacing:50,curve:`basis`,padding:15,defaultRenderer:`dagre-wrapper`,wrappingWidth:200,inheritDir:!1},swimlane:{useMaxWidth:!0,lineHops:`arc`,ignoreCrossLaneEdges:!0,optimizeRanksByCrossings:!0,automaticLaneOrdering:!1},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:`"Open Sans", sans-serif`,actorFontWeight:400,noteFontSize:14,noteFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,noteFontWeight:400,noteAlign:`center`,messageFontSize:16,messageFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:`%Y-%m-%d`,topAxis:!1,displayMode:``,weekday:`sunday`},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:`"Open Sans", sans-serif`,taskMargin:50,activationWidth:10,textPlacement:`fo`,actorColours:[`#8FBC8F`,`#7CFC00`,`#00FFFF`,`#20B2AA`,`#B0E0E6`,`#FFFFE0`],sectionFills:[`#191970`,`#8B008B`,`#4B0082`,`#2F4F4F`,`#800000`,`#8B4513`,`#00008B`],sectionColours:[`#fff`],titleColor:``,titleFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,titleFontSize:`4ex`},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:`dagre-wrapper`,htmlLabels:!1,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:`20`,compositTitleSize:35,radius:5,defaultRenderer:`dagre-wrapper`},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:`TB`,minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:`gray`,fill:`honeydew`,fontSize:12},pie:{useMaxWidth:!0,textPosition:.75,donutHole:0,legendPosition:`right`,highlightSlice:``},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:`top`,yAxisPosition:`left`,quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showDataLabelOutsideBar:!1,showTitle:!0,showLegend:!0,legendFontSize:14,legendPadding:10,xAxis:{$ref:`#/$defs/XYChartAxisConfig`,showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},yAxis:{$ref:`#/$defs/XYChartAxisConfig`,showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},chartOrientation:`vertical`,plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:`#f9f9f9`,text_color:`#333`,rect_border_size:`0.5px`,rect_border_color:`#bbb`,rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:`cose-bilkent`},ishikawa:{useMaxWidth:!0,diagramPadding:20},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:``},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:`"Open Sans", sans-serif`,taskMargin:50,activationWidth:10,textPlacement:`fo`,actorColours:[`#8FBC8F`,`#7CFC00`,`#00FFFF`,`#20B2AA`,`#B0E0E6`,`#FFFFE0`],sectionFills:[`#191970`,`#8B008B`,`#4B0082`,`#2F4F4F`,`#800000`,`#8B4513`,`#00008B`],sectionColours:[`#fff`],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:`main`,mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:`"Open Sans", sans-serif`,personFontWeight:`normal`,external_personFontSize:14,external_personFontFamily:`"Open Sans", sans-serif`,external_personFontWeight:`normal`,systemFontSize:14,systemFontFamily:`"Open Sans", sans-serif`,systemFontWeight:`normal`,external_systemFontSize:14,external_systemFontFamily:`"Open Sans", sans-serif`,external_systemFontWeight:`normal`,system_dbFontSize:14,system_dbFontFamily:`"Open Sans", sans-serif`,system_dbFontWeight:`normal`,external_system_dbFontSize:14,external_system_dbFontFamily:`"Open Sans", sans-serif`,external_system_dbFontWeight:`normal`,system_queueFontSize:14,system_queueFontFamily:`"Open Sans", sans-serif`,system_queueFontWeight:`normal`,external_system_queueFontSize:14,external_system_queueFontFamily:`"Open Sans", sans-serif`,external_system_queueFontWeight:`normal`,boundaryFontSize:14,boundaryFontFamily:`"Open Sans", sans-serif`,boundaryFontWeight:`normal`,messageFontSize:12,messageFontFamily:`"Open Sans", sans-serif`,messageFontWeight:`normal`,containerFontSize:14,containerFontFamily:`"Open Sans", sans-serif`,containerFontWeight:`normal`,external_containerFontSize:14,external_containerFontFamily:`"Open Sans", sans-serif`,external_containerFontWeight:`normal`,container_dbFontSize:14,container_dbFontFamily:`"Open Sans", sans-serif`,container_dbFontWeight:`normal`,external_container_dbFontSize:14,external_container_dbFontFamily:`"Open Sans", sans-serif`,external_container_dbFontWeight:`normal`,container_queueFontSize:14,container_queueFontFamily:`"Open Sans", sans-serif`,container_queueFontWeight:`normal`,external_container_queueFontSize:14,external_container_queueFontFamily:`"Open Sans", sans-serif`,external_container_queueFontWeight:`normal`,componentFontSize:14,componentFontFamily:`"Open Sans", sans-serif`,componentFontWeight:`normal`,external_componentFontSize:14,external_componentFontFamily:`"Open Sans", sans-serif`,external_componentFontWeight:`normal`,component_dbFontSize:14,component_dbFontFamily:`"Open Sans", sans-serif`,component_dbFontWeight:`normal`,external_component_dbFontSize:14,external_component_dbFontFamily:`"Open Sans", sans-serif`,external_component_dbFontWeight:`normal`,component_queueFontSize:14,component_queueFontFamily:`"Open Sans", sans-serif`,component_queueFontWeight:`normal`,external_component_queueFontSize:14,external_component_queueFontFamily:`"Open Sans", sans-serif`,external_component_queueFontWeight:`normal`,wrap:!0,wrapPadding:10,person_bg_color:`#08427B`,person_border_color:`#073B6F`,external_person_bg_color:`#686868`,external_person_border_color:`#8A8A8A`,system_bg_color:`#1168BD`,system_border_color:`#3C7FC0`,system_db_bg_color:`#1168BD`,system_db_border_color:`#3C7FC0`,system_queue_bg_color:`#1168BD`,system_queue_border_color:`#3C7FC0`,external_system_bg_color:`#999999`,external_system_border_color:`#8A8A8A`,external_system_db_bg_color:`#999999`,external_system_db_border_color:`#8A8A8A`,external_system_queue_bg_color:`#999999`,external_system_queue_border_color:`#8A8A8A`,container_bg_color:`#438DD5`,container_border_color:`#3C7FC0`,container_db_bg_color:`#438DD5`,container_db_border_color:`#3C7FC0`,container_queue_bg_color:`#438DD5`,container_queue_border_color:`#3C7FC0`,external_container_bg_color:`#B3B3B3`,external_container_border_color:`#A6A6A6`,external_container_db_bg_color:`#B3B3B3`,external_container_db_border_color:`#A6A6A6`,external_container_queue_bg_color:`#B3B3B3`,external_container_queue_border_color:`#A6A6A6`,component_bg_color:`#85BBF0`,component_border_color:`#78A8D8`,component_db_bg_color:`#85BBF0`,component_db_border_color:`#78A8D8`,component_queue_bg_color:`#85BBF0`,component_queue_border_color:`#78A8D8`,external_component_bg_color:`#CCCCCC`,external_component_border_color:`#BFBFBF`,external_component_db_bg_color:`#CCCCCC`,external_component_db_border_color:`#BFBFBF`,external_component_queue_bg_color:`#CCCCCC`,external_component_queue_border_color:`#BFBFBF`},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:`gradient`,nodeAlignment:`justify`,showValues:!0,prefix:``,suffix:``,nodeWidth:10,nodePadding:12,labelStyle:`legacy`},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},treeView:{useMaxWidth:!0,rowIndent:10,paddingX:5,paddingY:5,lineThickness:1,showIcons:!1,defaultIconPack:``,filenameIcons:{},extensionIcons:{}},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16,randomize:!1,nodeSeparation:75,idealEdgeLengthMultiplier:1.5,edgeElasticity:.45,numIter:2500,seed:1},eventmodeling:{useMaxWidth:!0,padding:30,rowHeight:32},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},venn:{useMaxWidth:!0,width:800,height:450,padding:8,useDebugLayout:!1},cynefin:{useMaxWidth:!0,width:800,height:600,padding:40,showDomainDescriptions:!0,boundaryAmplitude:8,seed:0},theme:`default`,look:`classic`,handDrawnSeed:0,layout:`dagre`,maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:`"trebuchet ms", verdana, arial, sans-serif;`,logLevel:5,securityLevel:`strict`,startOnLoad:!0,arrowMarkerAbsolute:!1,secure:[`secure`,`securityLevel`,`startOnLoad`,`maxTextSize`,`suppressErrorRendering`,`maxEdges`],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},qu={...Ku,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:`BRANDES_KOEPF`,nodePlacementAlignment:`NONE`,forceNodeModelOrder:!1,considerModelOrder:`NODES_AND_EDGES`,keepEntryNodeOnTop:!1},themeCSS:void 0,themeVariables:Gu.default.getThemeVariables(),sequence:{...Ku.sequence,messageFont:N(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},`messageFont`),noteFont:N(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},`noteFont`),actorFont:N(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},`actorFont`)},class:{defaultRenderer:`dagre-wrapper`,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},gantt:{...Ku.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Ku.c4,useWidth:void 0,personFont:N(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},`personFont`),flowchart:{...Ku.flowchart,inheritDir:!1},external_personFont:N(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},`external_personFont`),systemFont:N(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},`systemFont`),external_systemFont:N(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},`external_systemFont`),system_dbFont:N(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},`system_dbFont`),external_system_dbFont:N(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},`external_system_dbFont`),system_queueFont:N(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},`system_queueFont`),external_system_queueFont:N(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},`external_system_queueFont`),containerFont:N(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},`containerFont`),external_containerFont:N(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},`external_containerFont`),container_dbFont:N(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},`container_dbFont`),external_container_dbFont:N(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},`external_container_dbFont`),container_queueFont:N(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},`container_queueFont`),external_container_queueFont:N(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},`external_container_queueFont`),componentFont:N(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},`componentFont`),external_componentFont:N(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},`external_componentFont`),component_dbFont:N(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},`component_dbFont`),external_component_dbFont:N(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},`external_component_dbFont`),component_queueFont:N(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},`component_queueFont`),external_component_queueFont:N(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},`external_component_queueFont`),boundaryFont:N(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},`boundaryFont`),messageFont:N(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},`messageFont`)},pie:{...Ku.pie,useWidth:984},xyChart:{...Ku.xyChart,useWidth:void 0},requirement:{...Ku.requirement,useWidth:void 0},packet:{...Ku.packet},eventmodeling:{...Ku.eventmodeling},treeView:{...Ku.treeView,useWidth:void 0},radar:{...Ku.radar},railroad:{...Ku.railroad,fontSize:void 0,fontFamily:void 0,terminalFill:void 0,terminalStroke:void 0,terminalTextColor:void 0,nonTerminalFill:void 0,nonTerminalStroke:void 0,nonTerminalTextColor:void 0,lineColor:void 0,markerFill:void 0,commentFill:void 0,commentStroke:void 0,commentTextColor:void 0,specialFill:void 0,specialStroke:void 0,ruleNameColor:void 0},ishikawa:{...Ku.ishikawa},sankey:{...Ku.sankey,nodeColors:void 0},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:`,`},venn:{...Ku.venn},cynefin:{...Ku.cynefin}},Ju=N((e,t=``)=>Object.keys(e).reduce((n,r)=>Array.isArray(e[r])?n:typeof e[r]==`object`&&e[r]!==null?[...n,t+r,...Ju(e[r],``)]:[...n,t+r],[]),`keyify`),Yu=new Set(Ju(qu,``)),Xu=qu,Zu={nodeColors:/^#[\da-f]{3,8}$|^rgb\([\d\s%,.]+\)$|^hsl\([\d\s%,.]+\)$|^[a-z]+$/i,filenameIcons:/^[\w-]+(?::[\w-]+)?$/,extensionIcons:/^[\w-]+(?::[\w-]+)?$/},Qu=N((e,t)=>{for(let n of Object.keys(e)){let r=e[n];(n.startsWith(`__`)||n.includes(`proto`)||n.includes(`constr`)||typeof r!=`string`||!t.test(r))&&(P.debug(`sanitize deleting dictionary entry:`,n,r),delete e[n])}},`sanitizeDictionaryConfig`),$u=N(e=>{if(P.debug(`sanitizeDirective called with`,e),typeof e==`object`&&e){if(Array.isArray(e)){e.forEach(e=>$u(e));return}for(let t of Object.keys(e)){if(P.debug(`Checking key`,t),t.startsWith(`__`)||t.includes(`proto`)||t.includes(`constr`)||!Yu.has(t)||e[t]==null){P.debug(`sanitize deleting key: `,t),delete e[t];continue}if(typeof e[t]==`object`){let n=Zu[t];n?Qu(e[t],n):(P.debug(`sanitizing object`,t),$u(e[t]));continue}for(let n of[`themeCSS`,`fontFamily`,`altFontFamily`])t.includes(n)&&(P.debug(`sanitizing css option`,t),e[t]=ed(e[t]))}if(e.themeVariables)for(let t of Object.keys(e.themeVariables)){let n=e.themeVariables[t];n?.match&&!n.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]=``)}P.debug(`After sanitization`,e)}},`sanitizeDirective`),ed=N(e=>{let t=0,n=0;for(let r of e){if(t<n)return`{ /* ERROR: Unbalanced CSS */ }`;r===`{`?t++:r===`}`&&n++}return t===n?e:`{ /* ERROR: Unbalanced CSS */ }`},`sanitizeCss`),td=Object.freeze(Xu),nd=N(e=>!(e===!1||[`false`,`null`,`0`].includes(String(e).trim().toLowerCase())),`evaluate`),rd=xu({},td),id,ad=[],od=xu({},td),sd=N((e,t)=>{let n=xu({},e),r={};for(let e of t)md(e),r=xu(r,e);if(n=xu(n,r),r.theme&&r.theme in Gu){let e=xu(xu({},id).themeVariables||{},r.themeVariables);n.theme&&n.theme in Gu&&(n.themeVariables=Gu[n.theme].getThemeVariables(e))}return od=n,bd(od),od},`updateCurrentConfig`),cd=N(e=>(rd=xu({},td),rd=xu(rd,e),e.theme&&Gu[e.theme]&&(rd.themeVariables=Gu[e.theme].getThemeVariables(e.themeVariables)),sd(rd,ad),rd),`setSiteConfig`),ld=N(e=>{id=xu({},e)},`saveConfigFromInitialize`),ud=N(e=>(rd=xu(rd,e),sd(rd,ad),rd),`updateSiteConfig`),dd=N(()=>xu({},rd),`getSiteConfig`),fd=N(e=>(sd(od,[e]),pd()),`setConfig`),pd=N(()=>xu({},od),`getConfig`),md=N(e=>{e&&([`secure`,...rd.secure??[]].forEach(t=>{Object.hasOwn(e,t)&&(P.debug(`Denied attempt to modify a secure key ${t}`,e[t]),delete e[t])}),Object.keys(e).forEach(t=>{t.startsWith(`__`)&&delete e[t]}),Object.keys(e).forEach(t=>{typeof e[t]==`string`&&(e[t].includes(`<`)||e[t].includes(`>`)||e[t].includes(`url(data:`))&&delete e[t],typeof e[t]==`object`&&md(e[t])}))},`sanitize`),hd=N(e=>{$u(e),e.fontFamily&&!e.themeVariables?.fontFamily&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),ad.push(e),sd(rd,ad)},`addDirective`),gd=N((e=rd)=>{ad=[],sd(e,ad)},`reset`),_d={LAZY_LOAD_DEPRECATED:`The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.`,FLOWCHART_HTML_LABELS_DEPRECATED:`flowchart.htmlLabels is deprecated. Please use global htmlLabels instead.`},vd={},yd=N(e=>{vd[e]||(P.warn(_d[e]),vd[e]=!0)},`issueWarning`),bd=N(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&yd(`LAZY_LOAD_DEPRECATED`)},`checkConfig`),xd=N(()=>{let e={};id&&(e=xu(e,id));for(let t of ad)e=xu(e,t);return e},`getUserDefinedConfig`),Sd=N(e=>(e.flowchart?.htmlLabels!=null&&yd(`FLOWCHART_HTML_LABELS_DEPRECATED`),nd(e.htmlLabels??e.flowchart?.htmlLabels??!0)),`getEffectiveHtmlLabels`),Cd=/^([^\S\n\r]*)-{3}\s*[\n\r](.*?)[\n\r]\1-{3}\s*[\n\r]+/s,wd=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Td=/\s*%%.*\n/gm,Ed=class extends Error{static{N(this,`UnknownDiagramError`)}constructor(e){super(e),this.name=`UnknownDiagramError`}},Dd={},Od=N(function(e,t){e=e.replace(Cd,``).replace(wd,``).replace(Td,`
|
|
5
|
-
`);for(let[n,{detector:r}]of Object.entries(Dd))if(r(e,t))return n;throw new Ed(`No diagram type detected matching given configuration for text: ${e}`)},`detectType`),kd=N((...e)=>{for(let{id:t,detector:n,loader:r}of e)Ad(t,n,r)},`registerLazyLoadedDiagrams`),Ad=N((e,t,n)=>{Dd[e]&&P.warn(`Detector with key ${e} already exists. Overwriting.`),Dd[e]={detector:t,loader:n},P.debug(`Detector with key ${e} added${n?` with loader`:``}`)},`addDetector`),jd=N(e=>Dd[e].loader,`getDiagramLoader`),Md=/<br\s*\/?>/gi,Nd=N(e=>e?Ud(e).replace(/\\n/g,`#br#`).split(`#br#`):[``],`getRows`),Pd=(()=>{let e=!1;return()=>{e||=(Fd(),!0)}})();function Fd(){let e=`data-temp-href-target`;yu.addHook(`beforeSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(`target`)&&t.setAttribute(e,t.getAttribute(`target`)??``)}),yu.addHook(`afterSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(e)&&(t.setAttribute(`target`,t.getAttribute(e)??``),t.removeAttribute(e),t.getAttribute(`target`)===`_blank`&&t.setAttribute(`rel`,`noopener`))})}N(Fd,`setupDompurifyHooks`);var Id=N(e=>(Pd(),yu.sanitize(e)),`removeScript`),Ld=N((e,t)=>{if(Sd(t)){let n=t.securityLevel;n===`antiscript`||n===`strict`||n===`sandbox`?e=Id(e):n!==`loose`&&(e=Ud(e),e=e.replace(/</g,`<`).replace(/>/g,`>`),e=e.replace(/=/g,`=`),e=Hd(e))}return e},`sanitizeMore`),Rd=N((e,t)=>e&&(e=t.dompurifyConfig?yu.sanitize(Ld(e,t),t.dompurifyConfig).toString():yu.sanitize(Ld(e,t),{FORBID_TAGS:[`style`]}).toString(),e),`sanitizeText`),zd=N((e,t)=>typeof e==`string`?Rd(e,t):e.flat().map(e=>Rd(e,t)),`sanitizeTextOrArray`),Bd=N(e=>Md.test(e),`hasBreaks`),Vd=N(e=>e.split(Md),`splitBreaks`),Hd=N(e=>e.replace(/#br#/g,`<br/>`),`placeholderToBreak`),Ud=N(e=>e.replace(Md,`#br#`),`breakToPlaceholder`),Wd=N(e=>{let t=``;return e&&(t=window.location.protocol+`//`+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},`getUrl`),Gd=N(function(...e){let t=e.filter(e=>!isNaN(e));return Math.max(...t)},`getMax`),Kd=N(function(...e){let t=e.filter(e=>!isNaN(e));return Math.min(...t)},`getMin`),qd=N(function(e){let t=e.split(/(,)/),n=[];for(let e=0;e<t.length;e++){let r=t[e];if(r===`,`&&e>0&&e+1<t.length){let i=t[e-1],a=t[e+1];Yd(i,a)&&(r=i+`,`+a,e++,n.pop())}n.push(Xd(r))}return n.join(``)},`parseGenericTypes`),Jd=N((e,t)=>Math.max(0,e.split(t).length-1),`countOccurrence`),Yd=N((e,t)=>{let n=Jd(e,`~`),r=Jd(t,`~`);return n===1&&r===1},`shouldCombineSets`),Xd=N(e=>{let t=Jd(e,`~`),n=!1;if(t<=1)return e;t%2!=0&&e.startsWith(`~`)&&(e=e.substring(1),n=!0);let r=[...e],i=r.indexOf(`~`),a=r.lastIndexOf(`~`);for(;i!==-1&&a!==-1&&i!==a;)r[i]=`<`,r[a]=`>`,i=r.indexOf(`~`),a=r.lastIndexOf(`~`);return n&&r.unshift(`~`),r.join(``)},`processSet`),Zd=N(()=>window.MathMLElement!==void 0,`isMathMLSupported`),Qd=/\$\$(.*?)\$\$/g,$d=N(e=>(e.match(Qd)?.length??0)>0,`hasKatex`),ef=N(async(e,t)=>{let n=document.createElement(`div`);n.innerHTML=await nf(e,t),n.id=`katex-temp`,n.style.visibility=`hidden`,n.style.position=`absolute`,n.style.top=`0`,document.querySelector(`body`)?.insertAdjacentElement(`beforeend`,n);let r={width:n.clientWidth,height:n.clientHeight};return n.remove(),r},`calculateMathMLDimensions`),tf=N(async(e,t)=>{if(!$d(e))return e;if(!(Zd()||t.legacyMathML||t.forceLegacyMathML))return e.replace(Qd,`MathML is unsupported in this environment.`);{let{default:n}=await Tc(async()=>{let{default:e}=await import(`./vendor-
|
|
5
|
+
`);for(let[n,{detector:r}]of Object.entries(Dd))if(r(e,t))return n;throw new Ed(`No diagram type detected matching given configuration for text: ${e}`)},`detectType`),kd=N((...e)=>{for(let{id:t,detector:n,loader:r}of e)Ad(t,n,r)},`registerLazyLoadedDiagrams`),Ad=N((e,t,n)=>{Dd[e]&&P.warn(`Detector with key ${e} already exists. Overwriting.`),Dd[e]={detector:t,loader:n},P.debug(`Detector with key ${e} added${n?` with loader`:``}`)},`addDetector`),jd=N(e=>Dd[e].loader,`getDiagramLoader`),Md=/<br\s*\/?>/gi,Nd=N(e=>e?Ud(e).replace(/\\n/g,`#br#`).split(`#br#`):[``],`getRows`),Pd=(()=>{let e=!1;return()=>{e||=(Fd(),!0)}})();function Fd(){let e=`data-temp-href-target`;yu.addHook(`beforeSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(`target`)&&t.setAttribute(e,t.getAttribute(`target`)??``)}),yu.addHook(`afterSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(e)&&(t.setAttribute(`target`,t.getAttribute(e)??``),t.removeAttribute(e),t.getAttribute(`target`)===`_blank`&&t.setAttribute(`rel`,`noopener`))})}N(Fd,`setupDompurifyHooks`);var Id=N(e=>(Pd(),yu.sanitize(e)),`removeScript`),Ld=N((e,t)=>{if(Sd(t)){let n=t.securityLevel;n===`antiscript`||n===`strict`||n===`sandbox`?e=Id(e):n!==`loose`&&(e=Ud(e),e=e.replace(/</g,`<`).replace(/>/g,`>`),e=e.replace(/=/g,`=`),e=Hd(e))}return e},`sanitizeMore`),Rd=N((e,t)=>e&&(e=t.dompurifyConfig?yu.sanitize(Ld(e,t),t.dompurifyConfig).toString():yu.sanitize(Ld(e,t),{FORBID_TAGS:[`style`]}).toString(),e),`sanitizeText`),zd=N((e,t)=>typeof e==`string`?Rd(e,t):e.flat().map(e=>Rd(e,t)),`sanitizeTextOrArray`),Bd=N(e=>Md.test(e),`hasBreaks`),Vd=N(e=>e.split(Md),`splitBreaks`),Hd=N(e=>e.replace(/#br#/g,`<br/>`),`placeholderToBreak`),Ud=N(e=>e.replace(Md,`#br#`),`breakToPlaceholder`),Wd=N(e=>{let t=``;return e&&(t=window.location.protocol+`//`+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},`getUrl`),Gd=N(function(...e){let t=e.filter(e=>!isNaN(e));return Math.max(...t)},`getMax`),Kd=N(function(...e){let t=e.filter(e=>!isNaN(e));return Math.min(...t)},`getMin`),qd=N(function(e){let t=e.split(/(,)/),n=[];for(let e=0;e<t.length;e++){let r=t[e];if(r===`,`&&e>0&&e+1<t.length){let i=t[e-1],a=t[e+1];Yd(i,a)&&(r=i+`,`+a,e++,n.pop())}n.push(Xd(r))}return n.join(``)},`parseGenericTypes`),Jd=N((e,t)=>Math.max(0,e.split(t).length-1),`countOccurrence`),Yd=N((e,t)=>{let n=Jd(e,`~`),r=Jd(t,`~`);return n===1&&r===1},`shouldCombineSets`),Xd=N(e=>{let t=Jd(e,`~`),n=!1;if(t<=1)return e;t%2!=0&&e.startsWith(`~`)&&(e=e.substring(1),n=!0);let r=[...e],i=r.indexOf(`~`),a=r.lastIndexOf(`~`);for(;i!==-1&&a!==-1&&i!==a;)r[i]=`<`,r[a]=`>`,i=r.indexOf(`~`),a=r.lastIndexOf(`~`);return n&&r.unshift(`~`),r.join(``)},`processSet`),Zd=N(()=>window.MathMLElement!==void 0,`isMathMLSupported`),Qd=/\$\$(.*?)\$\$/g,$d=N(e=>(e.match(Qd)?.length??0)>0,`hasKatex`),ef=N(async(e,t)=>{let n=document.createElement(`div`);n.innerHTML=await nf(e,t),n.id=`katex-temp`,n.style.visibility=`hidden`,n.style.position=`absolute`,n.style.top=`0`,document.querySelector(`body`)?.insertAdjacentElement(`beforeend`,n);let r={width:n.clientWidth,height:n.clientHeight};return n.remove(),r},`calculateMathMLDimensions`),tf=N(async(e,t)=>{if(!$d(e))return e;if(!(Zd()||t.legacyMathML||t.forceLegacyMathML))return e.replace(Qd,`MathML is unsupported in this environment.`);{let{default:n}=await Tc(async()=>{let{default:e}=await import(`./vendor-O17eRefg.js`).then(e=>e.d);return{default:e}},__vite__mapDeps([0,1,2,3,4])),r=t.forceLegacyMathML||!Zd()&&t.legacyMathML?`htmlAndMathml`:`mathml`;return e.split(Md).map(e=>$d(e)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${e}</div>`:`<div>${e}</div>`).join(``).replace(Qd,(e,t)=>n.renderToString(t,{throwOnError:!0,displayMode:!0,output:r}).replace(/\n/g,` `).replace(/<annotation.*<\/annotation>/g,``))}},`renderKatexUnsanitized`),nf=N(async(e,t)=>Rd(await tf(e,t),t),`renderKatexSanitized`),rf={getRows:Nd,sanitizeText:Rd,sanitizeTextOrArray:zd,hasBreaks:Bd,splitBreaks:Vd,lineBreakRegex:Md,removeScript:Id,getUrl:Wd,evaluate:nd,getMax:Gd,getMin:Kd},af=N(function(e,t){for(let n of t)e.attr(n[0],n[1])},`d3Attrs`),of=N(function(e,t,n){let r=new Map;return n?(r.set(`width`,`100%`),r.set(`style`,`max-width: ${t}px;`)):(r.set(`height`,e),r.set(`width`,t)),r},`calculateSvgSizeAttrs`),sf=N(function(e,t,n,r){af(e,of(t,n,r))},`configureSvgSize`),cf=N(function(e,t,n,r){let i=t.node().getBBox(),a=i.width,o=i.height;P.info(`SVG bounds: ${a}x${o}`,i);let s=0,c=0;P.info(`Graph bounds: ${s}x${c}`,e),s=a+n*2,c=o+n*2,P.info(`Calculated bounds: ${s}x${c}`),sf(t,c,s,r);let l=`${i.x-n} ${i.y-n} ${i.width+2*n} ${i.height+2*n}`;t.attr(`viewBox`,l)},`setupGraphViewbox`),lf={};function uf(e){return[...e.cssRules].map(e=>e.cssText).join(`
|
|
6
6
|
`)}N(uf,`cssStyleSheetToString`);var df=N((e,t,n,r)=>{let i=``;return e in lf&&lf[e]?i=lf[e]({...n,svgId:r}):P.warn(`No theme found for ${e}`),`& {
|
|
7
7
|
font-family: ${n.fontFamily};
|
|
8
8
|
font-size: ${n.fontSize};
|
|
@@ -267,7 +267,7 @@ ${i.join(`
|
|
|
267
267
|
L0,20`)},`requirement_arrow`),requirement_contains:N((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).append(`g`);r.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),r.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),r.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10)},`requirement_contains`),requirement_arrow_neo:N((e,t,n)=>{let{themeVariables:r}=pd(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_arrowEnd`).attr(`refX`,20).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`stroke-width`,`${i}`).attr(`viewBox`,`0 0 25 20`).append(`path`).attr(`d`,`M0,0
|
|
268
268
|
L20,10
|
|
269
269
|
M20,10
|
|
270
|
-
L0,20`).attr(`stroke-linejoin`,`miter`)},`requirement_arrow_neo`),requirement_contains_neo:N((e,t,n)=>{let{themeVariables:r}=pd(),{strokeWidth:i}=r,a=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`g`);a.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),a.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),a.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10),a.selectAll(`*`).attr(`stroke-width`,`${i}`)},`requirement_contains_neo`)},pO=dO,mO=`\0`,hO=`\0`,gO=``,_O=class{constructor(e={}){this._isDirected=!Object.prototype.hasOwnProperty.call(e,`directed`)||e.directed,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,`multigraph`)?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,`compound`)?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=He(void 0),this._defaultEdgeLabelFn=He(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[hO]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return _e(e)||(e=He(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return pn(this._nodes)}sources(){var e=this;return Qo(this.nodes(),function(t){return vs(e._in[t])})}sinks(){var e=this;return Qo(this.nodes(),function(t){return vs(e._out[t])})}setNodes(e,t){var n=arguments,r=this;return M(e,function(e){n.length>1?r.setNode(e,t):r.setNode(e)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=hO,this._children[e]={},this._children[hO][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var t=e=>this.removeEdge(this._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],M(this.children(e),e=>{this.setParent(e)}),delete this._children[e]),M(pn(this._in[e]),t),delete this._in[e],delete this._preds[e],M(pn(this._out[e]),t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw Error(`Cannot set parent in a non-compound graph`);if(ys(t))t=hO;else{t+=``;for(var n=t;!ys(n);n=this.parent(n))if(n===e)throw Error(`Setting `+t+` as parent of `+e+` would create a cycle`);this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==hO)return t}}children(e){if(ys(e)&&(e=hO),this._isCompound){var t=this._children[e];if(t)return pn(t)}else if(e===hO)return this.nodes();else if(this.hasNode(e))return[]}predecessors(e){var t=this._preds[e];if(t)return pn(t)}successors(e){var t=this._sucs[e];if(t)return pn(t)}neighbors(e){var t=this.predecessors(e);if(t)return hc(t,this.successors(e))}isLeaf(e){return(this.isDirected()?this.successors(e):this.neighbors(e)).length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;M(this._nodes,function(n,r){e(r)&&t.setNode(r,n)}),M(this._edgeObjs,function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))});var r={};function i(e){var a=n.parent(e);return a===void 0||t.hasNode(a)?(r[e]=a,a):a in r?r[a]:i(a)}return this._isCompound&&M(t.nodes(),function(e){t.setParent(e,i(e))}),t}setDefaultEdgeLabel(e){return _e(e)||(e=He(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return ms(this._edgeObjs)}setPath(e,t){var n=this,r=arguments;return sc(e,function(e,i){return r.length>1?n.setEdge(e,i,t):n.setEdge(e,i),i}),this}setEdge(){var e,t,n,r,i=!1,a=arguments[0];typeof a==`object`&&a&&`v`in a?(e=a.v,t=a.w,n=a.name,arguments.length===2&&(r=arguments[1],i=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),e=``+e,t=``+t,ys(n)||(n=``+n);var o=bO(this._isDirected,e,t,n);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,o))return i&&(this._edgeLabels[o]=r),this;if(!ys(n)&&!this._isMultigraph)throw Error(`Cannot set a named edge when isMultigraph = false`);this.setNode(e),this.setNode(t),this._edgeLabels[o]=i?r:this._defaultEdgeLabelFn(e,t,n);var s=xO(this._isDirected,e,t,n);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[o]=s,vO(this._preds[t],e),vO(this._sucs[e],t),this._in[t][o]=s,this._out[e][o]=s,this._edgeCount++,this}edge(e,t,n){var r=arguments.length===1?SO(this._isDirected,arguments[0]):bO(this._isDirected,e,t,n);return this._edgeLabels[r]}hasEdge(e,t,n){var r=arguments.length===1?SO(this._isDirected,arguments[0]):bO(this._isDirected,e,t,n);return Object.prototype.hasOwnProperty.call(this._edgeLabels,r)}removeEdge(e,t,n){var r=arguments.length===1?SO(this._isDirected,arguments[0]):bO(this._isDirected,e,t,n),i=this._edgeObjs[r];return i&&(e=i.v,t=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],yO(this._preds[t],e),yO(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this}inEdges(e,t){var n=this._in[e];if(n){var r=ms(n);return t?Qo(r,function(e){return e.v===t}):r}}outEdges(e,t){var n=this._out[e];if(n){var r=ms(n);return t?Qo(r,function(e){return e.w===t}):r}}nodeEdges(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}};_O.prototype._nodeCount=0,_O.prototype._edgeCount=0;function vO(e,t){e[t]?e[t]++:e[t]=1}function yO(e,t){--e[t]||delete e[t]}function bO(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}return i+gO+a+gO+(ys(r)?mO:r)}function xO(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function SO(e,t){return bO(e,t.v,t.w,t.name)}var CO=N(async(e,t)=>{let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{clusterBkg:a,clusterBorder:o}=r,s=o,{labelStyles:c,nodeStyles:l,borderStyles:u,backgroundStyles:d}=W(t),f=e.insert(`g`).attr(`class`,`cluster swimlane `+(t.cssClasses||``)).attr(`id`,t.id).attr(`data-id`,t.id).attr(`data-et`,`cluster`).attr(`data-look`,t.look),p=nd(n.flowchart.htmlLabels),m=t.direction===`LR`,h=f.insert(`g`).attr(`class`,`cluster-label swimlane-label`),g=await DC(h,t.label,{style:t.labelStyle,useHtmlLabels:p,isNode:!0,width:t.width}),_=g.getBBox();if(p){let e=g.children[0],t=U(g);_=e.getBoundingClientRect(),t.attr(`width`,_.width),t.attr(`height`,_.height)}let v=t.padding??0,y=t.width<=_.width+v?_.width+v:t.width;t.diff=t.width<=_.width+v?(y-t.width)/2-v:-v;let b=t.height,x=t.y-b/2,S=t.y+b/2,C=t.x-y/2,w=t.swimlaneContentTop===void 0?x+b/3:t.swimlaneContentTop,T=m?4:0,E=_.height+2*T,D,O;if(m){let e=Math.max(E,_.height+2*T),n=C+e,r=Math.max(0,y-e);if(t.look===`handDrawn`){let o=q.svg(f),c=G(t,{roughness:.7,fill:a,stroke:s,fillWeight:3,seed:i}),l=G(t,{roughness:.7,fill:`none`,stroke:s,seed:i}),p=o.rectangle(C,x,e,b,c);D=f.insert(()=>p,`:first-child`);let m=o.rectangle(n,x,r,b,l);O=f.insert(()=>m,`:first-child`),D.select(`path:nth-child(2)`).attr(`style`,u.join(`;`)),D.select(`path`).attr(`style`,d.join(`;`).replace(`fill`,`stroke`))}else D=f.insert(`rect`,`:first-child`),O=f.insert(`rect`,`:first-child`),D.attr(`class`,`swimlane-title`).attr(`style`,l).attr(`x`,C).attr(`y`,x).attr(`width`,e).attr(`height`,b).attr(`fill`,a).attr(`stroke`,s),O.attr(`class`,`swimlane-body`).attr(`style`,l).attr(`x`,n).attr(`y`,x).attr(`width`,r).attr(`height`,b).attr(`fill`,`none`).attr(`stroke`,s);let o=C+e/2,c=t.y;h.attr(`transform`,`translate(${o}, ${c}) rotate(-90) translate(${-_.width/2}, ${-_.height/2})`)}else{let e=Math.max(0,w-x),n=Math.min(E,e),r=x+n,o=Math.max(0,S-r),c=t.x-y/2;if(t.look===`handDrawn`){let e=q.svg(f),l=G(t,{roughness:.7,fill:a,stroke:s,fillWeight:3,seed:i}),p=G(t,{roughness:.7,fill:`none`,stroke:s,seed:i}),m=e.rectangle(c,x,y,n,l);D=f.insert(()=>m,`:first-child`);let h=e.rectangle(c,r,y,o,p);O=f.insert(()=>h,`:first-child`),D.select(`path:nth-child(2)`).attr(`style`,u.join(`;`)),D.select(`path`).attr(`style`,d.join(`;`).replace(`fill`,`stroke`))}else D=f.insert(`rect`,`:first-child`),O=f.insert(`rect`,`:first-child`),D.attr(`class`,`swimlane-title`).attr(`style`,l).attr(`x`,c).attr(`y`,x).attr(`width`,y).attr(`height`,n).attr(`fill`,a).attr(`stroke`,s),O.attr(`class`,`swimlane-body`).attr(`style`,l).attr(`x`,c).attr(`y`,r).attr(`width`,y).attr(`height`,o).attr(`fill`,`none`).attr(`stroke`,s);let p=t.x-_.width/2,m=x+(n-_.height)/2;h.attr(`transform`,`translate(${p}, ${m})`)}if(P.trace(`Swimlane data `,t,JSON.stringify(t)),c){let e=h.select(`span`);e&&e.attr(`style`,c)}return t.offsetX=0,t.width=y,t.height=b,t.offsetY=_.height-v/2,t.intersect=function(e){return Yw(t,e)},{cluster:f,labelBBox:_}},`swimlane`),wO=N(async(e,t)=>{P.info(`Creating subgraph rect for `,t.id,t);let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{clusterBkg:a,clusterBorder:o}=r,{labelStyles:s,nodeStyles:c,borderStyles:l,backgroundStyles:u}=W(t),d=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),f=Sd(n),p=d.insert(`g`).attr(`class`,`cluster-label `),m;m=t.labelType===`markdown`?await DC(p,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width}):await Zw(p,t.label,t.labelStyle||``,!1,!0);let h=m.getBBox();if(Sd(n)){let e=m.children[0],t=U(m);h=e.getBoundingClientRect(),t.attr(`width`,h.width),t.attr(`height`,h.height)}let g=t.width<=h.width+t.padding?h.width+t.padding:t.width;t.diff=t.width<=h.width+t.padding?(g-t.width)/2-t.padding:-t.padding;let _=t.height,v=t.x-g/2,y=t.y-_/2;P.trace(`Data `,t,JSON.stringify(t));let b;if(t.look===`handDrawn`){let e=q.svg(d),n=G(t,{roughness:.7,fill:a,stroke:o,fillWeight:3,seed:i}),r=e.path(Xw(v,y,g,_,0),n);b=d.insert(()=>(P.debug(`Rough node insert CXC`,r),r),`:first-child`),b.select(`path:nth-child(2)`).attr(`style`,l.join(`;`)),b.select(`path`).attr(`style`,u.join(`;`).replace(`fill`,`stroke`))}else b=d.insert(`rect`,`:first-child`),b.attr(`style`,c).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,v).attr(`y`,y).attr(`width`,g).attr(`height`,_);let{subGraphTitleTopMargin:x}=OD(n);if(p.attr(`transform`,`translate(${t.x-h.width/2}, ${t.y-t.height/2+x})`),s){let e=p.select(`span`);e&&e.attr(`style`,s)}let S=b.node().getBBox();return t.offsetX=0,t.width=S.width,t.height=S.height,t.offsetY=h.height-t.padding/2,t.intersect=function(e){return Yw(t,e)},{cluster:d,labelBBox:h}},`rect`),TO={rect:wO,squareRect:wO,roundedWithTitle:N(async(e,t)=>{let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{altBackground:a,compositeBackground:o,compositeTitleBackground:s,nodeBorder:c}=r,l=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-id`,t.id).attr(`data-look`,t.look),u=l.insert(`g`,`:first-child`),d=l.insert(`g`).attr(`class`,`cluster-label`),f=l.append(`rect`),p=await Zw(d,t.label,t.labelStyle,void 0,!0),m=p.getBBox();if(Sd(n)){let e=p.children[0],t=U(p);m=e.getBoundingClientRect(),t.attr(`width`,m.width),t.attr(`height`,m.height)}let h=0*t.padding,g=h/2,_=(t.width<=m.width+t.padding?m.width+t.padding:t.width)+h;t.diff=t.width<=m.width+t.padding?(_-t.width)/2-t.padding:-t.padding;let v=t.height+h,y=t.height+h-m.height-6,b=t.x-_/2,x=t.y-v/2;t.width=_;let S=t.y-t.height/2-g+m.height+2,C;if(t.look===`handDrawn`){let e=t.cssClasses.includes(`statediagram-cluster-alt`),n=q.svg(l),r=t.rx||t.ry?n.path(Xw(b,x,_,v,10),{roughness:.7,fill:s,fillStyle:`solid`,stroke:c,seed:i}):n.rectangle(b,x,_,v,{seed:i});C=l.insert(()=>r,`:first-child`);let u=n.rectangle(b,S,_,y,{fill:e?a:o,fillStyle:e?`hachure`:`solid`,stroke:c,seed:i});C=l.insert(()=>r,`:first-child`),f=l.insert(()=>u)}else C=u.insert(`rect`,`:first-child`),C.attr(`class`,`outer`).attr(`x`,b).attr(`y`,x).attr(`width`,_).attr(`height`,v).attr(`data-look`,t.look),f.attr(`class`,`inner`).attr(`x`,b).attr(`y`,S).attr(`width`,_).attr(`height`,y);return d.attr(`transform`,`translate(${t.x-m.width/2}, ${x+1-(Sd(n)?0:3)})`),t.height=C.node().getBBox().height,t.offsetX=0,t.offsetY=m.height-t.padding/2,t.labelBBox=m,t.intersect=function(e){return Yw(t,e)},{cluster:l,labelBBox:m}},`roundedWithTitle`),noteGroup:N((e,t)=>{let n=e.insert(`g`).attr(`class`,`note-cluster`).attr(`id`,t.domId),r=n.insert(`rect`,`:first-child`),i=0*t.padding,a=i/2;r.attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,t.x-t.width/2-a).attr(`y`,t.y-t.height/2-a).attr(`width`,t.width+i).attr(`height`,t.height+i).attr(`fill`,`none`);let o=r.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(e){return Yw(t,e)},{cluster:n,labelBBox:{width:0,height:0}}},`noteGroup`),divider:N((e,t)=>{let{themeVariables:n,handDrawnSeed:r}=H(),{nodeBorder:i}=n,a=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),o=a.insert(`g`,`:first-child`),s=0*t.padding,c=t.width+s;t.diff=-t.padding;let l=t.height+s,u=t.x-c/2,d=t.y-l/2;t.width=c;let f;if(t.look===`handDrawn`){let e=q.svg(a).rectangle(u,d,c,l,{fill:`lightgrey`,roughness:.5,strokeLineDash:[5],stroke:i,seed:r});f=a.insert(()=>e,`:first-child`)}else{f=o.insert(`rect`,`:first-child`);let e=`outer`;e=(t.look,`divider`),f.attr(`class`,e).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l).attr(`data-look`,t.look)}return t.height=f.node().getBBox().height,t.offsetX=0,t.offsetY=0,t.intersect=function(e){return Yw(t,e)},{cluster:a,labelBBox:{}}},`divider`),kanbanSection:N(async(e,t)=>{P.info(`Creating subgraph rect for `,t.id,t);let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{clusterBkg:a,clusterBorder:o}=r,{labelStyles:s,nodeStyles:c,borderStyles:l,backgroundStyles:u}=W(t),d=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),f=Sd(n),p=d.insert(`g`).attr(`class`,`cluster-label `),m=await DC(p,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width}),h=m.getBBox();if(Sd(n)){let e=m.children[0],t=U(m);h=e.getBoundingClientRect(),t.attr(`width`,h.width),t.attr(`height`,h.height)}let g=t.width<=h.width+t.padding?h.width+t.padding:t.width;t.diff=t.width<=h.width+t.padding?(g-t.width)/2-t.padding:-t.padding;let _=t.height,v=t.x-g/2,y=t.y-_/2;P.trace(`Data `,t,JSON.stringify(t));let b;if(t.look===`handDrawn`){let e=q.svg(d),n=G(t,{roughness:.7,fill:a,stroke:o,fillWeight:4,seed:i}),r=e.path(Xw(v,y,g,_,t.rx),n);b=d.insert(()=>(P.debug(`Rough node insert CXC`,r),r),`:first-child`),b.select(`path:nth-child(2)`).attr(`style`,l.join(`;`)),b.select(`path`).attr(`style`,u.join(`;`).replace(`fill`,`stroke`))}else b=d.insert(`rect`,`:first-child`),b.attr(`style`,c).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,v).attr(`y`,y).attr(`width`,g).attr(`height`,_);let{subGraphTitleTopMargin:x}=OD(n);if(p.attr(`transform`,`translate(${t.x-h.width/2}, ${t.y-t.height/2+x})`),s){let e=p.select(`span`);e&&e.attr(`style`,s)}let S=b.node().getBBox();return t.offsetX=0,t.width=S.width,t.height=S.height,t.offsetY=h.height-t.padding/2,t.intersect=function(e){return Yw(t,e)},{cluster:d,labelBBox:h}},`kanbanSection`),swimlane:CO},EO=new Map,DO=N(async(e,t)=>{let n=await TO[t.shape||`rect`](e,t);return EO.set(t.id,n),n},`insertCluster`),OO=N(()=>{EO=new Map},`clear`);function kO(e,{edgePathsClass:t=`edges edgePaths`}={}){let n=e.insert(`g`).attr(`class`,`root`);return{clusters:n.insert(`g`).attr(`class`,`clusters`),edgePaths:n.insert(`g`).attr(`class`,t),edgeLabels:n.insert(`g`).attr(`class`,`edgeLabels`),nodes:n.insert(`g`).attr(`class`,`nodes`),rootGroups:n}}N(kO,`createLayoutElementGroups`);async function AO(e,t){if(t.label){let{shapeSvg:n,bbox:r}=await J(e,t);t.labelBBox={width:r.width,height:r.height},n.remove()}else t.labelBBox={width:0,height:0}}N(AO,`measureGroupLabel`);async function jO(e,t,n){let r=await AD(e,t,n),i=r.node()?.getBBox()??{width:0,height:0};return t.width=i.width,t.height=i.height,r}N(jO,`insertMeasuredNode`);async function MO(e,t){let n=new _O({multigraph:!0,compound:!0}),r=[...t.edges],i=H(),a=kO(e),{edgeLabels:o,nodes:s}=a,c=new Map,l=e.node()!=null;await Promise.all(t.nodes.map(async e=>{if(e.isGroup)l&&await AO(s,e),n.setNode(e.id,{...e});else{if(l){let t=await jO(s,e,{config:i,dir:e.dir});c.set(e.id,t)}n.setNode(e.id,{...e})}}));for(let e of r)l&&JD(e)&&await XD(o,e),n.setEdge(e.start,e.end,{...e},e.id),t.edges.some(t=>t.id===e.id)||t.edges.push(e);if(globalThis.mermaidCaptureSizes){let{captureNodeSizes:n}=await Tc(async()=>{let{captureNodeSizes:e}=await import(`./vendor-BD09UDuP.js`).then(e=>e.u);return{captureNodeSizes:e}},__vite__mapDeps([0,1,2,3,4]));n(e,t)}return{graph:n,groups:a,nodeElements:c}}N(MO,`createGraphWithElements`);var $=new Map,NO=new Map,PO=new Map,FO=N(()=>{NO.clear(),PO.clear(),$.clear()},`clear`),IO=N((e,t)=>{let n=NO.get(t)||[];return P.trace(`In isDescendant`,t,` `,e,` = `,n.includes(e)),n.includes(e)},`isDescendant`),LO=N((e,t)=>{let n=NO.get(t)||[];return P.info(`Descendants of `,t,` is `,n),P.info(`Edge is `,e),e.v===t||e.w===t?!1:n?n.includes(e.v)||IO(e.v,t)||IO(e.w,t)||n.includes(e.w):(P.debug(`Tilt, `,t,`,not in descendants`),!1)},`edgeInCluster`),RO=N((e,t,n,r)=>{P.debug(`Copying children of `,e,`root`,r,`data`,t.node(e),r);let i=t.children(e)||[];e!==r&&i.push(e),P.debug(`Copying (nodes) clusterId`,e,`nodes`,i),i.forEach(i=>{if(t.children(i).length>0)RO(i,t,n,r);else{let a=t.node(i);P.info(`cp `,i,` to `,r,` with parent `,e),n.setNode(i,a),r!==t.parent(i)&&(P.debug(`Setting parent`,i,t.parent(i)),n.setParent(i,t.parent(i))),e!==r&&i!==e?(P.debug(`Setting parent`,i,e),n.setParent(i,e)):(P.info(`In copy `,e,`root`,r,`data`,t.node(e),r),P.debug(`Not Setting parent for node=`,i,`cluster!==rootId`,e!==r,`node!==clusterId`,i!==e));let o=t.edges(i);P.debug(`Copying Edges`,o),o.forEach(i=>{P.info(`Edge`,i);let a=t.edge(i.v,i.w,i.name);P.info(`Edge data`,a,r);try{LO(i,r)?(P.info(`Copying as `,i.v,i.w,a,i.name),n.setEdge(i.v,i.w,a,i.name),P.info(`newGraph edges `,n.edges(),n.edge(n.edges()[0]))):P.info(`Skipping copy of edge `,i.v,`-->`,i.w,` rootId: `,r,` clusterId:`,e)}catch(e){P.error(e)}})}P.debug(`Removing node`,i),t.removeNode(i)})},`copy`),zO=N((e,t)=>{let n=t.children(e),r=[...n];for(let i of n)PO.set(i,e),r=[...r,...zO(i,t)];return r},`extractDescendants`),BO=N((e,t,n)=>{let r=e.edges().filter(e=>e.v===t||e.w===t),i=e.edges().filter(e=>e.v===n||e.w===n),a=r.map(e=>({v:e.v===t?n:e.v,w:e.w===t?t:e.w})),o=i.map(e=>({v:e.v,w:e.w}));return a.filter(e=>o.some(t=>e.v===t.v&&e.w===t.w))},`findCommonEdges`),VO=N((e,t,n)=>{let r=t.children(e);if(P.trace(`Searching children of id `,e,r),r.length<1)return e;let i;for(let e of r){let r=VO(e,t,n),a=BO(t,n,r);if(r){if(a.length>0)i=r;else return r}}return i},`findNonClusterChild`),HO=N(e=>!$.has(e)||!$.get(e).externalConnections?e:$.has(e)?$.get(e).id:e,`getAnchorId`),UO=N((e,t)=>{if(!e||t>10){P.debug(`Opting out, no graph `);return}P.debug(`Opting in, graph `),e.nodes().forEach(function(t){e.children(t).length>0&&(P.debug(`Cluster identified`,t,` Replacement id in edges: `,VO(t,e,t)),NO.set(t,zO(t,e)),$.set(t,{id:VO(t,e,t),clusterData:e.node(t)}))}),e.nodes().forEach(function(t){let n=e.children(t),r=e.edges();n.length>0?(P.debug(`Cluster identified`,t,NO),r.forEach(e=>{IO(e.v,t)^IO(e.w,t)&&(P.debug(`Edge: `,e,` leaves cluster `,t),P.debug(`Descendants of XXX `,t,`: `,NO.get(t)),$.get(t).externalConnections=!0)})):P.debug(`Not a cluster `,t,NO)});for(let t of $.keys()){let n=$.get(t).id,r=e.parent(n);r!==t&&$.has(r)&&!$.get(r).externalConnections&&($.get(t).id=r);let i=e.edges().some(e=>e.v===t);if(n&&$.get(t)?.externalConnections&&i&&qO(e,n,t)){let r=JO(e,t,e.parent(n));r&&($.get(t).id=r)}}e.edges().forEach(function(t){let n=e.edge(t);P.debug(`Edge `+t.v+` -> `+t.w+`: `+JSON.stringify(t)),P.debug(`Edge `+t.v+` -> `+t.w+`: `+JSON.stringify(e.edge(t)));let r=t.v,i=t.w;if(P.debug(`Fix XXX`,$,`ids:`,t.v,t.w,`Translating: `,$.get(t.v),` --- `,$.get(t.w)),$.get(t.v)||$.get(t.w)){if(P.debug(`Fixing and trying - removing XXX`,t.v,t.w,t.name),r=HO(t.v),i=HO(t.w),e.removeEdge(t.v,t.w,t.name),r!==t.v){let i=e.parent(r);$.get(i).externalConnections=!0,n.fromCluster=t.v}if(i!==t.w){let r=e.parent(i);$.get(r).externalConnections=!0,n.toCluster=t.w}P.debug(`Fix Replacing with XXX`,r,i,t.name),e.setEdge(r,i,n,t.name)}}),WO(e,0),P.trace($)},`adjustClustersAndEdges`),WO=N((e,t)=>{if(t>10){P.error(`Bailing out`);return}let n=e.nodes(),r=!1;for(let t of n){let n=e.children(t);r||=n.length>0}if(!r){P.debug(`Done, no node has children`,e.nodes());return}P.debug(`Nodes = `,n,t);for(let r of n)if(P.debug(`Extracting node`,r,$,$.has(r)&&!$.get(r).externalConnections,!e.parent(r),e.node(r),e.children(`D`),` Depth `,t),!$.has(r))P.debug(`Not a cluster`,r,t);else if(!$.get(r).externalConnections&&e.children(r)&&e.children(r).length>0){P.debug(`Cluster without external connections, without a parent and with children`,r,t);let n=e.graph().rankdir===`TB`?`LR`:`TB`;$.get(r)?.clusterData?.dir&&(n=$.get(r).clusterData.dir,P.debug(`Fixing dir`,$.get(r).clusterData.dir,n));let i=new _O({multigraph:!0,compound:!0}).setGraph({rankdir:n,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});RO(r,e,i,r),e.setNode(r,{clusterNode:!0,id:r,clusterData:$.get(r).clusterData,label:$.get(r).label,graph:i})}else P.debug(`Cluster ** `,r,` **not meeting the criteria !externalConnections:`,!$.get(r).externalConnections,` no parent: `,!e.parent(r),` children `,e.children(r)&&e.children(r).length>0,e.children(`D`),t),P.debug($);n=e.nodes(),P.debug(`New list of nodes`,n);for(let r of n){let n=e.node(r);P.debug(` Now next level`,r,n),n?.clusterNode&&WO(n.graph,t+1)}},`extractor`),GO=N((e,t)=>{if(t.length===0)return[];let n=Object.assign([],t);return t.forEach(t=>{let r=GO(e,e.children(t));n=[...n,...r]}),n},`sorter`),KO=N(e=>GO(e,e.children()),`sortNodesByHierarchy`),qO=N((e,t,n)=>{let r=e.parent(t);for(;r&&r!==n;){let t=$.get(r);if(t&&!t.externalConnections)return!0;r=e.parent(r)}return!1},`isNodeInExtractableCluster`),JO=N((e,t,n)=>{let r=e.children(t)??[];for(let i of r){if(i===n||IO(i,n))continue;let r=VO(i,e,t);if(r&&!qO(e,r,t))return r}return null},`findSafeAnchorNode`);function YO({prepareLayout:e,measureLayout:t,runLayoutCore:n,paintLayout:r,afterPaint:i,paintOptions:a}){let o=t??ZO;return N(async function(t,s,c,l){let u=s.select(`g`);(c?.insertMarkers??pO)(u,t.markers,t.type,t.diagramId),XO();let d={element:u,helpers:c,options:l};d.preparedLayout=await e?.(t,d);let f=await o(t,d),p=await n(t,d),m={...d,measure:f};r?await r(t,m,p):await QO(t,m,a),await i?.(t,m,p)},`render`)}N(YO,`createCommonLayoutRenderer`);function XO(){MD(),qD(),OO(),FO()}N(XO,`clearLayoutRenderState`);async function ZO(e,{element:t}){return await MO(t,e)}N(ZO,`defaultMeasureLayout`);async function QO(e,t,n={}){let{measure:r}=t,{groups:i}=r;for(let r of n.getNodes?.(e,t)??e.nodes)n.skipNode?.(r,t)||await $O(i,r,t,n);let a=tk(e.nodes);for(let r of e.edges)nk(r,n)||await rk(i,r,a,e,n,t)}N(QO,`paintLayoutData`);async function $O(e,t,n,r){t.clusterNode?ND(t):ek(t,n,r)?await DO(e.clusters,t):ND(t)}N($O,`paintLayoutNode`);function ek(e,t,n){return e.isGroup===!0&&(n.isCluster?.(e,t)??!0)}N(ek,`shouldPaintAsCluster`);function tk(e){let t=new Map;for(let n of e)n?.id&&t.set(n.id,n);return t}N(tk,`buildNodeLookup`);function nk(e,t){return e.isLayoutOnly||!!t.skipEdge?.(e)}N(nk,`shouldSkipPaintEdge`);async function rk(e,t,n,r,i,a){let o=sO(e.edgePaths,{...t},i.clusterDb??new Map,r.type,ik(t.start,t,n,a,i),ik(t.end,t,n,a,i),r.diagramId,ak(t,i));JD(t)&&(GD.has(t.id)||await XD(e.edgeLabels,t),ok(t,o))}N(rk,`paintLayoutEdge`);function ik(e,t,n,r,i){return i.getEdgeNode?.(e,t,r)??(e?n.get(e)??{}:{})}N(ik,`getRenderedNode`);function ak(e,t){return typeof t.skipIntersect==`function`?t.skipIntersect(e):t.skipIntersect??!1}N(ak,`shouldSkipIntersect`);function ok(e,t){let n=t?.updatedPath??t?.originalPath,{subGraphTitleTotalMargin:r}=OD({flowchart:pd().flowchart??{}});if(e.label){let i=GD.get(e.id),a=e.x,o=e.y;if(n){let r=gx.calcLabelPosition(n);P.debug(`Moving label `+e.label+` from (`,a,`,`,o,`) to (`,r.x,`,`,r.y,`) abc88`),t?.updatedPath&&(a=r.x,o=r.y)}i.attr(`transform`,`translate(${a}, ${o+r/2})`)}if(e?.startLabelLeft){let t=KD.get(e.id).startLeft,r=e?.x,i=e?.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_left`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}if(e.startLabelRight){let t=KD.get(e.id).startRight,r=e.x,i=e.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_right`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}if(e.endLabelLeft){let t=KD.get(e.id).endLeft,r=e.x,i=e.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_left`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}if(e.endLabelRight){let t=KD.get(e.id).endRight,r=e.x,i=e.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_right`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}}N(ok,`positionRenderedEdgeLabel`);var sk=class{constructor(){var e={};e._next=e._prev=e,this._sentinel=e}dequeue(){var e=this._sentinel,t=e._prev;if(t!==e)return ck(t),t}enqueue(e){var t=this._sentinel;e._prev&&e._next&&ck(e),e._next=t._next,t._next._prev=e,t._next=e,e._prev=t}toString(){for(var e=[],t=this._sentinel,n=t._prev;n!==t;)e.push(JSON.stringify(n,lk)),n=n._prev;return`[`+e.join(`, `)+`]`}};function ck(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function lk(e,t){if(e!==`_next`&&e!==`_prev`)return t}var uk=He(1);function dk(e,t){if(e.nodeCount()<=1)return[];var n=mk(e,t||uk);return fr(is(fk(n.graph,n.buckets,n.zeroIdx),function(t){return e.outEdges(t.v,t.w)}))}function fk(e,t,n){for(var r=[],i=t[t.length-1],a=t[0],o;e.nodeCount();){for(;o=a.dequeue();)pk(e,t,n,o);for(;o=i.dequeue();)pk(e,t,n,o);if(e.nodeCount()){for(var s=t.length-2;s>0;--s)if(o=t[s].dequeue(),o){r=r.concat(pk(e,t,n,o,!0));break}}}return r}function pk(e,t,n,r,i){var a=i?[]:void 0;return M(e.inEdges(r.v),function(r){var o=e.edge(r),s=e.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,hk(t,n,s)}),M(e.outEdges(r.v),function(r){var i=e.edge(r),a=r.w,o=e.node(a);o.in-=i,hk(t,n,o)}),e.removeNode(r.v),a}function mk(e,t){var n=new _O,r=0,i=0;M(e.nodes(),function(e){n.setNode(e,{v:e,in:0,out:0})}),M(e.edges(),function(e){var a=n.edge(e.v,e.w)||0,o=t(e),s=a+o;n.setEdge(e.v,e.w,s),i=Math.max(i,n.node(e.v).out+=o),r=Math.max(r,n.node(e.w).in+=o)});var a=ac(i+r+3).map(function(){return new sk}),o=r+1;return M(n.nodes(),function(e){hk(a,o,n.node(e))}),{graph:n,buckets:a,zeroIdx:o}}function hk(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}function gk(e){M(e.graph().acyclicer===`greedy`?dk(e,t(e)):_k(e),function(t){var n=e.edge(t);e.removeEdge(t),n.forwardName=t.name,n.reversed=!0,e.setEdge(t.w,t.v,n,_c(`rev`))});function t(e){return function(t){return e.edge(t).weight}}}function _k(e){var t=[],n={},r={};function i(a){Object.prototype.hasOwnProperty.call(r,a)||(r[a]=!0,n[a]=!0,M(e.outEdges(a),function(e){Object.prototype.hasOwnProperty.call(n,e.w)?t.push(e):i(e.w)}),delete n[a])}return M(e.nodes(),i),t}function vk(e){M(e.edges(),function(t){var n=e.edge(t);if(n.reversed){e.removeEdge(t);var r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}})}function yk(e,t,n,r){var i;do i=_c(r);while(e.hasNode(i));return n.dummy=t,e.setNode(i,n),i}function bk(e){var t=new _O().setGraph(e.graph());return M(e.nodes(),function(n){t.setNode(n,e.node(n))}),M(e.edges(),function(n){var r=t.edge(n.v,n.w)||{weight:0,minlen:1},i=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})}),t}function xk(e){var t=new _O({multigraph:e.isMultigraph()}).setGraph(e.graph());return M(e.nodes(),function(n){e.children(n).length||t.setNode(n,e.node(n))}),M(e.edges(),function(n){t.setEdge(n,e.edge(n))}),t}function Sk(e,t){var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2;if(!i&&!a)throw Error(`Not possible to find intersection inside of the rectangle`);var c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=s*i/a,l=s):(i<0&&(o=-o),c=o,l=o*a/i),{x:n+c,y:r+l}}function Ck(e){var t=is(ac(Dk(e)+1),function(){return[]});return M(e.nodes(),function(n){var r=e.node(n),i=r.rank;ys(i)||(t[i][r.order]=n)}),t}function wk(e){var t=Ts(is(e.nodes(),function(t){return e.node(t).rank}));M(e.nodes(),function(n){var r=e.node(n);us(r,`rank`)&&(r.rank-=t)})}function Tk(e){var t=Ts(is(e.nodes(),function(t){return e.node(t).rank})),n=[];M(e.nodes(),function(r){var i=e.node(r).rank-t;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=e.graph().nodeRankFactor;M(n,function(t,n){ys(t)&&n%i!==0?--r:r&&M(t,function(t){e.node(t).rank+=r})})}function Ek(e,t,n,r){var i={width:0,height:0};return arguments.length>=4&&(i.rank=n,i.order=r),yk(e,`border`,i,t)}function Dk(e){return Cs(is(e.nodes(),function(t){var n=e.node(t).rank;if(!ys(n))return n}))}function Ok(e,t){var n={lhs:[],rhs:[]};return M(e,function(e){t(e)?n.lhs.push(e):n.rhs.push(e)}),n}function kk(e,t){var n=Ro();try{return t()}finally{console.log(e+` time: `+(Ro()-n)+`ms`)}}function Ak(e,t){return t()}function jk(e){function t(n){var r=e.children(n),i=e.node(n);if(r.length&&M(r,t),Object.prototype.hasOwnProperty.call(i,`minRank`)){i.borderLeft=[],i.borderRight=[];for(var a=i.minRank,o=i.maxRank+1;a<o;++a)Mk(e,`borderLeft`,`_bl`,n,i,a),Mk(e,`borderRight`,`_br`,n,i,a)}}M(e.children(),t)}function Mk(e,t,n,r,i,a){var o={width:0,height:0,rank:a,borderType:t},s=i[t][a-1],c=yk(e,`border`,o,n);i[t][a]=c,e.setParent(c,r),s&&e.setEdge(s,c,{weight:1})}function Nk(e){var t=e.graph().rankdir.toLowerCase();(t===`lr`||t===`rl`)&&Fk(e)}function Pk(e){var t=e.graph().rankdir.toLowerCase();(t===`bt`||t===`rl`)&&Lk(e),(t===`lr`||t===`rl`)&&(zk(e),Fk(e))}function Fk(e){M(e.nodes(),function(t){Ik(e.node(t))}),M(e.edges(),function(t){Ik(e.edge(t))})}function Ik(e){var t=e.width;e.width=e.height,e.height=t}function Lk(e){M(e.nodes(),function(t){Rk(e.node(t))}),M(e.edges(),function(t){var n=e.edge(t);M(n.points,Rk),Object.prototype.hasOwnProperty.call(n,`y`)&&Rk(n)})}function Rk(e){e.y=-e.y}function zk(e){M(e.nodes(),function(t){Bk(e.node(t))}),M(e.edges(),function(t){var n=e.edge(t);M(n.points,Bk),Object.prototype.hasOwnProperty.call(n,`x`)&&Bk(n)})}function Bk(e){var t=e.x;e.x=e.y,e.y=t}function Vk(e){e.graph().dummyChains=[],M(e.edges(),function(t){Hk(e,t)})}function Hk(e,t){var n=t.v,r=e.node(n).rank,i=t.w,a=e.node(i).rank,o=t.name,s=e.edge(t),c=s.labelRank;if(a!==r+1){e.removeEdge(t);var l=void 0,u,d=0;for(++r;r<a;++d,++r)s.points=[],l={width:0,height:0,edgeLabel:s,edgeObj:t,rank:r},u=yk(e,`edge`,l,`_d`),r===c&&(l.width=s.width,l.height=s.height,l.dummy=`edge-label`,l.labelpos=s.labelpos),e.setEdge(n,u,{weight:s.weight},o),d===0&&e.graph().dummyChains.push(u),n=u;e.setEdge(n,i,{weight:s.weight},o)}}function Uk(e){M(e.graph().dummyChains,function(t){var n=e.node(t),r=n.edgeLabel,i;for(e.setEdge(n.edgeObj,r);n.dummy;)i=e.successors(t)[0],e.removeNode(t),r.points.push({x:n.x,y:n.y}),n.dummy===`edge-label`&&(r.x=n.x,r.y=n.y,r.width=n.width,r.height=n.height),t=i,n=e.node(t)})}function Wk(e){var t={};function n(r){var i=e.node(r);if(Object.prototype.hasOwnProperty.call(t,r))return i.rank;t[r]=!0;var a=Ts(is(e.outEdges(r),function(t){return n(t.w)-e.edge(t).minlen}));return(a===1/0||a==null)&&(a=0),i.rank=a}M(e.sources(),n)}function Gk(e,t){return e.node(t.w).rank-e.node(t.v).rank-e.edge(t).minlen}function Kk(e){var t=new _O({directed:!1}),n=e.nodes()[0],r=e.nodeCount();t.setNode(n,{});for(var i,a;qk(t,e)<r;)i=Jk(t,e),a=t.hasNode(i.v)?Gk(e,i):-Gk(e,i),Yk(t,e,a);return t}function qk(e,t){function n(r){M(t.nodeEdges(r),function(i){var a=i.v,o=r===a?i.w:a;!e.hasNode(o)&&!Gk(t,i)&&(e.setNode(o,{}),e.setEdge(r,o,{}),n(o))})}return M(e.nodes(),n),e.nodeCount()}function Jk(e,t){return Es(t.edges(),function(n){if(e.hasNode(n.v)!==e.hasNode(n.w))return Gk(t,n)})}function Yk(e,t,n){M(e.nodes(),function(e){t.node(e).rank+=n})}Xk.CycleException=Zk;function Xk(e){var t={},n={},r=[];function i(a){if(Object.prototype.hasOwnProperty.call(n,a))throw new Zk;Object.prototype.hasOwnProperty.call(t,a)||(n[a]=!0,t[a]=!0,M(e.predecessors(a),i),delete n[a],r.push(a))}if(M(e.sinks(),i),uc(t)!==e.nodeCount())throw new Zk;return r}function Zk(){}Zk.prototype=Error();function Qk(e,t,n){C(t)||(t=[t]);var r=(e.isDirected()?e.successors:e.neighbors).bind(e),i=[],a={};return M(t,function(t){if(!e.hasNode(t))throw Error(`Graph does not have node: `+t);$k(e,t,n===`post`,a,r,i)}),i}function $k(e,t,n,r,i,a){Object.prototype.hasOwnProperty.call(r,t)||(r[t]=!0,n||a.push(t),M(i(t),function(t){$k(e,t,n,r,i,a)}),n&&a.push(t))}function eA(e,t){return Qk(e,t,`post`)}function tA(e,t){return Qk(e,t,`pre`)}nA.initLowLimValues=oA,nA.initCutValues=rA,nA.calcCutValue=aA,nA.leaveEdge=cA,nA.enterEdge=lA,nA.exchangeEdges=uA;function nA(e){e=bk(e),Wk(e);var t=Kk(e);oA(t),rA(t,e);for(var n,r;n=cA(t);)r=lA(t,e,n),uA(t,e,n,r)}function rA(e,t){var n=eA(e,e.nodes());n=n.slice(0,n.length-1),M(n,function(n){iA(e,t,n)})}function iA(e,t,n){var r=e.node(n).parent;e.edge(n,r).cutvalue=aA(e,t,n)}function aA(e,t,n){var r=e.node(n).parent,i=!0,a=t.edge(n,r),o=0;return a||=(i=!1,t.edge(r,n)),o=a.weight,M(t.nodeEdges(n),function(a){var s=a.v===n,c=s?a.w:a.v;if(c!==r){var l=s===i,u=t.edge(a).weight;if(o+=l?u:-u,fA(e,n,c)){var d=e.edge(n,c).cutvalue;o+=l?-d:d}}}),o}function oA(e,t){arguments.length<2&&(t=e.nodes()[0]),sA(e,{},1,t)}function sA(e,t,n,r,i){var a=n,o=e.node(r);return t[r]=!0,M(e.neighbors(r),function(i){Object.prototype.hasOwnProperty.call(t,i)||(n=sA(e,t,n,i,r))}),o.low=a,o.lim=n++,i?o.parent=i:delete o.parent,n}function cA(e){return ns(e.edges(),function(t){return e.edge(t).cutvalue<0})}function lA(e,t,n){var r=n.v,i=n.w;t.hasEdge(r,i)||(r=n.w,i=n.v);var a=e.node(r),o=e.node(i),s=a,c=!1;return a.lim>o.lim&&(s=o,c=!0),Es(Qo(t.edges(),function(t){return c===pA(e,e.node(t.v),s)&&c!==pA(e,e.node(t.w),s)}),function(e){return Gk(t,e)})}function uA(e,t,n,r){var i=n.v,a=n.w;e.removeEdge(i,a),e.setEdge(r.v,r.w,{}),oA(e),rA(e,t),dA(e,t)}function dA(e,t){var n=tA(e,ns(e.nodes(),function(e){return!t.node(e).parent}));n=n.slice(1),M(n,function(n){var r=e.node(n).parent,i=t.edge(n,r),a=!1;i||(i=t.edge(r,n),a=!0),t.node(n).rank=t.node(r).rank+(a?i.minlen:-i.minlen)})}function fA(e,t,n){return e.hasEdge(t,n)}function pA(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}function mA(e){switch(e.graph().ranker){case`network-simplex`:_A(e);break;case`tight-tree`:gA(e);break;case`longest-path`:hA(e);break;default:_A(e)}}var hA=Wk;function gA(e){Wk(e),Kk(e)}function _A(e){nA(e)}function vA(e){var t=yk(e,`root`,{},`_root`),n=bA(e),r=Cs(ms(n))-1,i=2*r+1;e.graph().nestingRoot=t,M(e.edges(),function(t){e.edge(t).minlen*=i});var a=xA(e)+1;M(e.children(),function(o){yA(e,t,i,a,r,n,o)}),e.graph().nodeRankFactor=i}function yA(e,t,n,r,i,a,o){var s=e.children(o);if(!s.length){o!==t&&e.setEdge(t,o,{weight:0,minlen:n});return}var c=Ek(e,`_bt`),l=Ek(e,`_bb`),u=e.node(o);e.setParent(c,o),u.borderTop=c,e.setParent(l,o),u.borderBottom=l,M(s,function(s){yA(e,t,n,r,i,a,s);var u=e.node(s),d=u.borderTop?u.borderTop:s,f=u.borderBottom?u.borderBottom:s,p=u.borderTop?r:2*r,m=d===f?i-a[o]+1:1;e.setEdge(c,d,{weight:p,minlen:m,nestingEdge:!0}),e.setEdge(f,l,{weight:p,minlen:m,nestingEdge:!0})}),e.parent(o)||e.setEdge(t,c,{weight:0,minlen:i+a[o]})}function bA(e){var t={};function n(r,i){var a=e.children(r);a&&a.length&&M(a,function(e){n(e,i+1)}),t[r]=i}return M(e.children(),function(e){n(e,1)}),t}function xA(e){return sc(e.edges(),function(t,n){return t+e.edge(n).weight},0)}function SA(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,M(e.edges(),function(t){e.edge(t).nestingEdge&&e.removeEdge(t)})}function CA(e,t,n){var r={},i;M(n,function(n){for(var a=e.parent(n),o,s;a;){if(o=e.parent(a),o?(s=r[o],r[o]=a):(s=i,i=a),s&&s!==a){t.setEdge(s,a);return}a=o}})}function wA(e,t,n){var r=TA(e),i=new _O({compound:!0}).setGraph({root:r}).setDefaultNodeLabel(function(t){return e.node(t)});return M(e.nodes(),function(a){var o=e.node(a),s=e.parent(a);(o.rank===t||o.minRank<=t&&t<=o.maxRank)&&(i.setNode(a),i.setParent(a,s||r),M(e[n](a),function(t){var n=t.v===a?t.w:t.v,r=i.edge(n,a),o=ys(r)?0:r.weight;i.setEdge(n,a,{weight:e.edge(t).weight+o})}),Object.prototype.hasOwnProperty.call(o,`minRank`)&&i.setNode(a,{borderLeft:o.borderLeft[t],borderRight:o.borderRight[t]}))}),i}function TA(e){for(var t;e.hasNode(t=_c(`_root`)););return t}function EA(e,t){for(var n=0,r=1;r<t.length;++r)n+=DA(e,t[r-1],t[r]);return n}function DA(e,t,n){for(var r=yc(n,is(n,function(e,t){return t})),i=fr(is(t,function(t){return dc(is(e.outEdges(t),function(t){return{pos:r[t.w],weight:e.edge(t).weight}}),`pos`)})),a=1;a<n.length;)a<<=1;var o=2*a-1;--a;var s=is(Array(o),function(){return 0}),c=0;return M(i.forEach(function(e){var t=e.pos+a;s[t]+=e.weight;for(var n=0;t>0;)t%2&&(n+=s[t+1]),t=t-1>>1,s[t]+=e.weight;c+=e.weight*n})),c}function OA(e){var t={},n=Qo(e.nodes(),function(t){return!e.children(t).length}),r=is(ac(Cs(is(n,function(t){return e.node(t).rank}))+1),function(){return[]});function i(n){us(t,n)||(t[n]=!0,r[e.node(n).rank].push(n),M(e.successors(n),i))}return M(dc(n,function(t){return e.node(t).rank}),i),r}function kA(e,t){return is(t,function(t){var n=e.inEdges(t);if(n.length){var r=sc(n,function(t,n){var r=e.edge(n),i=e.node(n.v);return{sum:t.sum+r.weight*i.order,weight:t.weight+r.weight}},{sum:0,weight:0});return{v:t,barycenter:r.sum/r.weight,weight:r.weight}}return{v:t}})}function AA(e,t){var n={};return M(e,function(e,t){var r=n[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};ys(e.barycenter)||(r.barycenter=e.barycenter,r.weight=e.weight)}),M(t.edges(),function(e){var t=n[e.v],r=n[e.w];!ys(t)&&!ys(r)&&(r.indegree++,t.out.push(n[e.w]))}),jA(Qo(n,function(e){return!e.indegree}))}function jA(e){var t=[];function n(e){return function(t){t.merged||(ys(t.barycenter)||ys(e.barycenter)||t.barycenter>=e.barycenter)&&MA(e,t)}}function r(t){return function(n){n.in.push(t),--n.indegree===0&&e.push(n)}}for(;e.length;){var i=e.pop();t.push(i),M(i.in.reverse(),n(i)),M(i.out,r(i))}return is(Qo(t,function(e){return!e.merged}),function(e){return ec(e,[`vs`,`i`,`barycenter`,`weight`])})}function MA(e,t){var n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}function NA(e,t){var n=Ok(e,function(e){return Object.prototype.hasOwnProperty.call(e,`barycenter`)}),r=n.lhs,i=dc(n.rhs,function(e){return-e.i}),a=[],o=0,s=0,c=0;r.sort(FA(!!t)),c=PA(a,i,c),M(r,function(e){c+=e.vs.length,a.push(e.vs),o+=e.barycenter*e.weight,s+=e.weight,c=PA(a,i,c)});var l={vs:fr(a)};return s&&(l.barycenter=o/s,l.weight=s),l}function PA(e,t,n){for(var r;t.length&&(r=Yo(t)).i<=n;)t.pop(),e.push(r.vs),n++;return n}function FA(e){return function(t,n){return t.barycenter<n.barycenter?-1:t.barycenter>n.barycenter?1:e?n.i-t.i:t.i-n.i}}function IA(e,t,n,r){var i=e.children(t),a=e.node(t),o=a?a.borderLeft:void 0,s=a?a.borderRight:void 0,c={};o&&(i=Qo(i,function(e){return e!==o&&e!==s}));var l=kA(e,i);M(l,function(t){if(e.children(t.v).length){var i=IA(e,t.v,n,r);c[t.v]=i,Object.prototype.hasOwnProperty.call(i,`barycenter`)&&RA(t,i)}});var u=AA(l,n);LA(u,c);var d=NA(u,r);if(o&&(d.vs=fr([o,d.vs,s]),e.predecessors(o).length)){var f=e.node(e.predecessors(o)[0]),p=e.node(e.predecessors(s)[0]);Object.prototype.hasOwnProperty.call(d,`barycenter`)||(d.barycenter=0,d.weight=0),d.barycenter=(d.barycenter*d.weight+f.order+p.order)/(d.weight+2),d.weight+=2}return d}function LA(e,t){M(e,function(e){e.vs=fr(e.vs.map(function(e){return t[e]?t[e].vs:e}))})}function RA(e,t){ys(e.barycenter)?(e.barycenter=t.barycenter,e.weight=t.weight):(e.barycenter=(e.barycenter*e.weight+t.barycenter*t.weight)/(e.weight+t.weight),e.weight+=t.weight)}function zA(e){var t=Dk(e),n=BA(e,ac(1,t+1),`inEdges`),r=BA(e,ac(t-1,-1,-1),`outEdges`),i=OA(e);HA(e,i);for(var a=1/0,o,s=0,c=0;c<4;++s,++c){VA(s%2?n:r,s%4>=2),i=Ck(e);var l=EA(e,i);l<a&&(c=0,o=ja(i),a=l)}HA(e,o)}function BA(e,t,n){return is(t,function(t){return wA(e,t,n)})}function VA(e,t){var n=new _O;M(e,function(e){var r=e.graph().root,i=IA(e,r,n,t);M(i.vs,function(t,n){e.node(t).order=n}),CA(e,n,i.vs)})}function HA(e,t){M(t,function(t){M(t,function(t,n){e.node(t).order=n})})}function UA(e){var t=GA(e);M(e.graph().dummyChains,function(n){for(var r=e.node(n),i=r.edgeObj,a=WA(e,t,i.v,i.w),o=a.path,s=a.lca,c=0,l=o[c],u=!0;n!==i.w;){if(r=e.node(n),u){for(;(l=o[c])!==s&&e.node(l).maxRank<r.rank;)c++;l===s&&(u=!1)}if(!u){for(;c<o.length-1&&e.node(l=o[c+1]).minRank<=r.rank;)c++;l=o[c]}e.setParent(n,l),n=e.successors(n)[0]}})}function WA(e,t,n,r){var i=[],a=[],o=Math.min(t[n].low,t[r].low),s=Math.max(t[n].lim,t[r].lim),c=n,l;do c=e.parent(c),i.push(c);while(c&&(t[c].low>o||s>t[c].lim));for(l=c,c=r;(c=e.parent(c))!==l;)a.push(c);return{path:i.concat(a.reverse()),lca:l}}function GA(e){var t={},n=0;function r(i){var a=n;M(e.children(i),r),t[i]={low:a,lim:n++}}return M(e.children(),r),t}function KA(e,t){var n={};function r(t,r){var i=0,a=0,o=t.length,s=Yo(r);return M(r,function(t,c){var l=JA(e,t),u=l?e.node(l).order:o;(l||t===s)&&(M(r.slice(a,c+1),function(t){M(e.predecessors(t),function(r){var a=e.node(r),o=a.order;(o<i||u<o)&&!(a.dummy&&e.node(t).dummy)&&YA(n,r,t)})}),a=c+1,i=u)}),r}return sc(t,r),n}function qA(e,t){var n={};function r(t,r,i,a,o){var s;M(ac(r,i),function(r){s=t[r],e.node(s).dummy&&M(e.predecessors(s),function(t){var r=e.node(t);r.dummy&&(r.order<a||r.order>o)&&YA(n,t,s)})})}function i(t,n){var i=-1,a,o=0;return M(n,function(s,c){if(e.node(s).dummy===`border`){var l=e.predecessors(s);l.length&&(a=e.node(l[0]).order,r(n,o,c,i,a),o=c,i=a)}r(n,o,n.length,a,t.length)}),n}return sc(t,i),n}function JA(e,t){if(e.node(t).dummy)return ns(e.predecessors(t),function(t){return e.node(t).dummy})}function YA(e,t,n){if(t>n){var r=t;t=n,n=r}Object.prototype.hasOwnProperty.call(e,t)||Object.defineProperty(e,t,{enumerable:!0,configurable:!0,value:{},writable:!0});var i=e[t];Object.defineProperty(i,n,{enumerable:!0,configurable:!0,value:!0,writable:!0})}function XA(e,t,n){if(t>n){var r=t;t=n,n=r}return!!e[t]&&Object.prototype.hasOwnProperty.call(e[t],n)}function ZA(e,t,n,r){var i={},a={},o={};return M(t,function(e){M(e,function(e,t){i[e]=e,a[e]=e,o[e]=t})}),M(t,function(e){var t=-1;M(e,function(e){var s=r(e);if(s.length){s=dc(s,function(e){return o[e]});for(var c=(s.length-1)/2,l=Math.floor(c),u=Math.ceil(c);l<=u;++l){var d=s[l];a[e]===e&&t<o[d]&&!XA(n,e,d)&&(a[d]=e,a[e]=i[e]=i[d],t=o[d])}}})}),{root:i,align:a}}function QA(e,t,n,r,i){var a={},o=$A(e,t,n,i),s=i?`borderLeft`:`borderRight`;function c(e,t){for(var n=o.nodes(),r=n.pop(),i={};r;)i[r]?e(r):(i[r]=!0,n.push(r),n=n.concat(t(r))),r=n.pop()}function l(e){a[e]=o.inEdges(e).reduce(function(e,t){return Math.max(e,a[t.v]+o.edge(t))},0)}function u(t){var n=o.outEdges(t).reduce(function(e,t){return Math.min(e,a[t.w]-o.edge(t))},1/0),r=e.node(t);n!==1/0&&r.borderType!==s&&(a[t]=Math.max(a[t],n))}return c(l,o.predecessors.bind(o)),c(u,o.successors.bind(o)),M(r,function(e){a[e]=a[n[e]]}),a}function $A(e,t,n,r){var i=new _O,a=e.graph(),o=ij(a.nodesep,a.edgesep,r);return M(t,function(t){var r;M(t,function(t){var a=n[t];if(i.setNode(a),r){var s=n[r],c=i.edge(s,a);i.setEdge(s,a,Math.max(o(e,t,r),c||0))}r=t})}),i}function ej(e,t){return Es(ms(t),function(t){var n=-1/0,r=1/0;return as(t,function(t,i){var a=aj(e,i)/2;n=Math.max(t+a,n),r=Math.min(t-a,r)}),n-r})}function tj(e,t){var n=ms(t),r=Ts(n),i=Cs(n);M([`u`,`d`],function(n){M([`l`,`r`],function(a){var o=n+a,s=e[o],c;if(s!==t){var l=ms(s);c=a===`l`?r-Ts(l):i-Cs(l),c&&(e[o]=xs(s,function(e){return e+c}))}})})}function nj(e,t){return xs(e.ul,function(n,r){if(t)return e[t.toLowerCase()][r];var i=dc(is(e,r));return(i[1]+i[2])/2})}function rj(e){var t=Ck(e),n=ws(KA(e,t),qA(e,t)),r={},i;return M([`u`,`d`],function(a){i=a===`u`?t:ms(t).reverse(),M([`l`,`r`],function(t){t===`r`&&(i=is(i,function(e){return ms(e).reverse()}));var o=(a===`u`?e.predecessors:e.successors).bind(e),s=ZA(e,i,n,o),c=QA(e,i,s.root,s.align,t===`r`);t===`r`&&(c=xs(c,function(e){return-e})),r[a+t]=c})}),tj(r,ej(e,r)),nj(r,e.graph().align)}function ij(e,t,n){return function(r,i,a){var o=r.node(i),s=r.node(a),c=0,l;if(c+=o.width/2,Object.prototype.hasOwnProperty.call(o,`labelpos`))switch(o.labelpos.toLowerCase()){case`l`:l=-o.width/2;break;case`r`:l=o.width/2}if(l&&(c+=n?l:-l),l=0,c+=(o.dummy?t:e)/2,c+=(s.dummy?t:e)/2,c+=s.width/2,Object.prototype.hasOwnProperty.call(s,`labelpos`))switch(s.labelpos.toLowerCase()){case`l`:l=s.width/2;break;case`r`:l=-s.width/2}return l&&(c+=n?l:-l),l=0,c}}function aj(e,t){return e.node(t).width}function oj(e){e=xk(e),sj(e),os(rj(e),function(t,n){e.node(n).x=t})}function sj(e){var t=Ck(e),n=e.graph().ranksep,r=0;M(t,function(t){var i=Cs(is(t,function(t){return e.node(t).height}));M(t,function(t){e.node(t).y=r+i/2}),r+=i+n})}function cj(e,t){var n=t&&t.debugTiming?kk:Ak;n(`layout`,()=>{var t=n(` buildLayoutGraph`,()=>yj(e));n(` runLayout`,()=>lj(t,n)),n(` updateInputGraph`,()=>uj(e,t))})}function lj(e,t){t(` makeSpaceForEdgeLabels`,()=>bj(e)),t(` removeSelfEdges`,()=>kj(e)),t(` acyclic`,()=>gk(e)),t(` nestingGraph.run`,()=>vA(e)),t(` rank`,()=>mA(xk(e))),t(` injectEdgeLabelProxies`,()=>xj(e)),t(` removeEmptyRanks`,()=>Tk(e)),t(` nestingGraph.cleanup`,()=>SA(e)),t(` normalizeRanks`,()=>wk(e)),t(` assignRankMinMax`,()=>Sj(e)),t(` removeEdgeLabelProxies`,()=>Cj(e)),t(` normalize.run`,()=>Vk(e)),t(` parentDummyChains`,()=>UA(e)),t(` addBorderSegments`,()=>jk(e)),t(` order`,()=>zA(e)),t(` insertSelfEdges`,()=>Aj(e)),t(` adjustCoordinateSystem`,()=>Nk(e)),t(` position`,()=>oj(e)),t(` positionSelfEdges`,()=>jj(e)),t(` removeBorderNodes`,()=>Oj(e)),t(` normalize.undo`,()=>Uk(e)),t(` fixupEdgeLabelCoords`,()=>Ej(e)),t(` undoCoordinateSystem`,()=>Pk(e)),t(` translateGraph`,()=>wj(e)),t(` assignNodeIntersects`,()=>Tj(e)),t(` reversePoints`,()=>Dj(e)),t(` acyclic.undo`,()=>vk(e))}function uj(e,t){M(e.nodes(),function(n){var r=e.node(n),i=t.node(n);r&&(r.x=i.x,r.y=i.y,t.children(n).length&&(r.width=i.width,r.height=i.height))}),M(e.edges(),function(n){var r=e.edge(n),i=t.edge(n);r.points=i.points,Object.prototype.hasOwnProperty.call(i,`x`)&&(r.x=i.x,r.y=i.y)}),e.graph().width=t.graph().width,e.graph().height=t.graph().height}var dj=[`nodesep`,`edgesep`,`ranksep`,`marginx`,`marginy`],fj={ranksep:50,edgesep:20,nodesep:50,rankdir:`tb`},pj=[`acyclicer`,`ranker`,`rankdir`,`align`],mj=[`width`,`height`],hj={width:0,height:0},gj=[`minlen`,`weight`,`width`,`height`,`labeloffset`],_j={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:`r`},vj=[`labelpos`];function yj(e){var t=new _O({multigraph:!0,compound:!0}),n=Nj(e.graph());return t.setGraph(ws({},fj,Mj(n,dj),ec(n,pj))),M(e.nodes(),function(n){var r=Nj(e.node(n));t.setNode(n,Vo(Mj(r,mj),hj)),t.setParent(n,e.parent(n))}),M(e.edges(),function(n){var r=Nj(e.edge(n));t.setEdge(n,ws({},_j,Mj(r,gj),ec(r,vj)))}),t}function bj(e){var t=e.graph();t.ranksep/=2,M(e.edges(),function(n){var r=e.edge(n);r.minlen*=2,r.labelpos.toLowerCase()!==`c`&&(t.rankdir===`TB`||t.rankdir===`BT`?r.width+=r.labeloffset:r.height+=r.labeloffset)})}function xj(e){M(e.edges(),function(t){var n=e.edge(t);if(n.width&&n.height){var r=e.node(t.v);yk(e,`edge-proxy`,{rank:(e.node(t.w).rank-r.rank)/2+r.rank,e:t},`_ep`)}})}function Sj(e){var t=0;M(e.nodes(),function(n){var r=e.node(n);r.borderTop&&(r.minRank=e.node(r.borderTop).rank,r.maxRank=e.node(r.borderBottom).rank,t=Cs(t,r.maxRank))}),e.graph().maxRank=t}function Cj(e){M(e.nodes(),function(t){var n=e.node(t);n.dummy===`edge-proxy`&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))})}function wj(e){var t=1/0,n=0,r=1/0,i=0,a=e.graph(),o=a.marginx||0,s=a.marginy||0;function c(e){var a=e.x,o=e.y,s=e.width,c=e.height;t=Math.min(t,a-s/2),n=Math.max(n,a+s/2),r=Math.min(r,o-c/2),i=Math.max(i,o+c/2)}M(e.nodes(),function(t){c(e.node(t))}),M(e.edges(),function(t){var n=e.edge(t);Object.prototype.hasOwnProperty.call(n,`x`)&&c(n)}),t-=o,r-=s,M(e.nodes(),function(n){var i=e.node(n);i.x-=t,i.y-=r}),M(e.edges(),function(n){var i=e.edge(n);M(i.points,function(e){e.x-=t,e.y-=r}),Object.prototype.hasOwnProperty.call(i,`x`)&&(i.x-=t),Object.prototype.hasOwnProperty.call(i,`y`)&&(i.y-=r)}),a.width=n-t+o,a.height=i-r+s}function Tj(e){M(e.edges(),function(t){var n=e.edge(t),r=e.node(t.v),i=e.node(t.w),a,o;n.points?(a=n.points[0],o=n.points[n.points.length-1]):(n.points=[],a=i,o=r),n.points.unshift(Sk(r,a)),n.points.push(Sk(i,o))})}function Ej(e){M(e.edges(),function(t){var n=e.edge(t);if(Object.prototype.hasOwnProperty.call(n,`x`))switch((n.labelpos===`l`||n.labelpos===`r`)&&(n.width-=n.labeloffset),n.labelpos){case`l`:n.x-=n.width/2+n.labeloffset;break;case`r`:n.x+=n.width/2+n.labeloffset}})}function Dj(e){M(e.edges(),function(t){var n=e.edge(t);n.reversed&&n.points.reverse()})}function Oj(e){M(e.nodes(),function(t){if(e.children(t).length){var n=e.node(t),r=e.node(n.borderTop),i=e.node(n.borderBottom),a=e.node(Yo(n.borderLeft)),o=e.node(Yo(n.borderRight));n.width=Math.abs(o.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),M(e.nodes(),function(t){e.node(t).dummy===`border`&&e.removeNode(t)})}function kj(e){M(e.edges(),function(t){if(t.v===t.w){var n=e.node(t.v);n.selfEdges||=[],n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}})}function Aj(e){M(Ck(e),function(t){var n=0;M(t,function(t,r){var i=e.node(t);i.order=r+n,M(i.selfEdges,function(t){yk(e,`selfedge`,{width:t.label.width,height:t.label.height,rank:i.rank,order:r+ ++n,e:t.e,label:t.label},`_se`)}),delete i.selfEdges})})}function jj(e){M(e.nodes(),function(t){var n=e.node(t);if(n.dummy===`selfedge`){var r=e.node(n.e.v),i=r.x+r.width/2,a=r.y,o=n.x-i,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:i+2*o/3,y:a-s},{x:i+5*o/6,y:a-s},{x:i+o,y:a},{x:i+5*o/6,y:a+s},{x:i+2*o/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}})}function Mj(e,t){return xs(ec(e,t),Number)}function Nj(e){var t={};return M(e,function(e,n){t[n.toLowerCase()]=e}),t}var Pj=n({applyDagreLayoutResult:()=>Jj,getEdgesToRender:()=>Hj,measureDagreLayout:()=>Qj,prepareLayoutForDagre:()=>Zj,render:()=>eM,runDagreLayoutCore:()=>$j}),Fj=N((e,t,n)=>Math.max(t,Math.min(n,e)),`clamp`),Ij=N((e=`TB`)=>{switch(e){case`BT`:return`bottom`;case`LR`:return`right`;case`RL`:return`left`;default:return`top`}},`getDefaultSelfLoopSide`),Lj=N(e=>e===`flowchart`||e===`flowchart-v2`||e===`stateDiagram`||e===`er`||e===`classDiagram`,`shouldMergeSelfLoopSegments`),Rj=[`x`,`y`,`width`,`height`,`labelBBox`,`intersect`,`calcIntersect`,`diff`,`clusterNode`],zj=N((e,t,n,r,i)=>{let a=[],o=new Set;if(n.forEach(({start:e,end:t})=>{e!==r&&o.add(e),t!==r&&o.add(t)}),o.forEach(t=>{let n=e.node(t);typeof n?.x==`number`&&typeof n?.y==`number`&&a.push(n)}),a.length===0&&n.forEach(({edge:e})=>{(e.points??[]).forEach(e=>{typeof e?.x==`number`&&typeof e?.y==`number`&&a.push(e)})}),a.length===0)return Ij(i);let s=a.reduce((e,t)=>({x:e.x+t.x/a.length,y:e.y+t.y/a.length}),{x:0,y:0}),c=s.x-t.x,l=s.y-t.y;return Math.abs(c)>Math.abs(l)?c>0?`right`:`left`:Math.abs(l)>0?l>0?`bottom`:`top`:Ij(i)},`getSelfLoopSide`),Bj=N((e,t=`top`,n=0,r=0)=>{let i=e.x,a=e.y-n,o=e.width/2,s=e.height/2,c=Math.max(36,Math.min(100,e.width*.8)),l=Fj(Math.max(r,e.width*.35),36,c),u=Fj(Math.min(e.width,e.height)*.45,24,48);switch(t){case`bottom`:{let e=a+s;return[{x:i-l/2,y:e},{x:i-l/2,y:e+u},{x:i+l/2,y:e+u},{x:i+l/2,y:e}]}case`right`:{let e=i+o;return[{x:e,y:a-l/2},{x:e+u,y:a-l/2},{x:e+u,y:a+l/2},{x:e,y:a+l/2}]}case`left`:{let e=i-o;return[{x:e,y:a-l/2},{x:e-u,y:a-l/2},{x:e-u,y:a+l/2},{x:e,y:a+l/2}]}default:{let e=a-s;return[{x:i-l/2,y:e},{x:i-l/2,y:e-u},{x:i+l/2,y:e-u},{x:i+l/2,y:e}]}}},`getSelfLoopPoints`),Vj=N((e,t,n=`top`,r=0,i={})=>{let a=e.x,o=e.y-r,s=i.width??0,c=i.height??0;switch(n){case`bottom`:return{x:a,y:Math.max(...t.map(e=>e.y))+c/2+4};case`right`:return{x:Math.max(...t.map(e=>e.x))+s/2+4,y:o};case`left`:return{x:Math.min(...t.map(e=>e.x))-s/2-4,y:o};default:return{x:a,y:Math.min(...t.map(e=>e.y))-c/2-4}}},`getSelfLoopLabelPosition`),Hj=N((e,t=0,{mergeSelfLoops:n=!0}={})=>{let r=new Map,i=[],a=e.graph()?.rankdir;return e.edges().forEach(t=>{let a=e.edge(t);if(n&&a.selfLoop){let e=a.selfLoop.id;r.has(e)||r.set(e,[]),r.get(e).push({edge:a,start:t.v,end:t.w})}else i.push({edge:a,start:t.v,end:t.w})}),r.forEach(n=>{if(n.length!==3){n.forEach(e=>i.push(e));return}n.sort((e,t)=>e.edge.selfLoop.order-t.edge.selfLoop.order);let[r,o,s]=n,c=r.edge.originalEdge??o.edge.originalEdge??s.edge.originalEdge??o.edge,l=e.node(c.start);if(!l){n.forEach(e=>i.push(e));return}let u={width:o.edge.width,height:o.edge.height},d=zj(e,l,n,c.start,a),f=Bj(l,d,t,u.width??0),p=Vj(l,f,d,t,u),m={...o.edge,...c,id:c.id,points:f,start:c.start,end:c.end,x:p.x,y:p.y,width:u.width,height:u.height,labelStyle:o.edge.labelStyle,fromCluster:r.edge.fromCluster??o.edge.fromCluster??s.edge.fromCluster,toCluster:r.edge.toCluster??o.edge.toCluster??s.edge.toCluster};delete m.selfLoop,delete m.originalEdge,i.push({edge:m,start:m.start,end:m.end})}),i},`getEdgesToRender`),Uj=N(async({element:e,graph:t,diagramType:n,id:r,parentCluster:i,siteConfig:a})=>{let o=t.graph().rankdir;P.trace(`Dir in recursive render - dir:`,o);let{clusters:s,edgePaths:c,edgeLabels:l,nodes:u,rootGroups:d}=kO(e,{edgePathsClass:`edgePaths`});t.nodes()?P.info(`Recursive render XXX`,t.nodes()):P.info(`No nodes found for`,t),t.edges().length>0&&P.info(`Recursive edges`,t.edge(t.edges()[0]));let f=Lj(n);await Promise.all(t.nodes().map(async function(e){let s=t.node(e);if(i!==void 0){let n=JSON.parse(JSON.stringify(i.clusterData));P.trace(`Setting data for parent cluster XXX
|
|
270
|
+
L0,20`).attr(`stroke-linejoin`,`miter`)},`requirement_arrow_neo`),requirement_contains_neo:N((e,t,n)=>{let{themeVariables:r}=pd(),{strokeWidth:i}=r,a=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`g`);a.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),a.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),a.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10),a.selectAll(`*`).attr(`stroke-width`,`${i}`)},`requirement_contains_neo`)},pO=dO,mO=`\0`,hO=`\0`,gO=``,_O=class{constructor(e={}){this._isDirected=!Object.prototype.hasOwnProperty.call(e,`directed`)||e.directed,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,`multigraph`)?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,`compound`)?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=He(void 0),this._defaultEdgeLabelFn=He(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[hO]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return _e(e)||(e=He(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return pn(this._nodes)}sources(){var e=this;return Qo(this.nodes(),function(t){return vs(e._in[t])})}sinks(){var e=this;return Qo(this.nodes(),function(t){return vs(e._out[t])})}setNodes(e,t){var n=arguments,r=this;return M(e,function(e){n.length>1?r.setNode(e,t):r.setNode(e)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=hO,this._children[e]={},this._children[hO][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var t=e=>this.removeEdge(this._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],M(this.children(e),e=>{this.setParent(e)}),delete this._children[e]),M(pn(this._in[e]),t),delete this._in[e],delete this._preds[e],M(pn(this._out[e]),t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw Error(`Cannot set parent in a non-compound graph`);if(ys(t))t=hO;else{t+=``;for(var n=t;!ys(n);n=this.parent(n))if(n===e)throw Error(`Setting `+t+` as parent of `+e+` would create a cycle`);this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==hO)return t}}children(e){if(ys(e)&&(e=hO),this._isCompound){var t=this._children[e];if(t)return pn(t)}else if(e===hO)return this.nodes();else if(this.hasNode(e))return[]}predecessors(e){var t=this._preds[e];if(t)return pn(t)}successors(e){var t=this._sucs[e];if(t)return pn(t)}neighbors(e){var t=this.predecessors(e);if(t)return hc(t,this.successors(e))}isLeaf(e){return(this.isDirected()?this.successors(e):this.neighbors(e)).length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;M(this._nodes,function(n,r){e(r)&&t.setNode(r,n)}),M(this._edgeObjs,function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))});var r={};function i(e){var a=n.parent(e);return a===void 0||t.hasNode(a)?(r[e]=a,a):a in r?r[a]:i(a)}return this._isCompound&&M(t.nodes(),function(e){t.setParent(e,i(e))}),t}setDefaultEdgeLabel(e){return _e(e)||(e=He(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return ms(this._edgeObjs)}setPath(e,t){var n=this,r=arguments;return sc(e,function(e,i){return r.length>1?n.setEdge(e,i,t):n.setEdge(e,i),i}),this}setEdge(){var e,t,n,r,i=!1,a=arguments[0];typeof a==`object`&&a&&`v`in a?(e=a.v,t=a.w,n=a.name,arguments.length===2&&(r=arguments[1],i=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),e=``+e,t=``+t,ys(n)||(n=``+n);var o=bO(this._isDirected,e,t,n);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,o))return i&&(this._edgeLabels[o]=r),this;if(!ys(n)&&!this._isMultigraph)throw Error(`Cannot set a named edge when isMultigraph = false`);this.setNode(e),this.setNode(t),this._edgeLabels[o]=i?r:this._defaultEdgeLabelFn(e,t,n);var s=xO(this._isDirected,e,t,n);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[o]=s,vO(this._preds[t],e),vO(this._sucs[e],t),this._in[t][o]=s,this._out[e][o]=s,this._edgeCount++,this}edge(e,t,n){var r=arguments.length===1?SO(this._isDirected,arguments[0]):bO(this._isDirected,e,t,n);return this._edgeLabels[r]}hasEdge(e,t,n){var r=arguments.length===1?SO(this._isDirected,arguments[0]):bO(this._isDirected,e,t,n);return Object.prototype.hasOwnProperty.call(this._edgeLabels,r)}removeEdge(e,t,n){var r=arguments.length===1?SO(this._isDirected,arguments[0]):bO(this._isDirected,e,t,n),i=this._edgeObjs[r];return i&&(e=i.v,t=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],yO(this._preds[t],e),yO(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this}inEdges(e,t){var n=this._in[e];if(n){var r=ms(n);return t?Qo(r,function(e){return e.v===t}):r}}outEdges(e,t){var n=this._out[e];if(n){var r=ms(n);return t?Qo(r,function(e){return e.w===t}):r}}nodeEdges(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}};_O.prototype._nodeCount=0,_O.prototype._edgeCount=0;function vO(e,t){e[t]?e[t]++:e[t]=1}function yO(e,t){--e[t]||delete e[t]}function bO(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}return i+gO+a+gO+(ys(r)?mO:r)}function xO(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function SO(e,t){return bO(e,t.v,t.w,t.name)}var CO=N(async(e,t)=>{let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{clusterBkg:a,clusterBorder:o}=r,s=o,{labelStyles:c,nodeStyles:l,borderStyles:u,backgroundStyles:d}=W(t),f=e.insert(`g`).attr(`class`,`cluster swimlane `+(t.cssClasses||``)).attr(`id`,t.id).attr(`data-id`,t.id).attr(`data-et`,`cluster`).attr(`data-look`,t.look),p=nd(n.flowchart.htmlLabels),m=t.direction===`LR`,h=f.insert(`g`).attr(`class`,`cluster-label swimlane-label`),g=await DC(h,t.label,{style:t.labelStyle,useHtmlLabels:p,isNode:!0,width:t.width}),_=g.getBBox();if(p){let e=g.children[0],t=U(g);_=e.getBoundingClientRect(),t.attr(`width`,_.width),t.attr(`height`,_.height)}let v=t.padding??0,y=t.width<=_.width+v?_.width+v:t.width;t.diff=t.width<=_.width+v?(y-t.width)/2-v:-v;let b=t.height,x=t.y-b/2,S=t.y+b/2,C=t.x-y/2,w=t.swimlaneContentTop===void 0?x+b/3:t.swimlaneContentTop,T=m?4:0,E=_.height+2*T,D,O;if(m){let e=Math.max(E,_.height+2*T),n=C+e,r=Math.max(0,y-e);if(t.look===`handDrawn`){let o=q.svg(f),c=G(t,{roughness:.7,fill:a,stroke:s,fillWeight:3,seed:i}),l=G(t,{roughness:.7,fill:`none`,stroke:s,seed:i}),p=o.rectangle(C,x,e,b,c);D=f.insert(()=>p,`:first-child`);let m=o.rectangle(n,x,r,b,l);O=f.insert(()=>m,`:first-child`),D.select(`path:nth-child(2)`).attr(`style`,u.join(`;`)),D.select(`path`).attr(`style`,d.join(`;`).replace(`fill`,`stroke`))}else D=f.insert(`rect`,`:first-child`),O=f.insert(`rect`,`:first-child`),D.attr(`class`,`swimlane-title`).attr(`style`,l).attr(`x`,C).attr(`y`,x).attr(`width`,e).attr(`height`,b).attr(`fill`,a).attr(`stroke`,s),O.attr(`class`,`swimlane-body`).attr(`style`,l).attr(`x`,n).attr(`y`,x).attr(`width`,r).attr(`height`,b).attr(`fill`,`none`).attr(`stroke`,s);let o=C+e/2,c=t.y;h.attr(`transform`,`translate(${o}, ${c}) rotate(-90) translate(${-_.width/2}, ${-_.height/2})`)}else{let e=Math.max(0,w-x),n=Math.min(E,e),r=x+n,o=Math.max(0,S-r),c=t.x-y/2;if(t.look===`handDrawn`){let e=q.svg(f),l=G(t,{roughness:.7,fill:a,stroke:s,fillWeight:3,seed:i}),p=G(t,{roughness:.7,fill:`none`,stroke:s,seed:i}),m=e.rectangle(c,x,y,n,l);D=f.insert(()=>m,`:first-child`);let h=e.rectangle(c,r,y,o,p);O=f.insert(()=>h,`:first-child`),D.select(`path:nth-child(2)`).attr(`style`,u.join(`;`)),D.select(`path`).attr(`style`,d.join(`;`).replace(`fill`,`stroke`))}else D=f.insert(`rect`,`:first-child`),O=f.insert(`rect`,`:first-child`),D.attr(`class`,`swimlane-title`).attr(`style`,l).attr(`x`,c).attr(`y`,x).attr(`width`,y).attr(`height`,n).attr(`fill`,a).attr(`stroke`,s),O.attr(`class`,`swimlane-body`).attr(`style`,l).attr(`x`,c).attr(`y`,r).attr(`width`,y).attr(`height`,o).attr(`fill`,`none`).attr(`stroke`,s);let p=t.x-_.width/2,m=x+(n-_.height)/2;h.attr(`transform`,`translate(${p}, ${m})`)}if(P.trace(`Swimlane data `,t,JSON.stringify(t)),c){let e=h.select(`span`);e&&e.attr(`style`,c)}return t.offsetX=0,t.width=y,t.height=b,t.offsetY=_.height-v/2,t.intersect=function(e){return Yw(t,e)},{cluster:f,labelBBox:_}},`swimlane`),wO=N(async(e,t)=>{P.info(`Creating subgraph rect for `,t.id,t);let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{clusterBkg:a,clusterBorder:o}=r,{labelStyles:s,nodeStyles:c,borderStyles:l,backgroundStyles:u}=W(t),d=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),f=Sd(n),p=d.insert(`g`).attr(`class`,`cluster-label `),m;m=t.labelType===`markdown`?await DC(p,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width}):await Zw(p,t.label,t.labelStyle||``,!1,!0);let h=m.getBBox();if(Sd(n)){let e=m.children[0],t=U(m);h=e.getBoundingClientRect(),t.attr(`width`,h.width),t.attr(`height`,h.height)}let g=t.width<=h.width+t.padding?h.width+t.padding:t.width;t.diff=t.width<=h.width+t.padding?(g-t.width)/2-t.padding:-t.padding;let _=t.height,v=t.x-g/2,y=t.y-_/2;P.trace(`Data `,t,JSON.stringify(t));let b;if(t.look===`handDrawn`){let e=q.svg(d),n=G(t,{roughness:.7,fill:a,stroke:o,fillWeight:3,seed:i}),r=e.path(Xw(v,y,g,_,0),n);b=d.insert(()=>(P.debug(`Rough node insert CXC`,r),r),`:first-child`),b.select(`path:nth-child(2)`).attr(`style`,l.join(`;`)),b.select(`path`).attr(`style`,u.join(`;`).replace(`fill`,`stroke`))}else b=d.insert(`rect`,`:first-child`),b.attr(`style`,c).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,v).attr(`y`,y).attr(`width`,g).attr(`height`,_);let{subGraphTitleTopMargin:x}=OD(n);if(p.attr(`transform`,`translate(${t.x-h.width/2}, ${t.y-t.height/2+x})`),s){let e=p.select(`span`);e&&e.attr(`style`,s)}let S=b.node().getBBox();return t.offsetX=0,t.width=S.width,t.height=S.height,t.offsetY=h.height-t.padding/2,t.intersect=function(e){return Yw(t,e)},{cluster:d,labelBBox:h}},`rect`),TO={rect:wO,squareRect:wO,roundedWithTitle:N(async(e,t)=>{let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{altBackground:a,compositeBackground:o,compositeTitleBackground:s,nodeBorder:c}=r,l=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-id`,t.id).attr(`data-look`,t.look),u=l.insert(`g`,`:first-child`),d=l.insert(`g`).attr(`class`,`cluster-label`),f=l.append(`rect`),p=await Zw(d,t.label,t.labelStyle,void 0,!0),m=p.getBBox();if(Sd(n)){let e=p.children[0],t=U(p);m=e.getBoundingClientRect(),t.attr(`width`,m.width),t.attr(`height`,m.height)}let h=0*t.padding,g=h/2,_=(t.width<=m.width+t.padding?m.width+t.padding:t.width)+h;t.diff=t.width<=m.width+t.padding?(_-t.width)/2-t.padding:-t.padding;let v=t.height+h,y=t.height+h-m.height-6,b=t.x-_/2,x=t.y-v/2;t.width=_;let S=t.y-t.height/2-g+m.height+2,C;if(t.look===`handDrawn`){let e=t.cssClasses.includes(`statediagram-cluster-alt`),n=q.svg(l),r=t.rx||t.ry?n.path(Xw(b,x,_,v,10),{roughness:.7,fill:s,fillStyle:`solid`,stroke:c,seed:i}):n.rectangle(b,x,_,v,{seed:i});C=l.insert(()=>r,`:first-child`);let u=n.rectangle(b,S,_,y,{fill:e?a:o,fillStyle:e?`hachure`:`solid`,stroke:c,seed:i});C=l.insert(()=>r,`:first-child`),f=l.insert(()=>u)}else C=u.insert(`rect`,`:first-child`),C.attr(`class`,`outer`).attr(`x`,b).attr(`y`,x).attr(`width`,_).attr(`height`,v).attr(`data-look`,t.look),f.attr(`class`,`inner`).attr(`x`,b).attr(`y`,S).attr(`width`,_).attr(`height`,y);return d.attr(`transform`,`translate(${t.x-m.width/2}, ${x+1-(Sd(n)?0:3)})`),t.height=C.node().getBBox().height,t.offsetX=0,t.offsetY=m.height-t.padding/2,t.labelBBox=m,t.intersect=function(e){return Yw(t,e)},{cluster:l,labelBBox:m}},`roundedWithTitle`),noteGroup:N((e,t)=>{let n=e.insert(`g`).attr(`class`,`note-cluster`).attr(`id`,t.domId),r=n.insert(`rect`,`:first-child`),i=0*t.padding,a=i/2;r.attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,t.x-t.width/2-a).attr(`y`,t.y-t.height/2-a).attr(`width`,t.width+i).attr(`height`,t.height+i).attr(`fill`,`none`);let o=r.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(e){return Yw(t,e)},{cluster:n,labelBBox:{width:0,height:0}}},`noteGroup`),divider:N((e,t)=>{let{themeVariables:n,handDrawnSeed:r}=H(),{nodeBorder:i}=n,a=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),o=a.insert(`g`,`:first-child`),s=0*t.padding,c=t.width+s;t.diff=-t.padding;let l=t.height+s,u=t.x-c/2,d=t.y-l/2;t.width=c;let f;if(t.look===`handDrawn`){let e=q.svg(a).rectangle(u,d,c,l,{fill:`lightgrey`,roughness:.5,strokeLineDash:[5],stroke:i,seed:r});f=a.insert(()=>e,`:first-child`)}else{f=o.insert(`rect`,`:first-child`);let e=`outer`;e=(t.look,`divider`),f.attr(`class`,e).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l).attr(`data-look`,t.look)}return t.height=f.node().getBBox().height,t.offsetX=0,t.offsetY=0,t.intersect=function(e){return Yw(t,e)},{cluster:a,labelBBox:{}}},`divider`),kanbanSection:N(async(e,t)=>{P.info(`Creating subgraph rect for `,t.id,t);let n=H(),{themeVariables:r,handDrawnSeed:i}=n,{clusterBkg:a,clusterBorder:o}=r,{labelStyles:s,nodeStyles:c,borderStyles:l,backgroundStyles:u}=W(t),d=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),f=Sd(n),p=d.insert(`g`).attr(`class`,`cluster-label `),m=await DC(p,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width}),h=m.getBBox();if(Sd(n)){let e=m.children[0],t=U(m);h=e.getBoundingClientRect(),t.attr(`width`,h.width),t.attr(`height`,h.height)}let g=t.width<=h.width+t.padding?h.width+t.padding:t.width;t.diff=t.width<=h.width+t.padding?(g-t.width)/2-t.padding:-t.padding;let _=t.height,v=t.x-g/2,y=t.y-_/2;P.trace(`Data `,t,JSON.stringify(t));let b;if(t.look===`handDrawn`){let e=q.svg(d),n=G(t,{roughness:.7,fill:a,stroke:o,fillWeight:4,seed:i}),r=e.path(Xw(v,y,g,_,t.rx),n);b=d.insert(()=>(P.debug(`Rough node insert CXC`,r),r),`:first-child`),b.select(`path:nth-child(2)`).attr(`style`,l.join(`;`)),b.select(`path`).attr(`style`,u.join(`;`).replace(`fill`,`stroke`))}else b=d.insert(`rect`,`:first-child`),b.attr(`style`,c).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,v).attr(`y`,y).attr(`width`,g).attr(`height`,_);let{subGraphTitleTopMargin:x}=OD(n);if(p.attr(`transform`,`translate(${t.x-h.width/2}, ${t.y-t.height/2+x})`),s){let e=p.select(`span`);e&&e.attr(`style`,s)}let S=b.node().getBBox();return t.offsetX=0,t.width=S.width,t.height=S.height,t.offsetY=h.height-t.padding/2,t.intersect=function(e){return Yw(t,e)},{cluster:d,labelBBox:h}},`kanbanSection`),swimlane:CO},EO=new Map,DO=N(async(e,t)=>{let n=await TO[t.shape||`rect`](e,t);return EO.set(t.id,n),n},`insertCluster`),OO=N(()=>{EO=new Map},`clear`);function kO(e,{edgePathsClass:t=`edges edgePaths`}={}){let n=e.insert(`g`).attr(`class`,`root`);return{clusters:n.insert(`g`).attr(`class`,`clusters`),edgePaths:n.insert(`g`).attr(`class`,t),edgeLabels:n.insert(`g`).attr(`class`,`edgeLabels`),nodes:n.insert(`g`).attr(`class`,`nodes`),rootGroups:n}}N(kO,`createLayoutElementGroups`);async function AO(e,t){if(t.label){let{shapeSvg:n,bbox:r}=await J(e,t);t.labelBBox={width:r.width,height:r.height},n.remove()}else t.labelBBox={width:0,height:0}}N(AO,`measureGroupLabel`);async function jO(e,t,n){let r=await AD(e,t,n),i=r.node()?.getBBox()??{width:0,height:0};return t.width=i.width,t.height=i.height,r}N(jO,`insertMeasuredNode`);async function MO(e,t){let n=new _O({multigraph:!0,compound:!0}),r=[...t.edges],i=H(),a=kO(e),{edgeLabels:o,nodes:s}=a,c=new Map,l=e.node()!=null;await Promise.all(t.nodes.map(async e=>{if(e.isGroup)l&&await AO(s,e),n.setNode(e.id,{...e});else{if(l){let t=await jO(s,e,{config:i,dir:e.dir});c.set(e.id,t)}n.setNode(e.id,{...e})}}));for(let e of r)l&&JD(e)&&await XD(o,e),n.setEdge(e.start,e.end,{...e},e.id),t.edges.some(t=>t.id===e.id)||t.edges.push(e);if(globalThis.mermaidCaptureSizes){let{captureNodeSizes:n}=await Tc(async()=>{let{captureNodeSizes:e}=await import(`./vendor-O17eRefg.js`).then(e=>e.u);return{captureNodeSizes:e}},__vite__mapDeps([0,1,2,3,4]));n(e,t)}return{graph:n,groups:a,nodeElements:c}}N(MO,`createGraphWithElements`);var $=new Map,NO=new Map,PO=new Map,FO=N(()=>{NO.clear(),PO.clear(),$.clear()},`clear`),IO=N((e,t)=>{let n=NO.get(t)||[];return P.trace(`In isDescendant`,t,` `,e,` = `,n.includes(e)),n.includes(e)},`isDescendant`),LO=N((e,t)=>{let n=NO.get(t)||[];return P.info(`Descendants of `,t,` is `,n),P.info(`Edge is `,e),e.v===t||e.w===t?!1:n?n.includes(e.v)||IO(e.v,t)||IO(e.w,t)||n.includes(e.w):(P.debug(`Tilt, `,t,`,not in descendants`),!1)},`edgeInCluster`),RO=N((e,t,n,r)=>{P.debug(`Copying children of `,e,`root`,r,`data`,t.node(e),r);let i=t.children(e)||[];e!==r&&i.push(e),P.debug(`Copying (nodes) clusterId`,e,`nodes`,i),i.forEach(i=>{if(t.children(i).length>0)RO(i,t,n,r);else{let a=t.node(i);P.info(`cp `,i,` to `,r,` with parent `,e),n.setNode(i,a),r!==t.parent(i)&&(P.debug(`Setting parent`,i,t.parent(i)),n.setParent(i,t.parent(i))),e!==r&&i!==e?(P.debug(`Setting parent`,i,e),n.setParent(i,e)):(P.info(`In copy `,e,`root`,r,`data`,t.node(e),r),P.debug(`Not Setting parent for node=`,i,`cluster!==rootId`,e!==r,`node!==clusterId`,i!==e));let o=t.edges(i);P.debug(`Copying Edges`,o),o.forEach(i=>{P.info(`Edge`,i);let a=t.edge(i.v,i.w,i.name);P.info(`Edge data`,a,r);try{LO(i,r)?(P.info(`Copying as `,i.v,i.w,a,i.name),n.setEdge(i.v,i.w,a,i.name),P.info(`newGraph edges `,n.edges(),n.edge(n.edges()[0]))):P.info(`Skipping copy of edge `,i.v,`-->`,i.w,` rootId: `,r,` clusterId:`,e)}catch(e){P.error(e)}})}P.debug(`Removing node`,i),t.removeNode(i)})},`copy`),zO=N((e,t)=>{let n=t.children(e),r=[...n];for(let i of n)PO.set(i,e),r=[...r,...zO(i,t)];return r},`extractDescendants`),BO=N((e,t,n)=>{let r=e.edges().filter(e=>e.v===t||e.w===t),i=e.edges().filter(e=>e.v===n||e.w===n),a=r.map(e=>({v:e.v===t?n:e.v,w:e.w===t?t:e.w})),o=i.map(e=>({v:e.v,w:e.w}));return a.filter(e=>o.some(t=>e.v===t.v&&e.w===t.w))},`findCommonEdges`),VO=N((e,t,n)=>{let r=t.children(e);if(P.trace(`Searching children of id `,e,r),r.length<1)return e;let i;for(let e of r){let r=VO(e,t,n),a=BO(t,n,r);if(r){if(a.length>0)i=r;else return r}}return i},`findNonClusterChild`),HO=N(e=>!$.has(e)||!$.get(e).externalConnections?e:$.has(e)?$.get(e).id:e,`getAnchorId`),UO=N((e,t)=>{if(!e||t>10){P.debug(`Opting out, no graph `);return}P.debug(`Opting in, graph `),e.nodes().forEach(function(t){e.children(t).length>0&&(P.debug(`Cluster identified`,t,` Replacement id in edges: `,VO(t,e,t)),NO.set(t,zO(t,e)),$.set(t,{id:VO(t,e,t),clusterData:e.node(t)}))}),e.nodes().forEach(function(t){let n=e.children(t),r=e.edges();n.length>0?(P.debug(`Cluster identified`,t,NO),r.forEach(e=>{IO(e.v,t)^IO(e.w,t)&&(P.debug(`Edge: `,e,` leaves cluster `,t),P.debug(`Descendants of XXX `,t,`: `,NO.get(t)),$.get(t).externalConnections=!0)})):P.debug(`Not a cluster `,t,NO)});for(let t of $.keys()){let n=$.get(t).id,r=e.parent(n);r!==t&&$.has(r)&&!$.get(r).externalConnections&&($.get(t).id=r);let i=e.edges().some(e=>e.v===t);if(n&&$.get(t)?.externalConnections&&i&&qO(e,n,t)){let r=JO(e,t,e.parent(n));r&&($.get(t).id=r)}}e.edges().forEach(function(t){let n=e.edge(t);P.debug(`Edge `+t.v+` -> `+t.w+`: `+JSON.stringify(t)),P.debug(`Edge `+t.v+` -> `+t.w+`: `+JSON.stringify(e.edge(t)));let r=t.v,i=t.w;if(P.debug(`Fix XXX`,$,`ids:`,t.v,t.w,`Translating: `,$.get(t.v),` --- `,$.get(t.w)),$.get(t.v)||$.get(t.w)){if(P.debug(`Fixing and trying - removing XXX`,t.v,t.w,t.name),r=HO(t.v),i=HO(t.w),e.removeEdge(t.v,t.w,t.name),r!==t.v){let i=e.parent(r);$.get(i).externalConnections=!0,n.fromCluster=t.v}if(i!==t.w){let r=e.parent(i);$.get(r).externalConnections=!0,n.toCluster=t.w}P.debug(`Fix Replacing with XXX`,r,i,t.name),e.setEdge(r,i,n,t.name)}}),WO(e,0),P.trace($)},`adjustClustersAndEdges`),WO=N((e,t)=>{if(t>10){P.error(`Bailing out`);return}let n=e.nodes(),r=!1;for(let t of n){let n=e.children(t);r||=n.length>0}if(!r){P.debug(`Done, no node has children`,e.nodes());return}P.debug(`Nodes = `,n,t);for(let r of n)if(P.debug(`Extracting node`,r,$,$.has(r)&&!$.get(r).externalConnections,!e.parent(r),e.node(r),e.children(`D`),` Depth `,t),!$.has(r))P.debug(`Not a cluster`,r,t);else if(!$.get(r).externalConnections&&e.children(r)&&e.children(r).length>0){P.debug(`Cluster without external connections, without a parent and with children`,r,t);let n=e.graph().rankdir===`TB`?`LR`:`TB`;$.get(r)?.clusterData?.dir&&(n=$.get(r).clusterData.dir,P.debug(`Fixing dir`,$.get(r).clusterData.dir,n));let i=new _O({multigraph:!0,compound:!0}).setGraph({rankdir:n,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});RO(r,e,i,r),e.setNode(r,{clusterNode:!0,id:r,clusterData:$.get(r).clusterData,label:$.get(r).label,graph:i})}else P.debug(`Cluster ** `,r,` **not meeting the criteria !externalConnections:`,!$.get(r).externalConnections,` no parent: `,!e.parent(r),` children `,e.children(r)&&e.children(r).length>0,e.children(`D`),t),P.debug($);n=e.nodes(),P.debug(`New list of nodes`,n);for(let r of n){let n=e.node(r);P.debug(` Now next level`,r,n),n?.clusterNode&&WO(n.graph,t+1)}},`extractor`),GO=N((e,t)=>{if(t.length===0)return[];let n=Object.assign([],t);return t.forEach(t=>{let r=GO(e,e.children(t));n=[...n,...r]}),n},`sorter`),KO=N(e=>GO(e,e.children()),`sortNodesByHierarchy`),qO=N((e,t,n)=>{let r=e.parent(t);for(;r&&r!==n;){let t=$.get(r);if(t&&!t.externalConnections)return!0;r=e.parent(r)}return!1},`isNodeInExtractableCluster`),JO=N((e,t,n)=>{let r=e.children(t)??[];for(let i of r){if(i===n||IO(i,n))continue;let r=VO(i,e,t);if(r&&!qO(e,r,t))return r}return null},`findSafeAnchorNode`);function YO({prepareLayout:e,measureLayout:t,runLayoutCore:n,paintLayout:r,afterPaint:i,paintOptions:a}){let o=t??ZO;return N(async function(t,s,c,l){let u=s.select(`g`);(c?.insertMarkers??pO)(u,t.markers,t.type,t.diagramId),XO();let d={element:u,helpers:c,options:l};d.preparedLayout=await e?.(t,d);let f=await o(t,d),p=await n(t,d),m={...d,measure:f};r?await r(t,m,p):await QO(t,m,a),await i?.(t,m,p)},`render`)}N(YO,`createCommonLayoutRenderer`);function XO(){MD(),qD(),OO(),FO()}N(XO,`clearLayoutRenderState`);async function ZO(e,{element:t}){return await MO(t,e)}N(ZO,`defaultMeasureLayout`);async function QO(e,t,n={}){let{measure:r}=t,{groups:i}=r;for(let r of n.getNodes?.(e,t)??e.nodes)n.skipNode?.(r,t)||await $O(i,r,t,n);let a=tk(e.nodes);for(let r of e.edges)nk(r,n)||await rk(i,r,a,e,n,t)}N(QO,`paintLayoutData`);async function $O(e,t,n,r){t.clusterNode?ND(t):ek(t,n,r)?await DO(e.clusters,t):ND(t)}N($O,`paintLayoutNode`);function ek(e,t,n){return e.isGroup===!0&&(n.isCluster?.(e,t)??!0)}N(ek,`shouldPaintAsCluster`);function tk(e){let t=new Map;for(let n of e)n?.id&&t.set(n.id,n);return t}N(tk,`buildNodeLookup`);function nk(e,t){return e.isLayoutOnly||!!t.skipEdge?.(e)}N(nk,`shouldSkipPaintEdge`);async function rk(e,t,n,r,i,a){let o=sO(e.edgePaths,{...t},i.clusterDb??new Map,r.type,ik(t.start,t,n,a,i),ik(t.end,t,n,a,i),r.diagramId,ak(t,i));JD(t)&&(GD.has(t.id)||await XD(e.edgeLabels,t),ok(t,o))}N(rk,`paintLayoutEdge`);function ik(e,t,n,r,i){return i.getEdgeNode?.(e,t,r)??(e?n.get(e)??{}:{})}N(ik,`getRenderedNode`);function ak(e,t){return typeof t.skipIntersect==`function`?t.skipIntersect(e):t.skipIntersect??!1}N(ak,`shouldSkipIntersect`);function ok(e,t){let n=t?.updatedPath??t?.originalPath,{subGraphTitleTotalMargin:r}=OD({flowchart:pd().flowchart??{}});if(e.label){let i=GD.get(e.id),a=e.x,o=e.y;if(n){let r=gx.calcLabelPosition(n);P.debug(`Moving label `+e.label+` from (`,a,`,`,o,`) to (`,r.x,`,`,r.y,`) abc88`),t?.updatedPath&&(a=r.x,o=r.y)}i.attr(`transform`,`translate(${a}, ${o+r/2})`)}if(e?.startLabelLeft){let t=KD.get(e.id).startLeft,r=e?.x,i=e?.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_left`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}if(e.startLabelRight){let t=KD.get(e.id).startRight,r=e.x,i=e.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_right`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}if(e.endLabelLeft){let t=KD.get(e.id).endLeft,r=e.x,i=e.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_left`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}if(e.endLabelRight){let t=KD.get(e.id).endRight,r=e.x,i=e.y;if(n){let t=gx.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_right`,n);r=t.x,i=t.y}t.attr(`transform`,`translate(${r}, ${i})`)}}N(ok,`positionRenderedEdgeLabel`);var sk=class{constructor(){var e={};e._next=e._prev=e,this._sentinel=e}dequeue(){var e=this._sentinel,t=e._prev;if(t!==e)return ck(t),t}enqueue(e){var t=this._sentinel;e._prev&&e._next&&ck(e),e._next=t._next,t._next._prev=e,t._next=e,e._prev=t}toString(){for(var e=[],t=this._sentinel,n=t._prev;n!==t;)e.push(JSON.stringify(n,lk)),n=n._prev;return`[`+e.join(`, `)+`]`}};function ck(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function lk(e,t){if(e!==`_next`&&e!==`_prev`)return t}var uk=He(1);function dk(e,t){if(e.nodeCount()<=1)return[];var n=mk(e,t||uk);return fr(is(fk(n.graph,n.buckets,n.zeroIdx),function(t){return e.outEdges(t.v,t.w)}))}function fk(e,t,n){for(var r=[],i=t[t.length-1],a=t[0],o;e.nodeCount();){for(;o=a.dequeue();)pk(e,t,n,o);for(;o=i.dequeue();)pk(e,t,n,o);if(e.nodeCount()){for(var s=t.length-2;s>0;--s)if(o=t[s].dequeue(),o){r=r.concat(pk(e,t,n,o,!0));break}}}return r}function pk(e,t,n,r,i){var a=i?[]:void 0;return M(e.inEdges(r.v),function(r){var o=e.edge(r),s=e.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,hk(t,n,s)}),M(e.outEdges(r.v),function(r){var i=e.edge(r),a=r.w,o=e.node(a);o.in-=i,hk(t,n,o)}),e.removeNode(r.v),a}function mk(e,t){var n=new _O,r=0,i=0;M(e.nodes(),function(e){n.setNode(e,{v:e,in:0,out:0})}),M(e.edges(),function(e){var a=n.edge(e.v,e.w)||0,o=t(e),s=a+o;n.setEdge(e.v,e.w,s),i=Math.max(i,n.node(e.v).out+=o),r=Math.max(r,n.node(e.w).in+=o)});var a=ac(i+r+3).map(function(){return new sk}),o=r+1;return M(n.nodes(),function(e){hk(a,o,n.node(e))}),{graph:n,buckets:a,zeroIdx:o}}function hk(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}function gk(e){M(e.graph().acyclicer===`greedy`?dk(e,t(e)):_k(e),function(t){var n=e.edge(t);e.removeEdge(t),n.forwardName=t.name,n.reversed=!0,e.setEdge(t.w,t.v,n,_c(`rev`))});function t(e){return function(t){return e.edge(t).weight}}}function _k(e){var t=[],n={},r={};function i(a){Object.prototype.hasOwnProperty.call(r,a)||(r[a]=!0,n[a]=!0,M(e.outEdges(a),function(e){Object.prototype.hasOwnProperty.call(n,e.w)?t.push(e):i(e.w)}),delete n[a])}return M(e.nodes(),i),t}function vk(e){M(e.edges(),function(t){var n=e.edge(t);if(n.reversed){e.removeEdge(t);var r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}})}function yk(e,t,n,r){var i;do i=_c(r);while(e.hasNode(i));return n.dummy=t,e.setNode(i,n),i}function bk(e){var t=new _O().setGraph(e.graph());return M(e.nodes(),function(n){t.setNode(n,e.node(n))}),M(e.edges(),function(n){var r=t.edge(n.v,n.w)||{weight:0,minlen:1},i=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})}),t}function xk(e){var t=new _O({multigraph:e.isMultigraph()}).setGraph(e.graph());return M(e.nodes(),function(n){e.children(n).length||t.setNode(n,e.node(n))}),M(e.edges(),function(n){t.setEdge(n,e.edge(n))}),t}function Sk(e,t){var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2;if(!i&&!a)throw Error(`Not possible to find intersection inside of the rectangle`);var c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=s*i/a,l=s):(i<0&&(o=-o),c=o,l=o*a/i),{x:n+c,y:r+l}}function Ck(e){var t=is(ac(Dk(e)+1),function(){return[]});return M(e.nodes(),function(n){var r=e.node(n),i=r.rank;ys(i)||(t[i][r.order]=n)}),t}function wk(e){var t=Ts(is(e.nodes(),function(t){return e.node(t).rank}));M(e.nodes(),function(n){var r=e.node(n);us(r,`rank`)&&(r.rank-=t)})}function Tk(e){var t=Ts(is(e.nodes(),function(t){return e.node(t).rank})),n=[];M(e.nodes(),function(r){var i=e.node(r).rank-t;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=e.graph().nodeRankFactor;M(n,function(t,n){ys(t)&&n%i!==0?--r:r&&M(t,function(t){e.node(t).rank+=r})})}function Ek(e,t,n,r){var i={width:0,height:0};return arguments.length>=4&&(i.rank=n,i.order=r),yk(e,`border`,i,t)}function Dk(e){return Cs(is(e.nodes(),function(t){var n=e.node(t).rank;if(!ys(n))return n}))}function Ok(e,t){var n={lhs:[],rhs:[]};return M(e,function(e){t(e)?n.lhs.push(e):n.rhs.push(e)}),n}function kk(e,t){var n=Ro();try{return t()}finally{console.log(e+` time: `+(Ro()-n)+`ms`)}}function Ak(e,t){return t()}function jk(e){function t(n){var r=e.children(n),i=e.node(n);if(r.length&&M(r,t),Object.prototype.hasOwnProperty.call(i,`minRank`)){i.borderLeft=[],i.borderRight=[];for(var a=i.minRank,o=i.maxRank+1;a<o;++a)Mk(e,`borderLeft`,`_bl`,n,i,a),Mk(e,`borderRight`,`_br`,n,i,a)}}M(e.children(),t)}function Mk(e,t,n,r,i,a){var o={width:0,height:0,rank:a,borderType:t},s=i[t][a-1],c=yk(e,`border`,o,n);i[t][a]=c,e.setParent(c,r),s&&e.setEdge(s,c,{weight:1})}function Nk(e){var t=e.graph().rankdir.toLowerCase();(t===`lr`||t===`rl`)&&Fk(e)}function Pk(e){var t=e.graph().rankdir.toLowerCase();(t===`bt`||t===`rl`)&&Lk(e),(t===`lr`||t===`rl`)&&(zk(e),Fk(e))}function Fk(e){M(e.nodes(),function(t){Ik(e.node(t))}),M(e.edges(),function(t){Ik(e.edge(t))})}function Ik(e){var t=e.width;e.width=e.height,e.height=t}function Lk(e){M(e.nodes(),function(t){Rk(e.node(t))}),M(e.edges(),function(t){var n=e.edge(t);M(n.points,Rk),Object.prototype.hasOwnProperty.call(n,`y`)&&Rk(n)})}function Rk(e){e.y=-e.y}function zk(e){M(e.nodes(),function(t){Bk(e.node(t))}),M(e.edges(),function(t){var n=e.edge(t);M(n.points,Bk),Object.prototype.hasOwnProperty.call(n,`x`)&&Bk(n)})}function Bk(e){var t=e.x;e.x=e.y,e.y=t}function Vk(e){e.graph().dummyChains=[],M(e.edges(),function(t){Hk(e,t)})}function Hk(e,t){var n=t.v,r=e.node(n).rank,i=t.w,a=e.node(i).rank,o=t.name,s=e.edge(t),c=s.labelRank;if(a!==r+1){e.removeEdge(t);var l=void 0,u,d=0;for(++r;r<a;++d,++r)s.points=[],l={width:0,height:0,edgeLabel:s,edgeObj:t,rank:r},u=yk(e,`edge`,l,`_d`),r===c&&(l.width=s.width,l.height=s.height,l.dummy=`edge-label`,l.labelpos=s.labelpos),e.setEdge(n,u,{weight:s.weight},o),d===0&&e.graph().dummyChains.push(u),n=u;e.setEdge(n,i,{weight:s.weight},o)}}function Uk(e){M(e.graph().dummyChains,function(t){var n=e.node(t),r=n.edgeLabel,i;for(e.setEdge(n.edgeObj,r);n.dummy;)i=e.successors(t)[0],e.removeNode(t),r.points.push({x:n.x,y:n.y}),n.dummy===`edge-label`&&(r.x=n.x,r.y=n.y,r.width=n.width,r.height=n.height),t=i,n=e.node(t)})}function Wk(e){var t={};function n(r){var i=e.node(r);if(Object.prototype.hasOwnProperty.call(t,r))return i.rank;t[r]=!0;var a=Ts(is(e.outEdges(r),function(t){return n(t.w)-e.edge(t).minlen}));return(a===1/0||a==null)&&(a=0),i.rank=a}M(e.sources(),n)}function Gk(e,t){return e.node(t.w).rank-e.node(t.v).rank-e.edge(t).minlen}function Kk(e){var t=new _O({directed:!1}),n=e.nodes()[0],r=e.nodeCount();t.setNode(n,{});for(var i,a;qk(t,e)<r;)i=Jk(t,e),a=t.hasNode(i.v)?Gk(e,i):-Gk(e,i),Yk(t,e,a);return t}function qk(e,t){function n(r){M(t.nodeEdges(r),function(i){var a=i.v,o=r===a?i.w:a;!e.hasNode(o)&&!Gk(t,i)&&(e.setNode(o,{}),e.setEdge(r,o,{}),n(o))})}return M(e.nodes(),n),e.nodeCount()}function Jk(e,t){return Es(t.edges(),function(n){if(e.hasNode(n.v)!==e.hasNode(n.w))return Gk(t,n)})}function Yk(e,t,n){M(e.nodes(),function(e){t.node(e).rank+=n})}Xk.CycleException=Zk;function Xk(e){var t={},n={},r=[];function i(a){if(Object.prototype.hasOwnProperty.call(n,a))throw new Zk;Object.prototype.hasOwnProperty.call(t,a)||(n[a]=!0,t[a]=!0,M(e.predecessors(a),i),delete n[a],r.push(a))}if(M(e.sinks(),i),uc(t)!==e.nodeCount())throw new Zk;return r}function Zk(){}Zk.prototype=Error();function Qk(e,t,n){C(t)||(t=[t]);var r=(e.isDirected()?e.successors:e.neighbors).bind(e),i=[],a={};return M(t,function(t){if(!e.hasNode(t))throw Error(`Graph does not have node: `+t);$k(e,t,n===`post`,a,r,i)}),i}function $k(e,t,n,r,i,a){Object.prototype.hasOwnProperty.call(r,t)||(r[t]=!0,n||a.push(t),M(i(t),function(t){$k(e,t,n,r,i,a)}),n&&a.push(t))}function eA(e,t){return Qk(e,t,`post`)}function tA(e,t){return Qk(e,t,`pre`)}nA.initLowLimValues=oA,nA.initCutValues=rA,nA.calcCutValue=aA,nA.leaveEdge=cA,nA.enterEdge=lA,nA.exchangeEdges=uA;function nA(e){e=bk(e),Wk(e);var t=Kk(e);oA(t),rA(t,e);for(var n,r;n=cA(t);)r=lA(t,e,n),uA(t,e,n,r)}function rA(e,t){var n=eA(e,e.nodes());n=n.slice(0,n.length-1),M(n,function(n){iA(e,t,n)})}function iA(e,t,n){var r=e.node(n).parent;e.edge(n,r).cutvalue=aA(e,t,n)}function aA(e,t,n){var r=e.node(n).parent,i=!0,a=t.edge(n,r),o=0;return a||=(i=!1,t.edge(r,n)),o=a.weight,M(t.nodeEdges(n),function(a){var s=a.v===n,c=s?a.w:a.v;if(c!==r){var l=s===i,u=t.edge(a).weight;if(o+=l?u:-u,fA(e,n,c)){var d=e.edge(n,c).cutvalue;o+=l?-d:d}}}),o}function oA(e,t){arguments.length<2&&(t=e.nodes()[0]),sA(e,{},1,t)}function sA(e,t,n,r,i){var a=n,o=e.node(r);return t[r]=!0,M(e.neighbors(r),function(i){Object.prototype.hasOwnProperty.call(t,i)||(n=sA(e,t,n,i,r))}),o.low=a,o.lim=n++,i?o.parent=i:delete o.parent,n}function cA(e){return ns(e.edges(),function(t){return e.edge(t).cutvalue<0})}function lA(e,t,n){var r=n.v,i=n.w;t.hasEdge(r,i)||(r=n.w,i=n.v);var a=e.node(r),o=e.node(i),s=a,c=!1;return a.lim>o.lim&&(s=o,c=!0),Es(Qo(t.edges(),function(t){return c===pA(e,e.node(t.v),s)&&c!==pA(e,e.node(t.w),s)}),function(e){return Gk(t,e)})}function uA(e,t,n,r){var i=n.v,a=n.w;e.removeEdge(i,a),e.setEdge(r.v,r.w,{}),oA(e),rA(e,t),dA(e,t)}function dA(e,t){var n=tA(e,ns(e.nodes(),function(e){return!t.node(e).parent}));n=n.slice(1),M(n,function(n){var r=e.node(n).parent,i=t.edge(n,r),a=!1;i||(i=t.edge(r,n),a=!0),t.node(n).rank=t.node(r).rank+(a?i.minlen:-i.minlen)})}function fA(e,t,n){return e.hasEdge(t,n)}function pA(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}function mA(e){switch(e.graph().ranker){case`network-simplex`:_A(e);break;case`tight-tree`:gA(e);break;case`longest-path`:hA(e);break;default:_A(e)}}var hA=Wk;function gA(e){Wk(e),Kk(e)}function _A(e){nA(e)}function vA(e){var t=yk(e,`root`,{},`_root`),n=bA(e),r=Cs(ms(n))-1,i=2*r+1;e.graph().nestingRoot=t,M(e.edges(),function(t){e.edge(t).minlen*=i});var a=xA(e)+1;M(e.children(),function(o){yA(e,t,i,a,r,n,o)}),e.graph().nodeRankFactor=i}function yA(e,t,n,r,i,a,o){var s=e.children(o);if(!s.length){o!==t&&e.setEdge(t,o,{weight:0,minlen:n});return}var c=Ek(e,`_bt`),l=Ek(e,`_bb`),u=e.node(o);e.setParent(c,o),u.borderTop=c,e.setParent(l,o),u.borderBottom=l,M(s,function(s){yA(e,t,n,r,i,a,s);var u=e.node(s),d=u.borderTop?u.borderTop:s,f=u.borderBottom?u.borderBottom:s,p=u.borderTop?r:2*r,m=d===f?i-a[o]+1:1;e.setEdge(c,d,{weight:p,minlen:m,nestingEdge:!0}),e.setEdge(f,l,{weight:p,minlen:m,nestingEdge:!0})}),e.parent(o)||e.setEdge(t,c,{weight:0,minlen:i+a[o]})}function bA(e){var t={};function n(r,i){var a=e.children(r);a&&a.length&&M(a,function(e){n(e,i+1)}),t[r]=i}return M(e.children(),function(e){n(e,1)}),t}function xA(e){return sc(e.edges(),function(t,n){return t+e.edge(n).weight},0)}function SA(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,M(e.edges(),function(t){e.edge(t).nestingEdge&&e.removeEdge(t)})}function CA(e,t,n){var r={},i;M(n,function(n){for(var a=e.parent(n),o,s;a;){if(o=e.parent(a),o?(s=r[o],r[o]=a):(s=i,i=a),s&&s!==a){t.setEdge(s,a);return}a=o}})}function wA(e,t,n){var r=TA(e),i=new _O({compound:!0}).setGraph({root:r}).setDefaultNodeLabel(function(t){return e.node(t)});return M(e.nodes(),function(a){var o=e.node(a),s=e.parent(a);(o.rank===t||o.minRank<=t&&t<=o.maxRank)&&(i.setNode(a),i.setParent(a,s||r),M(e[n](a),function(t){var n=t.v===a?t.w:t.v,r=i.edge(n,a),o=ys(r)?0:r.weight;i.setEdge(n,a,{weight:e.edge(t).weight+o})}),Object.prototype.hasOwnProperty.call(o,`minRank`)&&i.setNode(a,{borderLeft:o.borderLeft[t],borderRight:o.borderRight[t]}))}),i}function TA(e){for(var t;e.hasNode(t=_c(`_root`)););return t}function EA(e,t){for(var n=0,r=1;r<t.length;++r)n+=DA(e,t[r-1],t[r]);return n}function DA(e,t,n){for(var r=yc(n,is(n,function(e,t){return t})),i=fr(is(t,function(t){return dc(is(e.outEdges(t),function(t){return{pos:r[t.w],weight:e.edge(t).weight}}),`pos`)})),a=1;a<n.length;)a<<=1;var o=2*a-1;--a;var s=is(Array(o),function(){return 0}),c=0;return M(i.forEach(function(e){var t=e.pos+a;s[t]+=e.weight;for(var n=0;t>0;)t%2&&(n+=s[t+1]),t=t-1>>1,s[t]+=e.weight;c+=e.weight*n})),c}function OA(e){var t={},n=Qo(e.nodes(),function(t){return!e.children(t).length}),r=is(ac(Cs(is(n,function(t){return e.node(t).rank}))+1),function(){return[]});function i(n){us(t,n)||(t[n]=!0,r[e.node(n).rank].push(n),M(e.successors(n),i))}return M(dc(n,function(t){return e.node(t).rank}),i),r}function kA(e,t){return is(t,function(t){var n=e.inEdges(t);if(n.length){var r=sc(n,function(t,n){var r=e.edge(n),i=e.node(n.v);return{sum:t.sum+r.weight*i.order,weight:t.weight+r.weight}},{sum:0,weight:0});return{v:t,barycenter:r.sum/r.weight,weight:r.weight}}return{v:t}})}function AA(e,t){var n={};return M(e,function(e,t){var r=n[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};ys(e.barycenter)||(r.barycenter=e.barycenter,r.weight=e.weight)}),M(t.edges(),function(e){var t=n[e.v],r=n[e.w];!ys(t)&&!ys(r)&&(r.indegree++,t.out.push(n[e.w]))}),jA(Qo(n,function(e){return!e.indegree}))}function jA(e){var t=[];function n(e){return function(t){t.merged||(ys(t.barycenter)||ys(e.barycenter)||t.barycenter>=e.barycenter)&&MA(e,t)}}function r(t){return function(n){n.in.push(t),--n.indegree===0&&e.push(n)}}for(;e.length;){var i=e.pop();t.push(i),M(i.in.reverse(),n(i)),M(i.out,r(i))}return is(Qo(t,function(e){return!e.merged}),function(e){return ec(e,[`vs`,`i`,`barycenter`,`weight`])})}function MA(e,t){var n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}function NA(e,t){var n=Ok(e,function(e){return Object.prototype.hasOwnProperty.call(e,`barycenter`)}),r=n.lhs,i=dc(n.rhs,function(e){return-e.i}),a=[],o=0,s=0,c=0;r.sort(FA(!!t)),c=PA(a,i,c),M(r,function(e){c+=e.vs.length,a.push(e.vs),o+=e.barycenter*e.weight,s+=e.weight,c=PA(a,i,c)});var l={vs:fr(a)};return s&&(l.barycenter=o/s,l.weight=s),l}function PA(e,t,n){for(var r;t.length&&(r=Yo(t)).i<=n;)t.pop(),e.push(r.vs),n++;return n}function FA(e){return function(t,n){return t.barycenter<n.barycenter?-1:t.barycenter>n.barycenter?1:e?n.i-t.i:t.i-n.i}}function IA(e,t,n,r){var i=e.children(t),a=e.node(t),o=a?a.borderLeft:void 0,s=a?a.borderRight:void 0,c={};o&&(i=Qo(i,function(e){return e!==o&&e!==s}));var l=kA(e,i);M(l,function(t){if(e.children(t.v).length){var i=IA(e,t.v,n,r);c[t.v]=i,Object.prototype.hasOwnProperty.call(i,`barycenter`)&&RA(t,i)}});var u=AA(l,n);LA(u,c);var d=NA(u,r);if(o&&(d.vs=fr([o,d.vs,s]),e.predecessors(o).length)){var f=e.node(e.predecessors(o)[0]),p=e.node(e.predecessors(s)[0]);Object.prototype.hasOwnProperty.call(d,`barycenter`)||(d.barycenter=0,d.weight=0),d.barycenter=(d.barycenter*d.weight+f.order+p.order)/(d.weight+2),d.weight+=2}return d}function LA(e,t){M(e,function(e){e.vs=fr(e.vs.map(function(e){return t[e]?t[e].vs:e}))})}function RA(e,t){ys(e.barycenter)?(e.barycenter=t.barycenter,e.weight=t.weight):(e.barycenter=(e.barycenter*e.weight+t.barycenter*t.weight)/(e.weight+t.weight),e.weight+=t.weight)}function zA(e){var t=Dk(e),n=BA(e,ac(1,t+1),`inEdges`),r=BA(e,ac(t-1,-1,-1),`outEdges`),i=OA(e);HA(e,i);for(var a=1/0,o,s=0,c=0;c<4;++s,++c){VA(s%2?n:r,s%4>=2),i=Ck(e);var l=EA(e,i);l<a&&(c=0,o=ja(i),a=l)}HA(e,o)}function BA(e,t,n){return is(t,function(t){return wA(e,t,n)})}function VA(e,t){var n=new _O;M(e,function(e){var r=e.graph().root,i=IA(e,r,n,t);M(i.vs,function(t,n){e.node(t).order=n}),CA(e,n,i.vs)})}function HA(e,t){M(t,function(t){M(t,function(t,n){e.node(t).order=n})})}function UA(e){var t=GA(e);M(e.graph().dummyChains,function(n){for(var r=e.node(n),i=r.edgeObj,a=WA(e,t,i.v,i.w),o=a.path,s=a.lca,c=0,l=o[c],u=!0;n!==i.w;){if(r=e.node(n),u){for(;(l=o[c])!==s&&e.node(l).maxRank<r.rank;)c++;l===s&&(u=!1)}if(!u){for(;c<o.length-1&&e.node(l=o[c+1]).minRank<=r.rank;)c++;l=o[c]}e.setParent(n,l),n=e.successors(n)[0]}})}function WA(e,t,n,r){var i=[],a=[],o=Math.min(t[n].low,t[r].low),s=Math.max(t[n].lim,t[r].lim),c=n,l;do c=e.parent(c),i.push(c);while(c&&(t[c].low>o||s>t[c].lim));for(l=c,c=r;(c=e.parent(c))!==l;)a.push(c);return{path:i.concat(a.reverse()),lca:l}}function GA(e){var t={},n=0;function r(i){var a=n;M(e.children(i),r),t[i]={low:a,lim:n++}}return M(e.children(),r),t}function KA(e,t){var n={};function r(t,r){var i=0,a=0,o=t.length,s=Yo(r);return M(r,function(t,c){var l=JA(e,t),u=l?e.node(l).order:o;(l||t===s)&&(M(r.slice(a,c+1),function(t){M(e.predecessors(t),function(r){var a=e.node(r),o=a.order;(o<i||u<o)&&!(a.dummy&&e.node(t).dummy)&&YA(n,r,t)})}),a=c+1,i=u)}),r}return sc(t,r),n}function qA(e,t){var n={};function r(t,r,i,a,o){var s;M(ac(r,i),function(r){s=t[r],e.node(s).dummy&&M(e.predecessors(s),function(t){var r=e.node(t);r.dummy&&(r.order<a||r.order>o)&&YA(n,t,s)})})}function i(t,n){var i=-1,a,o=0;return M(n,function(s,c){if(e.node(s).dummy===`border`){var l=e.predecessors(s);l.length&&(a=e.node(l[0]).order,r(n,o,c,i,a),o=c,i=a)}r(n,o,n.length,a,t.length)}),n}return sc(t,i),n}function JA(e,t){if(e.node(t).dummy)return ns(e.predecessors(t),function(t){return e.node(t).dummy})}function YA(e,t,n){if(t>n){var r=t;t=n,n=r}Object.prototype.hasOwnProperty.call(e,t)||Object.defineProperty(e,t,{enumerable:!0,configurable:!0,value:{},writable:!0});var i=e[t];Object.defineProperty(i,n,{enumerable:!0,configurable:!0,value:!0,writable:!0})}function XA(e,t,n){if(t>n){var r=t;t=n,n=r}return!!e[t]&&Object.prototype.hasOwnProperty.call(e[t],n)}function ZA(e,t,n,r){var i={},a={},o={};return M(t,function(e){M(e,function(e,t){i[e]=e,a[e]=e,o[e]=t})}),M(t,function(e){var t=-1;M(e,function(e){var s=r(e);if(s.length){s=dc(s,function(e){return o[e]});for(var c=(s.length-1)/2,l=Math.floor(c),u=Math.ceil(c);l<=u;++l){var d=s[l];a[e]===e&&t<o[d]&&!XA(n,e,d)&&(a[d]=e,a[e]=i[e]=i[d],t=o[d])}}})}),{root:i,align:a}}function QA(e,t,n,r,i){var a={},o=$A(e,t,n,i),s=i?`borderLeft`:`borderRight`;function c(e,t){for(var n=o.nodes(),r=n.pop(),i={};r;)i[r]?e(r):(i[r]=!0,n.push(r),n=n.concat(t(r))),r=n.pop()}function l(e){a[e]=o.inEdges(e).reduce(function(e,t){return Math.max(e,a[t.v]+o.edge(t))},0)}function u(t){var n=o.outEdges(t).reduce(function(e,t){return Math.min(e,a[t.w]-o.edge(t))},1/0),r=e.node(t);n!==1/0&&r.borderType!==s&&(a[t]=Math.max(a[t],n))}return c(l,o.predecessors.bind(o)),c(u,o.successors.bind(o)),M(r,function(e){a[e]=a[n[e]]}),a}function $A(e,t,n,r){var i=new _O,a=e.graph(),o=ij(a.nodesep,a.edgesep,r);return M(t,function(t){var r;M(t,function(t){var a=n[t];if(i.setNode(a),r){var s=n[r],c=i.edge(s,a);i.setEdge(s,a,Math.max(o(e,t,r),c||0))}r=t})}),i}function ej(e,t){return Es(ms(t),function(t){var n=-1/0,r=1/0;return as(t,function(t,i){var a=aj(e,i)/2;n=Math.max(t+a,n),r=Math.min(t-a,r)}),n-r})}function tj(e,t){var n=ms(t),r=Ts(n),i=Cs(n);M([`u`,`d`],function(n){M([`l`,`r`],function(a){var o=n+a,s=e[o],c;if(s!==t){var l=ms(s);c=a===`l`?r-Ts(l):i-Cs(l),c&&(e[o]=xs(s,function(e){return e+c}))}})})}function nj(e,t){return xs(e.ul,function(n,r){if(t)return e[t.toLowerCase()][r];var i=dc(is(e,r));return(i[1]+i[2])/2})}function rj(e){var t=Ck(e),n=ws(KA(e,t),qA(e,t)),r={},i;return M([`u`,`d`],function(a){i=a===`u`?t:ms(t).reverse(),M([`l`,`r`],function(t){t===`r`&&(i=is(i,function(e){return ms(e).reverse()}));var o=(a===`u`?e.predecessors:e.successors).bind(e),s=ZA(e,i,n,o),c=QA(e,i,s.root,s.align,t===`r`);t===`r`&&(c=xs(c,function(e){return-e})),r[a+t]=c})}),tj(r,ej(e,r)),nj(r,e.graph().align)}function ij(e,t,n){return function(r,i,a){var o=r.node(i),s=r.node(a),c=0,l;if(c+=o.width/2,Object.prototype.hasOwnProperty.call(o,`labelpos`))switch(o.labelpos.toLowerCase()){case`l`:l=-o.width/2;break;case`r`:l=o.width/2}if(l&&(c+=n?l:-l),l=0,c+=(o.dummy?t:e)/2,c+=(s.dummy?t:e)/2,c+=s.width/2,Object.prototype.hasOwnProperty.call(s,`labelpos`))switch(s.labelpos.toLowerCase()){case`l`:l=s.width/2;break;case`r`:l=-s.width/2}return l&&(c+=n?l:-l),l=0,c}}function aj(e,t){return e.node(t).width}function oj(e){e=xk(e),sj(e),os(rj(e),function(t,n){e.node(n).x=t})}function sj(e){var t=Ck(e),n=e.graph().ranksep,r=0;M(t,function(t){var i=Cs(is(t,function(t){return e.node(t).height}));M(t,function(t){e.node(t).y=r+i/2}),r+=i+n})}function cj(e,t){var n=t&&t.debugTiming?kk:Ak;n(`layout`,()=>{var t=n(` buildLayoutGraph`,()=>yj(e));n(` runLayout`,()=>lj(t,n)),n(` updateInputGraph`,()=>uj(e,t))})}function lj(e,t){t(` makeSpaceForEdgeLabels`,()=>bj(e)),t(` removeSelfEdges`,()=>kj(e)),t(` acyclic`,()=>gk(e)),t(` nestingGraph.run`,()=>vA(e)),t(` rank`,()=>mA(xk(e))),t(` injectEdgeLabelProxies`,()=>xj(e)),t(` removeEmptyRanks`,()=>Tk(e)),t(` nestingGraph.cleanup`,()=>SA(e)),t(` normalizeRanks`,()=>wk(e)),t(` assignRankMinMax`,()=>Sj(e)),t(` removeEdgeLabelProxies`,()=>Cj(e)),t(` normalize.run`,()=>Vk(e)),t(` parentDummyChains`,()=>UA(e)),t(` addBorderSegments`,()=>jk(e)),t(` order`,()=>zA(e)),t(` insertSelfEdges`,()=>Aj(e)),t(` adjustCoordinateSystem`,()=>Nk(e)),t(` position`,()=>oj(e)),t(` positionSelfEdges`,()=>jj(e)),t(` removeBorderNodes`,()=>Oj(e)),t(` normalize.undo`,()=>Uk(e)),t(` fixupEdgeLabelCoords`,()=>Ej(e)),t(` undoCoordinateSystem`,()=>Pk(e)),t(` translateGraph`,()=>wj(e)),t(` assignNodeIntersects`,()=>Tj(e)),t(` reversePoints`,()=>Dj(e)),t(` acyclic.undo`,()=>vk(e))}function uj(e,t){M(e.nodes(),function(n){var r=e.node(n),i=t.node(n);r&&(r.x=i.x,r.y=i.y,t.children(n).length&&(r.width=i.width,r.height=i.height))}),M(e.edges(),function(n){var r=e.edge(n),i=t.edge(n);r.points=i.points,Object.prototype.hasOwnProperty.call(i,`x`)&&(r.x=i.x,r.y=i.y)}),e.graph().width=t.graph().width,e.graph().height=t.graph().height}var dj=[`nodesep`,`edgesep`,`ranksep`,`marginx`,`marginy`],fj={ranksep:50,edgesep:20,nodesep:50,rankdir:`tb`},pj=[`acyclicer`,`ranker`,`rankdir`,`align`],mj=[`width`,`height`],hj={width:0,height:0},gj=[`minlen`,`weight`,`width`,`height`,`labeloffset`],_j={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:`r`},vj=[`labelpos`];function yj(e){var t=new _O({multigraph:!0,compound:!0}),n=Nj(e.graph());return t.setGraph(ws({},fj,Mj(n,dj),ec(n,pj))),M(e.nodes(),function(n){var r=Nj(e.node(n));t.setNode(n,Vo(Mj(r,mj),hj)),t.setParent(n,e.parent(n))}),M(e.edges(),function(n){var r=Nj(e.edge(n));t.setEdge(n,ws({},_j,Mj(r,gj),ec(r,vj)))}),t}function bj(e){var t=e.graph();t.ranksep/=2,M(e.edges(),function(n){var r=e.edge(n);r.minlen*=2,r.labelpos.toLowerCase()!==`c`&&(t.rankdir===`TB`||t.rankdir===`BT`?r.width+=r.labeloffset:r.height+=r.labeloffset)})}function xj(e){M(e.edges(),function(t){var n=e.edge(t);if(n.width&&n.height){var r=e.node(t.v);yk(e,`edge-proxy`,{rank:(e.node(t.w).rank-r.rank)/2+r.rank,e:t},`_ep`)}})}function Sj(e){var t=0;M(e.nodes(),function(n){var r=e.node(n);r.borderTop&&(r.minRank=e.node(r.borderTop).rank,r.maxRank=e.node(r.borderBottom).rank,t=Cs(t,r.maxRank))}),e.graph().maxRank=t}function Cj(e){M(e.nodes(),function(t){var n=e.node(t);n.dummy===`edge-proxy`&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))})}function wj(e){var t=1/0,n=0,r=1/0,i=0,a=e.graph(),o=a.marginx||0,s=a.marginy||0;function c(e){var a=e.x,o=e.y,s=e.width,c=e.height;t=Math.min(t,a-s/2),n=Math.max(n,a+s/2),r=Math.min(r,o-c/2),i=Math.max(i,o+c/2)}M(e.nodes(),function(t){c(e.node(t))}),M(e.edges(),function(t){var n=e.edge(t);Object.prototype.hasOwnProperty.call(n,`x`)&&c(n)}),t-=o,r-=s,M(e.nodes(),function(n){var i=e.node(n);i.x-=t,i.y-=r}),M(e.edges(),function(n){var i=e.edge(n);M(i.points,function(e){e.x-=t,e.y-=r}),Object.prototype.hasOwnProperty.call(i,`x`)&&(i.x-=t),Object.prototype.hasOwnProperty.call(i,`y`)&&(i.y-=r)}),a.width=n-t+o,a.height=i-r+s}function Tj(e){M(e.edges(),function(t){var n=e.edge(t),r=e.node(t.v),i=e.node(t.w),a,o;n.points?(a=n.points[0],o=n.points[n.points.length-1]):(n.points=[],a=i,o=r),n.points.unshift(Sk(r,a)),n.points.push(Sk(i,o))})}function Ej(e){M(e.edges(),function(t){var n=e.edge(t);if(Object.prototype.hasOwnProperty.call(n,`x`))switch((n.labelpos===`l`||n.labelpos===`r`)&&(n.width-=n.labeloffset),n.labelpos){case`l`:n.x-=n.width/2+n.labeloffset;break;case`r`:n.x+=n.width/2+n.labeloffset}})}function Dj(e){M(e.edges(),function(t){var n=e.edge(t);n.reversed&&n.points.reverse()})}function Oj(e){M(e.nodes(),function(t){if(e.children(t).length){var n=e.node(t),r=e.node(n.borderTop),i=e.node(n.borderBottom),a=e.node(Yo(n.borderLeft)),o=e.node(Yo(n.borderRight));n.width=Math.abs(o.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),M(e.nodes(),function(t){e.node(t).dummy===`border`&&e.removeNode(t)})}function kj(e){M(e.edges(),function(t){if(t.v===t.w){var n=e.node(t.v);n.selfEdges||=[],n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}})}function Aj(e){M(Ck(e),function(t){var n=0;M(t,function(t,r){var i=e.node(t);i.order=r+n,M(i.selfEdges,function(t){yk(e,`selfedge`,{width:t.label.width,height:t.label.height,rank:i.rank,order:r+ ++n,e:t.e,label:t.label},`_se`)}),delete i.selfEdges})})}function jj(e){M(e.nodes(),function(t){var n=e.node(t);if(n.dummy===`selfedge`){var r=e.node(n.e.v),i=r.x+r.width/2,a=r.y,o=n.x-i,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:i+2*o/3,y:a-s},{x:i+5*o/6,y:a-s},{x:i+o,y:a},{x:i+5*o/6,y:a+s},{x:i+2*o/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}})}function Mj(e,t){return xs(ec(e,t),Number)}function Nj(e){var t={};return M(e,function(e,n){t[n.toLowerCase()]=e}),t}var Pj=n({applyDagreLayoutResult:()=>Jj,getEdgesToRender:()=>Hj,measureDagreLayout:()=>Qj,prepareLayoutForDagre:()=>Zj,render:()=>eM,runDagreLayoutCore:()=>$j}),Fj=N((e,t,n)=>Math.max(t,Math.min(n,e)),`clamp`),Ij=N((e=`TB`)=>{switch(e){case`BT`:return`bottom`;case`LR`:return`right`;case`RL`:return`left`;default:return`top`}},`getDefaultSelfLoopSide`),Lj=N(e=>e===`flowchart`||e===`flowchart-v2`||e===`stateDiagram`||e===`er`||e===`classDiagram`,`shouldMergeSelfLoopSegments`),Rj=[`x`,`y`,`width`,`height`,`labelBBox`,`intersect`,`calcIntersect`,`diff`,`clusterNode`],zj=N((e,t,n,r,i)=>{let a=[],o=new Set;if(n.forEach(({start:e,end:t})=>{e!==r&&o.add(e),t!==r&&o.add(t)}),o.forEach(t=>{let n=e.node(t);typeof n?.x==`number`&&typeof n?.y==`number`&&a.push(n)}),a.length===0&&n.forEach(({edge:e})=>{(e.points??[]).forEach(e=>{typeof e?.x==`number`&&typeof e?.y==`number`&&a.push(e)})}),a.length===0)return Ij(i);let s=a.reduce((e,t)=>({x:e.x+t.x/a.length,y:e.y+t.y/a.length}),{x:0,y:0}),c=s.x-t.x,l=s.y-t.y;return Math.abs(c)>Math.abs(l)?c>0?`right`:`left`:Math.abs(l)>0?l>0?`bottom`:`top`:Ij(i)},`getSelfLoopSide`),Bj=N((e,t=`top`,n=0,r=0)=>{let i=e.x,a=e.y-n,o=e.width/2,s=e.height/2,c=Math.max(36,Math.min(100,e.width*.8)),l=Fj(Math.max(r,e.width*.35),36,c),u=Fj(Math.min(e.width,e.height)*.45,24,48);switch(t){case`bottom`:{let e=a+s;return[{x:i-l/2,y:e},{x:i-l/2,y:e+u},{x:i+l/2,y:e+u},{x:i+l/2,y:e}]}case`right`:{let e=i+o;return[{x:e,y:a-l/2},{x:e+u,y:a-l/2},{x:e+u,y:a+l/2},{x:e,y:a+l/2}]}case`left`:{let e=i-o;return[{x:e,y:a-l/2},{x:e-u,y:a-l/2},{x:e-u,y:a+l/2},{x:e,y:a+l/2}]}default:{let e=a-s;return[{x:i-l/2,y:e},{x:i-l/2,y:e-u},{x:i+l/2,y:e-u},{x:i+l/2,y:e}]}}},`getSelfLoopPoints`),Vj=N((e,t,n=`top`,r=0,i={})=>{let a=e.x,o=e.y-r,s=i.width??0,c=i.height??0;switch(n){case`bottom`:return{x:a,y:Math.max(...t.map(e=>e.y))+c/2+4};case`right`:return{x:Math.max(...t.map(e=>e.x))+s/2+4,y:o};case`left`:return{x:Math.min(...t.map(e=>e.x))-s/2-4,y:o};default:return{x:a,y:Math.min(...t.map(e=>e.y))-c/2-4}}},`getSelfLoopLabelPosition`),Hj=N((e,t=0,{mergeSelfLoops:n=!0}={})=>{let r=new Map,i=[],a=e.graph()?.rankdir;return e.edges().forEach(t=>{let a=e.edge(t);if(n&&a.selfLoop){let e=a.selfLoop.id;r.has(e)||r.set(e,[]),r.get(e).push({edge:a,start:t.v,end:t.w})}else i.push({edge:a,start:t.v,end:t.w})}),r.forEach(n=>{if(n.length!==3){n.forEach(e=>i.push(e));return}n.sort((e,t)=>e.edge.selfLoop.order-t.edge.selfLoop.order);let[r,o,s]=n,c=r.edge.originalEdge??o.edge.originalEdge??s.edge.originalEdge??o.edge,l=e.node(c.start);if(!l){n.forEach(e=>i.push(e));return}let u={width:o.edge.width,height:o.edge.height},d=zj(e,l,n,c.start,a),f=Bj(l,d,t,u.width??0),p=Vj(l,f,d,t,u),m={...o.edge,...c,id:c.id,points:f,start:c.start,end:c.end,x:p.x,y:p.y,width:u.width,height:u.height,labelStyle:o.edge.labelStyle,fromCluster:r.edge.fromCluster??o.edge.fromCluster??s.edge.fromCluster,toCluster:r.edge.toCluster??o.edge.toCluster??s.edge.toCluster};delete m.selfLoop,delete m.originalEdge,i.push({edge:m,start:m.start,end:m.end})}),i},`getEdgesToRender`),Uj=N(async({element:e,graph:t,diagramType:n,id:r,parentCluster:i,siteConfig:a})=>{let o=t.graph().rankdir;P.trace(`Dir in recursive render - dir:`,o);let{clusters:s,edgePaths:c,edgeLabels:l,nodes:u,rootGroups:d}=kO(e,{edgePathsClass:`edgePaths`});t.nodes()?P.info(`Recursive render XXX`,t.nodes()):P.info(`No nodes found for`,t),t.edges().length>0&&P.info(`Recursive edges`,t.edge(t.edges()[0]));let f=Lj(n);await Promise.all(t.nodes().map(async function(e){let s=t.node(e);if(i!==void 0){let n=JSON.parse(JSON.stringify(i.clusterData));P.trace(`Setting data for parent cluster XXX
|
|
271
271
|
Node.id = `,e,`
|
|
272
272
|
data=`,n.height,`
|
|
273
273
|
Parent cluster`,i.height),t.setNode(i.id,n),t.parent(e)||(P.trace(`Setting parent`,e,i.id),t.setParent(e,i.id,n))}if(P.info(`(Insert) Node XXX`+e+`: `+JSON.stringify(t.node(e))),s?.clusterNode){P.info(`Cluster identified XBX`,e,s.width,t.node(e));let{ranksep:i,nodesep:o}=t.graph();s.graph.setGraph({...s.graph.graph(),ranksep:i+25,nodesep:o});let c=await Xj({element:u,graph:s.graph,diagramType:n,id:r,parentCluster:t.node(e),siteConfig:a}),l=c.elem;Y(s,l),s.diff=c.diff||0,P.info(`New compound node after recursive render XAX`,e,`width`,s.width,`height`,s.height),jD(l,s)}else t.children(e).length>0?(P.trace(`Cluster - the non recursive path XBX`,e,s.id,s,s.width,`Graph:`,t),P.trace(VO(s.id,t)),$.set(s.id,{id:VO(s.id,t),node:s})):(P.trace(`Node - the non recursive path XAX`,e,u,t.node(e),o),await jO(u,t.node(e),{config:a,dir:o}))})),await N(async()=>{let e=t.edges().map(async function(e){let n=t.edge(e.v,e.w,e.name);if(P.info(`Edge `+e.v+` -> `+e.w+`: `+JSON.stringify(e)),P.info(`Edge `+e.v+` -> `+e.w+`: `,e,` `,JSON.stringify(t.edge(e))),P.info(`Fix`,$,`ids:`,e.v,e.w,`Translating: `,$.get(e.v),$.get(e.w)),f&&n.selfLoop){if(n.selfLoop.order!==1)return;let e={...n.originalEdge,...n,id:n.selfLoop.id,startLabelLeft:n.originalEdge?.startLabelLeft??n.startLabelLeft,startLabelRight:n.originalEdge?.startLabelRight??n.startLabelRight,endLabelLeft:n.originalEdge?.endLabelLeft??n.endLabelLeft,endLabelRight:n.originalEdge?.endLabelRight??n.endLabelRight};await XD(l,e),n.width=e.width,n.height=e.height,n.labelStyle=e.labelStyle;return}await XD(l,n)});await Promise.all(e)},`processEdges`)();let{subGraphTitleTotalMargin:p}=OD(a);return{elem:d,graph:t,groups:{clusters:s,edgePaths:c,edgeLabels:l,nodes:u,rootGroups:d},diagramType:n,id:r,mergeSelfLoops:f,subGraphTitleTotalMargin:p}},`measureDagreGraph`),Wj=N(e=>{P.info(`############################################# XXX`),P.info(`### Layout ### XXX`),P.info(`############################################# XXX`),cj(e)},`runDagreGraphLayout`),Gj=N((e,t,n)=>{let r=e.node(t);if(!r)return;let i={...r};return r?.clusterNode?i.y=(r.y??0)+n:e.children(t).length>0?i.height=(r.height??0)+n:i.y=(r.y??0)+n/2,i},`normalizeDagreNode`),Kj=N((e,t)=>{Rj.forEach(n=>{t[n]!==void 0&&(e[n]=t[n])})},`applyDagreNodeLayout`),qj=N((e,t,n,r)=>({...e,start:e.start??t,end:e.end??n,points:(e.points??[]).map(e=>({...e,y:typeof e.y==`number`?e.y+r:e.y}))}),`normalizeDagreEdge`),Jj=N((e,t)=>{let{graph:n,mergeSelfLoops:r,subGraphTitleTotalMargin:i=0}=t,a=new Map(e.nodes.map(e=>[e.id,e]));KO(n).forEach(e=>{let t=Gj(n,e,i);if(!t)return;Kj(n.node(e),t);let r=a.get(e);r&&Kj(r,t)});let o=i/2;return e.edges=Hj(n,o,{mergeSelfLoops:r}).map(({edge:e,start:t,end:n})=>qj(e,t,n,o)),e},`applyDagreLayoutResult`),Yj=N(async({elem:e,graph:t,groups:{clusters:n,edgePaths:r},diagramType:i,id:a,mergeSelfLoops:o,subGraphTitleTotalMargin:s})=>{let c=0;await Promise.all(KO(t).map(async function(e){let r=t.node(e);if(P.info(`Position XBX => `+e+`: (`+r.x,`,`+r.y,`) width: `,r.width,` height: `,r.height),r?.clusterNode)r.y+=s,P.info(`A tainted cluster node XBX1`,e,r.id,r.width,r.height,r.x,r.y,t.parent(e)),$.get(r.id).node=r,ND(r);else if(t.children(e).length>0){P.info(`A pure cluster node XBX1`,e,r.id,r.x,r.y,r.width,r.height,t.parent(e)),r.height+=s,t.node(r.parentId);let i=r?.padding/2||0,a=r?.labelBBox?.height||0,o=a-i||0;P.debug(`OffsetY`,o,`labelHeight`,a,`halfPadding`,i),await DO(n,r),$.get(r.id).node=r}else{let e=t.node(r.parentId);r.y+=s/2,P.info(`A regular node XBX1 - using the padding`,r.id,`parent`,r.parentId,r.width,r.height,r.x,r.y,`offsetY`,r.offsetY,`parent`,e,e?.offsetY,r),ND(r)}}));let l=s/2;return Hj(t,l,{mergeSelfLoops:o}).forEach(function({edge:e,start:n,end:o}){P.info(`Edge `+n+` -> `+o+`: `+JSON.stringify(e),e),e.points.forEach(e=>e.y+=l),QD(e,sO(r,e,$,i,t.node(n),t.node(o),a))}),t.nodes().forEach(function(e){let n=t.node(e);P.info(e,n.type,n.diff),n.isGroup&&(c=n.diff)}),P.warn(`Returning from recursive render XAX`,e,c),{elem:e,diff:c}},`paintDagreLayoutCore`),Xj=N(async e=>{let t=await Uj(e);return Wj(t.graph),await Yj(t)},`renderDagreSubgraph`),Zj=N(e=>{let t=new _O({multigraph:!0,compound:!0}).setGraph({rankdir:e.direction,nodesep:e.config?.nodeSpacing||e.nodeSpacing||e.config?.flowchart?.nodeSpacing,ranksep:e.config?.rankSpacing||e.rankSpacing||e.config?.flowchart?.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});return e.nodes.forEach(e=>{t.setNode(e.id,{...e}),e.parentId&&t.setParent(e.id,e.parentId)}),P.debug(`Edges:`,e.edges),e.edges.forEach(e=>{if(e.start===e.end){let n=e.start,r=n+`---`+n+`---1`,i=n+`---`+n+`---2`,a=t.node(n);t.setNode(r,{domId:r,id:r,parentId:a.parentId,labelStyle:``,label:``,padding:0,shape:`labelRect`,style:``,width:10,height:10}),t.setParent(r,a.parentId),t.setNode(i,{domId:i,id:i,parentId:a.parentId,labelStyle:``,padding:0,shape:`labelRect`,label:``,style:``,width:10,height:10}),t.setParent(i,a.parentId);let o=structuredClone(e),s=structuredClone(e),c=structuredClone(e),l=structuredClone(e);s.originalEdge=o,s.selfLoop={id:o.id,order:0},c.originalEdge=o,c.selfLoop={id:o.id,order:1},l.originalEdge=o,l.selfLoop={id:o.id,order:2},s.label=``,s.arrowTypeEnd=`none`,s.endLabelLeft=``,s.endLabelRight=``,s.startLabelLeft=``,s.id=n+`-cyclic-special-1`,c.startLabelRight=``,c.startLabelLeft=``,c.endLabelLeft=``,c.endLabelRight=``,c.arrowTypeStart=`none`,c.arrowTypeEnd=`none`,c.id=n+`-cyclic-special-mid`,l.label=``,l.startLabelRight=``,l.startLabelLeft=``,l.arrowTypeStart=`none`,a.isGroup&&(s.fromCluster=n,l.toCluster=n),l.id=n+`-cyclic-special-2`,l.arrowTypeStart=`none`,t.setEdge(n,r,s,n+`-cyclic-special-0`),t.setEdge(r,i,c,n+`-cyclic-special-1`),t.setEdge(i,n,l,n+`-cyclic-special-2`)}else t.setEdge(e.start,e.end,{...e},e.id)}),UO(t),{graph:t}},`prepareLayoutForDagre`),Qj=N(async(e,{element:t,preparedLayout:n})=>{let r=n??Zj(e),i=H(),a=await Uj({element:t,graph:r.graph,diagramType:e.type,id:e.diagramId,parentCluster:void 0,siteConfig:i});return r.measuredLayout=a,a},`measureDagreLayout`),$j=N((e,t)=>{let n=t.preparedLayout?.measuredLayout;if(!n)throw Error(`runDagreLayoutCore requires measureDagreLayout to run first`);return Wj(n.graph),Jj(e,n),n},`runDagreLayoutCore`),eM=YO({prepareLayout:Zj,measureLayout:Qj,runLayoutCore:$j,paintOptions:{clusterDb:$,getNodes:N((e,{measure:t})=>KO(t.graph).map(e=>t.graph.node(e)).filter(Boolean),`getDagrePaintNodes`),getEdgeNode:N((e,t,{measure:n})=>e?n.graph.node(e):void 0,`getDagreEdgeNode`),skipNode:N((e,{measure:t})=>!t.graph.hasNode(e.id),`skipNode`),isCluster:N((e,{measure:t})=>t.graph.hasNode(e.id)&&(t.graph.children(e.id)??[]).length>0,`isCluster`)}}),tM=r(((e,t)=>{function n(){this.__data__=[],this.size=0}t.exports=n})),nM=r(((e,t)=>{function n(e,t){return e===t||e!==e&&t!==t}t.exports=n})),rM=r(((e,t)=>{var n=nM();function r(e,t){for(var r=e.length;r--;)if(n(e[r][0],t))return r;return-1}t.exports=r})),iM=r(((e,t)=>{var n=rM(),r=Array.prototype.splice;function i(e){var t=this.__data__,i=n(t,e);return i<0?!1:(i==t.length-1?t.pop():r.call(t,i,1),--this.size,!0)}t.exports=i})),aM=r(((e,t)=>{var n=rM();function r(e){var t=this.__data__,r=n(t,e);return r<0?void 0:t[r][1]}t.exports=r})),oM=r(((e,t)=>{var n=rM();function r(e){return n(this.__data__,e)>-1}t.exports=r})),sM=r(((e,t)=>{var n=rM();function r(e,t){var r=this.__data__,i=n(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}t.exports=r})),cM=r(((e,t)=>{var n=tM(),r=iM(),i=aM(),a=oM(),o=sM();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),lM=r(((e,t)=>{var n=cM();function r(){this.__data__=new n,this.size=0}t.exports=r})),uM=r(((e,t)=>{function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}t.exports=n})),dM=r(((e,t)=>{function n(e){return this.__data__.get(e)}t.exports=n})),fM=r(((e,t)=>{function n(e){return this.__data__.has(e)}t.exports=n})),pM=r(((e,t)=>{t.exports=typeof global==`object`&&global&&global.Object===Object&&global})),mM=r(((e,t)=>{var n=pM(),r=typeof self==`object`&&self&&self.Object===Object&&self;t.exports=n||r||Function(`return this`)()})),hM=r(((e,t)=>{t.exports=mM().Symbol})),gM=r(((e,t)=>{var n=hM(),r=Object.prototype,i=r.hasOwnProperty,a=r.toString,o=n?n.toStringTag:void 0;function s(e){var t=i.call(e,o),n=e[o];try{e[o]=void 0;var r=!0}catch{}var s=a.call(e);return r&&(t?e[o]=n:delete e[o]),s}t.exports=s})),_M=r(((e,t)=>{var n=Object.prototype.toString;function r(e){return n.call(e)}t.exports=r})),vM=r(((e,t)=>{var n=hM(),r=gM(),i=_M(),a=`[object Null]`,o=`[object Undefined]`,s=n?n.toStringTag:void 0;function c(e){return e==null?e===void 0?o:a:s&&s in Object(e)?r(e):i(e)}t.exports=c})),yM=r(((e,t)=>{function n(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}t.exports=n})),bM=r(((e,t)=>{var n=vM(),r=yM(),i=`[object AsyncFunction]`,a=`[object Function]`,o=`[object GeneratorFunction]`,s=`[object Proxy]`;function c(e){if(!r(e))return!1;var t=n(e);return t==a||t==o||t==i||t==s}t.exports=c})),xM=r(((e,t)=>{t.exports=mM()[`__core-js_shared__`]})),SM=r(((e,t)=>{var n=xM(),r=function(){var e=/[^.]+$/.exec(n&&n.keys&&n.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function i(e){return!!r&&r in e}t.exports=i})),CM=r(((e,t)=>{var n=Function.prototype.toString;function r(e){if(e!=null){try{return n.call(e)}catch{}try{return e+``}catch{}}return``}t.exports=r})),wM=r(((e,t)=>{var n=bM(),r=SM(),i=yM(),a=CM(),o=/[\\^$.*+?()[\]{}|]/g,s=/^\[object .+?Constructor\]$/,c=Function.prototype,l=Object.prototype,u=c.toString,d=l.hasOwnProperty,f=RegExp(`^`+u.call(d).replace(o,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function p(e){return!i(e)||r(e)?!1:(n(e)?f:s).test(a(e))}t.exports=p})),TM=r(((e,t)=>{function n(e,t){return e?.[t]}t.exports=n})),EM=r(((e,t)=>{var n=wM(),r=TM();function i(e,t){var i=r(e,t);return n(i)?i:void 0}t.exports=i})),DM=r(((e,t)=>{t.exports=EM()(mM(),`Map`)})),OM=r(((e,t)=>{t.exports=EM()(Object,`create`)})),kM=r(((e,t)=>{var n=OM();function r(){this.__data__=n?n(null):{},this.size=0}t.exports=r})),AM=r(((e,t)=>{function n(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}t.exports=n})),jM=r(((e,t)=>{var n=OM(),r=`__lodash_hash_undefined__`,i=Object.prototype.hasOwnProperty;function a(e){var t=this.__data__;if(n){var a=t[e];return a===r?void 0:a}return i.call(t,e)?t[e]:void 0}t.exports=a})),MM=r(((e,t)=>{var n=OM(),r=Object.prototype.hasOwnProperty;function i(e){var t=this.__data__;return n?t[e]!==void 0:r.call(t,e)}t.exports=i})),NM=r(((e,t)=>{var n=OM(),r=`__lodash_hash_undefined__`;function i(e,t){var i=this.__data__;return this.size+=+!this.has(e),i[e]=n&&t===void 0?r:t,this}t.exports=i})),PM=r(((e,t)=>{var n=kM(),r=AM(),i=jM(),a=MM(),o=NM();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),FM=r(((e,t)=>{var n=PM(),r=cM(),i=DM();function a(){this.size=0,this.__data__={hash:new n,map:new(i||r),string:new n}}t.exports=a})),IM=r(((e,t)=>{function n(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}t.exports=n})),LM=r(((e,t)=>{var n=IM();function r(e,t){var r=e.__data__;return n(t)?r[typeof t==`string`?`string`:`hash`]:r.map}t.exports=r})),RM=r(((e,t)=>{var n=LM();function r(e){var t=n(this,e).delete(e);return this.size-=+!!t,t}t.exports=r})),zM=r(((e,t)=>{var n=LM();function r(e){return n(this,e).get(e)}t.exports=r})),BM=r(((e,t)=>{var n=LM();function r(e){return n(this,e).has(e)}t.exports=r})),VM=r(((e,t)=>{var n=LM();function r(e,t){var r=n(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}t.exports=r})),HM=r(((e,t)=>{var n=FM(),r=RM(),i=zM(),a=BM(),o=VM();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),UM=r(((e,t)=>{var n=cM(),r=DM(),i=HM(),a=200;function o(e,t){var o=this.__data__;if(o instanceof n){var s=o.__data__;if(!r||s.length<a-1)return s.push([e,t]),this.size=++o.size,this;o=this.__data__=new i(s)}return o.set(e,t),this.size=o.size,this}t.exports=o})),WM=r(((e,t)=>{var n=cM(),r=lM(),i=uM(),a=dM(),o=fM(),s=UM();function c(e){var t=this.__data__=new n(e);this.size=t.size}c.prototype.clear=r,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=o,c.prototype.set=s,t.exports=c})),GM=r(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}t.exports=n})),KM=r(((e,t)=>{var n=EM();t.exports=function(){try{var e=n(Object,`defineProperty`);return e({},``,{}),e}catch{}}()})),qM=r(((e,t)=>{var n=KM();function r(e,t,r){t==`__proto__`&&n?n(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}t.exports=r})),JM=r(((e,t)=>{var n=qM(),r=nM(),i=Object.prototype.hasOwnProperty;function a(e,t,a){var o=e[t];(!(i.call(e,t)&&r(o,a))||a===void 0&&!(t in e))&&n(e,t,a)}t.exports=a})),YM=r(((e,t)=>{var n=JM(),r=qM();function i(e,t,i,a){var o=!i;i||={};for(var s=-1,c=t.length;++s<c;){var l=t[s],u=a?a(i[l],e[l],l,i,e):void 0;u===void 0&&(u=e[l]),o?r(i,l,u):n(i,l,u)}return i}t.exports=i})),XM=r(((e,t)=>{function n(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}t.exports=n})),ZM=r(((e,t)=>{function n(e){return typeof e==`object`&&!!e}t.exports=n})),QM=r(((e,t)=>{var n=vM(),r=ZM(),i=`[object Arguments]`;function a(e){return r(e)&&n(e)==i}t.exports=a})),$M=r(((e,t)=>{var n=QM(),r=ZM(),i=Object.prototype,a=i.hasOwnProperty,o=i.propertyIsEnumerable;t.exports=n(function(){return arguments}())?n:function(e){return r(e)&&a.call(e,`callee`)&&!o.call(e,`callee`)}})),eN=r(((e,t)=>{t.exports=Array.isArray})),tN=r(((e,t)=>{function n(){return!1}t.exports=n})),nN=r(((e,t)=>{var n=mM(),r=tN(),i=typeof e==`object`&&e&&!e.nodeType&&e,a=i&&typeof t==`object`&&t&&!t.nodeType&&t,o=a&&a.exports===i?n.Buffer:void 0;t.exports=(o?o.isBuffer:void 0)||r})),rN=r(((e,t)=>{var n=/^(?:0|[1-9]\d*)$/;function r(e,t){var r=typeof e;return t??=9007199254740991,!!t&&(r==`number`||r!=`symbol`&&n.test(e))&&e>-1&&e%1==0&&e<t}t.exports=r})),iN=r(((e,t)=>{function n(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=9007199254740991}t.exports=n})),aN=r(((e,t)=>{var n=vM(),r=iN(),i=ZM(),a=`[object Arguments]`,o=`[object Array]`,s=`[object Boolean]`,c=`[object Date]`,l=`[object Error]`,u=`[object Function]`,d=`[object Map]`,f=`[object Number]`,p=`[object Object]`,m=`[object RegExp]`,h=`[object Set]`,g=`[object String]`,_=`[object WeakMap]`,v=`[object ArrayBuffer]`,y=`[object DataView]`,b=`[object Float32Array]`,x=`[object Float64Array]`,S=`[object Int8Array]`,C=`[object Int16Array]`,w=`[object Int32Array]`,T=`[object Uint8Array]`,E=`[object Uint8ClampedArray]`,D=`[object Uint16Array]`,O=`[object Uint32Array]`,k={};k[b]=k[x]=k[S]=k[C]=k[w]=k[T]=k[E]=k[D]=k[O]=!0,k[a]=k[o]=k[v]=k[s]=k[y]=k[c]=k[l]=k[u]=k[d]=k[f]=k[p]=k[m]=k[h]=k[g]=k[_]=!1;function ee(e){return i(e)&&r(e.length)&&!!k[n(e)]}t.exports=ee})),oN=r(((e,t)=>{function n(e){return function(t){return e(t)}}t.exports=n})),sN=r(((e,t)=>{var n=pM(),r=typeof e==`object`&&e&&!e.nodeType&&e,i=r&&typeof t==`object`&&t&&!t.nodeType&&t,a=i&&i.exports===r&&n.process;t.exports=function(){try{return i&&i.require&&i.require(`util`).types||a&&a.binding&&a.binding(`util`)}catch{}}()})),cN=r(((e,t)=>{var n=aN(),r=oN(),i=sN(),a=i&&i.isTypedArray;t.exports=a?r(a):n})),lN=r(((e,t)=>{var n=XM(),r=$M(),i=eN(),a=nN(),o=rN(),s=cN(),c=Object.prototype.hasOwnProperty;function l(e,t){var l=i(e),u=!l&&r(e),d=!l&&!u&&a(e),f=!l&&!u&&!d&&s(e),p=l||u||d||f,m=p?n(e.length,String):[],h=m.length;for(var g in e)(t||c.call(e,g))&&!(p&&(g==`length`||d&&(g==`offset`||g==`parent`)||f&&(g==`buffer`||g==`byteLength`||g==`byteOffset`)||o(g,h)))&&m.push(g);return m}t.exports=l})),uN=r(((e,t)=>{var n=Object.prototype;function r(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||n)}t.exports=r})),dN=r(((e,t)=>{function n(e,t){return function(n){return e(t(n))}}t.exports=n})),fN=r(((e,t)=>{t.exports=dN()(Object.keys,Object)})),pN=r(((e,t)=>{var n=uN(),r=fN(),i=Object.prototype.hasOwnProperty;function a(e){if(!n(e))return r(e);var t=[];for(var a in Object(e))i.call(e,a)&&a!=`constructor`&&t.push(a);return t}t.exports=a})),mN=r(((e,t)=>{var n=bM(),r=iN();function i(e){return e!=null&&r(e.length)&&!n(e)}t.exports=i})),hN=r(((e,t)=>{var n=lN(),r=pN(),i=mN();function a(e){return i(e)?n(e):r(e)}t.exports=a})),gN=r(((e,t)=>{var n=YM(),r=hN();function i(e,t){return e&&n(t,r(t),e)}t.exports=i})),_N=r(((e,t)=>{function n(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}t.exports=n})),vN=r(((e,t)=>{var n=yM(),r=uN(),i=_N(),a=Object.prototype.hasOwnProperty;function o(e){if(!n(e))return i(e);var t=r(e),o=[];for(var s in e)(s!=`constructor`||!t&&a.call(e,s))&&o.push(s);return o}t.exports=o})),yN=r(((e,t)=>{var n=lN(),r=vN(),i=mN();function a(e){return i(e)?n(e,!0):r(e)}t.exports=a})),bN=r(((e,t)=>{var n=YM(),r=yN();function i(e,t){return e&&n(t,r(t),e)}t.exports=i})),xN=r(((e,t)=>{var n=mM(),r=typeof e==`object`&&e&&!e.nodeType&&e,i=r&&typeof t==`object`&&t&&!t.nodeType&&t,a=i&&i.exports===r?n.Buffer:void 0,o=a?a.allocUnsafe:void 0;function s(e,t){if(t)return e.slice();var n=e.length,r=o?o(n):new e.constructor(n);return e.copy(r),r}t.exports=s})),SN=r(((e,t)=>{function n(e,t){var n=-1,r=e.length;for(t||=Array(r);++n<r;)t[n]=e[n];return t}t.exports=n})),CN=r(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}t.exports=n})),wN=r(((e,t)=>{function n(){return[]}t.exports=n})),TN=r(((e,t)=>{var n=CN(),r=wN(),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols;t.exports=a?function(e){return e==null?[]:(e=Object(e),n(a(e),function(t){return i.call(e,t)}))}:r})),EN=r(((e,t)=>{var n=YM(),r=TN();function i(e,t){return n(e,r(e),t)}t.exports=i})),DN=r(((e,t)=>{function n(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}t.exports=n})),ON=r(((e,t)=>{t.exports=dN()(Object.getPrototypeOf,Object)})),kN=r(((e,t)=>{var n=DN(),r=ON(),i=TN(),a=wN();t.exports=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)n(t,i(e)),e=r(e);return t}:a})),AN=r(((e,t)=>{var n=YM(),r=kN();function i(e,t){return n(e,r(e),t)}t.exports=i})),jN=r(((e,t)=>{var n=DN(),r=eN();function i(e,t,i){var a=t(e);return r(e)?a:n(a,i(e))}t.exports=i})),MN=r(((e,t)=>{var n=jN(),r=TN(),i=hN();function a(e){return n(e,i,r)}t.exports=a})),NN=r(((e,t)=>{var n=jN(),r=kN(),i=yN();function a(e){return n(e,i,r)}t.exports=a})),PN=r(((e,t)=>{t.exports=EM()(mM(),`DataView`)})),FN=r(((e,t)=>{t.exports=EM()(mM(),`Promise`)})),IN=r(((e,t)=>{t.exports=EM()(mM(),`Set`)})),LN=r(((e,t)=>{t.exports=EM()(mM(),`WeakMap`)})),RN=r(((e,t)=>{var n=PN(),r=DM(),i=FN(),a=IN(),o=LN(),s=vM(),c=CM(),l=`[object Map]`,u=`[object Object]`,d=`[object Promise]`,f=`[object Set]`,p=`[object WeakMap]`,m=`[object DataView]`,h=c(n),g=c(r),_=c(i),v=c(a),y=c(o),b=s;(n&&b(new n(new ArrayBuffer(1)))!=m||r&&b(new r)!=l||i&&b(i.resolve())!=d||a&&b(new a)!=f||o&&b(new o)!=p)&&(b=function(e){var t=s(e),n=t==u?e.constructor:void 0,r=n?c(n):``;if(r)switch(r){case h:return m;case g:return l;case _:return d;case v:return f;case y:return p}return t}),t.exports=b})),zN=r(((e,t)=>{var n=Object.prototype.hasOwnProperty;function r(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]==`string`&&n.call(e,`index`)&&(r.index=e.index,r.input=e.input),r}t.exports=r})),BN=r(((e,t)=>{t.exports=mM().Uint8Array})),VN=r(((e,t)=>{var n=BN();function r(e){var t=new e.constructor(e.byteLength);return new n(t).set(new n(e)),t}t.exports=r})),HN=r(((e,t)=>{var n=VN();function r(e,t){var r=t?n(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}t.exports=r})),UN=r(((e,t)=>{var n=/\w*$/;function r(e){var t=new e.constructor(e.source,n.exec(e));return t.lastIndex=e.lastIndex,t}t.exports=r})),WN=r(((e,t)=>{var n=hM(),r=n?n.prototype:void 0,i=r?r.valueOf:void 0;function a(e){return i?Object(i.call(e)):{}}t.exports=a})),GN=r(((e,t)=>{var n=VN();function r(e,t){var r=t?n(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}t.exports=r})),KN=r(((e,t)=>{var n=VN(),r=HN(),i=UN(),a=WN(),o=GN(),s=`[object Boolean]`,c=`[object Date]`,l=`[object Map]`,u=`[object Number]`,d=`[object RegExp]`,f=`[object Set]`,p=`[object String]`,m=`[object Symbol]`,h=`[object ArrayBuffer]`,g=`[object DataView]`,_=`[object Float32Array]`,v=`[object Float64Array]`,y=`[object Int8Array]`,b=`[object Int16Array]`,x=`[object Int32Array]`,S=`[object Uint8Array]`,C=`[object Uint8ClampedArray]`,w=`[object Uint16Array]`,T=`[object Uint32Array]`;function E(e,t,E){var D=e.constructor;switch(t){case h:return n(e);case s:case c:return new D(+e);case g:return r(e,E);case _:case v:case y:case b:case x:case S:case C:case w:case T:return o(e,E);case l:return new D;case u:case p:return new D(e);case d:return i(e);case f:return new D;case m:return a(e)}}t.exports=E})),qN=r(((e,t)=>{var n=yM(),r=Object.create;t.exports=function(){function e(){}return function(t){if(!n(t))return{};if(r)return r(t);e.prototype=t;var i=new e;return e.prototype=void 0,i}}()})),JN=r(((e,t)=>{var n=qN(),r=ON(),i=uN();function a(e){return typeof e.constructor==`function`&&!i(e)?n(r(e)):{}}t.exports=a})),YN=r(((e,t)=>{var n=RN(),r=ZM(),i=`[object Map]`;function a(e){return r(e)&&n(e)==i}t.exports=a})),XN=r(((e,t)=>{var n=YN(),r=oN(),i=sN(),a=i&&i.isMap;t.exports=a?r(a):n})),ZN=r(((e,t)=>{var n=RN(),r=ZM(),i=`[object Set]`;function a(e){return r(e)&&n(e)==i}t.exports=a})),QN=r(((e,t)=>{var n=ZN(),r=oN(),i=sN(),a=i&&i.isSet;t.exports=a?r(a):n})),$N=r(((e,t)=>{var n=WM(),r=GM(),i=JM(),a=gN(),o=bN(),s=xN(),c=SN(),l=EN(),u=AN(),d=MN(),f=NN(),p=RN(),m=zN(),h=KN(),g=JN(),_=eN(),v=nN(),y=XN(),b=yM(),x=QN(),S=hN(),C=yN(),w=1,T=2,E=4,D=`[object Arguments]`,O=`[object Array]`,k=`[object Boolean]`,ee=`[object Date]`,te=`[object Error]`,ne=`[object Function]`,re=`[object GeneratorFunction]`,ie=`[object Map]`,ae=`[object Number]`,oe=`[object Object]`,se=`[object RegExp]`,ce=`[object Set]`,le=`[object String]`,A=`[object Symbol]`,ue=`[object WeakMap]`,de=`[object ArrayBuffer]`,fe=`[object DataView]`,pe=`[object Float32Array]`,me=`[object Float64Array]`,he=`[object Int8Array]`,ge=`[object Int16Array]`,_e=`[object Int32Array]`,ve=`[object Uint8Array]`,ye=`[object Uint8ClampedArray]`,be=`[object Uint16Array]`,xe=`[object Uint32Array]`,j={};j[D]=j[O]=j[de]=j[fe]=j[k]=j[ee]=j[pe]=j[me]=j[he]=j[ge]=j[_e]=j[ie]=j[ae]=j[oe]=j[se]=j[ce]=j[le]=j[A]=j[ve]=j[ye]=j[be]=j[xe]=!0,j[te]=j[ne]=j[ue]=!1;function Se(e,t,O,k,ee,te){var ie,ae=t&w,se=t&T,ce=t&E;if(O&&(ie=ee?O(e,k,ee,te):O(e)),ie!==void 0)return ie;if(!b(e))return e;var le=_(e);if(le){if(ie=m(e),!ae)return c(e,ie)}else{var A=p(e),ue=A==ne||A==re;if(v(e))return s(e,ae);if(A==oe||A==D||ue&&!ee){if(ie=se||ue?{}:g(e),!ae)return se?u(e,o(ie,e)):l(e,a(ie,e))}else{if(!j[A])return ee?e:{};ie=h(e,A,ae)}}te||=new n;var de=te.get(e);if(de)return de;te.set(e,ie),x(e)?e.forEach(function(n){ie.add(Se(n,t,O,n,e,te))}):y(e)&&e.forEach(function(n,r){ie.set(r,Se(n,t,O,r,e,te))});var fe=le?void 0:(ce?se?f:d:se?C:S)(e);return r(fe||e,function(n,r){fe&&(r=n,n=e[r]),i(ie,r,Se(n,t,O,r,e,te))}),ie}t.exports=Se})),eP=r(((e,t)=>{var n=$N(),r=4;function i(e){return n(e,r)}t.exports=i})),tP=r(((e,t)=>{function n(e){return function(){return e}}t.exports=n})),nP=r(((e,t)=>{function n(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}t.exports=n})),rP=r(((e,t)=>{t.exports=nP()()})),iP=r(((e,t)=>{var n=rP(),r=hN();function i(e,t){return e&&n(e,t,r)}t.exports=i})),aP=r(((e,t)=>{var n=mN();function r(e,t){return function(r,i){if(r==null)return r;if(!n(r))return e(r,i);for(var a=r.length,o=t?a:-1,s=Object(r);(t?o--:++o<a)&&i(s[o],o,s)!==!1;);return r}}t.exports=r})),oP=r(((e,t)=>{var n=iP();t.exports=aP()(n)})),sP=r(((e,t)=>{function n(e){return e}t.exports=n})),cP=r(((e,t)=>{var n=sP();function r(e){return typeof e==`function`?e:n}t.exports=r})),lP=r(((e,t)=>{var n=GM(),r=oP(),i=cP(),a=eN();function o(e,t){return(a(e)?n:r)(e,i(t))}t.exports=o})),uP=r(((e,t)=>{t.exports=lP()})),dP=r(((e,t)=>{var n=oP();function r(e,t){var r=[];return n(e,function(e,n,i){t(e,n,i)&&r.push(e)}),r}t.exports=r})),fP=r(((e,t)=>{function n(e){return this.__data__.set(e,`__lodash_hash_undefined__`),this}t.exports=n})),pP=r(((e,t)=>{function n(e){return this.__data__.has(e)}t.exports=n})),mP=r(((e,t)=>{var n=HM(),r=fP(),i=pP();function a(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new n;++t<r;)this.add(e[t])}a.prototype.add=a.prototype.push=r,a.prototype.has=i,t.exports=a})),hP=r(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}t.exports=n})),gP=r(((e,t)=>{function n(e,t){return e.has(t)}t.exports=n})),_P=r(((e,t)=>{var n=mP(),r=hP(),i=gP(),a=1,o=2;function s(e,t,s,c,l,u){var d=s&a,f=e.length,p=t.length;if(f!=p&&!(d&&p>f))return!1;var m=u.get(e),h=u.get(t);if(m&&h)return m==t&&h==e;var g=-1,_=!0,v=s&o?new n:void 0;for(u.set(e,t),u.set(t,e);++g<f;){var y=e[g],b=t[g];if(c)var x=d?c(b,y,g,t,e,u):c(y,b,g,e,t,u);if(x!==void 0){if(x)continue;_=!1;break}if(v){if(!r(t,function(e,t){if(!i(v,t)&&(y===e||l(y,e,s,c,u)))return v.push(t)})){_=!1;break}}else if(!(y===b||l(y,b,s,c,u))){_=!1;break}}return u.delete(e),u.delete(t),_}t.exports=s})),vP=r(((e,t)=>{function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}t.exports=n})),yP=r(((e,t)=>{function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}t.exports=n})),bP=r(((e,t)=>{var n=hM(),r=BN(),i=nM(),a=_P(),o=vP(),s=yP(),c=1,l=2,u=`[object Boolean]`,d=`[object Date]`,f=`[object Error]`,p=`[object Map]`,m=`[object Number]`,h=`[object RegExp]`,g=`[object Set]`,_=`[object String]`,v=`[object Symbol]`,y=`[object ArrayBuffer]`,b=`[object DataView]`,x=n?n.prototype:void 0,S=x?x.valueOf:void 0;function C(e,t,n,x,C,w,T){switch(n){case b:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case y:return!(e.byteLength!=t.byteLength||!w(new r(e),new r(t)));case u:case d:case m:return i(+e,+t);case f:return e.name==t.name&&e.message==t.message;case h:case _:return e==t+``;case p:var E=o;case g:var D=x&c;if(E||=s,e.size!=t.size&&!D)return!1;var O=T.get(e);if(O)return O==t;x|=l,T.set(e,t);var k=a(E(e),E(t),x,C,w,T);return T.delete(e),k;case v:if(S)return S.call(e)==S.call(t)}return!1}t.exports=C})),xP=r(((e,t)=>{var n=MN(),r=1,i=Object.prototype.hasOwnProperty;function a(e,t,a,o,s,c){var l=a&r,u=n(e),d=u.length;if(d!=n(t).length&&!l)return!1;for(var f=d;f--;){var p=u[f];if(!(l?p in t:i.call(t,p)))return!1}var m=c.get(e),h=c.get(t);if(m&&h)return m==t&&h==e;var g=!0;c.set(e,t),c.set(t,e);for(var _=l;++f<d;){p=u[f];var v=e[p],y=t[p];if(o)var b=l?o(y,v,p,t,e,c):o(v,y,p,e,t,c);if(!(b===void 0?v===y||s(v,y,a,o,c):b)){g=!1;break}_||=p==`constructor`}if(g&&!_){var x=e.constructor,S=t.constructor;x!=S&&`constructor`in e&&`constructor`in t&&!(typeof x==`function`&&x instanceof x&&typeof S==`function`&&S instanceof S)&&(g=!1)}return c.delete(e),c.delete(t),g}t.exports=a})),SP=r(((e,t)=>{var n=WM(),r=_P(),i=bP(),a=xP(),o=RN(),s=eN(),c=nN(),l=cN(),u=1,d=`[object Arguments]`,f=`[object Array]`,p=`[object Object]`,m=Object.prototype.hasOwnProperty;function h(e,t,h,g,_,v){var y=s(e),b=s(t),x=y?f:o(e),S=b?f:o(t);x=x==d?p:x,S=S==d?p:S;var C=x==p,w=S==p,T=x==S;if(T&&c(e)){if(!c(t))return!1;y=!0,C=!1}if(T&&!C)return v||=new n,y||l(e)?r(e,t,h,g,_,v):i(e,t,x,h,g,_,v);if(!(h&u)){var E=C&&m.call(e,`__wrapped__`),D=w&&m.call(t,`__wrapped__`);if(E||D){var O=E?e.value():e,k=D?t.value():t;return v||=new n,_(O,k,h,g,v)}}return T?(v||=new n,a(e,t,h,g,_,v)):!1}t.exports=h})),CP=r(((e,t)=>{var n=SP(),r=ZM();function i(e,t,a,o,s){return e===t?!0:e==null||t==null||!r(e)&&!r(t)?e!==e&&t!==t:n(e,t,a,o,i,s)}t.exports=i})),wP=r(((e,t)=>{var n=WM(),r=CP(),i=1,a=2;function o(e,t,o,s){var c=o.length,l=c,u=!s;if(e==null)return!l;for(e=Object(e);c--;){var d=o[c];if(u&&d[2]?d[1]!==e[d[0]]:!(d[0]in e))return!1}for(;++c<l;){d=o[c];var f=d[0],p=e[f],m=d[1];if(u&&d[2]){if(p===void 0&&!(f in e))return!1}else{var h=new n;if(s)var g=s(p,m,f,e,t,h);if(!(g===void 0?r(m,p,i|a,s,h):g))return!1}}return!0}t.exports=o})),TP=r(((e,t)=>{var n=yM();function r(e){return e===e&&!n(e)}t.exports=r})),EP=r(((e,t)=>{var n=TP(),r=hN();function i(e){for(var t=r(e),i=t.length;i--;){var a=t[i],o=e[a];t[i]=[a,o,n(o)]}return t}t.exports=i})),DP=r(((e,t)=>{function n(e,t){return function(n){return n!=null&&n[e]===t&&(t!==void 0||e in Object(n))}}t.exports=n})),OP=r(((e,t)=>{var n=wP(),r=EP(),i=DP();function a(e){var t=r(e);return t.length==1&&t[0][2]?i(t[0][0],t[0][1]):function(r){return r===e||n(r,e,t)}}t.exports=a})),kP=r(((e,t)=>{var n=vM(),r=ZM(),i=`[object Symbol]`;function a(e){return typeof e==`symbol`||r(e)&&n(e)==i}t.exports=a})),AP=r(((e,t)=>{var n=eN(),r=kP(),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;function o(e,t){if(n(e))return!1;var o=typeof e;return o==`number`||o==`symbol`||o==`boolean`||e==null||r(e)?!0:a.test(e)||!i.test(e)||t!=null&&e in Object(t)}t.exports=o})),jP=r(((e,t)=>{var n=HM(),r=`Expected a function`;function i(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(r);var a=function(){var n=arguments,r=t?t.apply(this,n):n[0],i=a.cache;if(i.has(r))return i.get(r);var o=e.apply(this,n);return a.cache=i.set(r,o)||i,o};return a.cache=new(i.Cache||n),a}i.Cache=n,t.exports=i})),MP=r(((e,t)=>{var n=jP(),r=500;function i(e){var t=n(e,function(e){return i.size===r&&i.clear(),e}),i=t.cache;return t}t.exports=i})),NP=r(((e,t)=>{var n=MP(),r=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g;t.exports=n(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(r,function(e,n,r,a){t.push(r?a.replace(i,`$1`):n||e)}),t})})),PP=r(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}t.exports=n})),FP=r(((e,t)=>{var n=hM(),r=PP(),i=eN(),a=kP(),o=1/0,s=n?n.prototype:void 0,c=s?s.toString:void 0;function l(e){if(typeof e==`string`)return e;if(i(e))return r(e,l)+``;if(a(e))return c?c.call(e):``;var t=e+``;return t==`0`&&1/e==-o?`-0`:t}t.exports=l})),IP=r(((e,t)=>{var n=FP();function r(e){return e==null?``:n(e)}t.exports=r})),LP=r(((e,t)=>{var n=eN(),r=AP(),i=NP(),a=IP();function o(e,t){return n(e)?e:r(e,t)?[e]:i(a(e))}t.exports=o})),RP=r(((e,t)=>{var n=kP(),r=1/0;function i(e){if(typeof e==`string`||n(e))return e;var t=e+``;return t==`0`&&1/e==-r?`-0`:t}t.exports=i})),zP=r(((e,t)=>{var n=LP(),r=RP();function i(e,t){t=n(t,e);for(var i=0,a=t.length;e!=null&&i<a;)e=e[r(t[i++])];return i&&i==a?e:void 0}t.exports=i})),BP=r(((e,t)=>{var n=zP();function r(e,t,r){var i=e==null?void 0:n(e,t);return i===void 0?r:i}t.exports=r})),VP=r(((e,t)=>{function n(e,t){return e!=null&&t in Object(e)}t.exports=n})),HP=r(((e,t)=>{var n=LP(),r=$M(),i=eN(),a=rN(),o=iN(),s=RP();function c(e,t,c){t=n(t,e);for(var l=-1,u=t.length,d=!1;++l<u;){var f=s(t[l]);if(!(d=e!=null&&c(e,f)))break;e=e[f]}return d||++l!=u?d:(u=e==null?0:e.length,!!u&&o(u)&&a(f,u)&&(i(e)||r(e)))}t.exports=c})),UP=r(((e,t)=>{var n=VP(),r=HP();function i(e,t){return e!=null&&r(e,t,n)}t.exports=i})),WP=r(((e,t)=>{var n=CP(),r=BP(),i=UP(),a=AP(),o=TP(),s=DP(),c=RP(),l=1,u=2;function d(e,t){return a(e)&&o(t)?s(c(e),t):function(a){var o=r(a,e);return o===void 0&&o===t?i(a,e):n(t,o,l|u)}}t.exports=d})),GP=r(((e,t)=>{function n(e){return function(t){return t?.[e]}}t.exports=n})),KP=r(((e,t)=>{var n=zP();function r(e){return function(t){return n(t,e)}}t.exports=r})),qP=r(((e,t)=>{var n=GP(),r=KP(),i=AP(),a=RP();function o(e){return i(e)?n(a(e)):r(e)}t.exports=o})),JP=r(((e,t)=>{var n=OP(),r=WP(),i=sP(),a=eN(),o=qP();function s(e){return typeof e==`function`?e:e==null?i:typeof e==`object`?a(e)?r(e[0],e[1]):n(e):o(e)}t.exports=s})),YP=r(((e,t)=>{var n=CN(),r=dP(),i=JP(),a=eN();function o(e,t){return(a(e)?n:r)(e,i(t,3))}t.exports=o})),XP=r(((e,t)=>{var n=Object.prototype.hasOwnProperty;function r(e,t){return e!=null&&n.call(e,t)}t.exports=r})),ZP=r(((e,t)=>{var n=XP(),r=HP();function i(e,t){return e!=null&&r(e,t,n)}t.exports=i})),QP=r(((e,t)=>{var n=pN(),r=RN(),i=$M(),a=eN(),o=mN(),s=nN(),c=uN(),l=cN(),u=`[object Map]`,d=`[object Set]`,f=Object.prototype.hasOwnProperty;function p(e){if(e==null)return!0;if(o(e)&&(a(e)||typeof e==`string`||typeof e.splice==`function`||s(e)||l(e)||i(e)))return!e.length;var t=r(e);if(t==u||t==d)return!e.size;if(c(e))return!n(e).length;for(var p in e)if(f.call(e,p))return!1;return!0}t.exports=p})),$P=r(((e,t)=>{function n(e){return e===void 0}t.exports=n})),eF=r(((e,t)=>{var n=oP(),r=mN();function i(e,t){var i=-1,a=r(e)?Array(e.length):[];return n(e,function(e,n,r){a[++i]=t(e,n,r)}),a}t.exports=i})),tF=r(((e,t)=>{var n=PP(),r=JP(),i=eF(),a=eN();function o(e,t){return(a(e)?n:i)(e,r(t,3))}t.exports=o})),nF=r(((e,t)=>{function n(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}t.exports=n})),rF=r(((e,t)=>{function n(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}t.exports=n})),iF=r(((e,t)=>{var n=nF(),r=oP(),i=JP(),a=rF(),o=eN();function s(e,t,s){var c=o(e)?n:a,l=arguments.length<3;return c(e,i(t,4),s,l,r)}t.exports=s})),aF=r(((e,t)=>{var n=vM(),r=eN(),i=ZM(),a=`[object String]`;function o(e){return typeof e==`string`||!r(e)&&i(e)&&n(e)==a}t.exports=o})),oF=r(((e,t)=>{t.exports=GP()(`length`)})),sF=r(((e,t)=>{var n=RegExp(`[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]`);function r(e){return n.test(e)}t.exports=r})),cF=r(((e,t)=>{var n=`\\ud800-\\udfff`,r=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,i=`\\ufe0e\\ufe0f`,a=`[`+n+`]`,o=`[`+r+`]`,s=`\\ud83c[\\udffb-\\udfff]`,c=`(?:`+o+`|`+s+`)`,l=`[^`+n+`]`,u=`(?:\\ud83c[\\udde6-\\uddff]){2}`,d=`[\\ud800-\\udbff][\\udc00-\\udfff]`,f=`\\u200d`,p=c+`?`,m=`[`+i+`]?`,h=`(?:`+f+`(?:`+[l,u,d].join(`|`)+`)`+m+p+`)*`,g=m+p+h,_=`(?:`+[l+o+`?`,o,u,d,a].join(`|`)+`)`,v=RegExp(s+`(?=`+s+`)|`+_+g,`g`);function y(e){for(var t=v.lastIndex=0;v.test(e);)++t;return t}t.exports=y})),lF=r(((e,t)=>{var n=oF(),r=sF(),i=cF();function a(e){return r(e)?i(e):n(e)}t.exports=a})),uF=r(((e,t)=>{var n=pN(),r=RN(),i=mN(),a=aF(),o=lF(),s=`[object Map]`,c=`[object Set]`;function l(e){if(e==null)return 0;if(i(e))return a(e)?o(e):e.length;var t=r(e);return t==s||t==c?e.size:n(e).length}t.exports=l})),dF=r(((e,t)=>{var n=GM(),r=qN(),i=iP(),a=JP(),o=ON(),s=eN(),c=nN(),l=bM(),u=yM(),d=cN();function f(e,t,f){var p=s(e),m=p||c(e)||d(e);if(t=a(t,4),f==null){var h=e&&e.constructor;f=m?p?new h:[]:u(e)&&l(h)?r(o(e)):{}}return(m?n:i)(e,function(e,n,r){return t(f,e,n,r)}),f}t.exports=f})),fF=r(((e,t)=>{var n=hM(),r=$M(),i=eN(),a=n?n.isConcatSpreadable:void 0;function o(e){return i(e)||r(e)||!!(a&&e&&e[a])}t.exports=o})),pF=r(((e,t)=>{var n=DN(),r=fF();function i(e,t,a,o,s){var c=-1,l=e.length;for(a||=r,s||=[];++c<l;){var u=e[c];t>0&&a(u)?t>1?i(u,t-1,a,o,s):n(s,u):o||(s[s.length]=u)}return s}t.exports=i})),mF=r(((e,t)=>{function n(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}t.exports=n})),hF=r(((e,t)=>{var n=mF(),r=Math.max;function i(e,t,i){return t=r(t===void 0?e.length-1:t,0),function(){for(var a=arguments,o=-1,s=r(a.length-t,0),c=Array(s);++o<s;)c[o]=a[t+o];o=-1;for(var l=Array(t+1);++o<t;)l[o]=a[o];return l[t]=i(c),n(e,this,l)}}t.exports=i})),gF=r(((e,t)=>{var n=tP(),r=KM(),i=sP();t.exports=r?function(e,t){return r(e,`toString`,{configurable:!0,enumerable:!1,value:n(t),writable:!0})}:i})),_F=r(((e,t)=>{var n=Date.now;function r(e){var t=0,r=0;return function(){var i=n(),a=16-(i-r);if(r=i,a>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}t.exports=r})),vF=r(((e,t)=>{var n=gF();t.exports=_F()(n)})),yF=r(((e,t)=>{var n=sP(),r=hF(),i=vF();function a(e,t){return i(r(e,t,n),e+``)}t.exports=a})),bF=r(((e,t)=>{function n(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}t.exports=n})),xF=r(((e,t)=>{function n(e){return e!==e}t.exports=n})),SF=r(((e,t)=>{function n(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}t.exports=n})),CF=r(((e,t)=>{var n=bF(),r=xF(),i=SF();function a(e,t,a){return t===t?i(e,t,a):n(e,r,a)}t.exports=a})),wF=r(((e,t)=>{var n=CF();function r(e,t){return!!(e!=null&&e.length)&&n(e,t,0)>-1}t.exports=r})),TF=r(((e,t)=>{function n(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}t.exports=n})),EF=r(((e,t)=>{function n(){}t.exports=n})),DF=r(((e,t)=>{var n=IN(),r=EF(),i=yP();t.exports=n&&1/i(new n([,-0]))[1]==1/0?function(e){return new n(e)}:r})),OF=r(((e,t)=>{var n=mP(),r=wF(),i=TF(),a=gP(),o=DF(),s=yP(),c=200;function l(e,t,l){var u=-1,d=r,f=e.length,p=!0,m=[],h=m;if(l)p=!1,d=i;else if(f>=c){var g=t?null:o(e);if(g)return s(g);p=!1,d=a,h=new n}else h=t?[]:m;outer:for(;++u<f;){var _=e[u],v=t?t(_):_;if(_=l||_!==0?_:0,p&&v===v){for(var y=h.length;y--;)if(h[y]===v)continue outer;t&&h.push(v),m.push(_)}else d(h,v,l)||(h!==m&&h.push(v),m.push(_))}return m}t.exports=l})),kF=r(((e,t)=>{var n=mN(),r=ZM();function i(e){return r(e)&&n(e)}t.exports=i})),AF=r(((e,t)=>{var n=pF(),r=yF(),i=OF(),a=kF();t.exports=r(function(e){return i(n(e,1,a,!0))})})),jF=r(((e,t)=>{var n=PP();function r(e,t){return n(t,function(t){return e[t]})}t.exports=r})),MF=r(((e,t)=>{var n=jF(),r=hN();function i(e){return e==null?[]:n(e,r(e))}t.exports=i})),NF=r(((t,n)=>{var r;if(typeof e==`function`)try{r={clone:eP(),constant:tP(),each:uP(),filter:YP(),has:ZP(),isArray:eN(),isEmpty:QP(),isFunction:bM(),isUndefined:$P(),keys:hN(),map:tF(),reduce:iF(),size:uF(),transform:dF(),union:AF(),values:MF()}}catch{}r||=window._,n.exports=r})),PF=r(((e,t)=>{var n=NF();t.exports=o;var r=`\0`,i=`\0`,a=``;function o(e){this._isDirected=!n.has(e,`directed`)||e.directed,this._isMultigraph=n.has(e,`multigraph`)?e.multigraph:!1,this._isCompound=n.has(e,`compound`)?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=n.constant(void 0),this._defaultEdgeLabelFn=n.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[i]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}o.prototype._nodeCount=0,o.prototype._edgeCount=0,o.prototype.isDirected=function(){return this._isDirected},o.prototype.isMultigraph=function(){return this._isMultigraph},o.prototype.isCompound=function(){return this._isCompound},o.prototype.setGraph=function(e){return this._label=e,this},o.prototype.graph=function(){return this._label},o.prototype.setDefaultNodeLabel=function(e){return n.isFunction(e)||(e=n.constant(e)),this._defaultNodeLabelFn=e,this},o.prototype.nodeCount=function(){return this._nodeCount},o.prototype.nodes=function(){return n.keys(this._nodes)},o.prototype.sources=function(){var e=this;return n.filter(this.nodes(),function(t){return n.isEmpty(e._in[t])})},o.prototype.sinks=function(){var e=this;return n.filter(this.nodes(),function(t){return n.isEmpty(e._out[t])})},o.prototype.setNodes=function(e,t){var r=arguments,i=this;return n.each(e,function(e){r.length>1?i.setNode(e,t):i.setNode(e)}),this},o.prototype.setNode=function(e,t){return n.has(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=i,this._children[e]={},this._children[i][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)},o.prototype.node=function(e){return this._nodes[e]},o.prototype.hasNode=function(e){return n.has(this._nodes,e)},o.prototype.removeNode=function(e){var t=this;if(n.has(this._nodes,e)){var r=function(e){t.removeEdge(t._edgeObjs[e])};delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],n.each(this.children(e),function(e){t.setParent(e)}),delete this._children[e]),n.each(n.keys(this._in[e]),r),delete this._in[e],delete this._preds[e],n.each(n.keys(this._out[e]),r),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this},o.prototype.setParent=function(e,t){if(!this._isCompound)throw Error(`Cannot set parent in a non-compound graph`);if(n.isUndefined(t))t=i;else{t+=``;for(var r=t;!n.isUndefined(r);r=this.parent(r))if(r===e)throw Error(`Setting `+t+` as parent of `+e+` would create a cycle`);this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this},o.prototype._removeFromParentsChildList=function(e){delete this._children[this._parent[e]][e]},o.prototype.parent=function(e){if(this._isCompound){var t=this._parent[e];if(t!==i)return t}},o.prototype.children=function(e){if(n.isUndefined(e)&&(e=i),this._isCompound){var t=this._children[e];if(t)return n.keys(t)}else if(e===i)return this.nodes();else if(this.hasNode(e))return[]},o.prototype.predecessors=function(e){var t=this._preds[e];if(t)return n.keys(t)},o.prototype.successors=function(e){var t=this._sucs[e];if(t)return n.keys(t)},o.prototype.neighbors=function(e){var t=this.predecessors(e);if(t)return n.union(t,this.successors(e))},o.prototype.isLeaf=function(e){return(this.isDirected()?this.successors(e):this.neighbors(e)).length===0},o.prototype.filterNodes=function(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var r=this;n.each(this._nodes,function(n,r){e(r)&&t.setNode(r,n)}),n.each(this._edgeObjs,function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,r.edge(e))});var i={};function a(e){var n=r.parent(e);return n===void 0||t.hasNode(n)?(i[e]=n,n):n in i?i[n]:a(n)}return this._isCompound&&n.each(t.nodes(),function(e){t.setParent(e,a(e))}),t},o.prototype.setDefaultEdgeLabel=function(e){return n.isFunction(e)||(e=n.constant(e)),this._defaultEdgeLabelFn=e,this},o.prototype.edgeCount=function(){return this._edgeCount},o.prototype.edges=function(){return n.values(this._edgeObjs)},o.prototype.setPath=function(e,t){var r=this,i=arguments;return n.reduce(e,function(e,n){return i.length>1?r.setEdge(e,n,t):r.setEdge(e,n),n}),this},o.prototype.setEdge=function(){var e,t,r,i,a=!1,o=arguments[0];typeof o==`object`&&o&&`v`in o?(e=o.v,t=o.w,r=o.name,arguments.length===2&&(i=arguments[1],a=!0)):(e=o,t=arguments[1],r=arguments[3],arguments.length>2&&(i=arguments[2],a=!0)),e=``+e,t=``+t,n.isUndefined(r)||(r=``+r);var c=l(this._isDirected,e,t,r);if(n.has(this._edgeLabels,c))return a&&(this._edgeLabels[c]=i),this;if(!n.isUndefined(r)&&!this._isMultigraph)throw Error(`Cannot set a named edge when isMultigraph = false`);this.setNode(e),this.setNode(t),this._edgeLabels[c]=a?i:this._defaultEdgeLabelFn(e,t,r);var d=u(this._isDirected,e,t,r);return e=d.v,t=d.w,Object.freeze(d),this._edgeObjs[c]=d,s(this._preds[t],e),s(this._sucs[e],t),this._in[t][c]=d,this._out[e][c]=d,this._edgeCount++,this},o.prototype.edge=function(e,t,n){var r=arguments.length===1?d(this._isDirected,arguments[0]):l(this._isDirected,e,t,n);return this._edgeLabels[r]},o.prototype.hasEdge=function(e,t,r){var i=arguments.length===1?d(this._isDirected,arguments[0]):l(this._isDirected,e,t,r);return n.has(this._edgeLabels,i)},o.prototype.removeEdge=function(e,t,n){var r=arguments.length===1?d(this._isDirected,arguments[0]):l(this._isDirected,e,t,n),i=this._edgeObjs[r];return i&&(e=i.v,t=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],c(this._preds[t],e),c(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this},o.prototype.inEdges=function(e,t){var r=this._in[e];if(r){var i=n.values(r);return t?n.filter(i,function(e){return e.v===t}):i}},o.prototype.outEdges=function(e,t){var r=this._out[e];if(r){var i=n.values(r);return t?n.filter(i,function(e){return e.w===t}):i}},o.prototype.nodeEdges=function(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))};function s(e,t){e[t]?e[t]++:e[t]=1}function c(e,t){--e[t]||delete e[t]}function l(e,t,i,o){var s=``+t,c=``+i;if(!e&&s>c){var l=s;s=c,c=l}return s+a+c+a+(n.isUndefined(o)?r:o)}function u(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function d(e,t){return l(e,t.v,t.w,t.name)}})),FF=r(((e,t)=>{t.exports=`2.1.8`})),IF=r(((e,t)=>{t.exports={Graph:PF(),version:FF()}})),LF=r(((e,t)=>{var n=NF(),r=PF();t.exports={write:i,read:s};function i(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:a(e),edges:o(e)};return n.isUndefined(e.graph())||(t.value=n.clone(e.graph())),t}function a(e){return n.map(e.nodes(),function(t){var r=e.node(t),i=e.parent(t),a={v:t};return n.isUndefined(r)||(a.value=r),n.isUndefined(i)||(a.parent=i),a})}function o(e){return n.map(e.edges(),function(t){var r=e.edge(t),i={v:t.v,w:t.w};return n.isUndefined(t.name)||(i.name=t.name),n.isUndefined(r)||(i.value=r),i})}function s(e){var t=new r(e.options).setGraph(e.value);return n.each(e.nodes,function(e){t.setNode(e.v,e.value),e.parent&&t.setParent(e.v,e.parent)}),n.each(e.edges,function(e){t.setEdge({v:e.v,w:e.w,name:e.name},e.value)}),t}})),RF=r(((e,t)=>{var n=NF();t.exports=r;function r(e){var t={},r=[],i;function a(r){n.has(t,r)||(t[r]=!0,i.push(r),n.each(e.successors(r),a),n.each(e.predecessors(r),a))}return n.each(e.nodes(),function(e){i=[],a(e),i.length&&r.push(i)}),r}})),zF=r(((e,t)=>{var n=NF();t.exports=r;function r(){this._arr=[],this._keyIndices={}}r.prototype.size=function(){return this._arr.length},r.prototype.keys=function(){return this._arr.map(function(e){return e.key})},r.prototype.has=function(e){return n.has(this._keyIndices,e)},r.prototype.priority=function(e){var t=this._keyIndices[e];if(t!==void 0)return this._arr[t].priority},r.prototype.min=function(){if(this.size()===0)throw Error(`Queue underflow`);return this._arr[0].key},r.prototype.add=function(e,t){var r=this._keyIndices;if(e=String(e),!n.has(r,e)){var i=this._arr,a=i.length;return r[e]=a,i.push({key:e,priority:t}),this._decrease(a),!0}return!1},r.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key},r.prototype.decrease=function(e,t){var n=this._keyIndices[e];if(t>this._arr[n].priority)throw Error(`New priority is greater than current priority. Key: `+e+` Old: `+this._arr[n].priority+` New: `+t);this._arr[n].priority=t,this._decrease(n)},r.prototype._heapify=function(e){var t=this._arr,n=2*e,r=n+1,i=e;n<t.length&&(i=t[n].priority<t[i].priority?n:i,r<t.length&&(i=t[r].priority<t[i].priority?r:i),i!==e&&(this._swap(e,i),this._heapify(i)))},r.prototype._decrease=function(e){for(var t=this._arr,n=t[e].priority,r;e!==0&&(r=e>>1,!(t[r].priority<n));)this._swap(e,r),e=r},r.prototype._swap=function(e,t){var n=this._arr,r=this._keyIndices,i=n[e],a=n[t];n[e]=a,n[t]=i,r[a.key]=e,r[i.key]=t}})),BF=r(((e,t)=>{var n=NF(),r=zF();t.exports=a;var i=n.constant(1);function a(e,t,n,r){return o(e,String(t),n||i,r||function(t){return e.outEdges(t)})}function o(e,t,n,i){var a={},o=new r,s,c,l=function(e){var t=e.v===s?e.w:e.v,r=a[t],i=n(e),l=c.distance+i;if(i<0)throw Error(`dijkstra does not allow negative edge weights. Bad edge: `+e+` Weight: `+i);l<r.distance&&(r.distance=l,r.predecessor=s,o.decrease(t,l))};for(e.nodes().forEach(function(e){var n=e===t?0:1/0;a[e]={distance:n},o.add(e,n)});o.size()>0&&(s=o.removeMin(),c=a[s],c.distance!==1/0);)i(s).forEach(l);return a}})),VF=r(((e,t)=>{var n=BF(),r=NF();t.exports=i;function i(e,t,i){return r.transform(e.nodes(),function(r,a){r[a]=n(e,a,t,i)},{})}})),HF=r(((e,t)=>{var n=NF();t.exports=r;function r(e){var t=0,r=[],i={},a=[];function o(s){var c=i[s]={onStack:!0,lowlink:t,index:t++};if(r.push(s),e.successors(s).forEach(function(e){n.has(i,e)?i[e].onStack&&(c.lowlink=Math.min(c.lowlink,i[e].index)):(o(e),c.lowlink=Math.min(c.lowlink,i[e].lowlink))}),c.lowlink===c.index){var l=[],u;do u=r.pop(),i[u].onStack=!1,l.push(u);while(s!==u);a.push(l)}}return e.nodes().forEach(function(e){n.has(i,e)||o(e)}),a}})),UF=r(((e,t)=>{var n=NF(),r=HF();t.exports=i;function i(e){return n.filter(r(e),function(t){return t.length>1||t.length===1&&e.hasEdge(t[0],t[0])})}})),WF=r(((e,t)=>{var n=NF();t.exports=i;var r=n.constant(1);function i(e,t,n){return a(e,t||r,n||function(t){return e.outEdges(t)})}function a(e,t,n){var r={},i=e.nodes();return i.forEach(function(e){r[e]={},r[e][e]={distance:0},i.forEach(function(t){e!==t&&(r[e][t]={distance:1/0})}),n(e).forEach(function(n){var i=n.v===e?n.w:n.v,a=t(n);r[e][i]={distance:a,predecessor:e}})}),i.forEach(function(e){var t=r[e];i.forEach(function(n){var a=r[n];i.forEach(function(n){var r=a[e],i=t[n],o=a[n],s=r.distance+i.distance;s<o.distance&&(o.distance=s,o.predecessor=i.predecessor)})})}),r}})),GF=r(((e,t)=>{var n=NF();t.exports=r,r.CycleException=i;function r(e){var t={},r={},a=[];function o(s){if(n.has(r,s))throw new i;n.has(t,s)||(r[s]=!0,t[s]=!0,n.each(e.predecessors(s),o),delete r[s],a.push(s))}if(n.each(e.sinks(),o),n.size(t)!==e.nodeCount())throw new i;return a}function i(){}i.prototype=Error()})),KF=r(((e,t)=>{var n=GF();t.exports=r;function r(e){try{n(e)}catch(e){if(e instanceof n.CycleException)return!1;throw e}return!0}})),qF=r(((e,t)=>{var n=NF();t.exports=r;function r(e,t,r){n.isArray(t)||(t=[t]);var a=(e.isDirected()?e.successors:e.neighbors).bind(e),o=[],s={};return n.each(t,function(t){if(!e.hasNode(t))throw Error(`Graph does not have node: `+t);i(e,t,r===`post`,s,a,o)}),o}function i(e,t,r,a,o,s){n.has(a,t)||(a[t]=!0,r||s.push(t),n.each(o(t),function(t){i(e,t,r,a,o,s)}),r&&s.push(t))}})),JF=r(((e,t)=>{var n=qF();t.exports=r;function r(e,t){return n(e,t,`post`)}})),YF=r(((e,t)=>{var n=qF();t.exports=r;function r(e,t){return n(e,t,`pre`)}})),XF=r(((e,t)=>{var n=NF(),r=PF(),i=zF();t.exports=a;function a(e,t){var a=new r,o={},s=new i,c;function l(e){var n=e.v===c?e.w:e.v,r=s.priority(n);if(r!==void 0){var i=t(e);i<r&&(o[n]=c,s.decrease(n,i))}}if(e.nodeCount()===0)return a;n.each(e.nodes(),function(e){s.add(e,1/0),a.setNode(e)}),s.decrease(e.nodes()[0],0);for(var u=!1;s.size()>0;){if(c=s.removeMin(),n.has(o,c))a.setEdge(c,o[c]);else if(u)throw Error(`Input graph is not connected: `+e);else u=!0;e.nodeEdges(c).forEach(l)}return a}})),ZF=r(((e,t)=>{t.exports={components:RF(),dijkstra:BF(),dijkstraAll:VF(),findCycles:UF(),floydWarshall:WF(),isAcyclic:KF(),postorder:JF(),preorder:YF(),prim:XF(),tarjan:HF(),topsort:GF()}})),QF=r(((e,t)=>{var n=IF();t.exports={Graph:n.Graph,json:LF(),alg:ZF(),version:n.version}})),$F=r(((t,n)=>{var r;if(typeof e==`function`)try{r=QF()}catch{}r||=window.graphlib,n.exports=r})),eI=r(((e,t)=>{var n=$N(),r=1,i=4;function a(e){return n(e,r|i)}t.exports=a})),tI=r(((e,t)=>{var n=nM(),r=mN(),i=rN(),a=yM();function o(e,t,o){if(!a(o))return!1;var s=typeof t;return(s==`number`?r(o)&&i(t,o.length):s==`string`&&t in o)?n(o[t],e):!1}t.exports=o})),nI=r(((e,t)=>{var n=yF(),r=nM(),i=tI(),a=yN(),o=Object.prototype,s=o.hasOwnProperty;t.exports=n(function(e,t){e=Object(e);var n=-1,c=t.length,l=c>2?t[2]:void 0;for(l&&i(t[0],t[1],l)&&(c=1);++n<c;)for(var u=t[n],d=a(u),f=-1,p=d.length;++f<p;){var m=d[f],h=e[m];(h===void 0||r(h,o[m])&&!s.call(e,m))&&(e[m]=u[m])}return e})})),rI=r(((e,t)=>{var n=JP(),r=mN(),i=hN();function a(e){return function(t,a,o){var s=Object(t);if(!r(t)){var c=n(a,3);t=i(t),a=function(e){return c(s[e],e,s)}}var l=e(t,a,o);return l>-1?s[c?t[l]:l]:void 0}}t.exports=a})),iI=r(((e,t)=>{var n=/\s/;function r(e){for(var t=e.length;t--&&n.test(e.charAt(t)););return t}t.exports=r})),aI=r(((e,t)=>{var n=iI(),r=/^\s+/;function i(e){return e&&e.slice(0,n(e)+1).replace(r,``)}t.exports=i})),oI=r(((e,t)=>{var n=aI(),r=yM(),i=kP(),a=NaN,o=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,c=/^0o[0-7]+$/i,l=parseInt;function u(e){if(typeof e==`number`)return e;if(i(e))return a;if(r(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=r(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=n(e);var u=s.test(e);return u||c.test(e)?l(e.slice(2),u?2:8):o.test(e)?a:+e}t.exports=u})),sI=r(((e,t)=>{var n=oI(),r=1/0,i=17976931348623157e292;function a(e){return e?(e=n(e),e===r||e===-r?(e<0?-1:1)*i:e===e?e:0):e===0?e:0}t.exports=a})),cI=r(((e,t)=>{var n=sI();function r(e){var t=n(e),r=t%1;return t===t?r?t-r:t:0}t.exports=r})),lI=r(((e,t)=>{var n=bF(),r=JP(),i=cI(),a=Math.max;function o(e,t,o){var s=e==null?0:e.length;if(!s)return-1;var c=o==null?0:i(o);return c<0&&(c=a(s+c,0)),n(e,r(t,3),c)}t.exports=o})),uI=r(((e,t)=>{t.exports=rI()(lI())})),dI=r(((e,t)=>{var n=pF();function r(e){return e!=null&&e.length?n(e,1):[]}t.exports=r})),fI=r(((e,t)=>{var n=rP(),r=cP(),i=yN();function a(e,t){return e==null?e:n(e,r(t),i)}t.exports=a})),pI=r(((e,t)=>{function n(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}t.exports=n})),mI=r(((e,t)=>{var n=qM(),r=iP(),i=JP();function a(e,t){var a={};return t=i(t,3),r(e,function(e,r,i){n(a,r,t(e,r,i))}),a}t.exports=a})),hI=r(((e,t)=>{var n=kP();function r(e,t,r){for(var i=-1,a=e.length;++i<a;){var o=e[i],s=t(o);if(s!=null&&(c===void 0?s===s&&!n(s):r(s,c)))var c=s,l=o}return l}t.exports=r})),gI=r(((e,t)=>{function n(e,t){return e>t}t.exports=n})),_I=r(((e,t)=>{var n=hI(),r=gI(),i=sP();function a(e){return e&&e.length?n(e,i,r):void 0}t.exports=a})),vI=r(((e,t)=>{var n=qM(),r=nM();function i(e,t,i){(i!==void 0&&!r(e[t],i)||i===void 0&&!(t in e))&&n(e,t,i)}t.exports=i})),yI=r(((e,t)=>{var n=vM(),r=ON(),i=ZM(),a=`[object Object]`,o=Function.prototype,s=Object.prototype,c=o.toString,l=s.hasOwnProperty,u=c.call(Object);function d(e){if(!i(e)||n(e)!=a)return!1;var t=r(e);if(t===null)return!0;var o=l.call(t,`constructor`)&&t.constructor;return typeof o==`function`&&o instanceof o&&c.call(o)==u}t.exports=d})),bI=r(((e,t)=>{function n(e,t){if((t!==`constructor`||typeof e[t]!=`function`)&&t!=`__proto__`)return e[t]}t.exports=n})),xI=r(((e,t)=>{var n=YM(),r=yN();function i(e){return n(e,r(e))}t.exports=i})),SI=r(((e,t)=>{var n=vI(),r=xN(),i=GN(),a=SN(),o=JN(),s=$M(),c=eN(),l=kF(),u=nN(),d=bM(),f=yM(),p=yI(),m=cN(),h=bI(),g=xI();function _(e,t,_,v,y,b,x){var S=h(e,_),C=h(t,_),w=x.get(C);if(w){n(e,_,w);return}var T=b?b(S,C,_+``,e,t,x):void 0,E=T===void 0;if(E){var D=c(C),O=!D&&u(C),k=!D&&!O&&m(C);T=C,D||O||k?c(S)?T=S:l(S)?T=a(S):O?(E=!1,T=r(C,!0)):k?(E=!1,T=i(C,!0)):T=[]:p(C)||s(C)?(T=S,s(S)?T=g(S):(!f(S)||d(S))&&(T=o(C))):E=!1}E&&(x.set(C,T),y(T,C,v,b,x),x.delete(C)),n(e,_,T)}t.exports=_})),CI=r(((e,t)=>{var n=WM(),r=vI(),i=rP(),a=SI(),o=yM(),s=yN(),c=bI();function l(e,t,u,d,f){e!==t&&i(t,function(i,s){if(f||=new n,o(i))a(e,t,s,u,l,d,f);else{var p=d?d(c(e,s),i,s+``,e,t,f):void 0;p===void 0&&(p=i),r(e,s,p)}},s)}t.exports=l})),wI=r(((e,t)=>{var n=yF(),r=tI();function i(e){return n(function(t,n){var i=-1,a=n.length,o=a>1?n[a-1]:void 0,s=a>2?n[2]:void 0;for(o=e.length>3&&typeof o==`function`?(a--,o):void 0,s&&r(n[0],n[1],s)&&(o=a<3?void 0:o,a=1),t=Object(t);++i<a;){var c=n[i];c&&e(t,c,i,o)}return t})}t.exports=i})),TI=r(((e,t)=>{var n=CI();t.exports=wI()(function(e,t,r){n(e,t,r)})})),EI=r(((e,t)=>{function n(e,t){return e<t}t.exports=n})),DI=r(((e,t)=>{var n=hI(),r=EI(),i=sP();function a(e){return e&&e.length?n(e,i,r):void 0}t.exports=a})),OI=r(((e,t)=>{var n=hI(),r=JP(),i=EI();function a(e,t){return e&&e.length?n(e,r(t,2),i):void 0}t.exports=a})),kI=r(((e,t)=>{var n=mM();t.exports=function(){return n.Date.now()}})),AI=r(((e,t)=>{var n=JM(),r=LP(),i=rN(),a=yM(),o=RP();function s(e,t,s,c){if(!a(e))return e;t=r(t,e);for(var l=-1,u=t.length,d=u-1,f=e;f!=null&&++l<u;){var p=o(t[l]),m=s;if(p===`__proto__`||p===`constructor`||p===`prototype`)return e;if(l!=d){var h=f[p];m=c?c(h,p,f):void 0,m===void 0&&(m=a(h)?h:i(t[l+1])?[]:{})}n(f,p,m),f=f[p]}return e}t.exports=s})),jI=r(((e,t)=>{var n=zP(),r=AI(),i=LP();function a(e,t,a){for(var o=-1,s=t.length,c={};++o<s;){var l=t[o],u=n(e,l);a(u,l)&&r(c,i(l,e),u)}return c}t.exports=a})),MI=r(((e,t)=>{var n=jI(),r=UP();function i(e,t){return n(e,t,function(t,n){return r(e,n)})}t.exports=i})),NI=r(((e,t)=>{var n=dI(),r=hF(),i=vF();function a(e){return i(r(e,void 0,n),e+``)}t.exports=a})),PI=r(((e,t)=>{var n=MI();t.exports=NI()(function(e,t){return e==null?{}:n(e,t)})})),FI=r(((e,t)=>{var n=Math.ceil,r=Math.max;function i(e,t,i,a){for(var o=-1,s=r(n((t-e)/(i||1)),0),c=Array(s);s--;)c[a?s:++o]=e,e+=i;return c}t.exports=i})),II=r(((e,t)=>{var n=FI(),r=tI(),i=sI();function a(e){return function(t,a,o){return o&&typeof o!=`number`&&r(t,a,o)&&(a=o=void 0),t=i(t),a===void 0?(a=t,t=0):a=i(a),o=o===void 0?t<a?1:-1:i(o),n(t,a,o,e)}}t.exports=a})),LI=r(((e,t)=>{t.exports=II()()})),RI=r(((e,t)=>{function n(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}t.exports=n})),zI=r(((e,t)=>{var n=kP();function r(e,t){if(e!==t){var r=e!==void 0,i=e===null,a=e===e,o=n(e),s=t!==void 0,c=t===null,l=t===t,u=n(t);if(!c&&!u&&!o&&e>t||o&&s&&l&&!c&&!u||i&&s&&l||!r&&l||!a)return 1;if(!i&&!o&&!u&&e<t||u&&r&&a&&!i&&!o||c&&r&&a||!s&&a||!l)return-1}return 0}t.exports=r})),BI=r(((e,t)=>{var n=zI();function r(e,t,r){for(var i=-1,a=e.criteria,o=t.criteria,s=a.length,c=r.length;++i<s;){var l=n(a[i],o[i]);if(l)return i>=c?l:l*(r[i]==`desc`?-1:1)}return e.index-t.index}t.exports=r})),VI=r(((e,t)=>{var n=PP(),r=zP(),i=JP(),a=eF(),o=RI(),s=oN(),c=BI(),l=sP(),u=eN();function d(e,t,d){t=t.length?n(t,function(e){return u(e)?function(t){return r(t,e.length===1?e[0]:e)}:e}):[l];var f=-1;return t=n(t,s(i)),o(a(e,function(e,r,i){return{criteria:n(t,function(t){return t(e)}),index:++f,value:e}}),function(e,t){return c(e,t,d)})}t.exports=d})),HI=r(((e,t)=>{var n=pF(),r=VI(),i=yF(),a=tI();t.exports=i(function(e,t){if(e==null)return[];var i=t.length;return i>1&&a(e,t[0],t[1])?t=[]:i>2&&a(t[0],t[1],t[2])&&(t=[t[0]]),r(e,n(t,1),[])})})),UI=r(((e,t)=>{var n=IP(),r=0;function i(e){var t=++r;return n(e)+t}t.exports=i})),WI=r(((e,t)=>{function n(e,t,n){for(var r=-1,i=e.length,a=t.length,o={};++r<i;){var s=r<a?t[r]:void 0;n(o,e[r],s)}return o}t.exports=n})),GI=r(((e,t)=>{var n=JM(),r=WI();function i(e,t){return r(e||[],t||[],n)}t.exports=i})),KI=r(((t,n)=>{var r;if(typeof e==`function`)try{r={cloneDeep:eI(),constant:tP(),defaults:nI(),each:uP(),filter:YP(),find:uI(),flatten:dI(),forEach:lP(),forIn:fI(),has:ZP(),isUndefined:$P(),last:pI(),map:tF(),mapValues:mI(),max:_I(),merge:TI(),min:DI(),minBy:OI(),now:kI(),pick:PI(),range:LI(),reduce:iF(),sortBy:HI(),uniqueId:UI(),values:MF(),zipObject:GI()}}catch{}r||=window._,n.exports=r})),qI=r(((e,t)=>{t.exports=n;function n(){var e={};e._next=e._prev=e,this._sentinel=e}n.prototype.dequeue=function(){var e=this._sentinel,t=e._prev;if(t!==e)return r(t),t},n.prototype.enqueue=function(e){var t=this._sentinel;e._prev&&e._next&&r(e),e._next=t._next,t._next._prev=e,t._next=e,e._prev=t},n.prototype.toString=function(){for(var e=[],t=this._sentinel,n=t._prev;n!==t;)e.push(JSON.stringify(n,i)),n=n._prev;return`[`+e.join(`, `)+`]`};function r(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function i(e,t){if(e!==`_next`&&e!==`_prev`)return t}})),JI=r(((e,t)=>{var n=KI(),r=$F().Graph,i=qI();t.exports=o;var a=n.constant(1);function o(e,t){if(e.nodeCount()<=1)return[];var r=l(e,t||a),i=s(r.graph,r.buckets,r.zeroIdx);return n.flatten(n.map(i,function(t){return e.outEdges(t.v,t.w)}),!0)}function s(e,t,n){for(var r=[],i=t[t.length-1],a=t[0],o;e.nodeCount();){for(;o=a.dequeue();)c(e,t,n,o);for(;o=i.dequeue();)c(e,t,n,o);if(e.nodeCount()){for(var s=t.length-2;s>0;--s)if(o=t[s].dequeue(),o){r=r.concat(c(e,t,n,o,!0));break}}}return r}function c(e,t,r,i,a){var o=a?[]:void 0;return n.forEach(e.inEdges(i.v),function(n){var i=e.edge(n),s=e.node(n.v);a&&o.push({v:n.v,w:n.w}),s.out-=i,u(t,r,s)}),n.forEach(e.outEdges(i.v),function(n){var i=e.edge(n),a=n.w,o=e.node(a);o.in-=i,u(t,r,o)}),e.removeNode(i.v),o}function l(e,t){var a=new r,o=0,s=0;n.forEach(e.nodes(),function(e){a.setNode(e,{v:e,in:0,out:0})}),n.forEach(e.edges(),function(e){var n=a.edge(e.v,e.w)||0,r=t(e),i=n+r;a.setEdge(e.v,e.w,i),s=Math.max(s,a.node(e.v).out+=r),o=Math.max(o,a.node(e.w).in+=r)});var c=n.range(s+o+3).map(function(){return new i}),l=o+1;return n.forEach(a.nodes(),function(e){u(c,l,a.node(e))}),{graph:a,buckets:c,zeroIdx:l}}function u(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}})),YI=r(((e,t)=>{var n=KI(),r=JI();t.exports={run:i,undo:o};function i(e){var t=e.graph().acyclicer===`greedy`?r(e,i(e)):a(e);n.forEach(t,function(t){var r=e.edge(t);e.removeEdge(t),r.forwardName=t.name,r.reversed=!0,e.setEdge(t.w,t.v,r,n.uniqueId(`rev`))});function i(e){return function(t){return e.edge(t).weight}}}function a(e){var t=[],r={},i={};function a(o){n.has(i,o)||(i[o]=!0,r[o]=!0,n.forEach(e.outEdges(o),function(e){n.has(r,e.w)?t.push(e):a(e.w)}),delete r[o])}return n.forEach(e.nodes(),a),t}function o(e){n.forEach(e.edges(),function(t){var n=e.edge(t);if(n.reversed){e.removeEdge(t);var r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}})}})),XI=r(((e,t)=>{var n=KI(),r=$F().Graph;t.exports={addDummyNode:i,simplify:a,asNonCompoundGraph:o,successorWeights:s,predecessorWeights:c,intersectRect:l,buildLayerMatrix:u,normalizeRanks:d,removeEmptyRanks:f,addBorderNode:p,maxRank:m,partition:h,time:g,notime:_};function i(e,t,r,i){var a;do a=n.uniqueId(i);while(e.hasNode(a));return r.dummy=t,e.setNode(a,r),a}function a(e){var t=new r().setGraph(e.graph());return n.forEach(e.nodes(),function(n){t.setNode(n,e.node(n))}),n.forEach(e.edges(),function(n){var r=t.edge(n.v,n.w)||{weight:0,minlen:1},i=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})}),t}function o(e){var t=new r({multigraph:e.isMultigraph()}).setGraph(e.graph());return n.forEach(e.nodes(),function(n){e.children(n).length||t.setNode(n,e.node(n))}),n.forEach(e.edges(),function(n){t.setEdge(n,e.edge(n))}),t}function s(e){var t=n.map(e.nodes(),function(t){var r={};return n.forEach(e.outEdges(t),function(t){r[t.w]=(r[t.w]||0)+e.edge(t).weight}),r});return n.zipObject(e.nodes(),t)}function c(e){var t=n.map(e.nodes(),function(t){var r={};return n.forEach(e.inEdges(t),function(t){r[t.v]=(r[t.v]||0)+e.edge(t).weight}),r});return n.zipObject(e.nodes(),t)}function l(e,t){var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2;if(!i&&!a)throw Error(`Not possible to find intersection inside of the rectangle`);var c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=s*i/a,l=s):(i<0&&(o=-o),c=o,l=o*a/i),{x:n+c,y:r+l}}function u(e){var t=n.map(n.range(m(e)+1),function(){return[]});return n.forEach(e.nodes(),function(r){var i=e.node(r),a=i.rank;n.isUndefined(a)||(t[a][i.order]=r)}),t}function d(e){var t=n.min(n.map(e.nodes(),function(t){return e.node(t).rank}));n.forEach(e.nodes(),function(r){var i=e.node(r);n.has(i,`rank`)&&(i.rank-=t)})}function f(e){var t=n.min(n.map(e.nodes(),function(t){return e.node(t).rank})),r=[];n.forEach(e.nodes(),function(n){var i=e.node(n).rank-t;r[i]||(r[i]=[]),r[i].push(n)});var i=0,a=e.graph().nodeRankFactor;n.forEach(r,function(t,r){n.isUndefined(t)&&r%a!==0?--i:i&&n.forEach(t,function(t){e.node(t).rank+=i})})}function p(e,t,n,r){var a={width:0,height:0};return arguments.length>=4&&(a.rank=n,a.order=r),i(e,`border`,a,t)}function m(e){return n.max(n.map(e.nodes(),function(t){var r=e.node(t).rank;if(!n.isUndefined(r))return r}))}function h(e,t){var r={lhs:[],rhs:[]};return n.forEach(e,function(e){t(e)?r.lhs.push(e):r.rhs.push(e)}),r}function g(e,t){var r=n.now();try{return t()}finally{console.log(e+` time: `+(n.now()-r)+`ms`)}}function _(e,t){return t()}})),ZI=r(((e,t)=>{var n=KI(),r=XI();t.exports={run:i,undo:o};function i(e){e.graph().dummyChains=[],n.forEach(e.edges(),function(t){a(e,t)})}function a(e,t){var n=t.v,i=e.node(n).rank,a=t.w,o=e.node(a).rank,s=t.name,c=e.edge(t),l=c.labelRank;if(o!==i+1){e.removeEdge(t);var u,d,f=0;for(++i;i<o;++f,++i)c.points=[],d={width:0,height:0,edgeLabel:c,edgeObj:t,rank:i},u=r.addDummyNode(e,`edge`,d,`_d`),i===l&&(d.width=c.width,d.height=c.height,d.dummy=`edge-label`,d.labelpos=c.labelpos),e.setEdge(n,u,{weight:c.weight},s),f===0&&e.graph().dummyChains.push(u),n=u;e.setEdge(n,a,{weight:c.weight},s)}}function o(e){n.forEach(e.graph().dummyChains,function(t){var n=e.node(t),r=n.edgeLabel,i;for(e.setEdge(n.edgeObj,r);n.dummy;)i=e.successors(t)[0],e.removeNode(t),r.points.push({x:n.x,y:n.y}),n.dummy===`edge-label`&&(r.x=n.x,r.y=n.y,r.width=n.width,r.height=n.height),t=i,n=e.node(t)})}})),QI=r(((e,t)=>{var n=KI();t.exports={longestPath:r,slack:i};function r(e){var t={};function r(i){var a=e.node(i);if(n.has(t,i))return a.rank;t[i]=!0;var o=n.min(n.map(e.outEdges(i),function(t){return r(t.w)-e.edge(t).minlen}));return(o===1/0||o==null)&&(o=0),a.rank=o}n.forEach(e.sources(),r)}function i(e,t){return e.node(t.w).rank-e.node(t.v).rank-e.edge(t).minlen}})),$I=r(((e,t)=>{var n=KI(),r=$F().Graph,i=QI().slack;t.exports=a;function a(e){var t=new r({directed:!1}),n=e.nodes()[0],a=e.nodeCount();t.setNode(n,{});for(var l,u;o(t,e)<a;)l=s(t,e),u=t.hasNode(l.v)?i(e,l):-i(e,l),c(t,e,u);return t}function o(e,t){function r(a){n.forEach(t.nodeEdges(a),function(n){var o=n.v,s=a===o?n.w:o;!e.hasNode(s)&&!i(t,n)&&(e.setNode(s,{}),e.setEdge(a,s,{}),r(s))})}return n.forEach(e.nodes(),r),e.nodeCount()}function s(e,t){return n.minBy(t.edges(),function(n){if(e.hasNode(n.v)!==e.hasNode(n.w))return i(t,n)})}function c(e,t,r){n.forEach(e.nodes(),function(e){t.node(e).rank+=r})}})),eL=r(((e,t)=>{var n=KI(),r=$I(),i=QI().slack,a=QI().longestPath,o=$F().alg.preorder,s=$F().alg.postorder,c=XI().simplify;t.exports=l,l.initLowLimValues=p,l.initCutValues=u,l.calcCutValue=f,l.leaveEdge=h,l.enterEdge=g,l.exchangeEdges=_;function l(e){e=c(e),a(e);var t=r(e);p(t),u(t,e);for(var n,i;n=h(t);)i=g(t,e,n),_(t,e,n,i)}function u(e,t){var r=s(e,e.nodes());r=r.slice(0,r.length-1),n.forEach(r,function(n){d(e,t,n)})}function d(e,t,n){var r=e.node(n).parent;e.edge(n,r).cutvalue=f(e,t,n)}function f(e,t,r){var i=e.node(r).parent,a=!0,o=t.edge(r,i),s=0;return o||=(a=!1,t.edge(i,r)),s=o.weight,n.forEach(t.nodeEdges(r),function(n){var o=n.v===r,c=o?n.w:n.v;if(c!==i){var l=o===a,u=t.edge(n).weight;if(s+=l?u:-u,y(e,r,c)){var d=e.edge(r,c).cutvalue;s+=l?-d:d}}}),s}function p(e,t){arguments.length<2&&(t=e.nodes()[0]),m(e,{},1,t)}function m(e,t,r,i,a){var o=r,s=e.node(i);return t[i]=!0,n.forEach(e.neighbors(i),function(a){n.has(t,a)||(r=m(e,t,r,a,i))}),s.low=o,s.lim=r++,a?s.parent=a:delete s.parent,r}function h(e){return n.find(e.edges(),function(t){return e.edge(t).cutvalue<0})}function g(e,t,r){var a=r.v,o=r.w;t.hasEdge(a,o)||(a=r.w,o=r.v);var s=e.node(a),c=e.node(o),l=s,u=!1;s.lim>c.lim&&(l=c,u=!0);var d=n.filter(t.edges(),function(t){return u===b(e,e.node(t.v),l)&&u!==b(e,e.node(t.w),l)});return n.minBy(d,function(e){return i(t,e)})}function _(e,t,n,r){var i=n.v,a=n.w;e.removeEdge(i,a),e.setEdge(r.v,r.w,{}),p(e),u(e,t),v(e,t)}function v(e,t){var r=o(e,n.find(e.nodes(),function(e){return!t.node(e).parent}));r=r.slice(1),n.forEach(r,function(n){var r=e.node(n).parent,i=t.edge(n,r),a=!1;i||(i=t.edge(r,n),a=!0),t.node(n).rank=t.node(r).rank+(a?i.minlen:-i.minlen)})}function y(e,t,n){return e.hasEdge(t,n)}function b(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}})),tL=r(((e,t)=>{var n=QI().longestPath,r=$I(),i=eL();t.exports=a;function a(e){switch(e.graph().ranker){case`network-simplex`:c(e);break;case`tight-tree`:s(e);break;case`longest-path`:o(e);break;default:c(e)}}var o=n;function s(e){n(e),r(e)}function c(e){i(e)}})),nL=r(((e,t)=>{var n=KI();t.exports=r;function r(e){var t=a(e);n.forEach(e.graph().dummyChains,function(n){for(var r=e.node(n),a=r.edgeObj,o=i(e,t,a.v,a.w),s=o.path,c=o.lca,l=0,u=s[l],d=!0;n!==a.w;){if(r=e.node(n),d){for(;(u=s[l])!==c&&e.node(u).maxRank<r.rank;)l++;u===c&&(d=!1)}if(!d){for(;l<s.length-1&&e.node(u=s[l+1]).minRank<=r.rank;)l++;u=s[l]}e.setParent(n,u),n=e.successors(n)[0]}})}function i(e,t,n,r){var i=[],a=[],o=Math.min(t[n].low,t[r].low),s=Math.max(t[n].lim,t[r].lim),c=n,l;do c=e.parent(c),i.push(c);while(c&&(t[c].low>o||s>t[c].lim));for(l=c,c=r;(c=e.parent(c))!==l;)a.push(c);return{path:i.concat(a.reverse()),lca:l}}function a(e){var t={},r=0;function i(a){var o=r;n.forEach(e.children(a),i),t[a]={low:o,lim:r++}}return n.forEach(e.children(),i),t}})),rL=r(((e,t)=>{var n=KI(),r=XI();t.exports={run:i,cleanup:c};function i(e){var t=r.addDummyNode(e,`root`,{},`_root`),i=o(e),c=n.max(n.values(i))-1,l=2*c+1;e.graph().nestingRoot=t,n.forEach(e.edges(),function(t){e.edge(t).minlen*=l});var u=s(e)+1;n.forEach(e.children(),function(n){a(e,t,l,u,c,i,n)}),e.graph().nodeRankFactor=l}function a(e,t,i,o,s,c,l){var u=e.children(l);if(!u.length){l!==t&&e.setEdge(t,l,{weight:0,minlen:i});return}var d=r.addBorderNode(e,`_bt`),f=r.addBorderNode(e,`_bb`),p=e.node(l);e.setParent(d,l),p.borderTop=d,e.setParent(f,l),p.borderBottom=f,n.forEach(u,function(n){a(e,t,i,o,s,c,n);var r=e.node(n),u=r.borderTop?r.borderTop:n,p=r.borderBottom?r.borderBottom:n,m=r.borderTop?o:2*o,h=u===p?s-c[l]+1:1;e.setEdge(d,u,{weight:m,minlen:h,nestingEdge:!0}),e.setEdge(p,f,{weight:m,minlen:h,nestingEdge:!0})}),e.parent(l)||e.setEdge(t,d,{weight:0,minlen:s+c[l]})}function o(e){var t={};function r(i,a){var o=e.children(i);o&&o.length&&n.forEach(o,function(e){r(e,a+1)}),t[i]=a}return n.forEach(e.children(),function(e){r(e,1)}),t}function s(e){return n.reduce(e.edges(),function(t,n){return t+e.edge(n).weight},0)}function c(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,n.forEach(e.edges(),function(t){e.edge(t).nestingEdge&&e.removeEdge(t)})}})),iL=r(((e,t)=>{var n=KI(),r=XI();t.exports=i;function i(e){function t(r){var i=e.children(r),o=e.node(r);if(i.length&&n.forEach(i,t),n.has(o,`minRank`)){o.borderLeft=[],o.borderRight=[];for(var s=o.minRank,c=o.maxRank+1;s<c;++s)a(e,`borderLeft`,`_bl`,r,o,s),a(e,`borderRight`,`_br`,r,o,s)}}n.forEach(e.children(),t)}function a(e,t,n,i,a,o){var s={width:0,height:0,rank:o,borderType:t},c=a[t][o-1],l=r.addDummyNode(e,`border`,s,n);a[t][o]=l,e.setParent(l,i),c&&e.setEdge(c,l,{weight:1})}})),aL=r(((e,t)=>{var n=KI();t.exports={adjust:r,undo:i};function r(e){var t=e.graph().rankdir.toLowerCase();(t===`lr`||t===`rl`)&&a(e)}function i(e){var t=e.graph().rankdir.toLowerCase();(t===`bt`||t===`rl`)&&s(e),(t===`lr`||t===`rl`)&&(l(e),a(e))}function a(e){n.forEach(e.nodes(),function(t){o(e.node(t))}),n.forEach(e.edges(),function(t){o(e.edge(t))})}function o(e){var t=e.width;e.width=e.height,e.height=t}function s(e){n.forEach(e.nodes(),function(t){c(e.node(t))}),n.forEach(e.edges(),function(t){var r=e.edge(t);n.forEach(r.points,c),n.has(r,`y`)&&c(r)})}function c(e){e.y=-e.y}function l(e){n.forEach(e.nodes(),function(t){u(e.node(t))}),n.forEach(e.edges(),function(t){var r=e.edge(t);n.forEach(r.points,u),n.has(r,`x`)&&u(r)})}function u(e){var t=e.x;e.x=e.y,e.y=t}})),oL=r(((e,t)=>{var n=KI();t.exports=r;function r(e){var t={},r=n.filter(e.nodes(),function(t){return!e.children(t).length}),i=n.max(n.map(r,function(t){return e.node(t).rank})),a=n.map(n.range(i+1),function(){return[]});function o(r){n.has(t,r)||(t[r]=!0,a[e.node(r).rank].push(r),n.forEach(e.successors(r),o))}var s=n.sortBy(r,function(t){return e.node(t).rank});return n.forEach(s,o),a}})),sL=r(((e,t)=>{var n=KI();t.exports=r;function r(e,t){for(var n=0,r=1;r<t.length;++r)n+=i(e,t[r-1],t[r]);return n}function i(e,t,r){for(var i=n.zipObject(r,n.map(r,function(e,t){return t})),a=n.flatten(n.map(t,function(t){return n.sortBy(n.map(e.outEdges(t),function(t){return{pos:i[t.w],weight:e.edge(t).weight}}),`pos`)}),!0),o=1;o<r.length;)o<<=1;var s=2*o-1;--o;var c=n.map(Array(s),function(){return 0}),l=0;return n.forEach(a.forEach(function(e){var t=e.pos+o;c[t]+=e.weight;for(var n=0;t>0;)t%2&&(n+=c[t+1]),t=t-1>>1,c[t]+=e.weight;l+=e.weight*n})),l}})),cL=r(((e,t)=>{var n=KI();t.exports=r;function r(e,t){return n.map(t,function(t){var r=e.inEdges(t);if(r.length){var i=n.reduce(r,function(t,n){var r=e.edge(n),i=e.node(n.v);return{sum:t.sum+r.weight*i.order,weight:t.weight+r.weight}},{sum:0,weight:0});return{v:t,barycenter:i.sum/i.weight,weight:i.weight}}return{v:t}})}})),lL=r(((e,t)=>{var n=KI();t.exports=r;function r(e,t){var r={};return n.forEach(e,function(e,t){var i=r[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};n.isUndefined(e.barycenter)||(i.barycenter=e.barycenter,i.weight=e.weight)}),n.forEach(t.edges(),function(e){var t=r[e.v],i=r[e.w];!n.isUndefined(t)&&!n.isUndefined(i)&&(i.indegree++,t.out.push(r[e.w]))}),i(n.filter(r,function(e){return!e.indegree}))}function i(e){var t=[];function r(e){return function(t){t.merged||(n.isUndefined(t.barycenter)||n.isUndefined(e.barycenter)||t.barycenter>=e.barycenter)&&a(e,t)}}function i(t){return function(n){n.in.push(t),--n.indegree===0&&e.push(n)}}for(;e.length;){var o=e.pop();t.push(o),n.forEach(o.in.reverse(),r(o)),n.forEach(o.out,i(o))}return n.map(n.filter(t,function(e){return!e.merged}),function(e){return n.pick(e,[`vs`,`i`,`barycenter`,`weight`])})}function a(e,t){var n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}})),uL=r(((e,t)=>{var n=KI(),r=XI();t.exports=i;function i(e,t){var i=r.partition(e,function(e){return n.has(e,`barycenter`)}),s=i.lhs,c=n.sortBy(i.rhs,function(e){return-e.i}),l=[],u=0,d=0,f=0;s.sort(o(!!t)),f=a(l,c,f),n.forEach(s,function(e){f+=e.vs.length,l.push(e.vs),u+=e.barycenter*e.weight,d+=e.weight,f=a(l,c,f)});var p={vs:n.flatten(l,!0)};return d&&(p.barycenter=u/d,p.weight=d),p}function a(e,t,r){for(var i;t.length&&(i=n.last(t)).i<=r;)t.pop(),e.push(i.vs),r++;return r}function o(e){return function(t,n){return t.barycenter<n.barycenter?-1:t.barycenter>n.barycenter?1:e?n.i-t.i:t.i-n.i}}})),dL=r(((e,t)=>{var n=KI(),r=cL(),i=lL(),a=uL();t.exports=o;function o(e,t,l,u){var d=e.children(t),f=e.node(t),p=f?f.borderLeft:void 0,m=f?f.borderRight:void 0,h={};p&&(d=n.filter(d,function(e){return e!==p&&e!==m}));var g=r(e,d);n.forEach(g,function(t){if(e.children(t.v).length){var r=o(e,t.v,l,u);h[t.v]=r,n.has(r,`barycenter`)&&c(t,r)}});var _=i(g,l);s(_,h);var v=a(_,u);if(p&&(v.vs=n.flatten([p,v.vs,m],!0),e.predecessors(p).length)){var y=e.node(e.predecessors(p)[0]),b=e.node(e.predecessors(m)[0]);n.has(v,`barycenter`)||(v.barycenter=0,v.weight=0),v.barycenter=(v.barycenter*v.weight+y.order+b.order)/(v.weight+2),v.weight+=2}return v}function s(e,t){n.forEach(e,function(e){e.vs=n.flatten(e.vs.map(function(e){return t[e]?t[e].vs:e}),!0)})}function c(e,t){n.isUndefined(e.barycenter)?(e.barycenter=t.barycenter,e.weight=t.weight):(e.barycenter=(e.barycenter*e.weight+t.barycenter*t.weight)/(e.weight+t.weight),e.weight+=t.weight)}})),fL=r(((e,t)=>{var n=KI(),r=$F().Graph;t.exports=i;function i(e,t,i){var o=a(e),s=new r({compound:!0}).setGraph({root:o}).setDefaultNodeLabel(function(t){return e.node(t)});return n.forEach(e.nodes(),function(r){var a=e.node(r),c=e.parent(r);(a.rank===t||a.minRank<=t&&t<=a.maxRank)&&(s.setNode(r),s.setParent(r,c||o),n.forEach(e[i](r),function(t){var i=t.v===r?t.w:t.v,a=s.edge(i,r),o=n.isUndefined(a)?0:a.weight;s.setEdge(i,r,{weight:e.edge(t).weight+o})}),n.has(a,`minRank`)&&s.setNode(r,{borderLeft:a.borderLeft[t],borderRight:a.borderRight[t]}))}),s}function a(e){for(var t;e.hasNode(t=n.uniqueId(`_root`)););return t}})),pL=r(((e,t)=>{var n=KI();t.exports=r;function r(e,t,r){var i={},a;n.forEach(r,function(n){for(var r=e.parent(n),o,s;r;){if(o=e.parent(r),o?(s=i[o],i[o]=r):(s=a,a=r),s&&s!==r){t.setEdge(s,r);return}r=o}})}})),mL=r(((e,t)=>{var n=KI(),r=oL(),i=sL(),a=dL(),o=fL(),s=pL(),c=$F().Graph,l=XI();t.exports=u;function u(e){var t=l.maxRank(e),a=d(e,n.range(1,t+1),`inEdges`),o=d(e,n.range(t-1,-1,-1),`outEdges`),s=r(e);p(e,s);for(var c=1/0,u,m=0,h=0;h<4;++m,++h){f(m%2?a:o,m%4>=2),s=l.buildLayerMatrix(e);var g=i(e,s);g<c&&(h=0,u=n.cloneDeep(s),c=g)}p(e,u)}function d(e,t,r){return n.map(t,function(t){return o(e,t,r)})}function f(e,t){var r=new c;n.forEach(e,function(e){var i=e.graph().root,o=a(e,i,r,t);n.forEach(o.vs,function(t,n){e.node(t).order=n}),s(e,r,o.vs)})}function p(e,t){n.forEach(t,function(t){n.forEach(t,function(t,n){e.node(t).order=n})})}})),hL=r(((e,t)=>{var n=KI(),r=$F().Graph,i=XI();t.exports={positionX:g,findType1Conflicts:a,findType2Conflicts:o,addConflict:c,hasConflict:l,verticalAlignment:u,horizontalCompaction:d,alignCoordinates:m,findSmallestWidthAlignment:p,balance:h};function a(e,t){var r={};function i(t,i){var a=0,o=0,l=t.length,u=n.last(i);return n.forEach(i,function(t,d){var f=s(e,t),p=f?e.node(f).order:l;(f||t===u)&&(n.forEach(i.slice(o,d+1),function(t){n.forEach(e.predecessors(t),function(n){var i=e.node(n),o=i.order;(o<a||p<o)&&!(i.dummy&&e.node(t).dummy)&&c(r,n,t)})}),o=d+1,a=p)}),i}return n.reduce(t,i),r}function o(e,t){var r={};function i(t,i,a,o,s){var l;n.forEach(n.range(i,a),function(i){l=t[i],e.node(l).dummy&&n.forEach(e.predecessors(l),function(t){var n=e.node(t);n.dummy&&(n.order<o||n.order>s)&&c(r,t,l)})})}function a(t,r){var a=-1,o,s=0;return n.forEach(r,function(n,c){if(e.node(n).dummy===`border`){var l=e.predecessors(n);l.length&&(o=e.node(l[0]).order,i(r,s,c,a,o),s=c,a=o)}i(r,s,r.length,o,t.length)}),r}return n.reduce(t,a),r}function s(e,t){if(e.node(t).dummy)return n.find(e.predecessors(t),function(t){return e.node(t).dummy})}function c(e,t,n){if(t>n){var r=t;t=n,n=r}var i=e[t];i||(e[t]=i={}),i[n]=!0}function l(e,t,r){if(t>r){var i=t;t=r,r=i}return n.has(e[t],r)}function u(e,t,r,i){var a={},o={},s={};return n.forEach(t,function(e){n.forEach(e,function(e,t){a[e]=e,o[e]=e,s[e]=t})}),n.forEach(t,function(e){var t=-1;n.forEach(e,function(e){var c=i(e);if(c.length){c=n.sortBy(c,function(e){return s[e]});for(var u=(c.length-1)/2,d=Math.floor(u),f=Math.ceil(u);d<=f;++d){var p=c[d];o[e]===e&&t<s[p]&&!l(r,e,p)&&(o[p]=e,o[e]=a[e]=a[p],t=s[p])}}})}),{root:a,align:o}}function d(e,t,r,i,a){var o={},s=f(e,t,r,a),c=a?`borderLeft`:`borderRight`;function l(e,t){for(var n=s.nodes(),r=n.pop(),i={};r;)i[r]?e(r):(i[r]=!0,n.push(r),n=n.concat(t(r))),r=n.pop()}function u(e){o[e]=s.inEdges(e).reduce(function(e,t){return Math.max(e,o[t.v]+s.edge(t))},0)}function d(t){var n=s.outEdges(t).reduce(function(e,t){return Math.min(e,o[t.w]-s.edge(t))},1/0),r=e.node(t);n!==1/0&&r.borderType!==c&&(o[t]=Math.max(o[t],n))}return l(u,s.predecessors.bind(s)),l(d,s.successors.bind(s)),n.forEach(i,function(e){o[e]=o[r[e]]}),o}function f(e,t,i,a){var o=new r,s=e.graph(),c=_(s.nodesep,s.edgesep,a);return n.forEach(t,function(t){var r;n.forEach(t,function(t){var n=i[t];if(o.setNode(n),r){var a=i[r],s=o.edge(a,n);o.setEdge(a,n,Math.max(c(e,t,r),s||0))}r=t})}),o}function p(e,t){return n.minBy(n.values(t),function(t){var r=-1/0,i=1/0;return n.forIn(t,function(t,n){var a=v(e,n)/2;r=Math.max(t+a,r),i=Math.min(t-a,i)}),r-i})}function m(e,t){var r=n.values(t),i=n.min(r),a=n.max(r);n.forEach([`u`,`d`],function(r){n.forEach([`l`,`r`],function(o){var s=r+o,c=e[s],l;if(c!==t){var u=n.values(c);l=o===`l`?i-n.min(u):a-n.max(u),l&&(e[s]=n.mapValues(c,function(e){return e+l}))}})})}function h(e,t){return n.mapValues(e.ul,function(r,i){if(t)return e[t.toLowerCase()][i];var a=n.sortBy(n.map(e,i));return(a[1]+a[2])/2})}function g(e){var t=i.buildLayerMatrix(e),r=n.merge(a(e,t),o(e,t)),s={},c;return n.forEach([`u`,`d`],function(i){c=i===`u`?t:n.values(t).reverse(),n.forEach([`l`,`r`],function(t){t===`r`&&(c=n.map(c,function(e){return n.values(e).reverse()}));var a=(i===`u`?e.predecessors:e.successors).bind(e),o=u(e,c,r,a),l=d(e,c,o.root,o.align,t===`r`);t===`r`&&(l=n.mapValues(l,function(e){return-e})),s[i+t]=l})}),m(s,p(e,s)),h(s,e.graph().align)}function _(e,t,r){return function(i,a,o){var s=i.node(a),c=i.node(o),l=0,u;if(l+=s.width/2,n.has(s,`labelpos`))switch(s.labelpos.toLowerCase()){case`l`:u=-s.width/2;break;case`r`:u=s.width/2}if(u&&(l+=r?u:-u),u=0,l+=(s.dummy?t:e)/2,l+=(c.dummy?t:e)/2,l+=c.width/2,n.has(c,`labelpos`))switch(c.labelpos.toLowerCase()){case`l`:u=c.width/2;break;case`r`:u=-c.width/2}return u&&(l+=r?u:-u),u=0,l}}function v(e,t){return e.node(t).width}})),gL=r(((e,t)=>{var n=KI(),r=XI(),i=hL().positionX;t.exports=a;function a(e){e=r.asNonCompoundGraph(e),o(e),n.forEach(i(e),function(t,n){e.node(n).x=t})}function o(e){var t=r.buildLayerMatrix(e),i=e.graph().ranksep,a=0;n.forEach(t,function(t){var r=n.max(n.map(t,function(t){return e.node(t).height}));n.forEach(t,function(t){e.node(t).y=a+r/2}),a+=r+i})}})),_L=r(((e,t)=>{var n=KI(),r=YI(),i=ZI(),a=tL(),o=XI().normalizeRanks,s=nL(),c=XI().removeEmptyRanks,l=rL(),u=iL(),d=aL(),f=mL(),p=gL(),m=XI(),h=$F().Graph;t.exports=g;function g(e,t){var n=t&&t.debugTiming?m.time:m.notime;n(`layout`,function(){var t=n(` buildLayoutGraph`,function(){return D(e)});n(` runLayout`,function(){_(t,n)}),n(` updateInputGraph`,function(){v(e,t)})})}function _(e,t){t(` makeSpaceForEdgeLabels`,function(){O(e)}),t(` removeSelfEdges`,function(){se(e)}),t(` acyclic`,function(){r.run(e)}),t(` nestingGraph.run`,function(){l.run(e)}),t(` rank`,function(){a(m.asNonCompoundGraph(e))}),t(` injectEdgeLabelProxies`,function(){k(e)}),t(` removeEmptyRanks`,function(){c(e)}),t(` nestingGraph.cleanup`,function(){l.cleanup(e)}),t(` normalizeRanks`,function(){o(e)}),t(` assignRankMinMax`,function(){ee(e)}),t(` removeEdgeLabelProxies`,function(){te(e)}),t(` normalize.run`,function(){i.run(e)}),t(` parentDummyChains`,function(){s(e)}),t(` addBorderSegments`,function(){u(e)}),t(` order`,function(){f(e)}),t(` insertSelfEdges`,function(){ce(e)}),t(` adjustCoordinateSystem`,function(){d.adjust(e)}),t(` position`,function(){p(e)}),t(` positionSelfEdges`,function(){le(e)}),t(` removeBorderNodes`,function(){oe(e)}),t(` normalize.undo`,function(){i.undo(e)}),t(` fixupEdgeLabelCoords`,function(){ie(e)}),t(` undoCoordinateSystem`,function(){d.undo(e)}),t(` translateGraph`,function(){ne(e)}),t(` assignNodeIntersects`,function(){re(e)}),t(` reversePoints`,function(){ae(e)}),t(` acyclic.undo`,function(){r.undo(e)})}function v(e,t){n.forEach(e.nodes(),function(n){var r=e.node(n),i=t.node(n);r&&(r.x=i.x,r.y=i.y,t.children(n).length&&(r.width=i.width,r.height=i.height))}),n.forEach(e.edges(),function(r){var i=e.edge(r),a=t.edge(r);i.points=a.points,n.has(a,`x`)&&(i.x=a.x,i.y=a.y)}),e.graph().width=t.graph().width,e.graph().height=t.graph().height}var y=[`nodesep`,`edgesep`,`ranksep`,`marginx`,`marginy`],b={ranksep:50,edgesep:20,nodesep:50,rankdir:`tb`},x=[`acyclicer`,`ranker`,`rankdir`,`align`],S=[`width`,`height`],C={width:0,height:0},w=[`minlen`,`weight`,`width`,`height`,`labeloffset`],T={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:`r`},E=[`labelpos`];function D(e){var t=new h({multigraph:!0,compound:!0}),r=ue(e.graph());return t.setGraph(n.merge({},b,A(r,y),n.pick(r,x))),n.forEach(e.nodes(),function(r){var i=ue(e.node(r));t.setNode(r,n.defaults(A(i,S),C)),t.setParent(r,e.parent(r))}),n.forEach(e.edges(),function(r){var i=ue(e.edge(r));t.setEdge(r,n.merge({},T,A(i,w),n.pick(i,E)))}),t}function O(e){var t=e.graph();t.ranksep/=2,n.forEach(e.edges(),function(n){var r=e.edge(n);r.minlen*=2,r.labelpos.toLowerCase()!==`c`&&(t.rankdir===`TB`||t.rankdir===`BT`?r.width+=r.labeloffset:r.height+=r.labeloffset)})}function k(e){n.forEach(e.edges(),function(t){var n=e.edge(t);if(n.width&&n.height){var r=e.node(t.v),i={rank:(e.node(t.w).rank-r.rank)/2+r.rank,e:t};m.addDummyNode(e,`edge-proxy`,i,`_ep`)}})}function ee(e){var t=0;n.forEach(e.nodes(),function(r){var i=e.node(r);i.borderTop&&(i.minRank=e.node(i.borderTop).rank,i.maxRank=e.node(i.borderBottom).rank,t=n.max(t,i.maxRank))}),e.graph().maxRank=t}function te(e){n.forEach(e.nodes(),function(t){var n=e.node(t);n.dummy===`edge-proxy`&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))})}function ne(e){var t=1/0,r=0,i=1/0,a=0,o=e.graph(),s=o.marginx||0,c=o.marginy||0;function l(e){var n=e.x,o=e.y,s=e.width,c=e.height;t=Math.min(t,n-s/2),r=Math.max(r,n+s/2),i=Math.min(i,o-c/2),a=Math.max(a,o+c/2)}n.forEach(e.nodes(),function(t){l(e.node(t))}),n.forEach(e.edges(),function(t){var r=e.edge(t);n.has(r,`x`)&&l(r)}),t-=s,i-=c,n.forEach(e.nodes(),function(n){var r=e.node(n);r.x-=t,r.y-=i}),n.forEach(e.edges(),function(r){var a=e.edge(r);n.forEach(a.points,function(e){e.x-=t,e.y-=i}),n.has(a,`x`)&&(a.x-=t),n.has(a,`y`)&&(a.y-=i)}),o.width=r-t+s,o.height=a-i+c}function re(e){n.forEach(e.edges(),function(t){var n=e.edge(t),r=e.node(t.v),i=e.node(t.w),a,o;n.points?(a=n.points[0],o=n.points[n.points.length-1]):(n.points=[],a=i,o=r),n.points.unshift(m.intersectRect(r,a)),n.points.push(m.intersectRect(i,o))})}function ie(e){n.forEach(e.edges(),function(t){var r=e.edge(t);if(n.has(r,`x`))switch((r.labelpos===`l`||r.labelpos===`r`)&&(r.width-=r.labeloffset),r.labelpos){case`l`:r.x-=r.width/2+r.labeloffset;break;case`r`:r.x+=r.width/2+r.labeloffset}})}function ae(e){n.forEach(e.edges(),function(t){var n=e.edge(t);n.reversed&&n.points.reverse()})}function oe(e){n.forEach(e.nodes(),function(t){if(e.children(t).length){var r=e.node(t),i=e.node(r.borderTop),a=e.node(r.borderBottom),o=e.node(n.last(r.borderLeft)),s=e.node(n.last(r.borderRight));r.width=Math.abs(s.x-o.x),r.height=Math.abs(a.y-i.y),r.x=o.x+r.width/2,r.y=i.y+r.height/2}}),n.forEach(e.nodes(),function(t){e.node(t).dummy===`border`&&e.removeNode(t)})}function se(e){n.forEach(e.edges(),function(t){if(t.v===t.w){var n=e.node(t.v);n.selfEdges||=[],n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}})}function ce(e){var t=m.buildLayerMatrix(e);n.forEach(t,function(t){var r=0;n.forEach(t,function(t,i){var a=e.node(t);a.order=i+r,n.forEach(a.selfEdges,function(t){m.addDummyNode(e,`selfedge`,{width:t.label.width,height:t.label.height,rank:a.rank,order:i+ ++r,e:t.e,label:t.label},`_se`)}),delete a.selfEdges})})}function le(e){n.forEach(e.nodes(),function(t){var n=e.node(t);if(n.dummy===`selfedge`){var r=e.node(n.e.v),i=r.x+r.width/2,a=r.y,o=n.x-i,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:i+2*o/3,y:a-s},{x:i+5*o/6,y:a-s},{x:i+o,y:a},{x:i+5*o/6,y:a+s},{x:i+2*o/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}})}function A(e,t){return n.mapValues(n.pick(e,t),Number)}function ue(e){var t={};return n.forEach(e,function(e,n){t[n.toLowerCase()]=e}),t}})),vL=r(((e,t)=>{var n=KI(),r=XI(),i=$F().Graph;t.exports={debugOrdering:a};function a(e){var t=r.buildLayerMatrix(e),a=new i({compound:!0,multigraph:!0}).setGraph({});return n.forEach(e.nodes(),function(t){a.setNode(t,{label:t}),a.setParent(t,`layer`+e.node(t).rank)}),n.forEach(e.edges(),function(e){a.setEdge(e.v,e.w,{},e.name)}),n.forEach(t,function(e,t){var r=`layer`+t;a.setNode(r,{rank:`same`}),n.reduce(e,function(e,t){return a.setEdge(e,t,{style:`invis`}),t})}),a}})),yL=r(((e,t)=>{t.exports=`0.8.5`})),bL=r(((e,t)=>{t.exports={graphlib:$F(),layout:_L(),debug:vL(),util:{time:XI().time,notime:XI().notime},version:yL()}}));export{ub as $,F as $n,xu as $t,vx as A,nf as An,ce as Ar,ev as At,gx as B,cd as Bn,Mh as Bt,SC as C,Wd as Cn,or as Cr,iv as Ct,ox as D,qd as Dn,et as Dr,K_ as Dt,cx as E,Md as En,it as Er,rv as Et,Vb as F,Sf as Fn,Z_ as Ft,hb as G,ud as Gn,fh as Gt,Ob as H,jf as Hn,jh as Ht,fx as I,bf as In,tv as It,eb as J,I as Jn,Vm as Jt,pb as K,yu as Kn,sh as Kt,mx as L,fd as Ln,W_ as Lt,$b as M,ed as Mn,C as Mr,Y_ as Mt,yx as N,Rd as Nn,S as Nr,$_ as Nt,sx as O,Pf as On,Ke as Or,q_ as Ot,Zb as P,ld as Pn,X_ as Pt,Xy as Q,Bc as Qn,hd as Qt,tx as R,Of as Rn,Rh as Rt,W as S,ku as Sn,sr as Sr,av as St,$S as T,$d as Tn,rr as Tr,nv as Tt,Tb as U,pf as Un,Eh as Ut,ix as V,cf as Vn,kh as Vt,_b as W,Gu as Wn,Um as Wt,qy as X,Gc as Xn,U as Xt,$y as Y,Kc as Yn,Hm as Yt,nb as Z,Hc as Zn,Ed as Zt,DD as _,Ff as _n,Yr as _r,Ly as _t,YO as a,uf as an,bc as ar,Ky as at,q as b,Sd as bn,fr as br,_v as bt,DO as c,Xu as cn,ws as cr,Qy as ct,XD as d,nd as dn,Yo as dr,ab as dt,ef as en,P as er,db as et,FD as f,Cd as fn,Ro as fr,ob as ft,ND as g,H as gn,Oa as gr,zy as gt,AD as h,pd as hn,ja as hr,Uy as ht,XO as i,sf as in,Tc as ir,Zy as it,_x as j,gd as jn,ne as jr,J_ as jt,hx as k,kd as kn,de as kr,Q_ as kt,_O as l,Od as ln,ys as lr,Gy as lt,QD as m,xf as mn,ho as mr,ib as mt,Pj as n,mf as nn,Dc as nr,lb as nt,ZO as o,td as on,ec as or,tb as ot,pO as p,Cf as pn,Mo as pr,rb as pt,Jy as q,L as qn,uh as qt,cj as r,rf as rn,N as rr,sb as rt,QO as s,kf as sn,Ds as sr,Wy as st,bL as t,yf as tn,kc as tr,cb as tt,sO as u,Dd as un,is as ur,Yy as ut,J as v,jd as vn,xr as vr,Py as vt,DC as w,xd as wn,ar as wr,G_ as wt,MC as x,dd as xn,dr as xr,uv as xt,ED as y,Tf as yn,pr as yr,jy as yt,zb as z,wf as zn,Nh as zt};
|