@tyanxie/paimon-darwin-arm64 1.7.0 → 2.0.0

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.
Files changed (79) hide show
  1. package/bin/paimon +1 -1
  2. package/package.json +1 -1
  3. package/web/assets/abnfDiagram-VCTEODGH-C_ttoOR-.js +1 -0
  4. package/web/assets/arc-yAsaH0Dw.js +1 -0
  5. package/web/assets/architectureDiagram-5GKGNRK7-CaDJakVP.js +36 -0
  6. package/web/assets/blockDiagram-I7D4REHJ-BQd0dwKa.js +129 -0
  7. package/web/assets/c4Diagram-7LVT6UL2-nZGUi3mU.js +38 -0
  8. package/web/assets/channel-DF8NlRb_.js +1 -0
  9. package/web/assets/chunk-2Q5K7J3B-NPXGjG3f.js +1 -0
  10. package/web/assets/chunk-5VM5RSS4-CJY7RIjt.js +15 -0
  11. package/web/assets/chunk-F27PBJKO-DT1ynzIY.js +1 -0
  12. package/web/assets/chunk-IMKFNOWR-CH6O0dOI.js +231 -0
  13. package/web/assets/chunk-JWPE2WC7-HT0bbIVb.js +1 -0
  14. package/web/assets/chunk-POPQ4Y6H-JAIuAfSC.js +1 -0
  15. package/web/assets/chunk-SVP7TREG-6IvqfLNl.js +88 -0
  16. package/web/assets/chunk-TICWLB2K-Un-BtVJH.js +206 -0
  17. package/web/assets/chunk-XXDRQBXY-MmAyjRcU.js +1 -0
  18. package/web/assets/classDiagram-ZZMXUADV-BJm7NJbs.js +1 -0
  19. package/web/assets/classDiagram-v2-VYDZK3BY-BJm7NJbs.js +1 -0
  20. package/web/assets/cose-bilkent-JH36ORCC-BKY655a1.js +1 -0
  21. package/web/assets/cynefin-OW5HDTMX-Oul7bDb8.js +178 -0
  22. package/web/assets/cynefinDiagram-5FMLGOSQ-C2liQpUc.js +62 -0
  23. package/web/assets/cytoscape.esm-BLAcgzS2.js +331 -0
  24. package/web/assets/dagre-GXQ25YYZ-DYrwe_pj.js +4 -0
  25. package/web/assets/defaultLocale-CrowFXzY.js +1 -0
  26. package/web/assets/diagram-S7CK7UJ4-BiMW816X.js +30 -0
  27. package/web/assets/diagram-UQ7AKVKN-Dx--Yu_z.js +41 -0
  28. package/web/assets/diagram-VSXAHHWV-DRrurU6X.js +3 -0
  29. package/web/assets/diagram-VX7I27RA-00uuQ0k2.js +24 -0
  30. package/web/assets/diagram-Z3DM3KII-Cvgf5Y5I.js +24 -0
  31. package/web/assets/ebnfDiagram-PWID7BFC-CHZyB5eb.js +1 -0
  32. package/web/assets/erDiagram-RLTQ6QDP-BfpNZTDy.js +99 -0
  33. package/web/assets/flowDiagram-HODETNUW-BNTRT4LN.js +168 -0
  34. package/web/assets/framework-gzBbjyR4.js +49 -0
  35. package/web/assets/ganttDiagram-EL5Y4UJY-B8LaEeAd.js +292 -0
  36. package/web/assets/gitGraphDiagram-WWUBYQGX-BPhOAW6u.js +106 -0
  37. package/web/assets/index-BLBkIpT7.css +1 -0
  38. package/web/assets/index-DsjiosHk.js +78 -0
  39. package/web/assets/index-xz7ziSVU.js +264 -0
  40. package/web/assets/infoDiagram-27XIBGKW-U6LgO_ju.js +2 -0
  41. package/web/assets/init-Gi6I4Gst.js +1 -0
  42. package/web/assets/isObjectLike-DlmVz5ty.js +1 -0
  43. package/web/assets/ishikawaDiagram-5VMMS53U-DxXeMYDc.js +70 -0
  44. package/web/assets/journeyDiagram-3NMN7TZE-Bx7POPvm.js +139 -0
  45. package/web/assets/kanban-definition-UXKFOSKX-CpYDSQwK.js +89 -0
  46. package/web/assets/katex-C5jXJg4s.js +257 -0
  47. package/web/assets/layout-Bt4nl8Oy.js +1 -0
  48. package/web/assets/linear-IZfkTFEW.js +1 -0
  49. package/web/assets/markdown-OowzRXxA.js +69 -0
  50. package/web/assets/mermaid.core-DVbCkJL3.js +310 -0
  51. package/web/assets/mermaidTheme-DoQvsUbV.js +24 -0
  52. package/web/assets/mindmap-definition-YA3MSWOX-CcsjXg_l.js +96 -0
  53. package/web/assets/mix-CrMk8dT1.js +1 -0
  54. package/web/assets/modalFeatures-BeDlpc4S.js +1 -0
  55. package/web/assets/modelConfig-BWIG2U9q.js +374 -0
  56. package/web/assets/ordinal-Cboi1Yqb.js +1 -0
  57. package/web/assets/pegDiagram-XKGWAZYB-D8bhpeEX.js +1 -0
  58. package/web/assets/pieDiagram-E7YTZNPT-DpqpRrk3.js +39 -0
  59. package/web/assets/purify.es-CAi2OJFm.js +3 -0
  60. package/web/assets/quadrantDiagram-AXDQQJYC-D3jcnC7Q.js +7 -0
  61. package/web/assets/railroadDiagram-O6MQD6OU-KAu7lO3i.js +1 -0
  62. package/web/assets/requirementDiagram-BXWQKSXE-BjvIFtJN.js +84 -0
  63. package/web/assets/sankeyDiagram-P5KCCOFB-BAeQKqir.js +40 -0
  64. package/web/assets/sequenceDiagram-WJ2MYXX4-COPuE32n.js +162 -0
  65. package/web/assets/sizeCapture-INFHLROL-DOSmwQs7.js +1 -0
  66. package/web/assets/stateDiagram-D77RDMKH-DkQ3KhXj.js +1 -0
  67. package/web/assets/stateDiagram-v2-MP3YSRHH-C2O-IoZS.js +1 -0
  68. package/web/assets/swimlanes-42K2YHIH-Belip6eP.js +1 -0
  69. package/web/assets/swimlanesDiagram-VR7AAH4N-CzGu2D2p.js +8 -0
  70. package/web/assets/timeline-definition-24CTP7MA-Bntb2OTs.js +120 -0
  71. package/web/assets/vennDiagram-4TSXK5OY-Cw2eTnvz.js +34 -0
  72. package/web/assets/wardleyDiagram-VM6X3IG4-DzJNpWOP.js +78 -0
  73. package/web/assets/xychartDiagram-S5SC5T6Z-CmlwEiU8.js +7 -0
  74. package/web/index.html +4 -5
  75. package/web/assets/framework-CY9iUjoF.js +0 -49
  76. package/web/assets/index-BTA-j8zf.js +0 -6
  77. package/web/assets/index-CTEVuRr7.css +0 -1
  78. package/web/assets/markdown-CbB-lJ6c.js +0 -69
  79. package/web/assets/vendor-BXh3TPFq.js +0 -200
@@ -0,0 +1,310 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./sizeCapture-INFHLROL-DOSmwQs7.js","./framework-gzBbjyR4.js","./purify.es-CAi2OJFm.js","./mix-CrMk8dT1.js","./isObjectLike-DlmVz5ty.js","./dagre-GXQ25YYZ-DYrwe_pj.js","./layout-Bt4nl8Oy.js","./swimlanes-42K2YHIH-Belip6eP.js","./cose-bilkent-JH36ORCC-BKY655a1.js","./cytoscape.esm-BLAcgzS2.js","./c4Diagram-7LVT6UL2-nZGUi3mU.js","./chunk-F27PBJKO-DT1ynzIY.js","./flowDiagram-HODETNUW-BNTRT4LN.js","./chunk-5VM5RSS4-CJY7RIjt.js","./chunk-XXDRQBXY-MmAyjRcU.js","./chunk-POPQ4Y6H-JAIuAfSC.js","./channel-DF8NlRb_.js","./swimlanesDiagram-VR7AAH4N-CzGu2D2p.js","./erDiagram-RLTQ6QDP-BfpNZTDy.js","./gitGraphDiagram-WWUBYQGX-BPhOAW6u.js","./chunk-2Q5K7J3B-NPXGjG3f.js","./chunk-JWPE2WC7-HT0bbIVb.js","./cynefin-OW5HDTMX-Oul7bDb8.js","./ganttDiagram-EL5Y4UJY-B8LaEeAd.js","./linear-IZfkTFEW.js","./init-Gi6I4Gst.js","./defaultLocale-CrowFXzY.js","./infoDiagram-27XIBGKW-U6LgO_ju.js","./pieDiagram-E7YTZNPT-DpqpRrk3.js","./arc-yAsaH0Dw.js","./ordinal-Cboi1Yqb.js","./quadrantDiagram-AXDQQJYC-D3jcnC7Q.js","./xychartDiagram-S5SC5T6Z-CmlwEiU8.js","./requirementDiagram-BXWQKSXE-BjvIFtJN.js","./sequenceDiagram-WJ2MYXX4-COPuE32n.js","./classDiagram-ZZMXUADV-BJm7NJbs.js","./chunk-TICWLB2K-Un-BtVJH.js","./classDiagram-v2-VYDZK3BY-BJm7NJbs.js","./stateDiagram-D77RDMKH-DkQ3KhXj.js","./chunk-IMKFNOWR-CH6O0dOI.js","./stateDiagram-v2-MP3YSRHH-C2O-IoZS.js","./journeyDiagram-3NMN7TZE-Bx7POPvm.js","./timeline-definition-24CTP7MA-Bntb2OTs.js","./mindmap-definition-YA3MSWOX-CcsjXg_l.js","./kanban-definition-UXKFOSKX-CpYDSQwK.js","./sankeyDiagram-P5KCCOFB-BAeQKqir.js","./diagram-Z3DM3KII-Cvgf5Y5I.js","./diagram-UQ7AKVKN-Dx--Yu_z.js","./blockDiagram-I7D4REHJ-BQd0dwKa.js","./diagram-S7CK7UJ4-BiMW816X.js","./architectureDiagram-5GKGNRK7-CaDJakVP.js","./diagram-VSXAHHWV-DRrurU6X.js","./ishikawaDiagram-5VMMS53U-DxXeMYDc.js","./vennDiagram-4TSXK5OY-Cw2eTnvz.js","./diagram-VX7I27RA-00uuQ0k2.js","./wardleyDiagram-VM6X3IG4-DzJNpWOP.js","./cynefinDiagram-5FMLGOSQ-C2liQpUc.js","./railroadDiagram-O6MQD6OU-KAu7lO3i.js","./chunk-SVP7TREG-6IvqfLNl.js","./ebnfDiagram-PWID7BFC-CHZyB5eb.js","./abnfDiagram-VCTEODGH-C_ttoOR-.js","./pegDiagram-XKGWAZYB-D8bhpeEX.js"])))=>i.map(i=>d[i]);
2
+ var om=Object.defineProperty;var nm=(e,t,r)=>t in e?om(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var qt=(e,t,r)=>nm(e,typeof t!="symbol"?t+"":t,r);import{g as yn,_ as Ft}from"./framework-gzBbjyR4.js";import ri from"./purify.es-CAi2OJFm.js";import{C as ji,U as Fi,c as lm,m as hm,r as ur}from"./mix-CrMk8dT1.js";import{g as mn,i as vo}from"./isObjectLike-DlmVz5ty.js";const jl=typeof globalThis=="object"&&globalThis||typeof window=="object"&&window||typeof self=="object"&&self||typeof global=="object"&&global||(function(){return this})();function cm(){}function xn(e){return e==null||typeof e!="object"&&typeof e!="function"}function Cn(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function um(e){if(xn(e))return e;if(Array.isArray(e)||Cn(e)||e instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&e instanceof SharedArrayBuffer)return e.slice(0);const t=Object.getPrototypeOf(e);if(t==null)return Object.assign(Object.create(t),e);const r=t.constructor;if(e instanceof Date||e instanceof Map||e instanceof Set)return new r(e);if(e instanceof RegExp){const i=new r(e);return i.lastIndex=e.lastIndex,i}if(e instanceof DataView)return new r(e.buffer.slice(0));if(e instanceof Error){let i;return e instanceof AggregateError?i=new r(e.errors,e.message,{cause:e.cause}):i=new r(e.message,{cause:e.cause}),i.stack=e.stack,Object.assign(i,e),i}return typeof File<"u"&&e instanceof File?new r([e],e.name,{type:e.type,lastModified:e.lastModified}):typeof e=="object"?Object.assign(Object.create(t),e):e}function bn(e){return typeof jl.Buffer<"u"&&jl.Buffer.isBuffer(e)}function bu(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}const dm="[object RegExp]",ku="[object String]",wu="[object Number]",Su="[object Boolean]",Tu="[object Arguments]",fm="[object Symbol]",pm="[object Date]",gm="[object Map]",ym="[object Set]",mm="[object Array]",xm="[object ArrayBuffer]",Cm="[object Object]",bm="[object DataView]",km="[object Uint8Array]",wm="[object Uint8ClampedArray]",Sm="[object Uint16Array]",Tm="[object Uint32Array]",_m="[object Int8Array]",Bm="[object Int16Array]",vm="[object Int32Array]",Lm="[object Float32Array]",Fm="[object Float64Array]";function Mm(e,t){return Ir(e,void 0,e,new Map,t)}function Ir(e,t,r,i=new Map,s=void 0){const a=s==null?void 0:s(e,t,r,i);if(a!==void 0)return a;if(xn(e))return e;if(i.has(e))return i.get(e);if(Array.isArray(e)){const o=new Array(e.length);i.set(e,o);for(let n=0;n<e.length;n++)o[n]=Ir(e[n],n,r,i,s);return Object.hasOwn(e,"index")&&(o.index=e.index),Object.hasOwn(e,"input")&&(o.input=e.input),o}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){const o=new RegExp(e.source,e.flags);return o.lastIndex=e.lastIndex,o}if(e instanceof Map){const o=new Map;i.set(e,o);for(const[n,l]of e)o.set(n,Ir(l,n,r,i,s));return o}if(e instanceof Set){const o=new Set;i.set(e,o);for(const n of e)o.add(Ir(n,void 0,r,i,s));return o}if(bn(e))return e.subarray();if(Cn(e)){const o=new(Object.getPrototypeOf(e)).constructor(e.length);i.set(e,o);for(let n=0;n<e.length;n++)o[n]=Ir(e[n],n,r,i,s);return o}if(e instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&e instanceof SharedArrayBuffer)return e.slice(0);if(e instanceof DataView){const o=new DataView(e.buffer.slice(0),e.byteOffset,e.byteLength);return i.set(e,o),me(o,e,r,i,s),o}if(typeof File<"u"&&e instanceof File){const o=new File([e],e.name,{type:e.type});return i.set(e,o),me(o,e,r,i,s),o}if(typeof Blob<"u"&&e instanceof Blob){const o=new Blob([e],{type:e.type});return i.set(e,o),me(o,e,r,i,s),o}if(e instanceof Error){const o=structuredClone(e);return i.set(e,o),o.message=e.message,o.name=e.name,o.stack=e.stack,o.cause=e.cause,o.constructor=e.constructor,me(o,e,r,i,s),o}if(e instanceof Boolean){const o=new Boolean(e.valueOf());return i.set(e,o),me(o,e,r,i,s),o}if(e instanceof Number){const o=new Number(e.valueOf());return i.set(e,o),me(o,e,r,i,s),o}if(e instanceof String){const o=new String(e.valueOf());return i.set(e,o),me(o,e,r,i,s),o}if(typeof e=="object"&&Am(e)){const o=Object.create(Object.getPrototypeOf(e));return i.set(e,o),me(o,e,r,i,s),o}return e}function me(e,t,r=e,i,s){const a=[...Object.keys(t),...bu(t)];for(let o=0;o<a.length;o++){const n=a[o],l=Object.getOwnPropertyDescriptor(e,n);(l==null||l.writable)&&(e[n]=Ir(t[n],n,r,i,s))}}function Am(e){switch(mn(e)){case Tu:case mm:case xm:case bm:case Su:case pm:case Lm:case Fm:case _m:case Bm:case vm:case gm:case wu:case Cm:case dm:case ym:case ku:case fm:case km:case wm:case Sm:case Tm:return!0;default:return!1}}function Em(e){return e==="__proto__"}function Pa(e){var r;if(typeof e!="object"||e==null)return!1;if(Object.getPrototypeOf(e)===null)return!0;if(Object.prototype.toString.call(e)!=="[object Object]"){const i=e[Symbol.toStringTag];return i==null||!((r=Object.getOwnPropertyDescriptor(e,Symbol.toStringTag))!=null&&r.writable)?!1:e.toString()===`[object ${i}]`}let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function $m(e){return Number.isSafeInteger(e)&&e>=0}function _u(e){return e!=null&&typeof e!="function"&&$m(e.length)}function Om(e,t){return Mm(e,(r,i,s,a)=>{if(typeof e=="object"){if(mn(e)==="[object Object]"&&typeof e.constructor!="function"){const o={};return a.set(e,o),me(o,e,s,a),o}switch(Object.prototype.toString.call(e)){case wu:case ku:case Su:{const o=new e.constructor(e==null?void 0:e.valueOf());return me(o,e),o}case Tu:{const o={};return me(o,e),o.length=e.length,o[Symbol.iterator]=e[Symbol.iterator],o}default:return}}})}function Ul(e){return Om(e)}function Lo(e){return e!==null&&typeof e=="object"&&mn(e)==="[object Arguments]"}function Dm(e){return vo(e)&&_u(e)}function vs(e){return Cn(e)}function Pm(e){const t=e==null?void 0:e.constructor;return e===(typeof t=="function"?t.prototype:Object.prototype)}function is(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError("Expected a function");const r=function(...i){const s=t?t.apply(this,i):i[0],a=r.cache;if(a.has(s))return a.get(s);const o=e.apply(this,i);return r.cache=a.set(s,o)||a,o};return r.cache=new(is.Cache||Map),r}is.Cache=Map;function Im(e,...t){const r=t.slice(0,-1),i=t[t.length-1];let s=e;for(let a=0;a<r.length;a++){const o=r[a];s=Ls(s,o,i,new Map)}return s}function Ls(e,t,r,i){if(xn(e)&&(e=Object(e)),t==null||typeof t!="object")return e;if(i.has(t))return um(i.get(t));if(i.set(t,e),Array.isArray(t)){t=t.slice();for(let a=0;a<t.length;a++)a in t||(t[a]=void 0)}const s=[...Object.keys(t),...bu(t)];for(let a=0;a<s.length;a++){const o=s[a];if(Em(o))continue;let n=t[o],l=e[o];if(Lo(n)&&(n={...n}),Lo(l)&&(l={...l}),bn(n)&&(n=Ul(n)),Array.isArray(n))if(Array.isArray(l)){const h=[],u=Reflect.ownKeys(l);for(let d=0;d<u.length;d++){const f=u[d];h[f]=l[f]}l=h}else if(Dm(l)){const h=[];for(let u=0;u<l.length;u++)h[u]=l[u];l=h}else l=[];const c=r(l,n,o,e,t,i);c!==void 0?e[o]=c:Array.isArray(n)||vo(l)&&vo(n)&&(Pa(l)||Pa(n)||vs(l)||vs(n))?e[o]=Ls(l,n,r,i):l==null&&Pa(n)?e[o]=Ls({},n,r,i):l==null&&vs(n)?e[o]=Ul(n):(l===void 0||n!==void 0)&&(e[o]=n)}return e}function Rm(e,...t){return Im(e,...t,cm)}function Xl(e){if(e==null)return!0;if(_u(e))return typeof e.splice!="function"&&typeof e!="string"&&!bn(e)&&!vs(e)&&!Lo(e)?!1:e.length===0;if(typeof e=="object"||typeof e=="function"){if(e instanceof Map||e instanceof Set)return e.size===0;const t=Object.keys(e);return Pm(e)?t.filter(r=>r!=="constructor").length===0:t.length===0}return!0}var Fs={exports:{}},qm=Fs.exports,Gl;function Nm(){return Gl||(Gl=1,(function(e,t){(function(r,i){e.exports=i()})(qm,(function(){var r=1e3,i=6e4,s=36e5,a="millisecond",o="second",n="minute",l="hour",c="day",h="week",u="month",d="quarter",f="year",y="date",m="Invalid Date",C=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,x=/\[([^\]]+)]|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,k={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(A){var E=["th","st","nd","rd"],B=A%100;return"["+A+(E[(B-20)%10]||E[B]||E[0])+"]"}},w=function(A,E,B){var D=String(A);return!D||D.length>=E?A:""+Array(E+1-D.length).join(B)+A},T={s:w,z:function(A){var E=-A.utcOffset(),B=Math.abs(E),D=Math.floor(B/60),$=B%60;return(E<=0?"+":"-")+w(D,2,"0")+":"+w($,2,"0")},m:function A(E,B){if(E.date()<B.date())return-A(B,E);var D=12*(B.year()-E.year())+(B.month()-E.month()),$=E.clone().add(D,u),N=B-$<0,V=E.clone().add(D+(N?-1:1),u);return+(-(D+(B-$)/(N?$-V:V-$))||0)},a:function(A){return A<0?Math.ceil(A)||0:Math.floor(A)},p:function(A){return{M:u,y:f,w:h,d:c,D:y,h:l,m:n,s:o,ms:a,Q:d}[A]||String(A||"").toLowerCase().replace(/s$/,"")},u:function(A){return A===void 0}},_="en",v={};v[_]=k;var F="$isDayjsObject",L=function(A){return A instanceof rt||!(!A||!A[F])},U=function A(E,B,D){var $;if(!E)return _;if(typeof E=="string"){var N=E.toLowerCase();v[N]&&($=N),B&&(v[N]=B,$=N);var V=E.split("-");if(!$&&V.length>1)return A(V[0])}else{var at=E.name;v[at]=E,$=at}return!D&&$&&(_=$),$||!D&&_},W=function(A,E){if(L(A))return A.clone();var B=typeof E=="object"?E:{};return B.date=A,B.args=arguments,new rt(B)},q=T;q.l=U,q.i=L,q.w=function(A,E){return W(A,{locale:E.$L,utc:E.$u,x:E.$x,$offset:E.$offset})};var rt=(function(){function A(B){this.$L=U(B.locale,null,!0),this.parse(B),this.$x=this.$x||B.x||{},this[F]=!0}var E=A.prototype;return E.parse=function(B){this.$d=(function(D){var $=D.date,N=D.utc;if($===null)return new Date(NaN);if(q.u($))return new Date;if($ instanceof Date)return new Date($);if(typeof $=="string"&&!/Z$/i.test($)){var V=$.match(C);if(V){var at=V[2]-1||0,ht=(V[7]||"0").substring(0,3);return N?new Date(Date.UTC(V[1],at,V[3]||1,V[4]||0,V[5]||0,V[6]||0,ht)):new Date(V[1],at,V[3]||1,V[4]||0,V[5]||0,V[6]||0,ht)}}return new Date($)})(B),this.init()},E.init=function(){var B=this.$d;this.$y=B.getFullYear(),this.$M=B.getMonth(),this.$D=B.getDate(),this.$W=B.getDay(),this.$H=B.getHours(),this.$m=B.getMinutes(),this.$s=B.getSeconds(),this.$ms=B.getMilliseconds()},E.$utils=function(){return q},E.isValid=function(){return this.$d.toString()!==m},E.isSame=function(B,D){var $=W(B);return this.startOf(D)<=$&&$<=this.endOf(D)},E.isAfter=function(B,D){return W(B)<this.startOf(D)},E.isBefore=function(B,D){return this.endOf(D)<W(B)},E.$g=function(B,D,$){return q.u(B)?this[D]:this.set($,B)},E.unix=function(){return Math.floor(this.valueOf()/1e3)},E.valueOf=function(){return this.$d.getTime()},E.startOf=function(B,D){var $=this,N=!!q.u(D)||D,V=q.p(B),at=function(bt,it){var ut=q.w($.$u?Date.UTC($.$y,it,bt):new Date($.$y,it,bt),$);return N?ut:ut.endOf(c)},ht=function(bt,it){return q.w($.toDate()[bt].apply($.toDate("s"),(N?[0,0,0,0]:[23,59,59,999]).slice(it)),$)},pt=this.$W,yt=this.$M,gt=this.$D,_t="set"+(this.$u?"UTC":"");switch(V){case f:return N?at(1,0):at(31,11);case u:return N?at(1,yt):at(0,yt+1);case h:var wt=this.$locale().weekStart||0,Et=(pt<wt?pt+7:pt)-wt;return at(N?gt-Et:gt+(6-Et),yt);case c:case y:return ht(_t+"Hours",0);case l:return ht(_t+"Minutes",1);case n:return ht(_t+"Seconds",2);case o:return ht(_t+"Milliseconds",3);default:return this.clone()}},E.endOf=function(B){return this.startOf(B,!1)},E.$set=function(B,D){var $,N=q.p(B),V="set"+(this.$u?"UTC":""),at=($={},$[c]=V+"Date",$[y]=V+"Date",$[u]=V+"Month",$[f]=V+"FullYear",$[l]=V+"Hours",$[n]=V+"Minutes",$[o]=V+"Seconds",$[a]=V+"Milliseconds",$)[N],ht=N===c?this.$D+(D-this.$W):D;if(N===u||N===f){var pt=this.clone().set(y,1);pt.$d[at](ht),pt.init(),this.$d=pt.set(y,Math.min(this.$D,pt.daysInMonth())).$d}else at&&this.$d[at](ht);return this.init(),this},E.set=function(B,D){return this.clone().$set(B,D)},E.get=function(B){return this[q.p(B)]()},E.add=function(B,D){var $,N=this;B=Number(B);var V=q.p(D),at=function(yt){var gt=W(N);return q.w(gt.date(gt.date()+Math.round(yt*B)),N)};if(V===u)return this.set(u,this.$M+B);if(V===f)return this.set(f,this.$y+B);if(V===c)return at(1);if(V===h)return at(7);var ht=($={},$[n]=i,$[l]=s,$[o]=r,$)[V]||1,pt=this.$d.getTime()+B*ht;return q.w(pt,this)},E.subtract=function(B,D){return this.add(-1*B,D)},E.format=function(B){var D=this,$=this.$locale();if(!this.isValid())return $.invalidDate||m;var N=B||"YYYY-MM-DDTHH:mm:ssZ",V=q.z(this),at=this.$H,ht=this.$m,pt=this.$M,yt=$.weekdays,gt=$.months,_t=$.meridiem,wt=function(it,ut,Bt,Mt){return it&&(it[ut]||it(D,N))||Bt[ut].slice(0,Mt)},Et=function(it){return q.s(at%12||12,it,"0")},bt=_t||function(it,ut,Bt){var Mt=it<12?"AM":"PM";return Bt?Mt.toLowerCase():Mt};return N.replace(x,(function(it,ut){return ut||(function(Bt){switch(Bt){case"YY":return String(D.$y).slice(-2);case"YYYY":return q.s(D.$y,4,"0");case"M":return pt+1;case"MM":return q.s(pt+1,2,"0");case"MMM":return wt($.monthsShort,pt,gt,3);case"MMMM":return wt(gt,pt);case"D":return D.$D;case"DD":return q.s(D.$D,2,"0");case"d":return String(D.$W);case"dd":return wt($.weekdaysMin,D.$W,yt,2);case"ddd":return wt($.weekdaysShort,D.$W,yt,3);case"dddd":return yt[D.$W];case"H":return String(at);case"HH":return q.s(at,2,"0");case"h":return Et(1);case"hh":return Et(2);case"a":return bt(at,ht,!0);case"A":return bt(at,ht,!1);case"m":return String(ht);case"mm":return q.s(ht,2,"0");case"s":return String(D.$s);case"ss":return q.s(D.$s,2,"0");case"SSS":return q.s(D.$ms,3,"0");case"Z":return V}return null})(it)||V.replace(":","")}))},E.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},E.diff=function(B,D,$){var N,V=this,at=q.p(D),ht=W(B),pt=(ht.utcOffset()-this.utcOffset())*i,yt=this-ht,gt=function(){return q.m(V,ht)};switch(at){case f:N=gt()/12;break;case u:N=gt();break;case d:N=gt()/3;break;case h:N=(yt-pt)/6048e5;break;case c:N=(yt-pt)/864e5;break;case l:N=yt/s;break;case n:N=yt/i;break;case o:N=yt/r;break;default:N=yt}return $?N:q.a(N)},E.daysInMonth=function(){return this.endOf(u).$D},E.$locale=function(){return v[this.$L]},E.locale=function(B,D){if(!B)return this.$L;var $=this.clone(),N=U(B,D,!0);return N&&($.$L=N),$},E.clone=function(){return q.w(this.$d,this)},E.toDate=function(){return new Date(this.valueOf())},E.toJSON=function(){return this.isValid()?this.toISOString():null},E.toISOString=function(){return this.$d.toISOString()},E.toString=function(){return this.$d.toUTCString()},A})(),Y=rt.prototype;return W.prototype=Y,[["$ms",a],["$s",o],["$m",n],["$H",l],["$W",c],["$M",u],["$y",f],["$D",y]].forEach((function(A){Y[A[1]]=function(E){return this.$g(E,A[0],A[1])}})),W.extend=function(A,E){return A.$i||(A(E,rt,W),A.$i=!0),W},W.locale=U,W.isDayjs=L,W.unix=function(A){return W(1e3*A)},W.en=v[_],W.Ls=v,W.p={},W}))})(Fs)),Fs.exports}var Wm=Nm();const zm=yn(Wm);var Bu=Object.defineProperty,p=(e,t)=>Bu(e,"name",{value:t,configurable:!0}),Hm=(e,t)=>{for(var r in t)Bu(e,r,{get:t[r],enumerable:!0})},Re={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},I={trace:p((...e)=>{},"trace"),debug:p((...e)=>{},"debug"),info:p((...e)=>{},"info"),warn:p((...e)=>{},"warn"),error:p((...e)=>{},"error"),fatal:p((...e)=>{},"fatal")},kn=p(function(e="fatal"){let t=Re.fatal;typeof e=="string"?e.toLowerCase()in Re&&(t=Re[e]):typeof e=="number"&&(t=e),I.trace=()=>{},I.debug=()=>{},I.info=()=>{},I.warn=()=>{},I.error=()=>{},I.fatal=()=>{},t<=Re.fatal&&(I.fatal=console.error?console.error.bind(console,ue("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",ue("FATAL"))),t<=Re.error&&(I.error=console.error?console.error.bind(console,ue("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",ue("ERROR"))),t<=Re.warn&&(I.warn=console.warn?console.warn.bind(console,ue("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",ue("WARN"))),t<=Re.info&&(I.info=console.info?console.info.bind(console,ue("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",ue("INFO"))),t<=Re.debug&&(I.debug=console.debug?console.debug.bind(console,ue("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",ue("DEBUG"))),t<=Re.trace&&(I.trace=console.debug?console.debug.bind(console,ue("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",ue("TRACE")))},"setLogLevel"),ue=p(e=>`%c${zm().format("ss.SSS")} : ${e} : `,"format");const Ym=e=>{const{r:t,g:r,b:i}=ji.parse(e),s=.2126*Fi.channel.toLinear(t)+.7152*Fi.channel.toLinear(r)+.0722*Fi.channel.toLinear(i);return Fi.lang.round(s)},jm=e=>Ym(e)>=.5,we=e=>!jm(e),vu=(e,t,r)=>{const i=ji.parse(e),s=i[t],a=Fi.channel.clamp[t](s+r);return s!==a&&(i[t]=a),ji.stringify(i)},z=(e,t)=>vu(e,"l",t),H=(e,t)=>vu(e,"l",-t),b=(e,t)=>{const r=ji.parse(e),i={};for(const s in t)t[s]&&(i[s]=r[s]+t[s]);return lm(e,i)},M=(e,t=100)=>{const r=ji.parse(e);return r.r=255-r.r,r.g=255-r.g,r.b=255-r.b,hm(r,e,t)};var Fo=p((e,t,{depth:r=2}={})=>{const i={depth:r};if(Array.isArray(t)&&!Array.isArray(e))return t.forEach(s=>Fo(e,s,i)),e;if(Array.isArray(t)&&Array.isArray(e))return t.forEach(s=>{e.includes(s)||e.push(s)}),e;if(e==null||r<=0)return e!=null&&typeof e=="object"&&typeof t=="object"?Object.assign(e,t):t;if(t!=null&&typeof e=="object"&&typeof t=="object"){const s=e;Object.entries(t).forEach(([a,o])=>{if(typeof o=="object"){if(o===null)return;Object.hasOwn(e,a)||Object.defineProperty(e,a,{value:void 0,writable:!0,enumerable:!0,configurable:!0}),s[a]===void 0&&(s[a]=Array.isArray(o)?[]:{}),typeof s[a]=="object"&&(s[a]=Fo(s[a],o,{depth:r-1}))}else typeof s[a]!="object"&&(Object.hasOwn(e,a)?s[a]=o:Object.defineProperty(e,a,{value:o,writable:!0,enumerable:!0,configurable:!0}))})}return e},"assignWithDepth"),Vt=Fo,$e="#ffffff",Oe="#f2f2f2",Tt=p((e,t)=>t?b(e,{s:-40,l:10}):b(e,{s:-40,l:-10}),"mkBorder"),Wr,Um=(Wr=class{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(){var r,i,s,a,o,n,l,c,h,u,d,f,y,m,C,x,k,w,T,_,v,F,L,U,W,q,rt,Y,A,E,B,D,$,N,V,at,ht,pt,yt,gt,_t,wt,Et,bt,it,ut,Bt,Mt,Rt,R;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(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||z(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||H(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||H(this.mainBkg,10)):(this.rowOdd=this.rowOdd||z(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||z(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||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.darkMode)for(let vt=0;vt<this.THEME_COLOR_LIMIT;vt++)this["cScale"+vt]=H(this["cScale"+vt],75);else for(let vt=0;vt<this.THEME_COLOR_LIMIT;vt++)this["cScale"+vt]=H(this["cScale"+vt],25);for(let vt=0;vt<this.THEME_COLOR_LIMIT;vt++)this["cScaleInv"+vt]=this["cScaleInv"+vt]||M(this["cScale"+vt]);for(let vt=0;vt<this.THEME_COLOR_LIMIT;vt++)this.darkMode?this["cScalePeer"+vt]=this["cScalePeer"+vt]||z(this["cScale"+vt],10):this["cScalePeer"+vt]=this["cScalePeer"+vt]||H(this["cScale"+vt],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let vt=0;vt<this.THEME_COLOR_LIMIT;vt++)this["cScaleLabel"+vt]=this["cScaleLabel"+vt]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let vt=0;vt<5;vt++)this["surface"+vt]=this["surface"+vt]||b(this.mainBkg,{h:180,s:-15,l:t*(5+vt*3)}),this["surfacePeer"+vt]=this["surfacePeer"+vt]||b(this.mainBkg,{h:180,s:-15,l:t*(8+vt*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(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||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(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??b(this.primaryColor,{l:-30}),this.venn2=this.venn2??b(this.secondaryColor,{l:-30}),this.venn3=this.venn3??b(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??b(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??b(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??b(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??b(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??b(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:((r=this.cynefin)==null?void 0:r.domainFontSize)||16,itemFontSize:((i=this.cynefin)==null?void 0:i.itemFontSize)||12,boundaryColor:((s=this.cynefin)==null?void 0:s.boundaryColor)||this.lineColor,boundaryWidth:((a=this.cynefin)==null?void 0:a.boundaryWidth)||2,cliffColor:((o=this.cynefin)==null?void 0:o.cliffColor)||"#8B0000",cliffWidth:((n=this.cynefin)==null?void 0:n.cliffWidth)||4,arrowColor:((l=this.cynefin)==null?void 0:l.arrowColor)||this.lineColor,arrowWidth:((c=this.cynefin)==null?void 0:c.arrowWidth)||2,complexBg:((h=this.cynefin)==null?void 0:h.complexBg)||"#E8F5E9",complicatedBg:((u=this.cynefin)==null?void 0:u.complicatedBg)||"#E3F2FD",chaoticBg:((d=this.cynefin)==null?void 0:d.chaoticBg)||"#FBE9E7",clearBg:((f=this.cynefin)==null?void 0:f.clearBg)||"#FFF8E1",confusionBg:((y=this.cynefin)==null?void 0:y.confusionBg)||"#F3E5F5",textColor:((m=this.cynefin)==null?void 0:m.textColor)||this.textColor,labelColor:((C=this.cynefin)==null?void 0:C.labelColor)||this.primaryTextColor},this.radar={axisColor:((x=this.radar)==null?void 0:x.axisColor)||this.lineColor,axisStrokeWidth:((k=this.radar)==null?void 0:k.axisStrokeWidth)||2,axisLabelFontSize:((w=this.radar)==null?void 0:w.axisLabelFontSize)||12,curveOpacity:((T=this.radar)==null?void 0:T.curveOpacity)||.5,curveStrokeWidth:((_=this.radar)==null?void 0:_.curveStrokeWidth)||2,graticuleColor:((v=this.radar)==null?void 0:v.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((F=this.radar)==null?void 0:F.graticuleStrokeWidth)||1,graticuleOpacity:((L=this.radar)==null?void 0:L.graticuleOpacity)||.3,legendBoxSize:((U=this.radar)==null?void 0:U.legendBoxSize)||12,legendFontSize:((W=this.radar)==null?void 0:W.legendFontSize)||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:((q=this.wardley)==null?void 0:q.backgroundColor)||this.background,axisColor:((rt=this.wardley)==null?void 0:rt.axisColor)||this.lineColor,axisTextColor:((Y=this.wardley)==null?void 0:Y.axisTextColor)||this.primaryTextColor,gridColor:((A=this.wardley)==null?void 0:A.gridColor)||this.gridColor,componentFill:((E=this.wardley)==null?void 0:E.componentFill)||this.background,componentStroke:((B=this.wardley)==null?void 0:B.componentStroke)||this.lineColor,componentLabelColor:((D=this.wardley)==null?void 0:D.componentLabelColor)||this.primaryTextColor,linkStroke:(($=this.wardley)==null?void 0:$.linkStroke)||this.lineColor,evolutionStroke:((N=this.wardley)==null?void 0:N.evolutionStroke)||this.wardleyEvolutionColor,annotationStroke:((V=this.wardley)==null?void 0:V.annotationStroke)||this.lineColor,annotationTextColor:((at=this.wardley)==null?void 0:at.annotationTextColor)||this.primaryTextColor,annotationFill:((ht=this.wardley)==null?void 0:ht.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||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((pt=this.xyChart)==null?void 0:pt.backgroundColor)||this.background,titleColor:((yt=this.xyChart)==null?void 0:yt.titleColor)||this.primaryTextColor,dataLabelColor:((gt=this.xyChart)==null?void 0:gt.dataLabelColor)||this.primaryTextColor,legendTextColor:((_t=this.xyChart)==null?void 0:_t.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((wt=this.xyChart)==null?void 0:wt.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((Et=this.xyChart)==null?void 0:Et.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((bt=this.xyChart)==null?void 0:bt.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((it=this.xyChart)==null?void 0:it.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((ut=this.xyChart)==null?void 0:ut.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((Bt=this.xyChart)==null?void 0:Bt.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((Mt=this.xyChart)==null?void 0:Mt.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((Rt=this.xyChart)==null?void 0:Rt.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((R=this.xyChart)==null?void 0:R.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?H(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||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Wr,"Theme"),Wr),Xm=p(e=>{const t=new Um;return t.calculate(e),t},"getThemeVariables"),zr,Gm=(zr=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=z(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=M(this.background),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.lineColor=M(this.background),this.textColor=M(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=z(M("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=ur(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=H("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=H(this.sectionBkgColor,10),this.taskBorderColor=ur(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=ur(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||z(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||H(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(){var t,r,i,s,a,o,n,l,c,h,u,d,f,y,m,C,x,k,w,T,_,v,F,L,U,W,q,rt,Y,A,E,B,D,$,N,V,at,ht,pt,yt,gt,_t,wt,Et,bt,it,ut,Bt,Mt,Rt;this.secondBkg=z(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=z(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=z(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=M(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=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(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||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330});for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleInv"+R]=this["cScaleInv"+R]||M(this["cScale"+R]);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScalePeer"+R]=this["cScalePeer"+R]||z(this["cScale"+R],10);for(let R=0;R<5;R++)this["surface"+R]=this["surface"+R]||b(this.mainBkg,{h:30,s:-30,l:-(-10+R*4)}),this["surfacePeer"+R]=this["surfacePeer"+R]||b(this.mainBkg,{h:30,s:-30,l:-(-7+R*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleLabel"+R]=this["cScaleLabel"+R]||this.scaleLabelColor;for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["pie"+R]=this["cScale"+R];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 R=0;R<8;R++)this["venn"+(R+1)]=this["venn"+(R+1)]??z(this["cScale"+R],30);this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:((t=this.cynefin)==null?void 0:t.domainFontSize)||16,itemFontSize:((r=this.cynefin)==null?void 0:r.itemFontSize)||12,boundaryColor:((i=this.cynefin)==null?void 0:i.boundaryColor)||this.lineColor,boundaryWidth:((s=this.cynefin)==null?void 0:s.boundaryWidth)||2,cliffColor:((a=this.cynefin)==null?void 0:a.cliffColor)||"#FF6B6B",cliffWidth:((o=this.cynefin)==null?void 0:o.cliffWidth)||4,arrowColor:((n=this.cynefin)==null?void 0:n.arrowColor)||this.lineColor,arrowWidth:((l=this.cynefin)==null?void 0:l.arrowWidth)||2,complexBg:((c=this.cynefin)==null?void 0:c.complexBg)||"#1B5E20",complicatedBg:((h=this.cynefin)==null?void 0:h.complicatedBg)||"#0D47A1",chaoticBg:((u=this.cynefin)==null?void 0:u.chaoticBg)||"#BF360C",clearBg:((d=this.cynefin)==null?void 0:d.clearBg)||"#F57F17",confusionBg:((f=this.cynefin)==null?void 0:f.confusionBg)||"#4A148C",textColor:((y=this.cynefin)==null?void 0:y.textColor)||this.textColor,labelColor:((m=this.cynefin)==null?void 0:m.labelColor)||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((C=this.xyChart)==null?void 0:C.backgroundColor)||this.background,titleColor:((x=this.xyChart)==null?void 0:x.titleColor)||this.primaryTextColor,dataLabelColor:((k=this.xyChart)==null?void 0:k.dataLabelColor)||this.primaryTextColor,legendTextColor:((w=this.xyChart)==null?void 0:w.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((T=this.xyChart)==null?void 0:T.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((_=this.xyChart)==null?void 0:_.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((v=this.xyChart)==null?void 0:v.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((F=this.xyChart)==null?void 0:F.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((L=this.xyChart)==null?void 0:L.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((U=this.xyChart)==null?void 0:U.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((W=this.xyChart)==null?void 0:W.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((q=this.xyChart)==null?void 0:q.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((rt=this.xyChart)==null?void 0:rt.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:((Y=this.radar)==null?void 0:Y.axisColor)||this.lineColor,axisStrokeWidth:((A=this.radar)==null?void 0:A.axisStrokeWidth)||2,axisLabelFontSize:((E=this.radar)==null?void 0:E.axisLabelFontSize)||12,curveOpacity:((B=this.radar)==null?void 0:B.curveOpacity)||.5,curveStrokeWidth:((D=this.radar)==null?void 0:D.curveStrokeWidth)||2,graticuleColor:(($=this.radar)==null?void 0:$.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((N=this.radar)==null?void 0:N.graticuleStrokeWidth)||1,graticuleOpacity:((V=this.radar)==null?void 0:V.graticuleOpacity)||.3,legendBoxSize:((at=this.radar)==null?void 0:at.legendBoxSize)||12,legendFontSize:((ht=this.radar)==null?void 0:ht.legendFontSize)||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#ff6b6b",this.wardley={backgroundColor:((pt=this.wardley)==null?void 0:pt.backgroundColor)||this.background,axisColor:((yt=this.wardley)==null?void 0:yt.axisColor)||this.lineColor,axisTextColor:((gt=this.wardley)==null?void 0:gt.axisTextColor)||this.primaryTextColor,gridColor:((_t=this.wardley)==null?void 0:_t.gridColor)||this.gridColor,componentFill:((wt=this.wardley)==null?void 0:wt.componentFill)||this.mainBkg,componentStroke:((Et=this.wardley)==null?void 0:Et.componentStroke)||this.lineColor,componentLabelColor:((bt=this.wardley)==null?void 0:bt.componentLabelColor)||this.primaryTextColor,linkStroke:((it=this.wardley)==null?void 0:it.linkStroke)||this.lineColor,evolutionStroke:((ut=this.wardley)==null?void 0:ut.evolutionStroke)||this.wardleyEvolutionColor,annotationStroke:((Bt=this.wardley)==null?void 0:Bt.annotationStroke)||this.lineColor,annotationTextColor:((Mt=this.wardley)==null?void 0:Mt.annotationTextColor)||this.primaryTextColor,annotationFill:((Rt=this.wardley)==null?void 0:Rt.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?H(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=z(this.secondaryColor,20),this.git1=z(this.pie2||this.secondaryColor,20),this.git2=z(this.pie3||this.tertiaryColor,20),this.git3=z(this.pie4||b(this.primaryColor,{h:-30}),20),this.git4=z(this.pie5||b(this.primaryColor,{h:-60}),20),this.git5=z(this.pie6||b(this.primaryColor,{h:-90}),10),this.git6=z(this.pie7||b(this.primaryColor,{h:60}),10),this.git7=z(this.pie8||b(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||M(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||M(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||z("#5a3d5c",10),this.emProcessorStroke=this.emProcessorStroke||"#8a6d8c",this.emReadModelFill=this.emReadModelFill||z("#3d5a2d",10),this.emReadModelStroke=this.emReadModelStroke||"#6d8c5c",this.emCommandFill=this.emCommandFill||z("#2d3d5a",10),this.emCommandStroke=this.emCommandStroke||"#5c6d8c",this.emEventFill=this.emEventFill||z("#5a452d",10),this.emEventStroke=this.emEventStroke||"#8c755c",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||z(this.background,5),this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||z(this.background,12),this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||z(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||z(this.background,2),this.nodeBorder=this.nodeBorder||"#999"}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(zr,"Theme"),zr),Vm=p(e=>{const t=new Gm;return t.calculate(e),t},"getThemeVariables"),Hr,Zm=(Hr=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=b(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.lineColor=M(this.background),this.textColor=M(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.primaryBorderColor=Tt(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=ur(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(){var t,r,i,s,a,o,n,l,c,h,u,d,f,y,m,C,x,k,w,T,_,v,F,L,U,W,q,rt,Y,A,E,B,D,$,N,V,at,ht,pt,yt,gt,_t,wt,Et,bt,it,ut,Bt,Mt,Rt;this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||H(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||H(this.tertiaryColor,40);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScale"+R]=H(this["cScale"+R],10),this["cScalePeer"+R]=this["cScalePeer"+R]||H(this["cScale"+R],25);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleInv"+R]=this["cScaleInv"+R]||b(this["cScale"+R],{h:180});for(let R=0;R<5;R++)this["surface"+R]=this["surface"+R]||b(this.mainBkg,{h:30,l:-(5+R*5)}),this["surfacePeer"+R]=this["surfacePeer"+R]||b(this.mainBkg,{h:30,l:-(7+R*5)});if(this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!=="calculated"){this.cScaleLabel0=this.cScaleLabel0||M(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||M(this.labelTextColor);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleLabel"+R]=this["cScaleLabel"+R]||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||z(this.primaryColor,75)||"#ffffff",this.rowEven=this.rowEven||z(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=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||b(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-30}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||b(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||b(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??b(this.primaryColor,{l:-30}),this.venn2=this.venn2??b(this.secondaryColor,{l:-30}),this.venn3=this.venn3??b(this.tertiaryColor,{l:-40}),this.venn4=this.venn4??b(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??b(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??b(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??b(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??b(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:((t=this.cynefin)==null?void 0:t.domainFontSize)||16,itemFontSize:((r=this.cynefin)==null?void 0:r.itemFontSize)||12,boundaryColor:((i=this.cynefin)==null?void 0:i.boundaryColor)||this.lineColor,boundaryWidth:((s=this.cynefin)==null?void 0:s.boundaryWidth)||2,cliffColor:((a=this.cynefin)==null?void 0:a.cliffColor)||"#8B0000",cliffWidth:((o=this.cynefin)==null?void 0:o.cliffWidth)||4,arrowColor:((n=this.cynefin)==null?void 0:n.arrowColor)||this.lineColor,arrowWidth:((l=this.cynefin)==null?void 0:l.arrowWidth)||2,complexBg:((c=this.cynefin)==null?void 0:c.complexBg)||"#E8F5E9",complicatedBg:((h=this.cynefin)==null?void 0:h.complicatedBg)||"#E3F2FD",chaoticBg:((u=this.cynefin)==null?void 0:u.chaoticBg)||"#FBE9E7",clearBg:((d=this.cynefin)==null?void 0:d.clearBg)||"#FFF8E1",confusionBg:((f=this.cynefin)==null?void 0:f.confusionBg)||"#F3E5F5",textColor:((y=this.cynefin)==null?void 0:y.textColor)||this.textColor,labelColor:((m=this.cynefin)==null?void 0:m.labelColor)||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((C=this.radar)==null?void 0:C.axisColor)||this.lineColor,axisStrokeWidth:((x=this.radar)==null?void 0:x.axisStrokeWidth)||2,axisLabelFontSize:((k=this.radar)==null?void 0:k.axisLabelFontSize)||12,curveOpacity:((w=this.radar)==null?void 0:w.curveOpacity)||.5,curveStrokeWidth:((T=this.radar)==null?void 0:T.curveStrokeWidth)||2,graticuleColor:((_=this.radar)==null?void 0:_.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((v=this.radar)==null?void 0:v.graticuleStrokeWidth)||1,graticuleOpacity:((F=this.radar)==null?void 0:F.graticuleOpacity)||.3,legendBoxSize:((L=this.radar)==null?void 0:L.legendBoxSize)||12,legendFontSize:((U=this.radar)==null?void 0:U.legendFontSize)||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:((W=this.wardley)==null?void 0:W.backgroundColor)||this.background,axisColor:((q=this.wardley)==null?void 0:q.axisColor)||this.lineColor,axisTextColor:((rt=this.wardley)==null?void 0:rt.axisTextColor)||this.primaryTextColor,gridColor:((Y=this.wardley)==null?void 0:Y.gridColor)||this.gridColor,componentFill:((A=this.wardley)==null?void 0:A.componentFill)||this.background,componentStroke:((E=this.wardley)==null?void 0:E.componentStroke)||this.lineColor,componentLabelColor:((B=this.wardley)==null?void 0:B.componentLabelColor)||this.primaryTextColor,linkStroke:((D=this.wardley)==null?void 0:D.linkStroke)||this.lineColor,evolutionStroke:(($=this.wardley)==null?void 0:$.evolutionStroke)||this.wardleyEvolutionColor,annotationStroke:((N=this.wardley)==null?void 0:N.annotationStroke)||this.lineColor,annotationTextColor:((V=this.wardley)==null?void 0:V.annotationTextColor)||this.primaryTextColor,annotationFill:((at=this.wardley)==null?void 0:at.annotationFill)||this.background},this.xyChart={backgroundColor:((ht=this.xyChart)==null?void 0:ht.backgroundColor)||this.background,titleColor:((pt=this.xyChart)==null?void 0:pt.titleColor)||this.primaryTextColor,dataLabelColor:((yt=this.xyChart)==null?void 0:yt.dataLabelColor)||this.primaryTextColor,legendTextColor:((gt=this.xyChart)==null?void 0:gt.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((_t=this.xyChart)==null?void 0:_t.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((wt=this.xyChart)==null?void 0:wt.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((Et=this.xyChart)==null?void 0:Et.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((bt=this.xyChart)==null?void 0:bt.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((it=this.xyChart)==null?void 0:it.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((ut=this.xyChart)==null?void 0:ut.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((Bt=this.xyChart)==null?void 0:Bt.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((Mt=this.xyChart)==null?void 0:Mt.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((Rt=this.xyChart)==null?void 0:Rt.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||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||H(M(this.git0),25),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||M(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(Object.keys(this).forEach(i=>{this[i]==="calculated"&&(this[i]=void 0)}),typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Hr,"Theme"),Hr),Km=p(e=>{const t=new Zm;return t.calculate(e),t},"getThemeVariables"),Yr,Qm=(Yr=class{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=z("#cde498",10),this.primaryBorderColor=Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.primaryColor),this.lineColor=M(this.background),this.textColor=M(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(){var t,r,i,s,a,o,n,l,c,h,u,d,f,y,m,C,x,k,w,T,_,v,F,L,U,W,q,rt,Y,A,E,B,D,$,N,V,at,ht,pt,yt,gt,_t,wt,Et,bt,it,ut,Bt,Mt,Rt;this.actorBorder=H(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||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||H(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||H(this.tertiaryColor,40);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScale"+R]=H(this["cScale"+R],10),this["cScalePeer"+R]=this["cScalePeer"+R]||H(this["cScale"+R],25);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleInv"+R]=this["cScaleInv"+R]||b(this["cScale"+R],{h:180});this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleLabel"+R]=this["cScaleLabel"+R]||this.scaleLabelColor;for(let R=0;R<5;R++)this["surface"+R]=this["surface"+R]||b(this.mainBkg,{h:30,s:-30,l:-(5+R*5)}),this["surfacePeer"+R]=this["surfacePeer"+R]||b(this.mainBkg,{h:30,s:-30,l:-(8+R*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||z(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||z(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=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(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||b(this.primaryColor,{l:-30}),this.pie5=this.pie5||b(this.secondaryColor,{l:-30}),this.pie6=this.pie6||b(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||b(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??b(this.primaryColor,{l:-30}),this.venn2=this.venn2??b(this.secondaryColor,{l:-30}),this.venn3=this.venn3??b(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??b(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??b(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??b(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??b(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??b(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:((t=this.cynefin)==null?void 0:t.domainFontSize)||16,itemFontSize:((r=this.cynefin)==null?void 0:r.itemFontSize)||12,boundaryColor:((i=this.cynefin)==null?void 0:i.boundaryColor)||this.lineColor,boundaryWidth:((s=this.cynefin)==null?void 0:s.boundaryWidth)||2,cliffColor:((a=this.cynefin)==null?void 0:a.cliffColor)||"#8B4513",cliffWidth:((o=this.cynefin)==null?void 0:o.cliffWidth)||4,arrowColor:((n=this.cynefin)==null?void 0:n.arrowColor)||this.lineColor,arrowWidth:((l=this.cynefin)==null?void 0:l.arrowWidth)||2,complexBg:((c=this.cynefin)==null?void 0:c.complexBg)||"#C8E6C9",complicatedBg:((h=this.cynefin)==null?void 0:h.complicatedBg)||"#DCEDC8",chaoticBg:((u=this.cynefin)==null?void 0:u.chaoticBg)||"#FFE0B2",clearBg:((d=this.cynefin)==null?void 0:d.clearBg)||"#FFF9C4",confusionBg:((f=this.cynefin)==null?void 0:f.confusionBg)||"#D7CCC8",textColor:((y=this.cynefin)==null?void 0:y.textColor)||this.textColor,labelColor:((m=this.cynefin)==null?void 0:m.labelColor)||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((C=this.radar)==null?void 0:C.axisColor)||this.lineColor,axisStrokeWidth:((x=this.radar)==null?void 0:x.axisStrokeWidth)||2,axisLabelFontSize:((k=this.radar)==null?void 0:k.axisLabelFontSize)||12,curveOpacity:((w=this.radar)==null?void 0:w.curveOpacity)||.5,curveStrokeWidth:((T=this.radar)==null?void 0:T.curveStrokeWidth)||2,graticuleColor:((_=this.radar)==null?void 0:_.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((v=this.radar)==null?void 0:v.graticuleStrokeWidth)||1,graticuleOpacity:((F=this.radar)==null?void 0:F.graticuleOpacity)||.3,legendBoxSize:((L=this.radar)==null?void 0:L.legendBoxSize)||12,legendFontSize:((U=this.radar)==null?void 0:U.legendFontSize)||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:((W=this.wardley)==null?void 0:W.backgroundColor)||this.background,axisColor:((q=this.wardley)==null?void 0:q.axisColor)||this.lineColor,axisTextColor:((rt=this.wardley)==null?void 0:rt.axisTextColor)||this.primaryTextColor,gridColor:((Y=this.wardley)==null?void 0:Y.gridColor)||this.gridColor,componentFill:((A=this.wardley)==null?void 0:A.componentFill)||this.background,componentStroke:((E=this.wardley)==null?void 0:E.componentStroke)||this.lineColor,componentLabelColor:((B=this.wardley)==null?void 0:B.componentLabelColor)||this.primaryTextColor,linkStroke:((D=this.wardley)==null?void 0:D.linkStroke)||this.lineColor,evolutionStroke:(($=this.wardley)==null?void 0:$.evolutionStroke)||this.wardleyEvolutionColor,annotationStroke:((N=this.wardley)==null?void 0:N.annotationStroke)||this.lineColor,annotationTextColor:((V=this.wardley)==null?void 0:V.annotationTextColor)||this.primaryTextColor,annotationFill:((at=this.wardley)==null?void 0:at.annotationFill)||this.background},this.xyChart={backgroundColor:((ht=this.xyChart)==null?void 0:ht.backgroundColor)||this.background,titleColor:((pt=this.xyChart)==null?void 0:pt.titleColor)||this.primaryTextColor,dataLabelColor:((yt=this.xyChart)==null?void 0:yt.dataLabelColor)||this.primaryTextColor,legendTextColor:((gt=this.xyChart)==null?void 0:gt.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((_t=this.xyChart)==null?void 0:_t.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((wt=this.xyChart)==null?void 0:wt.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((Et=this.xyChart)==null?void 0:Et.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((bt=this.xyChart)==null?void 0:bt.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((it=this.xyChart)==null?void 0:it.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((ut=this.xyChart)==null?void 0:ut.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((Bt=this.xyChart)==null?void 0:Bt.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((Mt=this.xyChart)==null?void 0:Mt.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((Rt=this.xyChart)==null?void 0:Rt.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||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||M(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Yr,"Theme"),Yr),Jm=p(e=>{const t=new Qm;return t.calculate(e),t},"getThemeVariables"),jr,t0=(jr=class{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=z(this.contrast,55),this.background="#ffffff",this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.lineColor=M(this.background),this.textColor=M(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||z(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(){var t,r,i,s,a,o,n,l,c,h,u,d,f,y,m,C,x,k,w,T,_,v,F,L,U,W,q,rt,Y,A,E,B,D,$,N,V,at,ht,pt,yt,gt,_t,wt,Et,bt,it,ut,Bt,Mt,Rt;this.secondBkg=z(this.contrast,55),this.border2=this.contrast,this.actorBorder=z(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 R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleInv"+R]=this["cScaleInv"+R]||M(this["cScale"+R]);for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this.darkMode?this["cScalePeer"+R]=this["cScalePeer"+R]||z(this["cScale"+R],10):this["cScalePeer"+R]=this["cScalePeer"+R]||H(this["cScale"+R],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["cScaleLabel"+R]=this["cScaleLabel"+R]||this.scaleLabelColor;for(let R=0;R<5;R++)this["surface"+R]=this["surface"+R]||b(this.mainBkg,{l:-(5+R*5)}),this["surfacePeer"+R]=this["surfacePeer"+R]||b(this.mainBkg,{l:-(8+R*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=z(this.contrast,30),this.sectionBkgColor2=z(this.contrast,30),this.taskBorderColor=H(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=z(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=H(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=b(this.primaryColor,{h:64}),this.fillType3=b(this.secondaryColor,{h:64}),this.fillType4=b(this.primaryColor,{h:-64}),this.fillType5=b(this.secondaryColor,{h:-64}),this.fillType6=b(this.primaryColor,{h:128}),this.fillType7=b(this.secondaryColor,{h:128});for(let R=0;R<this.THEME_COLOR_LIMIT;R++)this["pie"+R]=this["cScale"+R];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 R=0;R<8;R++)this["venn"+(R+1)]=this["venn"+(R+1)]??this["cScale"+R];this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:((t=this.cynefin)==null?void 0:t.domainFontSize)||16,itemFontSize:((r=this.cynefin)==null?void 0:r.itemFontSize)||12,boundaryColor:((i=this.cynefin)==null?void 0:i.boundaryColor)||this.lineColor,boundaryWidth:((s=this.cynefin)==null?void 0:s.boundaryWidth)||2,cliffColor:((a=this.cynefin)==null?void 0:a.cliffColor)||"#8B0000",cliffWidth:((o=this.cynefin)==null?void 0:o.cliffWidth)||4,arrowColor:((n=this.cynefin)==null?void 0:n.arrowColor)||this.lineColor,arrowWidth:((l=this.cynefin)==null?void 0:l.arrowWidth)||2,complexBg:((c=this.cynefin)==null?void 0:c.complexBg)||"#E8F5E9",complicatedBg:((h=this.cynefin)==null?void 0:h.complicatedBg)||"#E3F2FD",chaoticBg:((u=this.cynefin)==null?void 0:u.chaoticBg)||"#FBE9E7",clearBg:((d=this.cynefin)==null?void 0:d.clearBg)||"#FFF8E1",confusionBg:((f=this.cynefin)==null?void 0:f.confusionBg)||"#F3E5F5",textColor:((y=this.cynefin)==null?void 0:y.textColor)||this.textColor,labelColor:((m=this.cynefin)==null?void 0:m.labelColor)||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((C=this.xyChart)==null?void 0:C.backgroundColor)||this.background,titleColor:((x=this.xyChart)==null?void 0:x.titleColor)||this.primaryTextColor,dataLabelColor:((k=this.xyChart)==null?void 0:k.dataLabelColor)||this.primaryTextColor,legendTextColor:((w=this.xyChart)==null?void 0:w.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((T=this.xyChart)==null?void 0:T.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((_=this.xyChart)==null?void 0:_.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((v=this.xyChart)==null?void 0:v.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((F=this.xyChart)==null?void 0:F.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((L=this.xyChart)==null?void 0:L.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((U=this.xyChart)==null?void 0:U.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((W=this.xyChart)==null?void 0:W.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((q=this.xyChart)==null?void 0:q.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((rt=this.xyChart)==null?void 0:rt.plotColorPalette)||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.radar={axisColor:((Y=this.radar)==null?void 0:Y.axisColor)||this.lineColor,axisStrokeWidth:((A=this.radar)==null?void 0:A.axisStrokeWidth)||2,axisLabelFontSize:((E=this.radar)==null?void 0:E.axisLabelFontSize)||12,curveOpacity:((B=this.radar)==null?void 0:B.curveOpacity)||.5,curveStrokeWidth:((D=this.radar)==null?void 0:D.curveStrokeWidth)||2,graticuleColor:(($=this.radar)==null?void 0:$.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:((N=this.radar)==null?void 0:N.graticuleStrokeWidth)||1,graticuleOpacity:((V=this.radar)==null?void 0:V.graticuleOpacity)||.3,legendBoxSize:((at=this.radar)==null?void 0:at.legendBoxSize)||12,legendFontSize:((ht=this.radar)==null?void 0:ht.legendFontSize)||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:((pt=this.wardley)==null?void 0:pt.backgroundColor)||this.background,axisColor:((yt=this.wardley)==null?void 0:yt.axisColor)||this.lineColor,axisTextColor:((gt=this.wardley)==null?void 0:gt.axisTextColor)||this.primaryTextColor,gridColor:((_t=this.wardley)==null?void 0:_t.gridColor)||this.gridColor,componentFill:((wt=this.wardley)==null?void 0:wt.componentFill)||this.background,componentStroke:((Et=this.wardley)==null?void 0:Et.componentStroke)||this.lineColor,componentLabelColor:((bt=this.wardley)==null?void 0:bt.componentLabelColor)||this.primaryTextColor,linkStroke:((it=this.wardley)==null?void 0:it.linkStroke)||this.lineColor,evolutionStroke:((ut=this.wardley)==null?void 0:ut.evolutionStroke)||this.wardleyEvolutionColor,annotationStroke:((Bt=this.wardley)==null?void 0:Bt.annotationStroke)||this.lineColor,annotationTextColor:((Mt=this.wardley)==null?void 0:Mt.annotationTextColor)||this.primaryTextColor,annotationFill:((Rt=this.wardley)==null?void 0:Rt.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=H(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||b(this.primaryColor,{h:-30}),this.git4=this.pie5||b(this.primaryColor,{h:-60}),this.git5=this.pie6||b(this.primaryColor,{h:-90}),this.git6=this.pie7||b(this.primaryColor,{h:60}),this.git7=this.pie8||b(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(jr,"Theme"),jr),e0=p(e=>{const t=new t0;return t.calculate(e),t},"getThemeVariables"),Ur,r0=(Ur=class{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=Tt(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(){var a,o,n,l,c,h,u,d,f,y,m,C;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor;const t="#ECECFE",r="#E9E9F1",i=b(t,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||i,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||r,this.sectionBkgColor2=this.sectionBkgColor2||t,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||t,this.activeTaskBorderColor=this.activeTaskBorderColor||t,this.activeTaskBkgColor=this.activeTaskBkgColor||z(t,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||t,this.cScale1=this.cScale1||r,this.cScale2=this.cScale2||i,this.cScale3=this.cScale3||b(t,{h:30}),this.cScale4=this.cScale4||b(t,{h:60}),this.cScale5=this.cScale5||b(t,{h:90}),this.cScale6=this.cScale6||b(t,{h:120}),this.cScale7=this.cScale7||b(t,{h:150}),this.cScale8=this.cScale8||b(t,{h:210,l:150}),this.cScale9=this.cScale9||b(t,{h:270}),this.cScale10=this.cScale10||b(t,{h:300}),this.cScale11=this.cScale11||b(t,{h:330}),this.darkMode)for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScale"+x]=H(this["cScale"+x],75);else for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScale"+x]=H(this["cScale"+x],25);for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScaleInv"+x]=this["cScaleInv"+x]||M(this["cScale"+x]);for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this.darkMode?this["cScalePeer"+x]=this["cScalePeer"+x]||z(this["cScale"+x],10):this["cScalePeer"+x]=this["cScalePeer"+x]||H(this["cScale"+x],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScaleLabel"+x]=this["cScaleLabel"+x]||this.scaleLabelColor;const s=this.darkMode?-4:-1;for(let x=0;x<5;x++)this["surface"+x]=this["surface"+x]||b(this.mainBkg,{h:180,s:-15,l:s*(5+x*3)}),this["surfacePeer"+x]=this["surfacePeer"+x]||b(this.mainBkg,{h:180,s:-15,l:s*(8+x*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||t,this.fillType1=this.fillType1||r,this.fillType2=this.fillType2||b(t,{h:64}),this.fillType3=this.fillType3||b(r,{h:64}),this.fillType4=this.fillType4||b(t,{h:-64}),this.fillType5=this.fillType5||b(r,{h:-64}),this.fillType6=this.fillType6||b(t,{h:128}),this.fillType7=this.fillType7||b(r,{h:128}),this.pie1=this.pie1||t,this.pie2=this.pie2||r,this.pie3=this.pie3||i,this.pie4=this.pie4||b(t,{l:-10}),this.pie5=this.pie5||b(r,{l:-10}),this.pie6=this.pie6||b(i,{l:-10}),this.pie7=this.pie7||b(t,{h:60,l:-10}),this.pie8=this.pie8||b(t,{h:-60,l:-10}),this.pie9=this.pie9||b(t,{h:120,l:0}),this.pie10=this.pie10||b(t,{h:60,l:-20}),this.pie11=this.pie11||b(t,{h:-60,l:-20}),this.pie12=this.pie12||b(t,{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||t,this.quadrant2Fill=this.quadrant2Fill||b(t,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(t,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(t,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((a=this.xyChart)==null?void 0:a.backgroundColor)||this.background,titleColor:((o=this.xyChart)==null?void 0:o.titleColor)||this.primaryTextColor,legendTextColor:((n=this.xyChart)==null?void 0:n.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((l=this.xyChart)==null?void 0:l.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((c=this.xyChart)==null?void 0:c.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((h=this.xyChart)==null?void 0:h.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((u=this.xyChart)==null?void 0:u.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((d=this.xyChart)==null?void 0:d.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((f=this.xyChart)==null?void 0:f.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((y=this.xyChart)==null?void 0:y.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((m=this.xyChart)==null?void 0:m.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((C=this.xyChart)==null?void 0:C.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||t,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?H(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||t,this.git1=this.git1||r,this.git2=this.git2||i,this.git3=this.git3||b(t,{h:-30}),this.git4=this.git4||b(t,{h:-60}),this.git5=this.git5||b(t,{h:-90}),this.git6=this.git6||b(t,{h:60}),this.git7=this.git7||b(t,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Ur,"Theme"),Ur),i0=p(e=>{const t=new r0;return t.calculate(e),t},"getThemeVariables"),Xr,s0=(Xr=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=z(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=M(this.background),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.mainBkg="#2a2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=z(M("#323D47"),10),this.border1="#ccc",this.border2=ur(255,255,255,.25),this.arrowheadColor=M(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(){var r,i,s,a,o,n,l,c,h,u,d,f;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(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||z(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||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.darkMode)for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScale"+y]=H(this["cScale"+y],75);else for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScale"+y]=H(this["cScale"+y],25);for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScaleInv"+y]=this["cScaleInv"+y]||M(this["cScale"+y]);for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this.darkMode?this["cScalePeer"+y]=this["cScalePeer"+y]||z(this["cScale"+y],10):this["cScalePeer"+y]=this["cScalePeer"+y]||H(this["cScale"+y],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScaleLabel"+y]=this["cScaleLabel"+y]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let y=0;y<5;y++)this["surface"+y]=this["surface"+y]||b(this.mainBkg,{h:180,s:-15,l:t*(5+y*3)}),this["surfacePeer"+y]=this["surfacePeer"+y]||b(this.mainBkg,{h:180,s:-15,l:t*(8+y*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(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||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(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||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((r=this.xyChart)==null?void 0:r.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,legendTextColor:((s=this.xyChart)==null?void 0:s.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((l=this.xyChart)==null?void 0:l.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((c=this.xyChart)==null?void 0:c.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((u=this.xyChart)==null?void 0:u.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((d=this.xyChart)==null?void 0:d.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.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?H(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=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Xr,"Theme"),Xr),a0=p(e=>{const t=new s0;return t.calculate(e),t},"getThemeVariables"),Gr,o0=(Gr=class{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=Tt("#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(){var a,o,n,l,c,h,u,d,f,y,m,C;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#FEF9C3",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor;const t="#ECECFE",r="#E9E9F1",i=b(t,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||i,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||r,this.sectionBkgColor2=this.sectionBkgColor2||t,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||t,this.activeTaskBorderColor=this.activeTaskBorderColor||t,this.activeTaskBkgColor=this.activeTaskBkgColor||z(t,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 x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScale"+x]=this.mainBkg;if(this.darkMode)for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScale"+x]=H(this["cScale"+x],75);else for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScale"+x]=H(this["cScale"+x],25);for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScaleInv"+x]=this["cScaleInv"+x]||M(this["cScale"+x]);for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this.darkMode?this["cScalePeer"+x]=this["cScalePeer"+x]||z(this["cScale"+x],10):this["cScalePeer"+x]=this["cScalePeer"+x]||H(this["cScale"+x],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScaleLabel"+x]=this["cScaleLabel"+x]||this.scaleLabelColor;const s=this.darkMode?-4:-1;for(let x=0;x<5;x++)this["surface"+x]=this["surface"+x]||b(this.mainBkg,{h:180,s:-15,l:s*(5+x*3)}),this["surfacePeer"+x]=this["surfacePeer"+x]||b(this.mainBkg,{h:180,s:-15,l:s*(8+x*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||t,this.fillType1=this.fillType1||r,this.fillType2=this.fillType2||b(t,{h:64}),this.fillType3=this.fillType3||b(r,{h:64}),this.fillType4=this.fillType4||b(t,{h:-64}),this.fillType5=this.fillType5||b(r,{h:-64}),this.fillType6=this.fillType6||b(t,{h:128}),this.fillType7=this.fillType7||b(r,{h:128}),this.pie1=this.pie1||t,this.pie2=this.pie2||r,this.pie3=this.pie3||i,this.pie4=this.pie4||b(t,{l:-10}),this.pie5=this.pie5||b(r,{l:-10}),this.pie6=this.pie6||b(i,{l:-10}),this.pie7=this.pie7||b(t,{h:60,l:-10}),this.pie8=this.pie8||b(t,{h:-60,l:-10}),this.pie9=this.pie9||b(t,{h:120,l:0}),this.pie10=this.pie10||b(t,{h:60,l:-20}),this.pie11=this.pie11||b(t,{h:-60,l:-20}),this.pie12=this.pie12||b(t,{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||t,this.quadrant2Fill=this.quadrant2Fill||b(t,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(t,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(t,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((a=this.xyChart)==null?void 0:a.backgroundColor)||this.background,titleColor:((o=this.xyChart)==null?void 0:o.titleColor)||this.primaryTextColor,legendTextColor:((n=this.xyChart)==null?void 0:n.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((l=this.xyChart)==null?void 0:l.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((c=this.xyChart)==null?void 0:c.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((h=this.xyChart)==null?void 0:h.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((u=this.xyChart)==null?void 0:u.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((d=this.xyChart)==null?void 0:d.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((f=this.xyChart)==null?void 0:f.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((y=this.xyChart)==null?void 0:y.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((m=this.xyChart)==null?void 0:m.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((C=this.xyChart)==null?void 0:C.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||t,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?H(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#FFFFFF",this.git0=this.git0||t,this.git1=this.git1||r,this.git2=this.git2||i,this.git3=this.git3||b(t,{h:-30}),this.git4=this.git4||b(t,{h:-60}),this.git5=this.git5||b(t,{h:-90}),this.git6=this.git6||b(t,{h:60}),this.git7=this.git7||b(t,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Gr,"Theme"),Gr),n0=p(e=>{const t=new o0;return t.calculate(e),t},"getThemeVariables"),Vr,l0=(Vr=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=z(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=M(this.background),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=z(M("#323D47"),10),this.border1="#ccc",this.border2=ur(255,255,255,.25),this.arrowheadColor=M(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(){var r,i,s,a,o,n,l,c,h,u,d,f;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(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||z(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||b(this.primaryColor,{h:30}),this.cScale4=this.cScale4||b(this.primaryColor,{h:60}),this.cScale5=this.cScale5||b(this.primaryColor,{h:90}),this.cScale6=this.cScale6||b(this.primaryColor,{h:120}),this.cScale7=this.cScale7||b(this.primaryColor,{h:150}),this.cScale8=this.cScale8||b(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||b(this.primaryColor,{h:270}),this.cScale10=this.cScale10||b(this.primaryColor,{h:300}),this.cScale11=this.cScale11||b(this.primaryColor,{h:330}),this.darkMode)for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScale"+y]=H(this["cScale"+y],75);else for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScale"+y]=H(this["cScale"+y],25);for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScaleInv"+y]=this["cScaleInv"+y]||M(this["cScale"+y]);for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this.darkMode?this["cScalePeer"+y]=this["cScalePeer"+y]||z(this["cScale"+y],10):this["cScalePeer"+y]=this["cScalePeer"+y]||H(this["cScale"+y],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScaleLabel"+y]=this["cScaleLabel"+y]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let y=0;y<5;y++)this["surface"+y]=this["surface"+y]||b(this.mainBkg,{h:180,s:-15,l:t*(5+y*3)}),this["surfacePeer"+y]=this["surfacePeer"+y]||b(this.mainBkg,{h:180,s:-15,l:t*(8+y*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(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||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(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||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((r=this.xyChart)==null?void 0:r.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,legendTextColor:((s=this.xyChart)==null?void 0:s.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((l=this.xyChart)==null?void 0:l.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((c=this.xyChart)==null?void 0:c.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((u=this.xyChart)==null?void 0:u.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((d=this.xyChart)==null?void 0:d.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.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?H(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||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Vr,"Theme"),Vr),h0=p(e=>{const t=new l0;return t.calculate(e),t},"getThemeVariables"),Zr,c0=(Zr=class{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=Tt(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(){var a,o,n,l,c,h,u,d,f,y,m,C;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor;const t="#ECECFE",r="#E9E9F1",i=b(t,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||i,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||r,this.sectionBkgColor2=this.sectionBkgColor2||t,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||t,this.activeTaskBorderColor=this.activeTaskBorderColor||t,this.activeTaskBkgColor=this.activeTaskBkgColor||z(t,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 x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScaleInv"+x]=this["cScaleInv"+x]||M(this["cScale"+x]);for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this.darkMode?this["cScalePeer"+x]=this["cScalePeer"+x]||z(this["cScale"+x],10):this["cScalePeer"+x]=this["cScalePeer"+x]||H(this["cScale"+x],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let x=0;x<this.THEME_COLOR_LIMIT;x++)this["cScaleLabel"+x]=this["cScaleLabel"+x]||this.scaleLabelColor;const s=this.darkMode?-4:-1;for(let x=0;x<5;x++)this["surface"+x]=this["surface"+x]||b(this.mainBkg,{h:180,s:-15,l:s*(5+x*3)}),this["surfacePeer"+x]=this["surfacePeer"+x]||b(this.mainBkg,{h:180,s:-15,l:s*(8+x*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||t,this.fillType1=this.fillType1||r,this.fillType2=this.fillType2||b(t,{h:64}),this.fillType3=this.fillType3||b(r,{h:64}),this.fillType4=this.fillType4||b(t,{h:-64}),this.fillType5=this.fillType5||b(r,{h:-64}),this.fillType6=this.fillType6||b(t,{h:128}),this.fillType7=this.fillType7||b(r,{h:128}),this.pie1=this.pie1||t,this.pie2=this.pie2||r,this.pie3=this.pie3||i,this.pie4=this.pie4||b(t,{l:-10}),this.pie5=this.pie5||b(r,{l:-10}),this.pie6=this.pie6||b(i,{l:-10}),this.pie7=this.pie7||b(t,{h:60,l:-10}),this.pie8=this.pie8||b(t,{h:-60,l:-10}),this.pie9=this.pie9||b(t,{h:120,l:0}),this.pie10=this.pie10||b(t,{h:60,l:-20}),this.pie11=this.pie11||b(t,{h:-60,l:-20}),this.pie12=this.pie12||b(t,{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||t,this.quadrant2Fill=this.quadrant2Fill||b(t,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(t,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(t,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((a=this.xyChart)==null?void 0:a.backgroundColor)||this.background,titleColor:((o=this.xyChart)==null?void 0:o.titleColor)||this.primaryTextColor,legendTextColor:((n=this.xyChart)==null?void 0:n.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((l=this.xyChart)==null?void 0:l.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((c=this.xyChart)==null?void 0:c.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((h=this.xyChart)==null?void 0:h.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((u=this.xyChart)==null?void 0:u.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((d=this.xyChart)==null?void 0:d.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((f=this.xyChart)==null?void 0:f.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((y=this.xyChart)==null?void 0:y.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((m=this.xyChart)==null?void 0:m.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((C=this.xyChart)==null?void 0:C.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||t,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?H(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||t,this.git1=this.git1||r,this.git2=this.git2||i,this.git3=this.git3||b(t,{h:-30}),this.git4=this.git4||b(t,{h:-60}),this.git5=this.git5||b(t,{h:-90}),this.git6=this.git6||b(t,{h:60}),this.git7=this.git7||b(t,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Zr,"Theme"),Zr),u0=p(e=>{const t=new c0;return t.calculate(e),t},"getThemeVariables"),Kr,d0=(Kr=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=z(this.primaryColor,16),this.tertiaryColor=b(this.primaryColor,{h:-160}),this.primaryBorderColor=M(this.background),this.secondaryBorderColor=Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Tt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=z(M("#323D47"),10),this.border1="#ccc",this.border2=ur(255,255,255,.25),this.arrowheadColor=M(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(){var r,i,s,a,o,n,l,c,h,u,d,f;this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||b(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||b(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Tt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Tt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Tt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Tt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(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?H(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||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(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||z(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 y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScaleInv"+y]=this["cScaleInv"+y]||M(this["cScale"+y]);for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this.darkMode?this["cScalePeer"+y]=this["cScalePeer"+y]||z(this["cScale"+y],10):this["cScalePeer"+y]=this["cScalePeer"+y]||H(this["cScale"+y],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let y=0;y<this.THEME_COLOR_LIMIT;y++)this["cScaleLabel"+y]=H(this["cScale"+y],75);const t=this.darkMode?-4:-1;for(let y=0;y<5;y++)this["surface"+y]=this["surface"+y]||b(this.mainBkg,{h:180,s:-15,l:t*(5+y*3)}),this["surfacePeer"+y]=this["surfacePeer"+y]||b(this.mainBkg,{h:180,s:-15,l:t*(8+y*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||b(this.primaryColor,{h:64}),this.fillType3=this.fillType3||b(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||b(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||b(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||b(this.primaryColor,{h:128}),this.fillType7=this.fillType7||b(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||b(this.primaryColor,{l:-10}),this.pie5=this.pie5||b(this.secondaryColor,{l:-10}),this.pie6=this.pie6||b(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||b(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||b(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||b(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||b(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||b(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||b(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||b(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||b(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||b(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||b(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||b(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||b(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||we(this.quadrant1Fill)?z(this.quadrant1Fill):H(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:((r=this.xyChart)==null?void 0:r.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,legendTextColor:((s=this.xyChart)==null?void 0:s.legendTextColor)||this.primaryTextColor,xAxisTitleColor:((a=this.xyChart)==null?void 0:a.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((l=this.xyChart)==null?void 0:l.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((c=this.xyChart)==null?void 0:c.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((h=this.xyChart)==null?void 0:h.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((u=this.xyChart)==null?void 0:u.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((d=this.xyChart)==null?void 0:d.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((f=this.xyChart)==null?void 0:f.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?H(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||b(this.primaryColor,{h:-30}),this.git4=this.git4||b(this.primaryColor,{h:-60}),this.git5=this.git5||b(this.primaryColor,{h:-90}),this.git6=this.git6||b(this.primaryColor,{h:60}),this.git7=this.git7||b(this.primaryColor,{h:120}),this.darkMode?(this.git0=z(this.git0,25),this.git1=z(this.git1,25),this.git2=z(this.git2,25),this.git3=z(this.git3,25),this.git4=z(this.git4,25),this.git5=z(this.git5,25),this.git6=z(this.git6,25),this.git7=z(this.git7,25)):(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)),this.gitInv0=this.gitInv0||M(this.git0),this.gitInv1=this.gitInv1||M(this.git1),this.gitInv2=this.gitInv2||M(this.git2),this.gitInv3=this.gitInv3||M(this.git3),this.gitInv4=this.gitInv4||M(this.git4),this.gitInv5=this.gitInv5||M(this.git5),this.gitInv6=this.gitInv6||M(this.git6),this.gitInv7=this.gitInv7||M(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||$e,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Oe}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Kr,"Theme"),Kr),f0=p(e=>{const t=new d0;return t.calculate(e),t},"getThemeVariables"),He={base:{getThemeVariables:Xm},dark:{getThemeVariables:Vm},default:{getThemeVariables:Km},forest:{getThemeVariables:Jm},neutral:{getThemeVariables:e0},neo:{getThemeVariables:i0},"neo-dark":{getThemeVariables:a0},redux:{getThemeVariables:n0},"redux-dark":{getThemeVariables:h0},"redux-color":{getThemeVariables:u0},"redux-dark-color":{getThemeVariables:f0}},Zt={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},Lu={...Zt,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF",nodePlacementAlignment:"NONE",forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES",keepEntryNodeOnTop:!1},themeCSS:void 0,themeVariables:He.default.getThemeVariables(),sequence:{...Zt.sequence,messageFont:p(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:p(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:p(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{defaultRenderer:"dagre-wrapper",hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},gantt:{...Zt.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Zt.c4,useWidth:void 0,personFont:p(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...Zt.flowchart,inheritDir:!1},external_personFont:p(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:p(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:p(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:p(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:p(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:p(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:p(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:p(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:p(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:p(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:p(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:p(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:p(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:p(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:p(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:p(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:p(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:p(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:p(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:p(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:p(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...Zt.pie,useWidth:984},xyChart:{...Zt.xyChart,useWidth:void 0},requirement:{...Zt.requirement,useWidth:void 0},packet:{...Zt.packet},eventmodeling:{...Zt.eventmodeling},treeView:{...Zt.treeView,useWidth:void 0},radar:{...Zt.radar},railroad:{...Zt.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:{...Zt.ishikawa},sankey:{...Zt.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:{...Zt.venn},cynefin:{...Zt.cynefin}},Fu=p((e,t="")=>Object.keys(e).reduce((r,i)=>Array.isArray(e[i])?r:typeof e[i]=="object"&&e[i]!==null?[...r,t+i,...Fu(e[i],"")]:[...r,t+i],[]),"keyify"),p0=new Set(Fu(Lu,"")),Mu=Lu,g0={nodeColors:/^#[\da-f]{3,8}$|^rgb\([\d\s%,.]+\)$|^hsl\([\d\s%,.]+\)$|^[a-z]+$/i,filenameIcons:/^[\w-]+(?::[\w-]+)?$/,extensionIcons:/^[\w-]+(?::[\w-]+)?$/},y0=p((e,t)=>{for(const r of Object.keys(e)){const i=e[r];(r.startsWith("__")||r.includes("proto")||r.includes("constr")||typeof i!="string"||!t.test(i))&&(I.debug("sanitize deleting dictionary entry:",r,i),delete e[r])}},"sanitizeDictionaryConfig"),qs=p(e=>{if(I.debug("sanitizeDirective called with",e),!(typeof e!="object"||e==null)){if(Array.isArray(e)){e.forEach(t=>qs(t));return}for(const t of Object.keys(e)){if(I.debug("Checking key",t),t.startsWith("__")||t.includes("proto")||t.includes("constr")||!p0.has(t)||e[t]==null){I.debug("sanitize deleting key: ",t),delete e[t];continue}if(typeof e[t]=="object"){const i=g0[t];i?y0(e[t],i):(I.debug("sanitizing object",t),qs(e[t]));continue}const r=["themeCSS","fontFamily","altFontFamily"];for(const i of r)t.includes(i)&&(I.debug("sanitizing css option",t),e[t]=Au(e[t]))}if(e.themeVariables)for(const t of Object.keys(e.themeVariables)){const r=e.themeVariables[t];r!=null&&r.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]="")}I.debug("After sanitization",e)}},"sanitizeDirective"),Au=p(e=>{let t=0,r=0;for(const i of e){if(t<r)return"{ /* ERROR: Unbalanced CSS */ }";i==="{"?t++:i==="}"&&r++}return t!==r?"{ /* ERROR: Unbalanced CSS */ }":e},"sanitizeCss"),ii=Object.freeze(Mu),De=p(e=>!(e===!1||["false","null","0"].includes(String(e).trim().toLowerCase())),"evaluate"),ae=Vt({},ii),Ns,pr=[],qi=Vt({},ii),ss=p((e,t)=>{let r=Vt({},e),i={};for(const s of t)Ou(s),i=Vt(i,s);if(r=Vt(r,i),i.theme&&i.theme in He){const s=Vt({},Ns),a=Vt(s.themeVariables||{},i.themeVariables);r.theme&&r.theme in He&&(r.themeVariables=He[r.theme].getThemeVariables(a))}return qi=r,w0(qi),qi},"updateCurrentConfig"),m0=p(e=>(ae=Vt({},ii),ae=Vt(ae,e),e.theme&&He[e.theme]&&(ae.themeVariables=He[e.theme].getThemeVariables(e.themeVariables)),ss(ae,pr),ae),"setSiteConfig"),x0=p(e=>{Ns=Vt({},e)},"saveConfigFromInitialize"),C0=p(e=>(ae=Vt(ae,e),ss(ae,pr),ae),"updateSiteConfig"),Eu=p(()=>Vt({},ae),"getSiteConfig"),$u=p(e=>(ss(qi,[e]),Ht()),"setConfig"),Ht=p(()=>Vt({},qi),"getConfig"),Ou=p(e=>{e&&(["secure",...ae.secure??[]].forEach(t=>{Object.hasOwn(e,t)&&(I.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"&&Ou(e[t])}))},"sanitize"),b0=p(e=>{var t;qs(e),e.fontFamily&&!((t=e.themeVariables)!=null&&t.fontFamily)&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),pr.push(e),ss(ae,pr)},"addDirective"),Ws=p((e=ae)=>{pr=[],ss(e,pr)},"reset"),k0={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."},Vl={},Du=p(e=>{Vl[e]||(I.warn(k0[e]),Vl[e]=!0)},"issueWarning"),w0=p(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&Du("LAZY_LOAD_DEPRECATED")},"checkConfig"),HM=p(()=>{let e={};Ns&&(e=Vt(e,Ns));for(const t of pr)e=Vt(e,t);return e},"getUserDefinedConfig"),ee=p(e=>{var t,r;return((t=e.flowchart)==null?void 0:t.htmlLabels)!=null&&Du("FLOWCHART_HTML_LABELS_DEPRECATED"),De(e.htmlLabels??((r=e.flowchart)==null?void 0:r.htmlLabels)??!0)},"getEffectiveHtmlLabels"),Pu=/^([^\S\n\r]*)-{3}\s*[\n\r](.*?)[\n\r]\1-{3}\s*[\n\r]+/s,Ni=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,S0=/\s*%%.*\n/gm,Qr,Iu=(Qr=class extends Error{constructor(t){super(t),this.name="UnknownDiagramError"}},p(Qr,"UnknownDiagramError"),Qr),gr={},wn=p(function(e,t){e=e.replace(Pu,"").replace(Ni,"").replace(S0,`
3
+ `);for(const[r,{detector:i}]of Object.entries(gr))if(i(e,t))return r;throw new Iu(`No diagram type detected matching given configuration for text: ${e}`)},"detectType"),Mo=p((...e)=>{for(const{id:t,detector:r,loader:i}of e)Ru(t,r,i)},"registerLazyLoadedDiagrams"),Ru=p((e,t,r)=>{gr[e]&&I.warn(`Detector with key ${e} already exists. Overwriting.`),gr[e]={detector:t,loader:r},I.debug(`Detector with key ${e} added${r?" with loader":""}`)},"addDetector"),T0=p(e=>gr[e].loader,"getDiagramLoader"),as=/<br\s*\/?>/gi,_0=p(e=>e?Wu(e).replace(/\\n/g,"#br#").split("#br#"):[""],"getRows"),B0=(()=>{let e=!1;return()=>{e||(qu(),e=!0)}})();function qu(){const e="data-temp-href-target";ri.addHook("beforeSanitizeAttributes",t=>{t.tagName==="A"&&t.hasAttribute("target")&&t.setAttribute(e,t.getAttribute("target")??"")}),ri.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"))})}p(qu,"setupDompurifyHooks");var Nu=p(e=>(B0(),ri.sanitize(e)),"removeScript"),Zl=p((e,t)=>{if(ee(t)){const r=t.securityLevel;r==="antiscript"||r==="strict"||r==="sandbox"?e=Nu(e):r!=="loose"&&(e=Wu(e),e=e.replace(/</g,"&lt;").replace(/>/g,"&gt;"),e=e.replace(/=/g,"&equals;"),e=M0(e))}return e},"sanitizeMore"),de=p((e,t)=>e&&(t.dompurifyConfig?e=ri.sanitize(Zl(e,t),t.dompurifyConfig).toString():e=ri.sanitize(Zl(e,t),{FORBID_TAGS:["style"]}).toString(),e),"sanitizeText"),v0=p((e,t)=>typeof e=="string"?de(e,t):e.flat().map(r=>de(r,t)),"sanitizeTextOrArray"),L0=p(e=>as.test(e),"hasBreaks"),F0=p(e=>e.split(as),"splitBreaks"),M0=p(e=>e.replace(/#br#/g,"<br/>"),"placeholderToBreak"),Wu=p(e=>e.replace(as,"#br#"),"breakToPlaceholder"),A0=p(e=>{let t="";return e&&(t=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},"getUrl"),E0=p(function(...e){const t=e.filter(r=>!isNaN(r));return Math.max(...t)},"getMax"),$0=p(function(...e){const t=e.filter(r=>!isNaN(r));return Math.min(...t)},"getMin"),Kl=p(function(e){const t=e.split(/(,)/),r=[];for(let i=0;i<t.length;i++){let s=t[i];if(s===","&&i>0&&i+1<t.length){const a=t[i-1],o=t[i+1];O0(a,o)&&(s=a+","+o,i++,r.pop())}r.push(D0(s))}return r.join("")},"parseGenericTypes"),Ao=p((e,t)=>Math.max(0,e.split(t).length-1),"countOccurrence"),O0=p((e,t)=>{const r=Ao(e,"~"),i=Ao(t,"~");return r===1&&i===1},"shouldCombineSets"),D0=p(e=>{const t=Ao(e,"~");let r=!1;if(t<=1)return e;t%2!==0&&e.startsWith("~")&&(e=e.substring(1),r=!0);const i=[...e];let s=i.indexOf("~"),a=i.lastIndexOf("~");for(;s!==-1&&a!==-1&&s!==a;)i[s]="<",i[a]=">",s=i.indexOf("~"),a=i.lastIndexOf("~");return r&&i.unshift("~"),i.join("")},"processSet"),Ql=p(()=>window.MathMLElement!==void 0,"isMathMLSupported"),Eo=/\$\$(.*?)\$\$/g,Ui=p(e=>{var t;return(((t=e.match(Eo))==null?void 0:t.length)??0)>0},"hasKatex"),YM=p(async(e,t)=>{const r=document.createElement("div");r.innerHTML=await zu(e,t),r.id="katex-temp",r.style.visibility="hidden",r.style.position="absolute",r.style.top="0";const i=document.querySelector("body");i==null||i.insertAdjacentElement("beforeend",r);const s={width:r.clientWidth,height:r.clientHeight};return r.remove(),s},"calculateMathMLDimensions"),P0=p(async(e,t)=>{if(!Ui(e))return e;if(!(Ql()||t.legacyMathML||t.forceLegacyMathML))return e.replace(Eo,"MathML is unsupported in this environment.");{const{default:r}=await Ft(async()=>{const{default:s}=await import("./katex-C5jXJg4s.js");return{default:s}},[],import.meta.url),i=t.forceLegacyMathML||!Ql()&&t.legacyMathML?"htmlAndMathml":"mathml";return e.split(as).map(s=>Ui(s)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${s}</div>`:`<div>${s}</div>`).join("").replace(Eo,(s,a)=>r.renderToString(a,{throwOnError:!0,displayMode:!0,output:i}).replace(/\n/g," ").replace(/<annotation.*<\/annotation>/g,""))}},"renderKatexUnsanitized"),zu=p(async(e,t)=>de(await P0(e,t),t),"renderKatexSanitized"),os={getRows:_0,sanitizeText:de,sanitizeTextOrArray:v0,hasBreaks:L0,splitBreaks:F0,lineBreakRegex:as,removeScript:Nu,getUrl:A0,evaluate:De,getMax:E0,getMin:$0},I0=p(function(e,t){for(let r of t)e.attr(r[0],r[1])},"d3Attrs"),R0=p(function(e,t,r){let i=new Map;return r?(i.set("width","100%"),i.set("style",`max-width: ${t}px;`)):(i.set("height",e),i.set("width",t)),i},"calculateSvgSizeAttrs"),Hu=p(function(e,t,r,i){const s=R0(t,r,i);I0(e,s)},"configureSvgSize"),q0=p(function(e,t,r,i){const s=t.node().getBBox(),a=s.width,o=s.height;I.info(`SVG bounds: ${a}x${o}`,s);let n=0,l=0;I.info(`Graph bounds: ${n}x${l}`,e),n=a+r*2,l=o+r*2,I.info(`Calculated bounds: ${n}x${l}`),Hu(t,l,n,i);const c=`${s.x-r} ${s.y-r} ${s.width+2*r} ${s.height+2*r}`;t.attr("viewBox",c)},"setupGraphViewbox"),Ms={};function $o(e){return[...e.cssRules].map(t=>t.cssText).join(`
4
+ `)}p($o,"cssStyleSheetToString");var N0=p((e,t,r,i)=>{let s="";return e in Ms&&Ms[e]?s=Ms[e]({...r,svgId:i}):I.warn(`No theme found for ${e}`),`& {
5
+ font-family: ${r.fontFamily};
6
+ font-size: ${r.fontSize};
7
+ fill: ${r.textColor}
8
+ }
9
+ @keyframes edge-animation-frame {
10
+ from {
11
+ stroke-dashoffset: 0;
12
+ }
13
+ }
14
+ @keyframes dash {
15
+ to {
16
+ stroke-dashoffset: 0;
17
+ }
18
+ }
19
+ & .edge-animation-slow {
20
+ stroke-dasharray: 9,5 !important;
21
+ stroke-dashoffset: 900;
22
+ animation: dash 50s linear infinite;
23
+ stroke-linecap: round;
24
+ }
25
+ & .edge-animation-fast {
26
+ stroke-dasharray: 9,5 !important;
27
+ stroke-dashoffset: 900;
28
+ animation: dash 20s linear infinite;
29
+ stroke-linecap: round;
30
+ }
31
+ /* Classes common for multiple diagrams */
32
+
33
+ & .error-icon {
34
+ fill: ${r.errorBkgColor};
35
+ }
36
+ & .error-text {
37
+ fill: ${r.errorTextColor};
38
+ stroke: ${r.errorTextColor};
39
+ }
40
+
41
+ & .edge-thickness-normal {
42
+ stroke-width: ${r.strokeWidth??1}px;
43
+ }
44
+ & .edge-thickness-thick {
45
+ stroke-width: 3.5px
46
+ }
47
+ & .edge-pattern-solid {
48
+ stroke-dasharray: 0;
49
+ }
50
+ & .edge-thickness-invisible {
51
+ stroke-width: 0;
52
+ fill: none;
53
+ }
54
+ & .edge-pattern-dashed{
55
+ stroke-dasharray: 3;
56
+ }
57
+ .edge-pattern-dotted {
58
+ stroke-dasharray: 2;
59
+ }
60
+
61
+ & .marker {
62
+ fill: ${r.lineColor};
63
+ stroke: ${r.lineColor};
64
+ }
65
+ & .marker.cross {
66
+ stroke: ${r.lineColor};
67
+ }
68
+
69
+ & svg {
70
+ font-family: ${r.fontFamily};
71
+ font-size: ${r.fontSize};
72
+ }
73
+ & p {
74
+ margin: 0
75
+ }
76
+
77
+ ${s}
78
+ .node .neo-node {
79
+ stroke: ${r.nodeBorder};
80
+ }
81
+
82
+ [data-look="neo"].node rect, [data-look="neo"].cluster rect, [data-look="neo"].node polygon {
83
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
84
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
85
+ }
86
+ [data-look="neo"].swimlane.cluster rect {
87
+ filter: none;
88
+ }
89
+
90
+
91
+ [data-look="neo"].node path {
92
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
93
+ stroke-width: ${r.strokeWidth??1}px;
94
+ }
95
+
96
+ [data-look="neo"].node .outer-path {
97
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
98
+ }
99
+
100
+ [data-look="neo"].node .neo-line path {
101
+ stroke: ${r.nodeBorder};
102
+ filter: none;
103
+ }
104
+
105
+ [data-look="neo"].node circle{
106
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
107
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
108
+ }
109
+
110
+ [data-look="neo"].node circle .state-start{
111
+ fill: #000000;
112
+ }
113
+
114
+ [data-look="neo"].icon-shape .icon {
115
+ fill: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
116
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
117
+ }
118
+
119
+ [data-look="neo"].icon-shape .icon-neo path {
120
+ stroke: ${r.useGradient?"url("+i+"-gradient)":r.nodeBorder};
121
+ filter: ${r.dropShadow?r.dropShadow.replace("url(#drop-shadow)",`url(${i}-drop-shadow)`):"none"};
122
+ }
123
+
124
+ ${t}
125
+ `},"getStyles"),W0=p((e,t)=>{t!==void 0&&(Ms[e]=t)},"addStylesForDiagram"),z0=N0,Yu={};Hm(Yu,{clear:()=>H0,getAccDescription:()=>X0,getAccTitle:()=>j0,getDiagramTitle:()=>V0,setAccDescription:()=>U0,setAccTitle:()=>Y0,setDiagramTitle:()=>G0});var Sn="",Tn="",_n="",Bn=p(e=>de(e,Ht()),"sanitizeText"),H0=p(()=>{Sn="",_n="",Tn=""},"clear"),Y0=p(e=>{Sn=Bn(e).replace(/^\s+/g,"")},"setAccTitle"),j0=p(()=>Sn,"getAccTitle"),U0=p(e=>{_n=Bn(e).replace(/\n\s+/g,`
126
+ `)},"setAccDescription"),X0=p(()=>_n,"getAccDescription"),G0=p(e=>{Tn=Bn(e)},"setDiagramTitle"),V0=p(()=>Tn,"getDiagramTitle"),Jl=I,Z0=kn,At=Ht,jM=$u,UM=ii,vn=p(e=>de(e,At()),"sanitizeText"),K0=q0,Q0=p(()=>Yu,"getCommonDb"),zs={},Hs=p((e,t,r)=>{var i;zs[e]&&Jl.warn(`Diagram with id ${e} already registered. Overwriting.`),zs[e]=t,r&&Ru(e,r),W0(e,t.styles),(i=t.injectUtils)==null||i.call(t,Jl,Z0,At,vn,K0,Q0(),()=>{})},"registerDiagram"),Oo=p(e=>{if(e in zs)return zs[e];throw new J0(e)},"getDiagram"),Jr,J0=(Jr=class extends Error{constructor(t){super(`Diagram ${t} not found.`)}},p(Jr,"DiagramNotFoundError"),Jr),tx={value:()=>{}};function ju(){for(var e=0,t=arguments.length,r={},i;e<t;++e){if(!(i=arguments[e]+"")||i in r||/[\s.]/.test(i))throw new Error("illegal type: "+i);r[i]=[]}return new As(r)}function As(e){this._=e}function ex(e,t){return e.trim().split(/^|\s+/).map(function(r){var i="",s=r.indexOf(".");if(s>=0&&(i=r.slice(s+1),r=r.slice(0,s)),r&&!t.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:i}})}As.prototype=ju.prototype={constructor:As,on:function(e,t){var r=this._,i=ex(e+"",r),s,a=-1,o=i.length;if(arguments.length<2){for(;++a<o;)if((s=(e=i[a]).type)&&(s=rx(r[s],e.name)))return s;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++a<o;)if(s=(e=i[a]).type)r[s]=th(r[s],e.name,t);else if(t==null)for(s in r)r[s]=th(r[s],e.name,null);return this},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new As(e)},call:function(e,t){if((s=arguments.length-2)>0)for(var r=new Array(s),i=0,s,a;i<s;++i)r[i]=arguments[i+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(a=this._[e],i=0,s=a.length;i<s;++i)a[i].value.apply(t,r)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var i=this._[e],s=0,a=i.length;s<a;++s)i[s].value.apply(t,r)}};function rx(e,t){for(var r=0,i=e.length,s;r<i;++r)if((s=e[r]).name===t)return s.value}function th(e,t,r){for(var i=0,s=e.length;i<s;++i)if(e[i].name===t){e[i]=tx,e=e.slice(0,i).concat(e.slice(i+1));break}return r!=null&&e.push({name:t,value:r}),e}var Do="http://www.w3.org/1999/xhtml";const eh={svg:"http://www.w3.org/2000/svg",xhtml:Do,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function da(e){var t=e+="",r=t.indexOf(":");return r>=0&&(t=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),eh.hasOwnProperty(t)?{space:eh[t],local:e}:e}function ix(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===Do&&t.documentElement.namespaceURI===Do?t.createElement(e):t.createElementNS(r,e)}}function sx(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function Uu(e){var t=da(e);return(t.local?sx:ix)(t)}function ax(){}function Ln(e){return e==null?ax:function(){return this.querySelector(e)}}function ox(e){typeof e!="function"&&(e=Ln(e));for(var t=this._groups,r=t.length,i=new Array(r),s=0;s<r;++s)for(var a=t[s],o=a.length,n=i[s]=new Array(o),l,c,h=0;h<o;++h)(l=a[h])&&(c=e.call(l,l.__data__,h,a))&&("__data__"in l&&(c.__data__=l.__data__),n[h]=c);return new ce(i,this._parents)}function nx(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function lx(){return[]}function Xu(e){return e==null?lx:function(){return this.querySelectorAll(e)}}function hx(e){return function(){return nx(e.apply(this,arguments))}}function cx(e){typeof e=="function"?e=hx(e):e=Xu(e);for(var t=this._groups,r=t.length,i=[],s=[],a=0;a<r;++a)for(var o=t[a],n=o.length,l,c=0;c<n;++c)(l=o[c])&&(i.push(e.call(l,l.__data__,c,o)),s.push(l));return new ce(i,s)}function Gu(e){return function(){return this.matches(e)}}function Vu(e){return function(t){return t.matches(e)}}var ux=Array.prototype.find;function dx(e){return function(){return ux.call(this.children,e)}}function fx(){return this.firstElementChild}function px(e){return this.select(e==null?fx:dx(typeof e=="function"?e:Vu(e)))}var gx=Array.prototype.filter;function yx(){return Array.from(this.children)}function mx(e){return function(){return gx.call(this.children,e)}}function xx(e){return this.selectAll(e==null?yx:mx(typeof e=="function"?e:Vu(e)))}function Cx(e){typeof e!="function"&&(e=Gu(e));for(var t=this._groups,r=t.length,i=new Array(r),s=0;s<r;++s)for(var a=t[s],o=a.length,n=i[s]=[],l,c=0;c<o;++c)(l=a[c])&&e.call(l,l.__data__,c,a)&&n.push(l);return new ce(i,this._parents)}function Zu(e){return new Array(e.length)}function bx(){return new ce(this._enter||this._groups.map(Zu),this._parents)}function Ys(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Ys.prototype={constructor:Ys,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function kx(e){return function(){return e}}function wx(e,t,r,i,s,a){for(var o=0,n,l=t.length,c=a.length;o<c;++o)(n=t[o])?(n.__data__=a[o],i[o]=n):r[o]=new Ys(e,a[o]);for(;o<l;++o)(n=t[o])&&(s[o]=n)}function Sx(e,t,r,i,s,a,o){var n,l,c=new Map,h=t.length,u=a.length,d=new Array(h),f;for(n=0;n<h;++n)(l=t[n])&&(d[n]=f=o.call(l,l.__data__,n,t)+"",c.has(f)?s[n]=l:c.set(f,l));for(n=0;n<u;++n)f=o.call(e,a[n],n,a)+"",(l=c.get(f))?(i[n]=l,l.__data__=a[n],c.delete(f)):r[n]=new Ys(e,a[n]);for(n=0;n<h;++n)(l=t[n])&&c.get(d[n])===l&&(s[n]=l)}function Tx(e){return e.__data__}function _x(e,t){if(!arguments.length)return Array.from(this,Tx);var r=t?Sx:wx,i=this._parents,s=this._groups;typeof e!="function"&&(e=kx(e));for(var a=s.length,o=new Array(a),n=new Array(a),l=new Array(a),c=0;c<a;++c){var h=i[c],u=s[c],d=u.length,f=Bx(e.call(h,h&&h.__data__,c,i)),y=f.length,m=n[c]=new Array(y),C=o[c]=new Array(y),x=l[c]=new Array(d);r(h,u,m,C,x,f,t);for(var k=0,w=0,T,_;k<y;++k)if(T=m[k]){for(k>=w&&(w=k+1);!(_=C[w])&&++w<y;);T._next=_||null}}return o=new ce(o,i),o._enter=n,o._exit=l,o}function Bx(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function vx(){return new ce(this._exit||this._groups.map(Zu),this._parents)}function Lx(e,t,r){var i=this.enter(),s=this,a=this.exit();return typeof e=="function"?(i=e(i),i&&(i=i.selection())):i=i.append(e+""),t!=null&&(s=t(s),s&&(s=s.selection())),r==null?a.remove():r(a),i&&s?i.merge(s).order():s}function Fx(e){for(var t=e.selection?e.selection():e,r=this._groups,i=t._groups,s=r.length,a=i.length,o=Math.min(s,a),n=new Array(s),l=0;l<o;++l)for(var c=r[l],h=i[l],u=c.length,d=n[l]=new Array(u),f,y=0;y<u;++y)(f=c[y]||h[y])&&(d[y]=f);for(;l<s;++l)n[l]=r[l];return new ce(n,this._parents)}function Mx(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var i=e[t],s=i.length-1,a=i[s],o;--s>=0;)(o=i[s])&&(a&&o.compareDocumentPosition(a)^4&&a.parentNode.insertBefore(o,a),a=o);return this}function Ax(e){e||(e=Ex);function t(u,d){return u&&d?e(u.__data__,d.__data__):!u-!d}for(var r=this._groups,i=r.length,s=new Array(i),a=0;a<i;++a){for(var o=r[a],n=o.length,l=s[a]=new Array(n),c,h=0;h<n;++h)(c=o[h])&&(l[h]=c);l.sort(t)}return new ce(s,this._parents).order()}function Ex(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function $x(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function Ox(){return Array.from(this)}function Dx(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var i=e[t],s=0,a=i.length;s<a;++s){var o=i[s];if(o)return o}return null}function Px(){let e=0;for(const t of this)++e;return e}function Ix(){return!this.node()}function Rx(e){for(var t=this._groups,r=0,i=t.length;r<i;++r)for(var s=t[r],a=0,o=s.length,n;a<o;++a)(n=s[a])&&e.call(n,n.__data__,a,s);return this}function qx(e){return function(){this.removeAttribute(e)}}function Nx(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Wx(e,t){return function(){this.setAttribute(e,t)}}function zx(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function Hx(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function Yx(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function jx(e,t){var r=da(e);if(arguments.length<2){var i=this.node();return r.local?i.getAttributeNS(r.space,r.local):i.getAttribute(r)}return this.each((t==null?r.local?Nx:qx:typeof t=="function"?r.local?Yx:Hx:r.local?zx:Wx)(r,t))}function Ku(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function Ux(e){return function(){this.style.removeProperty(e)}}function Xx(e,t,r){return function(){this.style.setProperty(e,t,r)}}function Gx(e,t,r){return function(){var i=t.apply(this,arguments);i==null?this.style.removeProperty(e):this.style.setProperty(e,i,r)}}function Vx(e,t,r){return arguments.length>1?this.each((t==null?Ux:typeof t=="function"?Gx:Xx)(e,t,r??"")):si(this.node(),e)}function si(e,t){return e.style.getPropertyValue(t)||Ku(e).getComputedStyle(e,null).getPropertyValue(t)}function Zx(e){return function(){delete this[e]}}function Kx(e,t){return function(){this[e]=t}}function Qx(e,t){return function(){var r=t.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function Jx(e,t){return arguments.length>1?this.each((t==null?Zx:typeof t=="function"?Qx:Kx)(e,t)):this.node()[e]}function Qu(e){return e.trim().split(/^|\s+/)}function Fn(e){return e.classList||new Ju(e)}function Ju(e){this._node=e,this._names=Qu(e.getAttribute("class")||"")}Ju.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function td(e,t){for(var r=Fn(e),i=-1,s=t.length;++i<s;)r.add(t[i])}function ed(e,t){for(var r=Fn(e),i=-1,s=t.length;++i<s;)r.remove(t[i])}function tC(e){return function(){td(this,e)}}function eC(e){return function(){ed(this,e)}}function rC(e,t){return function(){(t.apply(this,arguments)?td:ed)(this,e)}}function iC(e,t){var r=Qu(e+"");if(arguments.length<2){for(var i=Fn(this.node()),s=-1,a=r.length;++s<a;)if(!i.contains(r[s]))return!1;return!0}return this.each((typeof t=="function"?rC:t?tC:eC)(r,t))}function sC(){this.textContent=""}function aC(e){return function(){this.textContent=e}}function oC(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function nC(e){return arguments.length?this.each(e==null?sC:(typeof e=="function"?oC:aC)(e)):this.node().textContent}function lC(){this.innerHTML=""}function hC(e){return function(){this.innerHTML=e}}function cC(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function uC(e){return arguments.length?this.each(e==null?lC:(typeof e=="function"?cC:hC)(e)):this.node().innerHTML}function dC(){this.nextSibling&&this.parentNode.appendChild(this)}function fC(){return this.each(dC)}function pC(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function gC(){return this.each(pC)}function yC(e){var t=typeof e=="function"?e:Uu(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function mC(){return null}function xC(e,t){var r=typeof e=="function"?e:Uu(e),i=t==null?mC:typeof t=="function"?t:Ln(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),i.apply(this,arguments)||null)})}function CC(){var e=this.parentNode;e&&e.removeChild(this)}function bC(){return this.each(CC)}function kC(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function wC(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function SC(e){return this.select(e?wC:kC)}function TC(e){return arguments.length?this.property("__data__",e):this.node().__data__}function _C(e){return function(t){e.call(this,t,this.__data__)}}function BC(e){return e.trim().split(/^|\s+/).map(function(t){var r="",i=t.indexOf(".");return i>=0&&(r=t.slice(i+1),t=t.slice(0,i)),{type:t,name:r}})}function vC(e){return function(){var t=this.__on;if(t){for(var r=0,i=-1,s=t.length,a;r<s;++r)a=t[r],(!e.type||a.type===e.type)&&a.name===e.name?this.removeEventListener(a.type,a.listener,a.options):t[++i]=a;++i?t.length=i:delete this.__on}}}function LC(e,t,r){return function(){var i=this.__on,s,a=_C(t);if(i){for(var o=0,n=i.length;o<n;++o)if((s=i[o]).type===e.type&&s.name===e.name){this.removeEventListener(s.type,s.listener,s.options),this.addEventListener(s.type,s.listener=a,s.options=r),s.value=t;return}}this.addEventListener(e.type,a,r),s={type:e.type,name:e.name,value:t,listener:a,options:r},i?i.push(s):this.__on=[s]}}function FC(e,t,r){var i=BC(e+""),s,a=i.length,o;if(arguments.length<2){var n=this.node().__on;if(n){for(var l=0,c=n.length,h;l<c;++l)for(s=0,h=n[l];s<a;++s)if((o=i[s]).type===h.type&&o.name===h.name)return h.value}return}for(n=t?LC:vC,s=0;s<a;++s)this.each(n(i[s],t,r));return this}function rd(e,t,r){var i=Ku(e),s=i.CustomEvent;typeof s=="function"?s=new s(t,r):(s=i.document.createEvent("Event"),r?(s.initEvent(t,r.bubbles,r.cancelable),s.detail=r.detail):s.initEvent(t,!1,!1)),e.dispatchEvent(s)}function MC(e,t){return function(){return rd(this,e,t)}}function AC(e,t){return function(){return rd(this,e,t.apply(this,arguments))}}function EC(e,t){return this.each((typeof t=="function"?AC:MC)(e,t))}function*$C(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var i=e[t],s=0,a=i.length,o;s<a;++s)(o=i[s])&&(yield o)}var id=[null];function ce(e,t){this._groups=e,this._parents=t}function ns(){return new ce([[document.documentElement]],id)}function OC(){return this}ce.prototype=ns.prototype={constructor:ce,select:ox,selectAll:cx,selectChild:px,selectChildren:xx,filter:Cx,data:_x,enter:bx,exit:vx,join:Lx,merge:Fx,selection:OC,order:Mx,sort:Ax,call:$x,nodes:Ox,node:Dx,size:Px,empty:Ix,each:Rx,attr:jx,style:Vx,property:Jx,classed:iC,text:nC,html:uC,raise:fC,lower:gC,append:yC,insert:xC,remove:bC,clone:SC,datum:TC,on:FC,dispatch:EC,[Symbol.iterator]:$C};function Lt(e){return typeof e=="string"?new ce([[document.querySelector(e)]],[document.documentElement]):new ce([[e]],id)}function Mn(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function sd(e,t){var r=Object.create(e.prototype);for(var i in t)r[i]=t[i];return r}function ls(){}var Xi=.7,js=1/Xi,Rr="\\s*([+-]?\\d+)\\s*",Gi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ae="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",DC=/^#([0-9a-f]{3,8})$/,PC=new RegExp(`^rgb\\(${Rr},${Rr},${Rr}\\)$`),IC=new RegExp(`^rgb\\(${Ae},${Ae},${Ae}\\)$`),RC=new RegExp(`^rgba\\(${Rr},${Rr},${Rr},${Gi}\\)$`),qC=new RegExp(`^rgba\\(${Ae},${Ae},${Ae},${Gi}\\)$`),NC=new RegExp(`^hsl\\(${Gi},${Ae},${Ae}\\)$`),WC=new RegExp(`^hsla\\(${Gi},${Ae},${Ae},${Gi}\\)$`),rh={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Mn(ls,Vi,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:ih,formatHex:ih,formatHex8:zC,formatHsl:HC,formatRgb:sh,toString:sh});function ih(){return this.rgb().formatHex()}function zC(){return this.rgb().formatHex8()}function HC(){return ad(this).formatHsl()}function sh(){return this.rgb().formatRgb()}function Vi(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=DC.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?ah(t):r===3?new oe(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?ds(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?ds(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=PC.exec(e))?new oe(t[1],t[2],t[3],1):(t=IC.exec(e))?new oe(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=RC.exec(e))?ds(t[1],t[2],t[3],t[4]):(t=qC.exec(e))?ds(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=NC.exec(e))?lh(t[1],t[2]/100,t[3]/100,1):(t=WC.exec(e))?lh(t[1],t[2]/100,t[3]/100,t[4]):rh.hasOwnProperty(e)?ah(rh[e]):e==="transparent"?new oe(NaN,NaN,NaN,0):null}function ah(e){return new oe(e>>16&255,e>>8&255,e&255,1)}function ds(e,t,r,i){return i<=0&&(e=t=r=NaN),new oe(e,t,r,i)}function YC(e){return e instanceof ls||(e=Vi(e)),e?(e=e.rgb(),new oe(e.r,e.g,e.b,e.opacity)):new oe}function Po(e,t,r,i){return arguments.length===1?YC(e):new oe(e,t,r,i??1)}function oe(e,t,r,i){this.r=+e,this.g=+t,this.b=+r,this.opacity=+i}Mn(oe,Po,sd(ls,{brighter(e){return e=e==null?js:Math.pow(js,e),new oe(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Xi:Math.pow(Xi,e),new oe(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new oe(dr(this.r),dr(this.g),dr(this.b),Us(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:oh,formatHex:oh,formatHex8:jC,formatRgb:nh,toString:nh}));function oh(){return`#${hr(this.r)}${hr(this.g)}${hr(this.b)}`}function jC(){return`#${hr(this.r)}${hr(this.g)}${hr(this.b)}${hr((isNaN(this.opacity)?1:this.opacity)*255)}`}function nh(){const e=Us(this.opacity);return`${e===1?"rgb(":"rgba("}${dr(this.r)}, ${dr(this.g)}, ${dr(this.b)}${e===1?")":`, ${e})`}`}function Us(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function dr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function hr(e){return e=dr(e),(e<16?"0":"")+e.toString(16)}function lh(e,t,r,i){return i<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new be(e,t,r,i)}function ad(e){if(e instanceof be)return new be(e.h,e.s,e.l,e.opacity);if(e instanceof ls||(e=Vi(e)),!e)return new be;if(e instanceof be)return e;e=e.rgb();var t=e.r/255,r=e.g/255,i=e.b/255,s=Math.min(t,r,i),a=Math.max(t,r,i),o=NaN,n=a-s,l=(a+s)/2;return n?(t===a?o=(r-i)/n+(r<i)*6:r===a?o=(i-t)/n+2:o=(t-r)/n+4,n/=l<.5?a+s:2-a-s,o*=60):n=l>0&&l<1?0:o,new be(o,n,l,e.opacity)}function UC(e,t,r,i){return arguments.length===1?ad(e):new be(e,t,r,i??1)}function be(e,t,r,i){this.h=+e,this.s=+t,this.l=+r,this.opacity=+i}Mn(be,UC,sd(ls,{brighter(e){return e=e==null?js:Math.pow(js,e),new be(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Xi:Math.pow(Xi,e),new be(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,i=r+(r<.5?r:1-r)*t,s=2*r-i;return new oe(Ia(e>=240?e-240:e+120,s,i),Ia(e,s,i),Ia(e<120?e+240:e-120,s,i),this.opacity)},clamp(){return new be(hh(this.h),fs(this.s),fs(this.l),Us(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Us(this.opacity);return`${e===1?"hsl(":"hsla("}${hh(this.h)}, ${fs(this.s)*100}%, ${fs(this.l)*100}%${e===1?")":`, ${e})`}`}}));function hh(e){return e=(e||0)%360,e<0?e+360:e}function fs(e){return Math.max(0,Math.min(1,e||0))}function Ia(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const An=e=>()=>e;function od(e,t){return function(r){return e+r*t}}function XC(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(i){return Math.pow(e+i*t,r)}}function XM(e,t){var r=t-e;return r?od(e,r>180||r<-180?r-360*Math.round(r/360):r):An(isNaN(e)?t:e)}function GC(e){return(e=+e)==1?nd:function(t,r){return r-t?XC(t,r,e):An(isNaN(t)?r:t)}}function nd(e,t){var r=t-e;return r?od(e,r):An(isNaN(e)?t:e)}const ch=(function e(t){var r=GC(t);function i(s,a){var o=r((s=Po(s)).r,(a=Po(a)).r),n=r(s.g,a.g),l=r(s.b,a.b),c=nd(s.opacity,a.opacity);return function(h){return s.r=o(h),s.g=n(h),s.b=l(h),s.opacity=c(h),s+""}}return i.gamma=e,i})(1);function Ke(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}var Io=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Ra=new RegExp(Io.source,"g");function VC(e){return function(){return e}}function ZC(e){return function(t){return e(t)+""}}function KC(e,t){var r=Io.lastIndex=Ra.lastIndex=0,i,s,a,o=-1,n=[],l=[];for(e=e+"",t=t+"";(i=Io.exec(e))&&(s=Ra.exec(t));)(a=s.index)>r&&(a=t.slice(r,a),n[o]?n[o]+=a:n[++o]=a),(i=i[0])===(s=s[0])?n[o]?n[o]+=s:n[++o]=s:(n[++o]=null,l.push({i:o,x:Ke(i,s)})),r=Ra.lastIndex;return r<t.length&&(a=t.slice(r),n[o]?n[o]+=a:n[++o]=a),n.length<2?l[0]?ZC(l[0].x):VC(t):(t=l.length,function(c){for(var h=0,u;h<t;++h)n[(u=l[h]).i]=u.x(c);return n.join("")})}var uh=180/Math.PI,Ro={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function ld(e,t,r,i,s,a){var o,n,l;return(o=Math.sqrt(e*e+t*t))&&(e/=o,t/=o),(l=e*r+t*i)&&(r-=e*l,i-=t*l),(n=Math.sqrt(r*r+i*i))&&(r/=n,i/=n,l/=n),e*i<t*r&&(e=-e,t=-t,l=-l,o=-o),{translateX:s,translateY:a,rotate:Math.atan2(t,e)*uh,skewX:Math.atan(l)*uh,scaleX:o,scaleY:n}}var ps;function QC(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Ro:ld(t.a,t.b,t.c,t.d,t.e,t.f)}function JC(e){return e==null||(ps||(ps=document.createElementNS("http://www.w3.org/2000/svg","g")),ps.setAttribute("transform",e),!(e=ps.transform.baseVal.consolidate()))?Ro:(e=e.matrix,ld(e.a,e.b,e.c,e.d,e.e,e.f))}function hd(e,t,r,i){function s(c){return c.length?c.pop()+" ":""}function a(c,h,u,d,f,y){if(c!==u||h!==d){var m=f.push("translate(",null,t,null,r);y.push({i:m-4,x:Ke(c,u)},{i:m-2,x:Ke(h,d)})}else(u||d)&&f.push("translate("+u+t+d+r)}function o(c,h,u,d){c!==h?(c-h>180?h+=360:h-c>180&&(c+=360),d.push({i:u.push(s(u)+"rotate(",null,i)-2,x:Ke(c,h)})):h&&u.push(s(u)+"rotate("+h+i)}function n(c,h,u,d){c!==h?d.push({i:u.push(s(u)+"skewX(",null,i)-2,x:Ke(c,h)}):h&&u.push(s(u)+"skewX("+h+i)}function l(c,h,u,d,f,y){if(c!==u||h!==d){var m=f.push(s(f)+"scale(",null,",",null,")");y.push({i:m-4,x:Ke(c,u)},{i:m-2,x:Ke(h,d)})}else(u!==1||d!==1)&&f.push(s(f)+"scale("+u+","+d+")")}return function(c,h){var u=[],d=[];return c=e(c),h=e(h),a(c.translateX,c.translateY,h.translateX,h.translateY,u,d),o(c.rotate,h.rotate,u,d),n(c.skewX,h.skewX,u,d),l(c.scaleX,c.scaleY,h.scaleX,h.scaleY,u,d),c=h=null,function(f){for(var y=-1,m=d.length,C;++y<m;)u[(C=d[y]).i]=C.x(f);return u.join("")}}}var tb=hd(QC,"px, ","px)","deg)"),eb=hd(JC,", ",")",")"),ai=0,Mi=0,ki=0,cd=1e3,Xs,Ai,Gs=0,yr=0,fa=0,Zi=typeof performance=="object"&&performance.now?performance:Date,ud=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function En(){return yr||(ud(rb),yr=Zi.now()+fa)}function rb(){yr=0}function Vs(){this._call=this._time=this._next=null}Vs.prototype=dd.prototype={constructor:Vs,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?En():+r)+(t==null?0:+t),!this._next&&Ai!==this&&(Ai?Ai._next=this:Xs=this,Ai=this),this._call=e,this._time=r,qo()},stop:function(){this._call&&(this._call=null,this._time=1/0,qo())}};function dd(e,t,r){var i=new Vs;return i.restart(e,t,r),i}function ib(){En(),++ai;for(var e=Xs,t;e;)(t=yr-e._time)>=0&&e._call.call(void 0,t),e=e._next;--ai}function dh(){yr=(Gs=Zi.now())+fa,ai=Mi=0;try{ib()}finally{ai=0,ab(),yr=0}}function sb(){var e=Zi.now(),t=e-Gs;t>cd&&(fa-=t,Gs=e)}function ab(){for(var e,t=Xs,r,i=1/0;t;)t._call?(i>t._time&&(i=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:Xs=r);Ai=e,qo(i)}function qo(e){if(!ai){Mi&&(Mi=clearTimeout(Mi));var t=e-yr;t>24?(e<1/0&&(Mi=setTimeout(dh,e-Zi.now()-fa)),ki&&(ki=clearInterval(ki))):(ki||(Gs=Zi.now(),ki=setInterval(sb,cd)),ai=1,ud(dh))}}function fh(e,t,r){var i=new Vs;return t=t==null?0:+t,i.restart(s=>{i.stop(),e(s+t)},t,r),i}var ob=ju("start","end","cancel","interrupt"),nb=[],fd=0,ph=1,No=2,Es=3,gh=4,Wo=5,$s=6;function pa(e,t,r,i,s,a){var o=e.__transition;if(!o)e.__transition={};else if(r in o)return;lb(e,r,{name:t,index:i,group:s,on:ob,tween:nb,time:a.time,delay:a.delay,duration:a.duration,ease:a.ease,timer:null,state:fd})}function $n(e,t){var r=Se(e,t);if(r.state>fd)throw new Error("too late; already scheduled");return r}function Pe(e,t){var r=Se(e,t);if(r.state>Es)throw new Error("too late; already running");return r}function Se(e,t){var r=e.__transition;if(!r||!(r=r[t]))throw new Error("transition not found");return r}function lb(e,t,r){var i=e.__transition,s;i[t]=r,r.timer=dd(a,0,r.time);function a(c){r.state=ph,r.timer.restart(o,r.delay,r.time),r.delay<=c&&o(c-r.delay)}function o(c){var h,u,d,f;if(r.state!==ph)return l();for(h in i)if(f=i[h],f.name===r.name){if(f.state===Es)return fh(o);f.state===gh?(f.state=$s,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete i[h]):+h<t&&(f.state=$s,f.timer.stop(),f.on.call("cancel",e,e.__data__,f.index,f.group),delete i[h])}if(fh(function(){r.state===Es&&(r.state=gh,r.timer.restart(n,r.delay,r.time),n(c))}),r.state=No,r.on.call("start",e,e.__data__,r.index,r.group),r.state===No){for(r.state=Es,s=new Array(d=r.tween.length),h=0,u=-1;h<d;++h)(f=r.tween[h].value.call(e,e.__data__,r.index,r.group))&&(s[++u]=f);s.length=u+1}}function n(c){for(var h=c<r.duration?r.ease.call(null,c/r.duration):(r.timer.restart(l),r.state=Wo,1),u=-1,d=s.length;++u<d;)s[u].call(e,h);r.state===Wo&&(r.on.call("end",e,e.__data__,r.index,r.group),l())}function l(){r.state=$s,r.timer.stop(),delete i[t];for(var c in i)return;delete e.__transition}}function hb(e,t){var r=e.__transition,i,s,a=!0,o;if(r){t=t==null?null:t+"";for(o in r){if((i=r[o]).name!==t){a=!1;continue}s=i.state>No&&i.state<Wo,i.state=$s,i.timer.stop(),i.on.call(s?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete r[o]}a&&delete e.__transition}}function cb(e){return this.each(function(){hb(this,e)})}function ub(e,t){var r,i;return function(){var s=Pe(this,e),a=s.tween;if(a!==r){i=r=a;for(var o=0,n=i.length;o<n;++o)if(i[o].name===t){i=i.slice(),i.splice(o,1);break}}s.tween=i}}function db(e,t,r){var i,s;if(typeof r!="function")throw new Error;return function(){var a=Pe(this,e),o=a.tween;if(o!==i){s=(i=o).slice();for(var n={name:t,value:r},l=0,c=s.length;l<c;++l)if(s[l].name===t){s[l]=n;break}l===c&&s.push(n)}a.tween=s}}function fb(e,t){var r=this._id;if(e+="",arguments.length<2){for(var i=Se(this.node(),r).tween,s=0,a=i.length,o;s<a;++s)if((o=i[s]).name===e)return o.value;return null}return this.each((t==null?ub:db)(r,e,t))}function On(e,t,r){var i=e._id;return e.each(function(){var s=Pe(this,i);(s.value||(s.value={}))[t]=r.apply(this,arguments)}),function(s){return Se(s,i).value[t]}}function pd(e,t){var r;return(typeof t=="number"?Ke:t instanceof Vi?ch:(r=Vi(t))?(t=r,ch):KC)(e,t)}function pb(e){return function(){this.removeAttribute(e)}}function gb(e){return function(){this.removeAttributeNS(e.space,e.local)}}function yb(e,t,r){var i,s=r+"",a;return function(){var o=this.getAttribute(e);return o===s?null:o===i?a:a=t(i=o,r)}}function mb(e,t,r){var i,s=r+"",a;return function(){var o=this.getAttributeNS(e.space,e.local);return o===s?null:o===i?a:a=t(i=o,r)}}function xb(e,t,r){var i,s,a;return function(){var o,n=r(this),l;return n==null?void this.removeAttribute(e):(o=this.getAttribute(e),l=n+"",o===l?null:o===i&&l===s?a:(s=l,a=t(i=o,n)))}}function Cb(e,t,r){var i,s,a;return function(){var o,n=r(this),l;return n==null?void this.removeAttributeNS(e.space,e.local):(o=this.getAttributeNS(e.space,e.local),l=n+"",o===l?null:o===i&&l===s?a:(s=l,a=t(i=o,n)))}}function bb(e,t){var r=da(e),i=r==="transform"?eb:pd;return this.attrTween(e,typeof t=="function"?(r.local?Cb:xb)(r,i,On(this,"attr."+e,t)):t==null?(r.local?gb:pb)(r):(r.local?mb:yb)(r,i,t))}function kb(e,t){return function(r){this.setAttribute(e,t.call(this,r))}}function wb(e,t){return function(r){this.setAttributeNS(e.space,e.local,t.call(this,r))}}function Sb(e,t){var r,i;function s(){var a=t.apply(this,arguments);return a!==i&&(r=(i=a)&&wb(e,a)),r}return s._value=t,s}function Tb(e,t){var r,i;function s(){var a=t.apply(this,arguments);return a!==i&&(r=(i=a)&&kb(e,a)),r}return s._value=t,s}function _b(e,t){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;var i=da(e);return this.tween(r,(i.local?Sb:Tb)(i,t))}function Bb(e,t){return function(){$n(this,e).delay=+t.apply(this,arguments)}}function vb(e,t){return t=+t,function(){$n(this,e).delay=t}}function Lb(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?Bb:vb)(t,e)):Se(this.node(),t).delay}function Fb(e,t){return function(){Pe(this,e).duration=+t.apply(this,arguments)}}function Mb(e,t){return t=+t,function(){Pe(this,e).duration=t}}function Ab(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?Fb:Mb)(t,e)):Se(this.node(),t).duration}function Eb(e,t){if(typeof t!="function")throw new Error;return function(){Pe(this,e).ease=t}}function $b(e){var t=this._id;return arguments.length?this.each(Eb(t,e)):Se(this.node(),t).ease}function Ob(e,t){return function(){var r=t.apply(this,arguments);if(typeof r!="function")throw new Error;Pe(this,e).ease=r}}function Db(e){if(typeof e!="function")throw new Error;return this.each(Ob(this._id,e))}function Pb(e){typeof e!="function"&&(e=Gu(e));for(var t=this._groups,r=t.length,i=new Array(r),s=0;s<r;++s)for(var a=t[s],o=a.length,n=i[s]=[],l,c=0;c<o;++c)(l=a[c])&&e.call(l,l.__data__,c,a)&&n.push(l);return new je(i,this._parents,this._name,this._id)}function Ib(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,r=e._groups,i=t.length,s=r.length,a=Math.min(i,s),o=new Array(i),n=0;n<a;++n)for(var l=t[n],c=r[n],h=l.length,u=o[n]=new Array(h),d,f=0;f<h;++f)(d=l[f]||c[f])&&(u[f]=d);for(;n<i;++n)o[n]=t[n];return new je(o,this._parents,this._name,this._id)}function Rb(e){return(e+"").trim().split(/^|\s+/).every(function(t){var r=t.indexOf(".");return r>=0&&(t=t.slice(0,r)),!t||t==="start"})}function qb(e,t,r){var i,s,a=Rb(t)?$n:Pe;return function(){var o=a(this,e),n=o.on;n!==i&&(s=(i=n).copy()).on(t,r),o.on=s}}function Nb(e,t){var r=this._id;return arguments.length<2?Se(this.node(),r).on.on(e):this.each(qb(r,e,t))}function Wb(e){return function(){var t=this.parentNode;for(var r in this.__transition)if(+r!==e)return;t&&t.removeChild(this)}}function zb(){return this.on("end.remove",Wb(this._id))}function Hb(e){var t=this._name,r=this._id;typeof e!="function"&&(e=Ln(e));for(var i=this._groups,s=i.length,a=new Array(s),o=0;o<s;++o)for(var n=i[o],l=n.length,c=a[o]=new Array(l),h,u,d=0;d<l;++d)(h=n[d])&&(u=e.call(h,h.__data__,d,n))&&("__data__"in h&&(u.__data__=h.__data__),c[d]=u,pa(c[d],t,r,d,c,Se(h,r)));return new je(a,this._parents,t,r)}function Yb(e){var t=this._name,r=this._id;typeof e!="function"&&(e=Xu(e));for(var i=this._groups,s=i.length,a=[],o=[],n=0;n<s;++n)for(var l=i[n],c=l.length,h,u=0;u<c;++u)if(h=l[u]){for(var d=e.call(h,h.__data__,u,l),f,y=Se(h,r),m=0,C=d.length;m<C;++m)(f=d[m])&&pa(f,t,r,m,d,y);a.push(d),o.push(h)}return new je(a,o,t,r)}var jb=ns.prototype.constructor;function Ub(){return new jb(this._groups,this._parents)}function Xb(e,t){var r,i,s;return function(){var a=si(this,e),o=(this.style.removeProperty(e),si(this,e));return a===o?null:a===r&&o===i?s:s=t(r=a,i=o)}}function gd(e){return function(){this.style.removeProperty(e)}}function Gb(e,t,r){var i,s=r+"",a;return function(){var o=si(this,e);return o===s?null:o===i?a:a=t(i=o,r)}}function Vb(e,t,r){var i,s,a;return function(){var o=si(this,e),n=r(this),l=n+"";return n==null&&(l=n=(this.style.removeProperty(e),si(this,e))),o===l?null:o===i&&l===s?a:(s=l,a=t(i=o,n))}}function Zb(e,t){var r,i,s,a="style."+t,o="end."+a,n;return function(){var l=Pe(this,e),c=l.on,h=l.value[a]==null?n||(n=gd(t)):void 0;(c!==r||s!==h)&&(i=(r=c).copy()).on(o,s=h),l.on=i}}function Kb(e,t,r){var i=(e+="")=="transform"?tb:pd;return t==null?this.styleTween(e,Xb(e,i)).on("end.style."+e,gd(e)):typeof t=="function"?this.styleTween(e,Vb(e,i,On(this,"style."+e,t))).each(Zb(this._id,e)):this.styleTween(e,Gb(e,i,t),r).on("end.style."+e,null)}function Qb(e,t,r){return function(i){this.style.setProperty(e,t.call(this,i),r)}}function Jb(e,t,r){var i,s;function a(){var o=t.apply(this,arguments);return o!==s&&(i=(s=o)&&Qb(e,o,r)),i}return a._value=t,a}function t1(e,t,r){var i="style."+(e+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(t==null)return this.tween(i,null);if(typeof t!="function")throw new Error;return this.tween(i,Jb(e,t,r??""))}function e1(e){return function(){this.textContent=e}}function r1(e){return function(){var t=e(this);this.textContent=t??""}}function i1(e){return this.tween("text",typeof e=="function"?r1(On(this,"text",e)):e1(e==null?"":e+""))}function s1(e){return function(t){this.textContent=e.call(this,t)}}function a1(e){var t,r;function i(){var s=e.apply(this,arguments);return s!==r&&(t=(r=s)&&s1(s)),t}return i._value=e,i}function o1(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,a1(e))}function n1(){for(var e=this._name,t=this._id,r=yd(),i=this._groups,s=i.length,a=0;a<s;++a)for(var o=i[a],n=o.length,l,c=0;c<n;++c)if(l=o[c]){var h=Se(l,t);pa(l,e,r,c,o,{time:h.time+h.delay+h.duration,delay:0,duration:h.duration,ease:h.ease})}return new je(i,this._parents,e,r)}function l1(){var e,t,r=this,i=r._id,s=r.size();return new Promise(function(a,o){var n={value:o},l={value:function(){--s===0&&a()}};r.each(function(){var c=Pe(this,i),h=c.on;h!==e&&(t=(e=h).copy(),t._.cancel.push(n),t._.interrupt.push(n),t._.end.push(l)),c.on=t}),s===0&&a()})}var h1=0;function je(e,t,r,i){this._groups=e,this._parents=t,this._name=r,this._id=i}function yd(){return++h1}var qe=ns.prototype;je.prototype={constructor:je,select:Hb,selectAll:Yb,selectChild:qe.selectChild,selectChildren:qe.selectChildren,filter:Pb,merge:Ib,selection:Ub,transition:n1,call:qe.call,nodes:qe.nodes,node:qe.node,size:qe.size,empty:qe.empty,each:qe.each,on:Nb,attr:bb,attrTween:_b,style:Kb,styleTween:t1,text:i1,textTween:o1,remove:zb,tween:fb,delay:Lb,duration:Ab,ease:$b,easeVarying:Db,end:l1,[Symbol.iterator]:qe[Symbol.iterator]};function c1(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var u1={time:null,delay:0,duration:250,ease:c1};function d1(e,t){for(var r;!(r=e.__transition)||!(r=r[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return r}function f1(e){var t,r;e instanceof je?(t=e._id,e=e._name):(t=yd(),(r=u1).time=En(),e=e==null?null:e+"");for(var i=this._groups,s=i.length,a=0;a<s;++a)for(var o=i[a],n=o.length,l,c=0;c<n;++c)(l=o[c])&&pa(l,e,t,c,o,r||d1(l,t));return new je(i,this._parents,e,t)}ns.prototype.interrupt=cb;ns.prototype.transition=f1;const zo=Math.PI,Ho=2*zo,nr=1e-6,p1=Ho-nr;function md(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function g1(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return md;const r=10**t;return function(i){this._+=i[0];for(let s=1,a=i.length;s<a;++s)this._+=Math.round(arguments[s]*r)/r+i[s]}}class y1{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?md:g1(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,i,s){this._append`Q${+t},${+r},${this._x1=+i},${this._y1=+s}`}bezierCurveTo(t,r,i,s,a,o){this._append`C${+t},${+r},${+i},${+s},${this._x1=+a},${this._y1=+o}`}arcTo(t,r,i,s,a){if(t=+t,r=+r,i=+i,s=+s,a=+a,a<0)throw new Error(`negative radius: ${a}`);let o=this._x1,n=this._y1,l=i-t,c=s-r,h=o-t,u=n-r,d=h*h+u*u;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(d>nr)if(!(Math.abs(u*l-c*h)>nr)||!a)this._append`L${this._x1=t},${this._y1=r}`;else{let f=i-o,y=s-n,m=l*l+c*c,C=f*f+y*y,x=Math.sqrt(m),k=Math.sqrt(d),w=a*Math.tan((zo-Math.acos((m+d-C)/(2*x*k)))/2),T=w/k,_=w/x;Math.abs(T-1)>nr&&this._append`L${t+T*h},${r+T*u}`,this._append`A${a},${a},0,0,${+(u*f>h*y)},${this._x1=t+_*l},${this._y1=r+_*c}`}}arc(t,r,i,s,a,o){if(t=+t,r=+r,i=+i,o=!!o,i<0)throw new Error(`negative radius: ${i}`);let n=i*Math.cos(s),l=i*Math.sin(s),c=t+n,h=r+l,u=1^o,d=o?s-a:a-s;this._x1===null?this._append`M${c},${h}`:(Math.abs(this._x1-c)>nr||Math.abs(this._y1-h)>nr)&&this._append`L${c},${h}`,i&&(d<0&&(d=d%Ho+Ho),d>p1?this._append`A${i},${i},0,1,${u},${t-n},${r-l}A${i},${i},0,1,${u},${this._x1=c},${this._y1=h}`:d>nr&&this._append`A${i},${i},0,${+(d>=zo)},${u},${this._x1=t+i*Math.cos(a)},${this._y1=r+i*Math.sin(a)}`)}rect(t,r,i,s){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${i=+i}v${+s}h${-i}Z`}toString(){return this._}}function Mr(e){return function(){return e}}const GM=Math.abs,VM=Math.atan2,ZM=Math.cos,KM=Math.max,QM=Math.min,JM=Math.sin,tA=Math.sqrt,yh=1e-12,Dn=Math.PI,mh=Dn/2,eA=2*Dn;function rA(e){return e>1?0:e<-1?Dn:Math.acos(e)}function iA(e){return e>=1?mh:e<=-1?-mh:Math.asin(e)}function m1(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const i=Math.floor(r);if(!(i>=0))throw new RangeError(`invalid digits: ${r}`);t=i}return e},()=>new y1(t)}function x1(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function xd(e){this._context=e}xd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Wi(e){return new xd(e)}function C1(e){return e[0]}function b1(e){return e[1]}function k1(e,t){var r=Mr(!0),i=null,s=Wi,a=null,o=m1(n);e=typeof e=="function"?e:e===void 0?C1:Mr(e),t=typeof t=="function"?t:t===void 0?b1:Mr(t);function n(l){var c,h=(l=x1(l)).length,u,d=!1,f;for(i==null&&(a=s(f=o())),c=0;c<=h;++c)!(c<h&&r(u=l[c],c,l))===d&&((d=!d)?a.lineStart():a.lineEnd()),d&&a.point(+e(u,c,l),+t(u,c,l));if(f)return a=null,f+""||null}return n.x=function(l){return arguments.length?(e=typeof l=="function"?l:Mr(+l),n):e},n.y=function(l){return arguments.length?(t=typeof l=="function"?l:Mr(+l),n):t},n.defined=function(l){return arguments.length?(r=typeof l=="function"?l:Mr(!!l),n):r},n.curve=function(l){return arguments.length?(s=l,i!=null&&(a=s(i)),n):s},n.context=function(l){return arguments.length?(l==null?i=a=null:a=s(i=l),n):i},n}class Cd{constructor(t,r){this._context=t,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function bd(e){return new Cd(e,!0)}function kd(e){return new Cd(e,!1)}function tr(){}function Zs(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function ga(e){this._context=e}ga.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Zs(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Zs(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Yo(e){return new ga(e)}function wd(e){this._context=e}wd.prototype={areaStart:tr,areaEnd:tr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Zs(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function w1(e){return new wd(e)}function Sd(e){this._context=e}Sd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,i):this._context.moveTo(r,i);break;case 3:this._point=4;default:Zs(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function S1(e){return new Sd(e)}function Td(e,t){this._basis=new ga(e),this._beta=t}Td.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,r=e.length-1;if(r>0)for(var i=e[0],s=t[0],a=e[r]-i,o=t[r]-s,n=-1,l;++n<=r;)l=n/r,this._basis.point(this._beta*e[n]+(1-this._beta)*(i+l*a),this._beta*t[n]+(1-this._beta)*(s+l*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const T1=(function e(t){function r(i){return t===1?new ga(i):new Td(i,t)}return r.beta=function(i){return e(+i)},r})(.85);function Ks(e,t,r){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-r),e._x2,e._y2)}function Pn(e,t){this._context=e,this._k=(1-t)/6}Pn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Ks(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:Ks(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const _d=(function e(t){function r(i){return new Pn(i,t)}return r.tension=function(i){return e(+i)},r})(0);function In(e,t){this._context=e,this._k=(1-t)/6}In.prototype={areaStart:tr,areaEnd:tr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Ks(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const _1=(function e(t){function r(i){return new In(i,t)}return r.tension=function(i){return e(+i)},r})(0);function Rn(e,t){this._context=e,this._k=(1-t)/6}Rn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Ks(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const B1=(function e(t){function r(i){return new Rn(i,t)}return r.tension=function(i){return e(+i)},r})(0);function qn(e,t,r){var i=e._x1,s=e._y1,a=e._x2,o=e._y2;if(e._l01_a>yh){var n=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,l=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*n-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,s=(s*n-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>yh){var c=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,h=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*c+e._x1*e._l23_2a-t*e._l12_2a)/h,o=(o*c+e._y1*e._l23_2a-r*e._l12_2a)/h}e._context.bezierCurveTo(i,s,a,o,e._x2,e._y2)}function Bd(e,t){this._context=e,this._alpha=t}Bd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:qn(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const vd=(function e(t){function r(i){return t?new Bd(i,t):new Pn(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function Ld(e,t){this._context=e,this._alpha=t}Ld.prototype={areaStart:tr,areaEnd:tr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:qn(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const v1=(function e(t){function r(i){return t?new Ld(i,t):new In(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function Fd(e,t){this._context=e,this._alpha=t}Fd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:qn(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const L1=(function e(t){function r(i){return t?new Fd(i,t):new Rn(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function Md(e){this._context=e}Md.prototype={areaStart:tr,areaEnd:tr,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function F1(e){return new Md(e)}function xh(e){return e<0?-1:1}function Ch(e,t,r){var i=e._x1-e._x0,s=t-e._x1,a=(e._y1-e._y0)/(i||s<0&&-0),o=(r-e._y1)/(s||i<0&&-0),n=(a*s+o*i)/(i+s);return(xh(a)+xh(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(n))||0}function bh(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function qa(e,t,r){var i=e._x0,s=e._y0,a=e._x1,o=e._y1,n=(a-i)/3;e._context.bezierCurveTo(i+n,s+n*t,a-n,o-n*r,a,o)}function Qs(e){this._context=e}Qs.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:qa(this,this._t0,bh(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,qa(this,bh(this,r=Ch(this,e,t)),r);break;default:qa(this,this._t0,r=Ch(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function Ad(e){this._context=new Ed(e)}(Ad.prototype=Object.create(Qs.prototype)).point=function(e,t){Qs.prototype.point.call(this,t,e)};function Ed(e){this._context=e}Ed.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,i,s,a){this._context.bezierCurveTo(t,e,i,r,a,s)}};function $d(e){return new Qs(e)}function Od(e){return new Ad(e)}function Dd(e){this._context=e}Dd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var i=kh(e),s=kh(t),a=0,o=1;o<r;++a,++o)this._context.bezierCurveTo(i[0][a],s[0][a],i[1][a],s[1][a],e[o],t[o]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function kh(e){var t,r=e.length-1,i,s=new Array(r),a=new Array(r),o=new Array(r);for(s[0]=0,a[0]=2,o[0]=e[0]+2*e[1],t=1;t<r-1;++t)s[t]=1,a[t]=4,o[t]=4*e[t]+2*e[t+1];for(s[r-1]=2,a[r-1]=7,o[r-1]=8*e[r-1]+e[r],t=1;t<r;++t)i=s[t]/a[t-1],a[t]-=i,o[t]-=i*o[t-1];for(s[r-1]=o[r-1]/a[r-1],t=r-2;t>=0;--t)s[t]=(o[t]-s[t+1])/a[t];for(a[r-1]=(e[r]+s[r-1])/2,t=0;t<r-1;++t)a[t]=2*e[t+1]-s[t+1];return[s,a]}function Pd(e){return new Dd(e)}function ya(e,t){this._context=e,this._t=t}ya.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function Id(e){return new ya(e,.5)}function Rd(e){return new ya(e,0)}function qd(e){return new ya(e,1)}function Ei(e,t,r){this.k=e,this.x=t,this.y=r}Ei.prototype={constructor:Ei,scale:function(e){return e===1?this:new Ei(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Ei(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};Ei.prototype;var M1=p(e=>{var s;const{securityLevel:t}=At();let r=Lt("body");if(t==="sandbox"){const o=((s=Lt(`#i${e}`).node())==null?void 0:s.contentDocument)??document;r=Lt(o.body)}return r.select(`#${e}`)},"selectSvgElement"),A1=p(e=>{const{handDrawnSeed:t}=At();return{fill:e,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:e,seed:t}},"solidStateFill"),E1=p(e=>Array.isArray(e)?e:e?e.split(";").map(t=>t.trim()).filter(Boolean):[],"normalizeStyleList"),hi=p(e=>{const t=$1([...e.cssCompiledStyles||[],...e.cssStyles||[],...E1(e.labelStyle)]);return{stylesMap:t,stylesArray:[...t]}},"compileStyles"),$1=p(e=>{const t=new Map;return e.forEach(r=>{const[i,s]=r.split(":");t.set(i.trim(),s==null?void 0:s.trim())}),t},"styles2Map"),Nd=p(e=>e==="color"||e==="font-size"||e==="font-family"||e==="font-weight"||e==="font-style"||e==="text-decoration"||e==="text-align"||e==="text-transform"||e==="line-height"||e==="letter-spacing"||e==="word-spacing"||e==="text-shadow"||e==="text-overflow"||e==="white-space"||e==="word-wrap"||e==="word-break"||e==="overflow-wrap"||e==="hyphens","isLabelStyle"),dt=p(e=>{const{stylesArray:t}=hi(e),r=[],i=[],s=[],a=[];return t.forEach(o=>{const n=o[0];Nd(n)?r.push(o.join(":")+" !important"):(i.push(o.join(":")+" !important"),n.includes("stroke")&&s.push(o.join(":")+" !important"),n==="fill"&&a.push(o.join(":")+" !important"))}),{labelStyles:r.join(";"),nodeStyles:i.join(";"),stylesArray:t,borderStyles:s,backgroundStyles:a}},"styles2String"),ot=p((e,t)=>{var l;const{themeVariables:r,handDrawnSeed:i}=At(),{nodeBorder:s,mainBkg:a}=r,{stylesMap:o}=hi(e);return Object.assign({roughness:.7,fill:o.get("fill")||a,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:o.get("stroke")||s,seed:i,strokeWidth:((l=o.get("stroke-width"))==null?void 0:l.replace("px",""))||1.3,fillLineDash:[0,0],strokeLineDash:O1(o.get("stroke-dasharray"))},t)},"userNodeOverrides"),O1=p(e=>{if(!e)return[0,0];const t=e.trim().split(/\s+/).map(Number);if(t.length===1){const s=isNaN(t[0])?0:t[0];return[s,s]}const r=isNaN(t[0])?0:t[0],i=isNaN(t[1])?0:t[1];return[r,i]},"getStrokeDashArray");const D1=Object.freeze({left:0,top:0,width:16,height:16}),Js=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),Wd=Object.freeze({...D1,...Js}),P1=Object.freeze({...Wd,body:"",hidden:!1}),I1=Object.freeze({width:null,height:null}),R1=Object.freeze({...I1,...Js}),q1=(e,t,r,i="")=>{const s=e.split(":");if(e.slice(0,1)==="@"){if(s.length<2||s.length>3)return null;i=s.shift().slice(1)}if(s.length>3||!s.length)return null;if(s.length>1){const n=s.pop(),l=s.pop(),c={provider:s.length>0?s[0]:i,prefix:l,name:n};return Na(c)?c:null}const a=s[0],o=a.split("-");if(o.length>1){const n={provider:i,prefix:o.shift(),name:o.join("-")};return Na(n)?n:null}if(r&&i===""){const n={provider:i,prefix:"",name:a};return Na(n,r)?n:null}return null},Na=(e,t)=>e?!!((t&&e.prefix===""||e.prefix)&&e.name):!1;function N1(e,t){const r={};!e.hFlip!=!t.hFlip&&(r.hFlip=!0),!e.vFlip!=!t.vFlip&&(r.vFlip=!0);const i=((e.rotate||0)+(t.rotate||0))%4;return i&&(r.rotate=i),r}function wh(e,t){const r=N1(e,t);for(const i in P1)i in Js?i in e&&!(i in r)&&(r[i]=Js[i]):i in t?r[i]=t[i]:i in e&&(r[i]=e[i]);return r}function W1(e,t){const r=e.icons,i=e.aliases||Object.create(null),s=Object.create(null);function a(o){if(r[o])return s[o]=[];if(!(o in s)){s[o]=null;const n=i[o]&&i[o].parent,l=n&&a(n);l&&(s[o]=[n].concat(l))}return s[o]}return(t||Object.keys(r).concat(Object.keys(i))).forEach(a),s}function Sh(e,t,r){const i=e.icons,s=e.aliases||Object.create(null);let a={};function o(n){a=wh(i[n]||s[n],a)}return o(t),r.forEach(o),wh(e,a)}function z1(e,t){if(e.icons[t])return Sh(e,t,[]);const r=W1(e,[t])[t];return r?Sh(e,t,r):null}const H1=/(-?[0-9.]*[0-9]+[0-9.]*)/g,Y1=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function Th(e,t,r){if(t===1)return e;if(r=r||100,typeof e=="number")return Math.ceil(e*t*r)/r;if(typeof e!="string")return e;const i=e.split(H1);if(i===null||!i.length)return e;const s=[];let a=i.shift(),o=Y1.test(a);for(;;){if(o){const n=parseFloat(a);isNaN(n)?s.push(a):s.push(Math.ceil(n*t*r)/r)}else s.push(a);if(a=i.shift(),a===void 0)return s.join("");o=!o}}function j1(e,t="defs"){let r="";const i=e.indexOf("<"+t);for(;i>=0;){const s=e.indexOf(">",i),a=e.indexOf("</"+t);if(s===-1||a===-1)break;const o=e.indexOf(">",a);if(o===-1)break;r+=e.slice(s+1,a).trim(),e=e.slice(0,i).trim()+e.slice(o+1)}return{defs:r,content:e}}function U1(e,t){return e?"<defs>"+e+"</defs>"+t:t}function X1(e,t,r){const i=j1(e);return U1(i.defs,t+i.content+r)}const G1=e=>e==="unset"||e==="undefined"||e==="none";function V1(e,t){const r={...Wd,...e},i={...R1,...t},s={left:r.left,top:r.top,width:r.width,height:r.height};let a=r.body;[r,i].forEach(m=>{const C=[],x=m.hFlip,k=m.vFlip;let w=m.rotate;x?k?w+=2:(C.push("translate("+(s.width+s.left).toString()+" "+(0-s.top).toString()+")"),C.push("scale(-1 1)"),s.top=s.left=0):k&&(C.push("translate("+(0-s.left).toString()+" "+(s.height+s.top).toString()+")"),C.push("scale(1 -1)"),s.top=s.left=0);let T;switch(w<0&&(w-=Math.floor(w/4)*4),w=w%4,w){case 1:T=s.height/2+s.top,C.unshift("rotate(90 "+T.toString()+" "+T.toString()+")");break;case 2:C.unshift("rotate(180 "+(s.width/2+s.left).toString()+" "+(s.height/2+s.top).toString()+")");break;case 3:T=s.width/2+s.left,C.unshift("rotate(-90 "+T.toString()+" "+T.toString()+")")}w%2===1&&(s.left!==s.top&&(T=s.left,s.left=s.top,s.top=T),s.width!==s.height&&(T=s.width,s.width=s.height,s.height=T)),C.length&&(a=X1(a,'<g transform="'+C.join(" ")+'">',"</g>"))});const o=i.width,n=i.height,l=s.width,c=s.height;let h,u;o===null?(u=n===null?"1em":n==="auto"?c:n,h=Th(u,l/c)):(h=o==="auto"?l:o,u=n===null?Th(h,c/l):n==="auto"?c:n);const d={},f=(m,C)=>{G1(C)||(d[m]=C.toString())};f("width",h),f("height",u);const y=[s.left,s.top,l,c];return d.viewBox=y.join(" "),{attributes:d,viewBox:y,body:a}}const Z1=/\sid="(\S+)"/g,_h=new Map;function K1(e){e=e.replace(/[0-9]+$/,"")||"a";const t=_h.get(e)||0;return _h.set(e,t+1),t?`${e}${t}`:e}function Q1(e){const t=[];let r;for(;r=Z1.exec(e);)t.push(r[1]);if(!t.length)return e;const i="suffix"+(Math.random()*16777216|Date.now()).toString(16);return t.forEach(s=>{const a=K1(s),o=s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+o+')([")]|\\.[a-z])',"g"),"$1"+a+i+"$3")}),e=e.replace(new RegExp(i,"g"),""),e}function J1(e,t){let r=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const i in t)r+=" "+i+'="'+t[i]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+r+">"+e+"</svg>"}var tk={body:'<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',height:80,width:80},jo=new Map,zd=new Map,ek=p(e=>{for(const t of e){if(!t.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(I.debug("Registering icon pack:",t.name),"loader"in t)zd.set(t.name,t.loader);else if("icons"in t)jo.set(t.name,t.icons);else throw I.error("Invalid icon loader:",t),new Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),Hd=p(async(e,t)=>{const r=q1(e,!0,t!==void 0);if(!r)throw new Error(`Invalid icon name: ${e}`);const i=r.prefix||t;if(!i)throw new Error(`Icon name must contain a prefix: ${e}`);let s=jo.get(i);if(!s){const o=zd.get(i);if(!o)throw new Error(`Icon set not found: ${r.prefix}`);try{s={...await o(),prefix:i},jo.set(i,s)}catch(n){throw I.error(n),new Error(`Failed to load icon set: ${r.prefix}`)}}const a=z1(s,r.name);if(!a)throw new Error(`Icon not found: ${e}`);return a},"getRegisteredIconData"),rk=p(async e=>{try{return await Hd(e),!0}catch{return!1}},"isIconAvailable"),hs=p(async(e,t,r)=>{let i;try{i=await Hd(e,t==null?void 0:t.fallbackPrefix)}catch(o){I.error(o),i=tk}const s=V1(i,t),a=J1(Q1(s.body),{...s.attributes,...r});return de(a,Ht())},"getIconSVG"),gs={},Gt={},Bh;function ik(){return Bh||(Bh=1,Object.defineProperty(Gt,"__esModule",{value:!0}),Gt.BLANK_URL=Gt.relativeFirstCharacters=Gt.whitespaceEscapeCharsRegex=Gt.urlSchemeRegex=Gt.ctrlCharactersRegex=Gt.htmlCtrlEntityRegex=Gt.htmlEntitiesRegex=Gt.invalidProtocolRegex=void 0,Gt.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,Gt.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,Gt.htmlCtrlEntityRegex=/&(newline|tab);/gi,Gt.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,Gt.urlSchemeRegex=/^.+(:|&colon;)/gim,Gt.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,Gt.relativeFirstCharacters=[".","/"],Gt.BLANK_URL="about:blank"),Gt}var vh;function sk(){if(vh)return gs;vh=1,Object.defineProperty(gs,"__esModule",{value:!0}),gs.sanitizeUrl=a;var e=ik();function t(o){return e.relativeFirstCharacters.indexOf(o[0])>-1}function r(o){var n=o.replace(e.ctrlCharactersRegex,"");return n.replace(e.htmlEntitiesRegex,function(l,c){return String.fromCharCode(c)})}function i(o){return URL.canParse(o)}function s(o){try{return decodeURIComponent(o)}catch{return o}}function a(o){if(!o)return e.BLANK_URL;var n,l=s(o.trim());do l=r(l).replace(e.htmlCtrlEntityRegex,"").replace(e.ctrlCharactersRegex,"").replace(e.whitespaceEscapeCharsRegex,"").trim(),l=s(l),n=l.match(e.ctrlCharactersRegex)||l.match(e.htmlEntitiesRegex)||l.match(e.htmlCtrlEntityRegex)||l.match(e.whitespaceEscapeCharsRegex);while(n&&n.length>0);var c=l;if(!c)return e.BLANK_URL;if(t(c))return c;var h=c.trimStart(),u=h.match(e.urlSchemeRegex);if(!u)return c;var d=u[0].toLowerCase().trim();if(e.invalidProtocolRegex.test(d))return e.BLANK_URL;var f=h.replace(/\\/g,"/");if(d==="mailto:"||d.includes("://"))return f;if(d==="http:"||d==="https:"){if(!i(f))return e.BLANK_URL;var y=new URL(f);return y.protocol=y.protocol.toLowerCase(),y.hostname=y.hostname.toLowerCase(),y.toString()}return f}return gs}var ak=sk(),ok="​",nk={curveBasis:Yo,curveBasisClosed:w1,curveBasisOpen:S1,curveBumpX:bd,curveBumpY:kd,curveBundle:T1,curveCardinalClosed:_1,curveCardinalOpen:B1,curveCardinal:_d,curveCatmullRomClosed:v1,curveCatmullRomOpen:L1,curveCatmullRom:vd,curveLinear:Wi,curveLinearClosed:F1,curveMonotoneX:$d,curveMonotoneY:Od,curveNatural:Pd,curveStep:Id,curveStepAfter:qd,curveStepBefore:Rd},lk=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,hk=p(function(e,t){const r=Yd(e,/(?:init\b)|(?:initialize\b)/);let i={};if(Array.isArray(r)){const o=r.map(n=>n.args);qs(o),i=Vt(i,[...o])}else i=r.args;if(!i)return;let s=wn(e,t);const a="config";return i[a]!==void 0&&(s==="flowchart-v2"&&(s="flowchart"),i[s]=i[a],delete i[a]),i},"detectInit"),Yd=p(function(e,t=null){var r,i;try{const s=new RegExp(`[%]{2}(?![{]${lk.source})(?=[}][%]{2}).*
127
+ `,"ig");e=e.trim().replace(s,"").replace(/'/gm,'"'),I.debug(`Detecting diagram directive${t!==null?" type:"+t:""} based on the text:${e}`);let a;const o=[];for(;(a=Ni.exec(e))!==null;)if(a.index===Ni.lastIndex&&Ni.lastIndex++,a&&!t||t&&((r=a[1])!=null&&r.match(t))||t&&((i=a[2])!=null&&i.match(t))){const n=a[1]?a[1]:a[2],l=a[3]?a[3].trim():a[4]?JSON.parse(a[4].trim()):null;o.push({type:n,args:l})}return o.length===0?{type:e,args:null}:o.length===1?o[0]:o}catch(s){return I.error(`ERROR: ${s.message} - Unable to parse directive type: '${t}' based on the text: '${e}'`),{type:void 0,args:null}}},"detectDirective"),ck=p(function(e){return e.replace(Ni,"")},"removeDirectives"),uk=p(function(e,t){for(const[r,i]of t.entries())if(i.match(e))return r;return-1},"isSubstringInArray");function Nn(e,t){if(!e)return t;const r=`curve${e.charAt(0).toUpperCase()+e.slice(1)}`;return nk[r]??t}p(Nn,"interpolateToCurve");function jd(e,t){const r=e.trim();if(r)return t.securityLevel!=="loose"?ak.sanitizeUrl(r):r}p(jd,"formatUrl");var dk=p((e,...t)=>{const r=e.split("."),i=r.length-1,s=r[i];let a=window;for(let o=0;o<i;o++)if(a=a[r[o]],!a){I.error(`Function name: ${e} not found in window`);return}a[s](...t)},"runFunc");function Wn(e,t){return!e||!t?0:Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}p(Wn,"distance");function Ud(e){let t,r=0;e.forEach(s=>{r+=Wn(s,t),t=s});const i=r/2;return zn(e,i)}p(Ud,"traverseEdge");function Xd(e){return e.length===1?e[0]:Ud(e)}p(Xd,"calcLabelPosition");var Lh=p((e,t=2)=>{const r=Math.pow(10,t);return Math.round(e*r)/r},"roundNumber"),zn=p((e,t)=>{let r,i=t;for(const s of e){if(r){const a=Wn(s,r);if(a===0)return r;if(a<i)i-=a;else{const o=i/a;if(o<=0)return r;if(o>=1)return{x:s.x,y:s.y};if(o>0&&o<1)return{x:Lh((1-o)*r.x+o*s.x,5),y:Lh((1-o)*r.y+o*s.y,5)}}}r=s}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),fk=p((e,t,r)=>{I.info(`our points ${JSON.stringify(t)}`),t[0]!==r&&(t=t.reverse());const s=zn(t,25),a=e?10:5,o=Math.atan2(t[0].y-s.y,t[0].x-s.x),n={x:0,y:0};return n.x=Math.sin(o)*a+(t[0].x+s.x)/2,n.y=-Math.cos(o)*a+(t[0].y+s.y)/2,n},"calcCardinalityPosition");function Gd(e,t,r){const i=structuredClone(r);I.info("our points",i),t!=="start_left"&&t!=="start_right"&&i.reverse();const s=25+e,a=zn(i,s),o=10+e*.5,n=Math.atan2(i[0].y-a.y,i[0].x-a.x),l={x:0,y:0};return t==="start_left"?(l.x=Math.sin(n+Math.PI)*o+(i[0].x+a.x)/2,l.y=-Math.cos(n+Math.PI)*o+(i[0].y+a.y)/2):t==="end_right"?(l.x=Math.sin(n-Math.PI)*o+(i[0].x+a.x)/2-5,l.y=-Math.cos(n-Math.PI)*o+(i[0].y+a.y)/2-5):t==="end_left"?(l.x=Math.sin(n)*o+(i[0].x+a.x)/2-5,l.y=-Math.cos(n)*o+(i[0].y+a.y)/2-5):(l.x=Math.sin(n)*o+(i[0].x+a.x)/2,l.y=-Math.cos(n)*o+(i[0].y+a.y)/2),l}p(Gd,"calcTerminalLabelPosition");function Vd(e){let t="",r="";for(const i of e)i!==void 0&&(i.startsWith("color:")||i.startsWith("text-align:")?r=r+i+";":t=t+i+";");return{style:t,labelStyle:r}}p(Vd,"getStylesFromArray");var Fh=0,pk=p(()=>(Fh++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Fh),"generateId");function Zd(e){let t="";const r="0123456789abcdef",i=r.length;for(let s=0;s<e;s++)t+=r.charAt(Math.floor(Math.random()*i));return t}p(Zd,"makeRandomHex");var gk=p(e=>Zd(e.length),"random"),yk=p(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),mk=p(function(e,t){const r=t.text.replace(os.lineBreakRegex," "),[,i]=ma(t.fontSize),s=e.append("text");s.attr("x",t.x),s.attr("y",t.y),s.style("text-anchor",t.anchor),s.style("font-family",t.fontFamily),s.style("font-size",i),s.style("font-weight",t.fontWeight),s.attr("fill",t.fill),t.class!==void 0&&s.attr("class",t.class);const a=s.append("tspan");return a.attr("x",t.x+t.textMargin*2),a.attr("fill",t.fill),a.text(r),s},"drawSimpleText"),xk=is((e,t,r)=>{if(!e||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},r),os.lineBreakRegex.test(e)))return e;const i=e.split(" ").filter(Boolean),s=[];let a="";return i.forEach((o,n)=>{const l=Ue(`${o} `,r),c=Ue(a,r);if(l>t){const{hyphenatedStrings:d,remainingWord:f}=Ck(o,t,"-",r);s.push(a,...d),a=f}else c+l>=t?(s.push(a),a=o):a=[a,o].filter(Boolean).join(" ");n+1===i.length&&s.push(a)}),s.filter(o=>o!=="").join(r.joinWith)},(e,t,r)=>`${e}${t}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),Ck=is((e,t,r="-",i)=>{i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},i);const s=[...e],a=[];let o="";return s.forEach((n,l)=>{const c=`${o}${n}`;if(Ue(c,i)>=t){const u=l+1,d=s.length===u,f=`${c}${r}`;a.push(d?c:f),o=""}else o=c}),{hyphenatedStrings:a,remainingWord:o}},(e,t,r="-",i)=>`${e}${t}${r}${i.fontSize}${i.fontWeight}${i.fontFamily}`);function Kd(e,t){return Hn(e,t).height}p(Kd,"calculateTextHeight");function Ue(e,t){return Hn(e,t).width}p(Ue,"calculateTextWidth");var Hn=is((e,t)=>{const{fontSize:r=12,fontFamily:i="Arial",fontWeight:s=400}=t;if(!e)return{width:0,height:0};const[,a]=ma(r),o=["sans-serif",i],n=e.split(os.lineBreakRegex),l=[],c=Lt("body");if(!c.remove)return{width:0,height:0,lineHeight:0};const h=c.append("svg");for(const d of o){let f=0;const y={width:0,height:0,lineHeight:0};for(const m of n){const C=yk();C.text=m||ok;const x=mk(h,C).style("font-size",a).style("font-weight",s).style("font-family",d),k=(x._groups||x)[0][0].getBBox();if(k.width===0&&k.height===0)throw new Error("svg element not in render tree");y.width=Math.round(Math.max(y.width,k.width)),f=Math.round(k.height),y.height+=f,y.lineHeight=Math.round(Math.max(y.lineHeight,f))}l.push(y)}h.remove();const u=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[u]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),ti,bk=(ti=class{constructor(t=!1,r){this.count=0,this.count=r?r.length:0,this.next=t?()=>this.count++:()=>Date.now()}},p(ti,"InitIDGenerator"),ti),ys,kk=p(function(e){return ys=ys||document.createElement("div"),e=escape(e).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),ys.innerHTML=e,unescape(ys.textContent)},"entityDecode");function Yn(e){return"str"in e}p(Yn,"isDetailedError");var wk=p((e,t,r,i)=>{var a;if(!i)return;const s=(a=e.node())==null?void 0:a.getBBox();s&&e.append("text").text(i).attr("text-anchor","middle").attr("x",s.x+s.width/2).attr("y",-r).attr("class",t)},"insertTitle"),ma=p(e=>{if(typeof e=="number")return[e,e+"px"];const t=parseInt(e??"",10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+"px"]:[t,e]},"parseFontSize");function jn(e,t){return Rm({},e,t)}p(jn,"cleanAndMerge");var te={assignWithDepth:Vt,wrapLabel:xk,calculateTextHeight:Kd,calculateTextWidth:Ue,calculateTextDimensions:Hn,cleanAndMerge:jn,detectInit:hk,detectDirective:Yd,isSubstringInArray:uk,interpolateToCurve:Nn,calcLabelPosition:Xd,calcCardinalityPosition:fk,calcTerminalLabelPosition:Gd,formatUrl:jd,getStylesFromArray:Vd,generateId:pk,random:gk,runFunc:dk,entityDecode:kk,insertTitle:wk,isLabelCoordinateInPath:Qd,parseFontSize:ma,InitIDGenerator:bk},Sk=p(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),t=t.replace(/#\w+;/g,function(r){const i=r.substring(1,r.length-1);return/^\+?\d+$/.test(i)?"fl°°"+i+"¶ß":"fl°"+i+"¶ß"}),t},"encodeEntities"),er=p(function(e){return e.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),sA=p((e,t,{counter:r=0,prefix:i,suffix:s},a)=>a||`${i?`${i}_`:""}${e}_${t}_${r}${s?`_${s}`:""}`,"getEdgeId");function Xt(e){return e??null}p(Xt,"handleUndefinedAttr");function Qd(e,t){const r=Math.round(e.x),i=Math.round(e.y),s=t.replace(/(\d+\.\d+)/g,a=>Math.round(parseFloat(a)).toString());return s.includes(r.toString())||s.includes(i.toString())}p(Qd,"isLabelCoordinateInPath");var Os={exports:{}},Mh=Os.exports,Ah;function Tk(){return Ah||(Ah=1,(function(e){(function(t){var r=function(){},i=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.msRequestAnimationFrame||function(h){return setTimeout(h,16)};function s(){var h=this;h.reads=[],h.writes=[],h.raf=i.bind(t)}s.prototype={constructor:s,runTasks:function(h){for(var u;u=h.shift();)u()},measure:function(h,u){var d=u?h.bind(u):h;return this.reads.push(d),a(this),d},mutate:function(h,u){var d=u?h.bind(u):h;return this.writes.push(d),a(this),d},clear:function(h){return n(this.reads,h)||n(this.writes,h)},extend:function(h){if(typeof h!="object")throw new Error("expected object");var u=Object.create(this);return l(u,h),u.fastdom=this,u.initialize&&u.initialize(),u},catch:null};function a(h){h.scheduled||(h.scheduled=!0,h.raf(o.bind(null,h)))}function o(h){var u=h.writes,d=h.reads,f;try{r("flushing reads",d.length),h.runTasks(d),r("flushing writes",u.length),h.runTasks(u)}catch(y){f=y}if(h.scheduled=!1,(d.length||u.length)&&a(h),f)if(r("task errored",f.message),h.catch)h.catch(f);else throw f}function n(h,u){var d=h.indexOf(u);return!!~d&&!!h.splice(d,1)}function l(h,u){for(var d in u)u.hasOwnProperty(d)&&(h[d]=u[d])}var c=t.fastdom=t.fastdom||new s;e.exports=c})(typeof window<"u"?window:typeof Mh<"u"?Mh:globalThis)})(Os)),Os.exports}var _k=Tk();const Bk=yn(_k);var Wa={exports:{}},Eh;function vk(){return Eh||(Eh=1,(function(e){(function(){var t={initialize:function(){this._tasks=new Map},mutate:function(i,s){return r(this,"mutate",i,s)},measure:function(i,s){return r(this,"measure",i,s)},clear:function(i){var s=this._tasks,a=s.get(i);this.fastdom.clear(a),s.delete(i)}};function r(i,s,a,o){var n=i._tasks,l=i.fastdom,c,h=new Promise(function(u,d){c=l[s](function(){n.delete(h);try{u(o?a.call(o):a())}catch(f){d(f)}},o)});return n.set(h,c),h}e.exports=t})()})(Wa)),Wa.exports}var Lk=vk();const Fk=yn(Lk);function Un(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var wr=Un();function Jd(e){wr=e}var zi={exec:()=>null};function Pt(e,t=""){let r=typeof e=="string"?e:e.source,i={replace:(s,a)=>{let o=typeof a=="string"?a:a.source;return o=o.replace(ie.caret,"$1"),r=r.replace(s,o),i},getRegex:()=>new RegExp(r,t)};return i}var Mk=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),ie={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},Ak=/^(?:[ \t]*(?:\n|$))+/,Ek=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,$k=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,cs=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Ok=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Xn=/(?:[*+-]|\d{1,9}[.)])/,tf=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,ef=Pt(tf).replace(/bull/g,Xn).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),Dk=Pt(tf).replace(/bull/g,Xn).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),Gn=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Pk=/^[^\n]+/,Vn=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,Ik=Pt(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Vn).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Rk=Pt(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Xn).getRegex(),xa="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Zn=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,qk=Pt("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Zn).replace("tag",xa).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),rf=Pt(Gn).replace("hr",cs).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",xa).getRegex(),Nk=Pt(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",rf).getRegex(),Kn={blockquote:Nk,code:Ek,def:Ik,fences:$k,heading:Ok,hr:cs,html:qk,lheading:ef,list:Rk,newline:Ak,paragraph:rf,table:zi,text:Pk},$h=Pt("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",cs).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",xa).getRegex(),Wk={...Kn,lheading:Dk,table:$h,paragraph:Pt(Gn).replace("hr",cs).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",$h).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",xa).getRegex()},zk={...Kn,html:Pt(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Zn).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:zi,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Pt(Gn).replace("hr",cs).replace("heading",` *#{1,6} *[^
128
+ ]`).replace("lheading",ef).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Hk=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Yk=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,sf=/^( {2,}|\\)\n(?!\s*$)/,jk=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Ca=/[\p{P}\p{S}]/u,Qn=/[\s\p{P}\p{S}]/u,af=/[^\s\p{P}\p{S}]/u,Uk=Pt(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,Qn).getRegex(),of=/(?!~)[\p{P}\p{S}]/u,Xk=/(?!~)[\s\p{P}\p{S}]/u,Gk=/(?:[^\s\p{P}\p{S}]|~)/u,Vk=Pt(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",Mk?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),nf=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,Zk=Pt(nf,"u").replace(/punct/g,Ca).getRegex(),Kk=Pt(nf,"u").replace(/punct/g,of).getRegex(),lf="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",Qk=Pt(lf,"gu").replace(/notPunctSpace/g,af).replace(/punctSpace/g,Qn).replace(/punct/g,Ca).getRegex(),Jk=Pt(lf,"gu").replace(/notPunctSpace/g,Gk).replace(/punctSpace/g,Xk).replace(/punct/g,of).getRegex(),t2=Pt("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,af).replace(/punctSpace/g,Qn).replace(/punct/g,Ca).getRegex(),e2=Pt(/\\(punct)/,"gu").replace(/punct/g,Ca).getRegex(),r2=Pt(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),i2=Pt(Zn).replace("(?:-->|$)","-->").getRegex(),s2=Pt("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",i2).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),ta=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,a2=Pt(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",ta).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),hf=Pt(/^!?\[(label)\]\[(ref)\]/).replace("label",ta).replace("ref",Vn).getRegex(),cf=Pt(/^!?\[(ref)\](?:\[\])?/).replace("ref",Vn).getRegex(),o2=Pt("reflink|nolink(?!\\()","g").replace("reflink",hf).replace("nolink",cf).getRegex(),Oh=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,Jn={_backpedal:zi,anyPunctuation:e2,autolink:r2,blockSkip:Vk,br:sf,code:Yk,del:zi,emStrongLDelim:Zk,emStrongRDelimAst:Qk,emStrongRDelimUnd:t2,escape:Hk,link:a2,nolink:cf,punctuation:Uk,reflink:hf,reflinkSearch:o2,tag:s2,text:jk,url:zi},n2={...Jn,link:Pt(/^!?\[(label)\]\((.*?)\)/).replace("label",ta).getRegex(),reflink:Pt(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",ta).getRegex()},Uo={...Jn,emStrongRDelimAst:Jk,emStrongLDelim:Kk,url:Pt(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",Oh).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:Pt(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",Oh).getRegex()},l2={...Uo,br:Pt(sf).replace("{2,}","*").getRegex(),text:Pt(Uo.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},ms={normal:Kn,gfm:Wk,pedantic:zk},wi={normal:Jn,gfm:Uo,breaks:l2,pedantic:n2},h2={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Dh=e=>h2[e];function Be(e,t){if(t){if(ie.escapeTest.test(e))return e.replace(ie.escapeReplace,Dh)}else if(ie.escapeTestNoEncode.test(e))return e.replace(ie.escapeReplaceNoEncode,Dh);return e}function Ph(e){try{e=encodeURI(e).replace(ie.percentDecode,"%")}catch{return null}return e}function Ih(e,t){var a;let r=e.replace(ie.findPipe,(o,n,l)=>{let c=!1,h=n;for(;--h>=0&&l[h]==="\\";)c=!c;return c?"|":" |"}),i=r.split(ie.splitPipe),s=0;if(i[0].trim()||i.shift(),i.length>0&&!((a=i.at(-1))!=null&&a.trim())&&i.pop(),t)if(i.length>t)i.splice(t);else for(;i.length<t;)i.push("");for(;s<i.length;s++)i[s]=i[s].trim().replace(ie.slashPipe,"|");return i}function Si(e,t,r){let i=e.length;if(i===0)return"";let s=0;for(;s<i&&e.charAt(i-s-1)===t;)s++;return e.slice(0,i-s)}function c2(e,t){if(e.indexOf(t[1])===-1)return-1;let r=0;for(let i=0;i<e.length;i++)if(e[i]==="\\")i++;else if(e[i]===t[0])r++;else if(e[i]===t[1]&&(r--,r<0))return i;return r>0?-2:-1}function Rh(e,t,r,i,s){let a=t.href,o=t.title||null,n=e[1].replace(s.other.outputLinkReplace,"$1");i.state.inLink=!0;let l={type:e[0].charAt(0)==="!"?"image":"link",raw:r,href:a,title:o,text:n,tokens:i.inlineTokens(n)};return i.state.inLink=!1,l}function u2(e,t,r){let i=e.match(r.other.indentCodeCompensation);if(i===null)return t;let s=i[1];return t.split(`
129
+ `).map(a=>{let o=a.match(r.other.beginningSpace);if(o===null)return a;let[n]=o;return n.length>=s.length?a.slice(s.length):a}).join(`
130
+ `)}var ea=class{constructor(t){qt(this,"options");qt(this,"rules");qt(this,"lexer");this.options=t||wr}space(t){let r=this.rules.block.newline.exec(t);if(r&&r[0].length>0)return{type:"space",raw:r[0]}}code(t){let r=this.rules.block.code.exec(t);if(r){let i=r[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:r[0],codeBlockStyle:"indented",text:this.options.pedantic?i:Si(i,`
131
+ `)}}}fences(t){let r=this.rules.block.fences.exec(t);if(r){let i=r[0],s=u2(i,r[3]||"",this.rules);return{type:"code",raw:i,lang:r[2]?r[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):r[2],text:s}}}heading(t){let r=this.rules.block.heading.exec(t);if(r){let i=r[2].trim();if(this.rules.other.endingHash.test(i)){let s=Si(i,"#");(this.options.pedantic||!s||this.rules.other.endingSpaceChar.test(s))&&(i=s.trim())}return{type:"heading",raw:r[0],depth:r[1].length,text:i,tokens:this.lexer.inline(i)}}}hr(t){let r=this.rules.block.hr.exec(t);if(r)return{type:"hr",raw:Si(r[0],`
132
+ `)}}blockquote(t){let r=this.rules.block.blockquote.exec(t);if(r){let i=Si(r[0],`
133
+ `).split(`
134
+ `),s="",a="",o=[];for(;i.length>0;){let n=!1,l=[],c;for(c=0;c<i.length;c++)if(this.rules.other.blockquoteStart.test(i[c]))l.push(i[c]),n=!0;else if(!n)l.push(i[c]);else break;i=i.slice(c);let h=l.join(`
135
+ `),u=h.replace(this.rules.other.blockquoteSetextReplace,`
136
+ $1`).replace(this.rules.other.blockquoteSetextReplace2,"");s=s?`${s}
137
+ ${h}`:h,a=a?`${a}
138
+ ${u}`:u;let d=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(u,o,!0),this.lexer.state.top=d,i.length===0)break;let f=o.at(-1);if((f==null?void 0:f.type)==="code")break;if((f==null?void 0:f.type)==="blockquote"){let y=f,m=y.raw+`
139
+ `+i.join(`
140
+ `),C=this.blockquote(m);o[o.length-1]=C,s=s.substring(0,s.length-y.raw.length)+C.raw,a=a.substring(0,a.length-y.text.length)+C.text;break}else if((f==null?void 0:f.type)==="list"){let y=f,m=y.raw+`
141
+ `+i.join(`
142
+ `),C=this.list(m);o[o.length-1]=C,s=s.substring(0,s.length-f.raw.length)+C.raw,a=a.substring(0,a.length-y.raw.length)+C.raw,i=m.substring(o.at(-1).raw.length).split(`
143
+ `);continue}}return{type:"blockquote",raw:s,tokens:o,text:a}}}list(t){let r=this.rules.block.list.exec(t);if(r){let i=r[1].trim(),s=i.length>1,a={type:"list",raw:"",ordered:s,start:s?+i.slice(0,-1):"",loose:!1,items:[]};i=s?`\\d{1,9}\\${i.slice(-1)}`:`\\${i}`,this.options.pedantic&&(i=s?i:"[*+-]");let o=this.rules.other.listItemRegex(i),n=!1;for(;t;){let c=!1,h="",u="";if(!(r=o.exec(t))||this.rules.block.hr.test(t))break;h=r[0],t=t.substring(h.length);let d=r[2].split(`
144
+ `,1)[0].replace(this.rules.other.listReplaceTabs,k=>" ".repeat(3*k.length)),f=t.split(`
145
+ `,1)[0],y=!d.trim(),m=0;if(this.options.pedantic?(m=2,u=d.trimStart()):y?m=r[1].length+1:(m=r[2].search(this.rules.other.nonSpaceChar),m=m>4?1:m,u=d.slice(m),m+=r[1].length),y&&this.rules.other.blankLine.test(f)&&(h+=f+`
146
+ `,t=t.substring(f.length+1),c=!0),!c){let k=this.rules.other.nextBulletRegex(m),w=this.rules.other.hrRegex(m),T=this.rules.other.fencesBeginRegex(m),_=this.rules.other.headingBeginRegex(m),v=this.rules.other.htmlBeginRegex(m);for(;t;){let F=t.split(`
147
+ `,1)[0],L;if(f=F,this.options.pedantic?(f=f.replace(this.rules.other.listReplaceNesting," "),L=f):L=f.replace(this.rules.other.tabCharGlobal," "),T.test(f)||_.test(f)||v.test(f)||k.test(f)||w.test(f))break;if(L.search(this.rules.other.nonSpaceChar)>=m||!f.trim())u+=`
148
+ `+L.slice(m);else{if(y||d.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||T.test(d)||_.test(d)||w.test(d))break;u+=`
149
+ `+f}!y&&!f.trim()&&(y=!0),h+=F+`
150
+ `,t=t.substring(F.length+1),d=L.slice(m)}}a.loose||(n?a.loose=!0:this.rules.other.doubleBlankLine.test(h)&&(n=!0));let C=null,x;this.options.gfm&&(C=this.rules.other.listIsTask.exec(u),C&&(x=C[0]!=="[ ] ",u=u.replace(this.rules.other.listReplaceTask,""))),a.items.push({type:"list_item",raw:h,task:!!C,checked:x,loose:!1,text:u,tokens:[]}),a.raw+=h}let l=a.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;a.raw=a.raw.trimEnd();for(let c=0;c<a.items.length;c++)if(this.lexer.state.top=!1,a.items[c].tokens=this.lexer.blockTokens(a.items[c].text,[]),!a.loose){let h=a.items[c].tokens.filter(d=>d.type==="space"),u=h.length>0&&h.some(d=>this.rules.other.anyLine.test(d.raw));a.loose=u}if(a.loose)for(let c=0;c<a.items.length;c++)a.items[c].loose=!0;return a}}html(t){let r=this.rules.block.html.exec(t);if(r)return{type:"html",block:!0,raw:r[0],pre:r[1]==="pre"||r[1]==="script"||r[1]==="style",text:r[0]}}def(t){let r=this.rules.block.def.exec(t);if(r){let i=r[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),s=r[2]?r[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",a=r[3]?r[3].substring(1,r[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):r[3];return{type:"def",tag:i,raw:r[0],href:s,title:a}}}table(t){var n;let r=this.rules.block.table.exec(t);if(!r||!this.rules.other.tableDelimiter.test(r[2]))return;let i=Ih(r[1]),s=r[2].replace(this.rules.other.tableAlignChars,"").split("|"),a=(n=r[3])!=null&&n.trim()?r[3].replace(this.rules.other.tableRowBlankLine,"").split(`
151
+ `):[],o={type:"table",raw:r[0],header:[],align:[],rows:[]};if(i.length===s.length){for(let l of s)this.rules.other.tableAlignRight.test(l)?o.align.push("right"):this.rules.other.tableAlignCenter.test(l)?o.align.push("center"):this.rules.other.tableAlignLeft.test(l)?o.align.push("left"):o.align.push(null);for(let l=0;l<i.length;l++)o.header.push({text:i[l],tokens:this.lexer.inline(i[l]),header:!0,align:o.align[l]});for(let l of a)o.rows.push(Ih(l,o.header.length).map((c,h)=>({text:c,tokens:this.lexer.inline(c),header:!1,align:o.align[h]})));return o}}lheading(t){let r=this.rules.block.lheading.exec(t);if(r)return{type:"heading",raw:r[0],depth:r[2].charAt(0)==="="?1:2,text:r[1],tokens:this.lexer.inline(r[1])}}paragraph(t){let r=this.rules.block.paragraph.exec(t);if(r){let i=r[1].charAt(r[1].length-1)===`
152
+ `?r[1].slice(0,-1):r[1];return{type:"paragraph",raw:r[0],text:i,tokens:this.lexer.inline(i)}}}text(t){let r=this.rules.block.text.exec(t);if(r)return{type:"text",raw:r[0],text:r[0],tokens:this.lexer.inline(r[0])}}escape(t){let r=this.rules.inline.escape.exec(t);if(r)return{type:"escape",raw:r[0],text:r[1]}}tag(t){let r=this.rules.inline.tag.exec(t);if(r)return!this.lexer.state.inLink&&this.rules.other.startATag.test(r[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(r[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(r[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(r[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:r[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:r[0]}}link(t){let r=this.rules.inline.link.exec(t);if(r){let i=r[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(i)){if(!this.rules.other.endAngleBracket.test(i))return;let o=Si(i.slice(0,-1),"\\");if((i.length-o.length)%2===0)return}else{let o=c2(r[2],"()");if(o===-2)return;if(o>-1){let n=(r[0].indexOf("!")===0?5:4)+r[1].length+o;r[2]=r[2].substring(0,o),r[0]=r[0].substring(0,n).trim(),r[3]=""}}let s=r[2],a="";if(this.options.pedantic){let o=this.rules.other.pedanticHrefTitle.exec(s);o&&(s=o[1],a=o[3])}else a=r[3]?r[3].slice(1,-1):"";return s=s.trim(),this.rules.other.startAngleBracket.test(s)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(i)?s=s.slice(1):s=s.slice(1,-1)),Rh(r,{href:s&&s.replace(this.rules.inline.anyPunctuation,"$1"),title:a&&a.replace(this.rules.inline.anyPunctuation,"$1")},r[0],this.lexer,this.rules)}}reflink(t,r){let i;if((i=this.rules.inline.reflink.exec(t))||(i=this.rules.inline.nolink.exec(t))){let s=(i[2]||i[1]).replace(this.rules.other.multipleSpaceGlobal," "),a=r[s.toLowerCase()];if(!a){let o=i[0].charAt(0);return{type:"text",raw:o,text:o}}return Rh(i,a,i[0],this.lexer,this.rules)}}emStrong(t,r,i=""){let s=this.rules.inline.emStrongLDelim.exec(t);if(!(!s||s[3]&&i.match(this.rules.other.unicodeAlphaNumeric))&&(!(s[1]||s[2])||!i||this.rules.inline.punctuation.exec(i))){let a=[...s[0]].length-1,o,n,l=a,c=0,h=s[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(h.lastIndex=0,r=r.slice(-1*t.length+a);(s=h.exec(r))!=null;){if(o=s[1]||s[2]||s[3]||s[4]||s[5]||s[6],!o)continue;if(n=[...o].length,s[3]||s[4]){l+=n;continue}else if((s[5]||s[6])&&a%3&&!((a+n)%3)){c+=n;continue}if(l-=n,l>0)continue;n=Math.min(n,n+l+c);let u=[...s[0]][0].length,d=t.slice(0,a+s.index+u+n);if(Math.min(a,n)%2){let y=d.slice(1,-1);return{type:"em",raw:d,text:y,tokens:this.lexer.inlineTokens(y)}}let f=d.slice(2,-2);return{type:"strong",raw:d,text:f,tokens:this.lexer.inlineTokens(f)}}}}codespan(t){let r=this.rules.inline.code.exec(t);if(r){let i=r[2].replace(this.rules.other.newLineCharGlobal," "),s=this.rules.other.nonSpaceChar.test(i),a=this.rules.other.startingSpaceChar.test(i)&&this.rules.other.endingSpaceChar.test(i);return s&&a&&(i=i.substring(1,i.length-1)),{type:"codespan",raw:r[0],text:i}}}br(t){let r=this.rules.inline.br.exec(t);if(r)return{type:"br",raw:r[0]}}del(t){let r=this.rules.inline.del.exec(t);if(r)return{type:"del",raw:r[0],text:r[2],tokens:this.lexer.inlineTokens(r[2])}}autolink(t){let r=this.rules.inline.autolink.exec(t);if(r){let i,s;return r[2]==="@"?(i=r[1],s="mailto:"+i):(i=r[1],s=i),{type:"link",raw:r[0],text:i,href:s,tokens:[{type:"text",raw:i,text:i}]}}}url(t){var i;let r;if(r=this.rules.inline.url.exec(t)){let s,a;if(r[2]==="@")s=r[0],a="mailto:"+s;else{let o;do o=r[0],r[0]=((i=this.rules.inline._backpedal.exec(r[0]))==null?void 0:i[0])??"";while(o!==r[0]);s=r[0],r[1]==="www."?a="http://"+r[0]:a=r[0]}return{type:"link",raw:r[0],text:s,href:a,tokens:[{type:"text",raw:s,text:s}]}}}inlineText(t){let r=this.rules.inline.text.exec(t);if(r){let i=this.lexer.state.inRawBlock;return{type:"text",raw:r[0],text:r[0],escaped:i}}}},xe=class Xo{constructor(t){qt(this,"tokens");qt(this,"options");qt(this,"state");qt(this,"tokenizer");qt(this,"inlineQueue");this.tokens=[],this.tokens.links=Object.create(null),this.options=t||wr,this.options.tokenizer=this.options.tokenizer||new ea,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let r={other:ie,block:ms.normal,inline:wi.normal};this.options.pedantic?(r.block=ms.pedantic,r.inline=wi.pedantic):this.options.gfm&&(r.block=ms.gfm,this.options.breaks?r.inline=wi.breaks:r.inline=wi.gfm),this.tokenizer.rules=r}static get rules(){return{block:ms,inline:wi}}static lex(t,r){return new Xo(r).lex(t)}static lexInline(t,r){return new Xo(r).inlineTokens(t)}lex(t){t=t.replace(ie.carriageReturn,`
153
+ `),this.blockTokens(t,this.tokens);for(let r=0;r<this.inlineQueue.length;r++){let i=this.inlineQueue[r];this.inlineTokens(i.src,i.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,r=[],i=!1){var s,a,o;for(this.options.pedantic&&(t=t.replace(ie.tabCharGlobal," ").replace(ie.spaceLine,""));t;){let n;if((a=(s=this.options.extensions)==null?void 0:s.block)!=null&&a.some(c=>(n=c.call({lexer:this},t,r))?(t=t.substring(n.raw.length),r.push(n),!0):!1))continue;if(n=this.tokenizer.space(t)){t=t.substring(n.raw.length);let c=r.at(-1);n.raw.length===1&&c!==void 0?c.raw+=`
154
+ `:r.push(n);continue}if(n=this.tokenizer.code(t)){t=t.substring(n.raw.length);let c=r.at(-1);(c==null?void 0:c.type)==="paragraph"||(c==null?void 0:c.type)==="text"?(c.raw+=(c.raw.endsWith(`
155
+ `)?"":`
156
+ `)+n.raw,c.text+=`
157
+ `+n.text,this.inlineQueue.at(-1).src=c.text):r.push(n);continue}if(n=this.tokenizer.fences(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.heading(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.hr(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.blockquote(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.list(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.html(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.def(t)){t=t.substring(n.raw.length);let c=r.at(-1);(c==null?void 0:c.type)==="paragraph"||(c==null?void 0:c.type)==="text"?(c.raw+=(c.raw.endsWith(`
158
+ `)?"":`
159
+ `)+n.raw,c.text+=`
160
+ `+n.raw,this.inlineQueue.at(-1).src=c.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title},r.push(n));continue}if(n=this.tokenizer.table(t)){t=t.substring(n.raw.length),r.push(n);continue}if(n=this.tokenizer.lheading(t)){t=t.substring(n.raw.length),r.push(n);continue}let l=t;if((o=this.options.extensions)!=null&&o.startBlock){let c=1/0,h=t.slice(1),u;this.options.extensions.startBlock.forEach(d=>{u=d.call({lexer:this},h),typeof u=="number"&&u>=0&&(c=Math.min(c,u))}),c<1/0&&c>=0&&(l=t.substring(0,c+1))}if(this.state.top&&(n=this.tokenizer.paragraph(l))){let c=r.at(-1);i&&(c==null?void 0:c.type)==="paragraph"?(c.raw+=(c.raw.endsWith(`
161
+ `)?"":`
162
+ `)+n.raw,c.text+=`
163
+ `+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=c.text):r.push(n),i=l.length!==t.length,t=t.substring(n.raw.length);continue}if(n=this.tokenizer.text(t)){t=t.substring(n.raw.length);let c=r.at(-1);(c==null?void 0:c.type)==="text"?(c.raw+=(c.raw.endsWith(`
164
+ `)?"":`
165
+ `)+n.raw,c.text+=`
166
+ `+n.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=c.text):r.push(n);continue}if(t){let c="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(c);break}else throw new Error(c)}}return this.state.top=!0,r}inline(t,r=[]){return this.inlineQueue.push({src:t,tokens:r}),r}inlineTokens(t,r=[]){var l,c,h,u,d;let i=t,s=null;if(this.tokens.links){let f=Object.keys(this.tokens.links);if(f.length>0)for(;(s=this.tokenizer.rules.inline.reflinkSearch.exec(i))!=null;)f.includes(s[0].slice(s[0].lastIndexOf("[")+1,-1))&&(i=i.slice(0,s.index)+"["+"a".repeat(s[0].length-2)+"]"+i.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(s=this.tokenizer.rules.inline.anyPunctuation.exec(i))!=null;)i=i.slice(0,s.index)+"++"+i.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let a;for(;(s=this.tokenizer.rules.inline.blockSkip.exec(i))!=null;)a=s[2]?s[2].length:0,i=i.slice(0,s.index+a)+"["+"a".repeat(s[0].length-a-2)+"]"+i.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);i=((c=(l=this.options.hooks)==null?void 0:l.emStrongMask)==null?void 0:c.call({lexer:this},i))??i;let o=!1,n="";for(;t;){o||(n=""),o=!1;let f;if((u=(h=this.options.extensions)==null?void 0:h.inline)!=null&&u.some(m=>(f=m.call({lexer:this},t,r))?(t=t.substring(f.raw.length),r.push(f),!0):!1))continue;if(f=this.tokenizer.escape(t)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.tag(t)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.link(t)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(f.raw.length);let m=r.at(-1);f.type==="text"&&(m==null?void 0:m.type)==="text"?(m.raw+=f.raw,m.text+=f.text):r.push(f);continue}if(f=this.tokenizer.emStrong(t,i,n)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.codespan(t)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.br(t)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.del(t)){t=t.substring(f.raw.length),r.push(f);continue}if(f=this.tokenizer.autolink(t)){t=t.substring(f.raw.length),r.push(f);continue}if(!this.state.inLink&&(f=this.tokenizer.url(t))){t=t.substring(f.raw.length),r.push(f);continue}let y=t;if((d=this.options.extensions)!=null&&d.startInline){let m=1/0,C=t.slice(1),x;this.options.extensions.startInline.forEach(k=>{x=k.call({lexer:this},C),typeof x=="number"&&x>=0&&(m=Math.min(m,x))}),m<1/0&&m>=0&&(y=t.substring(0,m+1))}if(f=this.tokenizer.inlineText(y)){t=t.substring(f.raw.length),f.raw.slice(-1)!=="_"&&(n=f.raw.slice(-1)),o=!0;let m=r.at(-1);(m==null?void 0:m.type)==="text"?(m.raw+=f.raw,m.text+=f.text):r.push(f);continue}if(t){let m="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(m);break}else throw new Error(m)}}return r}},ra=class{constructor(t){qt(this,"options");qt(this,"parser");this.options=t||wr}space(t){return""}code({text:t,lang:r,escaped:i}){var o;let s=(o=(r||"").match(ie.notSpaceStart))==null?void 0:o[0],a=t.replace(ie.endingNewline,"")+`
167
+ `;return s?'<pre><code class="language-'+Be(s)+'">'+(i?a:Be(a,!0))+`</code></pre>
168
+ `:"<pre><code>"+(i?a:Be(a,!0))+`</code></pre>
169
+ `}blockquote({tokens:t}){return`<blockquote>
170
+ ${this.parser.parse(t)}</blockquote>
171
+ `}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:r}){return`<h${r}>${this.parser.parseInline(t)}</h${r}>
172
+ `}hr(t){return`<hr>
173
+ `}list(t){let r=t.ordered,i=t.start,s="";for(let n=0;n<t.items.length;n++){let l=t.items[n];s+=this.listitem(l)}let a=r?"ol":"ul",o=r&&i!==1?' start="'+i+'"':"";return"<"+a+o+`>
174
+ `+s+"</"+a+`>
175
+ `}listitem(t){var i;let r="";if(t.task){let s=this.checkbox({checked:!!t.checked});t.loose?((i=t.tokens[0])==null?void 0:i.type)==="paragraph"?(t.tokens[0].text=s+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&t.tokens[0].tokens[0].type==="text"&&(t.tokens[0].tokens[0].text=s+" "+Be(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:s+" ",text:s+" ",escaped:!0}):r+=s+" "}return r+=this.parser.parse(t.tokens,!!t.loose),`<li>${r}</li>
176
+ `}checkbox({checked:t}){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:t}){return`<p>${this.parser.parseInline(t)}</p>
177
+ `}table(t){let r="",i="";for(let a=0;a<t.header.length;a++)i+=this.tablecell(t.header[a]);r+=this.tablerow({text:i});let s="";for(let a=0;a<t.rows.length;a++){let o=t.rows[a];i="";for(let n=0;n<o.length;n++)i+=this.tablecell(o[n]);s+=this.tablerow({text:i})}return s&&(s=`<tbody>${s}</tbody>`),`<table>
178
+ <thead>
179
+ `+r+`</thead>
180
+ `+s+`</table>
181
+ `}tablerow({text:t}){return`<tr>
182
+ ${t}</tr>
183
+ `}tablecell(t){let r=this.parser.parseInline(t.tokens),i=t.header?"th":"td";return(t.align?`<${i} align="${t.align}">`:`<${i}>`)+r+`</${i}>
184
+ `}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${Be(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:r,tokens:i}){let s=this.parser.parseInline(i),a=Ph(t);if(a===null)return s;t=a;let o='<a href="'+t+'"';return r&&(o+=' title="'+Be(r)+'"'),o+=">"+s+"</a>",o}image({href:t,title:r,text:i,tokens:s}){s&&(i=this.parser.parseInline(s,this.parser.textRenderer));let a=Ph(t);if(a===null)return Be(i);t=a;let o=`<img src="${t}" alt="${i}"`;return r&&(o+=` title="${Be(r)}"`),o+=">",o}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:Be(t.text)}},tl=class{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}},Ce=class Go{constructor(t){qt(this,"options");qt(this,"renderer");qt(this,"textRenderer");this.options=t||wr,this.options.renderer=this.options.renderer||new ra,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new tl}static parse(t,r){return new Go(r).parse(t)}static parseInline(t,r){return new Go(r).parseInline(t)}parse(t,r=!0){var s,a;let i="";for(let o=0;o<t.length;o++){let n=t[o];if((a=(s=this.options.extensions)==null?void 0:s.renderers)!=null&&a[n.type]){let c=n,h=this.options.extensions.renderers[c.type].call({parser:this},c);if(h!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(c.type)){i+=h||"";continue}}let l=n;switch(l.type){case"space":{i+=this.renderer.space(l);continue}case"hr":{i+=this.renderer.hr(l);continue}case"heading":{i+=this.renderer.heading(l);continue}case"code":{i+=this.renderer.code(l);continue}case"table":{i+=this.renderer.table(l);continue}case"blockquote":{i+=this.renderer.blockquote(l);continue}case"list":{i+=this.renderer.list(l);continue}case"html":{i+=this.renderer.html(l);continue}case"def":{i+=this.renderer.def(l);continue}case"paragraph":{i+=this.renderer.paragraph(l);continue}case"text":{let c=l,h=this.renderer.text(c);for(;o+1<t.length&&t[o+1].type==="text";)c=t[++o],h+=`
185
+ `+this.renderer.text(c);r?i+=this.renderer.paragraph({type:"paragraph",raw:h,text:h,tokens:[{type:"text",raw:h,text:h,escaped:!0}]}):i+=h;continue}default:{let c='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(c),"";throw new Error(c)}}}return i}parseInline(t,r=this.renderer){var s,a;let i="";for(let o=0;o<t.length;o++){let n=t[o];if((a=(s=this.options.extensions)==null?void 0:s.renderers)!=null&&a[n.type]){let c=this.options.extensions.renderers[n.type].call({parser:this},n);if(c!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(n.type)){i+=c||"";continue}}let l=n;switch(l.type){case"escape":{i+=r.text(l);break}case"html":{i+=r.html(l);break}case"link":{i+=r.link(l);break}case"image":{i+=r.image(l);break}case"strong":{i+=r.strong(l);break}case"em":{i+=r.em(l);break}case"codespan":{i+=r.codespan(l);break}case"br":{i+=r.br(l);break}case"del":{i+=r.del(l);break}case"text":{i+=r.text(l);break}default:{let c='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(c),"";throw new Error(c)}}}return i}},Bs,$i=(Bs=class{constructor(t){qt(this,"options");qt(this,"block");this.options=t||wr}preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}emStrongMask(t){return t}provideLexer(){return this.block?xe.lex:xe.lexInline}provideParser(){return this.block?Ce.parse:Ce.parseInline}},qt(Bs,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),qt(Bs,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),Bs),d2=class{constructor(...t){qt(this,"defaults",Un());qt(this,"options",this.setOptions);qt(this,"parse",this.parseMarkdown(!0));qt(this,"parseInline",this.parseMarkdown(!1));qt(this,"Parser",Ce);qt(this,"Renderer",ra);qt(this,"TextRenderer",tl);qt(this,"Lexer",xe);qt(this,"Tokenizer",ea);qt(this,"Hooks",$i);this.use(...t)}walkTokens(t,r){var s,a;let i=[];for(let o of t)switch(i=i.concat(r.call(this,o)),o.type){case"table":{let n=o;for(let l of n.header)i=i.concat(this.walkTokens(l.tokens,r));for(let l of n.rows)for(let c of l)i=i.concat(this.walkTokens(c.tokens,r));break}case"list":{let n=o;i=i.concat(this.walkTokens(n.items,r));break}default:{let n=o;(a=(s=this.defaults.extensions)==null?void 0:s.childTokens)!=null&&a[n.type]?this.defaults.extensions.childTokens[n.type].forEach(l=>{let c=n[l].flat(1/0);i=i.concat(this.walkTokens(c,r))}):n.tokens&&(i=i.concat(this.walkTokens(n.tokens,r)))}}return i}use(...t){let r=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(i=>{let s={...i};if(s.async=this.defaults.async||s.async||!1,i.extensions&&(i.extensions.forEach(a=>{if(!a.name)throw new Error("extension name required");if("renderer"in a){let o=r.renderers[a.name];o?r.renderers[a.name]=function(...n){let l=a.renderer.apply(this,n);return l===!1&&(l=o.apply(this,n)),l}:r.renderers[a.name]=a.renderer}if("tokenizer"in a){if(!a.level||a.level!=="block"&&a.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let o=r[a.level];o?o.unshift(a.tokenizer):r[a.level]=[a.tokenizer],a.start&&(a.level==="block"?r.startBlock?r.startBlock.push(a.start):r.startBlock=[a.start]:a.level==="inline"&&(r.startInline?r.startInline.push(a.start):r.startInline=[a.start]))}"childTokens"in a&&a.childTokens&&(r.childTokens[a.name]=a.childTokens)}),s.extensions=r),i.renderer){let a=this.defaults.renderer||new ra(this.defaults);for(let o in i.renderer){if(!(o in a))throw new Error(`renderer '${o}' does not exist`);if(["options","parser"].includes(o))continue;let n=o,l=i.renderer[n],c=a[n];a[n]=(...h)=>{let u=l.apply(a,h);return u===!1&&(u=c.apply(a,h)),u||""}}s.renderer=a}if(i.tokenizer){let a=this.defaults.tokenizer||new ea(this.defaults);for(let o in i.tokenizer){if(!(o in a))throw new Error(`tokenizer '${o}' does not exist`);if(["options","rules","lexer"].includes(o))continue;let n=o,l=i.tokenizer[n],c=a[n];a[n]=(...h)=>{let u=l.apply(a,h);return u===!1&&(u=c.apply(a,h)),u}}s.tokenizer=a}if(i.hooks){let a=this.defaults.hooks||new $i;for(let o in i.hooks){if(!(o in a))throw new Error(`hook '${o}' does not exist`);if(["options","block"].includes(o))continue;let n=o,l=i.hooks[n],c=a[n];$i.passThroughHooks.has(o)?a[n]=h=>{if(this.defaults.async&&$i.passThroughHooksRespectAsync.has(o))return(async()=>{let d=await l.call(a,h);return c.call(a,d)})();let u=l.call(a,h);return c.call(a,u)}:a[n]=(...h)=>{if(this.defaults.async)return(async()=>{let d=await l.apply(a,h);return d===!1&&(d=await c.apply(a,h)),d})();let u=l.apply(a,h);return u===!1&&(u=c.apply(a,h)),u}}s.hooks=a}if(i.walkTokens){let a=this.defaults.walkTokens,o=i.walkTokens;s.walkTokens=function(n){let l=[];return l.push(o.call(this,n)),a&&(l=l.concat(a.call(this,n))),l}}this.defaults={...this.defaults,...s}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,r){return xe.lex(t,r??this.defaults)}parser(t,r){return Ce.parse(t,r??this.defaults)}parseMarkdown(t){return(r,i)=>{let s={...i},a={...this.defaults,...s},o=this.onError(!!a.silent,!!a.async);if(this.defaults.async===!0&&s.async===!1)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof r>"u"||r===null)return o(new Error("marked(): input parameter is undefined or null"));if(typeof r!="string")return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(r)+", string expected"));if(a.hooks&&(a.hooks.options=a,a.hooks.block=t),a.async)return(async()=>{let n=a.hooks?await a.hooks.preprocess(r):r,l=await(a.hooks?await a.hooks.provideLexer():t?xe.lex:xe.lexInline)(n,a),c=a.hooks?await a.hooks.processAllTokens(l):l;a.walkTokens&&await Promise.all(this.walkTokens(c,a.walkTokens));let h=await(a.hooks?await a.hooks.provideParser():t?Ce.parse:Ce.parseInline)(c,a);return a.hooks?await a.hooks.postprocess(h):h})().catch(o);try{a.hooks&&(r=a.hooks.preprocess(r));let n=(a.hooks?a.hooks.provideLexer():t?xe.lex:xe.lexInline)(r,a);a.hooks&&(n=a.hooks.processAllTokens(n)),a.walkTokens&&this.walkTokens(n,a.walkTokens);let l=(a.hooks?a.hooks.provideParser():t?Ce.parse:Ce.parseInline)(n,a);return a.hooks&&(l=a.hooks.postprocess(l)),l}catch(n){return o(n)}}}onError(t,r){return i=>{if(i.message+=`
186
+ Please report this to https://github.com/markedjs/marked.`,t){let s="<p>An error occurred:</p><pre>"+Be(i.message+"",!0)+"</pre>";return r?Promise.resolve(s):s}if(r)return Promise.reject(i);throw i}}},mr=new d2;function It(e,t){return mr.parse(e,t)}It.options=It.setOptions=function(e){return mr.setOptions(e),It.defaults=mr.defaults,Jd(It.defaults),It};It.getDefaults=Un;It.defaults=wr;It.use=function(...e){return mr.use(...e),It.defaults=mr.defaults,Jd(It.defaults),It};It.walkTokens=function(e,t){return mr.walkTokens(e,t)};It.parseInline=mr.parseInline;It.Parser=Ce;It.parser=Ce.parse;It.Renderer=ra;It.TextRenderer=tl;It.Lexer=xe;It.lexer=xe.lex;It.Tokenizer=ea;It.Hooks=$i;It.parse=It;It.options;It.setOptions;It.use;It.walkTokens;It.parseInline;Ce.parse;xe.lex;function uf(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var i=Array.from(typeof e=="string"?[e]:e);i[i.length-1]=i[i.length-1].replace(/\r?\n([\t ]*)$/,"");var s=i.reduce(function(n,l){var c=l.match(/\n([\t ]+|(?!\s).)/g);return c?n.concat(c.map(function(h){var u,d;return(d=(u=h.match(/[\t ]/g))===null||u===void 0?void 0:u.length)!==null&&d!==void 0?d:0})):n},[]);if(s.length){var a=new RegExp(`
187
+ [ ]{`.concat(Math.min.apply(Math,s),"}"),"g");i=i.map(function(n){return n.replace(a,`
188
+ `)})}i[0]=i[0].replace(/^\r?\n/,"");var o=i[0];return t.forEach(function(n,l){var c=o.match(/(?:^|\n)( *)$/),h=c?c[1]:"",u=n;typeof n=="string"&&n.includes(`
189
+ `)&&(u=String(n).split(`
190
+ `).map(function(d,f){return f===0?d:"".concat(h).concat(d)}).join(`
191
+ `)),o+=u+i[l+1]}),o}var Vo=typeof performance<"u"&&typeof performance.now=="function",Ar=p(()=>Vo?performance.now():0,"now"),za="🧜 ",f2="Mermaid render",p2="Mermaid",g2={parse:"tertiary",prepare:"secondary",measure:"primary",layout:"primary-dark",layoutCore:"error",draw:"primary-light",paint:"secondary-dark",serialize:"tertiary-dark",render:"primary-light"},ei;ei=class{constructor(){this.enabled=!1,this.autoPrint=!0,this.records=[],this.maxRecords=200,this.roots=[],this.stack=[],this.buckets={}}enable(){return this.enabled=!0,this}disable(){return this.enabled=!1,this}start(t){this.enabled&&(this.roots=[],this.stack=[],this.buckets={},this.begin(t))}tickSync(t,r){if(!this.enabled)return r();const i=Ar();try{return r()}finally{this.buckets[t]=(this.buckets[t]??0)+(Ar()-i)}}async tick(t,r){if(!this.enabled)return r();const i=Ar();try{return await r()}finally{this.buckets[t]=(this.buckets[t]??0)+(Ar()-i)}}stop(){if(!this.enabled)return;for(;this.stack.length>0;)this.end();const t=this.roots.at(-1),r=this.runLabel??(t==null?void 0:t.name);return t&&(this.records.push({label:r??t.name,tree:t,buckets:{...this.buckets}}),this.records.length>this.maxRecords&&this.records.splice(0,this.records.length-this.maxRecords),this.autoPrint&&this.printSummary(t,r)),this.runLabel=void 0,t}begin(t){if(!this.enabled)return;const r={name:t,start:Ar(),duration:-1,children:[]},i=this.stack.at(-1);if(i?i.children.push(r):this.roots.push(r),this.stack.push(r),Vo&&typeof performance.mark=="function")try{performance.mark(`${za}${t} ▶`)}catch{}}end(){if(!this.enabled)return;const t=this.stack.pop();if(!t)return;const r=Ar();if(t.duration=r-t.start,Vo&&typeof performance.measure=="function")try{performance.measure(`${za}${t.name}`,{start:t.start,end:r,detail:{devtools:{dataType:"track-entry",track:f2,trackGroup:p2,color:g2[t.name]??"primary",tooltipText:`${t.name} — ${t.duration.toFixed(1)} ms`}}})}catch{}}async span(t,r){if(!this.enabled)return r();this.begin(t);try{return await r()}finally{this.end()}}report(){var t;return((t=this.records.at(-1))==null?void 0:t.tree)??this.roots.at(-1)}clear(){this.records.length=0,this.roots=[],this.stack=[],this.runLabel=void 0}reset(){this.roots=[],this.stack=[]}printSummary(t=this.report(),r){if(!t)return;const i=t.duration,s=r&&r!==t.name?`${t.name} [${r}]`:t.name,a=["ms % phase"],o=p((l,c)=>{const h=" ".repeat(c),u=l.duration.toFixed(1).padStart(8),d=i>0?`${(l.duration/i*100).toFixed(0).padStart(3)}%`:" -";a.push(`${u} ${d} ${h}${l.name}`);for(const f of l.children)o(f,c+1);if(l.children.length>0){const f=l.children.reduce((m,C)=>m+C.duration,0),y=l.duration-f;if(y>.5){const m=y.toFixed(1).padStart(8);a.push(`${m} ${h} (self)`)}}},"walk");o(t,0);const n=Object.keys(this.buckets);if(n.length>0){a.push("—— buckets (summed) ——");for(const l of n)a.push(`${this.buckets[l].toFixed(1).padStart(8)} ${l}`)}console.log(`${za}mermaid render profile · ${s}
192
+ ${a.join(`
193
+ `)}`)}},p(ei,"Profiler");globalThis.injected??(globalThis.injected={includeLargeFeatures:!0,profiling:!1,version:"0.0.0"});var y2=Bk.extend({raf(e){typeof queueMicrotask=="function"?queueMicrotask(e):setTimeout(e,0)}}).extend(Fk),xr=y2;function df(e,{markdownAutoWrap:t}){const i=e.replace(/<br\/>/g,`
194
+ `).replace(/\n{2,}/g,`
195
+ `);return uf(i)}p(df,"preprocessMarkdown");function ff(e){return e.split(/\\n|\n|<br\s*\/?>/gi).map(t=>{var r;return((r=t.trim().match(/<[^>]+>|[^\s<>]+/g))==null?void 0:r.map(i=>({content:i,type:"normal"})))??[]})}p(ff,"nonMarkdownToLines");function pf(e,t={}){const r=df(e,t),i=It.lexer(r),s=[[]];let a=0;function o(n,l="normal"){n.type==="text"?n.text.split(`
196
+ `).forEach((h,u)=>{u!==0&&(a++,s.push([])),h.split(" ").forEach(d=>{d=d.replace(/&#39;/g,"'"),d&&s[a].push({content:d,type:l})})}):n.type==="strong"||n.type==="em"?n.tokens.forEach(c=>{o(c,n.type)}):n.type==="html"&&s[a].push({content:n.text,type:"normal"})}return p(o,"processNode"),i.forEach(n=>{var l;n.type==="paragraph"?(l=n.tokens)==null||l.forEach(c=>{o(c)}):n.type==="html"?s[a].push({content:n.text,type:"normal"}):s[a].push({content:n.raw,type:"normal"})}),s}p(pf,"markdownToLines");function gf(e){return e?`<p>${e.replace(/\\n|\n/g,"<br />")}</p>`:""}p(gf,"nonMarkdownToHTML");function yf(e,{markdownAutoWrap:t}={}){const r=It.lexer(e);function i(s){var a,o,n;return s.type==="text"?t===!1?s.text.replace(/\n */g,"<br/>").replace(/ /g,"&nbsp;"):s.text.replace(/\n */g,"<br/>"):s.type==="strong"?`<strong>${(a=s.tokens)==null?void 0:a.map(i).join("")}</strong>`:s.type==="em"?`<em>${(o=s.tokens)==null?void 0:o.map(i).join("")}</em>`:s.type==="paragraph"?`<p>${(n=s.tokens)==null?void 0:n.map(i).join("")}</p>`:s.type==="space"?"":s.type==="html"?`${s.text}`:s.type==="escape"?s.text:(I.warn(`Unsupported markdown: ${s.type}`),s.raw)}return p(i,"output"),r.map(i).join("")}p(yf,"markdownToHTML");function mf(e){return Intl.Segmenter?[...new Intl.Segmenter().segment(e)].map(t=>t.segment):[...e]}p(mf,"splitTextToChars");function xf(e,t){const r=mf(t.content);return el(e,[],r,t.type)}p(xf,"splitWordToFitWidth");function el(e,t,r,i){if(r.length===0)return[{content:t.join(""),type:i},{content:"",type:i}];const[s,...a]=r,o=[...t,s];return e([{content:o.join(""),type:i}])?el(e,o,a,i):(t.length===0&&s&&(t.push(s),r.shift()),[{content:t.join(""),type:i},{content:r.join(""),type:i}])}p(el,"splitWordToFitWidthRecursion");function Cf(e,t){if(e.some(({content:r})=>r.includes(`
197
+ `)))throw new Error("splitLineToFitWidth does not support newlines in the line");return ia(e,t)}p(Cf,"splitLineToFitWidth");function ia(e,t,r=[],i=[]){if(e.length===0)return i.length>0&&r.push(i),r.length>0?r:[];let s="";e[0].content===" "&&(s=" ",e.shift());const a=e.shift()??{content:" ",type:"normal"},o=[...i];if(s!==""&&o.push({content:s,type:"normal"}),o.push(a),t(o))return ia(e,t,r,o);if(i.length>0)r.push(i),e.unshift(a);else if(a.content){const[n,l]=xf(t,a);r.push([n]),l.content&&e.unshift(l)}return ia(e,t,r)}p(ia,"splitLineToFitWidthRecursion");function Zo(e,t){t&&e.attr("style",t)}p(Zo,"applyStyle");var qh=16384;async function bf(e,t,r,i,s=!1,a=Ht()){const o=e.append("foreignObject");o.attr("width",`${Math.min(10*r,qh)}px`),o.attr("height",`${Math.min(10*r,qh)}px`);const n=o.append("xhtml:div"),l=Ui(t.label)?await zu(t.label.replace(os.lineBreakRegex,`
198
+ `),a):de(t.label,a),c=t.isNode?"nodeLabel":"edgeLabel",h=n.append("span");return h.html(l),Zo(h,t.labelStyle),h.attr("class",`${c} ${i}`),Zo(n,t.labelStyle),n.style("display","table-cell"),n.style("white-space","nowrap"),n.style("line-height","1.5"),r!==Number.POSITIVE_INFINITY&&(n.style("max-width",r+"px"),n.style("text-align","center")),n.attr("xmlns","http://www.w3.org/1999/xhtml"),s&&n.attr("class","labelBkg"),(await xr.measure(()=>n.node().getBoundingClientRect())).width===r&&(n.style("display","table"),n.style("white-space","break-spaces"),n.style("width",r+"px")),o.node()}p(bf,"addHtmlSpan");function ba(e,t,r,i=!1){const s=e.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",t*r-.1+"em").attr("dy",r+"em");return i&&s.attr("text-anchor","middle"),s}p(ba,"createTspan");function kf(e,t,r){const i=e.append("text"),s=ba(i,1,t);ka(s,r);const a=s.node().getComputedTextLength();return i.remove(),a}p(kf,"computeWidthOfText");function m2(e,t,r){var o;const i=e.append("text"),s=ba(i,1,t);ka(s,[{content:r,type:"normal"}]);const a=(o=s.node())==null?void 0:o.getBoundingClientRect();return a&&i.remove(),a}p(m2,"computeDimensionOfText");function wf(e,t,r,i=!1,s=!1){const o=t.append("g"),n=o.insert("rect").attr("class","background").attr("style","stroke: none"),l=o.append("text").attr("y","-10.1");s&&l.attr("text-anchor","middle");let c=0;for(const h of r){const u=p(f=>kf(o,1.1,f)<=e,"checkWidth"),d=u(h)?[h]:Cf(h,u);for(const f of d){const y=ba(l,c,1.1,s);ka(y,f),c++}}if(i){const h=l.node().getBBox(),u=2;return n.attr("x",h.x-u).attr("y",h.y-u).attr("width",h.width+2*u).attr("height",h.height+2*u),o.node()}else return l.node()}p(wf,"createFormattedText");function Ko(e){const t=/&(amp|lt|gt);/g;return e.replace(t,(r,i)=>{switch(i){case"amp":return"&";case"lt":return"<";case"gt":return">";default:return r}})}p(Ko,"decodeHTMLEntities");function ka(e,t){e.text(""),t.forEach((r,i)=>{const s=e.append("tspan").attr("font-style",r.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",r.type==="strong"?"bold":"normal");i===0?s.text(Ko(r.content)):s.text(" "+Ko(r.content))})}p(ka,"updateTextContentAndStyles");async function Sf(e,t={}){const r=[];e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(s,a,o)=>(r.push((async()=>{const n=`${a}:${o}`;return await rk(n)?await hs(n,void 0,{class:"label-icon"}):`<i class='${de(s,t).replace(":"," ")}'></i>`})()),s));const i=await Promise.all(r);return e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>i.shift()??"")}p(Sf,"replaceIconSubstring");var Te=p(async(e,t="",{style:r="",isTitle:i=!1,classes:s="",useHtmlLabels:a=!0,markdown:o=!0,isNode:n=!0,width:l=200,addSvgBackground:c=!1}={},h)=>{if(I.debug("XYZ createText",t,r,i,s,a,n,"addSvgBackground: ",c),a){const u=o?yf(t,h):gf(t),d=await Sf(er(u),h),f=t.replace(/\\\\/g,"\\"),y={isNode:n,label:Ui(t)?f:d,labelStyle:r.replace("fill:","color:")};return await bf(e,y,l,s,c,h)}else{const u=er(t.replace(/<br\s*\/?>/g,"<br/>")),d=o?pf(u.replace("<br>","<br/>"),h):ff(u),f=wf(l,e,d,t?c:!1,!n);if(n){/stroke:/.exec(r)&&(r=r.replace("stroke:","lineColor:"));const y=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");Lt(f).attr("style",y)}else{const y=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");Lt(f).select("rect").attr("style",y.replace(/background:/g,"fill:"));const m=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");Lt(f).select("text").attr("style",m)}return i?Lt(f).selectAll("tspan.text-outer-tspan").classed("title-row",!0):Lt(f).selectAll("tspan.text-outer-tspan").classed("row",!0),f}},"createText");function Ha(e,t,r){if(e&&e.length){const[i,s]=t,a=Math.PI/180*r,o=Math.cos(a),n=Math.sin(a);for(const l of e){const[c,h]=l;l[0]=(c-i)*o-(h-s)*n+i,l[1]=(c-i)*n+(h-s)*o+s}}}function x2(e,t){return e[0]===t[0]&&e[1]===t[1]}function C2(e,t,r,i=1){const s=r,a=Math.max(t,.1),o=e[0]&&e[0][0]&&typeof e[0][0]=="number"?[e]:e,n=[0,0];if(s)for(const c of o)Ha(c,n,s);const l=(function(c,h,u){const d=[];for(const k of c){const w=[...k];x2(w[0],w[w.length-1])||w.push([w[0][0],w[0][1]]),w.length>2&&d.push(w)}const f=[];h=Math.max(h,.1);const y=[];for(const k of d)for(let w=0;w<k.length-1;w++){const T=k[w],_=k[w+1];if(T[1]!==_[1]){const v=Math.min(T[1],_[1]);y.push({ymin:v,ymax:Math.max(T[1],_[1]),x:v===T[1]?T[0]:_[0],islope:(_[0]-T[0])/(_[1]-T[1])})}}if(y.sort(((k,w)=>k.ymin<w.ymin?-1:k.ymin>w.ymin?1:k.x<w.x?-1:k.x>w.x?1:k.ymax===w.ymax?0:(k.ymax-w.ymax)/Math.abs(k.ymax-w.ymax))),!y.length)return f;let m=[],C=y[0].ymin,x=0;for(;m.length||y.length;){if(y.length){let k=-1;for(let w=0;w<y.length&&!(y[w].ymin>C);w++)k=w;y.splice(0,k+1).forEach((w=>{m.push({s:C,edge:w})}))}if(m=m.filter((k=>!(k.edge.ymax<=C))),m.sort(((k,w)=>k.edge.x===w.edge.x?0:(k.edge.x-w.edge.x)/Math.abs(k.edge.x-w.edge.x))),(u!==1||x%h==0)&&m.length>1)for(let k=0;k<m.length;k+=2){const w=k+1;if(w>=m.length)break;const T=m[k].edge,_=m[w].edge;f.push([[Math.round(T.x),C],[Math.round(_.x),C]])}C+=u,m.forEach((k=>{k.edge.x=k.edge.x+u*k.edge.islope})),x++}return f})(o,a,i);if(s){for(const c of o)Ha(c,n,-s);(function(c,h,u){const d=[];c.forEach((f=>d.push(...f))),Ha(d,h,u)})(l,n,-s)}return l}function us(e,t){var r;const i=t.hachureAngle+90;let s=t.hachureGap;s<0&&(s=4*t.strokeWidth),s=Math.round(Math.max(s,.1));let a=1;return t.roughness>=1&&(((r=t.randomizer)===null||r===void 0?void 0:r.next())||Math.random())>.7&&(a=s),C2(e,s,i,a||1)}class rl{constructor(t){this.helper=t}fillPolygons(t,r){return this._fillPolygons(t,r)}_fillPolygons(t,r){const i=us(t,r);return{type:"fillSketch",ops:this.renderLines(i,r)}}renderLines(t,r){const i=[];for(const s of t)i.push(...this.helper.doubleLineOps(s[0][0],s[0][1],s[1][0],s[1][1],r));return i}}function wa(e){const t=e[0],r=e[1];return Math.sqrt(Math.pow(t[0]-r[0],2)+Math.pow(t[1]-r[1],2))}class b2 extends rl{fillPolygons(t,r){let i=r.hachureGap;i<0&&(i=4*r.strokeWidth),i=Math.max(i,.1);const s=us(t,Object.assign({},r,{hachureGap:i})),a=Math.PI/180*r.hachureAngle,o=[],n=.5*i*Math.cos(a),l=.5*i*Math.sin(a);for(const[c,h]of s)wa([c,h])&&o.push([[c[0]-n,c[1]+l],[...h]],[[c[0]+n,c[1]-l],[...h]]);return{type:"fillSketch",ops:this.renderLines(o,r)}}}class k2 extends rl{fillPolygons(t,r){const i=this._fillPolygons(t,r),s=Object.assign({},r,{hachureAngle:r.hachureAngle+90}),a=this._fillPolygons(t,s);return i.ops=i.ops.concat(a.ops),i}}class w2{constructor(t){this.helper=t}fillPolygons(t,r){const i=us(t,r=Object.assign({},r,{hachureAngle:0}));return this.dotsOnLines(i,r)}dotsOnLines(t,r){const i=[];let s=r.hachureGap;s<0&&(s=4*r.strokeWidth),s=Math.max(s,.1);let a=r.fillWeight;a<0&&(a=r.strokeWidth/2);const o=s/4;for(const n of t){const l=wa(n),c=l/s,h=Math.ceil(c)-1,u=l-h*s,d=(n[0][0]+n[1][0])/2-s/4,f=Math.min(n[0][1],n[1][1]);for(let y=0;y<h;y++){const m=f+u+y*s,C=d-o+2*Math.random()*o,x=m-o+2*Math.random()*o,k=this.helper.ellipse(C,x,a,a,r);i.push(...k.ops)}}return{type:"fillSketch",ops:i}}}class S2{constructor(t){this.helper=t}fillPolygons(t,r){const i=us(t,r);return{type:"fillSketch",ops:this.dashedLine(i,r)}}dashedLine(t,r){const i=r.dashOffset<0?r.hachureGap<0?4*r.strokeWidth:r.hachureGap:r.dashOffset,s=r.dashGap<0?r.hachureGap<0?4*r.strokeWidth:r.hachureGap:r.dashGap,a=[];return t.forEach((o=>{const n=wa(o),l=Math.floor(n/(i+s)),c=(n+s-l*(i+s))/2;let h=o[0],u=o[1];h[0]>u[0]&&(h=o[1],u=o[0]);const d=Math.atan((u[1]-h[1])/(u[0]-h[0]));for(let f=0;f<l;f++){const y=f*(i+s),m=y+i,C=[h[0]+y*Math.cos(d)+c*Math.cos(d),h[1]+y*Math.sin(d)+c*Math.sin(d)],x=[h[0]+m*Math.cos(d)+c*Math.cos(d),h[1]+m*Math.sin(d)+c*Math.sin(d)];a.push(...this.helper.doubleLineOps(C[0],C[1],x[0],x[1],r))}})),a}}class T2{constructor(t){this.helper=t}fillPolygons(t,r){const i=r.hachureGap<0?4*r.strokeWidth:r.hachureGap,s=r.zigzagOffset<0?i:r.zigzagOffset,a=us(t,r=Object.assign({},r,{hachureGap:i+s}));return{type:"fillSketch",ops:this.zigzagLines(a,s,r)}}zigzagLines(t,r,i){const s=[];return t.forEach((a=>{const o=wa(a),n=Math.round(o/(2*r));let l=a[0],c=a[1];l[0]>c[0]&&(l=a[1],c=a[0]);const h=Math.atan((c[1]-l[1])/(c[0]-l[0]));for(let u=0;u<n;u++){const d=2*u*r,f=2*(u+1)*r,y=Math.sqrt(2*Math.pow(r,2)),m=[l[0]+d*Math.cos(h),l[1]+d*Math.sin(h)],C=[l[0]+f*Math.cos(h),l[1]+f*Math.sin(h)],x=[m[0]+y*Math.cos(h+Math.PI/4),m[1]+y*Math.sin(h+Math.PI/4)];s.push(...this.helper.doubleLineOps(m[0],m[1],x[0],x[1],i),...this.helper.doubleLineOps(x[0],x[1],C[0],C[1],i))}})),s}}const se={};class _2{constructor(t){this.seed=t}next(){return this.seed?(2**31-1&(this.seed=Math.imul(48271,this.seed)))/2**31:Math.random()}}const B2=0,Ya=1,Nh=2,xs={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function ja(e,t){return e.type===t}function il(e){const t=[],r=(function(o){const n=new Array;for(;o!=="";)if(o.match(/^([ \t\r\n,]+)/))o=o.substr(RegExp.$1.length);else if(o.match(/^([aAcChHlLmMqQsStTvVzZ])/))n[n.length]={type:B2,text:RegExp.$1},o=o.substr(RegExp.$1.length);else{if(!o.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];n[n.length]={type:Ya,text:`${parseFloat(RegExp.$1)}`},o=o.substr(RegExp.$1.length)}return n[n.length]={type:Nh,text:""},n})(e);let i="BOD",s=0,a=r[s];for(;!ja(a,Nh);){let o=0;const n=[];if(i==="BOD"){if(a.text!=="M"&&a.text!=="m")return il("M0,0"+e);s++,o=xs[a.text],i=a.text}else ja(a,Ya)?o=xs[i]:(s++,o=xs[a.text],i=a.text);if(!(s+o<r.length))throw new Error("Path data ended short");for(let l=s;l<s+o;l++){const c=r[l];if(!ja(c,Ya))throw new Error("Param not a number: "+i+","+c.text);n[n.length]=+c.text}if(typeof xs[i]!="number")throw new Error("Bad segment: "+i);{const l={key:i,data:n};t.push(l),s+=o,a=r[s],i==="M"&&(i="L"),i==="m"&&(i="l")}}return t}function Tf(e){let t=0,r=0,i=0,s=0;const a=[];for(const{key:o,data:n}of e)switch(o){case"M":a.push({key:"M",data:[...n]}),[t,r]=n,[i,s]=n;break;case"m":t+=n[0],r+=n[1],a.push({key:"M",data:[t,r]}),i=t,s=r;break;case"L":a.push({key:"L",data:[...n]}),[t,r]=n;break;case"l":t+=n[0],r+=n[1],a.push({key:"L",data:[t,r]});break;case"C":a.push({key:"C",data:[...n]}),t=n[4],r=n[5];break;case"c":{const l=n.map(((c,h)=>h%2?c+r:c+t));a.push({key:"C",data:l}),t=l[4],r=l[5];break}case"Q":a.push({key:"Q",data:[...n]}),t=n[2],r=n[3];break;case"q":{const l=n.map(((c,h)=>h%2?c+r:c+t));a.push({key:"Q",data:l}),t=l[2],r=l[3];break}case"A":a.push({key:"A",data:[...n]}),t=n[5],r=n[6];break;case"a":t+=n[5],r+=n[6],a.push({key:"A",data:[n[0],n[1],n[2],n[3],n[4],t,r]});break;case"H":a.push({key:"H",data:[...n]}),t=n[0];break;case"h":t+=n[0],a.push({key:"H",data:[t]});break;case"V":a.push({key:"V",data:[...n]}),r=n[0];break;case"v":r+=n[0],a.push({key:"V",data:[r]});break;case"S":a.push({key:"S",data:[...n]}),t=n[2],r=n[3];break;case"s":{const l=n.map(((c,h)=>h%2?c+r:c+t));a.push({key:"S",data:l}),t=l[2],r=l[3];break}case"T":a.push({key:"T",data:[...n]}),t=n[0],r=n[1];break;case"t":t+=n[0],r+=n[1],a.push({key:"T",data:[t,r]});break;case"Z":case"z":a.push({key:"Z",data:[]}),t=i,r=s}return a}function _f(e){const t=[];let r="",i=0,s=0,a=0,o=0,n=0,l=0;for(const{key:c,data:h}of e){switch(c){case"M":t.push({key:"M",data:[...h]}),[i,s]=h,[a,o]=h;break;case"C":t.push({key:"C",data:[...h]}),i=h[4],s=h[5],n=h[2],l=h[3];break;case"L":t.push({key:"L",data:[...h]}),[i,s]=h;break;case"H":i=h[0],t.push({key:"L",data:[i,s]});break;case"V":s=h[0],t.push({key:"L",data:[i,s]});break;case"S":{let u=0,d=0;r==="C"||r==="S"?(u=i+(i-n),d=s+(s-l)):(u=i,d=s),t.push({key:"C",data:[u,d,...h]}),n=h[0],l=h[1],i=h[2],s=h[3];break}case"T":{const[u,d]=h;let f=0,y=0;r==="Q"||r==="T"?(f=i+(i-n),y=s+(s-l)):(f=i,y=s);const m=i+2*(f-i)/3,C=s+2*(y-s)/3,x=u+2*(f-u)/3,k=d+2*(y-d)/3;t.push({key:"C",data:[m,C,x,k,u,d]}),n=f,l=y,i=u,s=d;break}case"Q":{const[u,d,f,y]=h,m=i+2*(u-i)/3,C=s+2*(d-s)/3,x=f+2*(u-f)/3,k=y+2*(d-y)/3;t.push({key:"C",data:[m,C,x,k,f,y]}),n=u,l=d,i=f,s=y;break}case"A":{const u=Math.abs(h[0]),d=Math.abs(h[1]),f=h[2],y=h[3],m=h[4],C=h[5],x=h[6];u===0||d===0?(t.push({key:"C",data:[i,s,C,x,C,x]}),i=C,s=x):(i!==C||s!==x)&&(Bf(i,s,C,x,u,d,f,y,m).forEach((function(k){t.push({key:"C",data:k})})),i=C,s=x);break}case"Z":t.push({key:"Z",data:[]}),i=a,s=o}r=c}return t}function Ti(e,t,r){return[e*Math.cos(r)-t*Math.sin(r),e*Math.sin(r)+t*Math.cos(r)]}function Bf(e,t,r,i,s,a,o,n,l,c){const h=(u=o,Math.PI*u/180);var u;let d=[],f=0,y=0,m=0,C=0;if(c)[f,y,m,C]=c;else{[e,t]=Ti(e,t,-h),[r,i]=Ti(r,i,-h);const Y=(e-r)/2,A=(t-i)/2;let E=Y*Y/(s*s)+A*A/(a*a);E>1&&(E=Math.sqrt(E),s*=E,a*=E);const B=s*s,D=a*a,$=B*D-B*A*A-D*Y*Y,N=B*A*A+D*Y*Y,V=(n===l?-1:1)*Math.sqrt(Math.abs($/N));m=V*s*A/a+(e+r)/2,C=V*-a*Y/s+(t+i)/2,f=Math.asin(parseFloat(((t-C)/a).toFixed(9))),y=Math.asin(parseFloat(((i-C)/a).toFixed(9))),e<m&&(f=Math.PI-f),r<m&&(y=Math.PI-y),f<0&&(f=2*Math.PI+f),y<0&&(y=2*Math.PI+y),l&&f>y&&(f-=2*Math.PI),!l&&y>f&&(y-=2*Math.PI)}let x=y-f;if(Math.abs(x)>120*Math.PI/180){const Y=y,A=r,E=i;y=l&&y>f?f+120*Math.PI/180*1:f+120*Math.PI/180*-1,d=Bf(r=m+s*Math.cos(y),i=C+a*Math.sin(y),A,E,s,a,o,0,l,[y,Y,m,C])}x=y-f;const k=Math.cos(f),w=Math.sin(f),T=Math.cos(y),_=Math.sin(y),v=Math.tan(x/4),F=4/3*s*v,L=4/3*a*v,U=[e,t],W=[e+F*w,t-L*k],q=[r+F*_,i-L*T],rt=[r,i];if(W[0]=2*U[0]-W[0],W[1]=2*U[1]-W[1],c)return[W,q,rt].concat(d);{d=[W,q,rt].concat(d);const Y=[];for(let A=0;A<d.length;A+=3){const E=Ti(d[A][0],d[A][1],h),B=Ti(d[A+1][0],d[A+1][1],h),D=Ti(d[A+2][0],d[A+2][1],h);Y.push([E[0],E[1],B[0],B[1],D[0],D[1]])}return Y}}const v2={randOffset:function(e,t){return St(e,t)},randOffsetWithRange:function(e,t,r){return sa(e,t,r)},ellipse:function(e,t,r,i,s){const a=Lf(r,i,s);return Qo(e,t,s,a).opset},doubleLineOps:function(e,t,r,i,s){return rr(e,t,r,i,s,!0)}};function vf(e,t,r,i,s){return{type:"path",ops:rr(e,t,r,i,s)}}function Ds(e,t,r){const i=(e||[]).length;if(i>2){const s=[];for(let a=0;a<i-1;a++)s.push(...rr(e[a][0],e[a][1],e[a+1][0],e[a+1][1],r));return t&&s.push(...rr(e[i-1][0],e[i-1][1],e[0][0],e[0][1],r)),{type:"path",ops:s}}return i===2?vf(e[0][0],e[0][1],e[1][0],e[1][1],r):{type:"path",ops:[]}}function L2(e,t,r,i,s){return(function(a,o){return Ds(a,!0,o)})([[e,t],[e+r,t],[e+r,t+i],[e,t+i]],s)}function Wh(e,t){if(e.length){const r=typeof e[0][0]=="number"?[e]:e,i=Cs(r[0],1*(1+.2*t.roughness),t),s=t.disableMultiStroke?[]:Cs(r[0],1.5*(1+.22*t.roughness),Yh(t));for(let a=1;a<r.length;a++){const o=r[a];if(o.length){const n=Cs(o,1*(1+.2*t.roughness),t),l=t.disableMultiStroke?[]:Cs(o,1.5*(1+.22*t.roughness),Yh(t));for(const c of n)c.op!=="move"&&i.push(c);for(const c of l)c.op!=="move"&&s.push(c)}}return{type:"path",ops:i.concat(s)}}return{type:"path",ops:[]}}function Lf(e,t,r){const i=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(e/2,2)+Math.pow(t/2,2))/2)),s=Math.ceil(Math.max(r.curveStepCount,r.curveStepCount/Math.sqrt(200)*i)),a=2*Math.PI/s;let o=Math.abs(e/2),n=Math.abs(t/2);const l=1-r.curveFitting;return o+=St(o*l,r),n+=St(n*l,r),{increment:a,rx:o,ry:n}}function Qo(e,t,r,i){const[s,a]=jh(i.increment,e,t,i.rx,i.ry,1,i.increment*sa(.1,sa(.4,1,r),r),r);let o=aa(s,null,r);if(!r.disableMultiStroke&&r.roughness!==0){const[n]=jh(i.increment,e,t,i.rx,i.ry,1.5,0,r),l=aa(n,null,r);o=o.concat(l)}return{estimatedPoints:a,opset:{type:"path",ops:o}}}function zh(e,t,r,i,s,a,o,n,l){const c=e,h=t;let u=Math.abs(r/2),d=Math.abs(i/2);u+=St(.01*u,l),d+=St(.01*d,l);let f=s,y=a;for(;f<0;)f+=2*Math.PI,y+=2*Math.PI;y-f>2*Math.PI&&(f=0,y=2*Math.PI);const m=2*Math.PI/l.curveStepCount,C=Math.min(m/2,(y-f)/2),x=Uh(C,c,h,u,d,f,y,1,l);if(!l.disableMultiStroke){const k=Uh(C,c,h,u,d,f,y,1.5,l);x.push(...k)}return o&&(n?x.push(...rr(c,h,c+u*Math.cos(f),h+d*Math.sin(f),l),...rr(c,h,c+u*Math.cos(y),h+d*Math.sin(y),l)):x.push({op:"lineTo",data:[c,h]},{op:"lineTo",data:[c+u*Math.cos(f),h+d*Math.sin(f)]})),{type:"path",ops:x}}function Hh(e,t){const r=_f(Tf(il(e))),i=[];let s=[0,0],a=[0,0];for(const{key:o,data:n}of r)switch(o){case"M":a=[n[0],n[1]],s=[n[0],n[1]];break;case"L":i.push(...rr(a[0],a[1],n[0],n[1],t)),a=[n[0],n[1]];break;case"C":{const[l,c,h,u,d,f]=n;i.push(...F2(l,c,h,u,d,f,a,t)),a=[d,f];break}case"Z":i.push(...rr(a[0],a[1],s[0],s[1],t)),a=[s[0],s[1]]}return{type:"path",ops:i}}function Ua(e,t){const r=[];for(const i of e)if(i.length){const s=t.maxRandomnessOffset||0,a=i.length;if(a>2){r.push({op:"move",data:[i[0][0]+St(s,t),i[0][1]+St(s,t)]});for(let o=1;o<a;o++)r.push({op:"lineTo",data:[i[o][0]+St(s,t),i[o][1]+St(s,t)]})}}return{type:"fillPath",ops:r}}function Er(e,t){return(function(r,i){let s=r.fillStyle||"hachure";if(!se[s])switch(s){case"zigzag":se[s]||(se[s]=new b2(i));break;case"cross-hatch":se[s]||(se[s]=new k2(i));break;case"dots":se[s]||(se[s]=new w2(i));break;case"dashed":se[s]||(se[s]=new S2(i));break;case"zigzag-line":se[s]||(se[s]=new T2(i));break;default:s="hachure",se[s]||(se[s]=new rl(i))}return se[s]})(t,v2).fillPolygons(e,t)}function Yh(e){const t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function Ff(e){return e.randomizer||(e.randomizer=new _2(e.seed||0)),e.randomizer.next()}function sa(e,t,r,i=1){return r.roughness*i*(Ff(r)*(t-e)+e)}function St(e,t,r=1){return sa(-e,e,t,r)}function rr(e,t,r,i,s,a=!1){const o=a?s.disableMultiStrokeFill:s.disableMultiStroke,n=Jo(e,t,r,i,s,!0,!1);if(o)return n;const l=Jo(e,t,r,i,s,!0,!0);return n.concat(l)}function Jo(e,t,r,i,s,a,o){const n=Math.pow(e-r,2)+Math.pow(t-i,2),l=Math.sqrt(n);let c=1;c=l<200?1:l>500?.4:-.0016668*l+1.233334;let h=s.maxRandomnessOffset||0;h*h*100>n&&(h=l/10);const u=h/2,d=.2+.2*Ff(s);let f=s.bowing*s.maxRandomnessOffset*(i-t)/200,y=s.bowing*s.maxRandomnessOffset*(e-r)/200;f=St(f,s,c),y=St(y,s,c);const m=[],C=()=>St(u,s,c),x=()=>St(h,s,c),k=s.preserveVertices;return o?m.push({op:"move",data:[e+(k?0:C()),t+(k?0:C())]}):m.push({op:"move",data:[e+(k?0:St(h,s,c)),t+(k?0:St(h,s,c))]}),o?m.push({op:"bcurveTo",data:[f+e+(r-e)*d+C(),y+t+(i-t)*d+C(),f+e+2*(r-e)*d+C(),y+t+2*(i-t)*d+C(),r+(k?0:C()),i+(k?0:C())]}):m.push({op:"bcurveTo",data:[f+e+(r-e)*d+x(),y+t+(i-t)*d+x(),f+e+2*(r-e)*d+x(),y+t+2*(i-t)*d+x(),r+(k?0:x()),i+(k?0:x())]}),m}function Cs(e,t,r){if(!e.length)return[];const i=[];i.push([e[0][0]+St(t,r),e[0][1]+St(t,r)]),i.push([e[0][0]+St(t,r),e[0][1]+St(t,r)]);for(let s=1;s<e.length;s++)i.push([e[s][0]+St(t,r),e[s][1]+St(t,r)]),s===e.length-1&&i.push([e[s][0]+St(t,r),e[s][1]+St(t,r)]);return aa(i,null,r)}function aa(e,t,r){const i=e.length,s=[];if(i>3){const a=[],o=1-r.curveTightness;s.push({op:"move",data:[e[1][0],e[1][1]]});for(let n=1;n+2<i;n++){const l=e[n];a[0]=[l[0],l[1]],a[1]=[l[0]+(o*e[n+1][0]-o*e[n-1][0])/6,l[1]+(o*e[n+1][1]-o*e[n-1][1])/6],a[2]=[e[n+1][0]+(o*e[n][0]-o*e[n+2][0])/6,e[n+1][1]+(o*e[n][1]-o*e[n+2][1])/6],a[3]=[e[n+1][0],e[n+1][1]],s.push({op:"bcurveTo",data:[a[1][0],a[1][1],a[2][0],a[2][1],a[3][0],a[3][1]]})}}else i===3?(s.push({op:"move",data:[e[1][0],e[1][1]]}),s.push({op:"bcurveTo",data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):i===2&&s.push(...Jo(e[0][0],e[0][1],e[1][0],e[1][1],r,!0,!0));return s}function jh(e,t,r,i,s,a,o,n){const l=[],c=[];if(n.roughness===0){e/=4,c.push([t+i*Math.cos(-e),r+s*Math.sin(-e)]);for(let h=0;h<=2*Math.PI;h+=e){const u=[t+i*Math.cos(h),r+s*Math.sin(h)];l.push(u),c.push(u)}c.push([t+i*Math.cos(0),r+s*Math.sin(0)]),c.push([t+i*Math.cos(e),r+s*Math.sin(e)])}else{const h=St(.5,n)-Math.PI/2;c.push([St(a,n)+t+.9*i*Math.cos(h-e),St(a,n)+r+.9*s*Math.sin(h-e)]);const u=2*Math.PI+h-.01;for(let d=h;d<u;d+=e){const f=[St(a,n)+t+i*Math.cos(d),St(a,n)+r+s*Math.sin(d)];l.push(f),c.push(f)}c.push([St(a,n)+t+i*Math.cos(h+2*Math.PI+.5*o),St(a,n)+r+s*Math.sin(h+2*Math.PI+.5*o)]),c.push([St(a,n)+t+.98*i*Math.cos(h+o),St(a,n)+r+.98*s*Math.sin(h+o)]),c.push([St(a,n)+t+.9*i*Math.cos(h+.5*o),St(a,n)+r+.9*s*Math.sin(h+.5*o)])}return[c,l]}function Uh(e,t,r,i,s,a,o,n,l){const c=a+St(.1,l),h=[];h.push([St(n,l)+t+.9*i*Math.cos(c-e),St(n,l)+r+.9*s*Math.sin(c-e)]);for(let u=c;u<=o;u+=e)h.push([St(n,l)+t+i*Math.cos(u),St(n,l)+r+s*Math.sin(u)]);return h.push([t+i*Math.cos(o),r+s*Math.sin(o)]),h.push([t+i*Math.cos(o),r+s*Math.sin(o)]),aa(h,null,l)}function F2(e,t,r,i,s,a,o,n){const l=[],c=[n.maxRandomnessOffset||1,(n.maxRandomnessOffset||1)+.3];let h=[0,0];const u=n.disableMultiStroke?1:2,d=n.preserveVertices;for(let f=0;f<u;f++)f===0?l.push({op:"move",data:[o[0],o[1]]}):l.push({op:"move",data:[o[0]+(d?0:St(c[0],n)),o[1]+(d?0:St(c[0],n))]}),h=d?[s,a]:[s+St(c[f],n),a+St(c[f],n)],l.push({op:"bcurveTo",data:[e+St(c[f],n),t+St(c[f],n),r+St(c[f],n),i+St(c[f],n),h[0],h[1]]});return l}function _i(e){return[...e]}function Xh(e,t=0){const r=e.length;if(r<3)throw new Error("A curve must have at least three points.");const i=[];if(r===3)i.push(_i(e[0]),_i(e[1]),_i(e[2]),_i(e[2]));else{const s=[];s.push(e[0],e[0]);for(let n=1;n<e.length;n++)s.push(e[n]),n===e.length-1&&s.push(e[n]);const a=[],o=1-t;i.push(_i(s[0]));for(let n=1;n+2<s.length;n++){const l=s[n];a[0]=[l[0],l[1]],a[1]=[l[0]+(o*s[n+1][0]-o*s[n-1][0])/6,l[1]+(o*s[n+1][1]-o*s[n-1][1])/6],a[2]=[s[n+1][0]+(o*s[n][0]-o*s[n+2][0])/6,s[n+1][1]+(o*s[n][1]-o*s[n+2][1])/6],a[3]=[s[n+1][0],s[n+1][1]],i.push(a[1],a[2],a[3])}}return i}function Ps(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)}function M2(e,t,r){const i=Ps(t,r);if(i===0)return Ps(e,t);let s=((e[0]-t[0])*(r[0]-t[0])+(e[1]-t[1])*(r[1]-t[1]))/i;return s=Math.max(0,Math.min(1,s)),Ps(e,lr(t,r,s))}function lr(e,t,r){return[e[0]+(t[0]-e[0])*r,e[1]+(t[1]-e[1])*r]}function tn(e,t,r,i){const s=i||[];if((function(n,l){const c=n[l+0],h=n[l+1],u=n[l+2],d=n[l+3];let f=3*h[0]-2*c[0]-d[0];f*=f;let y=3*h[1]-2*c[1]-d[1];y*=y;let m=3*u[0]-2*d[0]-c[0];m*=m;let C=3*u[1]-2*d[1]-c[1];return C*=C,f<m&&(f=m),y<C&&(y=C),f+y})(e,t)<r){const n=e[t+0];s.length?(a=s[s.length-1],o=n,Math.sqrt(Ps(a,o))>1&&s.push(n)):s.push(n),s.push(e[t+3])}else{const l=e[t+0],c=e[t+1],h=e[t+2],u=e[t+3],d=lr(l,c,.5),f=lr(c,h,.5),y=lr(h,u,.5),m=lr(d,f,.5),C=lr(f,y,.5),x=lr(m,C,.5);tn([l,d,m,x],0,r,s),tn([x,C,y,u],0,r,s)}var a,o;return s}function A2(e,t){return oa(e,0,e.length,t)}function oa(e,t,r,i,s){const a=s||[],o=e[t],n=e[r-1];let l=0,c=1;for(let h=t+1;h<r-1;++h){const u=M2(e[h],o,n);u>l&&(l=u,c=h)}return Math.sqrt(l)>i?(oa(e,t,c+1,i,a),oa(e,c,r,i,a)):(a.length||a.push(o),a.push(n)),a}function Xa(e,t=.15,r){const i=[],s=(e.length-1)/3;for(let a=0;a<s;a++)tn(e,3*a,t,i);return r&&r>0?oa(i,0,i.length,r):i}const le="none";class na{constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,r,i){return{shape:t,sets:r||[],options:i||this.defaultOptions}}line(t,r,i,s,a){const o=this._o(a);return this._d("line",[vf(t,r,i,s,o)],o)}rectangle(t,r,i,s,a){const o=this._o(a),n=[],l=L2(t,r,i,s,o);if(o.fill){const c=[[t,r],[t+i,r],[t+i,r+s],[t,r+s]];o.fillStyle==="solid"?n.push(Ua([c],o)):n.push(Er([c],o))}return o.stroke!==le&&n.push(l),this._d("rectangle",n,o)}ellipse(t,r,i,s,a){const o=this._o(a),n=[],l=Lf(i,s,o),c=Qo(t,r,o,l);if(o.fill)if(o.fillStyle==="solid"){const h=Qo(t,r,o,l).opset;h.type="fillPath",n.push(h)}else n.push(Er([c.estimatedPoints],o));return o.stroke!==le&&n.push(c.opset),this._d("ellipse",n,o)}circle(t,r,i,s){const a=this.ellipse(t,r,i,i,s);return a.shape="circle",a}linearPath(t,r){const i=this._o(r);return this._d("linearPath",[Ds(t,!1,i)],i)}arc(t,r,i,s,a,o,n=!1,l){const c=this._o(l),h=[],u=zh(t,r,i,s,a,o,n,!0,c);if(n&&c.fill)if(c.fillStyle==="solid"){const d=Object.assign({},c);d.disableMultiStroke=!0;const f=zh(t,r,i,s,a,o,!0,!1,d);f.type="fillPath",h.push(f)}else h.push((function(d,f,y,m,C,x,k){const w=d,T=f;let _=Math.abs(y/2),v=Math.abs(m/2);_+=St(.01*_,k),v+=St(.01*v,k);let F=C,L=x;for(;F<0;)F+=2*Math.PI,L+=2*Math.PI;L-F>2*Math.PI&&(F=0,L=2*Math.PI);const U=(L-F)/k.curveStepCount,W=[];for(let q=F;q<=L;q+=U)W.push([w+_*Math.cos(q),T+v*Math.sin(q)]);return W.push([w+_*Math.cos(L),T+v*Math.sin(L)]),W.push([w,T]),Er([W],k)})(t,r,i,s,a,o,c));return c.stroke!==le&&h.push(u),this._d("arc",h,c)}curve(t,r){const i=this._o(r),s=[],a=Wh(t,i);if(i.fill&&i.fill!==le)if(i.fillStyle==="solid"){const o=Wh(t,Object.assign(Object.assign({},i),{disableMultiStroke:!0,roughness:i.roughness?i.roughness+i.fillShapeRoughnessGain:0}));s.push({type:"fillPath",ops:this._mergedShape(o.ops)})}else{const o=[],n=t;if(n.length){const l=typeof n[0][0]=="number"?[n]:n;for(const c of l)c.length<3?o.push(...c):c.length===3?o.push(...Xa(Xh([c[0],c[0],c[1],c[2]]),10,(1+i.roughness)/2)):o.push(...Xa(Xh(c),10,(1+i.roughness)/2))}o.length&&s.push(Er([o],i))}return i.stroke!==le&&s.push(a),this._d("curve",s,i)}polygon(t,r){const i=this._o(r),s=[],a=Ds(t,!0,i);return i.fill&&(i.fillStyle==="solid"?s.push(Ua([t],i)):s.push(Er([t],i))),i.stroke!==le&&s.push(a),this._d("polygon",s,i)}path(t,r){const i=this._o(r),s=[];if(!t)return this._d("path",s,i);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const a=i.fill&&i.fill!=="transparent"&&i.fill!==le,o=i.stroke!==le,n=!!(i.simplification&&i.simplification<1),l=(function(h,u,d){const f=_f(Tf(il(h))),y=[];let m=[],C=[0,0],x=[];const k=()=>{x.length>=4&&m.push(...Xa(x,u)),x=[]},w=()=>{k(),m.length&&(y.push(m),m=[])};for(const{key:_,data:v}of f)switch(_){case"M":w(),C=[v[0],v[1]],m.push(C);break;case"L":k(),m.push([v[0],v[1]]);break;case"C":if(!x.length){const F=m.length?m[m.length-1]:C;x.push([F[0],F[1]])}x.push([v[0],v[1]]),x.push([v[2],v[3]]),x.push([v[4],v[5]]);break;case"Z":k(),m.push([C[0],C[1]])}if(w(),!d)return y;const T=[];for(const _ of y){const v=A2(_,d);v.length&&T.push(v)}return T})(t,1,n?4-4*(i.simplification||1):(1+i.roughness)/2),c=Hh(t,i);if(a)if(i.fillStyle==="solid")if(l.length===1){const h=Hh(t,Object.assign(Object.assign({},i),{disableMultiStroke:!0,roughness:i.roughness?i.roughness+i.fillShapeRoughnessGain:0}));s.push({type:"fillPath",ops:this._mergedShape(h.ops)})}else s.push(Ua(l,i));else s.push(Er(l,i));return o&&(n?l.forEach((h=>{s.push(Ds(h,!1,i))})):s.push(c)),this._d("path",s,i)}opsToPath(t,r){let i="";for(const s of t.ops){const a=typeof r=="number"&&r>=0?s.data.map((o=>+o.toFixed(r))):s.data;switch(s.op){case"move":i+=`M${a[0]} ${a[1]} `;break;case"bcurveTo":i+=`C${a[0]} ${a[1]}, ${a[2]} ${a[3]}, ${a[4]} ${a[5]} `;break;case"lineTo":i+=`L${a[0]} ${a[1]} `}}return i.trim()}toPaths(t){const r=t.sets||[],i=t.options||this.defaultOptions,s=[];for(const a of r){let o=null;switch(a.type){case"path":o={d:this.opsToPath(a),stroke:i.stroke,strokeWidth:i.strokeWidth,fill:le};break;case"fillPath":o={d:this.opsToPath(a),stroke:le,strokeWidth:0,fill:i.fill||le};break;case"fillSketch":o=this.fillSketch(a,i)}o&&s.push(o)}return s}fillSketch(t,r){let i=r.fillWeight;return i<0&&(i=r.strokeWidth/2),{d:this.opsToPath(t),stroke:r.fill||le,strokeWidth:i,fill:le}}_mergedShape(t){return t.filter(((r,i)=>i===0||r.op!=="move"))}}class E2{constructor(t,r){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new na(r)}draw(t){const r=t.sets||[],i=t.options||this.getDefaultOptions(),s=this.ctx,a=t.options.fixedDecimalPlaceDigits;for(const o of r)switch(o.type){case"path":s.save(),s.strokeStyle=i.stroke==="none"?"transparent":i.stroke,s.lineWidth=i.strokeWidth,i.strokeLineDash&&s.setLineDash(i.strokeLineDash),i.strokeLineDashOffset&&(s.lineDashOffset=i.strokeLineDashOffset),this._drawToContext(s,o,a),s.restore();break;case"fillPath":{s.save(),s.fillStyle=i.fill||"";const n=t.shape==="curve"||t.shape==="polygon"||t.shape==="path"?"evenodd":"nonzero";this._drawToContext(s,o,a,n),s.restore();break}case"fillSketch":this.fillSketch(s,o,i)}}fillSketch(t,r,i){let s=i.fillWeight;s<0&&(s=i.strokeWidth/2),t.save(),i.fillLineDash&&t.setLineDash(i.fillLineDash),i.fillLineDashOffset&&(t.lineDashOffset=i.fillLineDashOffset),t.strokeStyle=i.fill||"",t.lineWidth=s,this._drawToContext(t,r,i.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,r,i,s="nonzero"){t.beginPath();for(const a of r.ops){const o=typeof i=="number"&&i>=0?a.data.map((n=>+n.toFixed(i))):a.data;switch(a.op){case"move":t.moveTo(o[0],o[1]);break;case"bcurveTo":t.bezierCurveTo(o[0],o[1],o[2],o[3],o[4],o[5]);break;case"lineTo":t.lineTo(o[0],o[1])}}r.type==="fillPath"?t.fill(s):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,r,i,s,a){const o=this.gen.line(t,r,i,s,a);return this.draw(o),o}rectangle(t,r,i,s,a){const o=this.gen.rectangle(t,r,i,s,a);return this.draw(o),o}ellipse(t,r,i,s,a){const o=this.gen.ellipse(t,r,i,s,a);return this.draw(o),o}circle(t,r,i,s){const a=this.gen.circle(t,r,i,s);return this.draw(a),a}linearPath(t,r){const i=this.gen.linearPath(t,r);return this.draw(i),i}polygon(t,r){const i=this.gen.polygon(t,r);return this.draw(i),i}arc(t,r,i,s,a,o,n=!1,l){const c=this.gen.arc(t,r,i,s,a,o,n,l);return this.draw(c),c}curve(t,r){const i=this.gen.curve(t,r);return this.draw(i),i}path(t,r){const i=this.gen.path(t,r);return this.draw(i),i}}const bs="http://www.w3.org/2000/svg";class $2{constructor(t,r){this.svg=t,this.gen=new na(r)}draw(t){const r=t.sets||[],i=t.options||this.getDefaultOptions(),s=this.svg.ownerDocument||window.document,a=s.createElementNS(bs,"g"),o=t.options.fixedDecimalPlaceDigits;for(const n of r){let l=null;switch(n.type){case"path":l=s.createElementNS(bs,"path"),l.setAttribute("d",this.opsToPath(n,o)),l.setAttribute("stroke",i.stroke),l.setAttribute("stroke-width",i.strokeWidth+""),l.setAttribute("fill","none"),i.strokeLineDash&&l.setAttribute("stroke-dasharray",i.strokeLineDash.join(" ").trim()),i.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${i.strokeLineDashOffset}`);break;case"fillPath":l=s.createElementNS(bs,"path"),l.setAttribute("d",this.opsToPath(n,o)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",i.fill||""),t.shape!=="curve"&&t.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(s,n,i)}l&&a.appendChild(l)}return a}fillSketch(t,r,i){let s=i.fillWeight;s<0&&(s=i.strokeWidth/2);const a=t.createElementNS(bs,"path");return a.setAttribute("d",this.opsToPath(r,i.fixedDecimalPlaceDigits)),a.setAttribute("stroke",i.fill||""),a.setAttribute("stroke-width",s+""),a.setAttribute("fill","none"),i.fillLineDash&&a.setAttribute("stroke-dasharray",i.fillLineDash.join(" ").trim()),i.fillLineDashOffset&&a.setAttribute("stroke-dashoffset",`${i.fillLineDashOffset}`),a}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,r){return this.gen.opsToPath(t,r)}line(t,r,i,s,a){const o=this.gen.line(t,r,i,s,a);return this.draw(o)}rectangle(t,r,i,s,a){const o=this.gen.rectangle(t,r,i,s,a);return this.draw(o)}ellipse(t,r,i,s,a){const o=this.gen.ellipse(t,r,i,s,a);return this.draw(o)}circle(t,r,i,s){const a=this.gen.circle(t,r,i,s);return this.draw(a)}linearPath(t,r){const i=this.gen.linearPath(t,r);return this.draw(i)}polygon(t,r){const i=this.gen.polygon(t,r);return this.draw(i)}arc(t,r,i,s,a,o,n=!1,l){const c=this.gen.arc(t,r,i,s,a,o,n,l);return this.draw(c)}curve(t,r){const i=this.gen.curve(t,r);return this.draw(i)}path(t,r){const i=this.gen.path(t,r);return this.draw(i)}}var nt={canvas:(e,t)=>new E2(e,t),svg:(e,t)=>new $2(e,t),generator:e=>new na(e),newSeed:()=>na.newSeed()},O2=1,D2=3;async function sl(e){const t=e.getElementsByTagName("img");if(!t||t.length===0)return;const r=!al(e);await Promise.all([...t].map(i=>new Promise(s=>{function a(){if(i.style.display="flex",i.style.flexDirection="column",r){const o=At().fontSize?At().fontSize:window.getComputedStyle(document.body).fontSize,n=5,[l=Mu.fontSize]=ma(o),c=l*n+"px";i.style.minWidth=c,i.style.maxWidth=c}else i.style.width="100%";s(i)}p(a,"setupImage"),setTimeout(()=>{i.complete&&a()}),i.addEventListener("error",a),i.addEventListener("load",a)})))}p(sl,"configureLabelImages");function al(e){var r;return e.nodeType===D2?((r=e.textContent)==null?void 0:r.trim())!=="":e.nodeType!==O2||e.tagName.toLowerCase()==="img"?!1:[...e.childNodes].some(al)}p(al,"hasTextBesidesImages");var Gh=3,P2=32,I2=p(async(e,t,r)=>{var x,k,w;const i=At(),s=e.insert("g").attr("class",r??"node default").attr("id",t.domId||t.id),a=s.insert("g").attr("class","label").attr("style",Xt(t.labelStyle)),n=[{text:typeof t.label=="string"?t.label:((x=t.label)==null?void 0:x[0])??"",cssClass:"c4-name"},{text:t.stereotype,cssClass:"c4-type"},...(t.description??[]).map(T=>({text:T,cssClass:"c4-descr"}))].filter(T=>T.text),l=t.width?Math.max(t.width-2*(t.padding??0),P2):((k=At().flowchart)==null?void 0:k.wrappingWidth)??200,h=((w=i.c4)==null?void 0:w.wrap)??!0?l:Number.POSITIVE_INFINITY,u=await Promise.all(n.map(async T=>{const _=a.append("g").attr("class",T.cssClass),v=await Te(_,de(er(T.text??""),i),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:h,style:t.labelStyle},i);return Lt(v).selectAll("tspan.text-outer-tspan").attr("text-anchor","middle"),Lt(v).selectAll("tspan.text-inner-tspan").attr("font-weight",null).attr("font-style",null),{el:_,box:_.node().getBBox()}})),d=Math.max(...u.map(({box:T})=>T.width),0);let f=0;for(const{el:T,box:_}of u)T.attr("transform",`translate(${d/2-_.x-_.width/2}, ${f-_.y})`),f+=_.height+Gh;const y=u.length>0?f-Gh:0;a.insert("rect",":first-child"),a.attr("transform",`translate(${-d/2}, ${-y/2})`);const m=a.node().getBBox(),C=(t.padding??0)/2;return{shapeSvg:s,bbox:m,halfPadding:C,label:a}},"c4LabelHelper"),mt=p(async(e,t,r)=>{var f,y;if(t.stereotype!==void 0)return I2(e,t,r);let i;const s=t.useHtmlLabels||De((f=At())==null?void 0:f.htmlLabels);r?i=r:i="node default";const a=e.insert("g").attr("class",i).attr("id",t.domId||t.id),o=a.insert("g").attr("class","label").attr("style",Xt(t.labelStyle));let n;t.label===void 0?n="":n=typeof t.label=="string"?t.label:t.label[0];const l=!!t.icon||!!t.img,c=t.labelType==="markdown",h=await Te(o,de(er(n),At()),{useHtmlLabels:s,width:t.width||t.wrappingWidth||((y=At().flowchart)==null?void 0:y.wrappingWidth),classes:c?"markdown-node-label":"",style:t.labelStyle,addSvgBackground:l,markdown:c},At()),u=((t==null?void 0:t.padding)??0)/2;let d;if(s){const m=h.children[0],C=Lt(h);await sl(m),d=await xr.measure(()=>m.getBoundingClientRect()),C.attr("width",d.width),C.attr("height",d.height)}else d=await xr.measure(()=>h.getBBox());return s?o.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"):o.attr("transform","translate(0, "+-d.height/2+")"),t.centerLabel&&o.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),o.insert("rect",":first-child"),{shapeSvg:a,bbox:d,halfPadding:u,label:o}},"labelHelper"),Ga=p(async(e,t,r)=>{var l,c;const i=r.useHtmlLabels??ee(At()),s=e.insert("g").attr("class","label").attr("style",r.labelStyle||""),a=await Te(s,de(er(t),At()),{useHtmlLabels:i,width:r.width||((c=(l=At())==null?void 0:l.flowchart)==null?void 0:c.wrappingWidth),style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img}),o=r.padding/2;let n;if(ee(At())){const h=a.children[0],u=Lt(a);n=await xr.measure(()=>h.getBoundingClientRect()),u.attr("width",n.width),u.attr("height",n.height)}else n=await xr.measure(()=>a.getBBox());return i?s.attr("transform","translate("+-n.width/2+", "+-n.height/2+")"):s.attr("transform","translate(0, "+-n.height/2+")"),r.centerLabel&&s.attr("transform","translate("+-n.width/2+", "+-n.height/2+")"),s.insert("rect",":first-child"),{shapeSvg:e,bbox:n,halfPadding:o,label:s}},"insertLabel"),ct=p((e,t,r)=>{if(r){e.width=r.width,e.height=r.height;return}const i=t.node().getBBox();e.width=i.width,e.height=i.height},"updateNodeBounds"),xt=p((e,t)=>(e.look==="handDrawn"?"rough-node":"node")+" "+e.cssClasses+" "+(t||""),"getNodeClasses");function Dt(e){const t=e.map((r,i)=>`${i===0?"M":"L"}${r.x},${r.y}`);return t.push("Z"),t.join(" ")}p(Dt,"createPathFromPoints");function ir(e,t,r,i,s,a){const o=[],l=r-e,c=i-t,h=l/a,u=2*Math.PI/h,d=t+c/2;for(let f=0;f<=50;f++){const y=f/50,m=e+y*l,C=d+s*Math.sin(u*(m-e));o.push({x:m,y:C})}return o}p(ir,"generateFullSineWavePoints");function Me(e,t,r,i,s,a){const o=[],n=s*Math.PI/180,h=(a*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const d=n+u*h,f=e+r*Math.cos(d),y=t+r*Math.sin(d);o.push({x:-f,y:-y})}return o}p(Me,"generateCirclePoints");function en(e){const t=Array.from(e.childNodes).filter(l=>l.tagName==="path"),r=document.createElementNS("http://www.w3.org/2000/svg","path"),i=t.map(l=>l.getAttribute("d")).filter(l=>l!==null).join(" ");r.setAttribute("d",i);const s=t.find(l=>l.getAttribute("fill")!=="none"),a=t.find(l=>l.getAttribute("stroke")!=="none"),o=p((l,c)=>(l==null?void 0:l.getAttribute(c))??void 0,"getAttr");if(s){const l={fill:o(s,"fill"),"fill-opacity":o(s,"fill-opacity")??"1"};Object.entries(l).forEach(([c,h])=>{h&&r.setAttribute(c,h)})}if(a){const l={stroke:o(a,"stroke"),"stroke-width":o(a,"stroke-width")??"1","stroke-opacity":o(a,"stroke-opacity")??"1"};Object.entries(l).forEach(([c,h])=>{h&&r.setAttribute(c,h)})}const n=document.createElementNS("http://www.w3.org/2000/svg","g");return n.appendChild(r),n}p(en,"mergePaths");var R2=p((e,t)=>{var r=e.x,i=e.y,s=t.x-r,a=t.y-i,o=e.width/2,n=e.height/2,l,c;return Math.abs(a)*o>Math.abs(s)*n?(a<0&&(n=-n),l=a===0?0:n*s/a,c=n):(s<0&&(o=-o),l=o,c=s===0?0:o*a/s),{x:r+l,y:i+c}},"intersectRect"),Sr=R2,pe=p((e,t,r,i,s)=>["M",e+s,t,"H",e+r-s,"A",s,s,0,0,1,e+r,t+s,"V",t+i-s,"A",s,s,0,0,1,e+r-s,t+i,"H",e+s,"A",s,s,0,0,1,e,t+i-s,"V",t+s,"A",s,s,0,0,1,e+s,t,"Z"].join(" "),"createRoundedRectPathD"),q2=p(async(e,t,r,i=!1,s=!1)=>{let a=t||"";typeof a=="object"&&(a=a[0]);const o=At(),n=ee(o);return await Te(e,a,{style:r,isTitle:i,useHtmlLabels:n,markdown:!1,isNode:s,width:Number.POSITIVE_INFINITY},o)},"createLabel"),Qe=q2;function Mf(e,t){return e.intersect(t)}p(Mf,"intersectNode");var N2=Mf;function Af(e,t,r,i){var s=e.x,a=e.y,o=s-i.x,n=a-i.y,l=Math.sqrt(t*t*n*n+r*r*o*o),c=Math.abs(t*r*o/l);i.x<s&&(c=-c);var h=Math.abs(t*r*n/l);return i.y<a&&(h=-h),{x:s+c,y:a+h}}p(Af,"intersectEllipse");var Ef=Af;function $f(e,t,r){return Ef(e,t,t,r)}p($f,"intersectCircle");var W2=$f;function Of(e,t,r,i){{const s=t.y-e.y,a=e.x-t.x,o=t.x*e.y-e.x*t.y,n=s*r.x+a*r.y+o,l=s*i.x+a*i.y+o,c=1e-6;if(n!==0&&l!==0&&rn(n,l))return;const h=i.y-r.y,u=r.x-i.x,d=i.x*r.y-r.x*i.y,f=h*e.x+u*e.y+d,y=h*t.x+u*t.y+d;if(Math.abs(f)<c&&Math.abs(y)<c&&rn(f,y))return;const m=s*u-h*a;if(m===0)return;const C=Math.abs(m/2);let x=a*d-u*o;const k=x<0?(x-C)/m:(x+C)/m;x=h*o-s*d;const w=x<0?(x-C)/m:(x+C)/m;return{x:k,y:w}}}p(Of,"intersectLine");function rn(e,t){return e*t>0}p(rn,"sameSign");var z2=Of;function Df(e,t,r){let i=e.x,s=e.y,a=[],o=Number.POSITIVE_INFINITY,n=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(h){o=Math.min(o,h.x),n=Math.min(n,h.y)}):(o=Math.min(o,t.x),n=Math.min(n,t.y));let l=i-e.width/2-o,c=s-e.height/2-n;for(let h=0;h<t.length;h++){let u=t[h],d=t[h<t.length-1?h+1:0],f=z2(e,r,{x:l+u.x,y:c+u.y},{x:l+d.x,y:c+d.y});f&&a.push(f)}return a.length?(a.length>1&&a.sort(function(h,u){let d=h.x-r.x,f=h.y-r.y,y=Math.sqrt(d*d+f*f),m=u.x-r.x,C=u.y-r.y,x=Math.sqrt(m*m+C*C);return y<x?-1:y===x?0:1}),a[0]):e}p(Df,"intersectPolygon");var H2=Df,st={node:N2,circle:W2,ellipse:Ef,polygon:H2,rect:Sr};function Pf(e,t){const{labelStyles:r}=dt(t);t.labelStyle=r;const i=xt(t);let s=i;i||(s="anchor");const a=e.insert("g").attr("class",s).attr("id",t.domId||t.id),o=1,{cssStyles:n}=t,l=nt.svg(a),c=ot(t,{fill:"black",stroke:"none",fillStyle:"solid"});t.look!=="handDrawn"&&(c.roughness=0);const h=l.circle(0,0,o*2,c),u=a.insert(()=>h,":first-child");return u.attr("class","anchor").attr("style",Xt(n)),ct(t,u),t.intersect=function(d){return I.info("Circle intersect",t,o,d),st.circle(t,o,d)},a}p(Pf,"anchor");function sn(e,t,r,i,s,a,o){const l=(e+r)/2,c=(t+i)/2,h=Math.atan2(i-t,r-e),u=(r-e)/2,d=(i-t)/2,f=u/s,y=d/a,m=Math.sqrt(f**2+y**2);if(m>1)throw new Error("The given radii are too small to create an arc between the points.");const C=Math.sqrt(1-m**2),x=l+C*a*Math.sin(h)*(o?-1:1),k=c-C*s*Math.cos(h)*(o?-1:1),w=Math.atan2((t-k)/a,(e-x)/s);let _=Math.atan2((i-k)/a,(r-x)/s)-w;o&&_<0&&(_+=2*Math.PI),!o&&_>0&&(_-=2*Math.PI);const v=[];for(let F=0;F<20;F++){const L=F/19,U=w+L*_,W=x+s*Math.cos(U),q=k+a*Math.sin(U);v.push({x:W,y:q})}return v}p(sn,"generateArcPoints");function If(e,t,r){const[i,s]=[t,r].sort((a,o)=>o-a);return s*(1-Math.sqrt(1-(e/i/2)**2))}p(If,"calculateArcSagitta");async function Rf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s,n=p(U=>U+o,"calcTotalHeight"),l=p(U=>{const W=U/2;return[W/(2.5+U/50),W]},"calcEllipseRadius"),{shapeSvg:c,bbox:h}=await mt(e,t,xt(t)),u=n(t!=null&&t.height?t==null?void 0:t.height:h.height),[d,f]=l(u),y=If(u,d,f),C=(t!=null&&t.width?t==null?void 0:t.width:h.width)+a*2+y-y,x=u,{cssStyles:k}=t,w=[{x:C/2,y:-x/2},{x:-C/2,y:-x/2},...sn(-C/2,-x/2,-C/2,x/2,d,f,!1),{x:C/2,y:x/2},...sn(C/2,x/2,C/2,-x/2,d,f,!0)],T=nt.svg(c),_=ot(t,{});t.look!=="handDrawn"&&(_.roughness=0,_.fillStyle="solid");const v=Dt(w),F=T.path(v,_),L=c.insert(()=>F,":first-child");return L.attr("class","basic label-container outer-path"),k&&t.look!=="handDrawn"&&L.selectAll("path").attr("style",k),i&&t.look!=="handDrawn"&&L.selectAll("path").attr("style",i),L.attr("transform",`translate(${d/2}, 0)`),ct(t,L),t.intersect=function(U){return st.polygon(t,w,U)},c}p(Rf,"bowTieRect");async function qf(e,t,{config:{themeVariables:r}}){var F;const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i;const{shapeSvg:a,bbox:o,label:n}=await mt(e,t,xt(t)),l=(r==null?void 0:r.nodeBorder)??(r==null?void 0:r.lineColor)??"currentColor",c=t.padding??12,h=Math.max(o.width+c*2,t.width??0,80),u=Math.max(Math.min(h*.08,12),5),d=Math.max(o.height+c*2+u,t.height??0),f=-d/2+u,y=d/2,m=h*.72,C=[`M${-h/2},${f}`,`L${-m/2},${y}`,`A${m/2},${u} 0 0 0 ${m/2},${y}`,`L${h/2},${f}`,`A${h/2},${u} 0 0 0 ${-h/2},${f}`,"Z"].join(" "),{cssStyles:x}=t,k=a.insert("g",":first-child").attr("class","basic label-container");if(t.look==="handDrawn"){const U=nt.svg(a).path(C,ot(t,{}));(F=k.node())==null||F.appendChild(U),x&&k.attr("style",x)}else k.append("path").attr("d",C).attr("style",s);k.append("ellipse").attr("cx",0).attr("cy",f).attr("rx",h/2).attr("ry",u).attr("style",`fill:none;stroke:${l};stroke-width:1px`),ct(t,k);const w=f+(y-f)/2;n.attr("transform",`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${w-o.height/2-(o.y-(o.top??0))})`);const T=12,_=p((L,U,W)=>Array.from({length:T+1},(q,rt)=>{const Y=Math.PI-rt*Math.PI/T;return{x:L*Math.cos(Y),y:U+W*u*Math.sin(Y)}}),"arc"),v=[..._(h/2,f,-1),..._(m/2,y,1).reverse()];return t.intersect=function(L){return st.polygon(t,v,L)},a}p(qf,"bucket");var Vh=20,Zh=8,Y2=80,Va=8;async function Nf(e,t){const{themeVariables:r}=At(),i=r.clusterBkg,s=r.clusterBorder,{nodeStyles:a}=dt(t),{shapeSvg:o,bbox:n}=await mt(e,t,xt(t)),l=t.padding??8,c=n.height,h=Math.max(n.width+l*2,Y2,(t==null?void 0:t.width)??0),u=Math.max(c+Zh+Vh+l*2,(t==null?void 0:t.height)??0),d=-h/2,f=-u/2,y=-28/2,m=o.select(".label");m&&(t.useHtmlLabels??ee(At())?m.attr("transform",`translate(${-n.width/2}, ${-n.height/2+y})`):m.attr("transform",`translate(0, ${-n.height/2+y})`));let C;if(t.look==="handDrawn"){const _=nt.svg(o),v=ot(t,{fill:i,stroke:s,fillStyle:"solid"}),F=_.path(pe(d,f,h,u,Va),v);C=o.insert(()=>F,":first-child"),C.attr("class","basic label-container collapsed-group").attr("style",Xt(t.cssStyles))}else C=o.insert("rect",":first-child"),C.attr("class","basic label-container collapsed-group").attr("style",a).attr("rx",Va).attr("ry",Va).attr("x",d).attr("y",f).attr("width",h).attr("height",u).attr("fill",i).attr("stroke",s);const x=f+l+c+Zh;o.append("line").attr("class","collapsed-separator").attr("x1",d+8).attr("y1",x).attr("x2",d+h-8).attr("y2",x).attr("stroke",s).attr("stroke-dasharray","3, 3");const k=x+Vh/2,w=2.5,T=10;for(let _=-1;_<=1;_++)o.append("circle").attr("class","collapsed-indicator").attr("cx",_*T).attr("cy",k).attr("r",w).attr("fill",s);return ct(t,C),t.calcIntersect=function(_,v){return st.rect(_,v)},t.intersect=function(_){return st.rect(t,_)},o}p(Nf,"collapsedGroup");function Ie(e,t,r,i){return e.insert("polygon",":first-child").attr("points",i.map(function(s){return s.x+","+s.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+r/2+")")}p(Ie,"insertPolygonShape");var j2=["right","left","up","down"],ol="point",U2=p(e=>{const t=new Set;for(const r of e)switch(r){case"x":t.add("right"),t.add("left");break;case"y":t.add("up"),t.add("down");break;default:t.add(r);break}return t},"expandAndDeduplicateDirections"),X2=p(e=>j2.filter(t=>e.has(t)).join("|")||ol,"getDirectionKey"),Kh={"right|left|up|down":p(({height:e,midpoint:t,padding:r,width:i})=>[{x:0,y:0},{x:t,y:0},{x:i/2,y:2*r},{x:i-t,y:0},{x:i,y:0},{x:i,y:-e/3},{x:i+2*r,y:-e/2},{x:i,y:-2*e/3},{x:i,y:-e},{x:i-t,y:-e},{x:i/2,y:-e-2*r},{x:t,y:-e},{x:0,y:-e},{x:0,y:-2*e/3},{x:-2*r,y:-e/2},{x:0,y:-e/3}],"right|left|up|down"),"right|left|up":p(({height:e,midpoint:t,width:r})=>[{x:t,y:0},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:t,y:-e},{x:0,y:-e/2}],"right|left|up"),"right|left|down":p(({height:e,midpoint:t,width:r})=>[{x:0,y:0},{x:t,y:-e},{x:r-t,y:-e},{x:r,y:0}],"right|left|down"),"right|up|down":p(({height:e,midpoint:t,width:r})=>[{x:0,y:0},{x:r,y:-t},{x:r,y:-e+t},{x:0,y:-e}],"right|up|down"),"left|up|down":p(({height:e,midpoint:t,width:r})=>[{x:r,y:0},{x:0,y:-t},{x:0,y:-e+t},{x:r,y:-e}],"left|up|down"),"right|left":p(({height:e,midpoint:t,padding:r,width:i})=>[{x:t,y:0},{x:t,y:-r},{x:i-t,y:-r},{x:i-t,y:0},{x:i,y:-e/2},{x:i-t,y:-e},{x:i-t,y:-e+r},{x:t,y:-e+r},{x:t,y:-e},{x:0,y:-e/2}],"right|left"),"up|down":p(({height:e,midpoint:t,padding:r,width:i})=>[{x:i/2,y:0},{x:0,y:-r},{x:t,y:-r},{x:t,y:-e+r},{x:0,y:-e+r},{x:i/2,y:-e},{x:i,y:-e+r},{x:i-t,y:-e+r},{x:i-t,y:-r},{x:i,y:-r}],"up|down"),"right|up":p(({height:e,midpoint:t,width:r})=>[{x:0,y:0},{x:r,y:-t},{x:0,y:-e}],"right|up"),"right|down":p(({height:e,width:t})=>[{x:0,y:0},{x:t,y:0},{x:0,y:-e}],"right|down"),"left|up":p(({height:e,midpoint:t,width:r})=>[{x:r,y:0},{x:0,y:-t},{x:r,y:-e}],"left|up"),"left|down":p(({height:e,width:t})=>[{x:t,y:0},{x:0,y:0},{x:t,y:-e}],"left|down"),right:p(({height:e,midpoint:t,padding:r,width:i})=>[{x:t,y:-r},{x:t,y:-r},{x:i-t,y:-r},{x:i-t,y:0},{x:i,y:-e/2},{x:i-t,y:-e},{x:i-t,y:-e+r},{x:t,y:-e+r},{x:t,y:-e+r}],"right"),left:p(({height:e,midpoint:t,padding:r,width:i})=>[{x:t,y:0},{x:t,y:-r},{x:i-t,y:-r},{x:i-t,y:-e+r},{x:t,y:-e+r},{x:t,y:-e},{x:0,y:-e/2}],"left"),up:p(({height:e,midpoint:t,padding:r,width:i})=>[{x:t,y:-r},{x:t,y:-e+r},{x:0,y:-e+r},{x:i/2,y:-e},{x:i,y:-e+r},{x:i-t,y:-e+r},{x:i-t,y:-r}],"up"),down:p(({height:e,midpoint:t,padding:r,width:i})=>[{x:i/2,y:0},{x:0,y:-r},{x:t,y:-r},{x:t,y:-e+r},{x:i-t,y:-e+r},{x:i-t,y:-r},{x:i,y:-r}],"down"),[ol]:()=>[{x:0,y:0}]},G2=p((e,t,r,i)=>{const s=U2(e),a=(r.padding??0)/2,o=t.height+4*a,n=o/2,l=i??t.width+2*n+2*a,c=X2(s);return(Kh[c]??Kh[ol])({height:o,midpoint:n,padding:a,width:l})},"getArrowPoints");async function Wf(e,t){const r=t,{shapeSvg:i,bbox:s}=await mt(e,r,xt(r)),a=r.padding??0,o=s.height+2*a,n=o/2,l=s.width+2*n+a,c=r.width??0,u=r.positioned&&(r.widthInColumns??1)>1&&c>l?c:l,d=G2(r.directions??[],s,r,u),f=Ie(i,u,o,d);return f.attr("style",r.style??null),ct(r,f),r.intersect=function(y){return st.polygon(r,d,y)},i}p(Wf,"block_arrow");async function zf(e,t,{config:{themeVariables:r}}){var k;const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i;const{shapeSvg:a,bbox:o,label:n}=await mt(e,t,xt(t)),l=(r==null?void 0:r.nodeBorder)??(r==null?void 0:r.lineColor)??"currentColor",c=t.padding??12,h=18,u=12,d=Math.max(o.width+c*2,t.width??0,90),f=Math.max(o.height+c*2+h,t.height??0),y=-f/2,{cssStyles:m}=t,C=a.insert("g",":first-child").attr("class","basic label-container");if(t.look==="handDrawn"){const T=nt.svg(a).path(pe(-d/2,y,d,f,u),ot(t,{}));(k=C.node())==null||k.appendChild(T),m&&C.attr("style",m)}else C.append("rect").attr("x",-d/2).attr("y",y).attr("width",d).attr("height",f).attr("rx",u).attr("ry",u).attr("style",s);C.append("line").attr("x1",-d/2).attr("y1",y+h).attr("x2",d/2).attr("y2",y+h).attr("style",`stroke:${l};stroke-width:1px`);for(let w=0;w<3;w++)C.append("circle").attr("cx",-d/2+12+w*9).attr("cy",y+h/2).attr("r",2.5).attr("style",`fill:${l};stroke:none`);C.append("rect").attr("class","browser-address-bar").attr("x",-d/2+44).attr("y",y+4).attr("width",Math.max(d-56,10)).attr("height",h-8).attr("rx",3).attr("ry",3).attr("style",`fill:none;stroke:${l};stroke-width:1px;opacity:0.6`),ct(t,C);const x=y+h+(f-h)/2;return n.attr("transform",`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${x-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(w){return st.rect(t,w)},a}p(zf,"browser");var ks=12;async function Hf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?28:s,o=t.look==="neo"?24:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=((t==null?void 0:t.width)??l.width)+(t.look==="neo"?a*2:a+ks),h=((t==null?void 0:t.height)??l.height)+(t.look==="neo"?o*2:o),u=0,d=c,f=-h,y=0,m=[{x:u+ks,y:f},{x:d,y:f},{x:d,y},{x:u,y},{x:u,y:f+ks},{x:u+ks,y:f}];let C;const{cssStyles:x}=t;if(t.look==="handDrawn"){const k=nt.svg(n),w=ot(t,{}),T=Dt(m),_=k.path(T,w);C=n.insert(()=>_,":first-child").attr("transform",`translate(${-c/2}, ${h/2})`),x&&C.attr("style",x)}else C=Ie(n,c,h,m);return i&&C.attr("style",i),ct(t,C),t.intersect=function(k){return st.polygon(t,m,k)},n}p(Hf,"card");function Yf(e,t){const{nodeStyles:r}=dt(t);t.label="";const i=e.insert("g").attr("class",xt(t)).attr("id",t.domId??t.id),{cssStyles:s}=t,a=Math.max(28,t.width??0),o=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],n=nt.svg(i),l=ot(t,{});t.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");const c=Dt(o),h=n.path(c,l),u=i.insert(()=>h,":first-child");return s&&t.look!=="handDrawn"&&u.selectAll("path").attr("style",s),r&&t.look!=="handDrawn"&&u.selectAll("path").attr("style",r),t.width=28,t.height=28,t.intersect=function(d){return st.polygon(t,o,d)},i}p(Yf,"choice");async function nl(e,t,r){const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i;const{shapeSvg:a,bbox:o,halfPadding:n}=await mt(e,t,xt(t)),l=16,c=(r==null?void 0:r.padding)??n,h=t.look==="neo"?o.width/2+l*2:o.width/2+c;let u;const{cssStyles:d}=t;if(t.look==="handDrawn"){const f=nt.svg(a),y=ot(t,{}),m=f.circle(0,0,h*2,y);u=a.insert(()=>m,":first-child"),u.attr("class","basic label-container").attr("style",Xt(d))}else u=a.insert("circle",":first-child").attr("class","basic label-container").attr("style",s).attr("r",h).attr("cx",0).attr("cy",0);return ct(t,u),t.calcIntersect=function(f,y){const m=f.width/2;return st.circle(f,m,y)},t.intersect=function(f){return I.info("Circle intersect",t,h,f),st.circle(t,h,f)},a}p(nl,"circle");async function jf(e,t){const r=t,i=["node",r.cssClasses,r.class].filter(Boolean).join(" "),{shapeSvg:s,bbox:a,halfPadding:o}=await mt(e,r,i),n=s.insert("rect",":first-child"),l=r.padding??0,c=r.positioned?r.width??0:a.width+l,h=r.positioned?r.height??0:a.height+l,u=r.positioned?-c/2:-a.width/2-o,d=r.positioned?-h/2:-a.height/2-o;return n.attr("class","basic cluster composite label-container").attr("style",r.style??null).attr("rx",r.rx??null).attr("ry",r.ry??null).attr("x",u).attr("y",d).attr("width",c).attr("height",h),ct(r,n),r.intersect=function(f){return st.rect(r,f)},s}p(jf,"composite");async function Uf(e,t,{config:{themeVariables:r}}){var k;const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i;const{shapeSvg:a,bbox:o,label:n}=await mt(e,t,xt(t)),l=(r==null?void 0:r.nodeBorder)??(r==null?void 0:r.lineColor)??"currentColor",c=t.padding??12,h=20,u=12,d=Math.max(o.width+c*2,t.width??0,90),f=Math.max(o.height+c*2+h,t.height??0),y=-f/2,{cssStyles:m}=t,C=a.insert("g",":first-child").attr("class","basic label-container");if(t.look==="handDrawn"){const T=nt.svg(a).path(pe(-d/2,y,d,f,u),ot(t,{}));(k=C.node())==null||k.appendChild(T),m&&C.attr("style",m)}else C.append("rect").attr("x",-d/2).attr("y",y).attr("width",d).attr("height",f).attr("rx",u).attr("ry",u).attr("style",s);C.append("text").attr("x",-d/2+12).attr("y",y+16).attr("class","console-glyph").attr("style",`font-family:monospace;font-weight:bold;font-size:14px;fill:${l}`).text(">_"),ct(t,C);const x=y+h+(f-h)/2;return n.attr("transform",`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${x-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(w){return st.rect(t,w)},a}p(Uf,"consoleWindow");function Xf(e){const t=Math.cos(Math.PI/4),r=Math.sin(Math.PI/4),i=e*2,s={x:i/2*t,y:i/2*r},a={x:-(i/2)*t,y:i/2*r},o={x:-(i/2)*t,y:-(i/2)*r},n={x:i/2*t,y:-(i/2)*r};return`M ${a.x},${a.y} L ${n.x},${n.y}
199
+ M ${s.x},${s.y} L ${o.x},${o.y}`}p(Xf,"createLine");function Gf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r,t.label="";const s=e.insert("g").attr("class",xt(t)).attr("id",t.domId??t.id),a=Math.max(30,(t==null?void 0:t.width)??0),{cssStyles:o}=t,n=nt.svg(s),l=ot(t,{});t.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");const c=n.circle(0,0,a*2,l),h=Xf(a),u=n.path(h,l),d=s.insert(()=>c,":first-child");return d.insert(()=>u),d.attr("class","outer-path"),o&&t.look!=="handDrawn"&&d.selectAll("path").attr("style",o),i&&t.look!=="handDrawn"&&d.selectAll("path").attr("style",i),ct(t,d),t.intersect=function(f){return I.info("crossedCircle intersect",t,{radius:a,point:f}),st.circle(t,a,f)},s}p(Gf,"crossedCircle");function Ne(e,t,r,i=100,s=0,a=180){const o=[],n=s*Math.PI/180,h=(a*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const d=n+u*h,f=e+r*Math.cos(d),y=t+r*Math.sin(d);o.push({x:-f,y:-y})}return o}p(Ne,"generateCirclePoints");async function Vf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=t.look==="neo"?18:t.padding??0,l=t.look==="neo"?12:t.padding??0,c=a.width+n,h=a.height+l,u=Math.max(5,h*.1),{cssStyles:d}=t,f=[...Ne(c/2,-h/2,u,30,-90,0),{x:-c/2-u,y:u},...Ne(c/2+u*2,-u,u,20,-180,-270),...Ne(c/2+u*2,u,u,20,-90,-180),{x:-c/2-u,y:-h/2},...Ne(c/2,h/2,u,20,0,90)],y=[{x:c/2,y:-h/2-u},{x:-c/2,y:-h/2-u},...Ne(c/2,-h/2,u,20,-90,0),{x:-c/2-u,y:-u},...Ne(c/2+c*.1,-u,u,20,-180,-270),...Ne(c/2+c*.1,u,u,20,-90,-180),{x:-c/2-u,y:h/2},...Ne(c/2,h/2,u,20,0,90),{x:-c/2,y:h/2+u},{x:c/2,y:h/2+u}],m=nt.svg(s),C=ot(t,{fill:"none"});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const k=Dt(f).replace("Z",""),w=m.path(k,C),T=Dt(y),_=m.path(T,{...C}),v=s.insert("g",":first-child");return v.insert(()=>_,":first-child").attr("stroke-opacity",0),v.insert(()=>w,":first-child"),v.attr("class","text"),d&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",i),v.attr("transform",`translate(${u}, 0)`),o.attr("transform",`translate(${-c/2+u-(a.x-(a.left??0))},${-h/2+(t.padding??0)/2-(a.y-(a.top??0))})`),ct(t,v),t.intersect=function(F){return st.polygon(t,y,F)},s}p(Vf,"curlyBraceLeft");function We(e,t,r,i=100,s=0,a=180){const o=[],n=s*Math.PI/180,h=(a*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const d=n+u*h,f=e+r*Math.cos(d),y=t+r*Math.sin(d);o.push({x:f,y})}return o}p(We,"generateCirclePoints");async function Zf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=t.look==="neo"?18:t.padding??0,l=t.look==="neo"?12:t.padding??0,c=a.width+(t.look==="neo"?n*2:n),h=a.height+(t.look==="neo"?l*2:l),u=Math.max(5,h*.1),{cssStyles:d}=t,f=[...We(c/2,-h/2,u,20,-90,0),{x:c/2+u,y:-u},...We(c/2+u*2,-u,u,20,-180,-270),...We(c/2+u*2,u,u,20,-90,-180),{x:c/2+u,y:h/2},...We(c/2,h/2,u,20,0,90)],y=[{x:-c/2,y:-h/2-u},{x:c/2,y:-h/2-u},...We(c/2,-h/2,u,20,-90,0),{x:c/2+u,y:-u},...We(c/2+u*2,-u,u,20,-180,-270),...We(c/2+u*2,u,u,20,-90,-180),{x:c/2+u,y:h/2},...We(c/2,h/2,u,20,0,90),{x:c/2,y:h/2+u},{x:-c/2,y:h/2+u}],m=nt.svg(s),C=ot(t,{fill:"none"});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const k=Dt(f).replace("Z",""),w=m.path(k,C),T=Dt(y),_=m.path(T,{...C}),v=s.insert("g",":first-child");return v.insert(()=>_,":first-child").attr("stroke-opacity",0),v.insert(()=>w,":first-child"),v.attr("class","text"),d&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",i),v.attr("transform",`translate(${-u}, 0)`),o.attr("transform",`translate(${-c/2+(t.padding??0)/2-(a.x-(a.left??0))},${-h/2+(t.padding??0)/2-(a.y-(a.top??0))})`),ct(t,v),t.intersect=function(F){return st.polygon(t,y,F)},s}p(Zf,"curlyBraceRight");function Kt(e,t,r,i=100,s=0,a=180){const o=[],n=s*Math.PI/180,h=(a*Math.PI/180-n)/(i-1);for(let u=0;u<i;u++){const d=n+u*h,f=e+r*Math.cos(d),y=t+r*Math.sin(d);o.push({x:-f,y:-y})}return o}p(Kt,"generateCirclePoints");async function Kf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=t.look==="neo"?18:t.padding??0,l=t.look==="neo"?12:t.padding??0,c=a.width+(t.look==="neo"?n*2:n),h=a.height+(t.look==="neo"?l*2:l),u=Math.max(5,h*.1),{cssStyles:d}=t,f=[...Kt(c/2,-h/2,u,30,-90,0),{x:-c/2-u,y:u},...Kt(c/2+u*2,-u,u,20,-180,-270),...Kt(c/2+u*2,u,u,20,-90,-180),{x:-c/2-u,y:-h/2},...Kt(c/2,h/2,u,20,0,90)],y=[...Kt(-c/2+u+u/2,-h/2,u,20,-90,-180),{x:c/2-u/2,y:u},...Kt(-c/2-u/2,-u,u,20,0,90),...Kt(-c/2-u/2,u,u,20,-90,0),{x:c/2-u/2,y:-u},...Kt(-c/2+u+u/2,h/2,u,30,-180,-270)],m=[{x:c/2,y:-h/2-u},{x:-c/2,y:-h/2-u},...Kt(c/2,-h/2,u,20,-90,0),{x:-c/2-u,y:-u},...Kt(c/2+u*2,-u,u,20,-180,-270),...Kt(c/2+u*2,u,u,20,-90,-180),{x:-c/2-u,y:h/2},...Kt(c/2,h/2,u,20,0,90),{x:-c/2,y:h/2+u},{x:c/2-u-u/2,y:h/2+u},...Kt(-c/2+u+u/2,-h/2,u,20,-90,-180),{x:c/2-u/2,y:u},...Kt(-c/2-u/2,-u,u,20,0,90),...Kt(-c/2-u/2,u,u,20,-90,0),{x:c/2-u/2,y:-u},...Kt(-c/2+u+u/2,h/2,u,30,-180,-270)],C=nt.svg(s),x=ot(t,{fill:"none"});t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");const w=Dt(f).replace("Z",""),T=C.path(w,x),v=Dt(y).replace("Z",""),F=C.path(v,x),L=Dt(m),U=C.path(L,{...x}),W=s.insert("g",":first-child");return W.insert(()=>U,":first-child").attr("stroke-opacity",0),W.insert(()=>T,":first-child"),W.insert(()=>F,":first-child"),W.attr("class","text"),d&&t.look!=="handDrawn"&&W.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&W.selectAll("path").attr("style",i),W.attr("transform",`translate(${u-u/4}, 0)`),o.attr("transform",`translate(${-c/2+(t.padding??0)/2-(a.x-(a.left??0))},${-h/2+(t.padding??0)/2-(a.y-(a.top??0))})`),ct(t,W),t.intersect=function(q){return st.polygon(t,m,q)},s}p(Kf,"curlyBraces");async function Qf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s,n=20,l=5,{shapeSvg:c,bbox:h}=await mt(e,t,xt(t)),u=Math.max(n,(h.width+a*2)*1.25,(t==null?void 0:t.width)??0),d=Math.max(l,h.height+o*2,(t==null?void 0:t.height)??0),f=d/2,{cssStyles:y}=t,m=nt.svg(c),C=ot(t,{});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const x=u,k=d,w=x-f,T=k/4,_=[{x:w,y:0},{x:T,y:0},{x:0,y:k/2},{x:T,y:k},{x:w,y:k},...Me(-w,-k/2,f,50,270,90)],v=Dt(_),F=m.path(v,C),L=c.insert(()=>F,":first-child");return L.attr("class","basic label-container outer-path"),y&&t.look!=="handDrawn"&&L.selectChildren("path").attr("style",y),i&&t.look!=="handDrawn"&&L.selectChildren("path").attr("style",i),L.attr("transform",`translate(${-u/2}, ${-d/2})`),ct(t,L),t.intersect=function(U){return st.polygon(t,_,U)},c}p(Qf,"curvedTrapezoid");async function Jf(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=t.padding??20,l=Math.max(a.width+n*2,t.width??0,100),c=Math.min(Math.max(l*.23,16),56),h=c*.27,u=Math.max(a.height+n*2,t.height?t.height-(2*c-h):0),d=Math.min(l*.177,u*.45),f=u+2*c-h,y=-f/2,m=y+2*c-h,C=s.insert("g",":first-child").attr("class","basic label-container"),{cssStyles:x}=t;if(t.look==="handDrawn"){const L=nt.svg(s),U=ot(t,{}),W=L.path(pe(-l/2,m,l,u,d),U),q=L.circle(0,y+c,c*2,U);C.insert(()=>q,":first-child"),C.insert(()=>W,":first-child"),x&&C.attr("style",x)}else C.append("rect").attr("x",-l/2).attr("y",m).attr("width",l).attr("height",u).attr("rx",d).attr("ry",d).attr("style",i),C.append("circle").attr("cx",0).attr("cy",y+c).attr("r",c).attr("style",i);ct(t,C);const k=m+u/2;o.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${k-a.height/2-(a.y-(a.top??0))})`);const w=y+c,T=Math.asin(Math.min(1,(m-w)/c))*180/Math.PI,F=[...Me(0,-w,c,24,180+T,-T),...Me(-(-l/2+d),-(m+d),d,12,90,0),...Me(-(-l/2+d),-(f/2-d),d,12,360,270),...Me(-(l/2-d),-(f/2-d),d,12,270,180),...Me(-(l/2-d),-(m+d),d,12,180,90)];return t.intersect=function(L){return st.polygon(t,F,L)},s}p(Jf,"person");var V2=p((e,t,r,i,s,a)=>[`M${e},${t+a}`,`a${s},${a} 0,0,0 ${r},0`,`a${s},${a} 0,0,0 ${-r},0`,`l0,${i}`,`a${s},${a} 0,0,0 ${r},0`,`l0,${-i}`].join(" "),"createCylinderPathD"),Z2=p((e,t,r,i,s,a)=>[`M${e},${t+a}`,`M${e+r},${t+a}`,`a${s},${a} 0,0,0 ${-r},0`,`l0,${i}`,`a${s},${a} 0,0,0 ${r},0`,`l0,${-i}`].join(" "),"createOuterCylinderPathD"),K2=p((e,t,r,i,s,a)=>[`M${e-r/2},${-i/2}`,`a${s},${a} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD"),Qh=8,Jh=8;async function tp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?24:s,o=t.look==="neo"?24:s,n=t.width??0;if(t.width&&(t.width=t.width-o,t.width<Jh&&(t.width=Jh)),t.height){const k=n/2/(2.5+n/50);t.height=t.height-a-k*3,t.height<Qh&&(t.height=Qh)}const{shapeSvg:l,bbox:c,label:h}=await mt(e,t,xt(t)),u=Math.max(t.width??0,c.width)+o,d=u/2,f=d/(2.5+u/50),y=Math.max(t.height??0,c.height)+a+f;let m;const{cssStyles:C}=t;if(t.look==="handDrawn"){const x=nt.svg(l),k=Z2(0,0,u,y,d,f),w=K2(0,f,u,y,d,f),T=ot(t,{}),_=x.path(k,T),v=x.path(w,ot(t,{fill:"none"}));m=l.insert(()=>v,":first-child"),m=l.insert(()=>_,":first-child"),m.attr("class","basic label-container"),C&&m.attr("style",C)}else{const x=V2(0,0,u,y,d,f);m=l.insert("path",":first-child").attr("d",x).attr("class","basic label-container outer-path").attr("style",Xt(C)).attr("style",i)}return m.attr("label-offset-y",f),m.attr("transform",`translate(${-u/2}, ${-(y/2+f)})`),ct(t,m),h.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${-(c.height/2)+(t.padding??0)/1.5-(c.y-(c.top??0))})`),t.intersect=function(x){const k=st.rect(t,x),w=k.x-(t.x??0);if(d!=0&&(Math.abs(w)<(t.width??0)/2||Math.abs(w)==(t.width??0)/2&&Math.abs(k.y-(t.y??0))>(t.height??0)/2-f)){let T=f*f*(1-w*w/(d*d));T>0&&(T=Math.sqrt(T)),T=f-T,x.y-(t.y??0)>0&&(T=-T),k.y+=T}return k},l}p(tp,"cylinder");async function ci(e,t,r){const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i;const{shapeSvg:a,bbox:o}=await mt(e,t,xt(t)),n=Math.max(o.width+r.labelPaddingX*2,(t==null?void 0:t.width)||0),l=Math.max(o.height+r.labelPaddingY*2,(t==null?void 0:t.height)||0),c=-n/2,h=-l/2;let u,{rx:d,ry:f}=t;const{cssStyles:y}=t;if(r!=null&&r.rx&&r.ry&&(d=r.rx,f=r.ry),t.look==="handDrawn"){const m=nt.svg(a),C=ot(t,{}),x=d||f?m.path(pe(c,h,n,l,d||0),C):m.rectangle(c,h,n,l,C);u=a.insert(()=>x,":first-child"),u.attr("class","basic label-container").attr("style",Xt(y))}else u=a.insert("rect",":first-child"),u.attr("class","basic label-container").attr("style",s).attr("rx",Xt(d)).attr("ry",Xt(f)).attr("x",c).attr("y",h).attr("width",n).attr("height",l);return ct(t,u,t.look==="handDrawn"?void 0:{width:n,height:l}),t.calcIntersect=function(m,C){return st.rect(m,C)},t.intersect=function(m){return st.rect(t,m)},a}p(ci,"drawRect");async function ep(e,t){const{cssClasses:r,labelPaddingX:i,labelPaddingY:s,padding:a,width:o,height:n}=t,l={rx:0,ry:0,labelPaddingX:i??(a??0)*2,labelPaddingY:s??a??0},c=await ci(e,t,l);if(t.look==="handDrawn"){const f=nt.svg(c),y=ot(t,{}),m=c.select(".basic.label-container > path:nth-child(2)"),C=m.node();if(!C)return c;let x=null;if(C instanceof SVGGraphicsElement)x=C.getBBox();else return c;return c.insert(()=>f.line(x.x,x.y,x.x+x.width,x.y,y),".basic.label-container g.label"),c.insert(()=>f.line(x.x,x.y+x.height,x.x+x.width,x.y+x.height,y),".basic.label-container g.label"),m.remove(),c}const h=c.select(".basic.label-container"),u=(Number(h.attr("width"))||o)??0,d=(Number(h.attr("height"))||n)??0;return u>0&&d>0&&h.attr("stroke-dasharray",`${u} ${d}`),c}p(ep,"datastore");async function rp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.look==="neo"?16:t.padding??0,a=t.look==="neo"?16:t.padding??0,{shapeSvg:o,bbox:n,label:l}=await mt(e,t,xt(t)),c=n.width+s,h=n.height+a,u=h*.2,d=-c/2,f=-h/2-u/2,{cssStyles:y}=t,m=nt.svg(o),C=ot(t,{});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const x=[{x:d,y:f+u},{x:-d,y:f+u},{x:-d,y:-f},{x:d,y:-f},{x:d,y:f},{x:-d,y:f},{x:-d,y:f+u}],k=m.polygon(x.map(T=>[T.x,T.y]),C),w=o.insert(()=>k,":first-child");return w.attr("class","basic label-container outer-path"),y&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",y),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),l.attr("transform",`translate(${d+(t.padding??0)/2-(n.x-(n.left??0))}, ${f+u+(t.padding??0)/2-(n.y-(n.top??0))})`),ct(t,w),t.intersect=function(T){return st.rect(t,T)},o}p(rp,"dividedRectangle");async function ip(e,t){var f,y;const{labelStyles:r,nodeStyles:i}=dt(t),s=t.look==="neo"?12:5;t.labelStyle=r;const a=t.padding??0,o=t.look==="neo"?16:a,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=(t!=null&&t.width?(t==null?void 0:t.width)/2:l.width/2)+(o??0),h=c-s;let u;const{cssStyles:d}=t;if(t.look==="handDrawn"){const m=nt.svg(n),C=ot(t,{roughness:.2,strokeWidth:2.5}),x=ot(t,{roughness:.2,strokeWidth:1.5}),k=m.circle(0,0,c*2,C),w=m.circle(0,0,h*2,x);u=n.insert("g",":first-child"),u.attr("class",Xt(t.cssClasses)).attr("style",Xt(d)),(f=u.node())==null||f.appendChild(k),(y=u.node())==null||y.appendChild(w)}else{u=n.insert("g",":first-child");const m=u.insert("circle",":first-child"),C=u.insert("circle");u.attr("class","basic label-container").attr("style",i),m.attr("class","outer-circle").attr("style",i).attr("r",c).attr("cx",0).attr("cy",0),C.attr("class","inner-circle").attr("style",i).attr("r",h).attr("cx",0).attr("cy",0)}return ct(t,u),t.intersect=function(m){return I.info("DoubleCircle intersect",t,c,m),st.circle(t,c,m)},n}p(ip,"doublecircle");function sp(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:s}=dt(t);t.label="",t.labelStyle=i;const a=e.insert("g").attr("class",xt(t)).attr("id",t.domId??t.id),o=7,{cssStyles:n}=t,l=nt.svg(a),{nodeBorder:c}=r,h=ot(t,{fillStyle:"solid"});t.look!=="handDrawn"&&(h.roughness=0);const u=l.circle(0,0,o*2,h),d=a.insert(()=>u,":first-child");return d.selectAll("path").attr("style",`fill: ${c} !important;`),n&&n.length>0&&t.look!=="handDrawn"&&d.selectAll("path").attr("style",n),s&&t.look!=="handDrawn"&&d.selectAll("path").attr("style",s),ct(t,d),t.intersect=function(f){return I.info("filledCircle intersect",t,{radius:o,point:f}),st.circle(t,o,f)},a}p(sp,"filledCircle");var tc=10,ec=10;async function ap(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?s*2:s;(t.width||t.height)&&(t.height=(t==null?void 0:t.height)??0,t.height<tc&&(t.height=tc),t.width=((t==null?void 0:t.width)??0)-a-a/2,t.width<ec&&(t.width=ec));const{shapeSvg:o,bbox:n,label:l}=await mt(e,t,xt(t)),c=(t!=null&&t.width?t==null?void 0:t.width:n.width)+(a??0),h=t!=null&&t.height?t==null?void 0:t.height:c+n.height,u=h,d=[{x:0,y:-h},{x:u,y:-h},{x:u/2,y:0}],{cssStyles:f}=t,y=nt.svg(o),m=ot(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=Dt(d),x=y.path(C,m),k=o.insert(()=>x,":first-child").attr("transform",`translate(${-h/2}, ${h/2})`).attr("class","outer-path");return f&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",f),i&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",i),t.width=c,t.height=h,ct(t,k),l.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${-h/2+(t.padding??0)/2+(n.y-(n.top??0))})`),t.intersect=function(w){return I.info("Triangle intersect",t,d,w),st.polygon(t,d,w)},o}p(ap,"flippedTriangle");async function op(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=t.padding??12,l=Math.max(a.width+n*2,t.width??0,90),c=a.height+n*2,h=Math.max(Math.min(c*.16,14),8),u=Math.max(c+h,t.height??0),d=u-h,f=Math.max(l*.38,28),y=-u/2,m=[{x:-l/2,y},{x:-l/2+f,y},{x:-l/2+f,y:y+h},{x:l/2,y:y+h},{x:l/2,y:u/2},{x:-l/2,y:u/2}],C=[`M${m[0].x},${m[0].y}`,...m.slice(1).map(T=>`L${T.x},${T.y}`),"Z"].join(" "),{cssStyles:x}=t;let k;if(t.look==="handDrawn"){const _=nt.svg(s).path(C,ot(t,{}));k=s.insert(()=>_,":first-child").attr("class","basic label-container"),x&&k.attr("style",x)}else k=s.insert("path",":first-child").attr("d",C).attr("class","basic label-container").attr("style",i);t.look==="handDrawn"?ct(t,k):ct(t,k,{width:l,height:u});const w=y+h+d/2;return o.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${w-a.height/2-(a.y-(a.top??0))})`),t.intersect=function(T){return st.polygon(t,m,T)},s}p(op,"folder");function np(e,t,{dir:r,config:{state:i,themeVariables:s}}){const{nodeStyles:a}=dt(t);t.label="";const o=e.insert("g").attr("class",xt(t)).attr("id",t.domId??t.id),{cssStyles:n}=t;let l=Math.max(70,(t==null?void 0:t.width)??0),c=Math.max(10,(t==null?void 0:t.height)??0);r==="LR"&&(l=Math.max(10,(t==null?void 0:t.width)??0),c=Math.max(70,(t==null?void 0:t.height)??0));const h=-1*l/2,u=-1*c/2,d=nt.svg(o),f=ot(t,{stroke:s.lineColor,fill:s.lineColor});t.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");const y=d.rectangle(h,u,l,c,f),m=o.insert(()=>y,":first-child");n&&t.look!=="handDrawn"&&m.selectAll("path").attr("style",n),a&&t.look!=="handDrawn"&&m.selectAll("path").attr("style",a),ct(t,m);const C=(i==null?void 0:i.padding)??0;return t.width&&t.height&&(t.width+=C/2||0,t.height+=C/2||0),t.intersect=function(x){return st.rect(t,x)},o}p(np,"forkJoin");async function lp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=15,a=10,o=t.look==="neo"?16:t.padding??0,n=t.look==="neo"?12:t.padding??0;(t.width||t.height)&&(t.height=((t==null?void 0:t.height)??0)-n*2,t.height<a&&(t.height=a),t.width=((t==null?void 0:t.width)??0)-o*2,t.width<s&&(t.width=s));const{shapeSvg:l,bbox:c}=await mt(e,t,xt(t)),h=(t!=null&&t.width?t==null?void 0:t.width:Math.max(s,c.width))+o*2,u=(t!=null&&t.height?t==null?void 0:t.height:Math.max(a,c.height))+n*2,d=u/2,{cssStyles:f}=t,y=nt.svg(l),m=ot(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=[{x:-h/2,y:-u/2},{x:h/2-d,y:-u/2},...Me(-h/2+d,0,d,50,90,270),{x:h/2-d,y:u/2},{x:-h/2,y:u/2}],x=Dt(C),k=y.path(x,m),w=l.insert(()=>k,":first-child");return w.attr("class","basic label-container outer-path"),f&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",f),i&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",i),ct(t,w),t.intersect=function(T){return I.info("Pill intersect",t,{radius:d,point:T}),st.polygon(t,C,T)},l}p(lp,"halfRoundedRectangle");var Q2=p((e,t,r,i,s)=>[`M${e+s},${t}`,`L${e+r-s},${t}`,`L${e+r},${t-i/2}`,`L${e+r-s},${t-i}`,`L${e+s},${t-i}`,`L${e},${t-i/2}`,"Z"].join(" "),"createHexagonPathD");async function hp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t),s=t.look==="neo"?3.5:4;t.labelStyle=r;const a=t.padding??0,o=70,n=32,l=t.look==="neo"?o:a,c=t.look==="neo"?n:a;if(t.width||t.height){const w=(t.height??0)/s;t.width=((t==null?void 0:t.width)??0)-2*w-c,t.height=(t.height??0)-l}const{shapeSvg:h,bbox:u}=await mt(e,t,xt(t)),d=(t!=null&&t.height?t==null?void 0:t.height:u.height)+l,f=d/s,y=(t!=null&&t.width?t==null?void 0:t.width:u.width)+2*f+c,m=[{x:f,y:0},{x:y-f,y:0},{x:y,y:-d/2},{x:y-f,y:-d},{x:f,y:-d},{x:0,y:-d/2}];let C;const{cssStyles:x}=t;if(t.look==="handDrawn"){const k=nt.svg(h),w=ot(t,{}),T=Q2(0,0,y,d,f),_=k.path(T,w);C=h.insert(()=>_,":first-child").attr("transform",`translate(${-y/2}, ${d/2})`),x&&C.attr("style",x)}else C=Ie(h,y,d,m);return i&&C.attr("style",i),t.width=y,t.height=d,ct(t,C),t.intersect=function(k){return st.polygon(t,m,k)},h}p(hp,"hexagon");async function cp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.label="",t.labelStyle=r;const{shapeSvg:s}=await mt(e,t,xt(t)),a=Math.max(30,(t==null?void 0:t.width)??0),o=Math.max(30,(t==null?void 0:t.height)??0),{cssStyles:n}=t,l=nt.svg(s),c=ot(t,{});t.look!=="handDrawn"&&(c.roughness=0,c.fillStyle="solid");const h=[{x:0,y:0},{x:a,y:0},{x:0,y:o},{x:a,y:o}],u=Dt(h),d=l.path(u,c),f=s.insert(()=>d,":first-child");return f.attr("class","basic label-container outer-path"),n&&t.look!=="handDrawn"&&f.selectChildren("path").attr("style",n),i&&t.look!=="handDrawn"&&f.selectChildren("path").attr("style",i),f.attr("transform",`translate(${-a/2}, ${-o/2})`),ct(t,f),t.intersect=function(y){return I.info("Pill intersect",t,{points:h}),st.polygon(t,h,y)},s}p(cp,"hourglass");async function up(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:s}=dt(t);t.labelStyle=s;const a=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(a,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:c,bbox:h,label:u}=await mt(e,t,"icon-shape default"),d=t.pos==="t",f=n,y=n,{nodeBorder:m}=r,{stylesMap:C}=hi(t),x=-y/2,k=-f/2,w=t.label?8:0,T=nt.svg(c),_=ot(t,{stroke:"none",fill:"none"});t.look!=="handDrawn"&&(_.roughness=0,_.fillStyle="solid");const v=T.rectangle(x,k,y,f,_),F=Math.max(y,h.width),L=f+h.height+w,U=T.rectangle(-F/2,-L/2,F,L,{..._,fill:"transparent",stroke:"none"}),W=c.insert(()=>v,":first-child"),q=c.insert(()=>U);if(t.icon){const rt=c.append("g");rt.html(`<g>${await hs(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const Y=rt.node().getBBox(),A=Y.width,E=Y.height,B=Y.x,D=Y.y;rt.attr("transform",`translate(${-A/2-B},${d?h.height/2+w/2-E/2-D:-h.height/2-w/2-E/2-D})`),rt.attr("style",`color: ${C.get("stroke")??m};`)}return u.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${d?-L/2:L/2-h.height})`),W.attr("transform",`translate(0,${d?h.height/2+w/2:-h.height/2-w/2})`),ct(t,q),t.intersect=function(rt){if(I.info("iconSquare intersect",t,rt),!t.label)return st.rect(t,rt);const Y=t.x??0,A=t.y??0,E=t.height??0;let B=[];return d?B=[{x:Y-h.width/2,y:A-E/2},{x:Y+h.width/2,y:A-E/2},{x:Y+h.width/2,y:A-E/2+h.height+w},{x:Y+y/2,y:A-E/2+h.height+w},{x:Y+y/2,y:A+E/2},{x:Y-y/2,y:A+E/2},{x:Y-y/2,y:A-E/2+h.height+w},{x:Y-h.width/2,y:A-E/2+h.height+w}]:B=[{x:Y-y/2,y:A-E/2},{x:Y+y/2,y:A-E/2},{x:Y+y/2,y:A-E/2+f},{x:Y+h.width/2,y:A-E/2+f},{x:Y+h.width/2/2,y:A+E/2},{x:Y-h.width/2,y:A+E/2},{x:Y-h.width/2,y:A-E/2+f},{x:Y-y/2,y:A-E/2+f}],st.polygon(t,B,rt)},c}p(up,"icon");async function dp(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:s}=dt(t);t.labelStyle=s;const a=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(a,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:c,bbox:h,label:u}=await mt(e,t,"icon-shape default"),d=20,f=t.label?8:0,y=t.pos==="t",{nodeBorder:m,mainBkg:C}=r,{stylesMap:x}=hi(t),k=nt.svg(c),w=ot(t,{});t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");const T=x.get("fill");w.stroke=T??C;const _=c.append("g");t.icon&&_.html(`<g>${await hs(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const v=_.node().getBBox(),F=v.width,L=v.height,U=v.x,W=v.y,q=Math.max(F,L)*Math.SQRT2+d*2,rt=k.circle(0,0,q,w),Y=Math.max(q,h.width),A=q+h.height+f,E=k.rectangle(-Y/2,-A/2,Y,A,{...w,fill:"transparent",stroke:"none"}),B=c.insert(()=>rt,":first-child"),D=c.insert(()=>E);return _.attr("transform",`translate(${-F/2-U},${y?h.height/2+f/2-L/2-W:-h.height/2-f/2-L/2-W})`),_.attr("style",`color: ${x.get("stroke")??m};`),u.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${y?-A/2:A/2-h.height})`),B.attr("transform",`translate(0,${y?h.height/2+f/2:-h.height/2-f/2})`),ct(t,D),t.intersect=function($){return I.info("iconSquare intersect",t,$),st.rect(t,$)},c}p(dp,"iconCircle");async function fp(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:s}=dt(t);t.labelStyle=s;const a=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(a,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:c,bbox:h,halfPadding:u,label:d}=await mt(e,t,"icon-shape default"),f=t.pos==="t",y=n+u*2,m=n+u*2,{nodeBorder:C,mainBkg:x}=r,{stylesMap:k}=hi(t),w=-m/2,T=-y/2,_=t.label?8:0,v=nt.svg(c),F=ot(t,{});t.look!=="handDrawn"&&(F.roughness=0,F.fillStyle="solid");const L=k.get("fill");F.stroke=L??x;const U=v.path(pe(w,T,m,y,5),F),W=Math.max(m,h.width),q=y+h.height+_,rt=v.rectangle(-W/2,-q/2,W,q,{...F,fill:"transparent",stroke:"none"}),Y=c.insert(()=>U,":first-child").attr("class","icon-shape2"),A=c.insert(()=>rt);if(t.icon){const E=c.append("g");E.html(`<g>${await hs(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const B=E.node().getBBox(),D=B.width,$=B.height,N=B.x,V=B.y;E.attr("transform",`translate(${-D/2-N},${f?h.height/2+_/2-$/2-V:-h.height/2-_/2-$/2-V})`),E.attr("style",`color: ${k.get("stroke")??C};`)}return d.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${f?-q/2:q/2-h.height})`),Y.attr("transform",`translate(0,${f?h.height/2+_/2:-h.height/2-_/2})`),ct(t,A),t.intersect=function(E){if(I.info("iconSquare intersect",t,E),!t.label)return st.rect(t,E);const B=t.x??0,D=t.y??0,$=t.height??0;let N=[];return f?N=[{x:B-h.width/2,y:D-$/2},{x:B+h.width/2,y:D-$/2},{x:B+h.width/2,y:D-$/2+h.height+_},{x:B+m/2,y:D-$/2+h.height+_},{x:B+m/2,y:D+$/2},{x:B-m/2,y:D+$/2},{x:B-m/2,y:D-$/2+h.height+_},{x:B-h.width/2,y:D-$/2+h.height+_}]:N=[{x:B-m/2,y:D-$/2},{x:B+m/2,y:D-$/2},{x:B+m/2,y:D-$/2+y},{x:B+h.width/2,y:D-$/2+y},{x:B+h.width/2/2,y:D+$/2},{x:B-h.width/2,y:D+$/2},{x:B-h.width/2,y:D-$/2+y},{x:B-m/2,y:D-$/2+y}],st.polygon(t,N,E)},c}p(fp,"iconRounded");async function pp(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:s}=dt(t);t.labelStyle=s;const a=t.assetHeight??48,o=t.assetWidth??48,n=Math.max(a,o),l=i==null?void 0:i.wrappingWidth;t.width=Math.max(n,l??0);const{shapeSvg:c,bbox:h,halfPadding:u,label:d}=await mt(e,t,"icon-shape default"),f=t.pos==="t",y=n+u*2,m=n+u*2,{nodeBorder:C,mainBkg:x}=r,{stylesMap:k}=hi(t),w=-m/2,T=-y/2,_=t.label?8:0,v=nt.svg(c),F=ot(t,{});t.look!=="handDrawn"&&(F.roughness=0,F.fillStyle="solid");const L=k.get("fill");F.stroke=L??x;const U=v.path(pe(w,T,m,y,.1),F),W=Math.max(m,h.width),q=y+h.height+_,rt=v.rectangle(-W/2,-q/2,W,q,{...F,fill:"transparent",stroke:"none"}),Y=c.insert(()=>U,":first-child"),A=c.insert(()=>rt);if(t.icon){const E=c.append("g");E.html(`<g>${await hs(t.icon,{height:n,width:n,fallbackPrefix:""})}</g>`);const B=E.node().getBBox(),D=B.width,$=B.height,N=B.x,V=B.y;E.attr("transform",`translate(${-D/2-N},${f?h.height/2+_/2-$/2-V:-h.height/2-_/2-$/2-V})`),E.attr("style",`color: ${k.get("stroke")??C};`)}return d.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${f?-q/2:q/2-h.height})`),Y.attr("transform",`translate(0,${f?h.height/2+_/2:-h.height/2-_/2})`),ct(t,A),t.intersect=function(E){if(I.info("iconSquare intersect",t,E),!t.label)return st.rect(t,E);const B=t.x??0,D=t.y??0,$=t.height??0;let N=[];return f?N=[{x:B-h.width/2,y:D-$/2},{x:B+h.width/2,y:D-$/2},{x:B+h.width/2,y:D-$/2+h.height+_},{x:B+m/2,y:D-$/2+h.height+_},{x:B+m/2,y:D+$/2},{x:B-m/2,y:D+$/2},{x:B-m/2,y:D-$/2+h.height+_},{x:B-h.width/2,y:D-$/2+h.height+_}]:N=[{x:B-m/2,y:D-$/2},{x:B+m/2,y:D-$/2},{x:B+m/2,y:D-$/2+y},{x:B+h.width/2,y:D-$/2+y},{x:B+h.width/2/2,y:D+$/2},{x:B-h.width/2,y:D+$/2},{x:B-h.width/2,y:D-$/2+y},{x:B-m/2,y:D-$/2+y}],st.polygon(t,N,E)},c}p(pp,"iconSquare");async function gp(e,t,{config:{flowchart:r}}){const i=new Image;i.src=(t==null?void 0:t.img)??"",await i.decode();const s=Number(i.naturalWidth.toString().replace("px","")),a=Number(i.naturalHeight.toString().replace("px",""));t.imageAspectRatio=s/a;const{labelStyles:o}=dt(t);t.labelStyle=o;const n=r==null?void 0:r.wrappingWidth;t.defaultWidth=r==null?void 0:r.wrappingWidth;const l=Math.max(t.label?n??0:0,(t==null?void 0:t.assetWidth)??s),c=t.constraint==="on"&&t!=null&&t.assetHeight?t.assetHeight*t.imageAspectRatio:l,h=t.constraint==="on"?c/t.imageAspectRatio:(t==null?void 0:t.assetHeight)??a;t.width=Math.max(c,n??0);const{shapeSvg:u,bbox:d,label:f}=await mt(e,t,"image-shape default"),y=t.pos==="t",m=-c/2,C=-h/2,x=t.label?8:0,k=nt.svg(u),w=ot(t,{});t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");const T=k.rectangle(m,C,c,h,w),_=Math.max(c,d.width),v=h+d.height+x,F=k.rectangle(-_/2,-v/2,_,v,{...w,fill:"none",stroke:"none"}),L=u.insert(()=>T,":first-child"),U=u.insert(()=>F);if(t.img){const W=u.append("image");W.attr("href",t.img),W.attr("width",c),W.attr("height",h),W.attr("preserveAspectRatio","none"),W.attr("transform",`translate(${-c/2},${y?v/2-h:-v/2})`)}return f.attr("transform",`translate(${-d.width/2-(d.x-(d.left??0))},${y?-h/2-d.height/2-x/2:h/2-d.height/2+x/2})`),L.attr("transform",`translate(0,${y?d.height/2+x/2:-d.height/2-x/2})`),ct(t,U),t.intersect=function(W){if(I.info("iconSquare intersect",t,W),!t.label)return st.rect(t,W);const q=t.x??0,rt=t.y??0,Y=t.height??0;let A=[];return y?A=[{x:q-d.width/2,y:rt-Y/2},{x:q+d.width/2,y:rt-Y/2},{x:q+d.width/2,y:rt-Y/2+d.height+x},{x:q+c/2,y:rt-Y/2+d.height+x},{x:q+c/2,y:rt+Y/2},{x:q-c/2,y:rt+Y/2},{x:q-c/2,y:rt-Y/2+d.height+x},{x:q-d.width/2,y:rt-Y/2+d.height+x}]:A=[{x:q-c/2,y:rt-Y/2},{x:q+c/2,y:rt-Y/2},{x:q+c/2,y:rt-Y/2+h},{x:q+d.width/2,y:rt-Y/2+h},{x:q+d.width/2/2,y:rt+Y/2},{x:q-d.width/2,y:rt+Y/2},{x:q-d.width/2,y:rt-Y/2+h},{x:q-c/2,y:rt-Y/2+h}],st.polygon(t,A,W)},u}p(gp,"imageSquare");async function yp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=s,o=t.look==="neo"?s*2:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=Math.max(l.height+a*2,t.height??0),h=Math.max(l.width+o*2,(t.width??0)-c),u=[{x:0,y:0},{x:h,y:0},{x:h+3*c/6,y:-c},{x:-3*c/6,y:-c}];let d;const{cssStyles:f}=t;if(t.look==="handDrawn"){const y=nt.svg(n),m=ot(t,{}),C=Dt(u),x=y.path(C,m);d=n.insert(()=>x,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),f&&d.attr("style",f)}else d=Ie(n,h,c,u);return i&&d.attr("style",i),t.width=h,t.height=c,ct(t,d),t.intersect=function(y){return st.polygon(t,u,y)},n}p(yp,"inv_trapezoid");async function mp(e,t){const{shapeSvg:r,bbox:i,label:s}=await mt(e,t,"label"),a=r.insert("rect",":first-child");return a.attr("width",.1).attr("height",.1),r.attr("class","label edgeLabel"),s.attr("transform",`translate(${-(i.width/2)-(i.x-(i.left??0))}, ${-(i.height/2)-(i.y-(i.top??0))})`),ct(t,a),t.intersect=function(l){return st.rect(t,l)},r}p(mp,"labelRect");async function xp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=s,o=t.look==="neo"?s*2:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=Math.max(l.height+a,t.height??0),h=Math.max(l.width+o,(t.width??0)-c),u=[{x:0,y:0},{x:h+3*c/6,y:0},{x:h,y:-c},{x:-(3*c)/6,y:-c}];let d;const{cssStyles:f}=t;if(t.look==="handDrawn"){const y=nt.svg(n),m=ot(t,{}),C=Dt(u),x=y.path(C,m);d=n.insert(()=>x,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),f&&d.attr("style",f)}else d=Ie(n,h,c,u);return i&&d.attr("style",i),t.width=h,t.height=c,ct(t,d),t.intersect=function(y){return st.polygon(t,u,y)},n}p(xp,"lean_left");async function Cp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=s,o=t.look==="neo"?s*2:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=Math.max(l.height+a,t.height??0),h=Math.max(l.width+o,(t.width??0)-c),u=[{x:-3*c/6,y:0},{x:h,y:0},{x:h+3*c/6,y:-c},{x:0,y:-c}];let d;const{cssStyles:f}=t;if(t.look==="handDrawn"){const y=nt.svg(n),m=ot(t,{}),C=Dt(u),x=y.path(C,m);d=n.insert(()=>x,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),f&&d.attr("style",f)}else d=Ie(n,h,c,u);return i&&d.attr("style",i),t.width=h,t.height=c,ct(t,d),t.intersect=function(y){return st.polygon(t,u,y)},n}p(Cp,"lean_right");function bp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.label="",t.labelStyle=r;const s=e.insert("g").attr("class",xt(t)).attr("id",t.domId??t.id),{cssStyles:a}=t,o=Math.max(35,(t==null?void 0:t.width)??0),n=Math.max(35,(t==null?void 0:t.height)??0),l=7,c=[{x:o,y:0},{x:0,y:n+l/2},{x:o-2*l,y:n+l/2},{x:0,y:2*n},{x:o,y:n-l/2},{x:2*l,y:n-l/2}],h=nt.svg(s),u=ot(t,{});t.look!=="handDrawn"&&(u.roughness=0,u.fillStyle="solid");const d=Dt(c),f=h.path(d,u),y=s.insert(()=>f,":first-child");return y.attr("class","outer-path"),a&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",a),i&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",i),y.attr("transform",`translate(-${o/2},${-n})`),ct(t,y),t.intersect=function(m){return I.info("lightningBolt intersect",t,m),st.polygon(t,c,m)},s}p(bp,"lightningBolt");var J2=p((e,t,r,i,s,a,o)=>[`M${e},${t+a}`,`a${s},${a} 0,0,0 ${r},0`,`a${s},${a} 0,0,0 ${-r},0`,`l0,${i}`,`a${s},${a} 0,0,0 ${r},0`,`l0,${-i}`,`M${e},${t+a+o}`,`a${s},${a} 0,0,0 ${r},0`].join(" "),"createCylinderPathD"),tw=p((e,t,r,i,s,a,o)=>[`M${e},${t+a}`,`M${e+r},${t+a}`,`a${s},${a} 0,0,0 ${-r},0`,`l0,${i}`,`a${s},${a} 0,0,0 ${r},0`,`l0,${-i}`,`M${e},${t+a+o}`,`a${s},${a} 0,0,0 ${r},0`].join(" "),"createOuterCylinderPathD"),ew=p((e,t,r,i,s,a)=>[`M${e-r/2},${-i/2}`,`a${s},${a} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD"),rc=10,ic=10;async function kp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?24:s;if(t.width||t.height){const x=t.width??0;t.width=(t.width??0)-a,t.width<ic&&(t.width=ic);const w=x/2/(2.5+x/50);t.height=(t.height??0)-o-w*3,t.height<rc&&(t.height=rc)}const{shapeSvg:n,bbox:l,label:c}=await mt(e,t,xt(t)),h=(t!=null&&t.width?t==null?void 0:t.width:l.width)+a*2,u=h/2,d=u/(2.5+h/50),f=(t!=null&&t.height?t==null?void 0:t.height:l.height)+d+o*2,y=f*.1;let m;const{cssStyles:C}=t;if(t.look==="handDrawn"){const x=nt.svg(n),k=tw(0,0,h,f,u,d,y),w=ew(0,d,h,f,u,d),T=ot(t,{}),_=x.path(k,T),v=x.path(w,T);n.insert(()=>v,":first-child").attr("class","line"),m=n.insert(()=>_,":first-child"),m.attr("class","basic label-container"),C&&m.attr("style",C)}else{const x=J2(0,0,h,f,u,d,y);m=n.insert("path",":first-child").attr("d",x).attr("class","basic label-container outer-path").attr("style",Xt(C)).attr("style",i)}return m.attr("label-offset-y",d),m.attr("transform",`translate(${-h/2}, ${-(f/2+d)})`),ct(t,m),c.attr("transform",`translate(${-(l.width/2)-(l.x-(l.left??0))}, ${-(l.height/2)+d-(l.y-(l.top??0))})`),t.intersect=function(x){const k=st.rect(t,x),w=k.x-(t.x??0);if(u!=0&&(Math.abs(w)<(t.width??0)/2||Math.abs(w)==(t.width??0)/2&&Math.abs(k.y-(t.y??0))>(t.height??0)/2-d)){let T=d*d*(1-w*w/(u*u));T>0&&(T=Math.sqrt(T)),T=d-T,x.y-(t.y??0)>0&&(T=-T),k.y+=T}return k},n}p(kp,"linedCylinder");async function wp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s;if(t.width||t.height){const T=t.width;t.width=(T??0)*10/11-a*2,t.width<10&&(t.width=10),t.height=((t==null?void 0:t.height)??0)-o*2,t.height<10&&(t.height=10)}const{shapeSvg:n,bbox:l,label:c}=await mt(e,t,xt(t)),h=(t!=null&&t.width?t==null?void 0:t.width:l.width)+(a??0)*2,u=(t!=null&&t.height?t==null?void 0:t.height:l.height)+(o??0)*2,d=t.look==="neo"?u/4:u/8,f=u+d,{cssStyles:y}=t,m=nt.svg(n),C=ot(t,{});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const x=[{x:-h/2-h/2*.1,y:-f/2},{x:-h/2-h/2*.1,y:f/2},...ir(-h/2-h/2*.1,f/2,h/2+h/2*.1,f/2,d,.8),{x:h/2+h/2*.1,y:-f/2},{x:-h/2-h/2*.1,y:-f/2},{x:-h/2,y:-f/2},{x:-h/2,y:f/2*1.1},{x:-h/2,y:-f/2}],k=m.polygon(x.map(T=>[T.x,T.y]),C),w=n.insert(()=>k,":first-child");return w.attr("class","basic label-container outer-path"),y&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",y),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),w.attr("transform",`translate(0,${-d/2})`),c.attr("transform",`translate(${-h/2+(t.padding??0)+h/2*.1/2-(l.x-(l.left??0))},${-u/2+(t.padding??0)-d/2-(l.y-(l.top??0))})`),ct(t,w),t.intersect=function(T){return st.polygon(t,x,T)},n}p(wp,"linedWaveEdgedRect");async function Sp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s,n=t.look==="neo"?10:5;(t.width||t.height)&&(t.width=Math.max(((t==null?void 0:t.width)??0)-a*2-2*n,10),t.height=Math.max(((t==null?void 0:t.height)??0)-o*2-2*n,10));const{shapeSvg:l,bbox:c,label:h}=await mt(e,t,xt(t)),u=(t!=null&&t.width?t==null?void 0:t.width:c.width)+a*2+2*n,d=(t!=null&&t.height?t==null?void 0:t.height:c.height)+o*2+2*n,f=u-2*n,y=d-2*n,m=-f/2,C=-y/2,{cssStyles:x}=t,k=nt.svg(l),w=ot(t,{}),T=[{x:m-n,y:C+n},{x:m-n,y:C+y+n},{x:m+f-n,y:C+y+n},{x:m+f-n,y:C+y},{x:m+f,y:C+y},{x:m+f,y:C+y-n},{x:m+f+n,y:C+y-n},{x:m+f+n,y:C-n},{x:m+n,y:C-n},{x:m+n,y:C},{x:m,y:C},{x:m,y:C+n}],_=[{x:m,y:C+n},{x:m+f-n,y:C+n},{x:m+f-n,y:C+y},{x:m+f,y:C+y},{x:m+f,y:C},{x:m,y:C}];t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");const v=Dt(T);let F=k.path(v,w);const L=Dt(_);let U=k.path(L,w);t.look!=="handDrawn"&&(F=en(F),U=en(U));const W=l.insert("g",":first-child");return W.insert(()=>F),W.insert(()=>U),W.attr("class","basic label-container outer-path"),x&&t.look!=="handDrawn"&&W.selectAll("path").attr("style",x),i&&t.look!=="handDrawn"&&W.selectAll("path").attr("style",i),h.attr("transform",`translate(${-(c.width/2)-n-(c.x-(c.left??0))}, ${-(c.height/2)+n-(c.y-(c.top??0))})`),ct(t,W),t.intersect=function(q){return st.polygon(t,T,q)},l}p(Sp,"multiRect");async function Tp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=t.padding??0,l=t.look==="neo"?16:n,c=t.look==="neo"?12:n;let h=!0;(t.width||t.height)&&(h=!1,t.width=((t==null?void 0:t.width)??0)-l*2,t.height=((t==null?void 0:t.height)??0)-c*3);const u=Math.max(a.width,(t==null?void 0:t.width)??0)+l*2,d=Math.max(a.height,(t==null?void 0:t.height)??0)+c*3,f=t.look==="neo"?d/4:d/8,y=d+(h?f/2:-f/2),m=-u/2,C=-y/2,x=10,{cssStyles:k}=t,w=ir(m-x,C+y+x,m+u-x,C+y+x,f,.8),T=w==null?void 0:w[w.length-1],_=[{x:m-x,y:C+x},{x:m-x,y:C+y+x},...w,{x:m+u-x,y:T.y-x},{x:m+u,y:T.y-x},{x:m+u,y:T.y-2*x},{x:m+u+x,y:T.y-2*x},{x:m+u+x,y:C-x},{x:m+x,y:C-x},{x:m+x,y:C},{x:m,y:C},{x:m,y:C+x}],v=[{x:m,y:C+x},{x:m+u-x,y:C+x},{x:m+u-x,y:T.y-x},{x:m+u,y:T.y-x},{x:m+u,y:C},{x:m,y:C}],F=nt.svg(s),L=ot(t,{});t.look!=="handDrawn"&&(L.roughness=0,L.fillStyle="solid");const U=Dt(_),W=F.path(U,L),q=Dt(v),rt=F.path(q,L),Y=s.insert(()=>W,":first-child");return Y.insert(()=>rt),Y.attr("class","basic label-container outer-path"),k&&t.look!=="handDrawn"&&Y.selectAll("path").attr("style",k),i&&t.look!=="handDrawn"&&Y.selectAll("path").attr("style",i),Y.attr("transform",`translate(0,${-f/2})`),o.attr("transform",`translate(${-(a.width/2)-x-(a.x-(a.left??0))}, ${-(a.height/2)+x-f/2-(a.y-(a.top??0))})`),ct(t,Y),t.intersect=function(A){return st.polygon(t,_,A)},s}p(Tp,"multiWaveEdgedRectangle");async function _p(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i,t.useHtmlLabels||ee(Ht())||(t.centerLabel=!0);const{shapeSvg:o,bbox:n,label:l}=await mt(e,t,xt(t)),c=Math.max(n.width+(t.padding??0)*2,(t==null?void 0:t.width)??0),h=Math.max(n.height+(t.padding??0)*2,(t==null?void 0:t.height)??0),u=-c/2,d=-h/2,{cssStyles:f}=t,y=nt.svg(o),m=ot(t,{fill:r.noteBkgColor,stroke:r.noteBorderColor});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=y.rectangle(u,d,c,h,m),x=o.insert(()=>C,":first-child");return x.attr("class","basic label-container outer-path"),l.attr("class","label noteLabel"),f&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",f),s&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",s),l.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),ct(t,x),t.intersect=function(k){return st.rect(t,k)},o}p(_p,"note");var rw=p((e,t,r)=>[`M${e+r/2},${t}`,`L${e+r},${t-r/2}`,`L${e+r/2},${t-r}`,`L${e},${t-r/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function Bp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a}=await mt(e,t,xt(t)),o=a.width+(t.padding??0),n=a.height+(t.padding??0),l=o+n,c=.5,h=[{x:l/2,y:0},{x:l,y:-l/2},{x:l/2,y:-l},{x:0,y:-l/2}];let u;const{cssStyles:d}=t;if(t.look==="handDrawn"){const f=nt.svg(s),y=ot(t,{}),m=rw(0,0,l),C=f.path(m,y);u=s.insert(()=>C,":first-child").attr("transform",`translate(${-l/2+c}, ${l/2})`),d&&u.attr("style",d)}else u=Ie(s,l,l,h),u.attr("transform",`translate(${-l/2+c}, ${l/2})`);return i&&u.attr("style",i),ct(t,u),t.calcIntersect=function(f,y){const m=f.width,C=[{x:m/2,y:0},{x:m,y:-m/2},{x:m/2,y:-m},{x:0,y:-m/2}],x=st.polygon(f,C,y);return{x:x.x-.5,y:x.y-.5}},t.intersect=function(f){return this.calcIntersect(t,f)},s}p(Bp,"question");async function vp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?21:s??0,o=t.look==="neo"?12:s??0,{shapeSvg:n,bbox:l,label:c}=await mt(e,t,xt(t)),h=l.width+(t.look==="neo"?a*2:a),u=Math.max(l.height+(t.look==="neo"?o*2:o),t.height??0),d=u/4,y=-Math.max(h,(t.width??0)-d)/2,m=-u/2,C=m/2,x=[{x:y+C,y:m},{x:y,y:0},{x:y+C,y:-m},{x:-y,y:-m},{x:-y,y:m}],{cssStyles:k}=t,w=nt.svg(n),T=ot(t,{});t.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");const _=Dt(x),v=w.path(_,T),F=n.insert(()=>v,":first-child");return F.attr("class","basic label-container outer-path"),k&&t.look!=="handDrawn"&&F.selectAll("path").attr("style",k),i&&t.look!=="handDrawn"&&F.selectAll("path").attr("style",i),F.attr("transform",`translate(${-C/2},0)`),c.attr("transform",`translate(${-C/2-l.width/2-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),ct(t,F),t.intersect=function(L){return st.polygon(t,x,L)},n}p(vp,"rect_left_inv_arrow");async function Lp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;let s;t.cssClasses?s="node "+t.cssClasses:s="node default";const a=e.insert("g").attr("class",s).attr("id",t.domId||t.id),o=a.insert("g"),n=a.insert("g").attr("class","label").attr("style",i),l=t.description,c=t.label,h=await Qe(n,c,t.labelStyle,!0,!0);let u={width:0,height:0};if(ee(At())){const L=h.children[0],U=Lt(h);u=L.getBoundingClientRect(),U.attr("width",u.width),U.attr("height",u.height)}I.info("Text 2",l);const d=l||[],f=h.getBBox(),y=await Qe(n,Array.isArray(d)?d.join("<br/>"):d,t.labelStyle,!0,!0),m=y.children[0],C=Lt(y);u=m.getBoundingClientRect(),C.attr("width",u.width),C.attr("height",u.height);const x=(t.padding||0)/2;Lt(y).attr("transform","translate( "+(u.width>f.width?0:(f.width-u.width)/2)+", "+(f.height+x+5)+")"),Lt(h).attr("transform","translate( "+(u.width<f.width?0:-(f.width-u.width)/2)+", 0)"),u=n.node().getBBox(),n.attr("transform","translate("+-u.width/2+", "+(-u.height/2-x+3)+")");const k=u.width+(t.padding||0),w=u.height+(t.padding||0),T=-u.width/2-x,_=-u.height/2-x;let v,F;if(t.look==="handDrawn"){const L=nt.svg(a),U=ot(t,{}),W=L.path(pe(T,_,k,w,t.rx||0),U),q=L.line(-u.width/2-x,-u.height/2-x+f.height+x,u.width/2+x,-u.height/2-x+f.height+x,U);F=a.insert(()=>(I.debug("Rough node insert CXC",W),q),":first-child"),v=a.insert(()=>(I.debug("Rough node insert CXC",W),W),":first-child")}else v=o.insert("rect",":first-child"),F=o.insert("line"),v.attr("class","outer title-state").attr("style",i).attr("x",-u.width/2-x).attr("y",-u.height/2-x).attr("width",u.width+(t.padding||0)).attr("height",u.height+(t.padding||0)),F.attr("class","divider").attr("x1",-u.width/2-x).attr("x2",u.width/2+x).attr("y1",-u.height/2-x+f.height+x).attr("y2",-u.height/2-x+f.height+x);return ct(t,v),t.intersect=function(L){return st.rect(t,L)},a}p(Lp,"rectWithTitle");async function Fp(e,t,{config:{themeVariables:r}}){const i=(r==null?void 0:r.radius)??5,s={rx:i,ry:i,labelPaddingX:((t==null?void 0:t.padding)??0)*1,labelPaddingY:((t==null?void 0:t.padding)??0)*1};return ci(e,t,s)}p(Fp,"roundedRect");var sr=8;async function Mp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.look==="neo"?16:t.padding??0,a=t.look==="neo"?12:t.padding??0,{shapeSvg:o,bbox:n,label:l}=await mt(e,t,xt(t)),c=((t==null?void 0:t.width)??n.width)+s*2+(t.look==="neo"?sr:sr*2),h=((t==null?void 0:t.height)??n.height)+a*2,u=c-sr,d=h,f=sr-c/2,y=-h/2,{cssStyles:m}=t,C=nt.svg(o),x=ot(t,{});t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");const k=[{x:f,y},{x:f+u,y},{x:f+u,y:y+d},{x:f-sr,y:y+d},{x:f-sr,y},{x:f,y},{x:f,y:y+d}],w=C.polygon(k.map(_=>[_.x,_.y]),x),T=o.insert(()=>w,":first-child");return T.attr("class","basic label-container outer-path").attr("style",Xt(m)),i&&t.look!=="handDrawn"&&T.selectAll("path").attr("style",i),m&&t.look!=="handDrawn"&&T.selectAll("path").attr("style",i),l.attr("transform",`translate(${sr/2-n.width/2-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),ct(t,T),t.intersect=function(_){return st.rect(t,_)},o}p(Mp,"shadedProcess");async function Ap(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s;(t.width||t.height)&&(t.width=Math.max(((t==null?void 0:t.width)??0)-a*2,10),t.height=Math.max(((t==null?void 0:t.height)??0)/1.5-o*2,10));const{shapeSvg:n,bbox:l,label:c}=await mt(e,t,xt(t)),h=(t!=null&&t.width?t==null?void 0:t.width:l.width)+a*2,u=((t!=null&&t.height?t==null?void 0:t.height:l.height)+o*2)*1.5,d=h,f=u/1.5,y=-d/2,m=-f/2,{cssStyles:C}=t,x=nt.svg(n),k=ot(t,{});t.look!=="handDrawn"&&(k.roughness=0,k.fillStyle="solid");const w=[{x:y,y:m},{x:y,y:m+f},{x:y+d,y:m+f},{x:y+d,y:m-f/2}],T=Dt(w),_=x.path(T,k),v=n.insert(()=>_,":first-child");return v.attr("class","basic label-container outer-path"),C&&t.look!=="handDrawn"&&v.selectChildren("path").attr("style",C),i&&t.look!=="handDrawn"&&v.selectChildren("path").attr("style",i),v.attr("transform",`translate(0, ${f/4})`),c.attr("transform",`translate(${-d/2+(t.padding??0)-(l.x-(l.left??0))}, ${-f/4+(t.padding??0)-(l.y-(l.top??0))})`),ct(t,v),t.intersect=function(F){return st.polygon(t,w,F)},n}p(Ap,"slopedRect");async function Ep(e,t){const r=t.padding??0,i=t.look==="neo"?16:r*2,s=t.look==="neo"?12:r,a={rx:0,ry:0,labelPaddingX:t.labelPaddingX??i,labelPaddingY:s};return ci(e,t,a)}p(Ep,"squareRect");async function $p(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?20:s,o=t.look==="neo"?12:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=l.height+(t.look==="neo"?o*2:o),h=l.width+c/4+(t.look==="neo"?a*2:a),u=c/2,{cssStyles:d}=t,f=nt.svg(n),y=ot(t,{});t.look!=="handDrawn"&&(y.roughness=0,y.fillStyle="solid");const m=[{x:-h/2+u,y:-c/2},{x:h/2-u,y:-c/2},...Me(-h/2+u,0,u,50,90,270),{x:h/2-u,y:c/2},...Me(h/2-u,0,u,50,270,450)],C=Dt(m),x=f.path(C,y),k=n.insert(()=>x,":first-child");return k.attr("class","basic label-container outer-path"),d&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",d),i&&t.look!=="handDrawn"&&k.selectChildren("path").attr("style",i),ct(t,k),t.intersect=function(w){return st.polygon(t,m,w)},n}p($p,"stadium");async function Op(e,t){const r={rx:t.look==="neo"?3:5,ry:t.look==="neo"?3:5};return ci(e,t,r)}p(Op,"state");function Dp(e,t,{config:{themeVariables:r}}){var k,w;const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i;const{cssStyles:a}=t,{lineColor:o,stateBorder:n,nodeBorder:l,nodeShadow:c}=r;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||(t.width=14),t.height||(t.height=14);const h=e.insert("g").attr("class","node default").attr("id",t.domId??t.id),u=nt.svg(h),d=ot(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const f=u.circle(0,0,t.width,{...d,stroke:o,strokeWidth:2}),y=n??l,m=(t.width??0)*5/14,C=u.circle(0,0,m,{...d,fill:y,stroke:y,strokeWidth:2,fillStyle:"solid"}),x=h.insert(()=>f,":first-child");if(x.insert(()=>C),t.look!=="handDrawn"&&x.attr("class","outer-path"),a&&x.selectAll("path").attr("style",a),s&&x.selectAll("path").attr("style",s),t.width<25&&c&&t.look!=="handDrawn"){const T=((w=(k=e.node())==null?void 0:k.ownerSVGElement)==null?void 0:w.id)??"",_=T?`${T}-drop-shadow-small`:"drop-shadow-small";x.attr("style",`filter:url(#${_})`)}return ct(t,x),t.intersect=function(T){return st.circle(t,(t.width??0)/2,T)},h}p(Dp,"stateEnd");function Pp(e,t,{config:{themeVariables:r}}){var n,l;const{lineColor:i,nodeShadow:s}=r;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||(t.width=14),t.height||(t.height=14);const a=e.insert("g").attr("class","node default").attr("id",t.domId||t.id);let o;if(t.look==="handDrawn"){const h=nt.svg(a).circle(0,0,t.width,A1(i));o=a.insert(()=>h),o.attr("class","state-start").attr("r",(t.width??7)/2).attr("width",t.width??14).attr("height",t.height??14)}else o=a.insert("circle",":first-child"),o.attr("class","state-start").attr("r",(t.width??7)/2).attr("width",t.width??14).attr("height",t.height??14);if(t.width<25&&s&&t.look!=="handDrawn"){const c=((l=(n=e.node())==null?void 0:n.ownerSVGElement)==null?void 0:l.id)??"",h=c?`${c}-drop-shadow-small`:"drop-shadow-small";o.attr("style",`filter:url(#${h})`)}return ct(t,o),t.intersect=function(c){return st.circle(t,(t.width??7)/2,c)},a}p(Pp,"stateStart");var $r=8;async function Ip(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=(t==null?void 0:t.padding)??8,a=t.look==="neo"?28:s,o=t.look==="neo"?12:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=Math.max(l.width+2*$r+a,t.width??0),h=Math.max(l.height+o,t.height??0),u=c-2*$r,d=h,f=-c/2,y=-h/2,m=[{x:0,y:0},{x:u,y:0},{x:u,y:-d},{x:0,y:-d},{x:0,y:0},{x:-8,y:0},{x:u+8,y:0},{x:u+8,y:-d},{x:-8,y:-d},{x:-8,y:0}];if(t.look==="handDrawn"){const C=nt.svg(n),x=ot(t,{}),k=C.rectangle(f,y,u+16,d,x),w=C.line(f+$r,y,f+$r,y+d,x),T=C.line(f+$r+u,y,f+$r+u,y+d,x);n.insert(()=>w,":first-child"),n.insert(()=>T,":first-child");const _=n.insert(()=>k,":first-child"),{cssStyles:v}=t;_.attr("class","basic label-container").attr("style",Xt(v)),ct(t,_)}else{const C=Ie(n,u,d,m);i&&C.attr("style",i),ct(t,C)}return t.intersect=function(C){return st.polygon(t,m,C)},n}p(Ip,"subroutine");var Za=.2;async function Rp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s;(t.width||t.height)&&(t.height=Math.max(((t==null?void 0:t.height)??0)-o*2,10),t.width=Math.max(((t==null?void 0:t.width)??0)-a*2-Za*(t.height+o*2),10));const{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=(t!=null&&t.height?t==null?void 0:t.height:l.height)+o*2,h=Za*c,u=Za*c,f=(t!=null&&t.width?t==null?void 0:t.width:l.width)+a*2+h-h,y=c,m=-f/2,C=-y/2,{cssStyles:x}=t,k=nt.svg(n),w=ot(t,{}),T=[{x:m-h/2,y:C},{x:m+f+h/2,y:C},{x:m+f+h/2,y:C+y},{x:m-h/2,y:C+y}],_=[{x:m+f-h/2,y:C+y},{x:m+f+h/2,y:C+y},{x:m+f+h/2,y:C+y-u}];t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");const v=Dt(T),F=k.path(v,w),L=Dt(_),U=k.path(L,{...w,fillStyle:"solid"}),W=n.insert(()=>U,":first-child");return W.insert(()=>F,":first-child"),W.attr("class","basic label-container outer-path"),x&&t.look!=="handDrawn"&&W.selectAll("path").attr("style",x),i&&t.look!=="handDrawn"&&W.selectAll("path").attr("style",i),ct(t,W),t.intersect=function(q){return st.polygon(t,T,q)},n}p(Rp,"taggedRect");async function qp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,label:o}=await mt(e,t,xt(t)),n=Math.max(a.width+(t.padding??0)*2,(t==null?void 0:t.width)??0),l=Math.max(a.height+(t.padding??0)*2,(t==null?void 0:t.height)??0),c=l/8,h=.2*n,u=.2*l,d=l+c,{cssStyles:f}=t,y=nt.svg(s),m=ot(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=[{x:-n/2-n/2*.1,y:d/2},...ir(-n/2-n/2*.1,d/2,n/2+n/2*.1,d/2,c,.8),{x:n/2+n/2*.1,y:-d/2},{x:-n/2-n/2*.1,y:-d/2}],x=-n/2+n/2*.1,k=-d/2-u*.4,w=[{x:x+n-h,y:(k+l)*1.3},{x:x+n,y:k+l-u},{x:x+n,y:(k+l)*.9},...ir(x+n,(k+l)*1.25,x+n-h,(k+l)*1.3,-l*.02,.5)],T=Dt(C),_=y.path(T,m),v=Dt(w),F=y.path(v,{...m,fillStyle:"solid"}),L=s.insert(()=>F,":first-child");return L.insert(()=>_,":first-child"),L.attr("class","basic label-container outer-path"),f&&t.look!=="handDrawn"&&L.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&L.selectAll("path").attr("style",i),L.attr("transform",`translate(0,${-c/2})`),o.attr("transform",`translate(${-n/2+(t.padding??0)-(a.x-(a.left??0))},${-l/2+(t.padding??0)-c/2-(a.y-(a.top??0))})`),ct(t,L),t.intersect=function(U){return st.polygon(t,C,U)},s}p(qp,"taggedWaveEdgedRectangle");async function Np(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a}=await mt(e,t,xt(t)),o=Math.max(a.width+(t.padding??0),(t==null?void 0:t.width)||0),n=Math.max(a.height+(t.padding??0),(t==null?void 0:t.height)||0),l=-o/2,c=-n/2,h=s.insert("rect",":first-child");return h.attr("class","text").attr("style",i).attr("rx",0).attr("ry",0).attr("x",l).attr("y",c).attr("width",o).attr("height",n),ct(t,h),t.intersect=function(u){return st.rect(t,u)},s}p(Np,"text");var iw=p((e,t,r,i,s,a)=>`M${e},${t}
200
+ a${s},${a} 0,0,1 0,${-i}
201
+ l${r},0
202
+ a${s},${a} 0,0,1 0,${i}
203
+ M${r},${-i}
204
+ a${s},${a} 0,0,0 0,${i}
205
+ l${-r},0`,"createCylinderPathD"),sw=p((e,t,r,i,s,a)=>[`M${e},${t}`,`M${e+r},${t}`,`a${s},${a} 0,0,0 0,${-i}`,`l${-r},0`,`a${s},${a} 0,0,0 0,${i}`,`l${r},0`].join(" "),"createOuterCylinderPathD"),aw=p((e,t,r,i,s,a)=>[`M${e+r/2},${-i/2}`,`a${s},${a} 0,0,0 0,${i}`].join(" "),"createInnerCylinderPathD"),sc=5,ac=10;async function Wp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?12:s/2,o=t.height??0;if(t.height&&(t.height=t.height-a,t.height<sc&&(t.height=sc)),t.width){const x=o/2/(2.5+o/50);t.width=t.width-a-x*3,t.width<ac&&(t.width=ac)}const{shapeSvg:n,bbox:l,label:c}=await mt(e,t,xt(t)),h=Math.max(t.height??0,l.height)+a,u=h/2,d=u/(2.5+h/50),f=Math.max(t.width??0,l.width)+d+a,{cssStyles:y}=t;let m;if(t.look==="handDrawn"){const C=nt.svg(n),x=sw(0,0,f,h,d,u),k=aw(0,0,f,h,d,u),w=C.path(x,ot(t,{})),T=C.path(k,ot(t,{fill:"none"}));m=n.insert(()=>T,":first-child"),m=n.insert(()=>w,":first-child"),m.attr("class","basic label-container"),y&&m.attr("style",y)}else{const C=iw(0,0,f,h,d,u);m=n.insert("path",":first-child").attr("d",C).attr("class","basic label-container").attr("style",Xt(y)).attr("style",i),m.attr("class","basic label-container outer-path"),y&&m.selectAll("path").attr("style",y),i&&m.selectAll("path").attr("style",i)}return m.attr("label-offset-x",d),m.attr("transform",`translate(${-f/2}, ${h/2} )`),c.attr("transform",`translate(${-(l.width/2)-d-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),ct(t,m),t.intersect=function(C){const x=st.rect(t,C),k=x.y-(t.y??0);if(u!=0&&(Math.abs(k)<(t.height??0)/2||Math.abs(k)==(t.height??0)/2&&Math.abs(x.x-(t.x??0))>(t.width??0)/2-d)){let w=d*d*(1-k*k/(u*u));w!=0&&(w=Math.sqrt(Math.abs(w))),w=d-w,C.x-(t.x??0)>0&&(w=-w),x.x+=w}return x},n}p(Wp,"tiltedCylinder");async function zp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=(t.look==="neo",s),o=t.look==="neo"?s*2:s,{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=Math.max(l.height+a,t.height??0),h=Math.max(l.width+o,(t.width??0)-c),u=[{x:-3*c/6,y:0},{x:h+3*c/6,y:0},{x:h,y:-c},{x:0,y:-c}];let d;const{cssStyles:f}=t;if(t.look==="handDrawn"){const y=nt.svg(n),m=ot(t,{}),C=Dt(u),x=y.path(C,m);d=n.insert(()=>x,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),f&&d.attr("style",f)}else d=Ie(n,h,c,u);return i&&d.attr("style",i),t.width=h,t.height=c,ct(t,d),t.intersect=function(y){return st.polygon(t,u,y)},n}p(zp,"trapezoid");async function Hp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s,n=15,l=5;(t.width||t.height)&&(t.height=(t.height??0)-o*2,t.height<l&&(t.height=l),t.width=(t.width??0)-a*2,t.width<n&&(t.width=n));const{shapeSvg:c,bbox:h}=await mt(e,t,xt(t)),u=(t!=null&&t.width?t==null?void 0:t.width:h.width)+a*2,d=(t!=null&&t.height?t==null?void 0:t.height:h.height)+o*2,{cssStyles:f}=t,y=nt.svg(c),m=ot(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=[{x:-u/2*.8,y:-d/2},{x:u/2*.8,y:-d/2},{x:u/2,y:-d/2*.6},{x:u/2,y:d/2},{x:-u/2,y:d/2},{x:-u/2,y:-d/2*.6}],x=Dt(C),k=y.path(x,m),w=c.insert(()=>k,":first-child");return w.attr("class","basic label-container outer-path"),f&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",f),i&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",i),ct(t,w),t.intersect=function(T){return st.polygon(t,C,T)},c}p(Hp,"trapezoidalPentagon");var oc=10,nc=10;async function Yp(e,t){var T;const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?s*2:s;(t.width||t.height)&&(t.width=(((t==null?void 0:t.width)??0)-a)/2,t.width<nc&&(t.width=nc),t.height=(t==null?void 0:t.height)??0,t.height<oc&&(t.height=oc));const{shapeSvg:o,bbox:n,label:l}=await mt(e,t,xt(t)),c=De((T=At().flowchart)==null?void 0:T.htmlLabels),h=(t!=null&&t.width?t==null?void 0:t.width:n.width)+a,u=t!=null&&t.height?t==null?void 0:t.height:h+n.height,d=u,f=[{x:0,y:0},{x:d,y:0},{x:d/2,y:-u}],{cssStyles:y}=t,m=nt.svg(o),C=ot(t,{});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const x=Dt(f),k=m.path(x,C),w=o.insert(()=>k,":first-child").attr("transform",`translate(${-u/2}, ${u/2})`).attr("class","outer-path");return y&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",y),i&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",i),t.width=h,t.height=u,ct(t,w),l.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${u/2-(n.height+(t.padding??0)/(c?2:1)-(n.y-(n.top??0)))})`),t.intersect=function(_){return I.info("Triangle intersect",t,f,_),st.polygon(t,f,_)},o}p(Yp,"triangle");async function jp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?12:s;let n=!0;(t.width||t.height)&&(n=!1,t.width=((t==null?void 0:t.width)??0)-a*2,t.width<10&&(t.width=10),t.height=((t==null?void 0:t.height)??0)-o*2,t.height<10&&(t.height=10));const{shapeSvg:l,bbox:c,label:h}=await mt(e,t,xt(t)),u=(t!=null&&t.width?t==null?void 0:t.width:c.width)+(a??0)*2,d=(t!=null&&t.height?t==null?void 0:t.height:c.height)+(o??0)*2,f=t.look==="neo"?d/4:d/8,y=d+(n?f:-f),{cssStyles:m}=t,x=14-u,k=x>0?x/2:0,w=nt.svg(l),T=ot(t,{});t.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");const _=[{x:-u/2-k,y:y/2},...ir(-u/2-k,y/2,u/2+k,y/2,f,.8),{x:u/2+k,y:-y/2},{x:-u/2-k,y:-y/2}],v=Dt(_),F=w.path(v,T),L=l.insert(()=>F,":first-child");return L.attr("class","basic label-container outer-path"),m&&t.look!=="handDrawn"&&L.selectAll("path").attr("style",m),i&&t.look!=="handDrawn"&&L.selectAll("path").attr("style",i),L.attr("transform",`translate(0,${-f/2})`),h.attr("transform",`translate(${-u/2+(t.padding??0)-(c.x-(c.left??0))},${-d/2+(t.padding??0)-f-(c.y-(c.top??0))})`),ct(t,L),t.intersect=function(U){return st.polygon(t,_,U)},l}p(jp,"waveEdgedRectangle");async function Up(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.padding??0,a=t.look==="neo"?16:s,o=t.look==="neo"?20:s;if(t.width||t.height){t.width=(t==null?void 0:t.width)??0,t.width<20&&(t.width=20),t.height=(t==null?void 0:t.height)??0,t.height<10&&(t.height=10);const T=Math.min(t.height*.2,t.height/4);t.height=Math.ceil(t.height-o-T*(20/9)),t.width=t.width-a*2}const{shapeSvg:n,bbox:l}=await mt(e,t,xt(t)),c=(t!=null&&t.width?t==null?void 0:t.width:l.width)+a*2,h=(t!=null&&t.height?t==null?void 0:t.height:l.height)+o,u=h/8,d=h+u*2,{cssStyles:f}=t,y=nt.svg(n),m=ot(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const C=[{x:-c/2,y:d/2},...ir(-c/2,d/2,c/2,d/2,u,1),{x:c/2,y:-d/2},...ir(c/2,-d/2,-c/2,-d/2,u,-1)],x=Dt(C),k=y.path(x,m),w=n.insert(()=>k,":first-child");return w.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),ct(t,w),t.intersect=function(T){return st.polygon(t,C,T)},n}p(Up,"waveRectangle");var Yt=10;async function Xp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t.look==="neo"?16:t.padding??0,a=t.look==="neo"?12:t.padding??0;(t.width||t.height)&&(t.width=Math.max(((t==null?void 0:t.width)??0)-s*2-Yt,10),t.height=Math.max(((t==null?void 0:t.height)??0)-a*2-Yt,10));const{shapeSvg:o,bbox:n,label:l}=await mt(e,t,xt(t)),c=(t!=null&&t.width?t==null?void 0:t.width:n.width)+s*2+Yt,h=(t!=null&&t.height?t==null?void 0:t.height:n.height)+a*2+Yt,u=c-Yt,d=h-Yt,f=-u/2,y=-d/2,{cssStyles:m}=t,C=nt.svg(o),x=ot(t,{}),k=[{x:f-Yt,y:y-Yt},{x:f-Yt,y:y+d},{x:f+u,y:y+d},{x:f+u,y:y-Yt}],w=`M${f-Yt},${y-Yt} L${f+u},${y-Yt} L${f+u},${y+d} L${f-Yt},${y+d} L${f-Yt},${y-Yt}
206
+ M${f-Yt},${y} L${f+u},${y}
207
+ M${f},${y-Yt} L${f},${y+d}`;t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");const T=C.path(w,x),_=o.insert(()=>T,":first-child");return _.attr("transform",`translate(${Yt/2}, ${Yt/2})`),_.attr("class","basic label-container outer-path"),m&&t.look!=="handDrawn"&&_.selectAll("path").attr("style",m),i&&t.look!=="handDrawn"&&_.selectAll("path").attr("style",i),l.attr("transform",`translate(${-(n.width/2)+Yt/2-(n.x-(n.left??0))}, ${-(n.height/2)+Yt/2-(n.y-(n.top??0))})`),ct(t,_),t.intersect=function(v){return st.polygon(t,k,v)},o}p(Xp,"windowPane");var lc=new Set(["redux-color","redux-dark-color"]),ow=new Set(["redux","redux-dark","redux-color","redux-dark-color"]);async function ll(e,t){var _t,wt,Et,bt;const r=t;r.alias&&(t.label=r.alias);const{theme:i,themeVariables:s}=Ht(),{rowEven:a,rowOdd:o,nodeBorder:n,borderColorArray:l}=s;if(t.look==="handDrawn"){const{themeVariables:it}=Ht(),{background:ut}=it,Bt={...t,id:t.id+"-background",domId:(t.domId||t.id)+"-background",look:"default",cssStyles:["stroke: none",`fill: ${ut}`]};await ll(e,Bt)}const c=Ht();t.useHtmlLabels=c.htmlLabels;let h=((_t=c.er)==null?void 0:_t.diagramPadding)??10,u=((wt=c.er)==null?void 0:wt.entityPadding)??6;const{cssStyles:d}=t,{labelStyles:f,nodeStyles:y}=dt(t);if(r.attributes.length===0&&t.label){const it={rx:0,ry:0,labelPaddingX:h,labelPaddingY:h*1.5};Ue(t.label,c)+it.labelPaddingX*2<c.er.minEntityWidth&&(t.width=c.er.minEntityWidth);const ut=await ci(e,t,it);if(i!=null&&lc.has(i)){const Bt=r.colorIndex??0;ut.attr("data-color-id",`color-${Bt%l.length}`)}if(!De(c.htmlLabels)){const Bt=ut.select("text"),Mt=(Et=Bt.node())==null?void 0:Et.getBBox();Bt.attr("transform",`translate(${-Mt.width/2}, 0)`)}return ut}c.htmlLabels||(h*=1.25,u*=1.25);let m=xt(t);m||(m="node default");const C=e.insert("g").attr("class",m).attr("id",t.domId||t.id),x=await Or(C,t.label??"",c,0,0,["name"],f);x.height+=u;let k=0;const w=[],T=[];let _=0,v=0,F=0,L=0,U=!0,W=!0;for(const it of r.attributes){const ut=await Or(C,it.type,c,0,k,["attribute-type"],f);_=Math.max(_,ut.width+h);const Bt=await Or(C,it.name,c,0,k,["attribute-name"],f);v=Math.max(v,Bt.width+h);const Mt=await Or(C,it.keys.join(),c,0,k,["attribute-keys"],f);F=Math.max(F,Mt.width+h);const Rt=await Or(C,it.comment,c,0,k,["attribute-comment"],f);L=Math.max(L,Rt.width+h);const R=Math.max(ut.height,Bt.height,Mt.height,Rt.height)+u;T.push({yOffset:k,rowHeight:R}),k+=R}let q=4;F<=h&&(U=!1,F=0,q--),L<=h&&(W=!1,L=0,q--);const rt=C.node().getBBox();if(x.width+h*2-(_+v+F+L)>0){const it=x.width+h*2-(_+v+F+L);_+=it/q,v+=it/q,F>0&&(F+=it/q),L>0&&(L+=it/q)}const Y=_+v+F+L,A=nt.svg(C),E=ot(t,{});t.look!=="handDrawn"&&(E.roughness=0,E.fillStyle="solid");let B=0;T.length>0&&(B=T.reduce((it,ut)=>it+((ut==null?void 0:ut.rowHeight)??0),0));const D=Math.max(rt.width+h*2,(t==null?void 0:t.width)||0,Y),$=Math.max((B??0)+x.height,(t==null?void 0:t.height)||0),N=-D/2,V=-$/2;if(C.selectAll("g:not(:first-child)").each((it,ut,Bt)=>{const Mt=Lt(Bt[ut]),Rt=Mt.attr("transform");let R=0,vt=0;if(Rt){const _e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(Rt);_e&&(R=parseFloat(_e[1]),vt=parseFloat(_e[2]),Mt.attr("class").includes("attribute-name")?R+=_:Mt.attr("class").includes("attribute-keys")?R+=_+v:Mt.attr("class").includes("attribute-comment")&&(R+=_+v+F))}Mt.attr("transform",`translate(${N+h/2+R}, ${vt+V+x.height+u/2})`)}),C.select(".name").attr("transform","translate("+-x.width/2+", "+(V+u/2)+")"),i!=null&&lc.has(i)){const it=r.colorIndex??0;C.attr("data-color-id",`color-${it%l.length}`)}const at=A.rectangle(N,V,D,$,E),ht=C.insert(()=>at,":first-child").attr("class","outer-path").attr("style",d.join(""));w.push(0);for(const[it,ut]of T.entries()){const Mt=(it+1)%2===0&&ut.yOffset!==0,Rt=A.rectangle(N,x.height+V+(ut==null?void 0:ut.yOffset),D,ut==null?void 0:ut.rowHeight,{...E,fill:Mt?a:o,stroke:n});C.insert(()=>Rt,"g.label").attr("style",d.join("")).attr("class",`row-rect-${Mt?"even":"odd"}`)}const pt=1e-4;let yt=Dr(N,x.height+V,D+N,x.height+V,pt),gt=A.polygon(yt.map(it=>[it.x,it.y]),E);if(C.insert(()=>gt).attr("class","divider"),yt=Dr(_+N,x.height+V,_+N,$+V,pt),gt=A.polygon(yt.map(it=>[it.x,it.y]),E),C.insert(()=>gt).attr("class","divider"),U){const it=_+v+N;yt=Dr(it,x.height+V,it,$+V,pt),gt=A.polygon(yt.map(ut=>[ut.x,ut.y]),E),C.insert(()=>gt).attr("class","divider")}if(W){const it=_+v+F+N;yt=Dr(it,x.height+V,it,$+V,pt),gt=A.polygon(yt.map(ut=>[ut.x,ut.y]),E),C.insert(()=>gt).attr("class","divider")}for(const it of w){const ut=x.height+V+it;yt=Dr(N,ut,D+N,ut,pt),gt=A.polygon(yt.map(Bt=>[Bt.x,Bt.y]),E),C.insert(()=>gt).attr("class","divider")}if(ct(t,ht),y&&t.look!=="handDrawn")if(i!=null&&ow.has(i))C.selectAll("path").attr("style",y);else{const it=y.split(";"),ut=(bt=it==null?void 0:it.filter(Bt=>Bt.includes("stroke")))==null?void 0:bt.map(Bt=>`${Bt}`).join("; ");C.selectAll("path").attr("style",ut??""),C.selectAll(".row-rect-even path").attr("style",y)}return t.intersect=function(it){return st.rect(t,it)},C}p(ll,"erBox");async function Or(e,t,r,i=0,s=0,a=[],o=""){const n=e.insert("g").attr("class",`label ${a.join(" ")}`).attr("transform",`translate(${i}, ${s})`).attr("style",o);t!==Kl(t)&&(t=Kl(t),t=t.replaceAll("<","&lt;").replaceAll(">","&gt;"));const l=n.node().appendChild(await Te(n,t,{width:Ue(t,r)+100,style:o,useHtmlLabels:r.htmlLabels},r));if(t.includes("&lt;")||t.includes("&gt;")){let h=l.children[0];for(h.textContent=h.textContent.replaceAll("&lt;","<").replaceAll("&gt;",">");h.childNodes[0];)h=h.childNodes[0],h.textContent=h.textContent.replaceAll("&lt;","<").replaceAll("&gt;",">")}let c=l.getBBox();if(De(r.htmlLabels)){const h=l.children[0];h.style.textAlign="start";const u=Lt(l);c=h.getBoundingClientRect(),u.attr("width",c.width),u.attr("height",c.height)}return c}p(Or,"addText");function Dr(e,t,r,i,s){return e===r?[{x:e-s/2,y:t},{x:e+s/2,y:t},{x:r+s/2,y:i},{x:r-s/2,y:i}]:[{x:e,y:t-s/2},{x:e,y:t+s/2},{x:r,y:i+s/2},{x:r,y:i-s/2}]}p(Dr,"lineToPolygon");async function Gp(e,t,r,i,s=r.class.padding??12){const a=i?0:3,o=e.insert("g").attr("class",xt(t)).attr("id",t.domId||t.id);let n=null,l=null,c=null,h=null,u=0,d=0,f=0;if(n=o.insert("g").attr("class","annotation-group text"),t.annotations.length>0){const k=t.annotations[0];await Oi(n,{text:`«${k}»`},0),u=n.node().getBBox().height}l=o.insert("g").attr("class","label-group text"),await Oi(l,t,0,["font-weight: bolder"]);const y=l.node().getBBox();d=y.height,c=o.insert("g").attr("class","members-group text");let m=0;for(const k of t.members){const w=await Oi(c,k,m,[k.parseClassifier()]);m+=w+a}f=c.node().getBBox().height,f<=0&&(f=s/2),h=o.insert("g").attr("class","methods-group text");let C=0;for(const k of t.methods){const w=await Oi(h,k,C,[k.parseClassifier()]);C+=w+a}let x=o.node().getBBox();if(n!==null){const k=n.node().getBBox();n.attr("transform",`translate(${-k.width/2})`)}return l.attr("transform",`translate(${-y.width/2}, ${u})`),x=o.node().getBBox(),c.attr("transform",`translate(0, ${u+d+s*2})`),x=o.node().getBBox(),h.attr("transform",`translate(0, ${u+d+(f?f+s*4:s*2)})`),x=o.node().getBBox(),{shapeSvg:o,bbox:x}}p(Gp,"textHelper");async function Oi(e,t,r,i=[]){const s=e.insert("g").attr("class","label").attr("style",i.join("; ")),a=Ht();let o="useHtmlLabels"in t?t.useHtmlLabels:De(a.htmlLabels)??!0,n="";"text"in t?n=t.text:n=t.label,!o&&n.startsWith("\\")&&(n=n.substring(1)),Ui(n)&&(o=!0);const l=await Te(s,vn(er(n)),{width:Ue(n,a)+50,classes:"markdown-node-label",useHtmlLabels:o},a);let c,h=1;if(o){const u=l.children[0],d=Lt(l);h=u.innerHTML.split("<br>").length,u.innerHTML.includes("</math>")&&(h+=u.innerHTML.split("<mrow>").length-1),await sl(u),c=u.getBoundingClientRect(),d.attr("width",c.width),d.attr("height",c.height)}else{i.includes("font-weight: bolder")&&Lt(l).selectAll("tspan").attr("font-weight",""),h=l.children.length;const u=l.children[0];(l.textContent===""||l.textContent.includes("&gt"))&&(u.textContent=n[0]+n.substring(1).replaceAll("&gt;",">").replaceAll("&lt;","<").trim(),n[1]===" "&&(u.textContent=u.textContent[0]+" "+u.textContent.substring(1))),u.textContent==="undefined"&&(u.textContent=""),c=l.getBBox()}return s.attr("transform","translate(0,"+(-c.height/(2*h)+r)+")"),c.height}p(Oi,"addText");async function Vp(e,t){var A,E;const r=At(),{themeVariables:i}=r,{useGradient:s}=i,a=r.class.padding??12,o=a,n=t.useHtmlLabels??De(r.htmlLabels)??!0,l=t;l.annotations=l.annotations??[],l.members=l.members??[],l.methods=l.methods??[];const{shapeSvg:c,bbox:h}=await Gp(e,t,r,n,o),{labelStyles:u,nodeStyles:d}=dt(t);t.labelStyle=u,t.cssStyles=l.styles||"";const f=((A=l.styles)==null?void 0:A.join(";"))||d||"";t.cssStyles||(t.cssStyles=f.replaceAll("!important","").split(";"));const y=l.members.length===0&&l.methods.length===0&&!((E=r.class)!=null&&E.hideEmptyMembersBox),m=nt.svg(c),C=ot(t,{});t.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");const x=Math.max(t.width??0,h.width);let k=Math.max(t.height??0,h.height);const w=(t.height??0)>h.height;l.members.length===0&&l.methods.length===0?k+=o:l.members.length>0&&l.methods.length===0&&(k+=o*2);const T=-x/2,_=-k/2;let v=y?a*2:l.members.length===0&&l.methods.length===0?-a:0;w&&(v=a*2);const F=m.rectangle(T-a,_-a-(y?a:l.members.length===0&&l.methods.length===0?-a/2:0),x+2*a,k+2*a+v,C),L=c.insert(()=>F,":first-child");L.attr("class","basic label-container outer-path");const U=L.node().getBBox(),W=c.select(".annotation-group").node().getBBox().height-(y?a/2:0)||0,q=c.select(".label-group").node().getBBox().height-(y?a/2:0)||0,rt=c.select(".members-group").node().getBBox().height-(y?a/2:0)||0,Y=(W+q+_+a-(_-a-(y?a:l.members.length===0&&l.methods.length===0?-a/2:0)))/2;if(c.selectAll(".text").each((B,D,$)=>{var yt,gt;const N=Lt($[D]),V=N.attr("transform");let at=0;if(V){const wt=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(V);wt&&(at=parseFloat(wt[2]))}let ht=at+_+a-(y?a:l.members.length===0&&l.methods.length===0?-a/2:0);if(N.attr("class").includes("methods-group")){const _t=Math.max(rt,o/2);w?ht=Math.max(Y,W+q+_t+_+o*2+a)+o*2:ht=W+q+_t+_+o*4+a}l.members.length===0&&l.methods.length===0&&((yt=r.class)!=null&&yt.hideEmptyMembersBox)&&(l.annotations.length>0?ht=at-o:ht=at),n||(ht-=4);let pt=T;(N.attr("class").includes("label-group")||N.attr("class").includes("annotation-group"))&&(pt=-((gt=N.node())==null?void 0:gt.getBBox().width)/2||0,c.selectAll("text").each(function(_t,wt,Et){window.getComputedStyle(Et[wt]).textAnchor==="middle"&&(pt=0)})),N.attr("transform",`translate(${pt}, ${ht})`)}),l.members.length>0||l.methods.length>0||y){const B=W+q+_+a,D=m.line(U.x,B,U.x+U.width,B+.001,C);c.insert(()=>D).attr("class",`divider${t.look==="neo"&&!s?" neo-line":""}`).attr("style",f)}if(y||l.members.length>0||l.methods.length>0){const B=W+q+rt+_+o*2+a,D=m.line(U.x,w?Math.max(Y,B):B,U.x+U.width,(w?Math.max(Y,B):B)+.001,C);c.insert(()=>D).attr("class",`divider${t.look==="neo"&&!s?" neo-line":""}`).attr("style",f)}if(l.look!=="handDrawn"&&c.selectAll("path").attr("style",f),L.select(":nth-child(2)").attr("style",f),c.selectAll(".divider").select("path").attr("style",f),t.labelStyle?c.selectAll("span").attr("style",t.labelStyle):c.selectAll("span").attr("style",f),!n){const B=RegExp(/color\s*:\s*([^;]*)/),D=B.exec(f);if(D){const $=D[0].replace("color","fill");c.selectAll("tspan").attr("style",$)}else if(u){const $=B.exec(u);if($){const N=$[0].replace("color","fill");c.selectAll("tspan").attr("style",N)}}}return ct(t,L),t.intersect=function(B){return st.rect(t,B)},c}p(Vp,"classBox");async function Zp(e,t){var q,rt;const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const s=t,a=t,o=20,n=20,l="verifyMethod"in t,c=xt(t),h=At(),{themeVariables:u}=h,{borderColorArray:d,requirementEdgeLabelBackground:f}=u,y=h.layout==="elk"?"start":"center",m=e.insert("g").attr("class",c).attr("id",t.domId??t.id);let C;l?C=await ve(m,`&lt;&lt;${s.type}&gt;&gt;`,0,t.labelStyle):C=await ve(m,"&lt;&lt;Element&gt;&gt;",0,t.labelStyle);let x=C;const k=await ve(m,s.name,x,t.labelStyle+"; font-weight: bold;");if(x+=k+n,l){const Y=await ve(m,`${s.requirementId?`ID: ${s.requirementId}`:""}`,x,t.labelStyle,y);x+=Y;const A=await ve(m,`${s.text?`Text: ${s.text}`:""}`,x,t.labelStyle,y);x+=A;const E=await ve(m,`${s.risk?`Risk: ${s.risk}`:""}`,x,t.labelStyle,y);x+=E,await ve(m,`${s.verifyMethod?`Verification: ${s.verifyMethod}`:""}`,x,t.labelStyle,y)}else{const Y=await ve(m,`${a.type?`Type: ${a.type}`:""}`,x,t.labelStyle,y);x+=Y,await ve(m,`${a.docRef?`Doc Ref: ${a.docRef}`:""}`,x,t.labelStyle,y)}const w=(((q=m.node())==null?void 0:q.getBBox().width)??200)+o,T=(((rt=m.node())==null?void 0:rt.getBBox().height)??200)+o,_=-w/2,v=-T/2,F=nt.svg(m),L=ot(t,{});t.look!=="handDrawn"&&(L.roughness=0,L.fillStyle="solid");const U=F.rectangle(_,v,w,T,L),W=m.insert(()=>U,":first-child");if(W.attr("class","basic label-container outer-path").attr("style",i),d!=null&&d.length){const Y=t.colorIndex??0;m.attr("data-color-id",`color-${Y%d.length}`)}if(m.selectAll(".label").each((Y,A,E)=>{const B=Lt(E[A]),D=B.attr("transform");let $=0,N=0;if(D){const pt=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(D);pt&&($=parseFloat(pt[1]),N=parseFloat(pt[2]))}const V=N-T/2;let at=_+o/2;(A===0||A===1)&&(at=$),B.attr("transform",`translate(${at}, ${V+o})`)}),x>C+k+n){const Y=v+C+k+n;let A;if(t.look==="neo"){const D=[[_,Y],[_+w,Y],[_+w,Y+.001],[_,Y+.001]];A=F.polygon(D,L)}else A=F.line(_,Y,_+w,Y,L);m.insert(()=>A).attr("class","divider")}return ct(t,W),t.intersect=function(Y){return st.rect(t,Y)},i&&t.look!=="handDrawn"&&(f||d!=null&&d.length)&&m.selectAll("path").attr("style",i),m}p(Zp,"requirementBox");async function ve(e,t,r,i="",s="center"){if(t==="")return 0;const a=e.insert("g").attr("class","label").attr("style",i),o=At(),n=o.htmlLabels??!0,l=await Te(a,vn(er(t)),{width:Ue(t,o)+50,classes:"markdown-node-label",useHtmlLabels:n,style:i},o);let c;if(n){const h=l.children[0],u=Lt(l);s==="start"&&Lt(h).style("text-align","left"),c=h.getBoundingClientRect(),u.attr("width",c.width),u.attr("height",c.height)}else{const h=l.children[0];for(const u of h.children)i&&u.setAttribute("style",i);if(s==="start"){h.setAttribute("text-anchor","start");for(const u of h.children)u.setAttribute("text-anchor","start")}c=l.getBBox(),c.height+=6}return a.attr("transform",`translate(${-c.width/2},${-c.height/2+r})`),c.height}p(ve,"addText");var nw=p(e=>{switch(e){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function Kp(e,t,{config:r}){var rt,Y;const{labelStyles:i,nodeStyles:s}=dt(t);t.labelStyle=i||"";const a=10,o=t.width;t.width=(t.width??200)-10;const{shapeSvg:n,bbox:l,label:c}=await mt(e,t,xt(t)),h=t.padding||10;let u="",d;"ticket"in t&&t.ticket&&((rt=r==null?void 0:r.kanban)!=null&&rt.ticketBaseUrl)&&(u=(Y=r==null?void 0:r.kanban)==null?void 0:Y.ticketBaseUrl.replace("#TICKET#",t.ticket),d=n.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",u).attr("target","_blank"));const f={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||"",width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1};let y,m;d?{label:y,bbox:m}=await Ga(d,"ticket"in t&&t.ticket||"",f):{label:y,bbox:m}=await Ga(n,"ticket"in t&&t.ticket||"",f);const{label:C,bbox:x}=await Ga(n,"assigned"in t&&t.assigned||"",f);t.width=o;const k=10,w=(t==null?void 0:t.width)||0,T=Math.max(m.height,x.height)/2,_=Math.max(l.height+k*2,(t==null?void 0:t.height)||0)+T,v=-w/2,F=-_/2;c.attr("transform","translate("+(h-w/2)+", "+(-T-l.height/2)+")"),y.attr("transform","translate("+(h-w/2)+", "+(-T+l.height/2)+")"),C.attr("transform","translate("+(h+w/2-x.width-2*a)+", "+(-T+l.height/2)+")");let L;const{rx:U,ry:W}=t,{cssStyles:q}=t;if(t.look==="handDrawn"){const A=nt.svg(n),E=ot(t,{}),B=U||W?A.path(pe(v,F,w,_,U||0),E):A.rectangle(v,F,w,_,E);L=n.insert(()=>B,":first-child"),L.attr("class","basic label-container").attr("style",q||null)}else{L=n.insert("rect",":first-child"),L.attr("class","basic label-container __APA__").attr("style",s).attr("rx",U??5).attr("ry",W??5).attr("x",v).attr("y",F).attr("width",w).attr("height",_);const A="priority"in t&&t.priority;if(A){const E=n.append("line"),B=v+2,D=F+Math.floor((U??0)/2),$=F+_-Math.floor((U??0)/2);E.attr("x1",B).attr("y1",D).attr("x2",B).attr("y2",$).attr("stroke-width","4").attr("stroke",nw(A))}}return ct(t,L),t.height=_,t.intersect=function(A){return st.rect(t,A)},n}p(Kp,"kanbanItem");async function Qp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,halfPadding:o,label:n}=await mt(e,t,xt(t)),l=a.width+10*o,c=a.height+8*o,h=.15*l,{cssStyles:u}=t,d=a.width+20,f=a.height+20,y=Math.max(l,d),m=Math.max(c,f);n.attr("transform",`translate(${-a.width/2}, ${-a.height/2})`);let C;const x=`M0 0
208
+ a${h},${h} 1 0,0 ${y*.25},${-1*m*.1}
209
+ a${h},${h} 1 0,0 ${y*.25},0
210
+ a${h},${h} 1 0,0 ${y*.25},0
211
+ a${h},${h} 1 0,0 ${y*.25},${m*.1}
212
+
213
+ a${h},${h} 1 0,0 ${y*.15},${m*.33}
214
+ a${h*.8},${h*.8} 1 0,0 0,${m*.34}
215
+ a${h},${h} 1 0,0 ${-1*y*.15},${m*.33}
216
+
217
+ a${h},${h} 1 0,0 ${-1*y*.25},${m*.15}
218
+ a${h},${h} 1 0,0 ${-1*y*.25},0
219
+ a${h},${h} 1 0,0 ${-1*y*.25},0
220
+ a${h},${h} 1 0,0 ${-1*y*.25},${-1*m*.15}
221
+
222
+ a${h},${h} 1 0,0 ${-1*y*.1},${-1*m*.33}
223
+ a${h*.8},${h*.8} 1 0,0 0,${-1*m*.34}
224
+ a${h},${h} 1 0,0 ${y*.1},${-1*m*.33}
225
+ H0 V0 Z`;if(t.look==="handDrawn"){const k=nt.svg(s),w=ot(t,{}),T=k.path(x,w);C=s.insert(()=>T,":first-child"),C.attr("class","basic label-container").attr("style",Xt(u))}else C=s.insert("path",":first-child").attr("class","basic label-container").attr("style",i).attr("d",x);return C.attr("transform",`translate(${-y/2}, ${-m/2})`),ct(t,C),t.calcIntersect=function(k,w){return st.rect(k,w)},t.intersect=function(k){return I.info("Bang intersect",t,k),st.rect(t,k)},s}p(Qp,"bang");async function Jp(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,halfPadding:o,label:n}=await mt(e,t,xt(t)),l=a.width+2*o,c=a.height+2*o,h=.15*l,u=.25*l,d=.35*l,f=.2*l,{cssStyles:y}=t;let m;const C=`M0 0
226
+ a${h},${h} 0 0,1 ${l*.25},${-1*l*.1}
227
+ a${d},${d} 1 0,1 ${l*.4},${-1*l*.1}
228
+ a${u},${u} 1 0,1 ${l*.35},${l*.2}
229
+
230
+ a${h},${h} 1 0,1 ${l*.15},${c*.35}
231
+ a${f},${f} 1 0,1 ${-1*l*.15},${c*.65}
232
+
233
+ a${u},${h} 1 0,1 ${-1*l*.25},${l*.15}
234
+ a${d},${d} 1 0,1 ${-1*l*.5},0
235
+ a${h},${h} 1 0,1 ${-1*l*.25},${-1*l*.15}
236
+
237
+ a${h},${h} 1 0,1 ${-1*l*.1},${-1*c*.35}
238
+ a${f},${f} 1 0,1 ${l*.1},${-1*c*.65}
239
+ H0 V0 Z`;if(t.look==="handDrawn"){const x=nt.svg(s),k=ot(t,{}),w=x.path(C,k);m=s.insert(()=>w,":first-child"),m.attr("class","basic label-container").attr("style",Xt(y))}else m=s.insert("path",":first-child").attr("class","basic label-container").attr("style",i).attr("d",C);return n.attr("transform",`translate(${-a.width/2}, ${-a.height/2})`),m.attr("transform",`translate(${-l/2}, ${-c/2})`),ct(t,m),t.calcIntersect=function(x,k){return st.rect(x,k)},t.intersect=function(x){return I.info("Cloud intersect",t,x),st.rect(t,x)},s}p(Jp,"cloud");async function tg(e,t){const{labelStyles:r,nodeStyles:i}=dt(t);t.labelStyle=r;const{shapeSvg:s,bbox:a,halfPadding:o,label:n}=await mt(e,t,xt(t)),l=a.width+8*o,c=a.height+2*o,h=5,u=t.look==="neo"?`
240
+ M${-l/2} ${c/2-h}
241
+ v${-c+2*h}
242
+ q0,-${h} ${h},-${h}
243
+ h${l-2*h}
244
+ q${h},0 ${h},${h}
245
+ v${c-h}
246
+ H${-l/2}
247
+ Z
248
+ `:`
249
+ M${-l/2} ${c/2-h}
250
+ v${-c+2*h}
251
+ q0,-${h} ${h},-${h}
252
+ h${l-2*h}
253
+ q${h},0 ${h},${h}
254
+ v${c-2*h}
255
+ q0,${h} ${-h},${h}
256
+ h${-(l-2*h)}
257
+ q${-h},0 ${-h},${-h}
258
+ Z
259
+ `;if(!t.domId)throw new Error(`defaultMindmapNode: node "${t.id}" is missing a domId — was render.ts domId prefixing skipped?`);const d=s.append("path").attr("id",t.domId).attr("class","node-bkg node-"+t.type).attr("style",i).attr("d",u);return s.append("line").attr("class","node-line-").attr("x1",-l/2).attr("y1",c/2).attr("x2",l/2).attr("y2",c/2),n.attr("transform",`translate(${-a.width/2}, ${-a.height/2})`),s.append(()=>n.node()),ct(t,d),t.calcIntersect=function(f,y){return st.rect(f,y)},t.intersect=function(f){return st.rect(t,f)},s}p(tg,"defaultMindmapNode");async function eg(e,t){const r={padding:t.padding??0};return nl(e,t,r)}p(eg,"mindmapCircle");var lw=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:Ep},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:Fp},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:$p},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:Ip},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:tp},{semanticName:"Data Store",name:"Data Store",shortName:"datastore",description:"Data flow diagram data store",aliases:["data-store"],handler:ep},{semanticName:"Folder",name:"Folder",shortName:"folder",description:"Folder or directory",aliases:["directory"],handler:op},{semanticName:"Bucket",name:"Bucket",shortName:"bucket",description:"Object storage bucket",handler:qf},{semanticName:"Console",name:"Console (terminal window)",shortName:"console",description:"Terminal or console window",handler:Uf},{semanticName:"Browser",name:"Browser",shortName:"browser",description:"Browser window",handler:zf},{semanticName:"Person",name:"Person",shortName:"person",description:"Person (circular head above a rounded body)",handler:Jf},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:nl},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:Qp},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:Jp},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:Bp},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:hp},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:Cp},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:xp},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:zp},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:yp},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:ip},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:Np},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:Hf},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:Mp},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:Pp},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:Dp},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:np},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:cp},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:Vf},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:Zf},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:Kf},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:bp},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:jp},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:lp},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:Wp},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:kp},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:Qf},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:rp},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:Yp},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:Xp},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:sp},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:Hp},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:ap},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:Ap},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:Tp},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:Sp},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:Rf},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:Gf},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:qp},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:Rp},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:Up},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:vp},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:wp}],hw=p(()=>{const t=[...Object.entries({state:Op,choice:Yf,note:_p,composite:jf,rectWithTitle:Lp,labelRect:mp,block_arrow:Wf,collapsedGroup:Nf,iconSquare:pp,iconCircle:dp,icon:up,iconRounded:fp,imageSquare:gp,anchor:Pf,kanbanItem:Kp,mindmapCircle:eg,defaultMindmapNode:tg,classBox:Vp,erBox:ll,requirementBox:Zp}),...lw.flatMap(r=>[r.shortName,..."aliases"in r?r.aliases:[],..."internalAliases"in r?r.internalAliases:[]].map(s=>[s,r.handler]))];return Object.fromEntries(t)},"generateShapeMap"),rg=hw();function cw(e){return e in rg}p(cw,"isValidShape");var Sa=p(({flowchart:e})=>{var s,a;const t=((s=e==null?void 0:e.subGraphTitleMargin)==null?void 0:s.top)??0,r=((a=e==null?void 0:e.subGraphTitleMargin)==null?void 0:a.bottom)??0,i=t+r;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:r,subGraphTitleTotalMargin:i}},"getSubGraphTitleMargins"),Ta=new Map;async function hl(e,t,r){let i,s;t.shape==="rect"&&(t.rx&&t.ry?t.shape="roundedRect":t.shape="squareRect");const a=t.shape?rg[t.shape]:void 0;if(!a)throw new Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let o;r.config.securityLevel==="sandbox"?o="_top":t.linkTarget&&(o=t.linkTarget||"_blank"),i=e.insert("svg:a").attr("xlink:href",t.link).attr("target",o??null),s=await a(i,t,r)}else s=await a(e,t,r),i=s;return i.attr("data-look",Xt(t.look)),t.tooltip&&s.attr("title",t.tooltip),Ta.set(t.id,i),t.haveCallback&&i.attr("class",i.attr("class")+" clickable"),i}p(hl,"insertNode");var cA=p((e,t)=>{Ta.set(t.id,e)},"setNodeElem"),uw=p(()=>{Ta.clear()},"clear"),hc=p(e=>{const t=Ta.get(e.id);I.trace("Transforming node",e.diff,e,"translate("+(e.x-e.width/2-5)+", "+e.width/2+")");const r=8,i=e.diff||0;return e.clusterNode?t.attr("transform","translate("+(e.x+i-e.width/2)+", "+(e.y-e.height/2-r)+")"):t.attr("transform","translate("+e.x+", "+e.y+")"),i},"positionNode"),dw=p(async(e,t)=>{const r=At(),{themeVariables:i,handDrawnSeed:s}=r,{clusterBkg:a,clusterBorder:o}=i,n=o,{labelStyles:l,nodeStyles:c,borderStyles:h,backgroundStyles:u}=dt(t),d=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),f=De(r.flowchart.htmlLabels),y=t.direction==="LR",m=d.insert("g").attr("class","cluster-label swimlane-label"),C=await Te(m,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width});let x=C.getBBox();if(f){const Y=C.children[0],A=Lt(C);x=Y.getBoundingClientRect(),A.attr("width",x.width),A.attr("height",x.height)}const k=t.padding??0,w=t.width<=x.width+k?x.width+k:t.width;t.width<=x.width+k?t.diff=(w-t.width)/2-k:t.diff=-k;const T=t.height,_=t.y-T/2,v=t.y+T/2,F=t.x-w/2,L=t.swimlaneContentTop!==void 0?t.swimlaneContentTop:_+T/3,U=y?4:0,W=x.height+2*U;let q,rt;if(y){const Y=Math.max(W,x.height+2*U),A=F+Y,E=Math.max(0,w-Y);if(t.look==="handDrawn"){const $=nt.svg(d),N=ot(t,{roughness:.7,fill:a,stroke:n,fillWeight:3,seed:s}),V=ot(t,{roughness:.7,fill:"none",stroke:n,seed:s}),at=$.rectangle(F,_,Y,T,N);q=d.insert(()=>at,":first-child");const ht=$.rectangle(A,_,E,T,V);rt=d.insert(()=>ht,":first-child"),q.select("path:nth-child(2)").attr("style",h.join(";")),q.select("path").attr("style",u.join(";").replace("fill","stroke"))}else q=d.insert("rect",":first-child"),rt=d.insert("rect",":first-child"),q.attr("class","swimlane-title").attr("style",c).attr("x",F).attr("y",_).attr("width",Y).attr("height",T).attr("fill",a).attr("stroke",n),rt.attr("class","swimlane-body").attr("style",c).attr("x",A).attr("y",_).attr("width",E).attr("height",T).attr("fill","none").attr("stroke",n);const B=F+Y/2,D=t.y;m.attr("transform",`translate(${B}, ${D}) rotate(-90) translate(${-x.width/2}, ${-x.height/2})`)}else{const Y=Math.max(0,L-_),A=Math.min(W,Y),E=_+A,B=Math.max(0,v-E),D=t.x-w/2;if(t.look==="handDrawn"){const V=nt.svg(d),at=ot(t,{roughness:.7,fill:a,stroke:n,fillWeight:3,seed:s}),ht=ot(t,{roughness:.7,fill:"none",stroke:n,seed:s}),pt=V.rectangle(D,_,w,A,at);q=d.insert(()=>pt,":first-child");const yt=V.rectangle(D,E,w,B,ht);rt=d.insert(()=>yt,":first-child"),q.select("path:nth-child(2)").attr("style",h.join(";")),q.select("path").attr("style",u.join(";").replace("fill","stroke"))}else q=d.insert("rect",":first-child"),rt=d.insert("rect",":first-child"),q.attr("class","swimlane-title").attr("style",c).attr("x",D).attr("y",_).attr("width",w).attr("height",A).attr("fill",a).attr("stroke",n),rt.attr("class","swimlane-body").attr("style",c).attr("x",D).attr("y",E).attr("width",w).attr("height",B).attr("fill","none").attr("stroke",n);const $=t.x-x.width/2,N=_+(A-x.height)/2;m.attr("transform",`translate(${$}, ${N})`)}if(I.trace("Swimlane data ",t,JSON.stringify(t)),l){const Y=m.select("span");Y&&Y.attr("style",l)}return t.offsetX=0,t.width=w,t.height=T,t.offsetY=x.height-k/2,t.intersect=function(Y){return Sr(t,Y)},{cluster:d,labelBBox:x}},"swimlane"),ig=p(async(e,t)=>{I.info("Creating subgraph rect for ",t.id,t);const r=At(),{themeVariables:i,handDrawnSeed:s}=r,{clusterBkg:a,clusterBorder:o}=i,{labelStyles:n,nodeStyles:l,borderStyles:c,backgroundStyles:h}=dt(t),u=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.domId).attr("data-look",t.look),d=ee(r),f=u.insert("g").attr("class","cluster-label ");let y;t.labelType==="markdown"?y=await Te(f,t.label,{style:t.labelStyle,useHtmlLabels:d,isNode:!0,width:t.width}):y=await Qe(f,t.label,t.labelStyle||"",!1,!0);let m=y.getBBox();if(ee(r)){const F=y.children[0],L=Lt(y);m=F.getBoundingClientRect(),L.attr("width",m.width),L.attr("height",m.height)}const C=t.width<=m.width+t.padding?m.width+t.padding:t.width;t.width<=m.width+t.padding?t.diff=(C-t.width)/2-t.padding:t.diff=-t.padding;const x=t.height,k=t.x-C/2,w=t.y-x/2;I.trace("Data ",t,JSON.stringify(t));let T;if(t.look==="handDrawn"){const F=nt.svg(u),L=ot(t,{roughness:.7,fill:a,stroke:o,fillWeight:3,seed:s}),U=F.path(pe(k,w,C,x,0),L);T=u.insert(()=>(I.debug("Rough node insert CXC",U),U),":first-child"),T.select("path:nth-child(2)").attr("style",c.join(";")),T.select("path").attr("style",h.join(";").replace("fill","stroke"))}else T=u.insert("rect",":first-child"),T.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",k).attr("y",w).attr("width",C).attr("height",x);const{subGraphTitleTopMargin:_}=Sa(r);if(f.attr("transform",`translate(${t.x-m.width/2}, ${t.y-t.height/2+_})`),n){const F=f.select("span");F&&F.attr("style",n)}const v=T.node().getBBox();return t.offsetX=0,t.width=v.width,t.height=v.height,t.offsetY=m.height-t.padding/2,t.intersect=function(F){return Sr(t,F)},{cluster:u,labelBBox:m}},"rect"),fw=p((e,t)=>{const r=e.insert("g").attr("class","note-cluster").attr("id",t.domId),i=r.insert("rect",":first-child"),s=0*t.padding,a=s/2;i.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+s).attr("height",t.height+s).attr("fill","none");const o=i.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(n){return Sr(t,n)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),pw=p(async(e,t)=>{const r=At(),{themeVariables:i,handDrawnSeed:s}=r,{altBackground:a,compositeBackground:o,compositeTitleBackground:n,nodeBorder:l}=i,c=e.insert("g").attr("class",t.cssClasses).attr("id",t.domId).attr("data-id",t.id).attr("data-look",t.look),h=c.insert("g",":first-child"),u=c.insert("g").attr("class","cluster-label");let d=c.append("rect");const f=await Qe(u,t.label,t.labelStyle,void 0,!0);let y=f.getBBox();if(ee(r)){const U=f.children[0],W=Lt(f);y=U.getBoundingClientRect(),W.attr("width",y.width),W.attr("height",y.height)}const m=0*t.padding,C=m/2,x=(t.width<=y.width+t.padding?y.width+t.padding:t.width)+m;t.width<=y.width+t.padding?t.diff=(x-t.width)/2-t.padding:t.diff=-t.padding;const k=t.height+m,w=t.height+m-y.height-6,T=t.x-x/2,_=t.y-k/2;t.width=x;const v=t.y-t.height/2-C+y.height+2;let F;if(t.look==="handDrawn"){const U=t.cssClasses.includes("statediagram-cluster-alt"),W=nt.svg(c),q=t.rx||t.ry?W.path(pe(T,_,x,k,10),{roughness:.7,fill:n,fillStyle:"solid",stroke:l,seed:s}):W.rectangle(T,_,x,k,{seed:s});F=c.insert(()=>q,":first-child");const rt=W.rectangle(T,v,x,w,{fill:U?a:o,fillStyle:U?"hachure":"solid",stroke:l,seed:s});F=c.insert(()=>q,":first-child"),d=c.insert(()=>rt)}else F=h.insert("rect",":first-child"),F.attr("class","outer").attr("x",T).attr("y",_).attr("width",x).attr("height",k).attr("data-look",t.look),d.attr("class","inner").attr("x",T).attr("y",v).attr("width",x).attr("height",w);u.attr("transform",`translate(${t.x-y.width/2}, ${_+1-(ee(r)?0:3)})`);const L=F.node().getBBox();return t.height=L.height,t.offsetX=0,t.offsetY=y.height-t.padding/2,t.labelBBox=y,t.intersect=function(U){return Sr(t,U)},{cluster:c,labelBBox:y}},"roundedWithTitle"),gw=p(async(e,t)=>{I.info("Creating subgraph rect for ",t.id,t);const r=At(),{themeVariables:i,handDrawnSeed:s}=r,{clusterBkg:a,clusterBorder:o}=i,{labelStyles:n,nodeStyles:l,borderStyles:c,backgroundStyles:h}=dt(t),u=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.domId).attr("data-look",t.look),d=ee(r),f=u.insert("g").attr("class","cluster-label "),y=await Te(f,t.label,{style:t.labelStyle,useHtmlLabels:d,isNode:!0,width:t.width});let m=y.getBBox();if(ee(r)){const F=y.children[0],L=Lt(y);m=F.getBoundingClientRect(),L.attr("width",m.width),L.attr("height",m.height)}const C=t.width<=m.width+t.padding?m.width+t.padding:t.width;t.width<=m.width+t.padding?t.diff=(C-t.width)/2-t.padding:t.diff=-t.padding;const x=t.height,k=t.x-C/2,w=t.y-x/2;I.trace("Data ",t,JSON.stringify(t));let T;if(t.look==="handDrawn"){const F=nt.svg(u),L=ot(t,{roughness:.7,fill:a,stroke:o,fillWeight:4,seed:s}),U=F.path(pe(k,w,C,x,t.rx),L);T=u.insert(()=>(I.debug("Rough node insert CXC",U),U),":first-child"),T.select("path:nth-child(2)").attr("style",c.join(";")),T.select("path").attr("style",h.join(";").replace("fill","stroke"))}else T=u.insert("rect",":first-child"),T.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",k).attr("y",w).attr("width",C).attr("height",x);const{subGraphTitleTopMargin:_}=Sa(r);if(f.attr("transform",`translate(${t.x-m.width/2}, ${t.y-t.height/2+_})`),n){const F=f.select("span");F&&F.attr("style",n)}const v=T.node().getBBox();return t.offsetX=0,t.width=v.width,t.height=v.height,t.offsetY=m.height-t.padding/2,t.intersect=function(F){return Sr(t,F)},{cluster:u,labelBBox:m}},"kanbanSection"),yw=p((e,t)=>{const r=At(),{themeVariables:i,handDrawnSeed:s}=r,{nodeBorder:a}=i,o=e.insert("g").attr("class",t.cssClasses).attr("id",t.domId).attr("data-look",t.look),n=o.insert("g",":first-child"),l=0*t.padding,c=t.width+l;t.diff=-t.padding;const h=t.height+l,u=t.x-c/2,d=t.y-h/2;t.width=c;let f;if(t.look==="handDrawn"){const C=nt.svg(o).rectangle(u,d,c,h,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:a,seed:s});f=o.insert(()=>C,":first-child")}else{f=n.insert("rect",":first-child");let m="outer";t.look,m="divider",f.attr("class",m).attr("x",u).attr("y",d).attr("width",c).attr("height",h).attr("data-look",t.look)}const y=f.node().getBBox();return t.height=y.height,t.offsetX=0,t.offsetY=0,t.intersect=function(m){return Sr(t,m)},{cluster:o,labelBBox:{}}},"divider"),mw=ig,xw={rect:ig,squareRect:mw,roundedWithTitle:pw,noteGroup:fw,divider:yw,kanbanSection:gw,swimlane:dw},sg=new Map,ag=p(async(e,t)=>{const r=t.shape||"rect",i=await xw[r](e,t);return sg.set(t.id,i),i},"insertCluster"),Cw=p(()=>{sg=new Map},"clear"),Bi=p((e,t)=>{if(t)return"translate("+-e.width/2+", "+-e.height/2+")";const r=e.x??0,i=e.y??0;return"translate("+-(r+e.width/2)+", "+-(i+e.height/2)+")"},"computeLabelTransform"),Jt={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4,arrow_barb:0,arrow_barb_neo:5.5},cc={arrow_point:4,arrow_cross:12.5,arrow_circle:12.5};function Di(e,t){if(e===void 0||t===void 0)return{angle:0,deltaX:0,deltaY:0};e=zt(e),t=zt(t);const[r,i]=[e.x,e.y],[s,a]=[t.x,t.y],o=s-r,n=a-i;return{angle:Math.atan(n/o),deltaX:o,deltaY:n}}p(Di,"calculateDeltaAndAngle");var zt=p(e=>Array.isArray(e)?{x:e[0],y:e[1]}:e,"pointTransformer"),bw=p(e=>({x:p(function(t,r,i){let s=0;const a=zt(i[0]).x<zt(i[i.length-1]).x?"left":"right";if(r===0&&Object.hasOwn(Jt,e.arrowTypeStart)){const{angle:f,deltaX:y}=Di(i[0],i[1]);s=Jt[e.arrowTypeStart]*Math.cos(f)*(y>=0?1:-1)}else if(r===i.length-1&&Object.hasOwn(Jt,e.arrowTypeEnd)){const{angle:f,deltaX:y}=Di(i[i.length-1],i[i.length-2]);s=Jt[e.arrowTypeEnd]*Math.cos(f)*(y>=0?1:-1)}const o=Math.abs(zt(t).x-zt(i[i.length-1]).x),n=Math.abs(zt(t).y-zt(i[i.length-1]).y),l=Math.abs(zt(t).x-zt(i[0]).x),c=Math.abs(zt(t).y-zt(i[0]).y),h=Jt[e.arrowTypeStart],u=Jt[e.arrowTypeEnd],d=1;if(o<u&&o>0&&n<u){let f=u+d-o;f*=a==="right"?-1:1,s-=f}if(l<h&&l>0&&c<h){let f=h+d-l;f*=a==="right"?-1:1,s+=f}return zt(t).x+s},"x"),y:p(function(t,r,i){let s=0;const a=zt(i[0]).y<zt(i[i.length-1]).y?"down":"up";if(r===0&&Object.hasOwn(Jt,e.arrowTypeStart)){const{angle:f,deltaY:y}=Di(i[0],i[1]);s=Jt[e.arrowTypeStart]*Math.abs(Math.sin(f))*(y>=0?1:-1)}else if(r===i.length-1&&Object.hasOwn(Jt,e.arrowTypeEnd)){const{angle:f,deltaY:y}=Di(i[i.length-1],i[i.length-2]);s=Jt[e.arrowTypeEnd]*Math.abs(Math.sin(f))*(y>=0?1:-1)}const o=Math.abs(zt(t).y-zt(i[i.length-1]).y),n=Math.abs(zt(t).x-zt(i[i.length-1]).x),l=Math.abs(zt(t).y-zt(i[0]).y),c=Math.abs(zt(t).x-zt(i[0]).x),h=Jt[e.arrowTypeStart],u=Jt[e.arrowTypeEnd],d=1;if(o<u&&o>0&&n<u){let f=u+d-o;f*=a==="up"?-1:1,s-=f}if(l<h&&l>0&&c<h){let f=h+d-l;f*=a==="up"?-1:1,s+=f}return zt(t).y+s},"y")}),"getLineFunctionsWithOffset"),kw=p((e,t,r,i,s,a=!1,o)=>{t.arrowTypeStart&&uc(e,"start",t.arrowTypeStart,r,i,s,a,o),t.arrowTypeEnd&&uc(e,"end",t.arrowTypeEnd,r,i,s,a,o)},"addEdgeMarkers"),ww={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_barb_neo:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},Sw=["cross","point","circle","lollipop","aggregation","extension","composition","dependency","barb"],uc=p((e,t,r,i,s,a,o=!1,n)=>{var y;if(!r||r==="none")return;const l=ww[r],c=l&&Sw.includes(l.type);if(!l){I.warn(`Unknown arrow type: ${r}`);return}const h=l.type,f=`${s}_${a}-${h}${t==="start"?"Start":"End"}${o&&c?"-margin":""}`;if(n&&n.trim()!==""){const m=n.replace(/[^\dA-Za-z]/g,"_"),C=`${f}_${m}`;if(!document.getElementById(C)){const x=document.getElementById(f);if(x){const k=x.cloneNode(!0);k.id=C,k.querySelectorAll("path, circle, line").forEach(T=>{T.setAttribute("stroke",n),l.fill&&T.setAttribute("fill",n)}),(y=x.parentNode)==null||y.appendChild(k)}}e.attr(`marker-${t}`,`url(${i}#${C})`)}else e.attr(`marker-${t}`,`url(${i}#${f})`)},"addEdgeMarker"),Tw=p(e=>{var t,r;return typeof e=="string"?e:(r=(t=At())==null?void 0:t.flowchart)==null?void 0:r.curve},"resolveEdgeCurveType"),oi=new Map,jt=new Map,_w=p(()=>{oi.clear(),jt.clear()},"clear"),og=p(e=>!!(e.label||e.startLabelLeft||e.startLabelRight||e.endLabelLeft||e.endLabelRight),"hasEdgeLabel"),vi=p(e=>e?typeof e=="string"?e:e.reduce((t,r)=>t+";"+r,""):"","getLabelStyles"),cl=p(async(e,t)=>{const r=At();let i=ee(r);const{labelStyles:s}=dt(t);t.labelStyle=s;const a=e.insert("g").attr("class","edgeLabel"),o=a.insert("g").attr("class","label").attr("data-id",t.id),n=t.labelType==="markdown",c=await Te(e,t.label,{style:vi(t.labelStyle),useHtmlLabels:i,addSvgBackground:!0,isNode:!1,markdown:n,width:n?void 0:void 0},r);o.node().appendChild(c),I.info("abc82",t,t.labelType);let h,u;if(i){const f=c.children[0],y=Lt(c);h=await xr.measure(()=>f.getBoundingClientRect()),u=h,y.attr("width",h.width),y.attr("height",h.height)}else{const f=Lt(c).select("text").node();await xr.measure(()=>{h=c.getBBox(),f&&typeof f.getBBox=="function"?u=f.getBBox():u=h})}o.attr("transform",Bi(u,i)),oi.set(t.id,a),t.width=h.width,t.height=h.height;let d;if(t.startLabelLeft){const f=e.insert("g").attr("class","edgeTerminals"),y=f.insert("g").attr("class","inner"),m=await Qe(y,t.startLabelLeft,vi(t.labelStyle)||"",!1,!1);d=m;let C=m.getBBox();if(i){const x=m.children[0],k=Lt(m);C=x.getBoundingClientRect(),k.attr("width",C.width),k.attr("height",C.height)}y.attr("transform",Bi(C,i)),jt.get(t.id)||jt.set(t.id,{}),jt.get(t.id).startLeft=f,Pi(d,t.startLabelLeft)}if(t.startLabelRight){const f=e.insert("g").attr("class","edgeTerminals"),y=f.insert("g").attr("class","inner"),m=await Qe(y,t.startLabelRight,vi(t.labelStyle)||"",!1,!1);d=m;let C=m.getBBox();if(i){const x=m.children[0],k=Lt(m);C=x.getBoundingClientRect(),k.attr("width",C.width),k.attr("height",C.height)}y.attr("transform",Bi(C,i)),jt.get(t.id)||jt.set(t.id,{}),jt.get(t.id).startRight=f,Pi(d,t.startLabelRight)}if(t.endLabelLeft){const f=e.insert("g").attr("class","edgeTerminals"),y=f.insert("g").attr("class","inner"),m=await Qe(f,t.endLabelLeft,vi(t.labelStyle)||"",!1,!1);d=m;let C=m.getBBox();if(i){const x=m.children[0],k=Lt(m);C=x.getBoundingClientRect(),k.attr("width",C.width),k.attr("height",C.height)}y.attr("transform",Bi(C,i)),jt.get(t.id)||jt.set(t.id,{}),jt.get(t.id).endLeft=f,Pi(d,t.endLabelLeft)}if(t.endLabelRight){const f=e.insert("g").attr("class","edgeTerminals"),y=f.insert("g").attr("class","inner"),m=await Qe(f,t.endLabelRight,vi(t.labelStyle)||"",!1,!1);d=m;let C=m.getBBox();if(i){const x=m.children[0],k=Lt(m);C=x.getBoundingClientRect(),k.attr("width",C.width),k.attr("height",C.height)}y.attr("transform",Bi(C,i)),jt.get(t.id)||jt.set(t.id,{}),jt.get(t.id).endRight=f,Pi(d,t.endLabelRight)}return c},"insertEdgeLabel");function Pi(e,t){ee(At())&&e&&(e.style.width=t.length*9+"px",e.style.height="12px")}p(Pi,"setTerminalWidth");var Bw=p((e,t)=>{I.debug("Moving label abc88 ",e.id,e.label,oi.get(e.id),t);let r=t.updatedPath?t.updatedPath:t.originalPath;const i=At(),{subGraphTitleTotalMargin:s}=Sa(i);if(e.label){const a=oi.get(e.id);let o=e.x,n=e.y;if(r){const l=te.calcLabelPosition(r);I.debug("Moving label "+e.label+" from (",o,",",n,") to (",l.x,",",l.y,") abc88"),t.updatedPath&&(o=l.x,n=l.y)}a.attr("transform",`translate(${o}, ${n+s/2})`)}if(e.startLabelLeft){const a=jt.get(e.id).startLeft;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_left",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}if(e.startLabelRight){const a=jt.get(e.id).startRight;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_right",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}if(e.endLabelLeft){const a=jt.get(e.id).endLeft;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_left",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}if(e.endLabelRight){const a=jt.get(e.id).endRight;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_right",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}},"positionEdgeLabel"),vw=p((e,t)=>{var o;if(!(e!=null&&e.isLabelEdge)||!((o=e==null?void 0:e.id)!=null&&o.endsWith("-to-label"))||!Array.isArray(t)||t.length!==2)return t;const[r,i]=t,s=Math.abs(i.x-r.x),a=Math.abs(i.y-r.y);return s<.001||a<.001?t:a>=s?[r,{x:r.x,y:i.y},i]:[r,{x:i.x,y:r.y},i]},"orthogonalizeToLabelClippedPoints"),Lw=p((e,t)=>{const r=e.x,i=e.y,s=Math.abs(t.x-r),a=Math.abs(t.y-i),o=e.width/2,n=e.height/2;return s>=o||a>=n},"outsideNode"),Fw=p((e,t,r)=>{I.debug(`intersection calc abc89:
260
+ outsidePoint: ${JSON.stringify(t)}
261
+ insidePoint : ${JSON.stringify(r)}
262
+ node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);const i=e.x,s=e.y,a=Math.abs(i-r.x),o=e.width/2;let n=r.x<t.x?o-a:o+a;const l=e.height/2,c=Math.abs(t.y-r.y),h=Math.abs(t.x-r.x);if(Math.abs(s-t.y)*o>Math.abs(i-t.x)*l){let u=r.y<t.y?t.y-l-s:s-l-t.y;n=h*u/c;const d={x:r.x<t.x?r.x+n:r.x-h+n,y:r.y<t.y?r.y+c-u:r.y-c+u};return n===0&&(d.x=t.x,d.y=t.y),h===0&&(d.x=t.x),c===0&&(d.y=t.y),I.debug(`abc89 top/bottom calc, Q ${c}, q ${u}, R ${h}, r ${n}`,d),d}else{r.x<t.x?n=t.x-o-i:n=i-o-t.x;let u=c*n/h,d=r.x<t.x?r.x+h-n:r.x-h+n,f=r.y<t.y?r.y+u:r.y-u;return I.debug(`sides calc abc89, Q ${c}, q ${u}, R ${h}, r ${n}`,{_x:d,_y:f}),n===0&&(d=t.x,f=t.y),h===0&&(d=t.x),c===0&&(f=t.y),{x:d,y:f}}},"intersection"),dc=p((e,t)=>{I.warn("abc88 cutPathAtIntersect",e,t);let r=[],i=e[0],s=!1;return e.forEach(a=>{if(I.info("abc88 checking point",a,t),!Lw(t,a)&&!s){const o=Fw(t,i,a);I.debug("abc88 inside",a,i,o),I.debug("abc88 intersection",o,t);let n=!1;r.forEach(l=>{n=n||l.x===o.x&&l.y===o.y}),r.some(l=>l.x===o.x&&l.y===o.y)?I.warn("abc88 no intersect",o,r):r.push(o),s=!0}else I.warn("abc88 outside",a,i),i=a,s||r.push(a)}),I.debug("returning points",r),r},"cutPathAtIntersect");function ng(e){const t=[],r=[];for(let i=1;i<e.length-1;i++){const s=e[i-1],a=e[i],o=e[i+1];(s.x===a.x&&a.y===o.y&&Math.abs(a.x-o.x)>5&&Math.abs(a.y-s.y)>5||s.y===a.y&&a.x===o.x&&Math.abs(a.x-s.x)>5&&Math.abs(a.y-o.y)>5)&&(t.push(a),r.push(i))}return{cornerPoints:t,cornerPointPositions:r}}p(ng,"extractCornerPoints");var fc=p(function(e,t,r){const i=t.x-e.x,s=t.y-e.y,a=Math.sqrt(i*i+s*s),o=r/a;return{x:t.x-o*i,y:t.y-o*s}},"findAdjacentPoint"),Mw=p(function(e){const{cornerPointPositions:t}=ng(e),r=[];for(let i=0;i<e.length;i++)if(t.includes(i)){const s=e[i-1],a=e[i+1],o=e[i],n=fc(s,o,5),l=fc(a,o,5),c=l.x-n.x,h=l.y-n.y;r.push(n);const u=Math.sqrt(2)*2;let d={x:o.x,y:o.y};if(Math.abs(a.x-s.x)>10&&Math.abs(a.y-s.y)>=10){I.debug("Corner point fixing",Math.abs(a.x-s.x),Math.abs(a.y-s.y));const f=5;o.x===n.x?d={x:c<0?n.x-f+u:n.x+f-u,y:h<0?n.y-u:n.y+u}:d={x:c<0?n.x-u:n.x+u,y:h<0?n.y-f+u:n.y+f-u}}else I.debug("Corner point skipping fixing",Math.abs(a.x-s.x),Math.abs(a.y-s.y));r.push(d,l)}else r.push(e[i]);return r},"fixCorners"),Aw=p((e,t,r)=>{const i=e-t-r,s=2,a=2,o=s+a,n=Math.floor(i/o),l=Number.isFinite(n)?Math.max(0,n):0,c=Array(l).fill(`${s} ${a}`).join(" ");return`0 ${t} ${c} ${r}`},"generateDashArray"),lg=p(function(e,t,r,i,s,a,o,n=!1){var $;if(!o)throw new Error(`insertEdge: missing diagramId for edge "${t.id}" — edge IDs require a diagram prefix for uniqueness`);const{handDrawnSeed:l,layout:c}=At();let h=t.points,u=!1;const d=s;var f=a;const y=[];for(const N in t.cssCompiledStyles)Nd(N)||y.push(t.cssCompiledStyles[N]);if(c==="swimlane"){if(f.intersect&&d.intersect&&Array.isArray(h)&&h.length>=2)if(h.length===2)h=[d.intersect(h[0]),f.intersect(h[1])];else{const N=h.slice(1,-1),V=N[0],at=N[N.length-1],ht=.5,pt=Math.abs(h[h.length-1].x-at.x)<ht&&Math.abs(h[h.length-1].y-at.y)<ht,yt=d.intersect(V),gt=pt?at:f.intersect(at),_t=Math.abs(gt.x-at.x)<ht&&Math.abs(gt.y-at.y)<ht,Et=Math.abs(yt.x-V.x)<ht&&Math.abs(yt.y-V.y)<ht?[]:[yt],bt=_t?[]:[gt];h=[...Et,...N,...bt]}h=vw(t,h)}else f.intersect&&d.intersect&&!n&&(h=h.slice(1,t.points.length-1),h.unshift(d.intersect(h[0])),h.push(f.intersect(h[h.length-1])));const m=btoa(JSON.stringify(h));t.toCluster&&(I.info("to cluster abc88",r.get(t.toCluster)),h=dc(t.points,r.get(t.toCluster).node),u=!0),t.fromCluster&&(I.debug("from cluster abc88",r.get(t.fromCluster),JSON.stringify(h,null,2)),h=dc(h.reverse(),r.get(t.fromCluster).node).reverse(),u=!0);let C=h.filter(N=>!Number.isNaN(N.y));const x=Tw(t.curve);x!=="rounded"&&(C=Mw(C));let k=Wi;switch(x){case"linear":k=Wi;break;case"basis":k=Yo;break;case"cardinal":k=_d;break;case"bumpX":k=bd;break;case"bumpY":k=kd;break;case"catmullRom":k=vd;break;case"monotoneX":k=$d;break;case"monotoneY":k=Od;break;case"natural":k=Pd;break;case"step":k=Id;break;case"stepAfter":k=qd;break;case"stepBefore":k=Rd;break;case"rounded":k=Wi;break;default:k=Yo}const{x:w,y:T}=bw(t),_=k1().x(w).y(T).curve(k);let v;switch(t.thickness){case"normal":v="edge-thickness-normal";break;case"thick":v="edge-thickness-thick";break;case"invisible":v="edge-thickness-invisible";break;default:v="edge-thickness-normal"}switch(t.pattern){case"solid":v+=" edge-pattern-solid";break;case"dotted":v+=" edge-pattern-dotted";break;case"dashed":v+=" edge-pattern-dashed";break;default:v+=" edge-pattern-solid"}let F,L=x==="rounded"?hg(cg(C,t),5):_(C);const U=Array.isArray(t.style)?t.style:[t.style];let W=U.find(N=>N==null?void 0:N.startsWith("stroke:")),q="";t.animate&&(q="edge-animation-fast"),t.animation&&(q="edge-animation-"+t.animation);let rt=!1;if(t.look==="handDrawn"){const N=nt.svg(e);Object.assign([],C);const V=N.path(L,{roughness:.3,seed:l});v+=" transition",F=Lt(V).select("path").attr("id",`${o}-${t.id}`).attr("class"," "+v+(t.classes?" "+t.classes:"")+(q?" "+q:"")).attr("style",U?U.reduce((ht,pt)=>ht+";"+pt,""):"");let at=F.attr("d");F.attr("d",at),e.node().appendChild(F.node())}else{const N=y.join(";"),V=U?U.reduce((_t,wt)=>_t+wt+";",""):"",at=(N?N+";"+V+";":V)+";"+(U?U.reduce((_t,wt)=>_t+";"+wt,""):"");F=e.append("path").attr("d",L).attr("id",`${o}-${t.id}`).attr("class"," "+v+(t.classes?" "+t.classes:"")+(q?" "+q:"")).attr("style",at),W=($=at.match(/stroke:([^;]+)/))==null?void 0:$[1],rt=t.animate===!0||!!t.animation||N.includes("animation");const ht=F.node(),pt=typeof ht.getTotalLength=="function"?ht.getTotalLength():0,yt=cc[t.arrowTypeStart]||0,gt=cc[t.arrowTypeEnd]||0;if(t.look==="neo"&&!rt){const wt=`stroke-dasharray: ${t.pattern==="dotted"||t.pattern==="dashed"?Aw(pt,yt,gt):`0 ${yt} ${pt-yt-gt} ${gt}`}; stroke-dashoffset: 0;`;F.attr("style",wt+F.attr("style"))}}F.attr("data-edge",!0),F.attr("data-et","edge"),F.attr("data-id",t.id),F.attr("data-points",m),F.attr("data-look",Xt(t.look)),t.showPoints&&C.forEach(N=>{e.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",N.x).attr("cy",N.y)});let Y="";(At().flowchart.arrowMarkerAbsolute||At().state.arrowMarkerAbsolute)&&(Y=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,Y=Y.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),I.info("arrowTypeStart",t.arrowTypeStart),I.info("arrowTypeEnd",t.arrowTypeEnd);const A=!rt&&(t==null?void 0:t.look)==="neo";kw(F,t,Y,o,i,A,W);const E=Math.floor(h.length/2),B=h[E];te.isLabelCoordinateInPath(B,F.attr("d"))||(u=!0);let D={};return u&&(D.updatedPath=h),D.originalPath=t.points,D},"insertEdge");function hg(e,t){if(e.length<2)return"";let r="";const i=e.length,s=1e-5;for(let a=0;a<i;a++){const o=e[a],n=e[a-1],l=e[a+1];if(a===0)r+=`M${o.x},${o.y}`;else if(a===i-1)r+=`L${o.x},${o.y}`;else{const c=o.x-n.x,h=o.y-n.y,u=l.x-o.x,d=l.y-o.y,f=Math.hypot(c,h),y=Math.hypot(u,d);if(f<s||y<s){r+=`L${o.x},${o.y}`;continue}const m=c/f,C=h/f,x=u/y,k=d/y,w=m*x+C*k,T=Math.max(-1,Math.min(1,w)),_=Math.acos(T);if(_<s||Math.abs(Math.PI-_)<s){r+=`L${o.x},${o.y}`;continue}const v=Math.min(t/Math.sin(_/2),f/2,y/2),F=o.x-m*v,L=o.y-C*v,U=o.x+x*v,W=o.y+k*v;r+=`L${F},${L}`,r+=`Q${o.x},${o.y} ${U},${W}`}}return r}p(hg,"generateRoundedPath");function an(e,t){if(!e||!t)return{angle:0,deltaX:0,deltaY:0};const r=t.x-e.x,i=t.y-e.y;return{angle:Math.atan2(i,r),deltaX:r,deltaY:i}}p(an,"calculateDeltaAndAngle");function cg(e,t){const r=e.map(s=>({...s}));if(e.length>=2&&Jt[t.arrowTypeStart]){const s=Jt[t.arrowTypeStart],a=e[0],o=e[1],{angle:n}=an(a,o),l=s*Math.cos(n),c=s*Math.sin(n);r[0].x=a.x+l,r[0].y=a.y+c}const i=e.length;if(i>=2&&Jt[t.arrowTypeEnd]){const s=Jt[t.arrowTypeEnd],a=e[i-1],o=e[i-2],{angle:n}=an(o,a),l=s*Math.cos(n),c=s*Math.sin(n);r[i-1].x=a.x-l,r[i-1].y=a.y-c}return r}p(cg,"applyMarkerOffsetsToPoints");var Ew=p((e,t,r,i)=>{t.forEach(s=>{eS[s](e,r,i)})},"insertMarkers"),$w=p((e,t,r)=>{I.trace("Making markers for ",r),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,7 L18,13 V 1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,1 V 13 L18,7 Z"),e.append("marker").attr("id",r+"_"+t+"-extensionStart-margin").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,7 18,13 18,1").style("stroke-width",2).style("stroke-dasharray","0"),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd-margin").attr("class","marker extension "+t).attr("refX",9).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,1 10,13 18,7").style("stroke-width",2).style("stroke-dasharray","0")},"extension"),Ow=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart-margin").attr("class","marker composition "+t).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("viewBox","0 0 15 15").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd-margin").attr("class","marker composition "+t).attr("refX",3.5).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),Dw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart-margin").attr("class","marker aggregation "+t).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd-margin").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),Pw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart-margin").attr("class","marker dependency "+t).attr("refX",4).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd-margin").attr("class","marker dependency "+t).attr("refX",16).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),Iw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart-margin").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd-margin").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2)},"lollipop"),Rw=p((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointEnd-margin").attr("class","marker "+t).attr("viewBox","0 0 11.5 14").attr("refX",11.5).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",10.5).attr("markerHeight",14).attr("orient","auto").append("path").attr("d","M 0 0 L 11.5 7 L 0 14 z").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointStart-margin").attr("class","marker "+t).attr("viewBox","0 0 11.5 14").attr("refX",1).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11.5).attr("markerHeight",14).attr("orient","auto").append("polygon").attr("points","0,7 11.5,14 11.5,0").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"point"),qw=p((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleEnd-margin").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refY",5).attr("refX",12.25).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleStart-margin").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-2).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"circle"),Nw=p((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-crossEnd-margin").attr("class","marker cross "+t).attr("viewBox","0 0 15 15").attr("refX",17.7).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5),e.append("marker").attr("id",r+"_"+t+"-crossStart-margin").attr("class","marker cross "+t).attr("viewBox","0 0 15 15").attr("refX",-3.5).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5).style("stroke-dasharray","1,0")},"cross"),Ww=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),zw=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{transitionColor:a}=s;e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd-margin").attr("refX",17).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z").attr("fill",`${a}`)},"barbNeo"),Hw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneStart").attr("class","marker onlyOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneEnd").attr("class","marker onlyOne "+t).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),Yw=p((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneStart").attr("class","marker zeroOrOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),i.append("path").attr("d","M9,0 L9,18");const s=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+t).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");s.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),s.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),jw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreStart").attr("class","marker oneOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreEnd").attr("class","marker oneOrMore "+t).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),Uw=p((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),i.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");const s=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+t).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");s.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),s.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),Xw=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{strokeWidth:a}=s;e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneStart").attr("class","marker onlyOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M9,0 L9,18 M15,0 L15,18").attr("stroke-width",`${a}`),e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneEnd").attr("class","marker onlyOne "+t).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M3,0 L3,18 M9,0 L9,18").attr("stroke-width",`${a}`)},"only_one_neo"),Gw=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{strokeWidth:a,mainBkg:o}=s,n=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneStart").attr("class","marker zeroOrOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse");n.append("circle").attr("fill",o??"white").attr("cx",21).attr("cy",9).attr("stroke-width",`${a}`).attr("r",6),n.append("path").attr("d","M9,0 L9,18").attr("stroke-width",`${a}`);const l=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+t).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("markerUnits","userSpaceOnUse").attr("orient","auto");l.append("circle").attr("fill",o??"white").attr("cx",9).attr("cy",9).attr("stroke-width",`${a}`).attr("r",6),l.append("path").attr("d","M21,0 L21,18").attr("stroke-width",`${a}`)},"zero_or_one_neo"),Vw=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{strokeWidth:a}=s;e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreStart").attr("class","marker oneOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27").attr("stroke-width",`${a}`),e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreEnd").attr("class","marker oneOrMore "+t).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18").attr("stroke-width",`${a}`)},"one_or_more_neo"),Zw=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{strokeWidth:a,mainBkg:o}=s,n=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto");n.append("circle").attr("fill",o??"white").attr("cx",45.5).attr("cy",18).attr("r",6).attr("stroke-width",`${a}`),n.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18").attr("stroke-width",`${a}`);const l=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+t).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse");l.append("circle").attr("fill",o??"white").attr("cx",11).attr("cy",18).attr("r",6).attr("stroke-width",`${a}`),l.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18").attr("stroke-width",`${a}`)},"zero_or_more_neo"),Kw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d",`M0,0
263
+ L20,10
264
+ M20,10
265
+ L0,20`)},"requirement_arrow"),Qw=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{strokeWidth:a}=s;e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("stroke-width",`${a}`).attr("viewBox","0 0 25 20").append("path").attr("d",`M0,0
266
+ L20,10
267
+ M20,10
268
+ L0,20`).attr("stroke-linejoin","miter")},"requirement_arrow_neo"),Jw=p((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");i.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),i.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),i.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains"),tS=p((e,t,r)=>{const i=Ht(),{themeVariables:s}=i,{strokeWidth:a}=s,o=e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("g");o.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),o.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),o.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10),o.selectAll("*").attr("stroke-width",`${a}`)},"requirement_contains_neo"),eS={extension:$w,composition:Ow,aggregation:Dw,dependency:Pw,lollipop:Iw,point:Rw,circle:qw,cross:Nw,barb:Ww,barbNeo:zw,only_one:Hw,zero_or_one:Yw,one_or_more:jw,zero_or_more:Uw,only_one_neo:Xw,zero_or_one_neo:Gw,one_or_more_neo:Vw,zero_or_more_neo:Zw,requirement_arrow:Kw,requirement_contains:Jw,requirement_arrow_neo:Qw,requirement_contains_neo:tS},ug=Ew,dg=typeof global=="object"&&global&&global.Object===Object&&global,rS=typeof self=="object"&&self&&self.Object===Object&&self,Xe=dg||rS||Function("return this")(),Ee=Xe.Symbol,fg=Object.prototype,iS=fg.hasOwnProperty,sS=fg.toString,Li=Ee?Ee.toStringTag:void 0;function aS(e){var t=iS.call(e,Li),r=e[Li];try{e[Li]=void 0;var i=!0}catch{}var s=sS.call(e);return i&&(t?e[Li]=r:delete e[Li]),s}var oS=Object.prototype,nS=oS.toString;function lS(e){return nS.call(e)}var hS="[object Null]",cS="[object Undefined]",pc=Ee?Ee.toStringTag:void 0;function ui(e){return e==null?e===void 0?cS:hS:pc&&pc in Object(e)?aS(e):lS(e)}function Cr(e){return e!=null&&typeof e=="object"}var uS="[object Symbol]";function ul(e){return typeof e=="symbol"||Cr(e)&&ui(e)==uS}function pg(e,t){for(var r=-1,i=e==null?0:e.length,s=Array(i);++r<i;)s[r]=t(e[r],r,e);return s}var ne=Array.isArray,gc=Ee?Ee.prototype:void 0,yc=gc?gc.toString:void 0;function gg(e){if(typeof e=="string")return e;if(ne(e))return pg(e,gg)+"";if(ul(e))return yc?yc.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function dl(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function _a(e){return e}var dS="[object AsyncFunction]",fS="[object Function]",pS="[object GeneratorFunction]",gS="[object Proxy]";function la(e){if(!dl(e))return!1;var t=ui(e);return t==fS||t==pS||t==dS||t==gS}var Ka=Xe["__core-js_shared__"],mc=(function(){var e=/[^.]+$/.exec(Ka&&Ka.keys&&Ka.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function yS(e){return!!mc&&mc in e}var mS=Function.prototype,xS=mS.toString;function Tr(e){if(e!=null){try{return xS.call(e)}catch{}try{return e+""}catch{}}return""}var CS=/[\\^$.*+?()[\]{}|]/g,bS=/^\[object .+?Constructor\]$/,kS=Function.prototype,wS=Object.prototype,SS=kS.toString,TS=wS.hasOwnProperty,_S=RegExp("^"+SS.call(TS).replace(CS,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function BS(e){if(!dl(e)||yS(e))return!1;var t=la(e)?_S:bS;return t.test(Tr(e))}function vS(e,t){return e==null?void 0:e[t]}function _r(e,t){var r=vS(e,t);return BS(r)?r:void 0}var on=_r(Xe,"WeakMap");function LS(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function FS(){}var MS=800,AS=16,ES=Date.now;function $S(e){var t=0,r=0;return function(){var i=ES(),s=AS-(i-r);if(r=i,s>0){if(++t>=MS)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Ii(e){return function(){return e}}var xc=(function(){try{var e=_r(Object,"defineProperty");return e({},"",{}),e}catch{}})(),OS=xc?function(e,t){return xc(e,"toString",{configurable:!0,enumerable:!1,value:Ii(t),writable:!0})}:_a,DS=$S(OS);function PS(e,t){for(var r=-1,i=e==null?0:e.length;++r<i&&t(e[r],r,e)!==!1;);return e}function IS(e,t,r,i){for(var s=e.length,a=r+-1;++a<s;)if(t(e[a],a,e))return a;return-1}function RS(e){return e!==e}function qS(e,t,r){for(var i=r-1,s=e.length;++i<s;)if(e[i]===t)return i;return-1}function NS(e,t,r){return t===t?qS(e,t,r):IS(e,RS,r)}function WS(e,t){var r=e==null?0:e.length;return!!r&&NS(e,t,0)>-1}var zS=9007199254740991,HS=/^(?:0|[1-9]\d*)$/;function yg(e,t){var r=typeof e;return t=t??zS,!!t&&(r=="number"||r!="symbol"&&HS.test(e))&&e>-1&&e%1==0&&e<t}function mg(e,t){return e===t||e!==e&&t!==t}var Cc=Math.max;function YS(e,t,r){return t=Cc(t===void 0?e.length-1:t,0),function(){for(var i=arguments,s=-1,a=Cc(i.length-t,0),o=Array(a);++s<a;)o[s]=i[t+s];s=-1;for(var n=Array(t+1);++s<t;)n[s]=i[s];return n[t]=r(o),LS(e,this,n)}}function jS(e,t){return DS(YS(e,t,_a),e+"")}var US=9007199254740991;function fl(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=US}function Ba(e){return e!=null&&fl(e.length)&&!la(e)}var XS=Object.prototype;function xg(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||XS;return e===r}function GS(e,t){for(var r=-1,i=Array(e);++r<e;)i[r]=t(r);return i}var VS="[object Arguments]";function bc(e){return Cr(e)&&ui(e)==VS}var Cg=Object.prototype,ZS=Cg.hasOwnProperty,KS=Cg.propertyIsEnumerable,va=bc((function(){return arguments})())?bc:function(e){return Cr(e)&&ZS.call(e,"callee")&&!KS.call(e,"callee")};function QS(){return!1}var bg=typeof exports=="object"&&exports&&!exports.nodeType&&exports,kc=bg&&typeof module=="object"&&module&&!module.nodeType&&module,JS=kc&&kc.exports===bg,wc=JS?Xe.Buffer:void 0,tT=wc?wc.isBuffer:void 0,ha=tT||QS,eT="[object Arguments]",rT="[object Array]",iT="[object Boolean]",sT="[object Date]",aT="[object Error]",oT="[object Function]",nT="[object Map]",lT="[object Number]",hT="[object Object]",cT="[object RegExp]",uT="[object Set]",dT="[object String]",fT="[object WeakMap]",pT="[object ArrayBuffer]",gT="[object DataView]",yT="[object Float32Array]",mT="[object Float64Array]",xT="[object Int8Array]",CT="[object Int16Array]",bT="[object Int32Array]",kT="[object Uint8Array]",wT="[object Uint8ClampedArray]",ST="[object Uint16Array]",TT="[object Uint32Array]",Wt={};Wt[yT]=Wt[mT]=Wt[xT]=Wt[CT]=Wt[bT]=Wt[kT]=Wt[wT]=Wt[ST]=Wt[TT]=!0;Wt[eT]=Wt[rT]=Wt[pT]=Wt[iT]=Wt[gT]=Wt[sT]=Wt[aT]=Wt[oT]=Wt[nT]=Wt[lT]=Wt[hT]=Wt[cT]=Wt[uT]=Wt[dT]=Wt[fT]=!1;function _T(e){return Cr(e)&&fl(e.length)&&!!Wt[ui(e)]}function BT(e){return function(t){return e(t)}}var kg=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Hi=kg&&typeof module=="object"&&module&&!module.nodeType&&module,vT=Hi&&Hi.exports===kg,Qa=vT&&dg.process,Sc=(function(){try{var e=Hi&&Hi.require&&Hi.require("util").types;return e||Qa&&Qa.binding&&Qa.binding("util")}catch{}})(),Tc=Sc&&Sc.isTypedArray,pl=Tc?BT(Tc):_T,LT=Object.prototype,FT=LT.hasOwnProperty;function MT(e,t){var r=ne(e),i=!r&&va(e),s=!r&&!i&&ha(e),a=!r&&!i&&!s&&pl(e),o=r||i||s||a,n=o?GS(e.length,String):[],l=n.length;for(var c in e)(t||FT.call(e,c))&&!(o&&(c=="length"||s&&(c=="offset"||c=="parent")||a&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||yg(c,l)))&&n.push(c);return n}function AT(e,t){return function(r){return e(t(r))}}var ET=AT(Object.keys,Object),$T=Object.prototype,OT=$T.hasOwnProperty;function wg(e){if(!xg(e))return ET(e);var t=[];for(var r in Object(e))OT.call(e,r)&&r!="constructor"&&t.push(r);return t}function Fe(e){return Ba(e)?MT(e):wg(e)}var DT=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,PT=/^\w*$/;function gl(e,t){if(ne(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||ul(e)?!0:PT.test(e)||!DT.test(e)||t!=null&&e in Object(t)}var Ki=_r(Object,"create");function IT(){this.__data__=Ki?Ki(null):{},this.size=0}function RT(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var qT="__lodash_hash_undefined__",NT=Object.prototype,WT=NT.hasOwnProperty;function zT(e){var t=this.__data__;if(Ki){var r=t[e];return r===qT?void 0:r}return WT.call(t,e)?t[e]:void 0}var HT=Object.prototype,YT=HT.hasOwnProperty;function jT(e){var t=this.__data__;return Ki?t[e]!==void 0:YT.call(t,e)}var UT="__lodash_hash_undefined__";function XT(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Ki&&t===void 0?UT:t,this}function br(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}br.prototype.clear=IT;br.prototype.delete=RT;br.prototype.get=zT;br.prototype.has=jT;br.prototype.set=XT;function GT(){this.__data__=[],this.size=0}function La(e,t){for(var r=e.length;r--;)if(mg(e[r][0],t))return r;return-1}var VT=Array.prototype,ZT=VT.splice;function KT(e){var t=this.__data__,r=La(t,e);if(r<0)return!1;var i=t.length-1;return r==i?t.pop():ZT.call(t,r,1),--this.size,!0}function QT(e){var t=this.__data__,r=La(t,e);return r<0?void 0:t[r][1]}function JT(e){return La(this.__data__,e)>-1}function t_(e,t){var r=this.__data__,i=La(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}function Ge(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}Ge.prototype.clear=GT;Ge.prototype.delete=KT;Ge.prototype.get=QT;Ge.prototype.has=JT;Ge.prototype.set=t_;var Qi=_r(Xe,"Map");function e_(){this.size=0,this.__data__={hash:new br,map:new(Qi||Ge),string:new br}}function r_(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Fa(e,t){var r=e.__data__;return r_(t)?r[typeof t=="string"?"string":"hash"]:r.map}function i_(e){var t=Fa(this,e).delete(e);return this.size-=t?1:0,t}function s_(e){return Fa(this,e).get(e)}function a_(e){return Fa(this,e).has(e)}function o_(e,t){var r=Fa(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}function Ve(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}Ve.prototype.clear=e_;Ve.prototype.delete=i_;Ve.prototype.get=s_;Ve.prototype.has=a_;Ve.prototype.set=o_;var n_="Expected a function";function yl(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(n_);var r=function(){var i=arguments,s=t?t.apply(this,i):i[0],a=r.cache;if(a.has(s))return a.get(s);var o=e.apply(this,i);return r.cache=a.set(s,o)||a,o};return r.cache=new(yl.Cache||Ve),r}yl.Cache=Ve;var l_=500;function h_(e){var t=yl(e,function(i){return r.size===l_&&r.clear(),i}),r=t.cache;return t}var c_=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,u_=/\\(\\)?/g,d_=h_(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(c_,function(r,i,s,a){t.push(s?a.replace(u_,"$1"):i||r)}),t});function f_(e){return e==null?"":gg(e)}function Sg(e,t){return ne(e)?e:gl(e,t)?[e]:d_(f_(e))}function Ma(e){if(typeof e=="string"||ul(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function Tg(e,t){t=Sg(t,e);for(var r=0,i=t.length;e!=null&&r<i;)e=e[Ma(t[r++])];return r&&r==i?e:void 0}function p_(e,t,r){var i=e==null?void 0:Tg(e,t);return i===void 0?r:i}function _g(e,t){for(var r=-1,i=t.length,s=e.length;++r<i;)e[s+r]=t[r];return e}var _c=Ee?Ee.isConcatSpreadable:void 0;function g_(e){return ne(e)||va(e)||!!(_c&&e&&e[_c])}function y_(e,t,r,i,s){var a=-1,o=e.length;for(r||(r=g_),s||(s=[]);++a<o;){var n=e[a];r(n)?_g(s,n):i||(s[s.length]=n)}return s}function m_(e,t,r,i){var s=-1,a=e==null?0:e.length;for(i&&a&&(r=e[++s]);++s<a;)r=t(r,e[s],s,e);return r}function x_(){this.__data__=new Ge,this.size=0}function C_(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function b_(e){return this.__data__.get(e)}function k_(e){return this.__data__.has(e)}var w_=200;function S_(e,t){var r=this.__data__;if(r instanceof Ge){var i=r.__data__;if(!Qi||i.length<w_-1)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new Ve(i)}return r.set(e,t),this.size=r.size,this}function Ye(e){var t=this.__data__=new Ge(e);this.size=t.size}Ye.prototype.clear=x_;Ye.prototype.delete=C_;Ye.prototype.get=b_;Ye.prototype.has=k_;Ye.prototype.set=S_;function Bg(e,t){for(var r=-1,i=e==null?0:e.length,s=0,a=[];++r<i;){var o=e[r];t(o,r,e)&&(a[s++]=o)}return a}function T_(){return[]}var __=Object.prototype,B_=__.propertyIsEnumerable,Bc=Object.getOwnPropertySymbols,v_=Bc?function(e){return e==null?[]:(e=Object(e),Bg(Bc(e),function(t){return B_.call(e,t)}))}:T_;function L_(e,t,r){var i=t(e);return ne(e)?i:_g(i,r(e))}function vc(e){return L_(e,Fe,v_)}var nn=_r(Xe,"DataView"),ln=_r(Xe,"Promise"),qr=_r(Xe,"Set"),Lc="[object Map]",F_="[object Object]",Fc="[object Promise]",Mc="[object Set]",Ac="[object WeakMap]",Ec="[object DataView]",M_=Tr(nn),A_=Tr(Qi),E_=Tr(ln),$_=Tr(qr),O_=Tr(on),ze=ui;(nn&&ze(new nn(new ArrayBuffer(1)))!=Ec||Qi&&ze(new Qi)!=Lc||ln&&ze(ln.resolve())!=Fc||qr&&ze(new qr)!=Mc||on&&ze(new on)!=Ac)&&(ze=function(e){var t=ui(e),r=t==F_?e.constructor:void 0,i=r?Tr(r):"";if(i)switch(i){case M_:return Ec;case A_:return Lc;case E_:return Fc;case $_:return Mc;case O_:return Ac}return t});var $c=Xe.Uint8Array,D_="__lodash_hash_undefined__";function P_(e){return this.__data__.set(e,D_),this}function I_(e){return this.__data__.has(e)}function Ji(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Ve;++t<r;)this.add(e[t])}Ji.prototype.add=Ji.prototype.push=P_;Ji.prototype.has=I_;function R_(e,t){for(var r=-1,i=e==null?0:e.length;++r<i;)if(t(e[r],r,e))return!0;return!1}function vg(e,t){return e.has(t)}var q_=1,N_=2;function Lg(e,t,r,i,s,a){var o=r&q_,n=e.length,l=t.length;if(n!=l&&!(o&&l>n))return!1;var c=a.get(e),h=a.get(t);if(c&&h)return c==t&&h==e;var u=-1,d=!0,f=r&N_?new Ji:void 0;for(a.set(e,t),a.set(t,e);++u<n;){var y=e[u],m=t[u];if(i)var C=o?i(m,y,u,t,e,a):i(y,m,u,e,t,a);if(C!==void 0){if(C)continue;d=!1;break}if(f){if(!R_(t,function(x,k){if(!vg(f,k)&&(y===x||s(y,x,r,i,a)))return f.push(k)})){d=!1;break}}else if(!(y===m||s(y,m,r,i,a))){d=!1;break}}return a.delete(e),a.delete(t),d}function W_(e){var t=-1,r=Array(e.size);return e.forEach(function(i,s){r[++t]=[s,i]}),r}function ml(e){var t=-1,r=Array(e.size);return e.forEach(function(i){r[++t]=i}),r}var z_=1,H_=2,Y_="[object Boolean]",j_="[object Date]",U_="[object Error]",X_="[object Map]",G_="[object Number]",V_="[object RegExp]",Z_="[object Set]",K_="[object String]",Q_="[object Symbol]",J_="[object ArrayBuffer]",tB="[object DataView]",Oc=Ee?Ee.prototype:void 0,Ja=Oc?Oc.valueOf:void 0;function eB(e,t,r,i,s,a,o){switch(r){case tB:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case J_:return!(e.byteLength!=t.byteLength||!a(new $c(e),new $c(t)));case Y_:case j_:case G_:return mg(+e,+t);case U_:return e.name==t.name&&e.message==t.message;case V_:case K_:return e==t+"";case X_:var n=W_;case Z_:var l=i&z_;if(n||(n=ml),e.size!=t.size&&!l)return!1;var c=o.get(e);if(c)return c==t;i|=H_,o.set(e,t);var h=Lg(n(e),n(t),i,s,a,o);return o.delete(e),h;case Q_:if(Ja)return Ja.call(e)==Ja.call(t)}return!1}var rB=1,iB=Object.prototype,sB=iB.hasOwnProperty;function aB(e,t,r,i,s,a){var o=r&rB,n=vc(e),l=n.length,c=vc(t),h=c.length;if(l!=h&&!o)return!1;for(var u=l;u--;){var d=n[u];if(!(o?d in t:sB.call(t,d)))return!1}var f=a.get(e),y=a.get(t);if(f&&y)return f==t&&y==e;var m=!0;a.set(e,t),a.set(t,e);for(var C=o;++u<l;){d=n[u];var x=e[d],k=t[d];if(i)var w=o?i(k,x,d,t,e,a):i(x,k,d,e,t,a);if(!(w===void 0?x===k||s(x,k,r,i,a):w)){m=!1;break}C||(C=d=="constructor")}if(m&&!C){var T=e.constructor,_=t.constructor;T!=_&&"constructor"in e&&"constructor"in t&&!(typeof T=="function"&&T instanceof T&&typeof _=="function"&&_ instanceof _)&&(m=!1)}return a.delete(e),a.delete(t),m}var oB=1,Dc="[object Arguments]",Pc="[object Array]",ws="[object Object]",nB=Object.prototype,Ic=nB.hasOwnProperty;function lB(e,t,r,i,s,a){var o=ne(e),n=ne(t),l=o?Pc:ze(e),c=n?Pc:ze(t);l=l==Dc?ws:l,c=c==Dc?ws:c;var h=l==ws,u=c==ws,d=l==c;if(d&&ha(e)){if(!ha(t))return!1;o=!0,h=!1}if(d&&!h)return a||(a=new Ye),o||pl(e)?Lg(e,t,r,i,s,a):eB(e,t,l,r,i,s,a);if(!(r&oB)){var f=h&&Ic.call(e,"__wrapped__"),y=u&&Ic.call(t,"__wrapped__");if(f||y){var m=f?e.value():e,C=y?t.value():t;return a||(a=new Ye),s(m,C,r,i,a)}}return d?(a||(a=new Ye),aB(e,t,r,i,s,a)):!1}function xl(e,t,r,i,s){return e===t?!0:e==null||t==null||!Cr(e)&&!Cr(t)?e!==e&&t!==t:lB(e,t,r,i,xl,s)}var hB=1,cB=2;function uB(e,t,r,i){var s=r.length,a=s;if(e==null)return!a;for(e=Object(e);s--;){var o=r[s];if(o[2]?o[1]!==e[o[0]]:!(o[0]in e))return!1}for(;++s<a;){o=r[s];var n=o[0],l=e[n],c=o[1];if(o[2]){if(l===void 0&&!(n in e))return!1}else{var h=new Ye,u;if(!(u===void 0?xl(c,l,hB|cB,i,h):u))return!1}}return!0}function Fg(e){return e===e&&!dl(e)}function dB(e){for(var t=Fe(e),r=t.length;r--;){var i=t[r],s=e[i];t[r]=[i,s,Fg(s)]}return t}function Mg(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function fB(e){var t=dB(e);return t.length==1&&t[0][2]?Mg(t[0][0],t[0][1]):function(r){return r===e||uB(r,e,t)}}function pB(e,t){return e!=null&&t in Object(e)}function gB(e,t,r){t=Sg(t,e);for(var i=-1,s=t.length,a=!1;++i<s;){var o=Ma(t[i]);if(!(a=e!=null&&r(e,o)))break;e=e[o]}return a||++i!=s?a:(s=e==null?0:e.length,!!s&&fl(s)&&yg(o,s)&&(ne(e)||va(e)))}function yB(e,t){return e!=null&&gB(e,t,pB)}var mB=1,xB=2;function CB(e,t){return gl(e)&&Fg(t)?Mg(Ma(e),t):function(r){var i=p_(r,e);return i===void 0&&i===t?yB(r,e):xl(t,i,mB|xB)}}function bB(e){return function(t){return t==null?void 0:t[e]}}function kB(e){return function(t){return Tg(t,e)}}function wB(e){return gl(e)?bB(Ma(e)):kB(e)}function Ag(e){return typeof e=="function"?e:e==null?_a:typeof e=="object"?ne(e)?CB(e[0],e[1]):fB(e):wB(e)}function SB(e){return function(t,r,i){for(var s=-1,a=Object(t),o=i(t),n=o.length;n--;){var l=o[++s];if(r(a[l],l,a)===!1)break}return t}}var TB=SB();function _B(e,t){return e&&TB(e,t,Fe)}function BB(e,t){return function(r,i){if(r==null)return r;if(!Ba(r))return e(r,i);for(var s=r.length,a=-1,o=Object(r);++a<s&&i(o[a],a,o)!==!1;);return r}}var Cl=BB(_B);function vB(e){return Cr(e)&&Ba(e)}function LB(e){return typeof e=="function"?e:_a}function ar(e,t){var r=ne(e)?PS:Cl;return r(e,LB(t))}function FB(e,t){var r=[];return Cl(e,function(i,s,a){t(i,s,a)&&r.push(i)}),r}function Ss(e,t){var r=ne(e)?Bg:FB;return r(e,Ag(t))}function MB(e,t){return pg(t,function(r){return e[r]})}function to(e){return e==null?[]:MB(e,Fe(e))}var AB="[object Map]",EB="[object Set]",$B=Object.prototype,OB=$B.hasOwnProperty;function Rc(e){if(e==null)return!0;if(Ba(e)&&(ne(e)||typeof e=="string"||typeof e.splice=="function"||ha(e)||pl(e)||va(e)))return!e.length;var t=ze(e);if(t==AB||t==EB)return!e.size;if(xg(e))return!wg(e).length;for(var r in e)if(OB.call(e,r))return!1;return!0}function Pr(e){return e===void 0}function DB(e,t,r,i,s){return s(e,function(a,o,n){r=i?(i=!1,a):t(r,a,o,n)}),r}function PB(e,t,r){var i=ne(e)?m_:DB,s=arguments.length<3;return i(e,Ag(t),r,s,Cl)}var IB=1/0,RB=qr&&1/ml(new qr([,-0]))[1]==IB?function(e){return new qr(e)}:FS,qB=200;function NB(e,t,r){var i=-1,s=WS,a=e.length,o=!0,n=[],l=n;if(a>=qB){var c=RB(e);if(c)return ml(c);o=!1,s=vg,l=new Ji}else l=n;t:for(;++i<a;){var h=e[i],u=h;if(h=h!==0?h:0,o&&u===u){for(var d=l.length;d--;)if(l[d]===u)continue t;n.push(h)}else s(l,u,r)||(l!==n&&l.push(u),n.push(h))}return n}var WB=jS(function(e){return NB(y_(e,1,vB,!0))}),zB="\0",or="\0",qc="";class Aa{constructor(t={}){this._isDirected=Object.prototype.hasOwnProperty.call(t,"directed")?t.directed:!0,this._isMultigraph=Object.prototype.hasOwnProperty.call(t,"multigraph")?t.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(t,"compound")?t.compound:!1,this._label=void 0,this._defaultNodeLabelFn=Ii(void 0),this._defaultEdgeLabelFn=Ii(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[or]={}),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(t){return this._label=t,this}graph(){return this._label}setDefaultNodeLabel(t){return la(t)||(t=Ii(t)),this._defaultNodeLabelFn=t,this}nodeCount(){return this._nodeCount}nodes(){return Fe(this._nodes)}sources(){var t=this;return Ss(this.nodes(),function(r){return Rc(t._in[r])})}sinks(){var t=this;return Ss(this.nodes(),function(r){return Rc(t._out[r])})}setNodes(t,r){var i=arguments,s=this;return ar(t,function(a){i.length>1?s.setNode(a,r):s.setNode(a)}),this}setNode(t,r){return Object.prototype.hasOwnProperty.call(this._nodes,t)?(arguments.length>1&&(this._nodes[t]=r),this):(this._nodes[t]=arguments.length>1?r:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]=or,this._children[t]={},this._children[or][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)}node(t){return this._nodes[t]}hasNode(t){return Object.prototype.hasOwnProperty.call(this._nodes,t)}removeNode(t){if(Object.prototype.hasOwnProperty.call(this._nodes,t)){var r=i=>this.removeEdge(this._edgeObjs[i]);delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],ar(this.children(t),i=>{this.setParent(i)}),delete this._children[t]),ar(Fe(this._in[t]),r),delete this._in[t],delete this._preds[t],ar(Fe(this._out[t]),r),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this}setParent(t,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(Pr(r))r=or;else{r+="";for(var i=r;!Pr(i);i=this.parent(i))if(i===t)throw new Error("Setting "+r+" as parent of "+t+" would create a cycle");this.setNode(r)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=r,this._children[r][t]=!0,this}_removeFromParentsChildList(t){delete this._children[this._parent[t]][t]}parent(t){if(this._isCompound){var r=this._parent[t];if(r!==or)return r}}children(t){if(Pr(t)&&(t=or),this._isCompound){var r=this._children[t];if(r)return Fe(r)}else{if(t===or)return this.nodes();if(this.hasNode(t))return[]}}predecessors(t){var r=this._preds[t];if(r)return Fe(r)}successors(t){var r=this._sucs[t];if(r)return Fe(r)}neighbors(t){var r=this.predecessors(t);if(r)return WB(r,this.successors(t))}isLeaf(t){var r;return this.isDirected()?r=this.successors(t):r=this.neighbors(t),r.length===0}filterNodes(t){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var i=this;ar(this._nodes,function(o,n){t(n)&&r.setNode(n,o)}),ar(this._edgeObjs,function(o){r.hasNode(o.v)&&r.hasNode(o.w)&&r.setEdge(o,i.edge(o))});var s={};function a(o){var n=i.parent(o);return n===void 0||r.hasNode(n)?(s[o]=n,n):n in s?s[n]:a(n)}return this._isCompound&&ar(r.nodes(),function(o){r.setParent(o,a(o))}),r}setDefaultEdgeLabel(t){return la(t)||(t=Ii(t)),this._defaultEdgeLabelFn=t,this}edgeCount(){return this._edgeCount}edges(){return to(this._edgeObjs)}setPath(t,r){var i=this,s=arguments;return PB(t,function(a,o){return s.length>1?i.setEdge(a,o,r):i.setEdge(a,o),o}),this}setEdge(){var t,r,i,s,a=!1,o=arguments[0];typeof o=="object"&&o!==null&&"v"in o?(t=o.v,r=o.w,i=o.name,arguments.length===2&&(s=arguments[1],a=!0)):(t=o,r=arguments[1],i=arguments[3],arguments.length>2&&(s=arguments[2],a=!0)),t=""+t,r=""+r,Pr(i)||(i=""+i);var n=Ri(this._isDirected,t,r,i);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,n))return a&&(this._edgeLabels[n]=s),this;if(!Pr(i)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(r),this._edgeLabels[n]=a?s:this._defaultEdgeLabelFn(t,r,i);var l=HB(this._isDirected,t,r,i);return t=l.v,r=l.w,Object.freeze(l),this._edgeObjs[n]=l,Nc(this._preds[r],t),Nc(this._sucs[t],r),this._in[r][n]=l,this._out[t][n]=l,this._edgeCount++,this}edge(t,r,i){var s=arguments.length===1?eo(this._isDirected,arguments[0]):Ri(this._isDirected,t,r,i);return this._edgeLabels[s]}hasEdge(t,r,i){var s=arguments.length===1?eo(this._isDirected,arguments[0]):Ri(this._isDirected,t,r,i);return Object.prototype.hasOwnProperty.call(this._edgeLabels,s)}removeEdge(t,r,i){var s=arguments.length===1?eo(this._isDirected,arguments[0]):Ri(this._isDirected,t,r,i),a=this._edgeObjs[s];return a&&(t=a.v,r=a.w,delete this._edgeLabels[s],delete this._edgeObjs[s],Wc(this._preds[r],t),Wc(this._sucs[t],r),delete this._in[r][s],delete this._out[t][s],this._edgeCount--),this}inEdges(t,r){var i=this._in[t];if(i){var s=to(i);return r?Ss(s,function(a){return a.v===r}):s}}outEdges(t,r){var i=this._out[t];if(i){var s=to(i);return r?Ss(s,function(a){return a.w===r}):s}}nodeEdges(t,r){var i=this.inEdges(t,r);if(i)return i.concat(this.outEdges(t,r))}}Aa.prototype._nodeCount=0;Aa.prototype._edgeCount=0;function Nc(e,t){e[t]?e[t]++:e[t]=1}function Wc(e,t){--e[t]||delete e[t]}function Ri(e,t,r,i){var s=""+t,a=""+r;if(!e&&s>a){var o=s;s=a,a=o}return s+qc+a+qc+(Pr(i)?zB:i)}function HB(e,t,r,i){var s=""+t,a=""+r;if(!e&&s>a){var o=s;s=a,a=o}var n={v:s,w:a};return i&&(n.name=i),n}function eo(e,t){return Ri(e,t.v,t.w,t.name)}function Eg(e,{edgePathsClass:t="edges edgePaths"}={}){const r=e.insert("g").attr("class","root"),i=r.insert("g").attr("class","clusters"),s=r.insert("g").attr("class",t),a=r.insert("g").attr("class","edgeLabels"),o=r.insert("g").attr("class","nodes");return{clusters:i,edgePaths:s,edgeLabels:a,nodes:o,rootGroups:r}}p(Eg,"createLayoutElementGroups");async function $g(e,t){if(t.label){const{shapeSvg:r,bbox:i}=await mt(e,t);t.labelBBox={width:i.width,height:i.height},r.remove()}else t.labelBBox={width:0,height:0}}p($g,"measureGroupLabel");async function Og(e,t,r){var a;const i=await hl(e,t,r),s=((a=i.node())==null?void 0:a.getBBox())??{width:0,height:0};return t.width=s.width,t.height=s.height,i}p(Og,"insertMeasuredNode");async function Dg(e,t){const r=new Aa({multigraph:!0,compound:!0}),i=[...t.edges],s=At(),a=Eg(e),{edgeLabels:o,nodes:n}=a,l=new Map,c=e.node()!=null;await Promise.all(t.nodes.map(async h=>{if(h.isGroup)c&&await $g(n,h),r.setNode(h.id,{...h});else{if(c){const u=await Og(n,h,{config:s,dir:h.dir});l.set(h.id,u)}r.setNode(h.id,{...h})}}));for(const h of i)c&&og(h)&&await cl(o,h),r.setEdge(h.start,h.end,{...h},h.id),t.edges.some(d=>d.id===h.id)||t.edges.push(h);if(globalThis.mermaidCaptureSizes){const{captureNodeSizes:h}=await Ft(async()=>{const{captureNodeSizes:u}=await import("./sizeCapture-INFHLROL-DOSmwQs7.js");return{captureNodeSizes:u}},__vite__mapDeps([0,1,2,3,4]),import.meta.url);h(e,t)}return{graph:r,groups:a,nodeElements:l}}p(Dg,"createGraphWithElements");var Ot=new Map,cr=new Map,Pg=new Map,YB=p(()=>{cr.clear(),Pg.clear(),Ot.clear()},"clear"),ts=p((e,t)=>{const r=cr.get(t)||[];return I.trace("In isDescendant",t," ",e," = ",r.includes(e)),r.includes(e)},"isDescendant"),jB=p((e,t)=>{const r=cr.get(t)||[];return I.info("Descendants of ",t," is ",r),I.info("Edge is ",e),e.v===t||e.w===t?!1:r?r.includes(e.v)||ts(e.v,t)||ts(e.w,t)||r.includes(e.w):(I.debug("Tilt, ",t,",not in descendants"),!1)},"edgeInCluster"),Ig=p((e,t,r,i)=>{I.debug("Copying children of ",e,"root",i,"data",t.node(e),i);const s=t.children(e)||[];e!==i&&s.push(e),I.debug("Copying (nodes) clusterId",e,"nodes",s),s.forEach(a=>{if(t.children(a).length>0)Ig(a,t,r,i);else{const o=t.node(a);I.info("cp ",a," to ",i," with parent ",e),r.setNode(a,o),i!==t.parent(a)&&(I.debug("Setting parent",a,t.parent(a)),r.setParent(a,t.parent(a))),e!==i&&a!==e?(I.debug("Setting parent",a,e),r.setParent(a,e)):(I.info("In copy ",e,"root",i,"data",t.node(e),i),I.debug("Not Setting parent for node=",a,"cluster!==rootId",e!==i,"node!==clusterId",a!==e));const n=t.edges(a);I.debug("Copying Edges",n),n.forEach(l=>{I.info("Edge",l);const c=t.edge(l.v,l.w,l.name);I.info("Edge data",c,i);try{jB(l,i)?(I.info("Copying as ",l.v,l.w,c,l.name),r.setEdge(l.v,l.w,c,l.name),I.info("newGraph edges ",r.edges(),r.edge(r.edges()[0]))):I.info("Skipping copy of edge ",l.v,"-->",l.w," rootId: ",i," clusterId:",e)}catch(h){I.error(h)}})}I.debug("Removing node",a),t.removeNode(a)})},"copy"),Rg=p((e,t)=>{const r=t.children(e);let i=[...r];for(const s of r)Pg.set(s,e),i=[...i,...Rg(s,t)];return i},"extractDescendants"),UB=p((e,t,r)=>{const i=e.edges().filter(l=>l.v===t||l.w===t),s=e.edges().filter(l=>l.v===r||l.w===r),a=i.map(l=>({v:l.v===t?r:l.v,w:l.w===t?t:l.w})),o=s.map(l=>({v:l.v,w:l.w}));return a.filter(l=>o.some(c=>l.v===c.v&&l.w===c.w))},"findCommonEdges"),ca=p((e,t,r)=>{const i=t.children(e);if(I.trace("Searching children of id ",e,i),i.length<1)return e;let s;for(const a of i){const o=ca(a,t,r),n=UB(t,r,o);if(o)if(n.length>0)s=o;else return o}return s},"findNonClusterChild"),zc=p(e=>!Ot.has(e)||!Ot.get(e).externalConnections?e:Ot.has(e)?Ot.get(e).id:e,"getAnchorId"),uA=p((e,t)=>{var r;if(!e||t>10){I.debug("Opting out, no graph ");return}else I.debug("Opting in, graph ");e.nodes().forEach(function(i){e.children(i).length>0&&(I.debug("Cluster identified",i," Replacement id in edges: ",ca(i,e,i)),cr.set(i,Rg(i,e)),Ot.set(i,{id:ca(i,e,i),clusterData:e.node(i)}))}),e.nodes().forEach(function(i){const s=e.children(i),a=e.edges();s.length>0?(I.debug("Cluster identified",i,cr),a.forEach(o=>{const n=ts(o.v,i),l=ts(o.w,i);n^l&&(I.debug("Edge: ",o," leaves cluster ",i),I.debug("Descendants of XXX ",i,": ",cr.get(i)),Ot.get(i).externalConnections=!0)})):I.debug("Not a cluster ",i,cr)});for(let i of Ot.keys()){const s=Ot.get(i).id,a=e.parent(s);a!==i&&Ot.has(a)&&!Ot.get(a).externalConnections&&(Ot.get(i).id=a);const o=e.edges().some(n=>n.v===i);if(s&&((r=Ot.get(i))!=null&&r.externalConnections)&&o&&Wg(e,s,i)){const n=XB(e,i,e.parent(s));n&&(Ot.get(i).id=n)}}e.edges().forEach(function(i){const s=e.edge(i);I.debug("Edge "+i.v+" -> "+i.w+": "+JSON.stringify(i)),I.debug("Edge "+i.v+" -> "+i.w+": "+JSON.stringify(e.edge(i)));let a=i.v,o=i.w;if(I.debug("Fix XXX",Ot,"ids:",i.v,i.w,"Translating: ",Ot.get(i.v)," --- ",Ot.get(i.w)),Ot.get(i.v)||Ot.get(i.w)){if(I.debug("Fixing and trying - removing XXX",i.v,i.w,i.name),a=zc(i.v),o=zc(i.w),e.removeEdge(i.v,i.w,i.name),a!==i.v){const n=e.parent(a);Ot.get(n).externalConnections=!0,s.fromCluster=i.v}if(o!==i.w){const n=e.parent(o);Ot.get(n).externalConnections=!0,s.toCluster=i.w}I.debug("Fix Replacing with XXX",a,o,i.name),e.setEdge(a,o,s,i.name)}}),qg(e,0),I.trace(Ot)},"adjustClustersAndEdges"),qg=p((e,t)=>{var s,a;if(t>10){I.error("Bailing out");return}let r=e.nodes(),i=!1;for(const o of r){const n=e.children(o);i=i||n.length>0}if(!i){I.debug("Done, no node has children",e.nodes());return}I.debug("Nodes = ",r,t);for(const o of r)if(I.debug("Extracting node",o,Ot,Ot.has(o)&&!Ot.get(o).externalConnections,!e.parent(o),e.node(o),e.children("D")," Depth ",t),!Ot.has(o))I.debug("Not a cluster",o,t);else if(!Ot.get(o).externalConnections&&e.children(o)&&e.children(o).length>0){I.debug("Cluster without external connections, without a parent and with children",o,t);let l=e.graph().rankdir==="TB"?"LR":"TB";(a=(s=Ot.get(o))==null?void 0:s.clusterData)!=null&&a.dir&&(l=Ot.get(o).clusterData.dir,I.debug("Fixing dir",Ot.get(o).clusterData.dir,l));const c=new Aa({multigraph:!0,compound:!0}).setGraph({rankdir:l,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});Ig(o,e,c,o),e.setNode(o,{clusterNode:!0,id:o,clusterData:Ot.get(o).clusterData,label:Ot.get(o).label,graph:c})}else I.debug("Cluster ** ",o," **not meeting the criteria !externalConnections:",!Ot.get(o).externalConnections," no parent: ",!e.parent(o)," children ",e.children(o)&&e.children(o).length>0,e.children("D"),t),I.debug(Ot);r=e.nodes(),I.debug("New list of nodes",r);for(const o of r){const n=e.node(o);I.debug(" Now next level",o,n),n!=null&&n.clusterNode&&qg(n.graph,t+1)}},"extractor"),Ng=p((e,t)=>{if(t.length===0)return[];let r=Object.assign([],t);return t.forEach(i=>{const s=e.children(i),a=Ng(e,s);r=[...r,...a]}),r},"sorter"),dA=p(e=>Ng(e,e.children()),"sortNodesByHierarchy"),Wg=p((e,t,r)=>{let i=e.parent(t);for(;i&&i!==r;){const s=Ot.get(i);if(s&&!s.externalConnections)return!0;i=e.parent(i)}return!1},"isNodeInExtractableCluster"),XB=p((e,t,r)=>{const i=e.children(t)??[];for(const s of i){if(s===r||ts(s,r))continue;const a=ca(s,e,t);if(a&&!Wg(e,a,t))return a}return null},"findSafeAnchorNode");function zg({prepareLayout:e,measureLayout:t,runLayoutCore:r,paintLayout:i,afterPaint:s,paintOptions:a}){const o=t??kl;return p(async function(l,c,h,u){const d=c.select("g");((h==null?void 0:h.insertMarkers)??ug)(d,l.markers,l.type,l.diagramId),bl();const f={element:d,helpers:h,options:u};f.preparedLayout=await(e==null?void 0:e(l,f));const y=await o(l,f),m=await r(l,f),C={...f,measure:y};i?await i(l,C,m):await wl(l,C,a),await(s==null?void 0:s(l,C,m))},"render")}p(zg,"createCommonLayoutRenderer");function bl(){uw(),_w(),Cw(),YB()}p(bl,"clearLayoutRenderState");async function kl(e,{element:t}){return await Dg(t,e)}p(kl,"defaultMeasureLayout");async function wl(e,t,r={}){var o,n;const{measure:i}=t,{groups:s}=i;for(const l of((o=r.getNodes)==null?void 0:o.call(r,e,t))??e.nodes)(n=r.skipNode)!=null&&n.call(r,l,t)||await Hg(s,l,t,r);const a=jg(e.nodes);for(const l of e.edges)Ug(l,r)||await Xg(s,l,a,e,r,t)}p(wl,"paintLayoutData");async function Hg(e,t,r,i){t.clusterNode?hc(t):Yg(t,r,i)?await ag(e.clusters,t):hc(t)}p(Hg,"paintLayoutNode");function Yg(e,t,r){var i;return e.isGroup===!0&&(((i=r.isCluster)==null?void 0:i.call(r,e,t))??!0)}p(Yg,"shouldPaintAsCluster");function jg(e){const t=new Map;for(const r of e)r!=null&&r.id&&t.set(r.id,r);return t}p(jg,"buildNodeLookup");function Ug(e,t){var r;return e.isLayoutOnly||!!((r=t.skipEdge)!=null&&r.call(t,e))}p(Ug,"shouldSkipPaintEdge");async function Xg(e,t,r,i,s,a){const o=lg(e.edgePaths,{...t},s.clusterDb??new Map,i.type,hn(t.start,t,r,a,s),hn(t.end,t,r,a,s),i.diagramId,Gg(t,s));og(t)&&(oi.has(t.id)||await cl(e.edgeLabels,t),Vg(t,o))}p(Xg,"paintLayoutEdge");function hn(e,t,r,i,s){var a;return((a=s.getEdgeNode)==null?void 0:a.call(s,e,t,i))??(e?r.get(e)??{}:{})}p(hn,"getRenderedNode");function Gg(e,t){return typeof t.skipIntersect=="function"?t.skipIntersect(e):t.skipIntersect??!1}p(Gg,"shouldSkipIntersect");function Vg(e,t){const r=(t==null?void 0:t.updatedPath)??(t==null?void 0:t.originalPath),i=Ht(),{subGraphTitleTotalMargin:s}=Sa({flowchart:i.flowchart??{}});if(e.label){const a=oi.get(e.id);let o=e.x,n=e.y;if(r){const l=te.calcLabelPosition(r);I.debug("Moving label "+e.label+" from (",o,",",n,") to (",l.x,",",l.y,") abc88"),t!=null&&t.updatedPath&&(o=l.x,n=l.y)}a.attr("transform",`translate(${o}, ${n+s/2})`)}if(e!=null&&e.startLabelLeft){const a=jt.get(e.id).startLeft;let o=e==null?void 0:e.x,n=e==null?void 0:e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_left",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}if(e.startLabelRight){const a=jt.get(e.id).startRight;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_right",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}if(e.endLabelLeft){const a=jt.get(e.id).endLeft;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_left",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}if(e.endLabelRight){const a=jt.get(e.id).endRight;let o=e.x,n=e.y;if(r){const l=te.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_right",r);o=l.x,n=l.y}a.attr("transform",`translate(${o}, ${n})`)}}p(Vg,"positionRenderedEdgeLabel");function Zg(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}p(Zg,"getDefaultExportFromCjs");var Qt={},Ts={},Ze={},Hc;function di(){if(Hc)return Ze;Hc=1;function e(o){return typeof o>"u"||o===null}p(e,"isNothing");function t(o){return typeof o=="object"&&o!==null}p(t,"isObject");function r(o){return Array.isArray(o)?o:e(o)?[]:[o]}p(r,"toArray");function i(o,n){if(n){const l=Object.keys(n);for(let c=0,h=l.length;c<h;c+=1){const u=l[c];o[u]=n[u]}}return o}p(i,"extend");function s(o,n){let l="";for(let c=0;c<n;c+=1)l+=o;return l}p(s,"repeat");function a(o){return o===0&&Number.NEGATIVE_INFINITY===1/o}return p(a,"isNegativeZero"),Ze.isNothing=e,Ze.isObject=t,Ze.toArray=r,Ze.repeat=s,Ze.isNegativeZero=a,Ze.extend=i,Ze}p(di,"requireCommon");var ro,Yc;function fi(){if(Yc)return ro;Yc=1;function e(r,i){let s="";const a=r.reason||"(unknown reason)";return r.mark?(r.mark.name&&(s+='in "'+r.mark.name+'" '),s+="("+(r.mark.line+1)+":"+(r.mark.column+1)+")",!i&&r.mark.snippet&&(s+=`
269
+
270
+ `+r.mark.snippet),a+" "+s):a}p(e,"formatError");function t(r,i){Error.call(this),this.name="YAMLException",this.reason=r,this.mark=i,this.message=e(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}return p(t,"YAMLException2"),t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t.prototype.toString=p(function(i){return this.name+": "+e(this,i)},"toString"),ro=t,ro}p(fi,"requireException");var io,jc;function Kg(){if(jc)return io;jc=1;const e=di();function t(s,a,o,n,l){let c="",h="";const u=Math.floor(l/2)-1;return n-a>u&&(c=" ... ",a=n-u+c.length),o-n>u&&(h=" ...",o=n+u-h.length),{str:c+s.slice(a,o).replace(/\t/g,"→")+h,pos:n-a+c.length}}p(t,"getLine");function r(s,a){return e.repeat(" ",a-s.length)+s}p(r,"padStart");function i(s,a){if(a=Object.create(a||null),!s.buffer)return null;a.maxLength||(a.maxLength=79),typeof a.indent!="number"&&(a.indent=1),typeof a.linesBefore!="number"&&(a.linesBefore=3),typeof a.linesAfter!="number"&&(a.linesAfter=2);const o=/\r?\n|\r|\0/g,n=[0],l=[];let c,h=-1;for(;c=o.exec(s.buffer);)l.push(c.index),n.push(c.index+c[0].length),s.position<=c.index&&h<0&&(h=n.length-2);h<0&&(h=n.length-1);let u="";const d=Math.min(s.line+a.linesAfter,l.length).toString().length,f=a.maxLength-(a.indent+d+3);for(let m=1;m<=a.linesBefore&&!(h-m<0);m++){const C=t(s.buffer,n[h-m],l[h-m],s.position-(n[h]-n[h-m]),f);u=e.repeat(" ",a.indent)+r((s.line-m+1).toString(),d)+" | "+C.str+`
271
+ `+u}const y=t(s.buffer,n[h],l[h],s.position,f);u+=e.repeat(" ",a.indent)+r((s.line+1).toString(),d)+" | "+y.str+`
272
+ `,u+=e.repeat("-",a.indent+d+3+y.pos)+`^
273
+ `;for(let m=1;m<=a.linesAfter&&!(h+m>=l.length);m++){const C=t(s.buffer,n[h+m],l[h+m],s.position-(n[h]-n[h+m]),f);u+=e.repeat(" ",a.indent)+r((s.line+m+1).toString(),d)+" | "+C.str+`
274
+ `}return u.replace(/\n$/,"")}return p(i,"makeSnippet"),io=i,io}p(Kg,"requireSnippet");var so,Uc;function re(){if(Uc)return so;Uc=1;const e=fi(),t=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],r=["scalar","sequence","mapping"];function i(a){const o={};return a!==null&&Object.keys(a).forEach(function(n){a[n].forEach(function(l){o[String(l)]=n})}),o}p(i,"compileStyleAliases");function s(a,o){if(o=o||{},Object.keys(o).forEach(function(n){if(t.indexOf(n)===-1)throw new e('Unknown option "'+n+'" is met in definition of "'+a+'" YAML type.')}),this.options=o,this.tag=a,this.kind=o.kind||null,this.resolve=o.resolve||function(){return!0},this.construct=o.construct||function(n){return n},this.instanceOf=o.instanceOf||null,this.predicate=o.predicate||null,this.represent=o.represent||null,this.representName=o.representName||null,this.defaultStyle=o.defaultStyle||null,this.multi=o.multi||!1,this.styleAliases=i(o.styleAliases||null),r.indexOf(this.kind)===-1)throw new e('Unknown kind "'+this.kind+'" is specified for "'+a+'" YAML type.')}return p(s,"Type2"),so=s,so}p(re,"requireType");var ao,Xc;function Sl(){if(Xc)return ao;Xc=1;const e=fi(),t=re();function r(a,o){const n=[];return a[o].forEach(function(l){let c=n.length;n.forEach(function(h,u){h.tag===l.tag&&h.kind===l.kind&&h.multi===l.multi&&(c=u)}),n[c]=l}),n}p(r,"compileList");function i(){const a={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function o(n){n.multi?(a.multi[n.kind].push(n),a.multi.fallback.push(n)):a[n.kind][n.tag]=a.fallback[n.tag]=n}p(o,"collectType");for(let n=0,l=arguments.length;n<l;n+=1)arguments[n].forEach(o);return a}p(i,"compileMap");function s(a){return this.extend(a)}return p(s,"Schema2"),s.prototype.extend=p(function(o){let n=[],l=[];if(o instanceof t)l.push(o);else if(Array.isArray(o))l=l.concat(o);else if(o&&(Array.isArray(o.implicit)||Array.isArray(o.explicit)))o.implicit&&(n=n.concat(o.implicit)),o.explicit&&(l=l.concat(o.explicit));else throw new e("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");n.forEach(function(h){if(!(h instanceof t))throw new e("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(h.loadKind&&h.loadKind!=="scalar")throw new e("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(h.multi)throw new e("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),l.forEach(function(h){if(!(h instanceof t))throw new e("Specified list of YAML types (or a single Type object) contains a non-Type object.")});const c=Object.create(s.prototype);return c.implicit=(this.implicit||[]).concat(n),c.explicit=(this.explicit||[]).concat(l),c.compiledImplicit=r(c,"implicit"),c.compiledExplicit=r(c,"explicit"),c.compiledTypeMap=i(c.compiledImplicit,c.compiledExplicit),c},"extend"),ao=s,ao}p(Sl,"requireSchema");var oo,Gc;function Tl(){if(Gc)return oo;Gc=1;const e=re();return oo=new e("tag:yaml.org,2002:str",{kind:"scalar",construct:p(function(t){return t!==null?t:""},"construct")}),oo}p(Tl,"requireStr");var no,Vc;function _l(){if(Vc)return no;Vc=1;const e=re();return no=new e("tag:yaml.org,2002:seq",{kind:"sequence",construct:p(function(t){return t!==null?t:[]},"construct")}),no}p(_l,"requireSeq");var lo,Zc;function Bl(){if(Zc)return lo;Zc=1;const e=re();return lo=new e("tag:yaml.org,2002:map",{kind:"mapping",construct:p(function(t){return t!==null?t:{}},"construct")}),lo}p(Bl,"requireMap");var ho,Kc;function vl(){if(Kc)return ho;Kc=1;const e=Sl();return ho=new e({explicit:[Tl(),_l(),Bl()]}),ho}p(vl,"requireFailsafe");var co,Qc;function Ll(){if(Qc)return co;Qc=1;const e=re();function t(s){if(s===null)return!0;const a=s.length;return a===1&&s==="~"||a===4&&(s==="null"||s==="Null"||s==="NULL")}p(t,"resolveYamlNull");function r(){return null}p(r,"constructYamlNull");function i(s){return s===null}return p(i,"isNull"),co=new e("tag:yaml.org,2002:null",{kind:"scalar",resolve:t,construct:r,predicate:i,represent:{canonical:p(function(){return"~"},"canonical"),lowercase:p(function(){return"null"},"lowercase"),uppercase:p(function(){return"NULL"},"uppercase"),camelcase:p(function(){return"Null"},"camelcase"),empty:p(function(){return""},"empty")},defaultStyle:"lowercase"}),co}p(Ll,"require_null");var uo,Jc;function Fl(){if(Jc)return uo;Jc=1;const e=re();function t(s){if(s===null)return!1;const a=s.length;return a===4&&(s==="true"||s==="True"||s==="TRUE")||a===5&&(s==="false"||s==="False"||s==="FALSE")}p(t,"resolveYamlBoolean");function r(s){return s==="true"||s==="True"||s==="TRUE"}p(r,"constructYamlBoolean");function i(s){return Object.prototype.toString.call(s)==="[object Boolean]"}return p(i,"isBoolean"),uo=new e("tag:yaml.org,2002:bool",{kind:"scalar",resolve:t,construct:r,predicate:i,represent:{lowercase:p(function(s){return s?"true":"false"},"lowercase"),uppercase:p(function(s){return s?"TRUE":"FALSE"},"uppercase"),camelcase:p(function(s){return s?"True":"False"},"camelcase")},defaultStyle:"lowercase"}),uo}p(Fl,"requireBool");var fo,tu;function Ml(){if(tu)return fo;tu=1;const e=di(),t=re();function r(c){return c>=48&&c<=57||c>=65&&c<=70||c>=97&&c<=102}p(r,"isHexCode");function i(c){return c>=48&&c<=55}p(i,"isOctCode");function s(c){return c>=48&&c<=57}p(s,"isDecCode");function a(c){if(c===null)return!1;const h=c.length;let u=0,d=!1;if(!h)return!1;let f=c[u];if((f==="-"||f==="+")&&(f=c[++u]),f==="0"){if(u+1===h)return!0;if(f=c[++u],f==="b"){for(u++;u<h;u++){if(f=c[u],f!=="0"&&f!=="1")return!1;d=!0}return d&&isFinite(o(c))}if(f==="x"){for(u++;u<h;u++){if(!r(c.charCodeAt(u)))return!1;d=!0}return d&&isFinite(o(c))}if(f==="o"){for(u++;u<h;u++){if(!i(c.charCodeAt(u)))return!1;d=!0}return d&&isFinite(o(c))}}for(;u<h;u++){if(!s(c.charCodeAt(u)))return!1;d=!0}return d?isFinite(o(c)):!1}p(a,"resolveYamlInteger");function o(c){let h=c,u=1,d=h[0];if((d==="-"||d==="+")&&(d==="-"&&(u=-1),h=h.slice(1),d=h[0]),h==="0")return 0;if(d==="0"){if(h[1]==="b")return u*parseInt(h.slice(2),2);if(h[1]==="x")return u*parseInt(h.slice(2),16);if(h[1]==="o")return u*parseInt(h.slice(2),8)}return u*parseInt(h,10)}p(o,"parseYamlInteger");function n(c){return o(c)}p(n,"constructYamlInteger");function l(c){return Object.prototype.toString.call(c)==="[object Number]"&&c%1===0&&!e.isNegativeZero(c)}return p(l,"isInteger"),fo=new t("tag:yaml.org,2002:int",{kind:"scalar",resolve:a,construct:n,predicate:l,represent:{binary:p(function(c){return c>=0?"0b"+c.toString(2):"-0b"+c.toString(2).slice(1)},"binary"),octal:p(function(c){return c>=0?"0o"+c.toString(8):"-0o"+c.toString(8).slice(1)},"octal"),decimal:p(function(c){return c.toString(10)},"decimal"),hexadecimal:p(function(c){return c>=0?"0x"+c.toString(16).toUpperCase():"-0x"+c.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),fo}p(Ml,"requireInt");var po,eu;function Al(){if(eu)return po;eu=1;const e=di(),t=re(),r=new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),i=new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function s(c){return c===null||!r.test(c)?!1:isFinite(parseFloat(c,10))?!0:i.test(c)}p(s,"resolveYamlFloat");function a(c){let h=c.toLowerCase();const u=h[0]==="-"?-1:1;return"+-".indexOf(h[0])>=0&&(h=h.slice(1)),h===".inf"?u===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:h===".nan"?NaN:u*parseFloat(h,10)}p(a,"constructYamlFloat");const o=/^[-+]?[0-9]+e/;function n(c,h){if(isNaN(c))switch(h){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===c)switch(h){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===c)switch(h){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(e.isNegativeZero(c))return"-0.0";const u=c.toString(10);return o.test(u)?u.replace("e",".e"):u}p(n,"representYamlFloat");function l(c){return Object.prototype.toString.call(c)==="[object Number]"&&(c%1!==0||e.isNegativeZero(c))}return p(l,"isFloat"),po=new t("tag:yaml.org,2002:float",{kind:"scalar",resolve:s,construct:a,predicate:l,represent:n,defaultStyle:"lowercase"}),po}p(Al,"requireFloat");var go,ru;function El(){return ru||(ru=1,go=vl().extend({implicit:[Ll(),Fl(),Ml(),Al()]})),go}p(El,"requireJson");var yo,iu;function $l(){return iu||(iu=1,yo=El()),yo}p($l,"requireCore");var mo,su;function Ol(){if(su)return mo;su=1;const e=re(),t=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),r=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function i(o){return o===null?!1:t.exec(o)!==null||r.exec(o)!==null}p(i,"resolveYamlTimestamp");function s(o){let n=0,l=null,c=t.exec(o);if(c===null&&(c=r.exec(o)),c===null)throw new Error("Date resolve error");const h=+c[1],u=+c[2]-1,d=+c[3];if(!c[4])return new Date(Date.UTC(h,u,d));const f=+c[4],y=+c[5],m=+c[6];if(c[7]){for(n=c[7].slice(0,3);n.length<3;)n+="0";n=+n}if(c[9]){const x=+c[10],k=+(c[11]||0);l=(x*60+k)*6e4,c[9]==="-"&&(l=-l)}const C=new Date(Date.UTC(h,u,d,f,y,m,n));return l&&C.setTime(C.getTime()-l),C}p(s,"constructYamlTimestamp");function a(o){return o.toISOString()}return p(a,"representYamlTimestamp"),mo=new e("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:i,construct:s,instanceOf:Date,represent:a}),mo}p(Ol,"requireTimestamp");var xo,au;function Dl(){if(au)return xo;au=1;const e=re();function t(r){return r==="<<"||r===null}return p(t,"resolveYamlMerge"),xo=new e("tag:yaml.org,2002:merge",{kind:"scalar",resolve:t}),xo}p(Dl,"requireMerge");var Co,ou;function Pl(){if(ou)return Co;ou=1;const e=re(),t=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
275
+ \r`;function r(o){if(o===null)return!1;let n=0;const l=o.length,c=t;for(let h=0;h<l;h++){const u=c.indexOf(o.charAt(h));if(!(u>64)){if(u<0)return!1;n+=6}}return n%8===0}p(r,"resolveYamlBinary");function i(o){const n=o.replace(/[\r\n=]/g,""),l=n.length,c=t;let h=0;const u=[];for(let f=0;f<l;f++)f%4===0&&f&&(u.push(h>>16&255),u.push(h>>8&255),u.push(h&255)),h=h<<6|c.indexOf(n.charAt(f));const d=l%4*6;return d===0?(u.push(h>>16&255),u.push(h>>8&255),u.push(h&255)):d===18?(u.push(h>>10&255),u.push(h>>2&255)):d===12&&u.push(h>>4&255),new Uint8Array(u)}p(i,"constructYamlBinary");function s(o){let n="",l=0;const c=o.length,h=t;for(let d=0;d<c;d++)d%3===0&&d&&(n+=h[l>>18&63],n+=h[l>>12&63],n+=h[l>>6&63],n+=h[l&63]),l=(l<<8)+o[d];const u=c%3;return u===0?(n+=h[l>>18&63],n+=h[l>>12&63],n+=h[l>>6&63],n+=h[l&63]):u===2?(n+=h[l>>10&63],n+=h[l>>4&63],n+=h[l<<2&63],n+=h[64]):u===1&&(n+=h[l>>2&63],n+=h[l<<4&63],n+=h[64],n+=h[64]),n}p(s,"representYamlBinary");function a(o){return Object.prototype.toString.call(o)==="[object Uint8Array]"}return p(a,"isBinary"),Co=new e("tag:yaml.org,2002:binary",{kind:"scalar",resolve:r,construct:i,predicate:a,represent:s}),Co}p(Pl,"requireBinary");var bo,nu;function Il(){if(nu)return bo;nu=1;const e=re(),t=Object.prototype.hasOwnProperty,r=Object.prototype.toString;function i(a){if(a===null)return!0;const o=[],n=a;for(let l=0,c=n.length;l<c;l+=1){const h=n[l];let u=!1;if(r.call(h)!=="[object Object]")return!1;let d;for(d in h)if(t.call(h,d))if(!u)u=!0;else return!1;if(!u)return!1;if(o.indexOf(d)===-1)o.push(d);else return!1}return!0}p(i,"resolveYamlOmap");function s(a){return a!==null?a:[]}return p(s,"constructYamlOmap"),bo=new e("tag:yaml.org,2002:omap",{kind:"sequence",resolve:i,construct:s}),bo}p(Il,"requireOmap");var ko,lu;function Rl(){if(lu)return ko;lu=1;const e=re(),t=Object.prototype.toString;function r(s){if(s===null)return!0;const a=s,o=new Array(a.length);for(let n=0,l=a.length;n<l;n+=1){const c=a[n];if(t.call(c)!=="[object Object]")return!1;const h=Object.keys(c);if(h.length!==1)return!1;o[n]=[h[0],c[h[0]]]}return!0}p(r,"resolveYamlPairs");function i(s){if(s===null)return[];const a=s,o=new Array(a.length);for(let n=0,l=a.length;n<l;n+=1){const c=a[n],h=Object.keys(c);o[n]=[h[0],c[h[0]]]}return o}return p(i,"constructYamlPairs"),ko=new e("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:r,construct:i}),ko}p(Rl,"requirePairs");var wo,hu;function ql(){if(hu)return wo;hu=1;const e=re(),t=Object.prototype.hasOwnProperty;function r(s){if(s===null)return!0;const a=s;for(const o in a)if(t.call(a,o)&&a[o]!==null)return!1;return!0}p(r,"resolveYamlSet");function i(s){return s!==null?s:{}}return p(i,"constructYamlSet"),wo=new e("tag:yaml.org,2002:set",{kind:"mapping",resolve:r,construct:i}),wo}p(ql,"requireSet");var So,cu;function Ea(){return cu||(cu=1,So=$l().extend({implicit:[Ol(),Dl()],explicit:[Pl(),Il(),Rl(),ql()]})),So}p(Ea,"require_default");var uu;function Qg(){if(uu)return Ts;uu=1;const e=di(),t=fi(),r=Kg(),i=Ea(),s=Object.prototype.hasOwnProperty,a=1,o=2,n=3,l=4,c=1,h=2,u=3,d=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,f=/[\x85\u2028\u2029]/,y=/[,\[\]{}]/,m=/^(?:!|!!|![0-9A-Za-z-]+!)$/,C=/^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;function x(g){return Object.prototype.toString.call(g)}p(x,"_class");function k(g){return g===10||g===13}p(k,"isEol");function w(g){return g===9||g===32}p(w,"isWhiteSpace");function T(g){return g===9||g===32||g===10||g===13}p(T,"isWsOrEol");function _(g){return g===44||g===91||g===93||g===123||g===125}p(_,"isFlowIndicator");function v(g){if(g>=48&&g<=57)return g-48;const O=g|32;return O>=97&&O<=102?O-97+10:-1}p(v,"fromHexCode");function F(g){return g===120?2:g===117?4:g===85?8:0}p(F,"escapedHexLen");function L(g){return g>=48&&g<=57?g-48:-1}p(L,"fromDecimalCode");function U(g){switch(g){case 48:return"\0";case 97:return"\x07";case 98:return"\b";case 116:return" ";case 9:return" ";case 110:return`
276
+ `;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"…";case 95:return" ";case 76:return"\u2028";case 80:return"\u2029";default:return""}}p(U,"simpleEscapeSequence");function W(g){return g<=65535?String.fromCharCode(g):String.fromCharCode((g-65536>>10)+55296,(g-65536&1023)+56320)}p(W,"charFromCodepoint");function q(g,O,X){O==="__proto__"?Object.defineProperty(g,O,{configurable:!0,enumerable:!0,writable:!0,value:X}):g[O]=X}p(q,"setProperty");const rt=new Array(256),Y=new Array(256);for(let g=0;g<256;g++)rt[g]=U(g)?1:0,Y[g]=U(g);function A(g,O){this.input=g,this.filename=O.filename||null,this.schema=O.schema||i,this.onWarning=O.onWarning||null,this.legacy=O.legacy||!1,this.json=O.json||!1,this.listener=O.listener||null,this.maxDepth=typeof O.maxDepth=="number"?O.maxDepth:100,this.maxTotalMergeKeys=typeof O.maxTotalMergeKeys=="number"?O.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=g.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}p(A,"State");function E(g,O){const X={name:g.filename,buffer:g.input.slice(0,-1),position:g.position,line:g.line,column:g.position-g.lineStart};return X.snippet=r(X),new t(O,X)}p(E,"generateError");function B(g,O){throw E(g,O)}p(B,"throwError");function D(g,O){g.onWarning&&g.onWarning.call(null,E(g,O))}p(D,"throwWarning");function $(g,O,X){const K=g.anchorMapTransactions;if(K.length!==0){const j=K[K.length-1];s.call(j,O)||(j[O]={existed:s.call(g.anchorMap,O),value:g.anchorMap[O]})}g.anchorMap[O]=X}p($,"storeAnchor");function N(g){g.anchorMapTransactions.push(Object.create(null))}p(N,"beginAnchorTransaction");function V(g){const O=g.anchorMapTransactions.pop(),X=g.anchorMapTransactions;if(X.length===0)return;const K=X[X.length-1],j=Object.keys(O);for(let et=0,S=j.length;et<S;et+=1){const P=j[et];s.call(K,P)||(K[P]=O[P])}}p(V,"commitAnchorTransaction");function at(g){const O=g.anchorMapTransactions.pop(),X=Object.keys(O);for(let K=X.length-1;K>=0;K-=1){const j=O[X[K]];j.existed?g.anchorMap[X[K]]=j.value:delete g.anchorMap[X[K]]}}p(at,"rollbackAnchorTransaction");function ht(g){return{position:g.position,line:g.line,lineStart:g.lineStart,lineIndent:g.lineIndent,firstTabInLine:g.firstTabInLine,tag:g.tag,anchor:g.anchor,kind:g.kind,result:g.result}}p(ht,"snapshotState");function pt(g,O){g.position=O.position,g.line=O.line,g.lineStart=O.lineStart,g.lineIndent=O.lineIndent,g.firstTabInLine=O.firstTabInLine,g.tag=O.tag,g.anchor=O.anchor,g.kind=O.kind,g.result=O.result}p(pt,"restoreState");const yt={YAML:p(function(O,X,K){O.version!==null&&B(O,"duplication of %YAML directive"),K.length!==1&&B(O,"YAML directive accepts exactly one argument");const j=/^([0-9]+)\.([0-9]+)$/.exec(K[0]);j===null&&B(O,"ill-formed argument of the YAML directive");const et=parseInt(j[1],10),S=parseInt(j[2],10);et!==1&&B(O,"unacceptable YAML version of the document"),O.version=K[0],O.checkLineBreaks=S<2,S!==1&&S!==2&&D(O,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:p(function(O,X,K){let j;K.length!==2&&B(O,"TAG directive accepts exactly two arguments");const et=K[0];j=K[1],m.test(et)||B(O,"ill-formed tag handle (first argument) of the TAG directive"),s.call(O.tagMap,et)&&B(O,'there is a previously declared suffix for "'+et+'" tag handle'),C.test(j)||B(O,"ill-formed tag prefix (second argument) of the TAG directive");try{j=decodeURIComponent(j)}catch{B(O,"tag prefix is malformed: "+j)}O.tagMap[et]=j},"handleTagDirective")};function gt(g,O,X,K){if(O<X){const j=g.input.slice(O,X);if(K)for(let et=0,S=j.length;et<S;et+=1){const P=j.charCodeAt(et);P===9||P>=32&&P<=1114111||B(g,"expected valid JSON character")}else d.test(j)&&B(g,"the stream contains non-printable characters");g.result+=j}}p(gt,"captureSegment");function _t(g,O,X,K){e.isObject(X)||B(g,"cannot merge mappings; the provided source object is unacceptable");const j=Object.keys(X);for(let et=0,S=j.length;et<S;et+=1){const P=j[et];g.maxTotalMergeKeys!==-1&&++g.totalMergeKeys>g.maxTotalMergeKeys&&B(g,"merge keys exceeded maxTotalMergeKeys ("+g.maxTotalMergeKeys+")"),s.call(O,P)||(q(O,P,X[P]),K[P]=!0)}}p(_t,"mergeMappings");function wt(g,O,X,K,j,et,S,P,J){if(Array.isArray(j)){j=Array.prototype.slice.call(j);for(let G=0,Z=j.length;G<Z;G+=1)Array.isArray(j[G])&&B(g,"nested arrays are not supported inside keys"),typeof j=="object"&&x(j[G])==="[object Object]"&&(j[G]="[object Object]")}if(typeof j=="object"&&x(j)==="[object Object]"&&(j="[object Object]"),j=String(j),O===null&&(O={}),K==="tag:yaml.org,2002:merge")if(Array.isArray(et))for(let G=0,Z=et.length;G<Z;G+=1)_t(g,O,et[G],X);else _t(g,O,et,X);else!g.json&&!s.call(X,j)&&s.call(O,j)&&(g.line=S||g.line,g.lineStart=P||g.lineStart,g.position=J||g.position,B(g,"duplicated mapping key")),q(O,j,et),delete X[j];return O}p(wt,"storeMappingPair");function Et(g){const O=g.input.charCodeAt(g.position);O===10?g.position++:O===13?(g.position++,g.input.charCodeAt(g.position)===10&&g.position++):B(g,"a line break is expected"),g.line+=1,g.lineStart=g.position,g.firstTabInLine=-1}p(Et,"readLineBreak");function bt(g,O,X){let K=0,j=g.input.charCodeAt(g.position);for(;j!==0;){for(;w(j);)j===9&&g.firstTabInLine===-1&&(g.firstTabInLine=g.position),j=g.input.charCodeAt(++g.position);if(O&&j===35)do j=g.input.charCodeAt(++g.position);while(j!==10&&j!==13&&j!==0);if(k(j))for(Et(g),j=g.input.charCodeAt(g.position),K++,g.lineIndent=0;j===32;)g.lineIndent++,j=g.input.charCodeAt(++g.position);else break}return X!==-1&&K!==0&&g.lineIndent<X&&D(g,"deficient indentation"),K}p(bt,"skipSeparationSpace");function it(g){let O=g.position,X=g.input.charCodeAt(O);return!!((X===45||X===46)&&X===g.input.charCodeAt(O+1)&&X===g.input.charCodeAt(O+2)&&(O+=3,X=g.input.charCodeAt(O),X===0||T(X)))}p(it,"testDocumentSeparator");function ut(g,O){O===1?g.result+=" ":O>1&&(g.result+=e.repeat(`
277
+ `,O-1))}p(ut,"writeFoldedLines");function Bt(g,O,X){let K,j,et,S,P,J;const G=g.kind,Z=g.result;let tt=g.input.charCodeAt(g.position);if(T(tt)||_(tt)||tt===35||tt===38||tt===42||tt===33||tt===124||tt===62||tt===39||tt===34||tt===37||tt===64||tt===96)return!1;if(tt===63||tt===45){const Q=g.input.charCodeAt(g.position+1);if(T(Q)||X&&_(Q))return!1}for(g.kind="scalar",g.result="",K=j=g.position,et=!1;tt!==0;){if(tt===58){const Q=g.input.charCodeAt(g.position+1);if(T(Q)||X&&_(Q))break}else if(tt===35){const Q=g.input.charCodeAt(g.position-1);if(T(Q))break}else{if(g.position===g.lineStart&&it(g)||X&&_(tt))break;if(k(tt))if(S=g.line,P=g.lineStart,J=g.lineIndent,bt(g,!1,-1),g.lineIndent>=O){et=!0,tt=g.input.charCodeAt(g.position);continue}else{g.position=j,g.line=S,g.lineStart=P,g.lineIndent=J;break}}et&&(gt(g,K,j,!1),ut(g,g.line-S),K=j=g.position,et=!1),w(tt)||(j=g.position+1),tt=g.input.charCodeAt(++g.position)}return gt(g,K,j,!1),g.result?!0:(g.kind=G,g.result=Z,!1)}p(Bt,"readPlainScalar");function Mt(g,O){let X,K,j=g.input.charCodeAt(g.position);if(j!==39)return!1;for(g.kind="scalar",g.result="",g.position++,X=K=g.position;(j=g.input.charCodeAt(g.position))!==0;)if(j===39)if(gt(g,X,g.position,!0),j=g.input.charCodeAt(++g.position),j===39)X=g.position,g.position++,K=g.position;else return!0;else k(j)?(gt(g,X,K,!0),ut(g,bt(g,!1,O)),X=K=g.position):g.position===g.lineStart&&it(g)?B(g,"unexpected end of the document within a single quoted scalar"):(g.position++,w(j)||(K=g.position));B(g,"unexpected end of the stream within a single quoted scalar")}p(Mt,"readSingleQuotedScalar");function Rt(g,O){let X,K,j,et=g.input.charCodeAt(g.position);if(et!==34)return!1;for(g.kind="scalar",g.result="",g.position++,X=K=g.position;(et=g.input.charCodeAt(g.position))!==0;){if(et===34)return gt(g,X,g.position,!0),g.position++,!0;if(et===92){if(gt(g,X,g.position,!0),et=g.input.charCodeAt(++g.position),k(et))bt(g,!1,O);else if(et<256&&rt[et])g.result+=Y[et],g.position++;else if((j=F(et))>0){let S=j,P=0;for(;S>0;S--)et=g.input.charCodeAt(++g.position),(j=v(et))>=0?P=(P<<4)+j:B(g,"expected hexadecimal character");g.result+=W(P),g.position++}else B(g,"unknown escape sequence");X=K=g.position}else k(et)?(gt(g,X,K,!0),ut(g,bt(g,!1,O)),X=K=g.position):g.position===g.lineStart&&it(g)?B(g,"unexpected end of the document within a double quoted scalar"):(g.position++,w(et)||(K=g.position))}B(g,"unexpected end of the stream within a double quoted scalar")}p(Rt,"readDoubleQuotedScalar");function R(g,O){let X=!0,K,j,et;const S=g.tag;let P;const J=g.anchor;let G,Z,tt,Q;const ft=Object.create(null);let lt,Ct,kt,$t=g.input.charCodeAt(g.position);if($t===91)G=93,Q=!1,P=[];else if($t===123)G=125,Q=!0,P={};else return!1;for(g.anchor!==null&&$(g,g.anchor,P),$t=g.input.charCodeAt(++g.position);$t!==0;){if(bt(g,!0,O),$t=g.input.charCodeAt(g.position),$t===G)return g.position++,g.tag=S,g.anchor=J,g.kind=Q?"mapping":"sequence",g.result=P,!0;if(X?$t===44&&B(g,"expected the node content, but found ','"):B(g,"missed comma between flow collection entries"),Ct=lt=kt=null,Z=tt=!1,$t===63){const Nt=g.input.charCodeAt(g.position+1);T(Nt)&&(Z=tt=!0,g.position++,bt(g,!0,O))}K=g.line,j=g.lineStart,et=g.position,ye(g,O,a,!1,!0),Ct=g.tag,lt=g.result,bt(g,!0,O),$t=g.input.charCodeAt(g.position),(tt||g.line===K)&&$t===58&&(Z=!0,$t=g.input.charCodeAt(++g.position),bt(g,!0,O),ye(g,O,a,!1,!0),kt=g.result),Q?wt(g,P,ft,Ct,lt,kt,K,j,et):Z?P.push(wt(g,null,ft,Ct,lt,kt,K,j,et)):P.push(lt),bt(g,!0,O),$t=g.input.charCodeAt(g.position),$t===44?(X=!0,$t=g.input.charCodeAt(++g.position)):X=!1}B(g,"unexpected end of the stream within a flow collection")}p(R,"readFlowCollection");function vt(g,O){let X,K=c,j=!1,et=!1,S=O,P=0,J=!1,G,Z=g.input.charCodeAt(g.position);if(Z===124)X=!1;else if(Z===62)X=!0;else return!1;for(g.kind="scalar",g.result="";Z!==0;)if(Z=g.input.charCodeAt(++g.position),Z===43||Z===45)c===K?K=Z===43?u:h:B(g,"repeat of a chomping mode identifier");else if((G=L(Z))>=0)G===0?B(g,"bad explicit indentation width of a block scalar; it cannot be less than one"):et?B(g,"repeat of an indentation width identifier"):(S=O+G-1,et=!0);else break;if(w(Z)){do Z=g.input.charCodeAt(++g.position);while(w(Z));if(Z===35)do Z=g.input.charCodeAt(++g.position);while(!k(Z)&&Z!==0)}for(;Z!==0;){for(Et(g),g.lineIndent=0,Z=g.input.charCodeAt(g.position);(!et||g.lineIndent<S)&&Z===32;)g.lineIndent++,Z=g.input.charCodeAt(++g.position);if(!et&&g.lineIndent>S&&(S=g.lineIndent),k(Z)){P++;continue}if(!et&&S===0&&B(g,"missing indentation for block scalar"),g.lineIndent<S){K===u?g.result+=e.repeat(`
278
+ `,j?1+P:P):K===c&&j&&(g.result+=`
279
+ `);break}X?w(Z)?(J=!0,g.result+=e.repeat(`
280
+ `,j?1+P:P)):J?(J=!1,g.result+=e.repeat(`
281
+ `,P+1)):P===0?j&&(g.result+=" "):g.result+=e.repeat(`
282
+ `,P):g.result+=e.repeat(`
283
+ `,j?1+P:P),j=!0,et=!0,P=0;const tt=g.position;for(;!k(Z)&&Z!==0;)Z=g.input.charCodeAt(++g.position);gt(g,tt,g.position,!1)}return!0}p(vt,"readBlockScalar");function ge(g,O){const X=g.tag,K=g.anchor,j=[];let et=!1;if(g.firstTabInLine!==-1)return!1;g.anchor!==null&&$(g,g.anchor,j);let S=g.input.charCodeAt(g.position);for(;S!==0&&(g.firstTabInLine!==-1&&(g.position=g.firstTabInLine,B(g,"tab characters must not be used in indentation")),S===45);){const P=g.input.charCodeAt(g.position+1);if(!T(P))break;if(et=!0,g.position++,bt(g,!0,-1)&&g.lineIndent<=O){j.push(null),S=g.input.charCodeAt(g.position);continue}const J=g.line;if(ye(g,O,n,!1,!0),j.push(g.result),bt(g,!0,-1),S=g.input.charCodeAt(g.position),(g.line===J||g.lineIndent>O)&&S!==0)B(g,"bad indentation of a sequence entry");else if(g.lineIndent<O)break}return et?(g.tag=X,g.anchor=K,g.kind="sequence",g.result=j,!0):!1}p(ge,"readBlockSequence");function _e(g,O,X){let K,j,et,S;const P=g.tag,J=g.anchor,G={},Z=Object.create(null);let tt=null,Q=null,ft=null,lt=!1,Ct=!1;if(g.firstTabInLine!==-1)return!1;g.anchor!==null&&$(g,g.anchor,G);let kt=g.input.charCodeAt(g.position);for(;kt!==0;){!lt&&g.firstTabInLine!==-1&&(g.position=g.firstTabInLine,B(g,"tab characters must not be used in indentation"));const $t=g.input.charCodeAt(g.position+1),Nt=g.line;if((kt===63||kt===58)&&T($t))kt===63?(lt&&(wt(g,G,Z,tt,Q,null,j,et,S),tt=Q=ft=null),Ct=!0,lt=!0,K=!0):lt?(lt=!1,K=!0):B(g,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),g.position+=1,kt=$t;else{if(j=g.line,et=g.lineStart,S=g.position,!ye(g,X,o,!1,!0))break;if(g.line===Nt){for(kt=g.input.charCodeAt(g.position);w(kt);)kt=g.input.charCodeAt(++g.position);if(kt===58)kt=g.input.charCodeAt(++g.position),T(kt)||B(g,"a whitespace character is expected after the key-value separator within a block mapping"),lt&&(wt(g,G,Z,tt,Q,null,j,et,S),tt=Q=ft=null),Ct=!0,lt=!1,K=!1,tt=g.tag,Q=g.result;else if(Ct)B(g,"can not read an implicit mapping pair; a colon is missed");else return g.tag=P,g.anchor=J,!0}else if(Ct)B(g,"can not read a block mapping entry; a multiline key may not be an implicit key");else return g.tag=P,g.anchor=J,!0}if((g.line===Nt||g.lineIndent>O)&&(lt&&(j=g.line,et=g.lineStart,S=g.position),ye(g,O,l,!0,K)&&(lt?Q=g.result:ft=g.result),lt||(wt(g,G,Z,tt,Q,ft,j,et,S),tt=Q=ft=null),bt(g,!0,-1),kt=g.input.charCodeAt(g.position)),(g.line===Nt||g.lineIndent>O)&&kt!==0)B(g,"bad indentation of a mapping entry");else if(g.lineIndent<O)break}return lt&&wt(g,G,Z,tt,Q,null,j,et,S),Ct&&(g.tag=P,g.anchor=J,g.kind="mapping",g.result=G),Ct}p(_e,"readBlockMapping");function gi(g){let O=!1,X=!1,K,j,et=g.input.charCodeAt(g.position);if(et!==33)return!1;g.tag!==null&&B(g,"duplication of a tag property"),et=g.input.charCodeAt(++g.position),et===60?(O=!0,et=g.input.charCodeAt(++g.position)):et===33?(X=!0,K="!!",et=g.input.charCodeAt(++g.position)):K="!";let S=g.position;if(O){do et=g.input.charCodeAt(++g.position);while(et!==0&&et!==62);g.position<g.length?(j=g.input.slice(S,g.position),et=g.input.charCodeAt(++g.position)):B(g,"unexpected end of the stream within a verbatim tag")}else{for(;et!==0&&!T(et);)et===33&&(X?B(g,"tag suffix cannot contain exclamation marks"):(K=g.input.slice(S-1,g.position+1),m.test(K)||B(g,"named tag handle cannot contain such characters"),X=!0,S=g.position+1)),et=g.input.charCodeAt(++g.position);j=g.input.slice(S,g.position),y.test(j)&&B(g,"tag suffix cannot contain flow indicator characters")}j&&!C.test(j)&&B(g,"tag name cannot contain such characters: "+j);try{j=decodeURIComponent(j)}catch{B(g,"tag name is malformed: "+j)}return O?g.tag=j:s.call(g.tagMap,K)?g.tag=g.tagMap[K]+j:K==="!"?g.tag="!"+j:K==="!!"?g.tag="tag:yaml.org,2002:"+j:B(g,'undeclared tag handle "'+K+'"'),!0}p(gi,"readTagProperty");function Br(g){let O=g.input.charCodeAt(g.position);if(O!==38)return!1;g.anchor!==null&&B(g,"duplication of an anchor property"),O=g.input.charCodeAt(++g.position);const X=g.position;for(;O!==0&&!T(O)&&!_(O);)O=g.input.charCodeAt(++g.position);return g.position===X&&B(g,"name of an anchor node must contain at least one character"),g.anchor=g.input.slice(X,g.position),!0}p(Br,"readAnchorProperty");function vr(g){let O=g.input.charCodeAt(g.position);if(O!==42)return!1;O=g.input.charCodeAt(++g.position);const X=g.position;for(;O!==0&&!T(O)&&!_(O);)O=g.input.charCodeAt(++g.position);g.position===X&&B(g,"name of an alias node must contain at least one character");const K=g.input.slice(X,g.position);return s.call(g.anchorMap,K)||B(g,'unidentified alias "'+K+'"'),g.result=g.anchorMap[K],bt(g,!0,-1),!0}p(vr,"readAlias");function yi(g,O,X,K){const j=ht(g);return N(g),pt(g,O),g.tag=null,g.anchor=null,g.kind=null,g.result=null,_e(g,X,K)&&g.kind==="mapping"?(V(g),!0):(at(g),pt(g,j),!1)}p(yi,"tryReadBlockMappingFromProperty");function ye(g,O,X,K,j){let et,S,P=1,J=!1,G=!1,Z=null,tt,Q,ft;g.depth>=g.maxDepth&&B(g,"nesting exceeded maxDepth ("+g.maxDepth+")"),g.depth+=1,g.listener!==null&&g.listener("open",g),g.tag=null,g.anchor=null,g.kind=null,g.result=null;const lt=et=S=l===X||n===X;if(K&&bt(g,!0,-1)&&(J=!0,g.lineIndent>O?P=1:g.lineIndent===O?P=0:g.lineIndent<O&&(P=-1)),P===1)for(;;){const Ct=g.input.charCodeAt(g.position),kt=ht(g);if(J&&(Ct===33&&g.tag!==null||Ct===38&&g.anchor!==null)||!gi(g)&&!Br(g))break;Z===null&&(Z=kt),bt(g,!0,-1)?(J=!0,S=lt,g.lineIndent>O?P=1:g.lineIndent===O?P=0:g.lineIndent<O&&(P=-1)):S=!1}if(S&&(S=J||j),P===1||l===X)if(a===X||o===X?Q=O:Q=O+1,ft=g.position-g.lineStart,P===1)if(S&&(ge(g,ft)||_e(g,ft,Q))||R(g,Q))G=!0;else{const Ct=g.input.charCodeAt(g.position);Z!==null&&lt&&!S&&Ct!==124&&Ct!==62&&yi(g,Z,Z.position-Z.lineStart,Q)||et&&vt(g,Q)||Mt(g,Q)||Rt(g,Q)?G=!0:vr(g)?(G=!0,(g.tag!==null||g.anchor!==null)&&B(g,"alias node should not have any properties")):Bt(g,Q,a===X)&&(G=!0,g.tag===null&&(g.tag="?")),g.anchor!==null&&$(g,g.anchor,g.result)}else P===0&&(G=S&&ge(g,ft));if(g.tag===null)g.anchor!==null&&$(g,g.anchor,g.result);else if(g.tag==="?"){g.result!==null&&g.kind!=="scalar"&&B(g,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+g.kind+'"');for(let Ct=0,kt=g.implicitTypes.length;Ct<kt;Ct+=1)if(tt=g.implicitTypes[Ct],tt.resolve(g.result)){g.result=tt.construct(g.result),g.tag=tt.tag,g.anchor!==null&&$(g,g.anchor,g.result);break}}else if(g.tag!=="!"){if(s.call(g.typeMap[g.kind||"fallback"],g.tag))tt=g.typeMap[g.kind||"fallback"][g.tag];else{tt=null;const Ct=g.typeMap.multi[g.kind||"fallback"];for(let kt=0,$t=Ct.length;kt<$t;kt+=1)if(g.tag.slice(0,Ct[kt].tag.length)===Ct[kt].tag){tt=Ct[kt];break}}tt||B(g,"unknown tag !<"+g.tag+">"),g.result!==null&&tt.kind!==g.kind&&B(g,"unacceptable node kind for !<"+g.tag+'> tag; it should be "'+tt.kind+'", not "'+g.kind+'"'),tt.resolve(g.result,g.tag)?(g.result=tt.construct(g.result,g.tag),g.anchor!==null&&$(g,g.anchor,g.result)):B(g,"cannot resolve a node with !<"+g.tag+"> explicit tag")}return g.listener!==null&&g.listener("close",g),g.depth-=1,g.tag!==null||g.anchor!==null||G}p(ye,"composeNode");function mi(g){const O=g.position;let X=!1,K;for(g.version=null,g.checkLineBreaks=g.legacy,g.tagMap=Object.create(null),g.anchorMap=Object.create(null);(K=g.input.charCodeAt(g.position))!==0&&(bt(g,!0,-1),K=g.input.charCodeAt(g.position),!(g.lineIndent>0||K!==37));){X=!0,K=g.input.charCodeAt(++g.position);let j=g.position;for(;K!==0&&!T(K);)K=g.input.charCodeAt(++g.position);const et=g.input.slice(j,g.position),S=[];for(et.length<1&&B(g,"directive name must not be less than one character in length");K!==0;){for(;w(K);)K=g.input.charCodeAt(++g.position);if(K===35){do K=g.input.charCodeAt(++g.position);while(K!==0&&!k(K));break}if(k(K))break;for(j=g.position;K!==0&&!T(K);)K=g.input.charCodeAt(++g.position);S.push(g.input.slice(j,g.position))}K!==0&&Et(g),s.call(yt,et)?yt[et](g,et,S):D(g,'unknown document directive "'+et+'"')}if(bt(g,!0,-1),g.lineIndent===0&&g.input.charCodeAt(g.position)===45&&g.input.charCodeAt(g.position+1)===45&&g.input.charCodeAt(g.position+2)===45?(g.position+=3,bt(g,!0,-1)):X&&B(g,"directives end mark is expected"),ye(g,g.lineIndent-1,l,!1,!0),bt(g,!0,-1),g.checkLineBreaks&&f.test(g.input.slice(O,g.position))&&D(g,"non-ASCII line breaks are interpreted as content"),g.documents.push(g.result),g.position===g.lineStart&&it(g)){g.input.charCodeAt(g.position)===46&&(g.position+=3,bt(g,!0,-1));return}g.position<g.length-1&&B(g,"end of the stream or a document separator is expected")}p(mi,"readDocument");function Lr(g,O){g=String(g),O=O||{},g.length!==0&&(g.charCodeAt(g.length-1)!==10&&g.charCodeAt(g.length-1)!==13&&(g+=`
284
+ `),g.charCodeAt(0)===65279&&(g=g.slice(1)));const X=new A(g,O),K=g.indexOf("\0");for(K!==-1&&(X.position=K,B(X,"null byte is not allowed in input")),X.input+="\0";X.input.charCodeAt(X.position)===32;)X.lineIndent+=1,X.position+=1;for(;X.position<X.length-1;)mi(X);return X.documents}p(Lr,"loadDocuments");function Fr(g,O,X){O!==null&&typeof O=="object"&&typeof X>"u"&&(X=O,O=null);const K=Lr(g,X);if(typeof O!="function")return K;for(let j=0,et=K.length;j<et;j+=1)O(K[j])}p(Fr,"loadAll2");function xi(g,O){const X=Lr(g,O);if(X.length!==0){if(X.length===1)return X[0];throw new t("expected a single document in the stream, but found more")}}return p(xi,"load2"),Ts.loadAll=Fr,Ts.load=xi,Ts}p(Qg,"requireLoader");var To={},du;function Jg(){if(du)return To;du=1;const e=di(),t=fi(),r=Ea(),i=Object.prototype.toString,s=Object.prototype.hasOwnProperty,a=65279,o=9,n=10,l=13,c=32,h=33,u=34,d=35,f=37,y=38,m=39,C=42,x=44,k=45,w=58,T=61,_=62,v=63,F=64,L=91,U=93,W=96,q=123,rt=124,Y=125,A={};A[0]="\\0",A[7]="\\a",A[8]="\\b",A[9]="\\t",A[10]="\\n",A[11]="\\v",A[12]="\\f",A[13]="\\r",A[27]="\\e",A[34]='\\"',A[92]="\\\\",A[133]="\\N",A[160]="\\_",A[8232]="\\L",A[8233]="\\P";const E=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],B=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function D(S,P){if(P===null)return{};const J={},G=Object.keys(P);for(let Z=0,tt=G.length;Z<tt;Z+=1){let Q=G[Z],ft=String(P[Q]);Q.slice(0,2)==="!!"&&(Q="tag:yaml.org,2002:"+Q.slice(2));const lt=S.compiledTypeMap.fallback[Q];lt&&s.call(lt.styleAliases,ft)&&(ft=lt.styleAliases[ft]),J[Q]=ft}return J}p(D,"compileStyleMap");function $(S){let P,J;const G=S.toString(16).toUpperCase();if(S<=255)P="x",J=2;else if(S<=65535)P="u",J=4;else if(S<=4294967295)P="U",J=8;else throw new t("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+P+e.repeat("0",J-G.length)+G}p($,"encodeHex");const N=1,V=2;function at(S){this.schema=S.schema||r,this.indent=Math.max(1,S.indent||2),this.noArrayIndent=S.noArrayIndent||!1,this.skipInvalid=S.skipInvalid||!1,this.flowLevel=e.isNothing(S.flowLevel)?-1:S.flowLevel,this.styleMap=D(this.schema,S.styles||null),this.sortKeys=S.sortKeys||!1,this.lineWidth=S.lineWidth||80,this.noRefs=S.noRefs||!1,this.noCompatMode=S.noCompatMode||!1,this.condenseFlow=S.condenseFlow||!1,this.quotingType=S.quotingType==='"'?V:N,this.forceQuotes=S.forceQuotes||!1,this.replacer=typeof S.replacer=="function"?S.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}p(at,"State");function ht(S,P){const J=e.repeat(" ",P);let G=0,Z="";const tt=S.length;for(;G<tt;){let Q;const ft=S.indexOf(`
285
+ `,G);ft===-1?(Q=S.slice(G),G=tt):(Q=S.slice(G,ft+1),G=ft+1),Q.length&&Q!==`
286
+ `&&(Z+=J),Z+=Q}return Z}p(ht,"indentString");function pt(S,P){return`
287
+ `+e.repeat(" ",S.indent*P)}p(pt,"generateNextLine");function yt(S,P){for(let J=0,G=S.implicitTypes.length;J<G;J+=1)if(S.implicitTypes[J].resolve(P))return!0;return!1}p(yt,"testImplicitResolving");function gt(S){return S===c||S===o}p(gt,"isWhitespace");function _t(S){return S>=32&&S<=126||S>=161&&S<=55295&&S!==8232&&S!==8233||S>=57344&&S<=65533&&S!==a||S>=65536&&S<=1114111}p(_t,"isPrintable");function wt(S){return _t(S)&&S!==a&&S!==l&&S!==n}p(wt,"isNsCharOrWhitespace");function Et(S,P,J){const G=wt(S),Z=G&&!gt(S);return(J?G:G&&S!==x&&S!==L&&S!==U&&S!==q&&S!==Y)&&S!==d&&!(P===w&&!Z)||wt(P)&&!gt(P)&&S===d||P===w&&Z}p(Et,"isPlainSafe");function bt(S){return _t(S)&&S!==a&&!gt(S)&&S!==k&&S!==v&&S!==w&&S!==x&&S!==L&&S!==U&&S!==q&&S!==Y&&S!==d&&S!==y&&S!==C&&S!==h&&S!==rt&&S!==T&&S!==_&&S!==m&&S!==u&&S!==f&&S!==F&&S!==W}p(bt,"isPlainSafeFirst");function it(S){return!gt(S)&&S!==w}p(it,"isPlainSafeLast");function ut(S,P){const J=S.charCodeAt(P);let G;return J>=55296&&J<=56319&&P+1<S.length&&(G=S.charCodeAt(P+1),G>=56320&&G<=57343)?(J-55296)*1024+G-56320+65536:J}p(ut,"codePointAt");function Bt(S){return/^\n* /.test(S)}p(Bt,"needIndentIndicator");const Mt=1,Rt=2,R=3,vt=4,ge=5;function _e(S,P,J,G,Z,tt,Q,ft){let lt,Ct=0,kt=null,$t=!1,Nt=!1;const Yl=G!==-1;let Ci=-1,bi=bt(ut(S,0))&&it(ut(S,S.length-1));if(P||Q)for(lt=0;lt<S.length;Ct>=65536?lt+=2:lt++){if(Ct=ut(S,lt),!_t(Ct))return ge;bi=bi&&Et(Ct,kt,ft),kt=Ct}else{for(lt=0;lt<S.length;Ct>=65536?lt+=2:lt++){if(Ct=ut(S,lt),Ct===n)$t=!0,Yl&&(Nt=Nt||lt-Ci-1>G&&S[Ci+1]!==" ",Ci=lt);else if(!_t(Ct))return ge;bi=bi&&Et(Ct,kt,ft),kt=Ct}Nt=Nt||Yl&&lt-Ci-1>G&&S[Ci+1]!==" "}return!$t&&!Nt?bi&&!Q&&!Z(S)?Mt:tt===V?ge:Rt:J>9&&Bt(S)?ge:Q?tt===V?ge:Rt:Nt?vt:R}p(_e,"chooseScalarStyle");function gi(S,P,J,G,Z){S.dump=(function(){if(P.length===0)return S.quotingType===V?'""':"''";if(!S.noCompatMode&&(E.indexOf(P)!==-1||B.test(P)))return S.quotingType===V?'"'+P+'"':"'"+P+"'";const tt=S.indent*Math.max(1,J),Q=S.lineWidth===-1?-1:Math.max(Math.min(S.lineWidth,40),S.lineWidth-tt),ft=G||S.flowLevel>-1&&J>=S.flowLevel;function lt(Ct){return yt(S,Ct)}switch(p(lt,"testAmbiguity"),_e(P,ft,S.indent,Q,lt,S.quotingType,S.forceQuotes&&!G,Z)){case Mt:return P;case Rt:return"'"+P.replace(/'/g,"''")+"'";case R:return"|"+Br(P,S.indent)+vr(ht(P,tt));case vt:return">"+Br(P,S.indent)+vr(ht(yi(P,Q),tt));case ge:return'"'+mi(P)+'"';default:throw new t("impossible error: invalid scalar style")}})()}p(gi,"writeScalar");function Br(S,P){const J=Bt(S)?String(P):"",G=S[S.length-1]===`
288
+ `,tt=G&&(S[S.length-2]===`
289
+ `||S===`
290
+ `)?"+":G?"":"-";return J+tt+`
291
+ `}p(Br,"blockHeader");function vr(S){return S[S.length-1]===`
292
+ `?S.slice(0,-1):S}p(vr,"dropEndingNewline");function yi(S,P){const J=/(\n+)([^\n]*)/g;let G=(function(){let ft=S.indexOf(`
293
+ `);return ft=ft!==-1?ft:S.length,J.lastIndex=ft,ye(S.slice(0,ft),P)})(),Z=S[0]===`
294
+ `||S[0]===" ",tt,Q;for(;Q=J.exec(S);){const ft=Q[1],lt=Q[2];tt=lt[0]===" ",G+=ft+(!Z&&!tt&&lt!==""?`
295
+ `:"")+ye(lt,P),Z=tt}return G}p(yi,"foldString");function ye(S,P){if(S===""||S[0]===" ")return S;const J=/ [^ ]/g;let G,Z=0,tt,Q=0,ft=0,lt="";for(;G=J.exec(S);)ft=G.index,ft-Z>P&&(tt=Q>Z?Q:ft,lt+=`
296
+ `+S.slice(Z,tt),Z=tt+1),Q=ft;return lt+=`
297
+ `,S.length-Z>P&&Q>Z?lt+=S.slice(Z,Q)+`
298
+ `+S.slice(Q+1):lt+=S.slice(Z),lt.slice(1)}p(ye,"foldLine");function mi(S){let P="",J=0;for(let G=0;G<S.length;J>=65536?G+=2:G++){J=ut(S,G);const Z=A[J];!Z&&_t(J)?(P+=S[G],J>=65536&&(P+=S[G+1])):P+=Z||$(J)}return P}p(mi,"escapeString");function Lr(S,P,J){let G="";const Z=S.tag;for(let tt=0,Q=J.length;tt<Q;tt+=1){let ft=J[tt];S.replacer&&(ft=S.replacer.call(J,String(tt),ft)),(X(S,P,ft,!1,!1)||typeof ft>"u"&&X(S,P,null,!1,!1))&&(G!==""&&(G+=","+(S.condenseFlow?"":" ")),G+=S.dump)}S.tag=Z,S.dump="["+G+"]"}p(Lr,"writeFlowSequence");function Fr(S,P,J,G){let Z="";const tt=S.tag;for(let Q=0,ft=J.length;Q<ft;Q+=1){let lt=J[Q];S.replacer&&(lt=S.replacer.call(J,String(Q),lt)),(X(S,P+1,lt,!0,!0,!1,!0)||typeof lt>"u"&&X(S,P+1,null,!0,!0,!1,!0))&&((!G||Z!=="")&&(Z+=pt(S,P)),S.dump&&n===S.dump.charCodeAt(0)?Z+="-":Z+="- ",Z+=S.dump)}S.tag=tt,S.dump=Z||"[]"}p(Fr,"writeBlockSequence");function xi(S,P,J){let G="";const Z=S.tag,tt=Object.keys(J);for(let Q=0,ft=tt.length;Q<ft;Q+=1){let lt="";G!==""&&(lt+=", "),S.condenseFlow&&(lt+='"');const Ct=tt[Q];let kt=J[Ct];S.replacer&&(kt=S.replacer.call(J,Ct,kt)),X(S,P,Ct,!1,!1)&&(S.dump.length>1024&&(lt+="? "),lt+=S.dump+(S.condenseFlow?'"':"")+":"+(S.condenseFlow?"":" "),X(S,P,kt,!1,!1)&&(lt+=S.dump,G+=lt))}S.tag=Z,S.dump="{"+G+"}"}p(xi,"writeFlowMapping");function g(S,P,J,G){let Z="";const tt=S.tag,Q=Object.keys(J);if(S.sortKeys===!0)Q.sort();else if(typeof S.sortKeys=="function")Q.sort(S.sortKeys);else if(S.sortKeys)throw new t("sortKeys must be a boolean or a function");for(let ft=0,lt=Q.length;ft<lt;ft+=1){let Ct="";(!G||Z!=="")&&(Ct+=pt(S,P));const kt=Q[ft];let $t=J[kt];if(S.replacer&&($t=S.replacer.call(J,kt,$t)),!X(S,P+1,kt,!0,!0,!0))continue;const Nt=S.tag!==null&&S.tag!=="?"||S.dump&&S.dump.length>1024;Nt&&(S.dump&&n===S.dump.charCodeAt(0)?Ct+="?":Ct+="? "),Ct+=S.dump,Nt&&(Ct+=pt(S,P)),X(S,P+1,$t,!0,Nt)&&(S.dump&&n===S.dump.charCodeAt(0)?Ct+=":":Ct+=": ",Ct+=S.dump,Z+=Ct)}S.tag=tt,S.dump=Z||"{}"}p(g,"writeBlockMapping");function O(S,P,J){const G=J?S.explicitTypes:S.implicitTypes;for(let Z=0,tt=G.length;Z<tt;Z+=1){const Q=G[Z];if((Q.instanceOf||Q.predicate)&&(!Q.instanceOf||typeof P=="object"&&P instanceof Q.instanceOf)&&(!Q.predicate||Q.predicate(P))){if(J?Q.multi&&Q.representName?S.tag=Q.representName(P):S.tag=Q.tag:S.tag="?",Q.represent){const ft=S.styleMap[Q.tag]||Q.defaultStyle;let lt;if(i.call(Q.represent)==="[object Function]")lt=Q.represent(P,ft);else if(s.call(Q.represent,ft))lt=Q.represent[ft](P,ft);else throw new t("!<"+Q.tag+'> tag resolver accepts not "'+ft+'" style');S.dump=lt}return!0}}return!1}p(O,"detectType");function X(S,P,J,G,Z,tt,Q){S.tag=null,S.dump=J,O(S,J,!1)||O(S,J,!0);const ft=i.call(S.dump),lt=G;G&&(G=S.flowLevel<0||S.flowLevel>P);const Ct=ft==="[object Object]"||ft==="[object Array]";let kt,$t;if(Ct&&(kt=S.duplicates.indexOf(J),$t=kt!==-1),(S.tag!==null&&S.tag!=="?"||$t||S.indent!==2&&P>0)&&(Z=!1),$t&&S.usedDuplicates[kt])S.dump="*ref_"+kt;else{if(Ct&&$t&&!S.usedDuplicates[kt]&&(S.usedDuplicates[kt]=!0),ft==="[object Object]")G&&Object.keys(S.dump).length!==0?(g(S,P,S.dump,Z),$t&&(S.dump="&ref_"+kt+S.dump)):(xi(S,P,S.dump),$t&&(S.dump="&ref_"+kt+" "+S.dump));else if(ft==="[object Array]")G&&S.dump.length!==0?(S.noArrayIndent&&!Q&&P>0?Fr(S,P-1,S.dump,Z):Fr(S,P,S.dump,Z),$t&&(S.dump="&ref_"+kt+S.dump)):(Lr(S,P,S.dump),$t&&(S.dump="&ref_"+kt+" "+S.dump));else if(ft==="[object String]")S.tag!=="?"&&gi(S,S.dump,P,tt,lt);else{if(ft==="[object Undefined]")return!1;if(S.skipInvalid)return!1;throw new t("unacceptable kind of an object to dump "+ft)}if(S.tag!==null&&S.tag!=="?"){let Nt=encodeURI(S.tag[0]==="!"?S.tag.slice(1):S.tag).replace(/!/g,"%21");S.tag[0]==="!"?Nt="!"+Nt:Nt.slice(0,18)==="tag:yaml.org,2002:"?Nt="!!"+Nt.slice(18):Nt="!<"+Nt+">",S.dump=Nt+" "+S.dump}}return!0}p(X,"writeNode");function K(S,P){const J=[],G=[];j(S,J,G);const Z=G.length;for(let tt=0;tt<Z;tt+=1)P.duplicates.push(J[G[tt]]);P.usedDuplicates=new Array(Z)}p(K,"getDuplicateReferences");function j(S,P,J){if(S!==null&&typeof S=="object"){const G=P.indexOf(S);if(G!==-1)J.indexOf(G)===-1&&J.push(G);else if(P.push(S),Array.isArray(S))for(let Z=0,tt=S.length;Z<tt;Z+=1)j(S[Z],P,J);else{const Z=Object.keys(S);for(let tt=0,Q=Z.length;tt<Q;tt+=1)j(S[Z[tt]],P,J)}}}p(j,"inspectNode");function et(S,P){P=P||{};const J=new at(P);J.noRefs||K(S,J);let G=S;return J.replacer&&(G=J.replacer.call({"":G},"",G)),X(J,0,G,!0,!0)?J.dump+`
299
+ `:""}return p(et,"dump2"),To.dump=et,To}p(Jg,"requireDumper");var fu;function ty(){if(fu)return Qt;fu=1;const e=Qg(),t=Jg();function r(i,s){return function(){throw new Error("Function yaml."+i+" is removed in js-yaml 4. Use yaml."+s+" instead, which is now safe by default.")}}return p(r,"renamed"),Qt.Type=re(),Qt.Schema=Sl(),Qt.FAILSAFE_SCHEMA=vl(),Qt.JSON_SCHEMA=El(),Qt.CORE_SCHEMA=$l(),Qt.DEFAULT_SCHEMA=Ea(),Qt.load=e.load,Qt.loadAll=e.loadAll,Qt.dump=t.dump,Qt.YAMLException=fi(),Qt.types={binary:Pl(),float:Al(),map:Bl(),null:Ll(),pairs:Rl(),set:ql(),timestamp:Ol(),bool:Fl(),int:Ml(),merge:Dl(),omap:Il(),seq:_l(),str:Tl()},Qt.safeLoad=r("safeLoad","load"),Qt.safeLoadAll=r("safeLoadAll","loadAll"),Qt.safeDump=r("safeDump","dump"),Qt}p(ty,"requireJsYaml");var GB=ty(),VB=Zg(GB),{Type:fA,Schema:pA,FAILSAFE_SCHEMA:gA,JSON_SCHEMA:ZB,CORE_SCHEMA:yA,DEFAULT_SCHEMA:mA,load:KB,loadAll:xA,dump:CA,YAMLException:bA,types:kA,safeLoad:wA,safeLoadAll:SA,safeDump:TA}=VB,QB={common:os,getConfig:Ht,insertCluster:ag,insertEdge:lg,insertEdgeLabel:cl,insertMarkers:ug,insertNode:hl,interpolateToCurve:Nn,labelHelper:mt,log:I,positionEdgeLabel:Bw},es={},ey=p(e=>{for(const t of e)es[t.name]=t},"registerLayoutLoaders"),JB=p(()=>{ey([{name:"dagre",loader:p(async()=>await Ft(()=>import("./dagre-GXQ25YYZ-DYrwe_pj.js"),__vite__mapDeps([5,6,1,2,3,4]),import.meta.url),"loader")},{name:"swimlane",loader:p(async()=>await Ft(()=>import("./swimlanes-42K2YHIH-Belip6eP.js"),__vite__mapDeps([7,1,2,3,4]),import.meta.url),"loader")},{name:"cose-bilkent",loader:p(async()=>await Ft(()=>import("./cose-bilkent-JH36ORCC-BKY655a1.js"),__vite__mapDeps([8,9,1,2,3,4]),import.meta.url),"loader")}])},"registerDefaultLayoutLoaders");JB();var _A=p(async(e,t)=>{if(!(e.layoutAlgorithm in es))throw new Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);if(e.diagramId)for(const h of e.nodes){const u=h.domId||h.id;h.domId=`${e.diagramId}-${u}`}const r=es[e.layoutAlgorithm],i=await r.loader(),{theme:s,themeVariables:a}=e.config,{useGradient:o,gradientStart:n,gradientStop:l}=a,c=t.attr("id");if(t.append("defs").append("filter").attr("id",`${c}-drop-shadow`).attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${s!=null&&s.includes("dark")?"#FFFFFF":"#000000"}`),t.append("defs").append("filter").attr("id",`${c}-drop-shadow-small`).attr("height","150%").attr("width","150%").append("feDropShadow").attr("dx","2").attr("dy","2").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${s!=null&&s.includes("dark")?"#FFFFFF":"#000000"}`),o){const h=t.append("linearGradient").attr("id",t.attr("id")+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");h.append("svg:stop").attr("offset","0%").attr("stop-color",n).attr("stop-opacity",1),h.append("svg:stop").attr("offset","100%").attr("stop-color",l).attr("stop-opacity",1)}return i.render(e,t,QB,{algorithm:r.algorithm})},"render"),BA=p((e="",{fallback:t="dagre"}={})=>{if(e in es)return e;if(t in es)return I.warn(`Layout algorithm ${e} is not registered. Using ${t} as fallback.`),t;throw new Error(`Both layout algorithms ${e} and ${t} are not registered.`)},"getRegisteredLayoutAlgorithm"),Nl="comm",ry="rule",iy="decl",tv="@media",ev="@import",rv="@supports",iv="@namespace",cn="@keyframes",sy="@layer",sv="@scope",av=Math.abs,Yi=String.fromCharCode;function ay(e){return e.trim()}function un(e,t,r){return e.replace(t,r)}function Nr(e,t){return e.charCodeAt(t)|0}function ni(e,t,r){return e.slice(t,r)}function Le(e){return e.length}function oy(e){return e.length}function _s(e,t){return t.push(e),e}var $a=1,li=1,ny=0,fe=0,Ut=0,pi="";function Wl(e,t,r,i,s,a,o,n){return{value:e,root:t,parent:r,type:i,props:s,children:a,line:$a,column:li,length:o,return:"",siblings:n}}function ov(){return Ut}function nv(){return Ut=fe>0?Nr(pi,--fe):0,li--,Ut===10&&(li=1,$a--),Ut}function ke(){return Ut=fe<ny?Nr(pi,fe++):0,li++,Ut===10&&(li=1,$a++),Ut}function Je(){return Nr(pi,fe)}function Is(){return fe}function Oa(e,t){return ni(pi,e,t)}function rs(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function lv(e){return $a=li=1,ny=Le(pi=e),fe=0,[]}function hv(e){return pi="",e}function _o(e){return ay(Oa(fe-1,dn(e===91?e+2:e===40?e+1:e)))}function cv(e){for(;(Ut=Je())&&Ut<33;)ke();return rs(e)>2||rs(Ut)>3?"":" "}function uv(e,t){for(;--t&&ke()&&!(Ut<48||Ut>102||Ut>57&&Ut<65||Ut>70&&Ut<97););return Oa(e,Is()+(t<6&&Je()==32&&ke()==32))}function dn(e){for(;ke();)switch(Ut){case e:return fe;case 34:case 39:e!==34&&e!==39&&dn(Ut);break;case 40:e===41&&dn(e);break;case 92:ke();break}return fe}function dv(e,t){for(;ke()&&e+Ut!==57;)if(e+Ut===84&&Je()===47)break;return"/*"+Oa(t,fe-1)+"*"+Yi(e===47?e:ke())}function fv(e){for(;!rs(Je());)ke();return Oa(e,fe)}function pv(e){return hv(Rs("",null,null,null,[""],e=lv(e),0,[0],e))}function Rs(e,t,r,i,s,a,o,n,l){for(var c=0,h=0,u=o,d=0,f=0,y=0,m=1,C=1,x=1,k=0,w=0,T="",_=s,v=a,F=i,L=T;C;)switch(y=w,w=ke()){case 40:y!=108&&Nr(L,u-1)==58?(k++,L+="("):L+=_o(w);break;case 41:k--,L+=")";break;case 34:case 39:case 91:L+=_o(w);break;case 9:case 10:case 13:case 32:if(k>0){L+=Yi(w);break}L+=cv(y);break;case 92:L+=uv(Is()-1,7);continue;case 47:switch(Je()){case 42:case 47:_s(gv(dv(ke(),Is()),t,r,l),l),(rs(y||1)==5||rs(Je()||1)==5)&&Le(L)&&ni(L,-1,void 0)!==" "&&(L+=" ");break;default:L+="/"}break;case 123*m:n[c++]=Le(L)*x;case 125*m:case 59:case 0:if(k>0&&w){L+=Yi(w);break}switch(w){case 0:case 125:C=0;case 59+h:x==-1&&(L=un(L,/\f/g,"")),f>0&&(Le(L)-u||m===0)&&_s(f>32?gu(L+";",i,r,u-1,l):gu(un(L," ","")+";",i,r,u-2,l),l);break;case 59:L+=";";default:if(_s(F=pu(L,t,r,c,h,s,n,T,_=[],v=[],u,a),a),w===123)if(h===0)Rs(L,t,F,F,_,a,u,n,v);else{switch(d){case 99:if(Nr(L,3)===110)break;case 108:if(Nr(L,2)===97)break;default:h=0;case 100:case 109:case 115:}h?Rs(e,F,F,i&&_s(pu(e,F,F,0,0,s,n,T,s,_=[],u,v),v),s,v,u,n,i?_:v):Rs(L,F,F,F,[""],v,0,n,v)}}c=h=f=0,m=x=1,T=L="",u=o;break;case 58:u=1+Le(L),f=y;default:if(m<1){if(w==123)--m;else if(w==125&&m++==0&&nv()==125)continue}switch(L+=Yi(w),w*m){case 38:x=h>0?1:(L+="\f",-1);break;case 44:if(k>0)break;n[c++]=(Le(L)-1)*x,x=1;break;case 64:Je()===45&&(L+=_o(ke())),d=Je(),h=u=Le(T=L+=fv(Is())),w++;break;case 45:y===45&&Le(L)==2&&(m=0)}}return a}function pu(e,t,r,i,s,a,o,n,l,c,h,u){for(var d=s-1,f=s===0?a:[""],y=oy(f),m=0,C=0,x=0;m<i;++m)for(var k=0,w=ni(e,d+1,d=av(C=o[m])),T=e;k<y;++k)(T=ay(C>0?f[k]+" "+w:un(w,/&\f/g,f[k])))&&(l[x++]=T);return Wl(e,t,r,s===0?ry:n,l,c,h,u)}function gv(e,t,r,i){return Wl(e,t,r,Nl,Yi(ov()),ni(e,2,-2),0,i)}function gu(e,t,r,i,s){return Wl(e,t,r,iy,ni(e,0,i),ni(e,i+1,-1),i,s)}function fn(e,t){for(var r="",i=0;i<e.length;i++)r+=t(e[i],i,e,t)||"";return r}function yv(e,t,r,i){switch(e.type){case sy:if(e.children.length)break;case ev:case iv:case iy:return e.return=e.return||e.value;case Nl:return"";case cn:return e.return=e.value+"{"+fn(e.children,i)+"}";case ry:if(!Le(e.value=e.props.join(",")))return""}return Le(r=fn(e.children,i))?e.return=e.value+"{"+r+"}":""}function mv(e){var t=oy(e);return function(r,i,s,a){for(var o="",n=0;n<t;n++)o+=e[n](r,i,s,a)||"";return o}}var ly="c4",xv=p(e=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(e),"detector"),Cv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./c4Diagram-7LVT6UL2-nZGUi3mU.js");return{diagram:t}},__vite__mapDeps([10,11,1,2,3,4]),import.meta.url);return{id:ly,diagram:e}},"loader"),bv={id:ly,detector:xv,loader:Cv},kv=bv,hy="flowchart",wv=p((e,t)=>{var r,i;return((r=t==null?void 0:t.flowchart)==null?void 0:r.defaultRenderer)==="dagre-wrapper"||((i=t==null?void 0:t.flowchart)==null?void 0:i.defaultRenderer)==="elk"?!1:/^\s*graph/.test(e)},"detector"),Sv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./flowDiagram-HODETNUW-BNTRT4LN.js").then(r=>r.f);return{diagram:t}},__vite__mapDeps([12,13,14,15,11,2,3,16]),import.meta.url);return{id:hy,diagram:e}},"loader"),Tv={id:hy,detector:wv,loader:Sv},_v=Tv,cy="flowchart-v2",Bv=p((e,t)=>{var r,i,s;return((r=t==null?void 0:t.flowchart)==null?void 0:r.defaultRenderer)==="dagre-d3"?!1:(((i=t==null?void 0:t.flowchart)==null?void 0:i.defaultRenderer)==="elk"&&(t.layout="elk"),/^\s*graph/.test(e)&&((s=t==null?void 0:t.flowchart)==null?void 0:s.defaultRenderer)==="dagre-wrapper"?!0:/^\s*flowchart/.test(e))},"detector"),vv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./flowDiagram-HODETNUW-BNTRT4LN.js").then(r=>r.f);return{diagram:t}},__vite__mapDeps([12,13,14,15,11,2,3,16]),import.meta.url);return{id:cy,diagram:e}},"loader"),Lv={id:cy,detector:Bv,loader:vv},Fv=Lv,uy="swimlane",Mv=p(e=>/^\s*swimlane-beta\b/.test(e),"detector"),Av=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./swimlanesDiagram-VR7AAH4N-CzGu2D2p.js");return{diagram:t}},__vite__mapDeps([17,12,13,14,15,11,2,3,16,1,4]),import.meta.url);return{id:uy,diagram:e}},"loader"),Ev={id:uy,detector:Mv,loader:Av},$v=Ev,dy="er",Ov=p(e=>/^\s*erDiagram/.test(e),"detector"),Dv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./erDiagram-RLTQ6QDP-BfpNZTDy.js");return{diagram:t}},__vite__mapDeps([18,14,15,3,16,1,2,4]),import.meta.url);return{id:dy,diagram:e}},"loader"),Pv={id:dy,detector:Ov,loader:Dv},Iv=Pv,fy="gitGraph",Rv=p(e=>/^\s*gitGraph/.test(e),"detector"),qv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./gitGraphDiagram-WWUBYQGX-BPhOAW6u.js");return{diagram:t}},__vite__mapDeps([19,20,21,22,1,2,3,4]),import.meta.url);return{id:fy,diagram:e}},"loader"),Nv={id:fy,detector:Rv,loader:qv},Wv=Nv,py="gantt",zv=p(e=>/^\s*gantt/.test(e),"detector"),Hv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./ganttDiagram-EL5Y4UJY-B8LaEeAd.js");return{diagram:t}},__vite__mapDeps([23,1,24,25,26,2,3,4]),import.meta.url);return{id:py,diagram:e}},"loader"),Yv={id:py,detector:zv,loader:Hv},jv=Yv,gy="info",Uv=p(e=>/^\s*info/.test(e),"detector"),Xv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./infoDiagram-27XIBGKW-U6LgO_ju.js");return{diagram:t}},__vite__mapDeps([27,22,1,2,3,4]),import.meta.url);return{id:gy,diagram:e}},"loader"),Gv={id:gy,detector:Uv,loader:Xv},yy="pie",Vv=p(e=>/^\s*pie/.test(e),"detector"),Zv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./pieDiagram-E7YTZNPT-DpqpRrk3.js");return{diagram:t}},__vite__mapDeps([28,21,22,1,29,30,25,2,3,4]),import.meta.url);return{id:yy,diagram:e}},"loader"),Kv={id:yy,detector:Vv,loader:Zv},my="quadrantChart",Qv=p(e=>/^\s*quadrantChart/.test(e),"detector"),Jv=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./quadrantDiagram-AXDQQJYC-D3jcnC7Q.js");return{diagram:t}},__vite__mapDeps([31,24,25,26,1,2,3,4]),import.meta.url);return{id:my,diagram:e}},"loader"),tL={id:my,detector:Qv,loader:Jv},eL=tL,xy="xychart",rL=p(e=>/^\s*xychart(-beta)?/.test(e),"detector"),iL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./xychartDiagram-S5SC5T6Z-CmlwEiU8.js");return{diagram:t}},__vite__mapDeps([32,25,30,24,26,1,2,3,4]),import.meta.url);return{id:xy,diagram:e}},"loader"),sL={id:xy,detector:rL,loader:iL},aL=sL,Cy="requirement",oL=p(e=>/^\s*requirement(Diagram)?/.test(e),"detector"),nL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./requirementDiagram-BXWQKSXE-BjvIFtJN.js");return{diagram:t}},__vite__mapDeps([33,14,15,1,2,3,4]),import.meta.url);return{id:Cy,diagram:e}},"loader"),lL={id:Cy,detector:oL,loader:nL},hL=lL,by="sequence",cL=p(e=>/^\s*sequenceDiagram/.test(e),"detector"),uL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./sequenceDiagram-WJ2MYXX4-COPuE32n.js");return{diagram:t}},__vite__mapDeps([34,20,11,1,2,3,4]),import.meta.url);return{id:by,diagram:e}},"loader"),dL={id:by,detector:cL,loader:uL},fL=dL,ky="class",pL=p((e,t)=>{var r;return((r=t==null?void 0:t.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(e)},"detector"),gL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./classDiagram-ZZMXUADV-BJm7NJbs.js");return{diagram:t}},__vite__mapDeps([35,36,13,14,15,11,2,1,3,4]),import.meta.url);return{id:ky,diagram:e}},"loader"),yL={id:ky,detector:pL,loader:gL},mL=yL,wy="classDiagram",xL=p((e,t)=>{var r;return/^\s*classDiagram/.test(e)&&((r=t==null?void 0:t.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!0:/^\s*classDiagram-v2/.test(e)},"detector"),CL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./classDiagram-v2-VYDZK3BY-BJm7NJbs.js");return{diagram:t}},__vite__mapDeps([37,36,13,14,15,11,2,1,3,4]),import.meta.url);return{id:wy,diagram:e}},"loader"),bL={id:wy,detector:xL,loader:CL},kL=bL,Sy="state",wL=p((e,t)=>{var r;return((r=t==null?void 0:t.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(e)},"detector"),SL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./stateDiagram-D77RDMKH-DkQ3KhXj.js");return{diagram:t}},__vite__mapDeps([38,39,14,15,11,2,6,1,3,4]),import.meta.url);return{id:Sy,diagram:e}},"loader"),TL={id:Sy,detector:wL,loader:SL},_L=TL,Ty="stateDiagram",BL=p((e,t)=>{var r;return!!(/^\s*stateDiagram-v2/.test(e)||/^\s*stateDiagram/.test(e)&&((r=t==null?void 0:t.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper")},"detector"),vL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./stateDiagram-v2-MP3YSRHH-C2O-IoZS.js");return{diagram:t}},__vite__mapDeps([40,39,14,15,11,2,1,3,4]),import.meta.url);return{id:Ty,diagram:e}},"loader"),LL={id:Ty,detector:BL,loader:vL},FL=LL,_y="journey",ML=p(e=>/^\s*journey/.test(e),"detector"),AL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./journeyDiagram-3NMN7TZE-Bx7POPvm.js");return{diagram:t}},__vite__mapDeps([41,13,11,29,1,2,3,4]),import.meta.url);return{id:_y,diagram:e}},"loader"),EL={id:_y,detector:ML,loader:AL},$L=EL,OL=p((e,t,r)=>{I.debug(`rendering svg for syntax error
300
+ `);const i=M1(t),s=i.append("g");i.attr("viewBox","0 0 2412 512"),Hu(i,100,512,!0),s.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),s.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),s.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),s.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),s.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),s.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),s.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),s.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},"draw"),By={draw:OL},DL=By,PL={db:{},renderer:By,parser:{parse:p(()=>{},"parse")}},IL=PL,vy="flowchart-elk",RL=p((e,t={})=>{var r;return/^\s*flowchart-elk/.test(e)||/^\s*(flowchart|graph)/.test(e)&&((r=t==null?void 0:t.flowchart)==null?void 0:r.defaultRenderer)==="elk"?(t.layout="elk",!0):!1},"detector"),qL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./flowDiagram-HODETNUW-BNTRT4LN.js").then(r=>r.f);return{diagram:t}},__vite__mapDeps([12,13,14,15,11,2,3,16]),import.meta.url);return{id:vy,diagram:e}},"loader"),NL={id:vy,detector:RL,loader:qL},WL=NL,Ly="timeline",zL=p(e=>/^\s*timeline/.test(e),"detector"),HL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./timeline-definition-24CTP7MA-Bntb2OTs.js");return{diagram:t}},__vite__mapDeps([42,29,1,2,3,4]),import.meta.url);return{id:Ly,diagram:e}},"loader"),YL={id:Ly,detector:zL,loader:HL},jL=YL,Fy="mindmap",UL=p(e=>/^\s*mindmap/.test(e),"detector"),XL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./mindmap-definition-YA3MSWOX-CcsjXg_l.js");return{diagram:t}},__vite__mapDeps([43,14,15,1,2,3,4]),import.meta.url);return{id:Fy,diagram:e}},"loader"),GL={id:Fy,detector:UL,loader:XL},VL=GL,My="kanban",ZL=p(e=>/^\s*kanban/.test(e),"detector"),KL=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./kanban-definition-UXKFOSKX-CpYDSQwK.js");return{diagram:t}},__vite__mapDeps([44,13,1,2,3,4]),import.meta.url);return{id:My,diagram:e}},"loader"),QL={id:My,detector:ZL,loader:KL},JL=QL,Ay="sankey",tF=p(e=>/^\s*sankey(-beta)?/.test(e),"detector"),eF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./sankeyDiagram-P5KCCOFB-BAeQKqir.js");return{diagram:t}},__vite__mapDeps([45,30,25,1,2,3,4]),import.meta.url);return{id:Ay,diagram:e}},"loader"),rF={id:Ay,detector:tF,loader:eF},iF=rF,Ey="packet",sF=p(e=>/^\s*packet(-beta)?/.test(e),"detector"),aF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./diagram-Z3DM3KII-Cvgf5Y5I.js");return{diagram:t}},__vite__mapDeps([46,21,22,1,2,3,4]),import.meta.url);return{id:Ey,diagram:e}},"loader"),oF={id:Ey,detector:sF,loader:aF},$y="radar",nF=p(e=>/^\s*radar-beta/.test(e),"detector"),lF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./diagram-UQ7AKVKN-Dx--Yu_z.js");return{diagram:t}},__vite__mapDeps([47,21,22,1,2,3,4]),import.meta.url);return{id:$y,diagram:e}},"loader"),hF={id:$y,detector:nF,loader:lF},Oy="block",cF=p(e=>/^\s*block(-beta)?/.test(e),"detector"),uF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./blockDiagram-I7D4REHJ-BQd0dwKa.js");return{diagram:t}},__vite__mapDeps([48,13,4,3,16,1,2]),import.meta.url);return{id:Oy,diagram:e}},"loader"),dF={id:Oy,detector:cF,loader:uF},fF=dF,Dy="treeView",pF=p(e=>/^\s*treeView-beta/.test(e),"detector"),gF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./diagram-S7CK7UJ4-BiMW816X.js");return{diagram:t}},__vite__mapDeps([49,20,21,22,1,2,3,4]),import.meta.url);return{id:Dy,diagram:e}},"loader"),yF={id:Dy,detector:pF,loader:gF},mF=yF,Py="architecture",xF=p(e=>/^\s*architecture/.test(e),"detector"),CF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./architectureDiagram-5GKGNRK7-CaDJakVP.js");return{diagram:t}},__vite__mapDeps([50,21,22,1,9,2,3,4]),import.meta.url);return{id:Py,diagram:e}},"loader"),bF={id:Py,detector:xF,loader:CF},kF=bF,Iy="eventmodeling",wF=p(e=>/^\s*eventmodeling/.test(e),"detector"),SF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./diagram-VSXAHHWV-DRrurU6X.js");return{diagram:t}},__vite__mapDeps([51,21,22,1,2,3,4]),import.meta.url);return{id:Iy,diagram:e}},"loader"),TF={id:Iy,detector:wF,loader:SF},_F=TF,Ry="ishikawa",BF=p(e=>/^\s*ishikawa(-beta)?\b/i.test(e),"detector"),vF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./ishikawaDiagram-5VMMS53U-DxXeMYDc.js");return{diagram:t}},__vite__mapDeps([52,1,2,3,4]),import.meta.url);return{id:Ry,diagram:e}},"loader"),LF={id:Ry,detector:BF,loader:vF},qy="venn",FF=p(e=>/^\s*venn-beta/.test(e),"detector"),MF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./vennDiagram-4TSXK5OY-Cw2eTnvz.js");return{diagram:t}},__vite__mapDeps([53,1,2,3,4]),import.meta.url);return{id:qy,diagram:e}},"loader"),AF={id:qy,detector:FF,loader:MF},EF=AF,Ny="treemap",$F=p(e=>/^\s*treemap/.test(e),"detector"),OF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./diagram-VX7I27RA-00uuQ0k2.js");return{diagram:t}},__vite__mapDeps([54,21,15,22,1,26,30,25,2,3,4]),import.meta.url);return{id:Ny,diagram:e}},"loader"),DF={id:Ny,detector:$F,loader:OF},Wy="wardley",PF=p(e=>/^\s*wardley-beta/i.test(e),"detector"),IF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./wardleyDiagram-VM6X3IG4-DzJNpWOP.js");return{diagram:t}},__vite__mapDeps([55,21,22,1,2,3,4]),import.meta.url);return{id:Wy,diagram:e}},"loader"),RF={id:Wy,detector:PF,loader:IF},qF=RF,zy="cynefin",NF=p(e=>/^\s*cynefin-beta(?:[\s:]|$)/.test(e),"detector"),WF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./cynefinDiagram-5FMLGOSQ-C2liQpUc.js");return{diagram:t}},__vite__mapDeps([56,21,22,1,2,3,4]),import.meta.url);return{id:zy,diagram:e}},"loader"),zF={id:zy,detector:NF,loader:WF},Hy="railroad",HF=p(e=>/^\s*railroad-beta/i.test(e),"detector"),YF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./railroadDiagram-O6MQD6OU-KAu7lO3i.js");return{diagram:t}},__vite__mapDeps([57,58,21,22,1,2,3,4]),import.meta.url);return{id:Hy,diagram:e}},"loader"),jF={id:Hy,detector:HF,loader:YF},Yy="railroadEbnf",UF=p(e=>/^\s*railroad-ebnf-beta/i.test(e),"detector"),XF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./ebnfDiagram-PWID7BFC-CHZyB5eb.js");return{diagram:t}},__vite__mapDeps([59,58,21,22,1,2,3,4]),import.meta.url);return{id:Yy,diagram:e}},"loader"),GF={id:Yy,detector:UF,loader:XF},jy="railroadAbnf",VF=p(e=>/^\s*railroad-abnf-beta/i.test(e),"detector"),ZF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./abnfDiagram-VCTEODGH-C_ttoOR-.js");return{diagram:t}},__vite__mapDeps([60,58,21,22,1,2,3,4]),import.meta.url);return{id:jy,diagram:e}},"loader"),KF={id:jy,detector:VF,loader:ZF},Uy="railroadPeg",QF=p(e=>/^\s*railroad-peg-beta/i.test(e),"detector"),JF=p(async()=>{const{diagram:e}=await Ft(async()=>{const{diagram:t}=await import("./pegDiagram-XKGWAZYB-D8bhpeEX.js");return{diagram:t}},__vite__mapDeps([61,58,21,22,1,2,3,4]),import.meta.url);return{id:Uy,diagram:e}},"loader"),tM={id:Uy,detector:QF,loader:JF},yu=!1,Da=p(()=>{yu||(yu=!0,Hs("error",IL,e=>e.toLowerCase().trim()==="error"),Hs("---",{db:{clear:p(()=>{},"clear")},styles:{},renderer:{draw:p(()=>{},"draw")},parser:{parse:p(()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},"parse")},init:p(()=>null,"init")},e=>e.toLowerCase().trimStart().startsWith("---")),Mo(WL,VL,kF),Mo(kv,JL,kL,mL,Iv,jv,Gv,Kv,hL,fL,$v,Fv,_v,jL,Wv,FL,_L,$L,eL,iF,oF,aL,fF,_F,mF,hF,LF,DF,jF,GF,KF,tM,EF,qF,zF))},"addDiagrams"),eM=p(async()=>{I.debug("Loading registered diagrams");const t=(await Promise.allSettled(Object.entries(gr).map(async([r,{detector:i,loader:s}])=>{if(s)try{Oo(r)}catch{try{const{diagram:a,id:o}=await s();Hs(o,a,i)}catch(a){throw I.error(`Failed to load external diagram with key ${r}. Removing from detectors.`),delete gr[r],a}}}))).filter(r=>r.status==="rejected");if(t.length>0){I.error(`Failed to load ${t.length} external diagrams`);for(const r of t)I.error(r);throw new Error(`Failed to load ${t.length} external diagrams`)}},"loadRegisteredDiagrams"),rM="graphics-document document";function Xy(e,t){e.attr("role",rM),t!==""&&e.attr("aria-roledescription",t)}p(Xy,"setA11yDiagramInfo");function Gy(e,t,r,i){if(e.insert!==void 0){if(r){const s=`chart-desc-${i}`;e.attr("aria-describedby",s),e.insert("desc",":first-child").attr("id",s).text(r)}if(t){const s=`chart-title-${i}`;e.attr("aria-labelledby",s),e.insert("title",":first-child").attr("id",s).text(t)}}}p(Gy,"addSVGa11yTitleDescription");var fr,pn=(fr=class{constructor(t,r,i,s,a){this.type=t,this.text=r,this.db=i,this.parser=s,this.renderer=a}static async fromText(t,r={}){var c,h;const i=Ht(),s=wn(t,i);t=Sk(t)+`
301
+ `;try{Oo(s)}catch{const u=T0(s);if(!u)throw new Iu(`Diagram ${s} not found.`);const{id:d,diagram:f}=await u();Hs(d,f)}const{db:a,parser:o,renderer:n,init:l}=Oo(s);return o.parser&&(o.parser.yy=a),(c=a.clear)==null||c.call(a),l==null||l(i),r.title&&((h=a.setDiagramTitle)==null||h.call(a,r.title)),await o.parse(t),new fr(s,t,a,o,n)}async render(t,r){await this.renderer.draw(this.text,t,r,this)}getParser(){return this.parser}getType(){return this.type}},p(fr,"Diagram"),fr),mu=[],iM=p(()=>{mu.forEach(e=>{e()}),mu=[]},"attachFunctions"),sM=p(e=>e.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart(),"cleanupComments");function Vy(e){const t=e.match(Pu);if(!t)return{text:e,metadata:{}};const r=t[1],i=r?t[2].split(`
302
+ `).map(o=>o.startsWith(r)?o.slice(r.length):o).join(`
303
+ `):t[2];let s=KB(i,{schema:ZB})??{};s=typeof s=="object"&&!Array.isArray(s)?s:{};const a={};return s.displayMode&&(a.displayMode=s.displayMode.toString()),s.title&&(a.title=s.title.toString()),s.config&&(a.config=s.config),{text:e.slice(t[0].length),metadata:a}}p(Vy,"extractFrontMatter");var aM=p(e=>e.replace(/\r\n?/g,`
304
+ `).replace(/<(\w+)([^>]*)>/g,(t,r,i)=>"<"+r+i.replace(/="([^"]*)"/g,"='$1'")+">"),"cleanupText"),oM=p(e=>{const{text:t,metadata:r}=Vy(e),{displayMode:i,title:s,config:a={}}=r;return i&&(a.gantt||(a.gantt={}),a.gantt.displayMode=i),{title:s,config:a,text:t}},"processFrontmatter"),nM=p(e=>{const t=te.detectInit(e)??{},r=te.detectDirective(e,"wrap");return Array.isArray(r)?t.wrap=r.some(({type:i})=>i==="wrap"):(r==null?void 0:r.type)==="wrap"&&(t.wrap=!0),{text:ck(e),directive:t}},"processDirectives");function zl(e){const t=aM(e),r=oM(t),i=nM(r.text),s=jn(r.config,i.directive);return e=sM(i.text),{code:e,title:r.title,config:s}}p(zl,"preprocessDiagram");function Zy(e){const t=new TextEncoder().encode(e),r=Array.from(t,i=>String.fromCodePoint(i)).join("");return btoa(r)}p(Zy,"toBase64");var lM=5e4,hM="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",cM="sandbox",uM="loose",dM="http://www.w3.org/2000/svg",fM="http://www.w3.org/1999/xlink",pM="http://www.w3.org/1999/xhtml",gM="100%",yM="100%",mM="border:0;margin:0;",xM="margin:0",CM="allow-top-navigation-by-user-activation allow-popups",bM='The "iframe" tag is not supported by your browser.',kM=["foreignobject"],wM=["dominant-baseline"];function Hl(e){const t=zl(e);return Ws(),b0(t.config??{}),t}p(Hl,"processAndSetConfigs");async function Ky(e,t){Da();try{const{code:r,config:i}=Hl(e);return{diagramType:(await Jy(r)).type,config:i}}catch(r){if(t!=null&&t.suppressErrors)return!1;throw r}}p(Ky,"parse");var xu=p((e,t,r=[])=>{const i=Au(`{ ${r.join(" !important; ")} !important; }`);return`.${e} ${t} ${i}`},"cssImportantStyles"),SM=p((e,t=new Map)=>{const r=new CSSStyleSheet;if(e.fontFamily!==void 0&&r.insertRule(`:root { --mermaid-font-family: ${e.fontFamily}}`,r.cssRules.length),e.altFontFamily!==void 0&&r.insertRule(`:root { --mermaid-alt-font-family: ${e.altFontFamily}}`,r.cssRules.length),t instanceof Map){const n=ee(e)?["> *","span"]:["rect","polygon","ellipse","circle","path"];t.forEach(l=>{Xl(l.styles)||n.forEach(c=>{r.insertRule(xu(l.id,c,l.styles),r.cssRules.length)}),Xl(l.textStyles)||r.insertRule(xu(l.id,"tspan",((l==null?void 0:l.textStyles)||[]).map(c=>c.replace("color","fill"))),r.cssRules.length)})}let i="";if(e.themeCSS!==void 0)if(typeof r.replaceSync=="function"){const s=new CSSStyleSheet;s.replaceSync(e.themeCSS),i=$o(s)+`
305
+ `}else i+=`${e.themeCSS}
306
+ `;return i+$o(r)},"createCssStyles"),TM=p((e,t)=>fn(pv(`${e}{${t}}`),mv([p(function(i,s,a,o){if(i.type==="rule"&&Array.isArray(i.props)){if(i.parent&&i.parent.type===cn)return;i.props=i.props.map(n=>n===e&&Array.isArray(i.children)&&i.children.every(c=>c.type!=="decl"?!1:new Set(["font-family","font-size","fill"]).has(c.props))||(n.startsWith(`${e} `)||n.startsWith(`${e}>`))&&!n.startsWith(`${e} ||`)?n:`${e} ${n}`)}else i.type.startsWith("@")&&([...[tv,rv,sy,sv,"@container","@starting-style"],cn].includes(i.type)||(I.warn(`Removing unsupported at-rule ${i.type} from CSS`),i.type=Nl))},"addNamespace"),yv])),"compileCSS"),_M=p((e,t,r,i)=>{const s=SM(e,r),a=z0(t,s,{...e.themeVariables,theme:e.theme,look:e.look},i);return TM(i,a)},"createUserStyles"),BM=p((e="",t,r)=>{let i=e;return!r&&!t&&(i=i.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),i=er(i),i=i.replace(/<br>/g,"<br/>"),i},"cleanUpSvgCode"),vM=p((e="",t)=>{var s,a;const r=(a=(s=t==null?void 0:t.viewBox)==null?void 0:s.baseVal)!=null&&a.height?t.viewBox.baseVal.height+"px":yM,i=Zy(`<body style="${xM}">${e}</body>`);return`<iframe style="width:${gM};height:${r};${mM}" src="data:text/html;charset=UTF-8;base64,${i}" sandbox="${CM}">
307
+ ${bM}
308
+ </iframe>`},"putIntoIFrame"),Cu=p((e,t,r,i,s)=>{const a=e.append("div");a.attr("id",r),i&&a.attr("style",i);const o=a.append("svg").attr("id",t).attr("width","100%").attr("xmlns",dM);return s&&o.attr("xmlns:xlink",s),o.append("g"),e},"appendDivSvgG");function gn(e,t){return e.append("iframe").attr("id",t).attr("style","width: 100%; height: 100%;").attr("sandbox","")}p(gn,"sandboxedIframe");var LM=p((e,t,r,i)=>{var s,a,o;(s=e.getElementById(t))==null||s.remove(),(a=e.getElementById(r))==null||a.remove(),(o=e.getElementById(i))==null||o.remove()},"removeExistingElements"),FM=p(async function(e,t,r){var Y,A,E,B,D,$;Da();const i=Hl(t);t=i.code;const s=Ht();I.debug(s),t.length>((s==null?void 0:s.maxTextSize)??lM)&&(t=hM);const a=`#${e}`,o="i"+e,n="#"+o,l="d"+e,c="#"+l,h=p(()=>{const V=Lt(d?n:c).node();V&&"remove"in V&&V.remove()},"removeTempElements");let u=Lt(document.body);const d=s.securityLevel===cM,f=s.securityLevel===uM,y=s.fontFamily;if(r!==void 0){if(r&&(r.innerHTML=""),d){const N=gn(Lt(r),o);u=Lt(N.nodes()[0].contentDocument.body),u.node().style.margin="0"}else u=Lt(r);Cu(u,e,l,`font-family: ${y}`,fM)}else{if(LM(document,e,l,o),d){const N=gn(Lt(document.body),o);u=Lt(N.nodes()[0].contentDocument.body),u.node().style.margin="0"}else u=Lt("body");Cu(u,e,l)}let m,C;try{m=await pn.fromText(t,{title:i.title})}catch(N){if(s.suppressErrorRendering)throw h(),N;m=await pn.fromText("error"),C=N}const x=u.select(c).node(),k=m.type,w=x.firstChild,T=w.firstChild,_=(A=(Y=m.renderer).getClasses)==null?void 0:A.call(Y,t,m),v=_M(s,k,_,a),F=document.createElement("style");F.innerHTML=v,w.insertBefore(F,T);try{await m.renderer.draw(t,e,"11.17.2",m)}catch(N){throw s.suppressErrorRendering?h():DL.draw(t,e,"11.17.2"),N}const L=u.select(`${c} svg`),U=(B=(E=m.db).getAccTitle)==null?void 0:B.call(E),W=($=(D=m.db).getAccDescription)==null?void 0:$.call(D);tm(k,L,U,W);const rt=p(()=>{u.select(`[id="${e}"]`).selectAll("foreignobject > *").attr("xmlns",pM);let N=u.select(c).node().innerHTML;if(I.debug("config.arrowMarkerAbsolute",s.arrowMarkerAbsolute),N=BM(N,d,De(s.arrowMarkerAbsolute)),d){const V=u.select(c+" svg").node();N=vM(N,V)}else f||(N=ri.sanitize(N,{ADD_TAGS:kM,ADD_ATTR:wM,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));return iM(),N},"serializeSvg")();if(C)throw C;return h(),{diagramType:k,svg:rt,bindFunctions:m.db.bindFunctions}},"render");function Qy(e={}){var i;const t=Vt({},e);t!=null&&t.fontFamily&&!((i=t.themeVariables)!=null&&i.fontFamily)&&(t.themeVariables||(t.themeVariables={}),t.themeVariables.fontFamily=t.fontFamily),x0(t),t!=null&&t.theme&&t.theme in He?t.themeVariables=He[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=He.default.getThemeVariables(t.themeVariables));const r=typeof t=="object"?m0(t):Eu();kn(r.logLevel),Da()}p(Qy,"initialize");var Jy=p((e,t={})=>{const{code:r}=zl(e);return pn.fromText(r,t)},"getDiagramFromText");function tm(e,t,r,i){Xy(t,e),Gy(t,r,i,t.attr("id"))}p(tm,"addA11yInfo");var kr=Object.freeze({render:FM,parse:Ky,getDiagramFromText:Jy,initialize:Qy,getConfig:Ht,setConfig:$u,getSiteConfig:Eu,updateSiteConfig:C0,reset:p(()=>{Ws()},"reset"),globalReset:p(()=>{Ws(ii)},"globalReset"),defaultConfig:ii});kn(Ht().logLevel);Ws(Ht());var MM=p((e,t,r)=>{I.warn(e),Yn(e)?(r&&r(e.str,e.hash),t.push({...e,message:e.str,error:e})):(r&&r(e),e instanceof Error&&t.push({str:e.message,message:e.message,hash:e.name,error:e}))},"handleError"),em=p(async function(e={querySelector:".mermaid"}){try{await AM(e)}catch(t){if(Yn(t)&&I.error(t.str),he.parseError&&he.parseError(t),!e.suppressErrors)throw I.error("Use the suppressErrors option to suppress these errors"),t}},"run"),AM=p(async function({postRenderCallback:e,querySelector:t,nodes:r}={querySelector:".mermaid"}){const i=kr.getConfig();I.debug(`${e?"":"No "}Callback function found`);let s;if(r)s=r;else if(t)s=document.querySelectorAll(t);else throw new Error("Nodes and querySelector are both undefined");I.debug(`Found ${s.length} diagrams`),(i==null?void 0:i.startOnLoad)!==void 0&&(I.debug("Start On Load: "+(i==null?void 0:i.startOnLoad)),kr.updateSiteConfig({startOnLoad:i==null?void 0:i.startOnLoad}));const a=new te.InitIDGenerator(i.deterministicIds,i.deterministicIDSeed);let o;const n=[];for(const l of Array.from(s)){if(I.info("Rendering diagram: "+l.id),l.getAttribute("data-processed"))continue;l.setAttribute("data-processed","true");const c=`mermaid-${a.next()}`;o=l.innerHTML,o=uf(te.entityDecode(o)).trim().replace(/<br\s*\/?>/gi,"<br/>");const h=te.detectInit(o);h&&I.debug("Detected early reinit: ",h);try{const{svg:u,bindFunctions:d}=await am(c,o,l);l.innerHTML=u,e&&await e(c),d&&d(l)}catch(u){MM(u,n,he.parseError)}}if(n.length>0)throw n[0]},"runThrowsErrors"),rm=p(function(e){kr.initialize(e)},"initialize"),EM=p(async function(e,t,r){I.warn("mermaid.init is deprecated. Please use run instead."),e&&rm(e);const i={postRenderCallback:r,querySelector:".mermaid"};typeof t=="string"?i.querySelector=t:t&&(t instanceof HTMLElement?i.nodes=[t]:i.nodes=t),await em(i)},"init"),$M=p(async(e,{lazyLoad:t=!0}={})=>{Da(),Mo(...e),t===!1&&await eM()},"registerExternalDiagrams"),im=p(function(){if(he.startOnLoad){const{startOnLoad:e}=kr.getConfig();e&&he.run().catch(t=>I.error("Mermaid failed to initialize",t))}},"contentLoaded");typeof document<"u"&&window.addEventListener("load",im,!1);var OM=p(function(e){he.parseError=e},"setParseErrorHandler"),ua=[],Bo=!1,sm=p(async()=>{if(!Bo){for(Bo=!0;ua.length>0;){const e=ua.shift();if(e)try{await e()}catch(t){I.error("Error executing queue",t)}}Bo=!1}},"executeQueue"),DM=p(async(e,t)=>new Promise((r,i)=>{const s=p(()=>new Promise((a,o)=>{kr.parse(e,t).then(n=>{a(n),r(n)},n=>{var l;I.error("Error parsing",n),(l=he.parseError)==null||l.call(he,n),o(n),i(n)})}),"performCall");ua.push(s),sm().catch(i)}),"parse"),am=p((e,t,r)=>new Promise((i,s)=>{const a=p(()=>new Promise((o,n)=>{kr.render(e,t,r).then(l=>{o(l),i(l)},l=>{var c;I.error("Error parsing",l),(c=he.parseError)==null||c.call(he,l),n(l),s(l)})}),"performCall");ua.push(a),sm().catch(s)}),"render"),PM=p(()=>Object.keys(gr).map(e=>({id:e})),"getRegisteredDiagramsMetadata"),he={startOnLoad:!0,mermaidAPI:kr,parse:DM,render:am,init:EM,run:em,registerExternalDiagrams:$M,registerLayoutLoaders:ey,initialize:rm,parseError:void 0,contentLoaded:im,setParseErrorHandler:OM,detectType:wn,registerIconPacks:ek,getRegisteredDiagramsMetadata:PM},IM=he;/*! Check if previously processed *//*!
309
+ * Wait for document loaded before starting the execution
310
+ */const vA=Object.freeze(Object.defineProperty({__proto__:null,clearLayoutRenderState:bl,createCommonLayoutRenderer:zg,default:IM,defaultMeasureLayout:kl,paintLayoutData:wl},Symbol.toStringTag,{value:"Module"}));export{ZM as $,BT as A,Su as B,ls as C,YM as D,Hn as E,Kd as F,Aa as G,Ue as H,LB as I,ZB as J,Sg as K,jn as L,H0 as M,Ot as N,Vi as O,Yu as P,os as Q,oe as R,Ye as S,m2 as T,$c as U,Hu as V,Mr as W,An as X,Ii as Y,ok as Z,Hm as _,Ee as a,dl as a$,zg as a0,Eg as a1,Te as a2,Yo as a3,H as a4,bm as a5,pm as a6,zm as a7,UM as a8,Mu as a9,HM as aA,mh as aB,yB as aC,Ui as aD,gB as aE,XM as aF,_a as aG,ag as aH,lg as aI,cl as aJ,Og as aK,hl as aL,Bm as aM,vm as aN,_m as aO,Ke as aP,ch as aQ,KC as aR,va as aS,ne as aT,Ba as aU,vB as aV,ha as aW,we as aX,la as aY,yg as aZ,Nd as a_,Mn as aa,xc as ab,ak as ac,yh as ad,mg as ae,sd as af,Ss as ag,ca as ah,Lm as ai,Fm as aj,ar as ak,pk as al,X0 as am,j0 as an,vc as ao,Ht as ap,At as aq,V0 as ar,sA as as,hs as at,BA as au,Vd as av,Sa as aw,ze as ax,Km as ay,A0 as az,p as b,km as b$,Cr as b0,xn as b1,xg as b2,ul as b3,vs as b4,pl as b5,Pr as b6,cw as b7,Fe as b8,z as b9,zu as bA,YC as bB,Xe as bC,de as bD,Lt as bE,M1 as bF,U0 as bG,Y0 as bH,jM as bI,G0 as bJ,cA as bK,ym as bL,DS as bM,q0 as bN,K0 as bO,rg as bP,JM as bQ,dA as bR,tA as bS,ku as bT,dt as bU,fm as bV,eA as bW,Ma as bX,f_ as bY,Sm as bZ,Tm as b_,k1 as ba,as as bb,KB as bc,I as bd,gm as be,Jt as bf,ug as bg,KM as bh,vA as bi,QM as bj,Sc as bk,nd as bl,wu as bm,Cm as bn,AT as bo,YS as bp,ma as bq,Kl as br,Dn as bs,Bw as bt,hc as bu,gk as bv,PB as bw,dm as bx,ek as by,_A as bz,GM as c,wm as c0,tk as c1,ct as c2,te as c3,to as c4,m1 as c5,xk as c6,rA as d,vu as e,uA as f,Tu as g,x1 as h,xm as i,PS as j,MT as k,pg as l,mm as m,iA as n,Vt as o,nt as p,VM as q,Cl as r,IS as s,y_ as t,TB as u,_B as v,Tg as w,ui as x,Ag as y,jS as z};