Home
last modified time | relevance | path

Searched refs:Ji (Results 1 – 25 of 30) sorted by relevance

12

/plugin/pdfjs/pdfjs/web/locale/ku/
H A Dviewer.properties97 find_match_case_label=Ji bo tîpên hûrdek-girdek bihîstyar
139 password_label=Ji bo PDFê vekî şîfreyê binivîse.
/plugin/bpmnio/vendor/bpmn-js/dist/
H A Dbpmn-navigated-viewer.production.min.js2 !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).BpmnJS=t()}(this,(function(){"use strict";function e(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}const t=Object.prototype.toString,n=Object.prototype.hasOwnProperty;function i(e){return void 0===e}function r(e){return void 0!==e}function o(e){return"[object Array]"===t.call(e)}function a(e){return"[object Object]"===t.call(e)}function s(e){return"[object Number]"===t.call(e)}function l(e){const n=t.call(e);return"[object Function]"===n||"[object AsyncFunction]"===n||"[object GeneratorFunction]"===n||"[object AsyncGeneratorFunction]"===n||"[object Proxy]"===n}function p(e){return"[object String]"===t.call(e)}function c(e,t){return n.call(e,t)}function u(e,t){const n=v(t);let i;return f(e,(function(e,t){if(n(e,t))return i=e,!1})),i}function h(e,t){const n=v(t);let i=[];return f(e,(function(e,t){n(e,t)&&i.push(e)})),i}function f(e,t){let n,r;if(i(e))return;const a=o(e)?b:x;for(let i in e)if(c(e,i)&&(n=e[i],r=t(n,a(i)),!1===r))return n}function m(e,t,n){return f(e,(function(e,i){n=t(n,e,i)})),n}function d(e,t){return!!m(e,(function(e,n,i){return e&&t(n,i)}),!0)}function y(e,t){return!!u(e,t)}function g(e){return function(t){return d(e,(function(e,n){return t[n]===e}))}}function v(e){return l(e)?e:t=>t===e}function x(e){return e}function b(e){return Number(e)}function w(e,t){return e.bind(t)}function E(e,...t){return Object.assign(e,...t)}function _(e,t){var n=this;t=t||1e3,e.on(["render.shape","render.connection"],t,(function(e,t){var i=e.type,r=t.element,o=t.gfx,a=t.attrs;if(n.canRender(r))return"render.shape"===i?n.drawShape(o,r,a):n.drawConnection(o,r,a)})),e.on(["render.getShapePath","render.getConnectionPath"],t,(function(e,t){if(n.canRender(t))return"render.getShapePath"===e.type?n.getShapePath(t):n.getConnectionPath(t)}))}function A(e,t){var n=k(e);return n&&"function"==typeof n.$instanceOf&&n.$instanceOf(t)}function k(e){return e&&e.businessObject||e}function R(e){return e&&e.di}function S(e,t){return!A(e,"bpmn:CallActivity")&&(A(e,"bpmn:SubProcess")?!(!(t=t||R(e))||!A(t,"bpmndi:BPMNPlane"))||t&&!!t.isExpanded:!A(e,"bpmn:Participant")||!!k(e).processRef)}function C(e){if(A(e,"bpmn:Participant")||A(e,"bpmn:Lane")){var t=R(e).isHorizontal;return void 0===t||t}}_.prototype.canRender=function(e){},_.prototype.drawShape=function(e,t){},_.prototype.drawConnection=function(e,t){},_.prototype.getShapePath=function(e){},_.prototype.getConnectionPath=function(e){};var M={width:90,height:20};function P(e){var t=e.length/2-1,n=e[Math.floor(t)],i=e[Math.ceil(t+.01)],r=function(e){var t=e.length/2-1,n=e[Math.floor(t)],i=e[Math.ceil(t+.01)];return{x:n.x+(i.x-n.x)/2,y:n.y+(i.y-n.y)/2}}(e),o=Math.atan((i.y-n.y)/(i.x-n.x)),a=r.x,s=r.y;return Math.abs(o)<Math.PI/2?s-=15:a+=15,{x:a,y:s}}function N(e,t){var n,i,r,o=e.label;return o&&o.bounds?(r=o.bounds,i={width:Math.max(M.width,r.width),height:r.height},n={x:r.x+r.width/2,y:r.y+r.height/2}):(n=function(e){return e.waypoints?P(e.waypoints):A(e,"bpmn:Group")?{x:e.x+e.width/2,y:e.y+M.height/2}:{x:e.x+e.width/2,y:e.y+e.height+M.height/2}}(t),i=M),E({x:n.x-i.width/2,y:n.y-i.height/2},i)}function T(e){var t=e.businessObject,n=function(e){return A(e,"bpmn:FlowElement")||A(e,"bpmn:Participant")||A(e,"bpmn:Lane")||A(e,"bpmn:SequenceFlow")||A(e,"bpmn:MessageFlow")||A(e,"bpmn:DataInput")||A(e,"bpmn:DataOutput")?"name":A(e,"bpmn:TextAnnotation")?"text":A(e,"bpmn:Group")?"categoryValueRef":void 0}(t);if(n)return"categoryValueRef"===n?function(e){var t=e.categoryValueRef;return t&&t.value||""}(t):t[n]||""}function D(e,t){return function(e,t){t.appendChild(function(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch(e){}return e}(e,t))}(t,e),e}var B={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":2,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":2,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function O(e,t,n){var i=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),r=B[i];r?(2===r&&"number"==typeof n&&(n=String(n)+"px"),e.style[i]=n):e.setAttributeNS(null,t,n)}function L(e,t,n){if("string"==typeof t){if(void 0===n)return function(e,t){return B[t]?e.style[t]:e.getAttributeNS(null,t)}(e,t);O(e,t,n)}else!function(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)O(e,i,t[i])}(e,t);return e}const I=Object.prototype.toString;function F(e){return new j(e)}function j(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}j.prototype.add=function(e){return this.list.add(e),this},j.prototype.remove=function(e){return"[object RegExp]"==I.call(e)?this.removeMatching(e):(this.list.remove(e),this)},j.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},j.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},j.prototype.array=function(){return Array.from(this.list)},j.prototype.has=j.prototype.contains=function(e){return this.list.contains(e)};var V="http://www.w3.org/2000/svg",W='<svg xmlns="'+V+'"';function z(e){var t=!1;"<svg"===e.substring(0,4)?-1===e.indexOf(V)&&(e=W+e.substring(4)):(e=W+">"+e+"</svg>",t=!0);var n=function(e){var t;return(t=new DOMParser).async=!1,t.parseFromString(e,"text/xml")}(e);if(!t)return n;for(var i=document.createDocumentFragment(),r=n.firstChild;r.firstChild;)i.appendChild(r.firstChild);return i}function $(e,t){var n;return"<"===(e=e.trim()).charAt(0)?(n=z(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(V,e),t&&L(n,t),n}var G=null;function H(){return null===G&&(G=$("svg")),G}function K(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)e[i]=t[i];return e}function U(e){return H().createSVGTransform()}var q=/([&<>]{1})/g,Y=/([\n\r"]{1})/g,X={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"'"};function Z(e,t){return e.replace(t,(function(e,t){return X[t]||t}))}function J(e,t){var n,i,r,o,a;switch(e.nodeType){case 3:t.push(Z(e.textContent,q));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(n=0,i=(r=e.attributes).length;n<i;++n)o=r.item(n),t.push(" ",o.name,'="',Z(o.value,Y),'"');if(e.hasChildNodes()){for(t.push(">"),n=0,i=(a=e.childNodes).length;n<i;++n)J(a.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("\x3c!--",Z(e.nodeValue,q),"--\x3e");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function Q(e,t){return function(e){for(var t=e.firstChild,n=[];t;)J(t,n),t=t.nextSibling;return n.join("")}(e)}function ee(e){var t=e.parentNode;return t&&t.removeChild(e),e}function te(e,t){return t instanceof SVGMatrix?e.createSVGTransformFromMatrix(t):t}function ne(e,t){var n=e.transform.baseVal;return t&&(Array.isArray(t)||(t=[t]),function(e,t){var n,i;for(e.clear(),n=0;i=t[n];n++)e.appendItem(te(e,i))}(n,t)),n.consolidate()}function ie(e){return e.flat().join(",").replace(/,?([A-Za-z]),?/g,"$1")}function re(e){return["L",e.x,e.y]}function oe(e,t){const n=e.length,i=[(r=e[0],["M",r.x,r.y])];var r,o,a,s;for(let r=1;r<n;r++){const n=e[r-1],l=e[r],p=e[r+1];if(!p||!t){i.push(re(l));continue}const c=Math.min(t,se(l.x-n.x,l.y-n.y),se(p.x-l.x,p.y-l.y));if(!c){i.push(re(l));continue}const u=ae(l,n,c),h=ae(l,n,.5*c),f=ae(l,p,c),m=ae(l,p,.5*c);i.push(re(u)),i.push((a=m,s=f,["C",(o=h).x,o.y,a.x,a.y,s.x,s.y]))}return i}function ae(e,t,n){const i=t.x-e.x,r=t.y-e.y,o=n/se(i,r);return{x:e.x+i*o,y:e.y+r*o}}function se(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}function le(e,t,n){s(t)&&(n=t,t=null),t||(t={});const i=$("path",t);return s(n)&&(i.dataset.cornerRadius=String(n)),pe(i,e)}function pe(e,t){return L(e,{d:ie(oe(t,parseInt(e.dataset.cornerRadius,10)||0))}),e}var ce="hsl(225, 10%, 15%)";function ue(e,t){return y(e.eventDefinitions,(function(e){return e.$type===t}))}function he(e,t,n){var i=R(e);return n||i.get("color:background-color")||i.get("bioc:fill")||t||"white"}function fe(e,t,n){var i=R(e);return n||i.get("color:border-color")||i.get("bioc:stroke")||t||ce}function me(e,t,n,i){var r=R(e).get("label");return i||r&&r.get("color:color")||t||fe(e,n)}function de(e,t={}){return{width:ye(e,t),height:ge(e,t)}}function ye(e,t={}){return c(t,"width")?t.width:e.width}function ge(e,t={}){return c(t,"height")?t.height:e.height}function ve(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}const xe=Object.prototype.toString,be=Object.prototype.hasOwnProperty;function we(e,t){return be.call(e,t)}function Ee(e,t){let n,i;if(void 0===e)return;const r=function(e){return"[object Array]"===xe.call(e)}(e)?Ae:_e;for(let o in e)if(we(e,o)&&(n=e[o],i=t(n,r(o)),!1===i))return n}function _e(e){return e}function Ae(e){return Number(e)}function ke(e,...t){const n=e.style;return Ee(t,(function(e){e&&Ee(e,(function(e,t){n[t]=e}))})),e}function Re(e,t,n){return 2==arguments.length?e.getAttribute(t):null===n?e.removeAttribute(t):(e.setAttribute(t,n),e)}const Se=Object.prototype.toString;function Ce(e){return new Me(e)}function Me(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}function Pe(e){for(var t;t=e.firstChild;)e.removeChild(t);return e}function Ne(e,t,n){var i=n?e:e.parentNode;return i&&"function"==typeof i.closest&&i.closest(t)||null}Me.prototype.add=function(e){return this.list.add(e),this},Me.prototype.remove=function(e){return"[object RegExp]"==Se.call(e)?this.removeMatching(e):(this.list.remove(e),this)},Me.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Me.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Me.prototype.array=function(){return Array.from(this.list)},Me.prototype.has=Me.prototype.contains=function(e){return this.list.contains(e)};var Te,De,Be,Oe={};function Le(){Te=window.addEventListener?"addEventListener":"attachEvent",De=window.removeEventListener?"removeEventListener":"detachEvent",Be="addEventListener"!==Te?"on":""}var Ie=ve({__proto__:null,bind:Oe.bind=function(e,t,n,i){return Te||Le(),e[Te](Be+t,n,i||!1),n},unbind:Oe.unbind=function(e,t,n,i){return De||Le(),e[De](Be+t,n,i||!1),n},default:Oe},[Oe]),Fe=["focus","blur"];var je,Ve={bind:function(e,t,n,i,r){return-1!==Fe.indexOf(n)&&(r=!0),Ie.bind(e,n,(function(n){var r=n.target||n.srcElement;n.delegateTarget=Ne(r,t,!0),n.delegateTarget&&i.call(e,n)}),r)},unbind:function(e,t,n,i){return-1!==Fe.indexOf(t)&&(i=!0),Ie.unbind(e,t,n,i)}},We=function(e,t){if("string"!=typeof e)throw new TypeError("String expected");t||(t=document);var n=/<([\w:]+)/.exec(e);if(!n)return t.createTextNode(e);e=e.replace(/^\s+|\s+$/g,"");var i=n[1];if("body"==i){return(r=t.createElement("html")).innerHTML=e,r.removeChild(r.lastChild)}var r,o=Object.prototype.hasOwnProperty.call($e,i)?$e[i]:$e._default,a=o[0],s=o[1],l=o[2];(r=t.createElement("div")).innerHTML=s+e+l;for(;a--;)r=r.lastChild;if(r.firstChild==r.lastChild)return r.removeChild(r.firstChild);var p=t.createDocumentFragment();for(;r.firstChild;)p.appendChild(r.removeChild(r.firstChild));return p},ze=!1;"undefined"!=typeof document&&((je=document.createElement("div")).innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',ze=!je.getElementsByTagName("link").length,je=void 0);var $e={legend:[1,"<fieldset>","</fieldset>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],_default:ze?[1,"X<div>","</div>"]:[0,"",""]};$e.td=$e.th=[3,"<table><tbody><tr>","</tr></tbody></table>"],$e.option=$e.optgroup=[1,'<select multiple="multiple">',"</select>"],$e.thead=$e.tbody=$e.colgroup=$e.caption=$e.tfoot=[1,"<table>","</table>"],$e.polyline=$e.ellipse=$e.polygon=$e.circle=$e.text=$e.line=$e.path=$e.rect=$e.g=[1,'<svg xmlns="http://www.w3.org/2000/svg" version="1.1">',"</svg>"];var Ge=We;function He(e,t){return(t=t||document).querySelector(e)}function Ke(e){e.parentNode&&e.parentNode.removeChild(e)}function Ue(e,t,n,i,r){var o=U();o.setTranslate(t,n);var a=U();a.setRotate(i||0,0,0);var s=U();s.setScale(1,1),ne(e,[o,a,s])}function qe(e,t,n){var i=U();i.setTranslate(t,n),ne(e,i)}var Ye=function(e,t){return e(t={exports:{}},t.exports),t.exports}((function(e){var t=e.exports=function(e,n){if(n||(n=16),void 0===e&&(e=128),e<=0)return"0";for(var i=Math.log(Math.pow(2,e))/Math.log(n),r=2;i===1/0;r*=2)i=Math.log(Math.pow(2,e/r))/Math.log(n)*r;var o=i-Math.floor(i),a="";for(r=0;r<Math.floor(i);r++){a=Math.floor(Math.random()*n).toString(n)+a}if(o){var s=Math.pow(n,o);a=Math.floor(Math.random()*s).toString(n)+a}var l=parseInt(a,n);return l!==1/0&&l>=Math.pow(2,e)?t(e,n):a};t.rack=function(e,n,i){var r=function(r){var a=0;do{if(a++>10){if(!i)throw new Error("too many ID collisions, use more bits");e+=i}var s=t(e,n)}while(Object.hasOwnProperty.call(o,s));return o[s]=r,s},o=r.hats={};return r.get=function(e){return r.hats[e]},r.set=function(e,t){return r.hats[e]=t,r},r.bits=e||128,r.base=n||16,r}}));function Xe(e){if(!(this instanceof Xe))return new Xe(e);e=e||[128,36,1],this._seed=e.length?Ye.rack(e[0],e[1],e[2]):e}Xe.prototype.next=function(e){return this._seed(e||!0)},Xe.prototype.nextPrefixed=function(e,t){var n;do{n=e+this.next(!0)}while(this.assigned(n));return this.claim(n,t),n},Xe.prototype.claim=function(e,t){this._seed.set(e,t||!0)},Xe.prototype.assigned=function(e){return this._seed.get(e)||!1},Xe.prototype.unclaim=function(e){delete this._seed.hats[e]},Xe.prototype.clear=function(){var e,t=this._seed.hats;for(e in t)this.unclaim(e)};var Ze=new Xe,Je=.95;function Qe(e,t,n,i,r,o,s){_.call(this,t,s);var l=e&&e.defaultFillColor,p=e&&e.defaultStrokeColor,c=e&&e.defaultLabelColor;function u(e){return n.computeStyle(e,{strokeLinecap:"round",strokeLinejoin:"round",stroke:ce,strokeWidth:2,fill:"white"})}function h(e){return n.computeStyle(e,["no-fill"],{strokeLinecap:"round",strokeLinejoin:"round",stroke:ce,strokeWidth:2})}function m(e,t){var{ref:n={x:0,y:0},scale:i=1,element:o,parentGfx:a=r._svg}=t,s=$("marker",{id:e,viewBox:"0 0 20 20",refX:n.x,refY:n.y,markerWidth:20*i,markerHeight:20*i,orient:"auto"});D(s,o);var l=He(":scope > defs",a);l||D(a,l=$("defs")),D(l,s)}function d(e,t,n,i){var r=Ze.nextPrefixed("marker-");return function(e,t,n,i,r){if("sequenceflow-end"===n){m(t,{element:$("path",{d:"M 1 5 L 11 10 L 1 15 Z",...u({fill:r,stroke:r,strokeWidth:1})}),ref:{x:11,y:10},scale:.5,parentGfx:e})}if("messageflow-start"===n){m(t,{element:$("circle",{cx:6,cy:6,r:3.5,...u({fill:i,stroke:r,strokeWidth:1,strokeDasharray:[1e4,1]})}),ref:{x:6,y:6},parentGfx:e})}if("messageflow-end"===n){m(t,{element:$("path",{d:"m 1 5 l 0 -3 l 7 3 l -7 3 z",...u({fill:i,stroke:r,strokeWidth:1,strokeDasharray:[1e4,1]})}),ref:{x:8.5,y:5},parentGfx:e})}if("association-start"===n){m(t,{element:$("path",{d:"M 11 5 L 1 10 L 11 15",...h({fill:"none",stroke:r,strokeWidth:1.5,strokeDasharray:[1e4,1]})}),ref:{x:1,y:10},scale:.5,parentGfx:e})}if("association-end"===n){m(t,{element:$("path",{d:"M 1 5 L 11 10 L 1 15",...h({fill:"none",stroke:r,strokeWidth:1.5,strokeDasharray:[1e4,1]})}),ref:{x:11,y:10},scale:.5,parentGfx:e})}if("conditional-flow-marker"===n){m(t,{element:$("path",{d:"M 0 10 L 8 6 L 16 10 L 8 14 Z",...u({fill:i,stroke:r})}),ref:{x:-1,y:10},scale:.5,parentGfx:e})}if("conditional-default-flow-marker"===n){m(t,{element:$("path",{d:"M 6 4 L 10 16",...u({stroke:r,fill:"none"})}),ref:{x:0,y:10},scale:.5,parentGfx:e})}}(e,r,t,n,i),"url(#"+r+")"}function y(e,t,n,i,r={}){a(i)&&(r=i,i=0),i=i||0,r=u(r);var o=$("circle",{cx:t/2,cy:n/2,r:Math.round((t+n)/4-i),...r});return D(e,o),o}function g(e,t,n,i,r,o){a(r)&&(o=r,r=0),r=r||0,o=u(o);var s=$("rect",{x:r,y:r,width:t-2*r,height:n-2*r,rx:i,ry:i,...o});return D(e,s),s}function v(e,t,n,i){var r=le(t,n=h(n),i);return D(e,r),r}function x(e,t,n){return v(e,t,n,5)}function b(e,t,n){n=h(n);var i=$("path",{...n,d:t});return D(e,i),i}function w(e,t,n,i){return b(t,n,E({"data-marker":e},i))}function M(e){return be[e]}function P(e){return function(t,n,i){return M(e)(t,n,i)}}var N=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_MESSAGE",{xScaleFactor:.9,yScaleFactor:.9,containerWidth:t.width,containerHeight:t.height,position:{mx:.235,my:.315}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:r?he(t,l,n.fill):fe(t,p,n.stroke),strokeWidth:1})},B=function(e,t,n={}){var r=y(e,t.width,t.height,.2*t.height,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:2});b(e,i.getScaledPath("EVENT_TIMER_WH",{xScaleFactor:.75,yScaleFactor:.75,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.5}}),{stroke:fe(t,p,n.stroke),strokeWidth:2});for(var o=0;o<12;o++){var a=i.getScaledPath("EVENT_TIMER_LINE",{xScaleFactor:.75,yScaleFactor:.75,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.5}}),s=t.width/2,c=t.height/2;b(e,a,{strokeWidth:1,stroke:fe(t,p,n.stroke),transform:"rotate("+30*o+","+c+","+s+")"})}return r},O=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_ESCALATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.2}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},I=function(e,t,n={}){return b(e,i.getScaledPath("EVENT_CONDITIONAL",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.222}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},j=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_LINK",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.57,my:.263}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},V=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_ERROR",{xScaleFactor:1.1,yScaleFactor:1.1,containerWidth:t.width,containerHeight:t.height,position:{mx:.2,my:.722}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},W=function(e,t,n={},r){var o=b(e,i.getScaledPath("EVENT_CANCEL_45",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.638,my:-.055}}),{fill:r?fe(t,p,n.stroke):"none",stroke:fe(t,p,n.stroke),strokeWidth:1});return function(e,t){var n=U();n.setRotate(t,0,0),ne(e,n)}(o,45),o},z=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_COMPENSATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.22,my:.5}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},G=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_SIGNAL",{xScaleFactor:.9,yScaleFactor:.9,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.2}}),{strokeWidth:1,fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},H=function(e,t,n={},r){return b(e,i.getScaledPath("EVENT_MULTIPLE",{xScaleFactor:1.1,yScaleFactor:1.1,containerWidth:t.width,containerHeight:t.height,position:{mx:.222,my:.36}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),strokeWidth:1})},K=function(e,t,n={}){return b(e,i.getScaledPath("EVENT_PARALLEL_MULTIPLE",{xScaleFactor:1.2,yScaleFactor:1.2,containerWidth:t.width,containerHeight:t.height,position:{mx:.458,my:.194}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},q=function(e,t,n={}){return y(e,t.width,t.height,8,{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:4})};function Y(e,t,n={}){var i=k(e),r=function(e){return"bpmn:IntermediateThrowEvent"===e.$type||"bpmn:EndEvent"===e.$type}(i);return i.get("eventDefinitions")&&i.get("eventDefinitions").length>1?i.get("parallelMultiple")?K(t,e,n,r):H(t,e,n,r):ue(i,"bpmn:MessageEventDefinition")?N(t,e,n,r):ue(i,"bpmn:TimerEventDefinition")?B(t,e,n,r):ue(i,"bpmn:ConditionalEventDefinition")?I(t,e,n,r):ue(i,"bpmn:SignalEventDefinition")?G(t,e,n,r):ue(i,"bpmn:EscalationEventDefinition")?O(t,e,n,r):ue(i,"bpmn:LinkEventDefinition")?j(t,e,n,r):ue(i,"bpmn:ErrorEventDefinition")?V(t,e,n,r):ue(i,"bpmn:CancelEventDefinition")?W(t,e,n,r):ue(i,"bpmn:CompensateEventDefinition")?z(t,e,n,r):ue(i,"bpmn:TerminateEventDefinition")?q(t,e,n,r):null}var X={ParticipantMultiplicityMarker:function(e,t,n={}){var r=ye(t,n),o=ge(t,n);w("participant-multiplicity",e,i.getScaledPath("MARKER_PARALLEL",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2-6)/r,my:(o-15)/o}}),{strokeWidth:2,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},SubProcessMarker:function(e,t,n={}){qe(g(e,14,14,0,{strokeWidth:1,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)}),t.width/2-7.5,t.height-20),w("sub-process",e,i.getScaledPath("MARKER_SUB_PROCESS",{xScaleFactor:1.5,yScaleFactor:1.5,containerWidth:t.width,containerHeight:t.height,position:{mx:(t.width/2-7.5)/t.width,my:(t.height-20)/t.height}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},ParallelMarker:function(e,t,n){var r=ye(t,n),o=ge(t,n);w("parallel",e,i.getScaledPath("MARKER_PARALLEL",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2+n.parallel)/r,my:(o-20)/o}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},SequentialMarker:function(e,t,n){w("sequential",e,i.getScaledPath("MARKER_SEQUENTIAL",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:(t.width/2+n.seq)/t.width,my:(t.height-19)/t.height}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},CompensationMarker:function(e,t,n){w("compensation",e,i.getScaledPath("MARKER_COMPENSATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:(t.width/2+n.compensation)/t.width,my:(t.height-13)/t.height}}),{strokeWidth:1,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},LoopMarker:function(e,t,n){var r=ye(t,n),o=ge(t,n);w("loop",e,i.getScaledPath("MARKER_LOOP",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2+n.loop)/r,my:(o-7)/o}}),{strokeWidth:1.5,fill:"none",stroke:fe(t,p,n.stroke),strokeMiterlimit:.5})},AdhocMarker:function(e,t,n){var r=ye(t,n),o=ge(t,n);w("adhoc",e,i.getScaledPath("MARKER_ADHOC",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2+n.adhoc)/r,my:(o-15)/o}}),{strokeWidth:1,fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke)})}};function Z(e,t,n,i){X[e](t,n,i)}function J(e,t,n,i={}){i={fill:i.fill,stroke:i.stroke,width:ye(t,i),height:ge(t,i)};var r=k(t),o=n&&n.includes("SubProcessMarker");i=o?{...i,seq:-21,parallel:-22,compensation:-42,loop:-18,adhoc:10}:{...i,seq:-5,parallel:-6,compensation:-27,loop:0,adhoc:10},f(n,(function(n){Z(n,e,t,i)})),r.get("isForCompensation")&&Z("CompensationMarker",e,t,i),A(r,"bpmn:AdHocSubProcess")&&Z("AdhocMarker",e,t,i);var a=r.get("loopCharacteristics"),s=a&&a.get("isSequential");a&&(void 0===s&&Z("LoopMarker",e,t,i),!1===s&&Z("ParallelMarker",e,t,i),!0===s&&Z("SequentialMarker",e,t,i))}function Q(e,t,n={}){n=E({size:{width:100}},n);var i=o.createText(t||"",n);return F(i).add("djs-label"),D(e,i),i}function ee(e,t,n,i={}){var r=k(t),o=de({x:t.x,y:t.y,width:t.width,height:t.height},i);return Q(e,r.name,{align:n,box:o,padding:7,style:{fill:me(t,c,p,i.stroke)}})}function te(e,t,n,i={}){var r=C(n),o=Q(e,t,{box:{height:30,width:r?ge(n,i):ye(n,i)},align:"center-middle",style:{fill:me(n,c,p,i.stroke)}});r&&Ue(o,0,-(-1*ge(n,i)),270)}function ie(e,t,n={}){var{width:i,height:r}=de(t,n);return g(e,i,r,10,{...n,fill:he(t,l,n.fill),fillOpacity:Je,stroke:fe(t,p,n.stroke)})}function re(e,t,n={}){var i=k(t),r=he(t,l,n.fill),o=fe(t,p,n.stroke);return"One"!==i.get("associationDirection")&&"Both"!==i.get("associationDirection")||(n.markerEnd=d(e,"association-end",r,o)),"Both"===i.get("associationDirection")&&(n.markerStart=d(e,"association-start",r,o)),n=et(n,["markerStart","markerEnd"]),x(e,t.waypoints,{...n,stroke:o,strokeDasharray:"0, 5"})}function oe(e,t,n={}){var r=he(t,l,n.fill),o=fe(t,p,n.stroke),a=b(e,i.getScaledPath("DATA_OBJECT_PATH",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.474,my:.296}}),{fill:r,fillOpacity:Je,stroke:o});(function(e){var t=e.dataObjectRef;return e.isCollection||t&&t.isCollection})(k(t))&&b(e,i.getScaledPath("DATA_OBJECT_COLLECTION_PATH",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.33,my:(t.height-18)/t.height}}),{strokeWidth:2,fill:r,stroke:o});return a}function ae(e,t,n={}){return y(e,t.width,t.height,{fillOpacity:Je,...n,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})}function se(e,t,n={}){return function(e,t,n,i){var r=t/2,o=n/2,a=[{x:r,y:0},{x:t,y:o},{x:r,y:n},{x:0,y:o}].map((function(e){return e.x+","+e.y})).join(" ");i=u(i);var s=$("polygon",{...i,points:a});return D(e,s),s}(e,t.width,t.height,{fill:he(t,l,n.fill),fillOpacity:Je,stroke:fe(t,p,n.stroke)})}function pe(e,t,n={}){var i=g(e,ye(t,n),ge(t,n),0,{fill:he(t,l,n.fill),fillOpacity:n.fillOpacity||Je,stroke:fe(t,p,n.stroke),strokeWidth:1.5}),r=k(t);A(r,"bpmn:Lane")&&te(e,r.get("name"),t,n);return i}function ve(e,t,n={}){var i=ie(e,t,n);(function(e){return e&&!!k(e).triggeredByEvent})(t)&&L(i,{strokeDasharray:"0, 5.5",strokeWidth:2.5});var r=S(t);return ee(e,t,r?"center-top":"center-middle",n),J(e,t,r?void 0:["SubProcessMarker"],n),i}function xe(e,t,n={}){var i=ie(e,t,n);return ee(e,t,"center-middle",n),J(e,t,void 0,n),i}var be=this.handlers={"bpmn:AdHocSubProcess":function(e,t,n={}){return ve(e,t,n=S(t)?et(n,["fill","stroke","width","height"]):et(n,["fill","stroke"]))},"bpmn:Association":function(e,t,n={}){return re(e,t,n=et(n,["fill","stroke"]))},"bpmn:BoundaryEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=et(n,["fill","stroke"]);var r=k(t).get("cancelActivity");n={strokeWidth:1.5,fill:he(t,l,n.fill),fillOpacity:1,stroke:fe(t,p,n.stroke)},r||(n.strokeDasharray="6");var o=ae(e,t,n);return y(e,t.width,t.height,3,{...n,fill:"none"}),i&&Y(t,e,n),o},"bpmn:BusinessRuleTask":function(e,t,n={}){var r=xe(e,t,n=et(n,["fill","stroke"]));return L(b(e,i.getScaledPath("TASK_TYPE_BUSINESS_RULE_MAIN",{abspos:{x:8,y:8}})),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),L(b(e,i.getScaledPath("TASK_TYPE_BUSINESS_RULE_HEADER",{abspos:{x:8,y:8}})),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:CallActivity":function(e,t,n={}){return n=et(n,["fill","stroke"]),ve(e,t,{strokeWidth:5,...n})},"bpmn:ComplexGateway":function(e,t,n={}){var r=se(e,t,n=et(n,["fill","stroke"]));return b(e,i.getScaledPath("GATEWAY_COMPLEX",{xScaleFactor:.5,yScaleFactor:.5,containerWidth:t.width,containerHeight:t.height,position:{mx:.46,my:.26}}),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:DataInput":function(e,t,n={}){n=et(n,["fill","stroke"]);var r=i.getRawPath("DATA_ARROW"),o=oe(e,t,n);return b(e,r,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1}),o},"bpmn:DataInputAssociation":function(e,t,n={}){return n=et(n,["fill","stroke"]),re(e,t,{...n,markerEnd:d(e,"association-end",he(t,l,n.fill),fe(t,p,n.stroke))})},"bpmn:DataObject":function(e,t,n={}){return oe(e,t,n=et(n,["fill","stroke"]))},"bpmn:DataObjectReference":P("bpmn:DataObject"),"bpmn:DataOutput":function(e,t,n={}){n=et(n,["fill","stroke"]);var r=i.getRawPath("DATA_ARROW"),o=oe(e,t,n);return b(e,r,{strokeWidth:1,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)}),o},"bpmn:DataOutputAssociation":function(e,t,n={}){return n=et(n,["fill","stroke"]),re(e,t,{...n,markerEnd:d(e,"association-end",he(t,l,n.fill),fe(t,p,n.stroke))})},"bpmn:DataStoreReference":function(e,t,n={}){return n=et(n,["fill","stroke"]),b(e,i.getScaledPath("DATA_STORE",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:0,my:.133}}),{fill:he(t,l,n.fill),fillOpacity:Je,stroke:fe(t,p,n.stroke),strokeWidth:2})},"bpmn:EndEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=et(n,["fill","stroke"]);var r=ae(e,t,{...n,strokeWidth:4});return i&&Y(t,e,n),r},"bpmn:EventBasedGateway":function(e,t,n={}){n=et(n,["fill","stroke"]);var r=k(t),o=se(e,t,n);y(e,t.width,t.height,.2*t.height,{fill:he(t,"none",n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1});var a=r.get("eventGatewayType"),s=!!r.get("instantiate");if("Parallel"===a){var l=i.getScaledPath("GATEWAY_PARALLEL",{xScaleFactor:.4,yScaleFactor:.4,containerWidth:t.width,containerHeight:t.height,position:{mx:.474,my:.296}});b(e,l,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1})}else"Exclusive"===a&&(s||y(e,t.width,t.height,.26*t.height,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1}),function(){var r=i.getScaledPath("GATEWAY_EVENT_BASED",{xScaleFactor:.18,yScaleFactor:.18,containerWidth:t.width,containerHeight:t.height,position:{mx:.36,my:.44}});b(e,r,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:2})}());return o},"bpmn:ExclusiveGateway":function(e,t,n={}){var r=se(e,t,n=et(n,["fill","stroke"])),o=i.getScaledPath("GATEWAY_EXCLUSIVE",{xScaleFactor:.4,yScaleFactor:.4,containerWidth:t.width,containerHeight:t.height,position:{mx:.32,my:.3}});return R(t).get("isMarkerVisible")&&b(e,o,{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:Gateway":function(e,t,n={}){return se(e,t,n=et(n,["fill","stroke"]))},"bpmn:Group":function(e,t,n={}){return n=et(n,["fill","stroke","width","height"]),g(e,t.width,t.height,10,{stroke:fe(t,p,n.stroke),strokeWidth:1.5,strokeDasharray:"10, 6, 0, 6",fill:"none",pointerEvents:"none",width:ye(t,n),height:ge(t,n)})},"bpmn:InclusiveGateway":function(e,t,n={}){var i=se(e,t,n=et(n,["fill","stroke"]));return y(e,t.width,t.height,.24*t.height,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:2.5}),i},"bpmn:IntermediateEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=et(n,["fill","stroke"]);var r=ae(e,t,{...n,strokeWidth:1.5});return y(e,t.width,t.height,3,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1.5}),i&&Y(t,e,n),r},"bpmn:IntermediateCatchEvent":P("bpmn:IntermediateEvent"),"bpmn:IntermediateThrowEvent":P("bpmn:IntermediateEvent"),"bpmn:Lane":function(e,t,n={}){return n=et(n,["fill","stroke","width","height"]),pe(e,t,{...n,fillOpacity:.25})},"bpmn:ManualTask":function(e,t,n={}){var r=xe(e,t,n=et(n,["fill","stroke"]));return b(e,i.getScaledPath("TASK_TYPE_MANUAL",{abspos:{x:17,y:15}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:.5}),r},"bpmn:MessageFlow":function(e,t,n={}){n=et(n,["fill","stroke"]);var r=k(t),o=R(t),a=he(t,l,n.fill),s=fe(t,p,n.stroke),c=x(e,t.waypoints,{markerEnd:d(e,"messageflow-end",a,s),markerStart:d(e,"messageflow-start",a,s),stroke:s,strokeDasharray:"10, 11",strokeWidth:1.5});if(r.get("messageRef")){var u=c.getPointAtLength(c.getTotalLength()/2),h=i.getScaledPath("MESSAGE_FLOW_MARKER",{abspos:{x:u.x,y:u.y}}),f={strokeWidth:1};"initiating"===o.get("messageVisibleKind")?(f.fill=a,f.stroke=s):(f.fill=s,f.stroke=a);var m=b(e,h,f),y=Q(e,r.get("messageRef").get("name"),{align:"center-top",fitBox:!0,style:{fill:s}}),g=m.getBBox(),v=y.getBBox();Ue(y,u.x-v.width/2,u.y+g.height/2+10,0)}return c},"bpmn:ParallelGateway":function(e,t,n={}){var r=se(e,t,n=et(n,["fill","stroke"]));return b(e,i.getScaledPath("GATEWAY_PARALLEL",{xScaleFactor:.6,yScaleFactor:.6,containerWidth:t.width,containerHeight:t.height,position:{mx:.46,my:.2}}),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:Participant":function(e,t,n={}){var i=pe(e,t,n=et(n,["fill","stroke","width","height"])),r=S(t),o=C(t),a=k(t),s=a.get("name");if(r){v(e,o?[{x:30,y:0},{x:30,y:ge(t,n)}]:[{x:0,y:30},{x:ye(t,n),y:30}],{stroke:fe(t,p,n.stroke),strokeWidth:1.5}),te(e,s,t,n)}else{var l=de(t,n);o||(l.height=ye(t,n),l.width=ge(t,n));var u=Q(e,s,{box:l,align:"center-middle",style:{fill:me(t,c,p,n.stroke)}});if(!o)Ue(u,0,-(-1*ge(t,n)),270)}return a.get("participantMultiplicity")&&Z("ParticipantMultiplicityMarker",e,t,n),i},"bpmn:ReceiveTask":function(e,t,n={}){n=et(n,["fill","stroke"]);var r,o=k(t),a=xe(e,t,n);return o.get("instantiate")?(y(e,28,28,4.4,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),r=i.getScaledPath("TASK_TYPE_INSTANTIATING_SEND",{abspos:{x:7.77,y:9.52}})):r=i.getScaledPath("TASK_TYPE_SEND",{xScaleFactor:.9,yScaleFactor:.9,containerWidth:21,containerHeight:14,position:{mx:.3,my:.4}}),b(e,r,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),a},"bpmn:ScriptTask":function(e,t,n={}){var r=xe(e,t,n=et(n,["fill","stroke"]));return b(e,i.getScaledPath("TASK_TYPE_SCRIPT",{abspos:{x:15,y:20}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:SendTask":function(e,t,n={}){var r=xe(e,t,n=et(n,["fill","stroke"]));return b(e,i.getScaledPath("TASK_TYPE_SEND",{xScaleFactor:1,yScaleFactor:1,containerWidth:21,containerHeight:14,position:{mx:.285,my:.357}}),{fill:fe(t,p,n.stroke),stroke:he(t,l,n.fill),strokeWidth:1}),r},"bpmn:SequenceFlow":function(e,t,n={}){n=et(n,["fill","stroke"]);var i=he(t,l,n.fill),r=fe(t,p,n.stroke),o=x(e,t.waypoints,{markerEnd:d(e,"sequenceflow-end",i,r),stroke:r}),a=k(t),{source:s}=t;if(s){var c=k(s);a.get("conditionExpression")&&A(c,"bpmn:Activity")&&L(o,{markerStart:d(e,"conditional-flow-marker",i,r)}),c.get("default")&&(A(c,"bpmn:Gateway")||A(c,"bpmn:Activity"))&&c.get("default")===a&&L(o,{markerStart:d(e,"conditional-default-flow-marker",i,r)})}return o},"bpmn:ServiceTask":function(e,t,n={}){var r=xe(e,t,n=et(n,["fill","stroke"]));return y(e,10,10,{fill:he(t,l,n.fill),stroke:"none",transform:"translate(6, 6)"}),b(e,i.getScaledPath("TASK_TYPE_SERVICE",{abspos:{x:12,y:18}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),y(e,10,10,{fill:he(t,l,n.fill),stroke:"none",transform:"translate(11, 10)"}),b(e,i.getScaledPath("TASK_TYPE_SERVICE",{abspos:{x:17,y:22}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:StartEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=et(n,["fill","stroke"]),k(t).get("isInterrupting")||(n={...n,strokeDasharray:"6"});var r=ae(e,t,n);return i&&Y(t,e,n),r},"bpmn:SubProcess":function(e,t,n={}){return ve(e,t,n=S(t)?et(n,["fill","stroke","width","height"]):et(n,["fill","stroke"]))},"bpmn:Task":function(e,t,n={}){return xe(e,t,n=et(n,["fill","stroke"]))},"bpmn:TextAnnotation":function(e,t,n={}){n=et(n,["fill","stroke","width","height"]);var{width:r,height:o}=de(t,n),a=g(e,r,o,0,0,{fill:"none",stroke:"none"});return b(e,i.getScaledPath("TEXT_ANNOTATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:0,my:0}}),{stroke:fe(t,p,n.stroke)}),Q(e,k(t).get("text")||"",{align:"left-top",box:de(t,n),padding:7,style:{fill:me(t,c,p,n.stroke)}}),a},"bpmn:Transaction":function(e,t,i={}){i=S(t)?et(i,["fill","stroke","width","height"]):et(i,["fill","stroke"]);var r=ve(e,t,{strokeWidth:1.5,...i}),o=n.style(["no-fill","no-events"],{stroke:fe(t,p,i.stroke),strokeWidth:1.5});return S(t)||(i={}),g(e,ye(t,i),ge(t,i),7,3,o),r},"bpmn:UserTask":function(e,t,n={}){var r=xe(e,t,n=et(n,["fill","stroke"]));return b(e,i.getScaledPath("TASK_TYPE_USER_1",{abspos:{x:15,y:12}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:.5}),b(e,i.getScaledPath("TASK_TYPE_USER_2",{abspos:{x:15,y:12}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:.5}),b(e,i.getScaledPath("TASK_TYPE_USER_3",{abspos:{x:15,y:12}}),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:.5}),r},label:function(e,t,n={}){return function(e,t,n={}){var i={width:90,height:30,x:t.width/2+t.x,y:t.height/2+t.y};return Q(e,T(t),{box:i,fitBox:!0,style:E({},o.getExternalStyle(),{fill:me(t,c,p,n.stroke)})})}(e,t,n)}};this._drawPath=b,this._renderer=M}function et(e,t=[]){return t.reduce(((t,n)=>(e[n]&&(t[n]=e[n]),t)),{})}e(Qe,_),Qe.$inject=["config.bpmnRenderer","eventBus","styles","pathMap","canvas","textRenderer"],Qe.prototype.canRender=function(e){return A(e,"bpmn:BaseElement")},Qe.prototype.drawShape=function(e,t,n={}){var{type:i}=t;return this._renderer(i)(e,t,n)},Qe.prototype.drawConnection=function(e,t,n={}){var{type:i}=t;return this._renderer(i)(e,t,n)},Qe.prototype.getShapePath=function(e){return A(e,"bpmn:Event")?function(e){var t=e.x+e.width/2,n=e.y+e.height/2,i=e.width/2;return ie([["M",t,n],["m",0,-i],["a",i,i,0,1,1,0,2*i],["a",i,i,0,1,1,0,-2*i],["z"]])}(e):A(e,"bpmn:Activity")?function(e,t){var n=e.x,i=e.y,r=e.width,o=e.height;return ie([["M",n+t,i],["l",r-2*t,0],["a",t,t,0,0,1,t,t],["l",0,o-2*t],["a",t,t,0,0,1,-t,t],["l",2*t-r,0],["a",t,t,0,0,1,-t,-t],["l",0,2*t-o],["a",t,t,0,0,1,t,-t],["z"]])}(e,10):A(e,"bpmn:Gateway")?function(e){var t=e.width/2,n=e.height/2;return ie([["M",e.x+t,e.y],["l",t,n],["l",-t,n],["l",-t,-n],["z"]])}(e):function(e){var t=e.x,n=e.y,i=e.width;return ie([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])}(e)};var tt={width:150,height:50};function nt(e,t){var n;t.textContent=e;try{var i,r=""===e;return t.textContent=r?"dummy":e,i={width:(n=t.getBBox()).width+2*n.x,height:n.height},r&&(i.width=0),i}catch(e){return console.log(e),{width:0,height:0}}}function it(e,t,n){for(var i,r=e.shift(),o=r;;){if((i=nt(o,n)).width=o?i.width:0," "===o||""===o||i.width<Math.round(t)||o.length<2)return rt(e,o,r,i);o=at(o,i.width,t)}}function rt(e,t,n,i){if(t.length<n.length){var r=n.slice(t.length).trim();e.unshift(r)}return{width:i.width,height:i.height,text:t}}var ot="­";function at(e,t,n){var i=Math.max(e.length*(n/t),1),r=function(e,t){var n,i=e.split(/(\s|-|\u00AD)/g),r=[],o=0;if(i.length>1)for(;n=i.shift();){if(!(n.length+o<t)){"-"!==n&&n!==ot||r.pop();break}r.push(n),o+=n.length}var a=r[r.length-1];return a&&a===ot&&(r[r.length-1]="-"),r.join("")}(e,i);return r||(r=e.slice(0,Math.max(Math.round(i-1),1))),r}function st(e){this._config=E({},{size:tt,padding:0,style:{},align:"center-top"},e||{})}st.prototype.createText=function(e,t){return this.layoutText(e,t).element},st.prototype.getDimensions=function(e,t){return this.layoutText(e,t).dimensions},st.prototype.layoutText=function(e,t){var n=E({},this._config.size,t.box),i=E({},this._config.style,t.style),r=function(e){var t=e.split("-");return{horizontal:t[0]||"center",vertical:t[1]||"top"}}(t.align||this._config.align),o=function(e){return a(e)?E({top:0,left:0,right:0,bottom:0},e):{top:e,left:e,right:e,bottom:e}}(void 0!==t.padding?t.padding:this._config.padding),s=t.fitBox||!1,l=function(e){if("fontSize"in e&&"lineHeight"in e)return e.lineHeight*parseInt(e.fontSize,10)}(i),p=e.split(/\u00AD?\r?\n/),c=[],u=n.width-o.left-o.right,h=$("text");for(L(h,{x:0,y:0}),L(h,i),D(function(){var e=document.getElementById("helper-svg");return e||(L(e=$("svg"),{id:"helper-svg"}),ke(e,{visibility:"hidden",position:"fixed",width:0,height:0}),document.body.appendChild(e)),e}(),h);p.length;)c.push(it(p,u,h));"middle"===r.vertical&&(o.top=o.bottom=0);var d=m(c,(function(e,t,n){return e+(l||t.height)}),0)+o.top+o.bottom,y=m(c,(function(e,t,n){return t.width>e?t.width:e}),0),g=o.top;"middle"===r.vertical&&(g+=(n.height-d)/2),g-=(l||c[0].height)/4;var v=$("text");return L(v,i),f(c,(function(e){var t;switch(g+=l||e.height,r.horizontal){case"left":t=o.left;break;case"right":t=(s?y:u)-o.right-e.width;break;default:t=Math.max(((s?y:u)-e.width)/2+o.left,0)}var n=$("tspan");L(n,{x:t,y:g}),n.textContent=e.text,D(v,n)})),ee(h),{dimensions:{width:y,height:d},element:v}};function lt(e){var t=E({fontFamily:"Arial, sans-serif",fontSize:12,fontWeight:"normal",lineHeight:1.2},e&&e.defaultStyle||{}),n=parseInt(t.fontSize,10)-1,i=E({},t,{fontSize:n},e&&e.externalStyle||{}),r=new st({style:t});this.getExternalLabelBounds=function(e,t){var n=r.getDimensions(t,{box:{width:90,height:30},style:i});return{x:Math.round(e.x+e.width/2-n.width/2),y:Math.round(e.y),width:Math.ceil(n.width),height:Math.ceil(n.height)}},this.getTextAnnotationBounds=function(e,n){var i=r.getDimensions(n,{box:e,style:t,align:"left-top",padding:5});return{x:e.x,y:e.y,width:e.width,height:Math.max(30,Math.round(i.height))}},this.createText=function(e,t){return r.createText(e,t||{})},this.getDefaultStyle=function(){return t},this.getExternalStyle=function(){return i}}lt.$inject=["config.textRenderer"];var pt=/\{([^{}]+)\}/g,ct=/(?:(?:^|\.)(.+?)(?=\[|\.|$|\()|\[('|")(.+?)\2\])(\(\))?/g;var ut={__init__:["bpmnRenderer"],bpmnRenderer:["type",Qe],textRenderer:["type",lt],pathMap:["type",function(){this.pathMap={EVENT_MESSAGE:{d:"m {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}",height:36,width:36,heightElements:[6,14],widthElements:[10.5,21]},EVENT_SIGNAL:{d:"M {mx},{my} l {e.x0},{e.y0} l -{e.x1},0 Z",height:36,width:36,heightElements:[18],widthElements:[10,20]},EVENT_ESCALATION:{d:"M {mx},{my} l {e.x0},{e.y0} l -{e.x0},-{e.y1} l -{e.x0},{e.y1} Z",height:36,width:36,heightElements:[20,7],widthElements:[8]},EVENT_CONDITIONAL:{d:"M {e.x0},{e.y0} l {e.x1},0 l 0,{e.y2} l -{e.x1},0 Z M {e.x2},{e.y3} l {e.x0},0 M {e.x2},{e.y4} l {e.x0},0 M {e.x2},{e.y5} l {e.x0},0 M {e.x2},{e.y6} l {e.x0},0 M {e.x2},{e.y7} l {e.x0},0 M {e.x2},{e.y8} l {e.x0},0 ",height:36,width:36,heightElements:[8.5,14.5,18,11.5,14.5,17.5,20.5,23.5,26.5],widthElements:[10.5,14.5,12.5]},EVENT_LINK:{d:"m {mx},{my} 0,{e.y0} -{e.x1},0 0,{e.y1} {e.x1},0 0,{e.y0} {e.x0},-{e.y2} -{e.x0},-{e.y2} z",height:36,width:36,heightElements:[4.4375,6.75,7.8125],widthElements:[9.84375,13.5]},EVENT_ERROR:{d:"m {mx},{my} {e.x0},-{e.y0} {e.x1},-{e.y1} {e.x2},{e.y2} {e.x3},-{e.y3} -{e.x4},{e.y4} -{e.x5},-{e.y5} z",height:36,width:36,heightElements:[.023,8.737,8.151,16.564,10.591,8.714],widthElements:[.085,6.672,6.97,4.273,5.337,6.636]},EVENT_CANCEL_45:{d:"m {mx},{my} -{e.x1},0 0,{e.x0} {e.x1},0 0,{e.y1} {e.x0},0 0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z",height:36,width:36,heightElements:[4.75,8.5],widthElements:[4.75,8.5]},EVENT_COMPENSATION:{d:"m {mx},{my} {e.x0},-{e.y0} 0,{e.y1} z m {e.x1},-{e.y2} {e.x2},-{e.y3} 0,{e.y1} -{e.x2},-{e.y3} z",height:36,width:36,heightElements:[6.5,13,.4,6.1],widthElements:[9,9.3,8.7]},EVENT_TIMER_WH:{d:"M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ",height:36,width:36,heightElements:[10,2],widthElements:[3,7]},EVENT_TIMER_LINE:{d:"M {mx},{my} m {e.x0},{e.y0} l -{e.x1},{e.y1} ",height:36,width:36,heightElements:[10,3],widthElements:[0,0]},EVENT_MULTIPLE:{d:"m {mx},{my} {e.x1},-{e.y0} {e.x1},{e.y0} -{e.x0},{e.y1} -{e.x2},0 z",height:36,width:36,heightElements:[6.28099,12.56199],widthElements:[3.1405,9.42149,12.56198]},EVENT_PARALLEL_MULTIPLE:{d:"m {mx},{my} {e.x0},0 0,{e.y1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} -{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z",height:36,width:36,heightElements:[2.56228,7.68683],widthElements:[2.56228,7.68683]},GATEWAY_EXCLUSIVE:{d:"m {mx},{my} {e.x0},{e.y0} {e.x1},{e.y0} {e.x2},0 {e.x4},{e.y2} {e.x4},{e.y1} {e.x2},0 {e.x1},{e.y3} {e.x0},{e.y3} {e.x3},0 {e.x5},{e.y1} {e.x5},{e.y2} {e.x3},0 z",height:17.5,width:17.5,heightElements:[8.5,6.5312,-6.5312,-8.5],widthElements:[6.5,-6.5,3,-3,5,-5]},GATEWAY_PARALLEL:{d:"m {mx},{my} 0,{e.y1} -{e.x1},0 0,{e.y0} {e.x1},0 0,{e.y1} {e.x0},0 0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z",height:30,width:30,heightElements:[5,12.5],widthElements:[5,12.5]},GATEWAY_EVENT_BASED:{d:"m {mx},{my} {e.x0},{e.y0} {e.x0},{e.y1} {e.x1},{e.y2} {e.x2},0 z",height:11,width:11,heightElements:[-6,6,12,-12],widthElements:[9,-3,-12]},GATEWAY_COMPLEX:{d:"m {mx},{my} 0,{e.y0} -{e.x0},-{e.y1} -{e.x1},{e.y2} {e.x0},{e.y1} -{e.x2},0 0,{e.y3} {e.x2},0 -{e.x0},{e.y1} l {e.x1},{e.y2} {e.x0},-{e.y1} 0,{e.y0} {e.x3},0 0,-{e.y0} {e.x0},{e.y1} {e.x1},-{e.y2} -{e.x0},-{e.y1} {e.x2},0 0,-{e.y3} -{e.x2},0 {e.x0},-{e.y1} -{e.x1},-{e.y2} -{e.x0},{e.y1} 0,-{e.y0} -{e.x3},0 z",height:17.125,width:17.125,heightElements:[4.875,3.4375,2.125,3],widthElements:[3.4375,2.125,4.875,3]},DATA_OBJECT_PATH:{d:"m 0,0 {e.x1},0 {e.x0},{e.y0} 0,{e.y1} -{e.x2},0 0,-{e.y2} {e.x1},0 0,{e.y0} {e.x0},0",height:61,width:51,heightElements:[10,50,60],widthElements:[10,40,50,60]},DATA_OBJECT_COLLECTION_PATH:{d:"m{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10",height:10,width:10,heightElements:[],widthElements:[]},DATA_ARROW:{d:"m 5,9 9,0 0,-3 5,5 -5,5 0,-3 -9,0 z",height:61,width:51,heightElements:[],widthElements:[]},DATA_STORE:{d:"m {mx},{my} l 0,{e.y2} c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 l 0,-{e.y2} c -{e.x0},-{e.y1} -{e.x1},-{e.y1} -{e.x2},0c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 m -{e.x2},{e.y0}c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0m -{e.x2},{e.y0}c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0",height:61,width:61,heightElements:[7,10,45],widthElements:[2,58,60]},TEXT_ANNOTATION:{d:"m {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0",height:30,width:10,heightElements:[30],widthElements:[10]},MARKER_SUB_PROCESS:{d:"m{mx},{my} m 7,2 l 0,10 m -5,-5 l 10,0",height:10,width:10,heightElements:[],widthElements:[]},MARKER_PARALLEL:{d:"m{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10",height:10,width:10,heightElements:[],widthElements:[]},MARKER_SEQUENTIAL:{d:"m{mx},{my} m 0,3 l 10,0 m -10,3 l 10,0 m -10,3 l 10,0",height:10,width:10,heightElements:[],widthElements:[]},MARKER_COMPENSATION:{d:"m {mx},{my} 7,-5 0,10 z m 7.1,-0.3 6.9,-4.7 0,10 -6.9,-4.7 z",height:10,width:21,heightElements:[],widthElements:[]},MARKER_LOOP:{d:"m {mx},{my} c 3.526979,0 6.386161,-2.829858 6.386161,-6.320661 0,-3.490806 -2.859182,-6.320661 -6.386161,-6.320661 -3.526978,0 -6.38616,2.829855 -6.38616,6.320661 0,1.745402 0.714797,3.325567 1.870463,4.469381 0.577834,0.571908 1.265885,1.034728 2.029916,1.35457 l -0.718163,-3.909793 m 0.718163,3.909793 -3.885211,0.802902",height:13.9,width:13.7,heightElements:[],widthElements:[]},MARKER_ADHOC:{d:"m {mx},{my} m 0.84461,2.64411 c 1.05533,-1.23780996 2.64337,-2.07882 4.29653,-1.97997996 2.05163,0.0805 3.85579,1.15803 5.76082,1.79107 1.06385,0.34139996 2.24454,0.1438 3.18759,-0.43767 0.61743,-0.33642 1.2775,-0.64078 1.7542,-1.17511 0,0.56023 0,1.12046 0,1.6807 -0.98706,0.96237996 -2.29792,1.62393996 -3.6918,1.66181996 -1.24459,0.0927 -2.46671,-0.2491 -3.59505,-0.74812 -1.35789,-0.55965 -2.75133,-1.33436996 -4.27027,-1.18121996 -1.37741,0.14601 -2.41842,1.13685996 -3.44288,1.96782996 z",height:4,width:15,heightElements:[],widthElements:[]},TASK_TYPE_SEND:{d:"m {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}",height:14,width:21,heightElements:[6,14],widthElements:[10.5,21]},TASK_TYPE_SCRIPT:{d:"m {mx},{my} c 9.966553,-6.27276 -8.000926,-7.91932 2.968968,-14.938 l -8.802728,0 c -10.969894,7.01868 6.997585,8.66524 -2.968967,14.938 z m -7,-12 l 5,0 m -4.5,3 l 4.5,0 m -3,3 l 5,0m -4,3 l 5,0",height:15,width:12.6,heightElements:[6,14],widthElements:[10.5,21]},TASK_TYPE_USER_1:{d:"m {mx},{my} c 0.909,-0.845 1.594,-2.049 1.594,-3.385 0,-2.554 -1.805,-4.62199999 -4.357,-4.62199999 -2.55199998,0 -4.28799998,2.06799999 -4.28799998,4.62199999 0,1.348 0.974,2.562 1.89599998,3.405 -0.52899998,0.187 -5.669,2.097 -5.794,4.7560005 v 6.718 h 17 v -6.718 c 0,-2.2980005 -5.5279996,-4.5950005 -6.0509996,-4.7760005 zm -8,6 l 0,5.5 m 11,0 l 0,-5"},TASK_TYPE_USER_2:{d:"m {mx},{my} m 2.162,1.009 c 0,2.4470005 -2.158,4.4310005 -4.821,4.4310005 -2.66499998,0 -4.822,-1.981 -4.822,-4.4310005 "},TASK_TYPE_USER_3:{d:"m {mx},{my} m -6.9,-3.80 c 0,0 2.25099998,-2.358 4.27399998,-1.177 2.024,1.181 4.221,1.537 4.124,0.965 -0.098,-0.57 -0.117,-3.79099999 -4.191,-4.13599999 -3.57499998,0.001 -4.20799998,3.36699999 -4.20699998,4.34799999 z"},TASK_TYPE_MANUAL:{d:"m {mx},{my} c 0.234,-0.01 5.604,0.008 8.029,0.004 0.808,0 1.271,-0.172 1.417,-0.752 0.227,-0.898 -0.334,-1.314 -1.338,-1.316 -2.467,-0.01 -7.886,-0.004 -8.108,-0.004 -0.014,-0.079 0.016,-0.533 0,-0.61 0.195,-0.042 8.507,0.006 9.616,0.002 0.877,-0.007 1.35,-0.438 1.353,-1.208 0.003,-0.768 -0.479,-1.09 -1.35,-1.091 -2.968,-0.002 -9.619,-0.013 -9.619,-0.013 v -0.591 c 0,0 5.052,-0.016 7.225,-0.016 0.888,-0.002 1.354,-0.416 1.351,-1.193 -0.006,-0.761 -0.492,-1.196 -1.361,-1.196 -3.473,-0.005 -10.86,-0.003 -11.0829995,-0.003 -0.022,-0.047 -0.045,-0.094 -0.069,-0.139 0.3939995,-0.319 2.0409995,-1.626 2.4149995,-2.017 0.469,-0.4870005 0.519,-1.1650005 0.162,-1.6040005 -0.414,-0.511 -0.973,-0.5 -1.48,-0.236 -1.4609995,0.764 -6.5999995,3.6430005 -7.7329995,4.2710005 -0.9,0.499 -1.516,1.253 -1.882,2.19 -0.37000002,0.95 -0.17,2.01 -0.166,2.979 0.004,0.718 -0.27300002,1.345 -0.055,2.063 0.629,2.087 2.425,3.312 4.859,3.318 4.6179995,0.014 9.2379995,-0.139 13.8569995,-0.158 0.755,-0.004 1.171,-0.301 1.182,-1.033 0.012,-0.754 -0.423,-0.969 -1.183,-0.973 -1.778,-0.01 -5.824,-0.004 -6.04,-0.004 10e-4,-0.084 0.003,-0.586 10e-4,-0.67 z"},TASK_TYPE_INSTANTIATING_SEND:{d:"m {mx},{my} l 0,8.4 l 12.6,0 l 0,-8.4 z l 6.3,3.6 l 6.3,-3.6"},TASK_TYPE_SERVICE:{d:"m {mx},{my} v -1.71335 c 0.352326,-0.0705 0.703932,-0.17838 1.047628,-0.32133 0.344416,-0.14465 0.665822,-0.32133 0.966377,-0.52145 l 1.19431,1.18005 1.567487,-1.57688 -1.195028,-1.18014 c 0.403376,-0.61394 0.683079,-1.29908 0.825447,-2.01824 l 1.622133,-0.01 v -2.2196 l -1.636514,0.01 c -0.07333,-0.35153 -0.178319,-0.70024 -0.323564,-1.04372 -0.145244,-0.34406 -0.321407,-0.6644 -0.522735,-0.96217 l 1.131035,-1.13631 -1.583305,-1.56293 -1.129598,1.13589 c -0.614052,-0.40108 -1.302883,-0.68093 -2.022633,-0.82247 l 0.0093,-1.61852 h -2.241173 l 0.0042,1.63124 c -0.353763,0.0736 -0.705369,0.17977 -1.049785,0.32371 -0.344415,0.14437 -0.665102,0.32092 -0.9635006,0.52046 l -1.1698628,-1.15823 -1.5667691,1.5792 1.1684265,1.15669 c -0.4026573,0.61283 -0.68308,1.29797 -0.8247287,2.01713 l -1.6588041,0.003 v 2.22174 l 1.6724648,-0.006 c 0.073327,0.35077 0.1797598,0.70243 0.3242851,1.04472 0.1452428,0.34448 0.3214064,0.6644 0.5227339,0.96066 l -1.1993431,1.19723 1.5840256,1.56011 1.1964668,-1.19348 c 0.6140517,0.40346 1.3028827,0.68232 2.0233517,0.82331 l 7.19e-4,1.69892 h 2.226848 z m 0.221462,-3.9957 c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z"},TASK_TYPE_SERVICE_FILL:{d:"m {mx},{my} c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z"},TASK_TYPE_BUSINESS_RULE_HEADER:{d:"m {mx},{my} 0,4 20,0 0,-4 z"},TASK_TYPE_BUSINESS_RULE_MAIN:{d:"m {mx},{my} 0,12 20,0 0,-12 zm 0,8 l 20,0 m -13,-4 l 0,8"},MESSAGE_FLOW_MARKER:{d:"m {mx},{my} m -10.5 ,-7 l 0,14 l 21,0 l 0,-14 z l 10.5,6 l 10.5,-6"}},this.getRawPath=function(e){return this.pathMap[e].d},this.getScaledPath=function(e,t){var n,i,r=this.pathMap[e];t.abspos?(n=t.abspos.x,i=t.abspos.y):(n=t.containerWidth*t.position.mx,i=t.containerHeight*t.position.my);var o={};if(t.position){for(var a=t.containerHeight/r.height*t.yScaleFactor,s=t.containerWidth/r.width*t.xScaleFactor,l=0;l<r.heightElements.length;l++)o["y"+l]=r.heightElements[l]*a;for(var p=0;p<r.widthElements.length;p++)o["x"+p]=r.widthElements[p]*s}var c,u,h=(c=r.d,u={mx:n,my:i,e:o},String(c).replace(pt,(function(e,t){return function(e,t,n){var i=n;return t.replace(ct,(function(e,t,n,r,o){t=t||r,i&&(t in i&&(i=i[t]),"function"==typeof i&&o&&(i=i()))})),i=(null==i||i==n?e:i)+""}(e,t,u)})));return h}}]};var ht={translate:["value",function(e,t){return t=t||{},e.replace(/{([^}]+)}/g,(function(e,n){return t[n]||"{"+n+"}"}))}]};function ft(e){return{top:e.y,right:e.x+(e.width||0),bottom:e.y+(e.height||0),left:e.x}}function mt(e){return t={x:e.x+(e.width||0)/2,y:e.y+(e.height||0)/2},{x:Math.round(t.x),y:Math.round(t.y)};var t}function dt(e){for(var t=e.waypoints,n=t.reduce((function(e,n,i){var r,o,a=t[i-1];if(a){var s=e[e.length-1],l=s&&s.endLength||0,p=(r=a,o=n,Math.sqrt(Math.pow(r.x-o.x,2)+Math.pow(r.y-o.y,2)));e.push({start:a,end:n,startLength:l,endLength:l+p,length:p})}return e}),[]),i=n.reduce((function(e,t){return e+t.length}),0),r=i/2,o=0,a=n[o];a.endLength<r;)a=n[++o];var s=(r-a.startLength)/a.length;return{x:a.start.x+(a.end.x-a.start.x)*s,y:a.start.y+(a.end.y-a.start.y)*s}}function yt(e){return a(t=e)&&c(t,"waypoints")?dt(e):mt(e);var t}function gt(e){return e?"<"+e.$type+(e.id?' id="'+e.id:"")+'" />':"<null>"}function vt(e,t,n){return E({id:e.id,type:e.$type,businessObject:e,di:t},n)}function xt(e,t,n){var i=e.waypoint;return!i||i.length<2?[yt(t),yt(n)]:i.map((function(e){return{x:e.x,y:e.y}}))}function bt(e,t,n){return new Error(`element ${gt(t)} referenced by ${gt(e)}#${n} not yet drawn`)}function wt(e,t,n,i,r){this._eventBus=e,this._canvas=t,this._elementFactory=n,this._elementRegistry=i,this._textRenderer=r}wt.$inject=["eventBus","canvas","elementFactory","elementRegistry","textRenderer"],wt.prototype.add=function(e,t,n){var i,r,o,a,s,l,p;if(A(t,"bpmndi:BPMNPlane")){var c=A(e,"bpmn:SubProcess")?{id:e.id+"_plane"}:{};i=this._elementFactory.createRoot(vt(e,t,c)),this._canvas.addRootElement(i)}else if(A(t,"bpmndi:BPMNShape")){var u=!S(e,t),h=function(e){return A(e,"bpmn:Group")}(e);r=n&&(n.hidden||n.collapsed);var f=t.bounds;i=this._elementFactory.createShape(vt(e,t,{collapsed:u,hidden:r,x:Math.round(f.x),y:Math.round(f.y),width:Math.round(f.width),height:Math.round(f.height),isFrame:h})),A(e,"bpmn:BoundaryEvent")&&this._attachBoundary(e,i),A(e,"bpmn:Lane")&&(o=0),A(e,"bpmn:DataStoreReference")&&(a=n,s=yt(f),l=s.x,p=s.y,l>=a.x&&l<=a.x+a.width&&p>=a.y&&p<=a.y+a.height||(n=this._canvas.findRoot(n))),this._canvas.addShape(i,n,o)}else{if(!A(t,"bpmndi:BPMNEdge"))throw new Error(`unknown di ${gt(t)} for element ${gt(e)}`);var m=this._getSource(e),d=this._getTarget(e);r=n&&(n.hidden||n.collapsed),i=this._elementFactory.createConnection(vt(e,t,{hidden:r,source:m,target:d,waypoints:xt(t,m,d)})),A(e,"bpmn:DataAssociation")&&(n=this._canvas.findRoot(n)),this._canvas.addConnection(i,n,o)}return function(e){return A(e,"bpmn:Event")||A(e,"bpmn:Gateway")||A(e,"bpmn:DataStoreReference")||A(e,"bpmn:DataObjectReference")||A(e,"bpmn:DataInput")||A(e,"bpmn:DataOutput")||A(e,"bpmn:SequenceFlow")||A(e,"bpmn:MessageFlow")||A(e,"bpmn:Group")}(e)&&T(i)&&this.addLabel(e,t,i),this._eventBus.fire("bpmnElement.added",{element:i}),i},wt.prototype._attachBoundary=function(e,t){var n=e.attachedToRef;if(!n)throw new Error(`missing ${gt(e)}#attachedToRef`);var i=this._elementRegistry.get(n.id),r=i&&i.attachers;if(!i)throw bt(e,n,"attachedToRef");t.host=i,r||(i.attachers=r=[]),-1===r.indexOf(t)&&r.push(t)},wt.prototype.addLabel=function(e,t,n){var i,r,o;return i=N(t,n),(r=T(n))&&(i=this._textRenderer.getExternalLabelBounds(i,r)),o=this._elementFactory.createLabel(vt(e,t,{id:e.id+"_label",labelTarget:n,type:"label",hidden:n.hidden||!T(n),x:Math.round(i.x),y:Math.round(i.y),width:Math.round(i.width),height:Math.round(i.height)})),this._canvas.addShape(o,n.parent)},wt.prototype._getConnectedElement=function(e,t){var n,i,r=e.$type;if(i=e[t+"Ref"],"source"===t&&"bpmn:DataInputAssociation"===r&&(i=i&&i[0]),("source"===t&&"bpmn:DataOutputAssociation"===r||"target"===t&&"bpmn:DataInputAssociation"===r)&&(i=e.$parent),n=i&&this._getElement(i))return n;throw i?bt(e,i,t+"Ref"):new Error(`${gt(e)}#${t} Ref not specified`)},wt.prototype._getSource=function(e){return this._getConnectedElement(e,"source")},wt.prototype._getTarget=function(e){return this._getConnectedElement(e,"target")},wt.prototype._getElement=function(e){return this._elementRegistry.get(e.id)};var Et={__depends__:[ut,{__depends__:[ht],bpmnImporter:["type",wt]}]};function _t(e,t){var n,i,r,a;return t=!!t,o(e)||(e=[e]),f(e,(function(e){var o=e;e.waypoints&&!t&&(o=_t(e.waypoints,!0));var s=o.x,l=o.y,p=o.height||0,c=o.width||0;(s<n||void 0===n)&&(n=s),(l<i||void 0===i)&&(i=l),(s+c>r||void 0===r)&&(r=s+c),(l+p>a||void 0===a)&&(a=l+p)})),{x:n,y:i,height:a-i,width:r-n}}function At(e){return"waypoints"in e?"connection":"x"in e?"shape":"root"}function kt(e){return!(!e||!e.isFrame)}function Rt(e){this._counter=0,this._prefix=(e?e+"-":"")+Math.floor(1e9*Math.random())+"-"}Rt.prototype.next=function(){return this._prefix+ ++this._counter};var St=new Rt("ov");function Ct(e,t,n,i){var r,o;this._eventBus=t,this._canvas=n,this._elementRegistry=i,this._ids=St,this._overlayDefaults=E({show:null,scale:!0},e&&e.defaults),this._overlays={},this._overlayContainers=[],this._overlayRoot=(r=n.getContainer(),ke(o=Ge('<div class="djs-overlay-container" />'),{position:"absolute",width:0,height:0}),r.insertBefore(o,r.firstChild),o),this._init()}function Mt(e,t,n){ke(e,{left:t+"px",top:n+"px"})}function Pt(e,t){e.style.display=!1===t?"none":""}function Nt(e,t){e.style["transform-origin"]="top left",["","-ms-","-webkit-"].forEach((function(n){e.style[n+"transform"]=t}))}Ct.$inject=["config.overlays","eventBus","canvas","elementRegistry"],Ct.prototype.get=function(e){if(p(e)&&(e={id:e}),p(e.element)&&(e.element=this._elementRegistry.get(e.element)),e.element){var t=this._getOverlayContainer(e.element,!0);return t?e.type?h(t.overlays,g({type:e.type})):t.overlays.slice():[]}return e.type?h(this._overlays,g({type:e.type})):e.id?this._overlays[e.id]:null},Ct.prototype.add=function(e,t,n){if(a(t)&&(n=t,t=null),e.id||(e=this._elementRegistry.get(e)),!n.position)throw new Error("must specifiy overlay position");if(!n.html)throw new Error("must specifiy overlay html");if(!e)throw new Error("invalid element specified");var i=this._ids.next();return n=E({},this._overlayDefaults,n,{id:i,type:t,element:e,html:n.html}),this._addOverlay(n),i},Ct.prototype.remove=function(e){var t=this.get(e)||[];o(t)||(t=[t]);var n=this;f(t,(function(e){var t=n._getOverlayContainer(e.element,!0);if(e&&(Ke(e.html),Ke(e.htmlContainer),delete e.htmlContainer,delete e.element,delete n._overlays[e.id]),t){var i=t.overlays.indexOf(e);-1!==i&&t.overlays.splice(i,1)}}))},Ct.prototype.isShown=function(){return"none"!==this._overlayRoot.style.display},Ct.prototype.show=function(){Pt(this._overlayRoot)},Ct.prototype.hide=function(){Pt(this._overlayRoot,!1)},Ct.prototype.clear=function(){this._overlays={},this._overlayContainers=[],Pe(this._overlayRoot)},Ct.prototype._updateOverlayContainer=function(e){var t=e.element,n=e.html,i=t.x,r=t.y;if(t.waypoints){var o=_t(t);i=o.x,r=o.y}Mt(n,i,r),Re(e.html,"data-container-id",t.id)},Ct.prototype._updateOverlay=function(e){var t,n,i=e.position,r=e.htmlContainer,o=e.element,a=i.left,s=i.top;void 0!==i.right&&(t=o.waypoints?_t(o).width:o.width,a=-1*i.right+t);void 0!==i.bottom&&(n=o.waypoints?_t(o).height:o.height,s=-1*i.bottom+n);Mt(r,a||0,s||0),this._updateOverlayVisibilty(e,this._canvas.viewbox())},Ct.prototype._createOverlayContainer=function(e){var t=Ge('<div class="djs-overlays" />');ke(t,{position:"absolute"}),this._overlayRoot.appendChild(t);var n={html:t,element:e,overlays:[]};return this._updateOverlayContainer(n),this._overlayContainers.push(n),n},Ct.prototype._updateRoot=function(e){var t=e.scale||1,n="matrix("+[t,0,0,t,-1*e.x*t,-1*e.y*t].join(",")+")";Nt(this._overlayRoot,n)},Ct.prototype._getOverlayContainer=function(e,t){var n=u(this._overlayContainers,(function(t){return t.element===e}));return n||t?n:this._createOverlayContainer(e)},Ct.prototype._addOverlay=function(e){var t,n,i=e.id,r=e.element,o=e.html;o.get&&o.constructor.prototype.jquery&&(o=o.get(0)),p(o)&&(o=Ge(o)),n=this._getOverlayContainer(r),ke(t=Ge('<div class="djs-overlay" data-overlay-id="'+i+'">'),{position:"absolute"}),t.appendChild(o),e.type&&Ce(t).add("djs-overlay-"+e.type),Pt(t,this._canvas.findRoot(r)===this._canvas.getRootElement()),e.htmlContainer=t,n.overlays.push(e),n.html.appendChild(t),this._overlays[i]=e,this._updateOverlay(e),this._updateOverlayVisibilty(e,this._canvas.viewbox())},Ct.prototype._updateOverlayVisibilty=function(e,t){var n=e.show,i=this._canvas.findRoot(e.element),o=n&&n.minZoom,a=n&&n.maxZoom,s=e.htmlContainer,l=!0;(i!==this._canvas.getRootElement()||n&&(r(o)&&o>t.scale||r(a)&&a<t.scale))&&(l=!1),Pt(s,l),this._updateOverlayScale(e,t)},Ct.prototype._updateOverlayScale=function(e,t){var n,i,o,a=e.scale,s=e.htmlContainer,l="";!0!==a&&(!1===a?(n=1,i=1):(n=a.min,i=a.max),r(n)&&t.scale<n&&(o=(1/t.scale||1)*n),r(i)&&t.scale>i&&(o=(1/t.scale||1)*i)),r(o)&&(l="scale("+o+","+o+")"),Nt(s,l)},Ct.prototype._updateOverlaysVisibilty=function(e){var t=this;f(this._overlays,(function(n){t._updateOverlayVisibilty(n,e)}))},Ct.prototype._init=function(){var e=this._eventBus,t=this;e.on("canvas.viewbox.changing",(function(e){t.hide()})),e.on("canvas.viewbox.changed",(function(e){var n;n=e.viewbox,t._updateRoot(n),t._updateOverlaysVisibilty(n),t.show()})),e.on(["shape.remove","connection.remove"],(function(e){var n=e.element;f(t.get({element:n}),(function(e){t.remove(e.id)}));var i=t._getOverlayContainer(n);if(i){Ke(i.html);var r=t._overlayContainers.indexOf(i);-1!==r&&t._overlayContainers.splice(r,1)}})),e.on("element.changed",500,(function(e){var n=e.element,i=t._getOverlayContainer(n,!0);i&&(f(i.overlays,(function(e){t._updateOverlay(e)})),t._updateOverlayContainer(i))})),e.on("element.marker.update",(function(e){var n=t._getOverlayContainer(e.element,!0);n&&Ce(n.html)[e.add?"add":"remove"](e.marker)})),e.on("root.set",(function(){t._updateOverlaysVisibilty(t._canvas.viewbox())})),e.on("diagram.clear",this.clear,this)};var Tt={__init__:["overlays"],overlays:["type",Ct]};function Dt(e,t,n,i){e.on("element.changed",(function(i){var r=i.element;(r.parent||r===t.getRootElement())&&(i.gfx=n.getGraphics(r)),i.gfx&&e.fire(At(r)+".changed",i)})),e.on("elements.changed",(function(t){var n=t.elements;n.forEach((function(t){e.fire("element.changed",{element:t})})),i.updateContainments(n)})),e.on("shape.changed",(function(e){i.update("shape",e.element,e.gfx)})),e.on("connection.changed",(function(e){i.update("connection",e.element,e.gfx)}))}Dt.$inject=["eventBus","canvas","elementRegistry","graphicsFactory"];var Bt={__init__:["changeSupport"],changeSupport:["type",Dt]};function Ot(e){this._eventBus=e}function Lt(e){return function(t,n,i,r,o){(l(t)||s(t))&&(o=r,r=i,i=n,n=t,t=null),this.on(t,e,n,i,r,o)}}function It(e,t){t.invoke(Ot,this),this.executed((function(t){var n=t.context;n.rootElement?e.setRootElement(n.rootElement):n.rootElement=e.getRootElement()})),this.revert((function(t){var n=t.context;n.rootElement&&e.setRootElement(n.rootElement)}))}Ot.$inject=["eventBus"],Ot.prototype.on=function(e,t,n,i,r,p){if((l(t)||s(t))&&(p=r,r=i,i=n,n=t,t=null),l(n)&&(p=r,r=i,i=n,n=1e3),a(r)&&(p=r,r=!1),!l(i))throw new Error("handlerFn must be a function");o(e)||(e=[e]);var c=this._eventBus;f(e,(function(e){var o=["commandStack",e,t].filter((function(e){return e})).join(".");c.on(o,n,r?function(e,t){return function(n){return e.call(t||null,n.context,n.command,n)}}(i,p):i,p)}))},Ot.prototype.canExecute=Lt("canExecute"),Ot.prototype.preExecute=Lt("preExecute"),Ot.prototype.preExecuted=Lt("preExecuted"),Ot.prototype.execute=Lt("execute"),Ot.prototype.executed=Lt("executed"),Ot.prototype.postExecute=Lt("postExecute"),Ot.prototype.postExecuted=Lt("postExecuted"),Ot.prototype.revert=Lt("revert"),Ot.prototype.reverted=Lt("reverted"),e(It,Ot),It.$inject=["canvas","injector"];var Ft={__init__:["rootElementsBehavior"],rootElementsBehavior:["type",It]},jt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};var Vt="_plane";function Wt(e){var t=e.id;return A(e,"bpmn:SubProcess")?function(e){return e+Vt}(t):t}function zt(e,t,n){var i=Ge('<ul class="bjs-breadcrumbs"></ul>'),r=n.getContainer(),o=Ce(r);r.appendChild(i);var a=[];function s(e){e&&(a=function(e){for(var t=k(e),n=[],i=t;i;i=i.$parent)(A(i,"bpmn:SubProcess")||A(i,"bpmn:Process"))&&n.push(i);return n.reverse()}(e));var r=a.flatMap((function(e){var i=n.findRoot(Wt(e))||n.findRoot(e.id);if(!i&&A(e,"bpmn:Process")){var r=t.find((function(t){var n=k(t);return n&&n.get("processRef")===e}));i=r&&n.findRoot(r.id)}if(!i)return[];var o,a=(o=""+(o=e.name||e.id))&&o.replace(/[&<>"']/g,(function(e){return jt[e]})),s=Ge('<li><span class="bjs-crumb"><a title="'+a+'">'+a+"</a></span></li>");return s.addEventListener("click",(function(){n.setRootElement(i)})),s}));i.innerHTML="";var s=r.length>1;o.toggle("bjs-breadcrumbs-shown",s),r.forEach((function(e){i.appendChild(e)}))}e.on("element.changed",(function(e){var t=k(e.element);u(a,(function(e){return e===t}))&&s()})),e.on("root.set",(function(e){s(e.element)}))}function $t(e,t){var n=null,i=new Gt;e.on("root.set",(function(e){var r=e.element,o=t.viewbox(),a=i.get(r);if(i.set(n,{x:o.x,y:o.y,zoom:o.scale}),n=r,A(r,"bpmn:SubProcess")||a){a=a||{x:0,y:0,zoom:1};var s=(o.x-a.x)*o.scale,l=(o.y-a.y)*o.scale;0===s&&0===l||t.scroll({dx:s,dy:l}),a.zoom!==o.scale&&t.zoom(a.zoom,{x:0,y:0})}})),e.on("diagram.clear",(function(){i.clear(),n=null}))}function Gt(){this._entries=[],this.set=function(e,t){var n=!1;for(var i in this._entries)if(this._entries[i][0]===e){this._entries[i][1]=t,n=!0;break}n||this._entries.push([e,t])},this.get=function(e){for(var t in this._entries)if(this._entries[t][0]===e)return this._entries[t][1];return null},this.clear=function(){this._entries.length=0},this.remove=function(e){var t=-1;for(var n in this._entries)if(this._entries[n][0]===e){t=n;break}-1!==t&&this._entries.splice(t,1)}}zt.$inject=["eventBus","elementRegistry","canvas"],$t.$inject=["eventBus","canvas"];var Ht=180,Kt=160;function Ut(e,t){this._eventBus=e,this._moddle=t;var n=this;e.on("import.render.start",1500,(function(e,t){n._handleImport(t.definitions)}))}function qt(e){return A(e,"bpmndi:BPMNDiagram")?e:qt(e.$parent)}Ut.prototype._handleImport=function(e){if(e.diagrams){var t=this;this._definitions=e,this._processToDiagramMap={},e.diagrams.forEach((function(e){e.plane&&e.plane.bpmnElement&&(t._processToDiagramMap[e.plane.bpmnElement.id]=e)})),e.diagrams.filter((e=>e.plane)).flatMap((e=>t._createNewDiagrams(e.plane))).forEach((function(e){t._movePlaneElementsToOrigin(e.plane)}))}},Ut.prototype._createNewDiagrams=function(e){var t=this,n=[],i=[];e.get("planeElement").forEach((function(t){var r=t.bpmnElement;if(r){var o=r.$parent;A(r,"bpmn:SubProcess")&&!t.isExpanded&&n.push(r),function(e,t){var n=e.$parent;if(!A(n,"bpmn:SubProcess")||n===t.bpmnElement)return!1;if(function(e,t){return y(t,(function(t){return A(e,t)}))}(e,["bpmn:DataInputAssociation","bpmn:DataOutputAssociation"]))return!1;return!0}(r,e)&&i.push({diElement:t,parent:o})}}));var r=[];return n.forEach((function(e){if(!t._processToDiagramMap[e.id]){var n=t._createDiagram(e);t._processToDiagramMap[e.id]=n,r.push(n)}})),i.forEach((function(e){for(var i=e.diElement,r=e.parent;r&&-1===n.indexOf(r);)r=r.$parent;if(r){var o=t._processToDiagramMap[r.id];t._moveToDiPlane(i,o.plane)}})),r},Ut.prototype._movePlaneElementsToOrigin=function(e){var t=e.get("planeElement"),n=function(e){var t={top:1/0,right:-1/0,bottom:-1/0,left:1/0};return e.planeElement.forEach((function(e){if(e.bounds){var n=ft(e.bounds);t.top=Math.min(n.top,t.top),t.left=Math.min(n.left,t.left)}})),function(e){return{x:e.left,y:e.top,width:e.right-e.left,height:e.bottom-e.top}}(t)}(e),i=n.x-Ht,r=n.y-Kt;t.forEach((function(e){e.waypoint?e.waypoint.forEach((function(e){e.x=e.x-i,e.y=e.y-r})):e.bounds&&(e.bounds.x=e.bounds.x-i,e.bounds.y=e.bounds.y-r)}))},Ut.prototype._moveToDiPlane=function(e,t){var n=qt(e).plane.get("planeElement");n.splice(n.indexOf(e),1),t.get("planeElement").push(e)},Ut.prototype._createDiagram=function(e){var t=this._moddle.create("bpmndi:BPMNPlane",{bpmnElement:e}),n=this._moddle.create("bpmndi:BPMNDiagram",{plane:t});return t.$parent=n,t.bpmnElement=e,n.$parent=this._definitions,this._definitions.diagrams.push(n),n},Ut.$inject=["eventBus","moddle"];var Yt=250;function Xt(e,t,n,i,r){Ot.call(this,t),this._canvas=e,this._eventBus=t,this._elementRegistry=n,this._overlays=i,this._translate=r;var o=this;this.executed("shape.toggleCollapse",Yt,(function(e){var t=e.shape;o._canDrillDown(t)?o._addOverlay(t):o._removeOverlay(t)}),!0),this.reverted("shape.toggleCollapse",Yt,(function(e){var t=e.shape;o._canDrillDown(t)?o._addOverlay(t):o._removeOverlay(t)}),!0),this.executed(["shape.create","shape.move","shape.delete"],Yt,(function(e){var t=e.oldParent,n=e.newParent||e.parent,i=e.shape;o._canDrillDown(i)&&o._addOverlay(i),o._updateDrilldownOverlay(t),o._updateDrilldownOverlay(n),o._updateDrilldownOverlay(i)}),!0),this.reverted(["shape.create","shape.move","shape.delete"],Yt,(function(e){var t=e.oldParent,n=e.newParent||e.parent,i=e.shape;o._canDrillDown(i)&&o._addOverlay(i),o._updateDrilldownOverlay(t),o._updateDrilldownOverlay(n),o._updateDrilldownOverlay(i)}),!0),t.on("import.render.complete",(function(){n.filter((function(e){return o._canDrillDown(e)})).map((function(e){o._addOverlay(e)}))}))}e(Xt,Ot),Xt.prototype._updateDrilldownOverlay=function(e){var t=this._canvas;if(e){var n=t.findRoot(e);n&&this._updateOverlayVisibility(n)}},Xt.prototype._canDrillDown=function(e){var t=this._canvas;return A(e,"bpmn:SubProcess")&&t.findRoot(Wt(e))},Xt.prototype._updateOverlayVisibility=function(e){var t=this._overlays,n=k(e),i=t.get({element:n.id,type:"drilldown"})[0];if(i){var r=n&&n.get("flowElements")&&n.get("flowElements").length;Ce(i.html).toggle("bjs-drilldown-empty",!r)}},Xt.prototype._addOverlay=function(e){var t=this._canvas,n=this._overlays,i=k(e);n.get({element:e,type:"drilldown"}).length&&this._removeOverlay(e);var r=Ge('<button type="button" class="bjs-drilldown"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M4.81801948,3.50735931 L10.4996894,9.1896894 L10.5,4 L12,4 L12,12 L4,12 L4,10.5 L9.6896894,10.4996894 L3.75735931,4.56801948 C3.46446609,4.27512627 3.46446609,3.80025253 3.75735931,3.50735931 C4.05025253,3.21446609 4.52512627,3.21446609 4.81801948,3.50735931 Z"/></svg></button>'),o=i.get("name")||i.get("id"),a=this._translate("Open {element}",{element:o});r.setAttribute("title",a),r.addEventListener("click",(function(){t.setRootElement(t.findRoot(Wt(e)))})),n.add(e,"drilldown",{position:{bottom:-7,right:-8},html:r}),this._updateOverlayVisibility(e)},Xt.prototype._removeOverlay=function(e){this._overlays.remove({element:e,type:"drilldown"})},Xt.$inject=["canvas","eventBus","elementRegistry","overlays","translate"];var Zt={__depends__:[Tt,Bt,Ft],__init__:["drilldownBreadcrumbs","drilldownOverlayBehavior","drilldownCentering","subprocessCompatibility"],drilldownBreadcrumbs:["type",zt],drilldownCentering:["type",$t],drilldownOverlayBehavior:["type",Xt],subprocessCompatibility:["type",Ut]};function Jt(e){return e.originalEvent||e.srcEvent}function Qt(e){return e.pointers&&e.pointers.length&&(e=e.pointers[0]),e.touches&&e.touches.length&&(e=e.touches[0]),e?{x:e.clientX,y:e.clientY}:null}function en(e,t){return(Jt(e)||e).button===t}function tn(e){return en(e,0)}function nn(e){return!0}function rn(e){return tn(e)||function(e){return en(e,1)}(e)}function on(e,t,n){var i=this;function r(n,i,r){var o,a;(function(e,t){var n=l[e]||tn;return!n(t)})(n,i)||(r?a=t.getGraphics(r):(o=i.delegateTarget||i.target)&&(a=o,r=t.get(a)),a&&r&&!1===e.fire(n,{element:r,gfx:a,originalEvent:i})&&(i.stopPropagation(),i.preventDefault()))}var o={};function a(e){return o[e]}var s={click:"element.click",contextmenu:"element.contextmenu",dblclick:"element.dblclick",mousedown:"element.mousedown",mousemove:"element.mousemove",mouseover:"element.hover",mouseout:"element.out",mouseup:"element.mouseup"},l={"element.contextmenu":nn,"element.mousedown":rn,"element.mouseup":rn,"element.click":rn,"element.dblclick":rn};function p(e,t,n,i){var a=o[n]=function(e){r(n,e)};i&&(l[n]=i),a.$delegate=Ve.bind(e,"svg, .djs-element",t,a)}function c(e,t,n){var i=a(n);i&&Ve.unbind(e,t,i.$delegate)}e.on("canvas.destroy",(function(e){var t;t=e.svg,f(s,(function(e,n){c(t,n,e)}))})),e.on("canvas.init",(function(e){var t;t=e.svg,f(s,(function(e,n){p(t,n,e)}))})),e.on(["shape.added","connection.added"],(function(t){var n=t.element,i=t.gfx;e.fire("interactionEvents.createHit",{element:n,gfx:i})})),e.on(["shape.changed","connection.changed"],500,(function(t){var n=t.element,i=t.gfx;e.fire("interactionEvents.updateHit",{element:n,gfx:i})})),e.on("interactionEvents.createHit",500,(function(e){var t=e.element,n=e.gfx;i.createDefaultHit(t,n)})),e.on("interactionEvents.updateHit",(function(e){var t=e.element,n=e.gfx;i.updateDefaultHit(t,n)}));var u=d("djs-hit djs-hit-stroke"),h=d("djs-hit djs-hit-click-stroke"),m={all:d("djs-hit djs-hit-all"),"click-stroke":h,stroke:u,"no-move":d("djs-hit djs-hit-no-move")};function d(e,t){return t=E({stroke:"white",strokeWidth:15},t||{}),n.cls(e,["no-fill","no-border"],t)}function y(e,t){var n=m[t];if(!n)throw new Error("invalid hit type <"+t+">");return L(e,n),e}function g(e,t){D(e,t)}this.removeHits=function(e){var t;f((t=".djs-hit",(e||document).querySelectorAll(t)),ee)},this.createDefaultHit=function(e,t){var n,i=e.waypoints,r=e.isFrame;return i?this.createWaypointsHit(t,i):(n=r?"stroke":"all",this.createBoxHit(t,n,{width:e.width,height:e.height}))},this.createWaypointsHit=function(e,t){var n=le(t);return y(n,"stroke"),g(e,n),n},this.createBoxHit=function(e,t,n){n=E({x:0,y:0},n);var i=$("rect");return y(i,t),L(i,n),g(e,i),i},this.updateDefaultHit=function(e,t){var n=He(".djs-hit",t);if(n)return e.waypoints?pe(n,e.waypoints):L(n,{width:e.width,height:e.height}),n},this.fire=r,this.triggerMouseEvent=function(e,t,n){var i=s[e];if(!i)throw new Error("unmapped DOM event name <"+e+">");return r(i,t,n)},this.mouseHandler=a,this.registerEvent=p,this.unregisterEvent=c}on.$inject=["eventBus","elementRegistry","styles"];var an={__init__:["interactionEvents"],interactionEvents:["type",on]};function sn(e,t){this._eventBus=e,this._canvas=t,this._selectedElements=[];var n=this;e.on(["shape.remove","connection.remove"],(function(e){var t=e.element;n.deselect(t)})),e.on(["diagram.clear","root.set"],(function(e){n.select(null)}))}sn.$inject=["eventBus","canvas"],sn.prototype.deselect=function(e){var t=this._selectedElements,n=t.indexOf(e);if(-1!==n){var i=t.slice();t.splice(n,1),this._eventBus.fire("selection.changed",{oldSelection:i,newSelection:t})}},sn.prototype.get=function(){return this._selectedElements},sn.prototype.isSelected=function(e){return-1!==this._selectedElements.indexOf(e)},sn.prototype.select=function(e,t){var n=this._selectedElements,i=n.slice();o(e)||(e=e?[e]:[]);var r=this._canvas,a=r.getRootElement();e=e.filter((function(e){var t=r.findRoot(e);return a===t})),t?f(e,(function(e){-1===n.indexOf(e)&&n.push(e)})):this._selectedElements=n=e.slice(),this._eventBus.fire("selection.changed",{oldSelection:i,newSelection:n})};var ln="hover",pn="selected";function cn(e,t){function n(t,n){e.addMarker(t,n)}function i(t,n){e.removeMarker(t,n)}this._canvas=e,t.on("element.hover",(function(e){n(e.element,ln)})),t.on("element.out",(function(e){i(e.element,ln)})),t.on("selection.changed",(function(e){var t=e.oldSelection,r=e.newSelection;f(t,(function(e){-1===r.indexOf(e)&&i(e,pn)})),f(r,(function(e){-1===t.indexOf(e)&&n(e,pn)}))}))}function un(e,t,n,i){e.on("create.end",500,(function(e){var n=e.context,i=n.canExecute,r=n.elements,a=(n.hints||{}).autoSelect;if(i){if(!1===a)return;o(a)?t.select(a):t.select(r.filter(hn))}})),e.on("connect.end",500,(function(e){var n=e.context.connection;n&&t.select(n)})),e.on("shape.move.end",500,(function(e){var n=e.previousSelection||[],r=i.get(e.context.shape.id);u(n,(function(e){return r.id===e.id}))||t.select(r)})),e.on("element.click",(function(e){if(tn(e)){var i=e.element;i===n.getRootElement()&&(i=null);var r=t.isSelected(i),o=t.get().length>1,a=function(e){var t=Jt(e)||e;return tn(e)&&t.shiftKey}(e);if(r&&o)return a?t.deselect(i):t.select(i);r?t.deselect(i):t.select(i,a)}}))}function hn(e){return!e.hidden}cn.$inject=["canvas","eventBus"],un.$inject=["eventBus","selection","canvas","elementRegistry"];var fn={__init__:["selectionVisuals","selectionBehavior"],__depends__:[an],selection:["type",sn],selectionVisuals:["type",cn],selectionBehavior:["type",un]};const mn=/^class[ {]/;function dn(e){return Array.isArray(e)}function yn(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function gn(...e){1===e.length&&dn(e[0])&&(e=e[0]);const t=(e=[...e]).pop();return t.$inject=e,t}const vn=/constructor\s*[^(]*\(\s*([^)]*)\)/m,xn=/^(?:async\s+)?(?:function\s*[^(]*)?(?:\(\s*([^)]*)\)|(\w+))/m,bn=/\/\*([^*]*)\*\//m;function wn(e){if("function"!=typeof e)throw new Error(`Cannot annotate "${e}". Expected a function!`);const t=e.toString().match(function(e){return mn.test(e.toString())}(e)?vn:xn);if(!t)return[];const n=t[1]||t[2];return n&&n.split(",").map((e=>{const t=e.match(bn);return(t&&t[1]||e).trim()}))||[]}function En(e,t){const n=t||{get:function(e,t){if(i.push(e),!1===t)return null;throw s(`No provider for "${e}"!`)}},i=[],r=this._providers=Object.create(n._providers||null),o=this._instances=Object.create(null),a=o.injector=this,s=function(e){const t=i.join(" -> ");return i.length=0,new Error(t?`${e} (Resolving: ${t})`:e)};function l(e,t){if(!r[e]&&e.includes(".")){const t=e.split(".");let n=l(t.shift());for(;t.length;)n=n[t.shift()];return n}if(yn(o,e))return o[e];if(yn(r,e)){if(-1!==i.indexOf(e))throw i.push(e),s("Cannot resolve circular dependency!");return i.push(e),o[e]=r[e][0](r[e][1]),i.pop(),o[e]}return n.get(e,t)}function p(e,t){if(void 0===t&&(t={}),"function"!=typeof e){if(!dn(e))throw s(`Cannot invoke "${e}". Expected a function!`);e=gn(e.slice())}return{fn:e,dependencies:(e.$inject||wn(e)).map((e=>yn(t,e)?t[e]:l(e)))}}function c(e){const{fn:t,dependencies:n}=p(e);return new(Function.prototype.bind.call(t,null,...n))}function u(e,t,n){const{fn:i,dependencies:r}=p(e,n);return i.apply(t,r)}function h(e){return gn((t=>e.get(t)))}function f(e,t){if(t&&t.length){const n=Object.create(null),i=Object.create(null),o=[],a=[],s=[];let l,p,c,u;for(let e in r)l=r[e],-1!==t.indexOf(e)&&("private"===l[2]?(p=o.indexOf(l[3]),-1===p?(c=l[3].createChild([],t),u=h(c),o.push(l[3]),a.push(c),s.push(u),n[e]=[u,e,"private",c]):n[e]=[s[p],e,"private",a[p]]):n[e]=[l[2],l[1]],i[e]=!0),"factory"!==l[2]&&"type"!==l[2]||!l[1].$scope||t.forEach((t=>{-1!==l[1].$scope.indexOf(t)&&(n[e]=[l[2],l[1]],i[t]=!0)}));t.forEach((e=>{if(!i[e])throw new Error('No provider for "'+e+'". Cannot use provider from the parent!')})),e.unshift(n)}return new En(e,a)}const m={factory:u,type:c,value:function(e){return e}};function d(e,t){const n=e.__init__||[];return function(){n.forEach((e=>{"string"==typeof e?t.get(e):t.invoke(e)}))}}function y(e){const t=e.__exports__;if(t){const n=e.__modules__,i=Object.keys(e).reduce(((t,n)=>("__exports__"!==n&&"__modules__"!==n&&"__init__"!==n&&"__depends__"!==n&&(t[n]=e[n]),t)),Object.create(null)),o=f((n||[]).concat(i)),a=gn((function(e){return o.get(e)}));t.forEach((function(e){r[e]=[a,e,"private",o]}));const s=(e.__init__||[]).slice();return s.unshift((function(){o.init()})),d(e=Object.assign({},e,{__init__:s}),o)}return Object.keys(e).forEach((function(t){if("__init__"===t||"__depends__"===t)return;const n=e[t];if("private"===n[2])return void(r[t]=n);const i=n[0],o=n[1];r[t]=[m[i],_n(i,o),i]})),d(e,a)}function g(e,t){return-1!==e.indexOf(t)||-1!==(e=(t.__depends__||[]).reduce(g,e)).indexOf(t)?e:e.concat(t)}this.get=l,this.invoke=u,this.instantiate=c,this.createChild=f,this.init=function(e){const t=e.reduce(g,[]).map(y);let n=!1;return function(){n||(n=!0,t.forEach((e=>e())))}}(e)}function _n(e,t){return"value"!==e&&dn(t)&&(t=gn(t.slice())),t}function An(e,t){_.call(this,e,1),this.CONNECTION_STYLE=t.style(["no-fill"],{strokeWidth:5,stroke:"fuchsia"}),this.SHAPE_STYLE=t.style({fill:"white",stroke:"fuchsia",strokeWidth:2}),this.FRAME_STYLE=t.style(["no-fill"],{stroke:"fuchsia",strokeDasharray:4,strokeWidth:2})}e(An,_),An.prototype.canRender=function(){return!0},An.prototype.drawShape=function(e,t,n){var i=$("rect");return L(i,{x:0,y:0,width:t.width||0,height:t.height||0}),kt(t)?L(i,E({},this.FRAME_STYLE,n||{})):L(i,E({},this.SHAPE_STYLE,n||{})),D(e,i),i},An.prototype.drawConnection=function(e,t,n){var i=le(t.waypoints,E({},this.CONNECTION_STYLE,n||{}));return D(e,i),i},An.prototype.getShapePath=function(e){var t=e.x,n=e.y,i=e.width;return ie([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])},An.prototype.getConnectionPath=function(e){var t,n,i=e.waypoints,r=[];for(t=0;n=i[t];t++)n=n.original||n,r.push([0===t?"M":"L",n.x,n.y]);return ie(r)},An.$inject=["eventBus","styles"];var kn={__init__:["defaultRenderer"],defaultRenderer:["type",An],styles:["type",function(){var e={"no-fill":{fill:"none"},"no-border":{strokeOpacity:0},"no-events":{pointerEvents:"none"}},t=this;this.cls=function(e,t,n){return E(this.style(t,n),{class:e})},this.style=function(t,n){o(t)||n||(n=t,t=[]);var i=m(t,(function(t,n){return E(t,e[n]||{})}),{});return n?E(i,n):i},this.computeStyle=function(e,n,i){return o(n)||(i=n,n=[]),t.style(n||[],E({},i,e||{}))}}]};function Rn(e,t){return Math.round(e*t)/t}function Sn(e){return s(e)?e+"px":e}function Cn(e,t,n){const i=$("g");F(i).add(t);const r=void 0!==n?n:e.childNodes.length-1;return e.insertBefore(i,e.childNodes[r]||null),i}const Mn={shape:["x","y","width","height"],connection:["waypoints"]};function Pn(e,t,n,i){this._eventBus=t,this._elementRegistry=i,this._graphicsFactory=n,this._rootsIdx=0,this._layers={},this._planes=[],this._rootElement=null,this._focused=!1,this._init(e||{})}function Nn(e,t){const n="matrix("+t.a+","+t.b+","+t.c+","+t.d+","+t.e+","+t.f+")";e.setAttribute("transform",n)}Pn.$inject=["config.canvas","eventBus","graphicsFactory","elementRegistry"],Pn.prototype._init=function(e){const t=this._eventBus,n=this._container=function(e){const t=(e=E({},{width:"100%",height:"100%"},e)).container||document.body,n=document.createElement("div");return n.setAttribute("class","djs-container djs-parent"),ke(n,{position:"relative",overflow:"hidden",width:Sn(e.width),height:Sn(e.height)}),t.appendChild(n),n}(e),i=this._svg=$("svg");L(i,{width:"100%",height:"100%"}),Re(i,"tabindex",0),e.autoFocus&&t.on("element.hover",(()=>{this.restoreFocus()})),t.on("element.mousedown",500,(e=>{this.focus()})),i.addEventListener("focusin",(()=>{this._setFocused(!0)})),i.addEventListener("focusout",(()=>{this._setFocused(!1)})),D(n,i);const r=this._viewport=Cn(i,"viewport");e.deferUpdate&&(this._viewboxChanged=function(e,t){let n,i,r,o;function a(n){let a=Date.now(),p=n?0:o+t-a;if(p>0)return s(p);e.apply(r,i),l()}function s(e){n=setTimeout(a,e)}function l(){n&&clearTimeout(n),n=o=i=r=void 0}function p(...e){o=Date.now(),i=e,r=this,n||s(t)}return p.flush=function(){n&&a(!0),l()},p.cancel=l,p}(w(this._viewboxChanged,this),300)),t.on("diagram.init",(()=>{t.fire("canvas.init",{svg:i,viewport:r})})),t.on(["shape.added","connection.added","shape.removed","connection.removed","elements.changed","root.set"],(()=>{delete this._cachedViewbox})),t.on("diagram.destroy",500,this._destroy,this),t.on("diagram.clear",500,this._clear,this)},Pn.prototype._destroy=function(){this._eventBus.fire("canvas.destroy",{svg:this._svg,viewport:this._viewport});const e=this._container.parentNode;e&&e.removeChild(this._container),delete this._svg,delete this._container,delete this._layers,delete this._planes,delete this._rootElement,delete this._viewport},Pn.prototype._setFocused=function(e){e!=this._focused&&(this._focused=e,this._eventBus.fire("canvas.focus.changed",{focused:e}))},Pn.prototype._clear=function(){this._elementRegistry.getAll().forEach((e=>{const t=At(e);"root"===t?this.removeRootElement(e):this._removeElement(e,t)})),this._planes=[],this._rootElement=null,delete this._cachedViewbox},Pn.prototype.focus=function(){this._svg.focus({preventScroll:!0}),this._setFocused(!0)},Pn.prototype.restoreFocus=function(){document.activeElement===document.body&&this.focus()},Pn.prototype.isFocused=function(){return this._focused},Pn.prototype.getDefaultLayer=function(){return this.getLayer("base",0)},Pn.prototype.getLayer=function(e,t){if(!e)throw new Error("must specify a name");let n=this._layers[e];if(n||(n=this._layers[e]=this._createLayer(e,t)),void 0!==t&&n.index!==t)throw new Error("layer <"+e+"> already created at index <"+t+">");return n.group},Pn.prototype._getChildIndex=function(e){return m(this._layers,(function(t,n){return n.visible&&e>=n.index&&t++,t}),0)},Pn.prototype._createLayer=function(e,t){void 0===t&&(t=1);const n=this._getChildIndex(t);return{group:Cn(this._viewport,"layer-"+e,n),index:t,visible:!0}},Pn.prototype.showLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=this._viewport,i=t.group,r=t.index;if(t.visible)return i;const o=this._getChildIndex(r);return n.insertBefore(i,n.childNodes[o]||null),t.visible=!0,i},Pn.prototype.hideLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=t.group;return t.visible?(ee(n),t.visible=!1,n):n},Pn.prototype._removeLayer=function(e){const t=this._layers[e];t&&(delete this._layers[e],ee(t.group))},Pn.prototype.getActiveLayer=function(){const e=this._findPlaneForRoot(this.getRootElement());return e?e.layer:null},Pn.prototype.findRoot=function(e){if("string"==typeof e&&(e=this._elementRegistry.get(e)),!e)return;const t=this._findPlaneForRoot(function(e){for(;e.parent;)e=e.parent;return e}(e))||{};return t.rootElement},Pn.prototype.getRootElements=function(){return this._planes.map((function(e){return e.rootElement}))},Pn.prototype._findPlaneForRoot=function(e){return u(this._planes,(function(t){return t.rootElement===e}))},Pn.prototype.getContainer=function(){return this._container},Pn.prototype._updateMarker=function(e,t,n){let i;e.id||(e=this._elementRegistry.get(e)),e.markers=e.markers||new Set,i=this._elementRegistry._elements[e.id],i&&(f([i.gfx,i.secondaryGfx],(function(i){i&&(n?(e.markers.add(t),F(i).add(t)):(e.markers.delete(t),F(i).remove(t)))})),this._eventBus.fire("element.marker.update",{element:e,gfx:i.gfx,marker:t,add:!!n}))},Pn.prototype.addMarker=function(e,t){this._updateMarker(e,t,!0)},Pn.prototype.removeMarker=function(e,t){this._updateMarker(e,t,!1)},Pn.prototype.hasMarker=function(e,t){return e.id||(e=this._elementRegistry.get(e)),!!e.markers&&e.markers.has(t)},Pn.prototype.toggleMarker=function(e,t){this.hasMarker(e,t)?this.removeMarker(e,t):this.addMarker(e,t)},Pn.prototype.getRootElement=function(){const e=this._rootElement;return e||this._planes.length?e:this.setRootElement(this.addRootElement(null))},Pn.prototype.addRootElement=function(e){const t=this._rootsIdx++;e||(e={id:"__implicitroot_"+t,children:[],isImplicit:!0});const n=e.layer="root-"+t;this._ensureValid("root",e);const i=this.getLayer(n,0);return this.hideLayer(n),this._addRoot(e,i),this._planes.push({rootElement:e,layer:i}),e},Pn.prototype.removeRootElement=function(e){"string"==typeof e&&(e=this._elementRegistry.get(e));if(this._findPlaneForRoot(e))return this._removeRoot(e),this._removeLayer(e.layer),this._planes=this._planes.filter((function(t){return t.rootElement!==e})),this._rootElement===e&&(this._rootElement=null),e},Pn.prototype.setRootElement=function(e){if(e===this._rootElement)return e;let t;if(!e)throw new Error("rootElement required");return t=this._findPlaneForRoot(e),t||(e=this.addRootElement(e)),this._setRoot(e),e},Pn.prototype._removeRoot=function(e){const t=this._elementRegistry,n=this._eventBus;n.fire("root.remove",{element:e}),n.fire("root.removed",{element:e}),t.remove(e)},Pn.prototype._addRoot=function(e,t){const n=this._elementRegistry,i=this._eventBus;i.fire("root.add",{element:e}),n.add(e,t),i.fire("root.added",{element:e,gfx:t})},Pn.prototype._setRoot=function(e,t){const n=this._rootElement;n&&(this._elementRegistry.updateGraphics(n,null,!0),this.hideLayer(n.layer)),e&&(t||(t=this._findPlaneForRoot(e).layer),this._elementRegistry.updateGraphics(e,this._svg,!0),this.showLayer(e.layer)),this._rootElement=e,this._eventBus.fire("root.set",{element:e})},Pn.prototype._ensureValid=function(e,t){if(!t.id)throw new Error("element must have an id");if(this._elementRegistry.get(t.id))throw new Error("element <"+t.id+"> already exists");const n=Mn[e],i=d(n,(function(e){return void 0!==t[e]}));if(!i)throw new Error("must supply { "+n.join(", ")+" } with "+e)},Pn.prototype._setParent=function(e,t,n){!function(e,t,n){if(e&&t){"number"!=typeof n&&(n=-1);var i=e.indexOf(t);if(-1!==i){if(i===n)return;if(-1===n)return;e.splice(i,1)}-1!==n?e.splice(n,0,t):e.push(t)}}(t.children,e,n),e.parent=t},Pn.prototype._addElement=function(e,t,n,i){n=n||this.getRootElement();const r=this._eventBus,o=this._graphicsFactory;this._ensureValid(e,t),r.fire(e+".add",{element:t,parent:n}),this._setParent(t,n,i);const a=o.create(e,t,i);return this._elementRegistry.add(t,a),o.update(e,t,a),r.fire(e+".added",{element:t,gfx:a}),t},Pn.prototype.addShape=function(e,t,n){return this._addElement("shape",e,t,n)},Pn.prototype.addConnection=function(e,t,n){return this._addElement("connection",e,t,n)},Pn.prototype._removeElement=function(e,t){const n=this._elementRegistry,i=this._graphicsFactory,r=this._eventBus;if(e=n.get(e.id||e))return r.fire(t+".remove",{element:e}),i.remove(e),function(e,t){if(!e||!t)return-1;var n=e.indexOf(t);-1!==n&&e.splice(n,1)}(e.parent&&e.parent.children,e),e.parent=null,r.fire(t+".removed",{element:e}),n.remove(e),e},Pn.prototype.removeShape=function(e){return this._removeElement(e,"shape")},Pn.prototype.removeConnection=function(e){return this._removeElement(e,"connection")},Pn.prototype.getGraphics=function(e,t){return this._elementRegistry.getGraphics(e,t)},Pn.prototype._changeViewbox=function(e){this._eventBus.fire("canvas.viewbox.changing"),e.apply(this),this._cachedViewbox=null,this._viewboxChanged()},Pn.prototype._viewboxChanged=function(){this._eventBus.fire("canvas.viewbox.changed",{viewbox:this.viewbox()})},Pn.prototype.viewbox=function(e){if(void 0===e&&this._cachedViewbox)return structuredClone(this._cachedViewbox);const t=this._viewport,n=this.getSize();let i,r,o,a,s,l,p;return e?(this._changeViewbox((function(){s=Math.min(n.width/e.width,n.height/e.height);const i=this._svg.createSVGMatrix().scale(s).translate(-e.x,-e.y);ne(t,i)})),e):(o=this._rootElement?this.getActiveLayer():null,i=o&&o.getBBox()||{},a=ne(t),r=a?a.matrix:function(e,t,n,i,r,o){var a=H().createSVGMatrix();switch(arguments.length){case 0:return a;case 1:return K(a,e);case 6:return K(a,{a:e,b:t,c:n,d:i,e:r,f:o})}}(),s=Rn(r.a,1e3),l=Rn(-r.e||0,1e3),p=Rn(-r.f||0,1e3),e=this._cachedViewbox={x:l?l/s:0,y:p?p/s:0,width:n.width/s,height:n.height/s,scale:s,inner:{width:i.width||0,height:i.height||0,x:i.x||0,y:i.y||0},outer:n})},Pn.prototype.scroll=function(e){const t=this._viewport;let n=t.getCTM();return e&&this._changeViewbox((function(){e=E({dx:0,dy:0},e||{}),n=this._svg.createSVGMatrix().translate(e.dx,e.dy).multiply(n),Nn(t,n)})),{x:n.e,y:n.f}},Pn.prototype.scrollToElement=function(e,t){let n=100;"string"==typeof e&&(e=this._elementRegistry.get(e));const i=this.findRoot(e);if(i!==this.getRootElement()&&this.setRootElement(i),i===e)return;t||(t={}),"number"==typeof t&&(n=t),t={top:t.top||n,right:t.right||n,bottom:t.bottom||n,left:t.left||n};const r=_t(e),o=ft(r),a=this.viewbox(),s=this.zoom();let l,p;a.y+=t.top/s,a.x+=t.left/s,a.width-=(t.right+t.left)/s,a.height-=(t.bottom+t.top)/s;const c=ft(a);if(r.width<a.width&&r.height<a.height){const e=Math.max(0,o.right-c.right),t=Math.min(0,o.left-c.left),n=Math.max(0,o.bottom-c.bottom),i=Math.min(0,o.top-c.top);l=e||t,p=n||i}else l=r.x-a.x,p=r.y-a.y;this.scroll({dx:-l*s,dy:-p*s})},Pn.prototype.zoom=function(e,t){if(!e)return this.viewbox(e).scale;if("fit-viewport"===e)return this._fitViewport(t);let n,i;return this._changeViewbox((function(){"object"!=typeof t&&(n=this.viewbox().outer,t={x:n.width/2,y:n.height/2}),i=this._setZoom(e,t)})),Rn(i.a,1e3)},Pn.prototype._fitViewport=function(e){const t=this.viewbox(),n=t.outer,i=t.inner;let r,o;return i.x>=0&&i.y>=0&&i.x+i.width<=n.width&&i.y+i.height<=n.height&&!e?o={x:0,y:0,width:Math.max(i.width+i.x,n.width),height:Math.max(i.height+i.y,n.height)}:(r=Math.min(1,n.width/i.width,n.height/i.height),o={x:i.x+(e?i.width/2-n.width/r/2:0),y:i.y+(e?i.height/2-n.height/r/2:0),width:n.width/r,height:n.height/r}),this.viewbox(o),this.viewbox(!1).scale},Pn.prototype._setZoom=function(e,t){const n=this._svg,i=this._viewport,r=n.createSVGMatrix(),o=n.createSVGPoint();let a,s,l,p,c;l=i.getCTM();const u=l.a;return t?(a=E(o,t),s=a.matrixTransform(l.inverse()),p=r.translate(s.x,s.y).scale(1/u*e).translate(-s.x,-s.y),c=l.multiply(p)):c=r.scale(e),Nn(this._viewport,c),c},Pn.prototype.getSize=function(){return{width:this._container.clientWidth,height:this._container.clientHeight}},Pn.prototype.getAbsoluteBBox=function(e){const t=this.viewbox();let n;if(e.waypoints){n=this.getGraphics(e).getBBox()}else n=e;return{x:n.x*t.scale-t.x*t.scale,y:n.y*t.scale-t.y*t.scale,width:n.width*t.scale,height:n.height*t.scale}},Pn.prototype.resized=function(){delete this._cachedViewbox,this._eventBus.fire("canvas.resized")};var Tn="data-element-id";function Dn(e){this._elements={},this._eventBus=e}function Bn(e,t,n){var i=function(e,t,n,i){var r=n.inverse;return Object.defineProperty(e,"remove",{value:function(e){var n=this.indexOf(e);return-1!==n&&(this.splice(n,1),t.unset(e,r,i)),e}}),Object.defineProperty(e,"contains",{value:function(e){return-1!==this.indexOf(e)}}),Object.defineProperty(e,"add",{value:function(e,n){var o=this.indexOf(e);if(void 0===n){if(-1!==o)return;n=this.length}-1!==o&&this.splice(o,1),this.splice(n,0,e),-1===o&&t.set(e,r,i)}}),Object.defineProperty(e,"__refs_collection",{value:!0}),e}(n[t.name]||[],e,t,n);Object.defineProperty(n,t.name,{enumerable:t.enumerable,value:i}),i.length&&i.forEach((function(i){e.set(i,t.inverse,n)}))}function On(e,t){if(!(this instanceof On))return new On(e,t);e.inverse=t,t.inverse=e,this.props={},this.props[e.name]=e,this.props[t.name]=t}Dn.$inject=["eventBus"],Dn.prototype.add=function(e,t,n){var i=e.id;this._validateId(i),L(t,Tn,i),n&&L(n,Tn,i),this._elements[i]={element:e,gfx:t,secondaryGfx:n}},Dn.prototype.remove=function(e){var t=this._elements,n=e.id||e,i=n&&t[n];i&&(L(i.gfx,Tn,""),i.secondaryGfx&&L(i.secondaryGfx,Tn,""),delete t[n])},Dn.prototype.updateId=function(e,t){this._validateId(t),"string"==typeof e&&(e=this.get(e)),this._eventBus.fire("element.updateId",{element:e,newId:t});var n=this.getGraphics(e),i=this.getGraphics(e,!0);this.remove(e),e.id=t,this.add(e,n,i)},Dn.prototype.updateGraphics=function(e,t,n){var i=e.id||e,r=this._elements[i];return n?r.secondaryGfx=t:r.gfx=t,t&&L(t,Tn,i),t},Dn.prototype.get=function(e){var t;t="string"==typeof e?e:e&&L(e,Tn);var n=this._elements[t];return n&&n.element},Dn.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(n)})),t},Dn.prototype.find=function(e){for(var t=this._elements,n=Object.keys(t),i=0;i<n.length;i++){var r=t[n[i]],o=r.element;if(e(o,r.gfx))return o}},Dn.prototype.getAll=function(){return this.filter((function(e){return e}))},Dn.prototype.forEach=function(e){var t=this._elements;Object.keys(t).forEach((function(n){var i=t[n],r=i.element,o=i.gfx;return e(r,o)}))},Dn.prototype.getGraphics=function(e,t){var n=e.id||e,i=this._elements[n];return i&&(t?i.secondaryGfx:i.gfx)},Dn.prototype._validateId=function(e){if(!e)throw new Error("element must have an id");if(this._elements[e])throw new Error("element with id "+e+" already added")},On.prototype.bind=function(e,t){if("string"==typeof t){if(!this.props[t])throw new Error("no property <"+t+"> in ref");t=this.props[t]}t.collection?Bn(this,t,e):function(e,t,n){var i=t.inverse,r=n[t.name];Object.defineProperty(n,t.name,{configurable:t.configurable,enumerable:t.enumerable,get:function(){return r},set:function(t){if(t!==r){var o=r;r=null,o&&e.unset(o,i,n),r=t,e.set(r,i,n)}}})}(this,t,e)},On.prototype.ensureRefsCollection=function(e,t){var n=e[t.name];return function(e){return!0===e.__refs_collection}(n)||Bn(this,t,e),n},On.prototype.ensureBound=function(e,t){(function(e,t){return Object.prototype.hasOwnProperty.call(e,t.name||t)})(e,t)||this.bind(e,t)},On.prototype.unset=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).remove(n):e[t.name]=void 0)},On.prototype.set=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).add(n):e[t.name]=n)};var Ln=new On({name:"children",enumerable:!0,collection:!0},{name:"parent"}),In=new On({name:"labels",enumerable:!0,collection:!0},{name:"labelTarget"}),Fn=new On({name:"attachers",collection:!0},{name:"host"}),jn=new On({name:"outgoing",collection:!0},{name:"source"}),Vn=new On({name:"incoming",collection:!0},{name:"target"});function Wn(){Object.defineProperty(this,"businessObject",{writable:!0}),Object.defineProperty(this,"label",{get:function(){return this.labels[0]},set:function(e){var t=this.label,n=this.labels;!e&&t?n.remove(t):n.add(e,0)}}),Ln.bind(this,"parent"),In.bind(this,"labels"),jn.bind(this,"outgoing"),Vn.bind(this,"incoming")}function zn(){Wn.call(this),Ln.bind(this,"children"),Fn.bind(this,"host"),Fn.bind(this,"attachers")}function $n(){Wn.call(this),Ln.bind(this,"children")}function Gn(){zn.call(this),In.bind(this,"labelTarget")}function Hn(){Wn.call(this),jn.bind(this,"source"),Vn.bind(this,"target")}e(zn,Wn),e($n,zn),e(Gn,zn),e(Hn,Wn);var Kn={connection:Hn,shape:zn,label:Gn,root:$n};function Un(){this._uid=12}Un.prototype.createRoot=function(e){return this.create("root",e)},Un.prototype.createLabel=function(e){return this.create("label",e)},Un.prototype.createShape=function(e){return this.create("shape",e)},Un.prototype.createConnection=function(e){return this.create("connection",e)},Un.prototype.create=function(e,t){return(t=E({},t||{})).id||(t.id=e+"_"+this._uid++),function(e,t){var n=Kn[e];if(!n)throw new Error("unknown type: <"+e+">");return E(new n,t)}(e,t)};var qn="__fn",Yn=Array.prototype.slice;function Xn(){this._listeners={},this.on("diagram.destroy",1,this._destroy,this)}function Zn(){}function Jn(e,t){this._eventBus=e,this._elementRegistry=t}function Qn(e,t,n){var i=n||t.firstChild;e!==i&&t.insertBefore(e,i)}Xn.prototype.on=function(e,t,n,i){if(e=o(e)?e:[e],l(t)&&(i=n,n=t,t=1e3),!s(t))throw new Error("priority must be a number");var r=n;i&&((r=w(n,i))[qn]=n[qn]||n);var a=this;e.forEach((function(e){a._addListener(e,{priority:t,callback:r,next:null})}))},Xn.prototype.once=function(e,t,n,i){var r=this;if(l(t)&&(i=n,n=t,t=1e3),!s(t))throw new Error("priority must be a number");function o(){o.__isTomb=!0;var t=n.apply(i,arguments);return r.off(e,o),t}o[qn]=n,this.on(e,t,o)},Xn.prototype.off=function(e,t){e=o(e)?e:[e];var n=this;e.forEach((function(e){n._removeListener(e,t)}))},Xn.prototype.createEvent=function(e){var t=new Zn;return t.init(e),t},Xn.prototype.fire=function(e,t){var n,i,r,o;if(o=Yn.call(arguments),"object"==typeof e&&(e=(t=e).type),!e)throw new Error("no event type specified");if(i=this._listeners[e]){n=t instanceof Zn?t:this.createEvent(t),o[0]=n;var a=n.type;e!==a&&(n.type=e);try{r=this._invokeListeners(n,o,i)}finally{e!==a&&(n.type=a)}return void 0===r&&n.defaultPrevented&&(r=!1),r}},Xn.prototype.handleError=function(e){return!1===this.fire("error",{error:e})},Xn.prototype._destroy=function(){this._listeners={}},Xn.prototype._invokeListeners=function(e,t,n){for(var i;n&&!e.cancelBubble;)i=this._invokeListener(e,t,n),n=n.next;return i},Xn.prototype._invokeListener=function(e,t,n){var i;if(n.callback.__isTomb)return i;try{i=function(e,t){return e.apply(null,t)}(n.callback,t),void 0!==i&&(e.returnValue=i,e.stopPropagation()),!1===i&&e.preventDefault()}catch(e){if(!this.handleError(e))throw console.error("unhandled error in event listener",e),e}return i},Xn.prototype._addListener=function(e,t){var n,i=this._getListeners(e);if(i){for(;i;){if(i.priority<t.priority)return t.next=i,void(n?n.next=t:this._setListeners(e,t));n=i,i=i.next}n.next=t}else this._setListeners(e,t)},Xn.prototype._getListeners=function(e){return this._listeners[e]},Xn.prototype._setListeners=function(e,t){this._listeners[e]=t},Xn.prototype._removeListener=function(e,t){var n,i,r,o=this._getListeners(e);if(t)for(;o;)n=o.next,(r=o.callback)!==t&&r[qn]!==t||(i?i.next=n:this._setListeners(e,n)),i=o,o=n;else this._setListeners(e,null)},Zn.prototype.stopPropagation=function(){this.cancelBubble=!0},Zn.prototype.preventDefault=function(){this.defaultPrevented=!0},Zn.prototype.init=function(e){E(this,e||{})},Jn.$inject=["eventBus","elementRegistry"],Jn.prototype._getChildrenContainer=function(e){var t,n=this._elementRegistry.getGraphics(e);return e.parent?(t=function(e){return e.parentNode.childNodes[1]}(n),t||(F(t=$("g")).add("djs-children"),D(n.parentNode,t))):t=n,t},Jn.prototype._clear=function(e){var t=function(e){return e.childNodes[0]}(e);return Pe(t),t},Jn.prototype._createContainer=function(e,t,n,i){var r=$("g");F(r).add("djs-group"),void 0!==n?Qn(r,t,t.childNodes[n]):D(t,r);var o=$("g");F(o).add("djs-element"),F(o).add("djs-"+e),i&&F(o).add("djs-frame"),D(r,o);var a=$("g");return F(a).add("djs-visual"),D(o,a),o},Jn.prototype.create=function(e,t,n){var i=this._getChildrenContainer(t.parent);return this._createContainer(e,i,n,kt(t))},Jn.prototype.updateContainments=function(e){var t,n=this,i=this._elementRegistry;t=m(e,(function(e,t){return t.parent&&(e[t.parent.id]=t.parent),e}),{}),f(t,(function(e){var t=e.children;if(t){var r=n._getChildrenContainer(e);f(t.slice().reverse(),(function(e){Qn(i.getGraphics(e).parentNode,r)}))}}))},Jn.prototype.drawShape=function(e,t,n={}){return this._eventBus.fire("render.shape",{gfx:e,element:t,attrs:n})},Jn.prototype.getShapePath=function(e){return this._eventBus.fire("render.getShapePath",e)},Jn.prototype.drawConnection=function(e,t,n={}){return this._eventBus.fire("render.connection",{gfx:e,element:t,attrs:n})},Jn.prototype.getConnectionPath=function(e){return this._eventBus.fire("render.getConnectionPath",e)},Jn.prototype.update=function(e,t,n){if(t.parent){var i=this._clear(n);if("shape"===e)this.drawShape(i,t),qe(n,t.x,t.y);else{if("connection"!==e)throw new Error("unknown type: "+e);this.drawConnection(i,t)}t.hidden?L(n,"display","none"):L(n,"display","block")}},Jn.prototype.remove=function(e){ee(this._elementRegistry.getGraphics(e).parentNode)};var ei={__depends__:[kn],__init__:["canvas"],canvas:["type",Pn],elementRegistry:["type",Dn],elementFactory:["type",Un],eventBus:["type",Xn],graphicsFactory:["type",Jn]};function ti(e){return function(e){var t=new En(e);return t.init(),t}([{config:["value",e=e||{}]},ei].concat(e.modules||[]))}function ni(e,t){this._injector=t||ti(e),this.get("eventBus").fire("diagram.init")}function ii(){}function ri(e,t){this.model=e,this.properties=t}ni.prototype.get=function(e,t){return this._injector.get(e,t)},ni.prototype.invoke=function(e,t,n){return this._injector.invoke(e,t,n)},ni.prototype.destroy=function(){this.get("eventBus").fire("diagram.destroy")},ni.prototype.clear=function(){this.get("eventBus").fire("diagram.clear")},ii.prototype.get=function(e){return this.$model.properties.get(this,e)},ii.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},ri.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(ii.prototype);f(e.properties,(function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)})),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function o(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),f(e,w((function(e,t){this.set(t,e)}),this))}return o.prototype=i,o.hasType=i.$instanceOf=this.model.hasType,n.defineModel(o,t),n.defineDescriptor(o,e),o};var oi={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},ai={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e)}};function si(e,t){var n=ai[e];return n?n(t):t}function li(e){return!!oi[e]}function pi(e){return!!ai[e]}function ci(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function ui(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function hi(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,f(e,w(this.registerPackage,this))}function fi(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function mi(e){this.model=e}function di(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function yi(e){return e.replace(/^:/,"")}function gi(e,t={}){this.properties=new mi(this),this.factory=new ri(this,this.properties),this.registry=new hi(e,this.properties),this.typeCache={},this.config=t}ui.prototype.build=function(){return function(e,t){let n={},i=Object(e);return f(t,(function(t){t in i&&(n[t]=e[t])})),n}(this,["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"])},ui.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},ui.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,o=this.propertiesByName,a=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var s=r.indexOf(e);if(-1===s)throw new Error("property <"+i.name+"> not found in property list");r.splice(s,1),this.addProperty(t,n?void 0:s,a),o[i.name]=o[i.localName]=t},ui.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),o=ci(r[0],i),a=ci(r[1],o.prefix).name,s=this.propertiesByName[a];if(!s)throw new Error("refined property <"+a+"> not found");this.replaceProperty(s,e,n),delete e.redefines},ui.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},ui.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},ui.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},ui.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},ui.prototype.assertNotTrait=function(e){if((e.extends||[]).length)throw new Error(`cannot create <${e.name}> extending <${e.extends}>`)},ui.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},ui.prototype.hasProperty=function(e){return this.propertiesByName[e]},ui.prototype.addTrait=function(e,t){t&&this.assertNotTrait(e);var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(f(e.properties,w((function(n){n=E({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))}),this)),i.push(e),n[r]=e)},hi.prototype.getPackage=function(e){return this.packageMap[e]},hi.prototype.getPackages=function(){return this.packages},hi.prototype.registerPackage=function(e){e=E({},e);var t=this.packageMap;fi(t,e,"prefix"),fi(t,e,"uri"),f(e.types,w((function(t){this.registerType(t,e)}),this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},hi.prototype.registerType=function(e,t){var n=ci((e=E({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:E(e.meta||{})})).name,t.prefix),i=n.name,r={};f(e.properties,w((function(e){var t=ci(e.name,n.prefix),i=t.name;li(e.type)||(e.type=ci(e.type,t.prefix).name),E(e,{ns:t,name:i}),r[i]=e}),this)),E(e,{ns:n,name:i,propertiesByName:r}),f(e.extends,w((function(e){var t=ci(e,n.prefix),r=this.typeMap[t.name];r.traits=r.traits||[],r.traits.push(i)}),this)),this.definePackage(e,t),this.typeMap[i]=e},hi.prototype.mapTypes=function(e,t,n){var i=li(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function o(n,i){var o=ci(n,li(n)?"":e.prefix);r.mapTypes(o,t,i)}function a(e){return o(e,!0)}if(!i)throw new Error("unknown type <"+e.name+">");f(i.superClass,n?a:function(e){return o(e,!1)}),t(i,!n),f(i.traits,a)},hi.prototype.getEffectiveDescriptor=function(e){var t=ci(e),n=new ui(t);this.mapTypes(t,(function(e,t){n.addTrait(e,t)}));var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},hi.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},mi.prototype.set=function(e,t,n){if(!p(t)||!t.length)throw new TypeError("property name must be a non-empty string");var i=this.getProperty(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[yi(t)]:i?r in e?e[r]=n:di(e,i,n):e.$attrs[yi(t)]=n},mi.prototype.get=function(e,t){var n=this.getProperty(e,t);if(!n)return e.$attrs[yi(t)];var i=n.name;return!e[i]&&n.isMany&&di(e,n,[]),e[i]},mi.prototype.define=function(e,t,n){if(!n.writable){var i=n.value;delete(n=E({},n,{get:function(){return i}})).value}Object.defineProperty(e,t,n)},mi.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},mi.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},mi.prototype.getProperty=function(e,t){var n=this.model,i=n.getPropertyDescriptor(e,t);if(i)return i;if(t.includes(":"))return null;const r=n.config.strict;if(void 0!==r){const n=new TypeError(`unknown property <${t}> on <${e.$type}>`);if(r)throw n;"undefined"!=typeof console&&console.warn(n)}return null},gi.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},gi.prototype.getType=function(e){var t=this.typeCache,n=p(e)?e:e.ns.name,i=t[n];return i||(e=this.registry.getEffectiveDescriptor(n),i=t[n]=this.factory.createType(e)),i},gi.prototype.createAny=function(e,t,n){var o=ci(e),s={$type:e,$instanceOf:function(e){return e===this.$type},get:function(e){return this[e]},set:function(e,t){!function(e,t,n){let o=e;f(t,(function(e,a){if("number"!=typeof e&&"string"!=typeof e)throw new Error("illegal key type: "+typeof e+". Key should be of type number or string.");if("constructor"===e)throw new Error("illegal key: constructor");if("__proto__"===e)throw new Error("illegal key: __proto__");let s=t[a+1],l=o[e];r(s)&&null==l&&(l=o[e]=isNaN(+s)?{}:[]),i(s)?i(n)?delete o[e]:o[e]=n:o=l}))}(this,[e],t)}},l={name:e,isGeneric:!0,ns:{prefix:o.prefix,localName:o.localName,uri:t}};return this.properties.defineDescriptor(s,l),this.properties.defineModel(s,this),this.properties.define(s,"get",{enumerable:!1,writable:!0}),this.properties.define(s,"set",{enumerable:!1,writable:!0}),this.properties.define(s,"$parent",{enumerable:!1,writable:!0}),this.properties.define(s,"$instanceOf",{enumerable:!1,writable:!0}),f(n,(function(e,t){a(e)&&void 0!==e.value?s[e.name]=e.value:s[t]=e})),s},gi.prototype.getPackage=function(e){return this.registry.getPackage(e)},gi.prototype.getPackages=function(){return this.registry.getPackages()},gi.prototype.getElementDescriptor=function(e){return e.$descriptor},gi.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},gi.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},gi.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var vi=String.fromCharCode,xi=Object.prototype.hasOwnProperty,bi=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,wi={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function Ei(e,t,n,i){return i?xi.call(wi,i)?wi[i]:"&"+i+";":vi(t||parseInt(n,16))}function _i(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(bi,Ei):e}Object.keys(wi).forEach((function(e){wi[e.toUpperCase()]=wi[e]}));var Ai="non-whitespace outside of root node";function ki(e){return new Error(e)}function Ri(e){return"missing namespace for prefix <"+e+">"}function Si(e){return{get:e,enumerable:!0}}function Ci(e){var t,n={};for(t in e)n[t]=e[t];return n}function Mi(e){return e+"$uri"}function Pi(){return{line:0,column:0}}function Ni(e){throw e}function Ti(e){if(!this)return new Ti(e);var t,n,i,r,o,a,s,l,p,c=e&&e.proxy,u=Ni,h=Pi,f=!1,m=!1,d=null,y=!1;function g(e){e instanceof Error||(e=ki(e)),d=e,u(e,h)}function v(e){o&&(e instanceof Error||(e=ki(e)),o(e,h))}this.on=function(e,p){if("function"!=typeof p)throw ki("required args <name, cb>");switch(e){case"openTag":n=p;break;case"text":t=p;break;case"closeTag":i=p;break;case"error":u=p;break;case"warn":o=p;break;case"cdata":r=p;break;case"attention":l=p;break;case"question":s=p;break;case"comment":a=p;break;default:throw ki("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw ki("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return m=!0,p=n,this},this.parse=function(e){if("string"!=typeof e)throw ki("required args <xml=string>");return d=null,function(e){var o,u,d,x,b,w,E,_,A,k,R,S=m?[]:null,C=m?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[Mi(n)]=t;return i}(p):null,M=[],P=0,N=!1,T=!1,D=0,B=0,O="",L=0;function I(){if(null!==R)return R;var e,t,n,i,r,o,a,s,l,c,u,h=m&&C.xmlns,d=m&&f?[]:null,y=L,g=O,x=g.length,b={},w={};e:for(;y<x;y++)if(l=!1,!(32===(c=g.charCodeAt(y))||c<14&&c>8)){for((c<65||c>122||c>90&&c<97)&&95!==c&&58!==c&&(v("illegal first char attribute name"),l=!0),u=y+1;u<x;u++)if(!((c=g.charCodeAt(u))>96&&c<123||c>64&&c<91||c>47&&c<59||46===c||45===c||95===c)){if(32===c||c<14&&c>8){v("missing attribute value"),y=u;continue e}if(61===c)break;v("illegal attribute name char"),l=!0}if("xmlns:xmlns"===(s=g.substring(y,u))&&(v("illegal declaration of xmlns"),l=!0),34===(c=g.charCodeAt(u+1)))-1===(u=g.indexOf('"',y=u+2))&&-1!==(u=g.indexOf("'",y))&&(v("attribute value quote missmatch"),l=!0);else if(39===c)-1===(u=g.indexOf("'",y=u+2))&&-1!==(u=g.indexOf('"',y))&&(v("attribute value quote missmatch"),l=!0);else for(v("missing attribute value quotes"),l=!0,u+=1;u<x&&!(32===(c=g.charCodeAt(u+1))||c<14&&c>8);u++);for(-1===u&&(v("missing closing quotes"),u=x,l=!0),l||(o=g.substring(y,u)),y=u;u+1<x&&!(32===(c=g.charCodeAt(u+1))||c<14&&c>8);u++)y===u&&(v("illegal character after attribute end"),l=!0);if(y=u+1,!l)if(s in w)v("attribute <"+s+"> already defined");else if(w[s]=!0,m)if(f){if(null!==(r="xmlns"===s?"xmlns":120===s.charCodeAt(0)&&"xmlns:"===s.substr(0,6)?s.substr(6):null)){if(e=_i(o),t=Mi(r),!(a=p[e])){if("xmlns"===r||t in C&&C[t]!==e)do{a="ns"+P++}while(void 0!==C[a]);else a=r;p[e]=a}C[r]!==a&&(i||(C=Ci(C),i=!0),C[r]=a,"xmlns"===r&&(C[Mi(a)]=e,h=a),C[t]=e),b[s]=o;continue}d.push(s,o)}else-1!==(c=s.indexOf(":"))?(n=C[s.substring(0,c)])?b[s=h===n?s.substr(c+1):n+s.substr(c)]=o:v(Ri(s.substring(0,c))):b[s]=o;else b[s]=o}if(f)for(y=0,x=d.length;y<x;y++){if(s=d[y++],o=d[y],-1!==(c=s.indexOf(":"))){if(!(n=C[s.substring(0,c)])){v(Ri(s.substring(0,c)));continue}s=h===n?s.substr(c+1):n+s.substr(c)}b[s]=o}return R=b}function F(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,o=0,a=0,s=B;D>=a&&(t=i.exec(e))&&!((s=t[0].length+t.index)>D);)r+=1,a=s;return-1==D?(o=s,n=e.substring(B)):0===B?n=e.substring(B,D):(o=D-a,n=-1==B?e.substring(D):e.substring(D,B+1)),{data:n,line:r,column:o}}h=F,c&&(k=Object.create({},{name:Si((function(){return _})),originalName:Si((function(){return A})),attrs:Si(I),ns:Si((function(){return C}))}));for(;-1!==B;){if(-1===(D=60===e.charCodeAt(B)?B:e.indexOf("<",B)))return M.length?g("unexpected end of file"):0===B?g("missing start tag"):void(B<e.length&&e.substring(B).trim()&&v(Ai));if(B!==D)if(M.length){if(t&&(t(e.substring(B,D),_i,h),y))return}else if(e.substring(B,D).trim()&&(v(Ai),y))return;if(33===(b=e.charCodeAt(D+1))){if(91===(x=e.charCodeAt(D+2))&&"CDATA["===e.substr(D+3,6)){if(-1===(B=e.indexOf("]]>",D)))return g("unclosed cdata");if(r&&(r(e.substring(D+9,B),h),y))return;B+=3;continue}if(45===x&&45===e.charCodeAt(D+3)){if(-1===(B=e.indexOf("--\x3e",D)))return g("unclosed comment");if(a&&(a(e.substring(D+4,B),_i,h),y))return;B+=3;continue}}if(63!==b){for(u=D+1;;u++){if(w=e.charCodeAt(u),isNaN(w))return B=-1,g("unclosed tag");if(34===w)u=-1!==(x=e.indexOf('"',u+1))?x:u;else if(39===w)u=-1!==(x=e.indexOf("'",u+1))?x:u;else if(62===w){B=u;break}}if(33!==b){if(R={},47===b){if(N=!1,T=!0,!M.length)return g("missing open tag");if(u=_=M.pop(),x=D+2+u.length,e.substring(D+2,x)!==u)return g("closing tag mismatch");for(;x<B;x++)if(!(32===(b=e.charCodeAt(x))||b>8&&b<14))return g("close tag")}else{if(47===e.charCodeAt(B-1)?(u=_=e.substring(D+1,B-1),N=!0,T=!0):(u=_=e.substring(D+1,B),N=!0,T=!1),!(b>96&&b<123||b>64&&b<91||95===b||58===b))return g("illegal first char nodeName");for(x=1,d=u.length;x<d;x++)if(!((b=u.charCodeAt(x))>96&&b<123||b>64&&b<91||b>47&&b<59||45===b||95===b||46==b)){if(32===b||b<14&&b>8){_=u.substring(0,x),R=null;break}return g("invalid nodeName")}T||M.push(_)}if(m){if(o=C,N&&(T||S.push(o),null===R&&(f=-1!==u.indexOf("xmlns",x))&&(L=x,O=u,I(),f=!1)),A=_,-1!==(b=_.indexOf(":"))){if(!(E=C[_.substring(0,b)]))return g("missing namespace on <"+A+">");_=_.substr(b+1)}else E=C.xmlns;E&&(_=E+":"+_)}if(N&&(L=x,O=u,n&&(c?n(k,_i,T,h):n(_,I,_i,T,h),y)))return;if(T){if(i&&(i(c?k:_,_i,N,h),y))return;m&&(C=N?o:S.pop())}B+=1}else{if(l&&(l(e.substring(D,B+1),_i,h),y))return;B+=1}}else{if(-1===(B=e.indexOf("?>",D)))return g("unclosed question");if(s&&(s(e.substring(D,B+2),h),y))return;B+=2}}}(e),h=Pi,y=!1,d},this.stop=function(){y=!0}}function Di(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var Bi={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},Oi="property";function Li(e){return e.xml&&e.xml.serialize}function Ii(e,t){return Di(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function Fi(e){return new Error(e)}function ji(e){return e.$descriptor}function Vi(e){E(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw Fi("expected element");var t,n=this.elementsById,i=ji(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw Fi("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function Wi(){}function zi(){}function $i(){}function Gi(e,t){this.property=e,this.context=t}function Hi(e,t){this.element=t,this.propertyDesc=e}function Ki(){}function Ui(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function qi(e,t,n){Ui.call(this,e,t,n)}function Yi(e,t,n){this.model=e,this.context=n}function Xi(e){e instanceof gi&&(e={model:e}),E(this,{lax:!1},e)}Wi.prototype.handleEnd=function(){},Wi.prototype.handleText=function(){},Wi.prototype.handleNode=function(){},zi.prototype=Object.create(Wi.prototype),zi.prototype.handleNode=function(){return this},$i.prototype=Object.create(Wi.prototype),$i.prototype.handleText=function(e){this.body=(this.body||"")+e},Gi.prototype=Object.create($i.prototype),Gi.prototype.handleNode=function(e){if(this.element)throw Fi("expected no sub nodes");return this.element=this.createReference(e),this},Gi.prototype.handleEnd=function(){this.element.id=this.body},Gi.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},Hi.prototype=Object.create($i.prototype),Hi.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=si(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},Ki.prototype=Object.create($i.prototype),Ki.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},Ui.prototype=Object.create(Ki.prototype),Ui.prototype.addReference=function(e){this.context.addReference(e)},Ui.prototype.handleText=function(e){if(!ji(this.element).bodyProperty)throw Fi("unexpected body text <"+e+">");$i.prototype.handleText.call(this,e)},Ui.prototype.handleEnd=function(){var e=this.body,t=this.element,n=ji(t).bodyProperty;n&&void 0!==e&&(e=si(n.type,e),t.set(n.name,e))},Ui.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=ji(i),o=this.context,a=new i({}),s=this.model;return f(n,(function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?f(e.split(" "),(function(e){o.addReference({element:a,property:i.ns.name,id:e})})):o.addReference({element:a,property:i.ns.name,id:e}):(i?e=si(i.type,e):"xmlns"===n?n=":"+n:(t=ci(n,r.ns.prefix),s.getPackage(t.prefix)&&o.addWarning({message:"unknown attribute <"+n+">",element:a,property:n,value:e})),a.set(n,e))})),a},Ui.prototype.getPropertyForNode=function(e){var t=ci(e.name),n=this.type,i=this.model,r=ji(n),o=t.name,a=r.propertiesByName[o];if(a&&!a.isAttr){const t=function(e){const t=Li(e);return t!==Oi&&(t||null)}(a);if(t){const n=e.attributes[t];if(n){const t=function(e,t,n){const i=ci(e,t.xmlns),r=ci(`${t[i.prefix]||i.prefix}:${i.localName}`);return function(e,t){var n=e.name,i=e.localName,r=t&&t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(r,n.getPackage(r.prefix))}(n,e.ns,i);return E({},a,{effectiveType:ji(i.getType(t)).name})}}return a}var s=i.getPackage(t.prefix);if(s){const e=Ii(t,s),n=i.getType(e);if(a=u(r.properties,(function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)})))return E({},a,{effectiveType:ji(n).name})}else if(a=u(r.properties,(function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type})))return a;throw Fi("unrecognized element <"+t.name+">")},Ui.prototype.toString=function(){return"ElementDescriptor["+ji(this.type).name+"]"},Ui.prototype.valueHandler=function(e,t){return new Hi(e,t)},Ui.prototype.referenceHandler=function(e){return new Gi(e,this.context)},Ui.prototype.handler=function(e){return"Element"===e?new Yi(this.model,e,this.context):new Ui(this.model,e,this.context)},Ui.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,pi(n=t.effectiveType||t.type))return this.valueHandler(t,i);var o=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==o&&(t.isMany?i.get(t.name).push(o):i.set(t.name,o),t.isReference?(E(o,{element:i}),this.context.addReference(o)):o.$parent=i),r},qi.prototype=Object.create(Ui.prototype),qi.prototype.createElement=function(e){var t=e.name,n=ci(t),i=this.model,r=this.type,o=i.getPackage(n.prefix),a=o&&Ii(n,o)||t;if(!r.hasType(a))throw Fi("unexpected element <"+e.originalName+">");return Ui.prototype.createElement.call(this,e)},Yi.prototype=Object.create(Ki.prototype),Yi.prototype.createElement=function(e){var t=e.name,n=ci(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},Yi.prototype.handleChild=function(e){var t=new Yi(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},Yi.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},Xi.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof Ui?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,o=this.lax,a=new Vi(E({},t,{rootHandler:i})),s=new Ti({proxy:!0}),l=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function p(e,t,n){var i=t(),r=i.line,o=i.column,s=i.data;"<"===s.charAt(0)&&-1!==s.indexOf(" ")&&(s=s.slice(0,s.indexOf(" "))+">");var l="unparsable content "+(s?s+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+o+"\n\tnested error: "+e.message;if(n)return a.addWarning({message:l,error:e}),!0;throw Fi(l)}function c(e,t){return p(e,t,!0)}i.context=a,l.push(i);var u=/^<\?xml /i,h=/ encoding="([^"]+)"/i,f=/^utf-8$/i;function m(e,t){try{l.peek().handleText(e)}catch(e){c(e,t)}}var d=r.getPackages().reduce((function(e,t){return e[t.uri]=t.prefix,e}),Object.entries(Bi).reduce((function(e,[t,n]){return e[n]=t,e}),r.config&&r.config.nsMap||{}));return s.ns(d).on("openTag",(function(e,t,n,i){var r=e.attrs||{},a=Object.keys(r).reduce((function(e,n){var i=t(r[n]);return e[n]=i,e}),{});!function(e,t){var n=l.peek();try{l.push(n.handleNode(e))}catch(e){p(e,t,o)&&l.push(new zi)}}({name:e.name,originalName:e.originalName,attributes:a,ns:e.ns},i)})).on("question",(function(e){if(u.test(e)){var t=h.exec(e),n=t&&t[1];n&&!f.test(n)&&a.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}})).on("closeTag",(function(){l.pop().handleEnd()})).on("cdata",m).on("text",(function(e,t,n){!function(e,t){e.trim()&&m(e,t)}(t(e),n)})).on("error",p).on("warn",c),new Promise((function(t,n){var r;try{s.parse(e),function(){var e,t,n=a.elementsById,i=a.references;for(e=0;t=i[e];e++){var r=t.element,o=n[t.id],s=ji(r).propertiesByName[t.property];if(o||a.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),s.isMany){var l=r.get(s.name),p=l.indexOf(t);-1===p&&(p=l.length),o?l[p]=o:l.splice(p,1)}else r.set(s.name,o)}}()}catch(e){r=e}var o=i.element;r||o||(r=Fi("failed to parse document as <"+i.type.$descriptor.name+">"));var l=a.warnings,p=a.references,c=a.elementsById;return r?(r.warnings=l,n(r)):t({rootElement:o,elementsById:c,references:p,warnings:l})}))},Xi.prototype.handler=function(e){return new qi(this.model,e)};var Zi=/<|>|'|"|&|\n\r|\n/g,Ji=/<|>|&/g;function Qi(e){this.prefixMap={},this.uriMap={},this.used={},this.wellknown=[],this.custom=[],this.parent=e,this.defaultPrefixMap=e&&e.defaultPrefixMap||{}}function er(e,t){return Di(t)?(n=e).charAt(0).toLowerCase()+n.slice(1):e;var n}function tr(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function nr(e){return p(e)?e:(e.prefix?e.prefix+":":"")+e.localName}Qi.prototype.mapDefaultPrefixes=function(e){this.defaultPrefixMap=e},Qi.prototype.defaultUriByPrefix=function(e){return this.defaultPrefixMap[e]},Qi.prototype.byUri=function(e){return this.uriMap[e]||this.parent&&this.parent.byUri(e)},Qi.prototype.add=function(e,t){this.uriMap[e.uri]=e,t?this.wellknown.push(e):this.custom.push(e),this.mapPrefix(e.prefix,e.uri)},Qi.prototype.uriByPrefix=function(e){return this.prefixMap[e||"xmlns"]||this.parent&&this.parent.uriByPrefix(e)},Qi.prototype.mapPrefix=function(e,t){this.prefixMap[e||"xmlns"]=t},Qi.prototype.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},Qi.prototype.logUsed=function(e){var t=e.uri,n=this.getNSKey(e);this.used[n]=this.byUri(t),this.parent&&this.parent.logUsed(e)},Qi.prototype.getUsed=function(e){return[].concat(this.wellknown,this.custom).filter((e=>{var t=this.getNSKey(e);return this.used[t]}))};var ir={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},rr={"<":"lt",">":"gt","&":"amp"};function or(e,t,n){return(e=p(e)?e:""+e).replace(t,(function(e){return"&"+n[e]+";"}))}function ar(e){this.tagName=e}function sr(){}function lr(e){this.tagName=e}function pr(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function cr(e,t,n){pr.call(this,e,t),this.serialization=n}function ur(){this.value="",this.write=function(e){this.value+=e}}function hr(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function fr(e){return e=E({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new ur,r=new hr(i,e.format);e.preamble&&r.append('<?xml version="1.0" encoding="UTF-8"?>\n');var o=new pr,a=t.$model;if(o.getNamespaces().mapDefaultPrefixes(function(e){const t=e.config&&e.config.nsMap||{},n={};for(const e in Bi)n[e]=Bi[e];for(const e in t){n[t[e]]=e}for(const t of e.getPackages())n[t.prefix]=t.uri;return n}(a)),o.build(t).serializeTo(r),!n)return i.value}}}function mr(e,t){gi.call(this,e,t)}ar.prototype.build=function(e){return this.element=e,this},ar.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},sr.prototype.serializeValue=sr.prototype.serializeTo=function(e){e.append(this.escape?or(this.value,Ji,rr):this.value)},sr.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(Ji)&&(this.escape=!0),this},tr(lr,sr),lr.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},pr.prototype.build=function(e){this.element=e;var t,n,i=e.$descriptor,r=this.propertyDescriptor,o=i.isGeneric;return t=o?this.parseGenericNsAttributes(e):this.parseNsAttributes(e),this.ns=r?this.nsPropertyTagName(r):this.nsTagName(i),this.tagName=this.addTagName(this.ns),o?this.parseGenericContainments(e):(n=function(e){return h(e.$descriptor.properties,(function(t){var n=t.name;if(t.isVirtual)return!1;if(!c(e,n))return!1;var i=e[n];return i!==t.default&&null!==i&&(!t.isMany||i.length)}))}(e),this.parseAttributes(h(n,(function(e){return e.isAttr}))),this.parseContainments(function(e){return h(e,(function(e){return!e.isAttr}))}(n))),this.parseGenericAttributes(e,t),this},pr.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?E({localName:t.ns.localName},e):E({localName:er(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},pr.prototype.nsPropertyTagName=function(e){return function(e,t){return E({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},pr.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},pr.prototype.nsAttributeName=function(e){var t;if(t=p(e)?ci(e):e.ns,e.inherited)return{localName:t.localName};var n=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(n),this.isLocalNs(n)?{localName:t.localName}:E({localName:t.localName},n)},pr.prototype.parseGenericNsAttributes=function(e){return Object.entries(e).filter((([t,n])=>!t.startsWith("$")&&this.parseNsAttribute(e,t,n))).map((([e,t])=>({name:e,value:t})))},pr.prototype.parseGenericContainments=function(e){var t=e.$body;t&&this.body.push((new sr).build({type:"String"},t));var n=e.$children;n&&f(n,(e=>{this.body.push(new pr(this).build(e))}))},pr.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,o=ci(t);if("xmlns"===o.prefix&&(i={prefix:o.localName,uri:n}),o.prefix||"xmlns"!==o.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var a=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(a)}},pr.prototype.parseNsAttributes=function(e){var t=this,n=e.$attrs,i=[];return f(n,(function(n,r){var o=t.parseNsAttribute(e,r,n);o&&i.push(o)})),i},pr.prototype.parseGenericAttributes=function(e,t){var n=this;f(t,(function(t){try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){"undefined"!=typeof console&&console.warn(`missing namespace information for <${t.name}=${t.value}> on`,e,n)}}))},pr.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;f(e,(function(e){var r=i.get(e.name),o=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new sr).build(e,r[0]));else if(pi(e.type))f(r,(function(i){n.push(new lr(t.addTagName(t.nsPropertyTagName(e))).build(e,i))}));else if(o)f(r,(function(i){n.push(new ar(t.addTagName(t.nsPropertyTagName(e))).build(i))}));else{var a=Li(e);f(r,(function(i){var r;r=a?a===Oi?new pr(t,e):new cr(t,e,a):new pr(t),n.push(r.build(i))}))}}))},pr.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new Qi(t):n=t),n},pr.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,o=e.prefix;return i.byUri(r)&&!n||i.add(e,t),i.mapPrefix(o,r),e},pr.prototype.logNamespaceUsed=function(e,t){var n,i,r,o=this.getNamespaces(t),a=e.prefix,s=e.uri;if(!a&&!s)return{localName:e.localName};if(r=o.defaultUriByPrefix(a),!(s=s||r||o.uriByPrefix(a)))throw new Error("no namespace uri given for prefix <"+a+">");if((e=o.byUri(s))||a||(e=this.logNamespace({uri:s},r===s,!0)),!e){for(n=a,i=1;o.uriByPrefix(n);)n=a+"_"+i++;e=this.logNamespace({prefix:n,uri:s},r===s)}return a&&o.mapPrefix(a,s),e},pr.prototype.parseAttributes=function(e){var t=this,n=this.element;f(e,(function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];f(i,(function(e){r.push(e.id)})),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)}))},pr.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),nr(e)},pr.prototype.addAttribute=function(e,t){var n=this.attrs;p(t)&&(t=or(t,Zi,ir));var i=function(e,t){const n=v(t);let i=o(e)?-1:void 0;return f(e,(function(e,t){if(n(e,t))return i=t,!1})),i}(n,(function(t){return t.name.localName===e.localName&&t.name.uri===e.uri&&t.name.prefix===e.prefix})),r={name:e,value:t};-1!==i?n.splice(i,1,r):n.push(r)},pr.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=function(e){return e.getUsed().filter((function(e){return"xml"!==e.prefix})).map((function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}}))}(n).concat(t)),f(t,(function(t){e.append(" ").append(nr(t.name)).append('="').append(t.value).append('"')}))},pr.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==sr;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),f(this.body,(function(t){t.serializeTo(e)})),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},tr(cr,pr),cr.prototype.parseNsAttributes=function(e){var t=pr.prototype.parseNsAttributes.call(this,e).filter((e=>e.name!==this.serialization)),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),o=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(this.serialization),(i.prefix?i.prefix+":":"")+o+n.ns.localName),t},cr.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},mr.prototype=Object.create(gi.prototype),mr.prototype.fromXML=function(e,t,n){p(t)||(n=t,t="bpmn:Definitions");var i=new Xi(E({model:this,lax:!0},n)),r=i.handler(t);return i.fromXML(e,r)},mr.prototype.toXML=function(e,t){var n=new fr(t);return new Promise((function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}}))};const dr={bpmn:{name:"BPMN20",uri:"http://www.omg.org/spec/BPMN/20100524/MODEL",prefix:"bpmn",associations:[],types:[{name:"Interface",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"operations",type:"Operation",isMany:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"Operation",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"inMessageRef",type:"Message",isReference:!0},{name:"outMessageRef",type:"Message",isReference:!0},{name:"errorRef",type:"Error",isMany:!0,isReference:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"EndPoint",superClass:["RootElement"]},{name:"Auditing",superClass:["BaseElement"]},{name:"GlobalTask",superClass:["CallableElement"],properties:[{name:"resources",type:"ResourceRole",isMany:!0}]},{name:"Monitoring",superClass:["BaseElement"]},{name:"Performer",superClass:["ResourceRole"]},{name:"Process",superClass:["FlowElementsContainer","CallableElement"],properties:[{name:"processType",type:"ProcessType",isAttr:!0},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"properties",type:"Property",isMany:!0},{name:"laneSets",isMany:!0,replaces:"FlowElementsContainer#laneSets",type:"LaneSet"},{name:"flowElements",isMany:!0,replaces:"FlowElementsContainer#flowElements",type:"FlowElement"},{name:"artifacts",type:"Artifact",isMany:!0},{name:"resources",type:"ResourceRole",isMany:!0},{name:"correlationSubscriptions",type:"CorrelationSubscription",isMany:!0},{name:"supports",type:"Process",isMany:!0,isReference:!0},{name:"definitionalCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"isExecutable",isAttr:!0,type:"Boolean"}]},{name:"LaneSet",superClass:["BaseElement"],properties:[{name:"lanes",type:"Lane",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Lane",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"partitionElementRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"partitionElement",type:"BaseElement"},{name:"flowNodeRef",type:"FlowNode",isMany:!0,isReference:!0},{name:"childLaneSet",type:"LaneSet",xml:{serialize:"xsi:type"}}]},{name:"GlobalManualTask",superClass:["GlobalTask"]},{name:"ManualTask",superClass:["Task"]},{name:"UserTask",superClass:["Task"],properties:[{name:"renderings",type:"Rendering",isMany:!0},{name:"implementation",isAttr:!0,type:"String"}]},{name:"Rendering",superClass:["BaseElement"]},{name:"HumanPerformer",superClass:["Performer"]},{name:"PotentialOwner",superClass:["HumanPerformer"]},{name:"GlobalUserTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"renderings",type:"Rendering",isMany:!0}]},{name:"Gateway",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"gatewayDirection",type:"GatewayDirection",default:"Unspecified",isAttr:!0}]},{name:"EventBasedGateway",superClass:["Gateway"],properties:[{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"eventGatewayType",type:"EventBasedGatewayType",isAttr:!0,default:"Exclusive"}]},{name:"ComplexGateway",superClass:["Gateway"],properties:[{name:"activationCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ExclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"InclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ParallelGateway",superClass:["Gateway"]},{name:"RootElement",isAbstract:!0,superClass:["BaseElement"]},{name:"Relationship",superClass:["BaseElement"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"direction",type:"RelationshipDirection",isAttr:!0},{name:"source",isMany:!0,isReference:!0,type:"Element"},{name:"target",isMany:!0,isReference:!0,type:"Element"}]},{name:"BaseElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,type:"String",isId:!0},{name:"documentation",type:"Documentation",isMany:!0},{name:"extensionDefinitions",type:"ExtensionDefinition",isMany:!0,isReference:!0},{name:"extensionElements",type:"ExtensionElements"}]},{name:"Extension",properties:[{name:"mustUnderstand",default:!1,isAttr:!0,type:"Boolean"},{name:"definition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"extensionAttributeDefinitions",type:"ExtensionAttributeDefinition",isMany:!0}]},{name:"ExtensionAttributeDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"type",isAttr:!0,type:"String"},{name:"isReference",default:!1,isAttr:!0,type:"Boolean"},{name:"extensionDefinition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionElements",properties:[{name:"valueRef",isAttr:!0,isReference:!0,type:"Element"},{name:"values",type:"Element",isMany:!0},{name:"extensionAttributeDefinition",type:"ExtensionAttributeDefinition",isAttr:!0,isReference:!0}]},{name:"Documentation",superClass:["BaseElement"],properties:[{name:"text",type:"String",isBody:!0},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Event",isAbstract:!0,superClass:["FlowNode","InteractionNode"],properties:[{name:"properties",type:"Property",isMany:!0}]},{name:"IntermediateCatchEvent",superClass:["CatchEvent"]},{name:"IntermediateThrowEvent",superClass:["ThrowEvent"]},{name:"EndEvent",superClass:["ThrowEvent"]},{name:"StartEvent",superClass:["CatchEvent"],properties:[{name:"isInterrupting",default:!0,isAttr:!0,type:"Boolean"}]},{name:"ThrowEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"inputSet",type:"InputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"CatchEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"parallelMultiple",isAttr:!0,type:"Boolean",default:!1},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"outputSet",type:"OutputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"BoundaryEvent",superClass:["CatchEvent"],properties:[{name:"cancelActivity",default:!0,isAttr:!0,type:"Boolean"},{name:"attachedToRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"EventDefinition",isAbstract:!0,superClass:["RootElement"]},{name:"CancelEventDefinition",superClass:["EventDefinition"]},{name:"ErrorEventDefinition",superClass:["EventDefinition"],properties:[{name:"errorRef",type:"Error",isAttr:!0,isReference:!0}]},{name:"TerminateEventDefinition",superClass:["EventDefinition"]},{name:"EscalationEventDefinition",superClass:["EventDefinition"],properties:[{name:"escalationRef",type:"Escalation",isAttr:!0,isReference:!0}]},{name:"Escalation",properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"escalationCode",isAttr:!0,type:"String"}],superClass:["RootElement"]},{name:"CompensateEventDefinition",superClass:["EventDefinition"],properties:[{name:"waitForCompletion",isAttr:!0,type:"Boolean",default:!0},{name:"activityRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"TimerEventDefinition",superClass:["EventDefinition"],properties:[{name:"timeDate",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeCycle",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeDuration",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"LinkEventDefinition",superClass:["EventDefinition"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"target",type:"LinkEventDefinition",isReference:!0},{name:"source",type:"LinkEventDefinition",isMany:!0,isReference:!0}]},{name:"MessageEventDefinition",superClass:["EventDefinition"],properties:[{name:"messageRef",type:"Message",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"ConditionalEventDefinition",superClass:["EventDefinition"],properties:[{name:"condition",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"SignalEventDefinition",superClass:["EventDefinition"],properties:[{name:"signalRef",type:"Signal",isAttr:!0,isReference:!0}]},{name:"Signal",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ImplicitThrowEvent",superClass:["ThrowEvent"]},{name:"DataState",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ItemAwareElement",superClass:["BaseElement"],properties:[{name:"itemSubjectRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"dataState",type:"DataState"}]},{name:"DataAssociation",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"ItemAwareElement",isMany:!0,isReference:!0},{name:"targetRef",type:"ItemAwareElement",isReference:!0},{name:"transformation",type:"FormalExpression",xml:{serialize:"property"}},{name:"assignment",type:"Assignment",isMany:!0}]},{name:"DataInput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"inputSetRef",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithOptional",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithWhileExecuting",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"DataOutput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"outputSetRef",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithOptional",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithWhileExecuting",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"InputSet",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"dataInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"optionalInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"whileExecutingInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"outputSetRefs",type:"OutputSet",isMany:!0,isReference:!0}]},{name:"OutputSet",superClass:["BaseElement"],properties:[{name:"dataOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"inputSetRefs",type:"InputSet",isMany:!0,isReference:!0},{name:"optionalOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"whileExecutingOutputRefs",type:"DataOutput",isMany:!0,isReference:!0}]},{name:"Property",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"DataInputAssociation",superClass:["DataAssociation"]},{name:"DataOutputAssociation",superClass:["DataAssociation"]},{name:"InputOutputSpecification",superClass:["BaseElement"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"inputSets",type:"InputSet",isMany:!0},{name:"outputSets",type:"OutputSet",isMany:!0}]},{name:"DataObject",superClass:["FlowElement","ItemAwareElement"],properties:[{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"}]},{name:"InputOutputBinding",properties:[{name:"inputDataRef",type:"InputSet",isAttr:!0,isReference:!0},{name:"outputDataRef",type:"OutputSet",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"Assignment",superClass:["BaseElement"],properties:[{name:"from",type:"Expression",xml:{serialize:"xsi:type"}},{name:"to",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"DataStore",superClass:["RootElement","ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"capacity",isAttr:!0,type:"Integer"},{name:"isUnlimited",default:!0,isAttr:!0,type:"Boolean"}]},{name:"DataStoreReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataStoreRef",type:"DataStore",isAttr:!0,isReference:!0}]},{name:"DataObjectReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataObjectRef",type:"DataObject",isAttr:!0,isReference:!0}]},{name:"ConversationLink",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ConversationAssociation",superClass:["BaseElement"],properties:[{name:"innerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0},{name:"outerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0}]},{name:"CallConversation",superClass:["ConversationNode"],properties:[{name:"calledCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"Conversation",superClass:["ConversationNode"]},{name:"SubConversation",superClass:["ConversationNode"],properties:[{name:"conversationNodes",type:"ConversationNode",isMany:!0}]},{name:"ConversationNode",isAbstract:!0,superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"messageFlowRefs",type:"MessageFlow",isMany:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0}]},{name:"GlobalConversation",superClass:["Collaboration"]},{name:"PartnerEntity",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"PartnerRole",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"CorrelationProperty",superClass:["RootElement"],properties:[{name:"correlationPropertyRetrievalExpression",type:"CorrelationPropertyRetrievalExpression",isMany:!0},{name:"name",isAttr:!0,type:"String"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Error",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"errorCode",isAttr:!0,type:"String"}]},{name:"CorrelationKey",superClass:["BaseElement"],properties:[{name:"correlationPropertyRef",type:"CorrelationProperty",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Expression",superClass:["BaseElement"],isAbstract:!1,properties:[{name:"body",isBody:!0,type:"String"}]},{name:"FormalExpression",superClass:["Expression"],properties:[{name:"language",isAttr:!0,type:"String"},{name:"evaluatesToTypeRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Message",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"itemRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"ItemDefinition",superClass:["RootElement"],properties:[{name:"itemKind",type:"ItemKind",isAttr:!0},{name:"structureRef",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"import",type:"Import",isAttr:!0,isReference:!0}]},{name:"FlowElement",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"categoryValueRef",type:"CategoryValue",isMany:!0,isReference:!0}]},{name:"SequenceFlow",superClass:["FlowElement"],properties:[{name:"isImmediate",isAttr:!0,type:"Boolean"},{name:"conditionExpression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"sourceRef",type:"FlowNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"FlowNode",isAttr:!0,isReference:!0}]},{name:"FlowElementsContainer",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"laneSets",type:"LaneSet",isMany:!0},{name:"flowElements",type:"FlowElement",isMany:!0}]},{name:"CallableElement",isAbstract:!0,superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"supportedInterfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"ioBinding",type:"InputOutputBinding",isMany:!0,xml:{serialize:"property"}}]},{name:"FlowNode",isAbstract:!0,superClass:["FlowElement"],properties:[{name:"incoming",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"outgoing",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"lanes",type:"Lane",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"CorrelationPropertyRetrievalExpression",superClass:["BaseElement"],properties:[{name:"messagePath",type:"FormalExpression"},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"CorrelationPropertyBinding",superClass:["BaseElement"],properties:[{name:"dataPath",type:"FormalExpression"},{name:"correlationPropertyRef",type:"CorrelationProperty",isAttr:!0,isReference:!0}]},{name:"Resource",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"resourceParameters",type:"ResourceParameter",isMany:!0}]},{name:"ResourceParameter",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isRequired",isAttr:!0,type:"Boolean"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"CorrelationSubscription",superClass:["BaseElement"],properties:[{name:"correlationKeyRef",type:"CorrelationKey",isAttr:!0,isReference:!0},{name:"correlationPropertyBinding",type:"CorrelationPropertyBinding",isMany:!0}]},{name:"MessageFlow",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"MessageFlowAssociation",superClass:["BaseElement"],properties:[{name:"innerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0},{name:"outerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0}]},{name:"InteractionNode",isAbstract:!0,properties:[{name:"incomingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0},{name:"outgoingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"Participant",superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"interfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"participantMultiplicity",type:"ParticipantMultiplicity"},{name:"endPointRefs",type:"EndPoint",isMany:!0,isReference:!0},{name:"processRef",type:"Process",isAttr:!0,isReference:!0}]},{name:"ParticipantAssociation",superClass:["BaseElement"],properties:[{name:"innerParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"outerParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"ParticipantMultiplicity",properties:[{name:"minimum",default:0,isAttr:!0,type:"Integer"},{name:"maximum",default:1,isAttr:!0,type:"Integer"}],superClass:["BaseElement"]},{name:"Collaboration",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"participants",type:"Participant",isMany:!0},{name:"messageFlows",type:"MessageFlow",isMany:!0},{name:"artifacts",type:"Artifact",isMany:!0},{name:"conversations",type:"ConversationNode",isMany:!0},{name:"conversationAssociations",type:"ConversationAssociation"},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0},{name:"messageFlowAssociations",type:"MessageFlowAssociation",isMany:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"choreographyRef",type:"Choreography",isMany:!0,isReference:!0},{name:"conversationLinks",type:"ConversationLink",isMany:!0}]},{name:"ChoreographyActivity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"loopType",type:"ChoreographyLoopType",default:"None",isAttr:!0}]},{name:"CallChoreography",superClass:["ChoreographyActivity"],properties:[{name:"calledChoreographyRef",type:"Choreography",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"SubChoreography",superClass:["ChoreographyActivity","FlowElementsContainer"],properties:[{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"ChoreographyTask",superClass:["ChoreographyActivity"],properties:[{name:"messageFlowRef",type:"MessageFlow",isMany:!0,isReference:!0}]},{name:"Choreography",superClass:["Collaboration","FlowElementsContainer"]},{name:"GlobalChoreographyTask",superClass:["Choreography"],properties:[{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Group",superClass:["Artifact"],properties:[{name:"categoryValueRef",type:"CategoryValue",isAttr:!0,isReference:!0}]},{name:"Association",superClass:["Artifact"],properties:[{name:"associationDirection",type:"AssociationDirection",isAttr:!0},{name:"sourceRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"targetRef",type:"BaseElement",isAttr:!0,isReference:!0}]},{name:"Category",superClass:["RootElement"],properties:[{name:"categoryValue",type:"CategoryValue",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Artifact",isAbstract:!0,superClass:["BaseElement"]},{name:"CategoryValue",superClass:["BaseElement"],properties:[{name:"categorizedFlowElements",type:"FlowElement",isMany:!0,isVirtual:!0,isReference:!0},{name:"value",isAttr:!0,type:"String"}]},{name:"Activity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"isForCompensation",default:!1,isAttr:!0,type:"Boolean"},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"boundaryEventRefs",type:"BoundaryEvent",isMany:!0,isReference:!0},{name:"properties",type:"Property",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"startQuantity",default:1,isAttr:!0,type:"Integer"},{name:"resources",type:"ResourceRole",isMany:!0},{name:"completionQuantity",default:1,isAttr:!0,type:"Integer"},{name:"loopCharacteristics",type:"LoopCharacteristics"}]},{name:"ServiceTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"SubProcess",superClass:["Activity","FlowElementsContainer","InteractionNode"],properties:[{name:"triggeredByEvent",default:!1,isAttr:!0,type:"Boolean"},{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"LoopCharacteristics",isAbstract:!0,superClass:["BaseElement"]},{name:"MultiInstanceLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"isSequential",default:!1,isAttr:!0,type:"Boolean"},{name:"behavior",type:"MultiInstanceBehavior",default:"All",isAttr:!0},{name:"loopCardinality",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopDataInputRef",type:"ItemAwareElement",isReference:!0},{name:"loopDataOutputRef",type:"ItemAwareElement",isReference:!0},{name:"inputDataItem",type:"DataInput",xml:{serialize:"property"}},{name:"outputDataItem",type:"DataOutput",xml:{serialize:"property"}},{name:"complexBehaviorDefinition",type:"ComplexBehaviorDefinition",isMany:!0},{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"oneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0},{name:"noneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0}]},{name:"StandardLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"testBefore",default:!1,isAttr:!0,type:"Boolean"},{name:"loopCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopMaximum",type:"Integer",isAttr:!0}]},{name:"CallActivity",superClass:["Activity","InteractionNode"],properties:[{name:"calledElement",type:"String",isAttr:!0}]},{name:"Task",superClass:["Activity","InteractionNode"]},{name:"SendTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ReceiveTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ScriptTask",superClass:["Task"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"script",type:"String"}]},{name:"BusinessRuleTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"AdHocSubProcess",superClass:["SubProcess"],properties:[{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"ordering",type:"AdHocOrdering",isAttr:!0},{name:"cancelRemainingInstances",default:!0,isAttr:!0,type:"Boolean"}]},{name:"Transaction",superClass:["SubProcess"],properties:[{name:"protocol",isAttr:!0,type:"String"},{name:"method",isAttr:!0,type:"String"}]},{name:"GlobalScriptTask",superClass:["GlobalTask"],properties:[{name:"scriptLanguage",isAttr:!0,type:"String"},{name:"script",isAttr:!0,type:"String"}]},{name:"GlobalBusinessRuleTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"ComplexBehaviorDefinition",superClass:["BaseElement"],properties:[{name:"condition",type:"FormalExpression"},{name:"event",type:"ImplicitThrowEvent"}]},{name:"ResourceRole",superClass:["BaseElement"],properties:[{name:"resourceRef",type:"Resource",isReference:!0},{name:"resourceParameterBindings",type:"ResourceParameterBinding",isMany:!0},{name:"resourceAssignmentExpression",type:"ResourceAssignmentExpression"},{name:"name",isAttr:!0,type:"String"}]},{name:"ResourceParameterBinding",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"parameterRef",type:"ResourceParameter",isAttr:!0,isReference:!0}],superClass:["BaseElement"]},{name:"ResourceAssignmentExpression",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}}],superClass:["BaseElement"]},{name:"Import",properties:[{name:"importType",isAttr:!0,type:"String"},{name:"location",isAttr:!0,type:"String"},{name:"namespace",isAttr:!0,type:"String"}]},{name:"Definitions",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"targetNamespace",isAttr:!0,type:"String"},{name:"expressionLanguage",default:"http://www.w3.org/1999/XPath",isAttr:!0,type:"String"},{name:"typeLanguage",default:"http://www.w3.org/2001/XMLSchema",isAttr:!0,type:"String"},{name:"imports",type:"Import",isMany:!0},{name:"extensions",type:"Extension",isMany:!0},{name:"rootElements",type:"RootElement",isMany:!0},{name:"diagrams",isMany:!0,type:"bpmndi:BPMNDiagram"},{name:"exporter",isAttr:!0,type:"String"},{name:"relationships",type:"Relationship",isMany:!0},{name:"exporterVersion",isAttr:!0,type:"String"}]}],enumerations:[{name:"ProcessType",literalValues:[{name:"None"},{name:"Public"},{name:"Private"}]},{name:"GatewayDirection",literalValues:[{name:"Unspecified"},{name:"Converging"},{name:"Diverging"},{name:"Mixed"}]},{name:"EventBasedGatewayType",literalValues:[{name:"Parallel"},{name:"Exclusive"}]},{name:"RelationshipDirection",literalValues:[{name:"None"},{name:"Forward"},{name:"Backward"},{name:"Both"}]},{name:"ItemKind",literalValues:[{name:"Physical"},{name:"Information"}]},{name:"ChoreographyLoopType",literalValues:[{name:"None"},{name:"Standard"},{name:"MultiInstanceSequential"},{name:"MultiInstanceParallel"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"MultiInstanceBehavior",literalValues:[{name:"None"},{name:"One"},{name:"All"},{name:"Complex"}]},{name:"AdHocOrdering",literalValues:[{name:"Parallel"},{name:"Sequential"}]}],xml:{tagAlias:"lowerCase",typePrefix:"t"}},bpmndi:{name:"BPMNDI",uri:"http://www.omg.org/spec/BPMN/20100524/DI",prefix:"bpmndi",types:[{name:"BPMNDiagram",properties:[{name:"plane",type:"BPMNPlane",redefines:"di:Diagram#rootElement"},{name:"labelStyle",type:"BPMNLabelStyle",isMany:!0}],superClass:["di:Diagram"]},{name:"BPMNPlane",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"}],superClass:["di:Plane"]},{name:"BPMNShape",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"isHorizontal",isAttr:!0,type:"Boolean"},{name:"isExpanded",isAttr:!0,type:"Boolean"},{name:"isMarkerVisible",isAttr:!0,type:"Boolean"},{name:"label",type:"BPMNLabel"},{name:"isMessageVisible",isAttr:!0,type:"Boolean"},{name:"participantBandKind",type:"ParticipantBandKind",isAttr:!0},{name:"choreographyActivityShape",type:"BPMNShape",isAttr:!0,isReference:!0}],superClass:["di:LabeledShape"]},{name:"BPMNEdge",properties:[{name:"label",type:"BPMNLabel"},{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"sourceElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#source"},{name:"targetElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#target"},{name:"messageVisibleKind",type:"MessageVisibleKind",isAttr:!0,default:"initiating"}],superClass:["di:LabeledEdge"]},{name:"BPMNLabel",properties:[{name:"labelStyle",type:"BPMNLabelStyle",isAttr:!0,isReference:!0,redefines:"di:DiagramElement#style"}],superClass:["di:Label"]},{name:"BPMNLabelStyle",properties:[{name:"font",type:"dc:Font"}],superClass:["di:Style"]}],enumerations:[{name:"ParticipantBandKind",literalValues:[{name:"top_initiating"},{name:"middle_initiating"},{name:"bottom_initiating"},{name:"top_non_initiating"},{name:"middle_non_initiating"},{name:"bottom_non_initiating"}]},{name:"MessageVisibleKind",literalValues:[{name:"initiating"},{name:"non_initiating"}]}],associations:[]},dc:{name:"DC",uri:"http://www.omg.org/spec/DD/20100524/DC",prefix:"dc",types:[{name:"Boolean"},{name:"Integer"},{name:"Real"},{name:"String"},{name:"Font",properties:[{name:"name",type:"String",isAttr:!0},{name:"size",type:"Real",isAttr:!0},{name:"isBold",type:"Boolean",isAttr:!0},{name:"isItalic",type:"Boolean",isAttr:!0},{name:"isUnderline",type:"Boolean",isAttr:!0},{name:"isStrikeThrough",type:"Boolean",isAttr:!0}]},{name:"Point",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0}]},{name:"Bounds",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0},{name:"width",type:"Real",isAttr:!0},{name:"height",type:"Real",isAttr:!0}]}],associations:[]},di:{name:"DI",uri:"http://www.omg.org/spec/DD/20100524/DI",prefix:"di",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"extension",type:"Extension"},{name:"owningDiagram",type:"Diagram",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"owningElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"modelElement",isReadOnly:!0,isVirtual:!0,isReference:!0,type:"Element"},{name:"style",type:"Style",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"ownedElement",type:"DiagramElement",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Node",isAbstract:!0,superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,superClass:["DiagramElement"],properties:[{name:"source",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"target",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"waypoint",isUnique:!1,isMany:!0,type:"dc:Point",xml:{serialize:"xsi:type"}}]},{name:"Diagram",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"rootElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0},{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"},{name:"ownedStyle",type:"Style",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Shape",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Plane",isAbstract:!0,superClass:["Node"],properties:[{name:"planeElement",type:"DiagramElement",subsettedProperty:"DiagramElement-ownedElement",isMany:!0}]},{name:"LabeledEdge",isAbstract:!0,superClass:["Edge"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"LabeledShape",isAbstract:!0,superClass:["Shape"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"Label",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],xml:{tagAlias:"lowerCase"}},bioc:{name:"bpmn.io colors for BPMN",uri:"http://bpmn.io/schema/bpmn/biocolor/1.0",prefix:"bioc",types:[{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]},color:{name:"BPMN in Color",uri:"http://www.omg.org/spec/BPMN/non-normative/color/1.0",prefix:"color",types:[{name:"ColoredLabel",extends:["bpmndi:BPMNLabel"],properties:[{name:"color",isAttr:!0,type:"String"}]},{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"background-color",isAttr:!0,type:"String"},{name:"border-color",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"border-color",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]}};function yr(e,t){return new mr(E({},dr,e),t)}function gr(e,t){return e.$instanceOf(t)}function vr(e){var t={},n=[],i={};function r(e,t){return function(n){e(n,t)}}function o(e){t[e.id]=e}function a(t,n){try{var r=i[t.id]&&function(t,n){if(t.gfx)throw new Error(`already rendered ${gt(t)}`);return e.element(t,i[t.id],n)}(t,n);return o(t),r}catch(e){s(e.message,{element:t,error:e}),console.error(`failed to import ${gt(t)}`,e)}}function s(t,n){e.error(t,n)}var l=this.registerDi=function(e){var t,n=e.bpmnElement;n?i[n.id]?s(`multiple DI elements defined for ${gt(n)}`,{element:n}):(i[n.id]=e,c(t=n,"di")||Object.defineProperty(t,"di",{enumerable:!1,get:function(){throw new Error("Tried to access di from the businessObject. The di is available through the diagram element only. For more information, see https://github.com/bpmn-io/bpmn-js/issues/1472")}})):s(`no bpmnElement referenced in ${gt(e)}`,{element:e})};function p(e){var t;t=e.plane,l(t),f(t.planeElement,m)}function m(e){l(e)}this.handleDefinitions=function(o,a){var c=o.diagrams;if(a&&-1===c.indexOf(a))throw new Error("diagram not part of <bpmn:Definitions />");if(!a&&c&&c.length&&(a=c[0]),!a)throw new Error("no diagram to display");i={},p(a);var m=a.plane;if(!m)throw new Error(`no plane for ${gt(a)}`);var v=m.bpmnElement;if(!v){if(v=function(e){return u(e.rootElements,(function(e){return gr(e,"bpmn:Process")||gr(e,"bpmn:Collaboration")}))}(o),!v)throw new Error("no process or collaboration to display");s(`correcting missing bpmnElement on ${gt(m)} to ${gt(v)}`),m.bpmnElement=v,l(m)}var x,b,w=function(t,n){return e.root(t,i[t.id],n)}(v,m);if(gr(v,"bpmn:Process")||gr(v,"bpmn:SubProcess"))y(v,w);else{if(!gr(v,"bpmn:Collaboration"))throw new Error(`unsupported bpmnElement for ${gt(m)}: ${gt(v)}`);b=w,f((x=v).participants,r(P,b)),E(x.artifacts,b),n.push((function(){!function(e,t){f(e,r(g,t))}(x.messageFlows,b)})),function(e,n){var i=h(e,(function(e){return!t[e.id]&&gr(e,"bpmn:Process")&&e.laneSets}));i.forEach(r(y,n))}(o.rootElements,w)}d(n)};var d=this.handleDeferred=function(){for(;n.length;)n.shift()()};function y(e,t){M(e,t),_(e.ioSpecification,t),E(e.artifacts,t),o(e)}function g(e,t){a(e,t)}function v(e,t){a(e,t)}function x(e,t){a(e,t)}function b(e,t){a(e,t)}function w(e,t){a(e,t)}function E(e,t){f(e,(function(e){gr(e,"bpmn:Association")?n.push((function(){w(e,t)})):w(e,t)}))}function _(e,t){e&&(f(e.dataInputs,r(x,t)),f(e.dataOutputs,r(b,t)))}var A=this.handleSubProcess=function(e,t){M(e,t),E(e.artifacts,t)};function k(e,t){var i=a(e,t);gr(e,"bpmn:SubProcess")&&A(e,i||t),gr(e,"bpmn:Activity")&&_(e.ioSpecification,t),n.push((function(){f(e.dataInputAssociations,r(v,t)),f(e.dataOutputAssociations,r(v,t))}))}function R(e,t){a(e,t)}function S(e,t){n.push((function(){var n=a(e,t);e.childLaneSet&&C(e.childLaneSet,n||t),function(e){f(e.flowNodeRef,(function(t){var n=t.get("lanes");n&&n.push(e)}))}(e)}))}function C(e,t){f(e.lanes,r(S,t))}function M(e,t){!function(e,t){f(e,(function(e){gr(e,"bpmn:SequenceFlow")?n.push((function(){!function(e,t){a(e,t)}(e,t)})):gr(e,"bpmn:BoundaryEvent")?n.unshift((function(){k(e,t)})):gr(e,"bpmn:FlowNode")?k(e,t):gr(e,"bpmn:DataObject")||(gr(e,"bpmn:DataStoreReference")||gr(e,"bpmn:DataObjectReference")?R(e,t):s(`unrecognized flowElement ${gt(e)} in context ${gt(t&&t.businessObject)}`,{element:e,context:t}))}))}(e.flowElements,t),e.laneSets&&function(e,t){f(e,r(C,t))}(e.laneSets,t)}function P(e,t){var n=a(e,t),i=e.processRef;i&&y(i,n||t)}}function xr(e,t,n){var i,r,o,a=[];function s(e,t){var n=new vr({root:function(e,t){return i.add(e,t)},element:function(e,t,n){return i.add(e,t,n)},error:function(e,t){a.push({message:e,context:t})}});t=t||e.diagrams&&e.diagrams[0];var r=function(e,t){if(!t||!t.plane)return;var n,i=t.plane.bpmnElement,r=i;A(i,"bpmn:Process")||A(i,"bpmn:Collaboration")||(r=function(e){var t=e;for(;t;){if(A(t,"bpmn:Process"))return t;t=t.$parent}} class
H A Dbpmn-viewer.production.min.js2 !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).BpmnJS=t()}(this,(function(){"use strict";function e(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}const t=Object.prototype.toString,n=Object.prototype.hasOwnProperty;function i(e){return void 0===e}function r(e){return void 0!==e}function o(e){return"[object Array]"===t.call(e)}function a(e){return"[object Object]"===t.call(e)}function s(e){return"[object Number]"===t.call(e)}function l(e){const n=t.call(e);return"[object Function]"===n||"[object AsyncFunction]"===n||"[object GeneratorFunction]"===n||"[object AsyncGeneratorFunction]"===n||"[object Proxy]"===n}function p(e){return"[object String]"===t.call(e)}function c(e,t){return n.call(e,t)}function u(e,t){const n=v(t);let i;return f(e,(function(e,t){if(n(e,t))return i=e,!1})),i}function h(e,t){const n=v(t);let i=[];return f(e,(function(e,t){n(e,t)&&i.push(e)})),i}function f(e,t){let n,r;if(i(e))return;const a=o(e)?w:x;for(let i in e)if(c(e,i)&&(n=e[i],r=t(n,a(i)),!1===r))return n}function m(e,t,n){return f(e,(function(e,i){n=t(n,e,i)})),n}function d(e,t){return!!m(e,(function(e,n,i){return e&&t(n,i)}),!0)}function y(e,t){return!!u(e,t)}function g(e){return function(t){return d(e,(function(e,n){return t[n]===e}))}}function v(e){return l(e)?e:t=>t===e}function x(e){return e}function w(e){return Number(e)}function b(e,t){return e.bind(t)}function E(e,...t){return Object.assign(e,...t)}function _(e,t){var n=this;t=t||1e3,e.on(["render.shape","render.connection"],t,(function(e,t){var i=e.type,r=t.element,o=t.gfx,a=t.attrs;if(n.canRender(r))return"render.shape"===i?n.drawShape(o,r,a):n.drawConnection(o,r,a)})),e.on(["render.getShapePath","render.getConnectionPath"],t,(function(e,t){if(n.canRender(t))return"render.getShapePath"===e.type?n.getShapePath(t):n.getConnectionPath(t)}))}function A(e,t){var n=R(e);return n&&"function"==typeof n.$instanceOf&&n.$instanceOf(t)}function R(e){return e&&e.businessObject||e}function k(e){return e&&e.di}function S(e,t){return!A(e,"bpmn:CallActivity")&&(A(e,"bpmn:SubProcess")?!(!(t=t||k(e))||!A(t,"bpmndi:BPMNPlane"))||t&&!!t.isExpanded:!A(e,"bpmn:Participant")||!!R(e).processRef)}function C(e){if(A(e,"bpmn:Participant")||A(e,"bpmn:Lane")){var t=k(e).isHorizontal;return void 0===t||t}}_.prototype.canRender=function(e){},_.prototype.drawShape=function(e,t){},_.prototype.drawConnection=function(e,t){},_.prototype.getShapePath=function(e){},_.prototype.getConnectionPath=function(e){};var M={width:90,height:20};function P(e){var t=e.length/2-1,n=e[Math.floor(t)],i=e[Math.ceil(t+.01)],r=function(e){var t=e.length/2-1,n=e[Math.floor(t)],i=e[Math.ceil(t+.01)];return{x:n.x+(i.x-n.x)/2,y:n.y+(i.y-n.y)/2}}(e),o=Math.atan((i.y-n.y)/(i.x-n.x)),a=r.x,s=r.y;return Math.abs(o)<Math.PI/2?s-=15:a+=15,{x:a,y:s}}function N(e,t){var n,i,r,o=e.label;return o&&o.bounds?(r=o.bounds,i={width:Math.max(M.width,r.width),height:r.height},n={x:r.x+r.width/2,y:r.y+r.height/2}):(n=function(e){return e.waypoints?P(e.waypoints):A(e,"bpmn:Group")?{x:e.x+e.width/2,y:e.y+M.height/2}:{x:e.x+e.width/2,y:e.y+e.height+M.height/2}}(t),i=M),E({x:n.x-i.width/2,y:n.y-i.height/2},i)}function T(e){var t=e.businessObject,n=function(e){return A(e,"bpmn:FlowElement")||A(e,"bpmn:Participant")||A(e,"bpmn:Lane")||A(e,"bpmn:SequenceFlow")||A(e,"bpmn:MessageFlow")||A(e,"bpmn:DataInput")||A(e,"bpmn:DataOutput")?"name":A(e,"bpmn:TextAnnotation")?"text":A(e,"bpmn:Group")?"categoryValueRef":void 0}(t);if(n)return"categoryValueRef"===n?function(e){var t=e.categoryValueRef;return t&&t.value||""}(t):t[n]||""}function D(e,t){return function(e,t){t.appendChild(function(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch(e){}return e}(e,t))}(t,e),e}var B={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":2,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":2,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function O(e,t,n){var i=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),r=B[i];r?(2===r&&"number"==typeof n&&(n=String(n)+"px"),e.style[i]=n):e.setAttributeNS(null,t,n)}function L(e,t,n){if("string"==typeof t){if(void 0===n)return function(e,t){return B[t]?e.style[t]:e.getAttributeNS(null,t)}(e,t);O(e,t,n)}else!function(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)O(e,i,t[i])}(e,t);return e}const I=Object.prototype.toString;function F(e){return new j(e)}function j(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}j.prototype.add=function(e){return this.list.add(e),this},j.prototype.remove=function(e){return"[object RegExp]"==I.call(e)?this.removeMatching(e):(this.list.remove(e),this)},j.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},j.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},j.prototype.array=function(){return Array.from(this.list)},j.prototype.has=j.prototype.contains=function(e){return this.list.contains(e)};var V="http://www.w3.org/2000/svg",W='<svg xmlns="'+V+'"';function $(e){var t=!1;"<svg"===e.substring(0,4)?-1===e.indexOf(V)&&(e=W+e.substring(4)):(e=W+">"+e+"</svg>",t=!0);var n=function(e){var t;return(t=new DOMParser).async=!1,t.parseFromString(e,"text/xml")}(e);if(!t)return n;for(var i=document.createDocumentFragment(),r=n.firstChild;r.firstChild;)i.appendChild(r.firstChild);return i}function z(e,t){var n;return"<"===(e=e.trim()).charAt(0)?(n=$(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(V,e),t&&L(n,t),n}var G=null;function H(){return null===G&&(G=z("svg")),G}function K(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)e[i]=t[i];return e}function U(e){return H().createSVGTransform()}var q=/([&<>]{1})/g,Y=/([\n\r"]{1})/g,X={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"'"};function Z(e,t){return e.replace(t,(function(e,t){return X[t]||t}))}function J(e,t){var n,i,r,o,a;switch(e.nodeType){case 3:t.push(Z(e.textContent,q));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(n=0,i=(r=e.attributes).length;n<i;++n)o=r.item(n),t.push(" ",o.name,'="',Z(o.value,Y),'"');if(e.hasChildNodes()){for(t.push(">"),n=0,i=(a=e.childNodes).length;n<i;++n)J(a.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("\x3c!--",Z(e.nodeValue,q),"--\x3e");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function Q(e,t){return function(e){for(var t=e.firstChild,n=[];t;)J(t,n),t=t.nextSibling;return n.join("")}(e)}function ee(e){var t=e.parentNode;return t&&t.removeChild(e),e}function te(e,t){return t instanceof SVGMatrix?e.createSVGTransformFromMatrix(t):t}function ne(e,t){var n=e.transform.baseVal;return t&&(Array.isArray(t)||(t=[t]),function(e,t){var n,i;for(e.clear(),n=0;i=t[n];n++)e.appendItem(te(e,i))}(n,t)),n.consolidate()}function ie(e){return e.flat().join(",").replace(/,?([A-Za-z]),?/g,"$1")}function re(e){return["L",e.x,e.y]}function oe(e,t){const n=e.length,i=[(r=e[0],["M",r.x,r.y])];var r,o,a,s;for(let r=1;r<n;r++){const n=e[r-1],l=e[r],p=e[r+1];if(!p||!t){i.push(re(l));continue}const c=Math.min(t,se(l.x-n.x,l.y-n.y),se(p.x-l.x,p.y-l.y));if(!c){i.push(re(l));continue}const u=ae(l,n,c),h=ae(l,n,.5*c),f=ae(l,p,c),m=ae(l,p,.5*c);i.push(re(u)),i.push((a=m,s=f,["C",(o=h).x,o.y,a.x,a.y,s.x,s.y]))}return i}function ae(e,t,n){const i=t.x-e.x,r=t.y-e.y,o=n/se(i,r);return{x:e.x+i*o,y:e.y+r*o}}function se(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}function le(e,t,n){s(t)&&(n=t,t=null),t||(t={});const i=z("path",t);return s(n)&&(i.dataset.cornerRadius=String(n)),pe(i,e)}function pe(e,t){return L(e,{d:ie(oe(t,parseInt(e.dataset.cornerRadius,10)||0))}),e}var ce="hsl(225, 10%, 15%)";function ue(e,t){return y(e.eventDefinitions,(function(e){return e.$type===t}))}function he(e,t,n){var i=k(e);return n||i.get("color:background-color")||i.get("bioc:fill")||t||"white"}function fe(e,t,n){var i=k(e);return n||i.get("color:border-color")||i.get("bioc:stroke")||t||ce}function me(e,t,n,i){var r=k(e).get("label");return i||r&&r.get("color:color")||t||fe(e,n)}function de(e,t={}){return{width:ye(e,t),height:ge(e,t)}}function ye(e,t={}){return c(t,"width")?t.width:e.width}function ge(e,t={}){return c(t,"height")?t.height:e.height}function ve(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}const xe=Object.prototype.toString,we=Object.prototype.hasOwnProperty;function be(e,t){return we.call(e,t)}function Ee(e,t){let n,i;if(void 0===e)return;const r=function(e){return"[object Array]"===xe.call(e)}(e)?Ae:_e;for(let o in e)if(be(e,o)&&(n=e[o],i=t(n,r(o)),!1===i))return n}function _e(e){return e}function Ae(e){return Number(e)}function Re(e,...t){const n=e.style;return Ee(t,(function(e){e&&Ee(e,(function(e,t){n[t]=e}))})),e}function ke(e,t,n){return 2==arguments.length?e.getAttribute(t):null===n?e.removeAttribute(t):(e.setAttribute(t,n),e)}const Se=Object.prototype.toString;function Ce(e){return new Me(e)}function Me(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}function Pe(e){for(var t;t=e.firstChild;)e.removeChild(t);return e}Me.prototype.add=function(e){return this.list.add(e),this},Me.prototype.remove=function(e){return"[object RegExp]"==Se.call(e)?this.removeMatching(e):(this.list.remove(e),this)},Me.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Me.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Me.prototype.array=function(){return Array.from(this.list)},Me.prototype.has=Me.prototype.contains=function(e){return this.list.contains(e)};var Ne,Te,De,Be={};function Oe(){Ne=window.addEventListener?"addEventListener":"attachEvent",Te=window.removeEventListener?"removeEventListener":"detachEvent",De="addEventListener"!==Ne?"on":""}var Le=ve({__proto__:null,bind:Be.bind=function(e,t,n,i){return Ne||Oe(),e[Ne](De+t,n,i||!1),n},unbind:Be.unbind=function(e,t,n,i){return Te||Oe(),e[Te](De+t,n,i||!1),n},default:Be},[Be]),Ie=["focus","blur"];var Fe,je={bind:function(e,t,n,i,r){return-1!==Ie.indexOf(n)&&(r=!0),Le.bind(e,n,(function(n){var r=n.target||n.srcElement;n.delegateTarget=function(e,t,n){var i=n?e:e.parentNode;return i&&"function"==typeof i.closest&&i.closest(t)||null}(r,t,!0),n.delegateTarget&&i.call(e,n)}),r)},unbind:function(e,t,n,i){return-1!==Ie.indexOf(t)&&(i=!0),Le.unbind(e,t,n,i)}},Ve=function(e,t){if("string"!=typeof e)throw new TypeError("String expected");t||(t=document);var n=/<([\w:]+)/.exec(e);if(!n)return t.createTextNode(e);e=e.replace(/^\s+|\s+$/g,"");var i=n[1];if("body"==i){return(r=t.createElement("html")).innerHTML=e,r.removeChild(r.lastChild)}var r,o=Object.prototype.hasOwnProperty.call($e,i)?$e[i]:$e._default,a=o[0],s=o[1],l=o[2];(r=t.createElement("div")).innerHTML=s+e+l;for(;a--;)r=r.lastChild;if(r.firstChild==r.lastChild)return r.removeChild(r.firstChild);var p=t.createDocumentFragment();for(;r.firstChild;)p.appendChild(r.removeChild(r.firstChild));return p},We=!1;"undefined"!=typeof document&&((Fe=document.createElement("div")).innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',We=!Fe.getElementsByTagName("link").length,Fe=void 0);var $e={legend:[1,"<fieldset>","</fieldset>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],_default:We?[1,"X<div>","</div>"]:[0,"",""]};$e.td=$e.th=[3,"<table><tbody><tr>","</tr></tbody></table>"],$e.option=$e.optgroup=[1,'<select multiple="multiple">',"</select>"],$e.thead=$e.tbody=$e.colgroup=$e.caption=$e.tfoot=[1,"<table>","</table>"],$e.polyline=$e.ellipse=$e.polygon=$e.circle=$e.text=$e.line=$e.path=$e.rect=$e.g=[1,'<svg xmlns="http://www.w3.org/2000/svg" version="1.1">',"</svg>"];var ze=Ve;function Ge(e,t){return(t=t||document).querySelector(e)}function He(e){e.parentNode&&e.parentNode.removeChild(e)}function Ke(e,t,n,i,r){var o=U();o.setTranslate(t,n);var a=U();a.setRotate(i||0,0,0);var s=U();s.setScale(1,1),ne(e,[o,a,s])}function Ue(e,t,n){var i=U();i.setTranslate(t,n),ne(e,i)}var qe=function(e,t){return e(t={exports:{}},t.exports),t.exports}((function(e){var t=e.exports=function(e,n){if(n||(n=16),void 0===e&&(e=128),e<=0)return"0";for(var i=Math.log(Math.pow(2,e))/Math.log(n),r=2;i===1/0;r*=2)i=Math.log(Math.pow(2,e/r))/Math.log(n)*r;var o=i-Math.floor(i),a="";for(r=0;r<Math.floor(i);r++){a=Math.floor(Math.random()*n).toString(n)+a}if(o){var s=Math.pow(n,o);a=Math.floor(Math.random()*s).toString(n)+a}var l=parseInt(a,n);return l!==1/0&&l>=Math.pow(2,e)?t(e,n):a};t.rack=function(e,n,i){var r=function(r){var a=0;do{if(a++>10){if(!i)throw new Error("too many ID collisions, use more bits");e+=i}var s=t(e,n)}while(Object.hasOwnProperty.call(o,s));return o[s]=r,s},o=r.hats={};return r.get=function(e){return r.hats[e]},r.set=function(e,t){return r.hats[e]=t,r},r.bits=e||128,r.base=n||16,r}}));function Ye(e){if(!(this instanceof Ye))return new Ye(e);e=e||[128,36,1],this._seed=e.length?qe.rack(e[0],e[1],e[2]):e}Ye.prototype.next=function(e){return this._seed(e||!0)},Ye.prototype.nextPrefixed=function(e,t){var n;do{n=e+this.next(!0)}while(this.assigned(n));return this.claim(n,t),n},Ye.prototype.claim=function(e,t){this._seed.set(e,t||!0)},Ye.prototype.assigned=function(e){return this._seed.get(e)||!1},Ye.prototype.unclaim=function(e){delete this._seed.hats[e]},Ye.prototype.clear=function(){var e,t=this._seed.hats;for(e in t)this.unclaim(e)};var Xe=new Ye,Ze=.95;function Je(e,t,n,i,r,o,s){_.call(this,t,s);var l=e&&e.defaultFillColor,p=e&&e.defaultStrokeColor,c=e&&e.defaultLabelColor;function u(e){return n.computeStyle(e,{strokeLinecap:"round",strokeLinejoin:"round",stroke:ce,strokeWidth:2,fill:"white"})}function h(e){return n.computeStyle(e,["no-fill"],{strokeLinecap:"round",strokeLinejoin:"round",stroke:ce,strokeWidth:2})}function m(e,t){var{ref:n={x:0,y:0},scale:i=1,element:o,parentGfx:a=r._svg}=t,s=z("marker",{id:e,viewBox:"0 0 20 20",refX:n.x,refY:n.y,markerWidth:20*i,markerHeight:20*i,orient:"auto"});D(s,o);var l=Ge(":scope > defs",a);l||D(a,l=z("defs")),D(l,s)}function d(e,t,n,i){var r=Xe.nextPrefixed("marker-");return function(e,t,n,i,r){if("sequenceflow-end"===n){m(t,{element:z("path",{d:"M 1 5 L 11 10 L 1 15 Z",...u({fill:r,stroke:r,strokeWidth:1})}),ref:{x:11,y:10},scale:.5,parentGfx:e})}if("messageflow-start"===n){m(t,{element:z("circle",{cx:6,cy:6,r:3.5,...u({fill:i,stroke:r,strokeWidth:1,strokeDasharray:[1e4,1]})}),ref:{x:6,y:6},parentGfx:e})}if("messageflow-end"===n){m(t,{element:z("path",{d:"m 1 5 l 0 -3 l 7 3 l -7 3 z",...u({fill:i,stroke:r,strokeWidth:1,strokeDasharray:[1e4,1]})}),ref:{x:8.5,y:5},parentGfx:e})}if("association-start"===n){m(t,{element:z("path",{d:"M 11 5 L 1 10 L 11 15",...h({fill:"none",stroke:r,strokeWidth:1.5,strokeDasharray:[1e4,1]})}),ref:{x:1,y:10},scale:.5,parentGfx:e})}if("association-end"===n){m(t,{element:z("path",{d:"M 1 5 L 11 10 L 1 15",...h({fill:"none",stroke:r,strokeWidth:1.5,strokeDasharray:[1e4,1]})}),ref:{x:11,y:10},scale:.5,parentGfx:e})}if("conditional-flow-marker"===n){m(t,{element:z("path",{d:"M 0 10 L 8 6 L 16 10 L 8 14 Z",...u({fill:i,stroke:r})}),ref:{x:-1,y:10},scale:.5,parentGfx:e})}if("conditional-default-flow-marker"===n){m(t,{element:z("path",{d:"M 6 4 L 10 16",...u({stroke:r,fill:"none"})}),ref:{x:0,y:10},scale:.5,parentGfx:e})}}(e,r,t,n,i),"url(#"+r+")"}function y(e,t,n,i,r={}){a(i)&&(r=i,i=0),i=i||0,r=u(r);var o=z("circle",{cx:t/2,cy:n/2,r:Math.round((t+n)/4-i),...r});return D(e,o),o}function g(e,t,n,i,r,o){a(r)&&(o=r,r=0),r=r||0,o=u(o);var s=z("rect",{x:r,y:r,width:t-2*r,height:n-2*r,rx:i,ry:i,...o});return D(e,s),s}function v(e,t,n,i){var r=le(t,n=h(n),i);return D(e,r),r}function x(e,t,n){return v(e,t,n,5)}function w(e,t,n){n=h(n);var i=z("path",{...n,d:t});return D(e,i),i}function b(e,t,n,i){return w(t,n,E({"data-marker":e},i))}function M(e){return we[e]}function P(e){return function(t,n,i){return M(e)(t,n,i)}}var N=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_MESSAGE",{xScaleFactor:.9,yScaleFactor:.9,containerWidth:t.width,containerHeight:t.height,position:{mx:.235,my:.315}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:r?he(t,l,n.fill):fe(t,p,n.stroke),strokeWidth:1})},B=function(e,t,n={}){var r=y(e,t.width,t.height,.2*t.height,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:2});w(e,i.getScaledPath("EVENT_TIMER_WH",{xScaleFactor:.75,yScaleFactor:.75,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.5}}),{stroke:fe(t,p,n.stroke),strokeWidth:2});for(var o=0;o<12;o++){var a=i.getScaledPath("EVENT_TIMER_LINE",{xScaleFactor:.75,yScaleFactor:.75,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.5}}),s=t.width/2,c=t.height/2;w(e,a,{strokeWidth:1,stroke:fe(t,p,n.stroke),transform:"rotate("+30*o+","+c+","+s+")"})}return r},O=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_ESCALATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.2}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},I=function(e,t,n={}){return w(e,i.getScaledPath("EVENT_CONDITIONAL",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.222}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},j=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_LINK",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.57,my:.263}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},V=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_ERROR",{xScaleFactor:1.1,yScaleFactor:1.1,containerWidth:t.width,containerHeight:t.height,position:{mx:.2,my:.722}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},W=function(e,t,n={},r){var o=w(e,i.getScaledPath("EVENT_CANCEL_45",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.638,my:-.055}}),{fill:r?fe(t,p,n.stroke):"none",stroke:fe(t,p,n.stroke),strokeWidth:1});return function(e,t){var n=U();n.setRotate(t,0,0),ne(e,n)}(o,45),o},$=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_COMPENSATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.22,my:.5}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},G=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_SIGNAL",{xScaleFactor:.9,yScaleFactor:.9,containerWidth:t.width,containerHeight:t.height,position:{mx:.5,my:.2}}),{strokeWidth:1,fill:r?fe(t,p,n.stroke):he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},H=function(e,t,n={},r){return w(e,i.getScaledPath("EVENT_MULTIPLE",{xScaleFactor:1.1,yScaleFactor:1.1,containerWidth:t.width,containerHeight:t.height,position:{mx:.222,my:.36}}),{fill:r?fe(t,p,n.stroke):he(t,l,n.fill),strokeWidth:1})},K=function(e,t,n={}){return w(e,i.getScaledPath("EVENT_PARALLEL_MULTIPLE",{xScaleFactor:1.2,yScaleFactor:1.2,containerWidth:t.width,containerHeight:t.height,position:{mx:.458,my:.194}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1})},q=function(e,t,n={}){return y(e,t.width,t.height,8,{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:4})};function Y(e,t,n={}){var i=R(e),r=function(e){return"bpmn:IntermediateThrowEvent"===e.$type||"bpmn:EndEvent"===e.$type}(i);return i.get("eventDefinitions")&&i.get("eventDefinitions").length>1?i.get("parallelMultiple")?K(t,e,n,r):H(t,e,n,r):ue(i,"bpmn:MessageEventDefinition")?N(t,e,n,r):ue(i,"bpmn:TimerEventDefinition")?B(t,e,n,r):ue(i,"bpmn:ConditionalEventDefinition")?I(t,e,n,r):ue(i,"bpmn:SignalEventDefinition")?G(t,e,n,r):ue(i,"bpmn:EscalationEventDefinition")?O(t,e,n,r):ue(i,"bpmn:LinkEventDefinition")?j(t,e,n,r):ue(i,"bpmn:ErrorEventDefinition")?V(t,e,n,r):ue(i,"bpmn:CancelEventDefinition")?W(t,e,n,r):ue(i,"bpmn:CompensateEventDefinition")?$(t,e,n,r):ue(i,"bpmn:TerminateEventDefinition")?q(t,e,n,r):null}var X={ParticipantMultiplicityMarker:function(e,t,n={}){var r=ye(t,n),o=ge(t,n);b("participant-multiplicity",e,i.getScaledPath("MARKER_PARALLEL",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2-6)/r,my:(o-15)/o}}),{strokeWidth:2,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},SubProcessMarker:function(e,t,n={}){Ue(g(e,14,14,0,{strokeWidth:1,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)}),t.width/2-7.5,t.height-20),b("sub-process",e,i.getScaledPath("MARKER_SUB_PROCESS",{xScaleFactor:1.5,yScaleFactor:1.5,containerWidth:t.width,containerHeight:t.height,position:{mx:(t.width/2-7.5)/t.width,my:(t.height-20)/t.height}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},ParallelMarker:function(e,t,n){var r=ye(t,n),o=ge(t,n);b("parallel",e,i.getScaledPath("MARKER_PARALLEL",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2+n.parallel)/r,my:(o-20)/o}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},SequentialMarker:function(e,t,n){b("sequential",e,i.getScaledPath("MARKER_SEQUENTIAL",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:(t.width/2+n.seq)/t.width,my:(t.height-19)/t.height}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},CompensationMarker:function(e,t,n){b("compensation",e,i.getScaledPath("MARKER_COMPENSATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:(t.width/2+n.compensation)/t.width,my:(t.height-13)/t.height}}),{strokeWidth:1,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})},LoopMarker:function(e,t,n){var r=ye(t,n),o=ge(t,n);b("loop",e,i.getScaledPath("MARKER_LOOP",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2+n.loop)/r,my:(o-7)/o}}),{strokeWidth:1.5,fill:"none",stroke:fe(t,p,n.stroke),strokeMiterlimit:.5})},AdhocMarker:function(e,t,n){var r=ye(t,n),o=ge(t,n);b("adhoc",e,i.getScaledPath("MARKER_ADHOC",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:(r/2+n.adhoc)/r,my:(o-15)/o}}),{strokeWidth:1,fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke)})}};function Z(e,t,n,i){X[e](t,n,i)}function J(e,t,n,i={}){i={fill:i.fill,stroke:i.stroke,width:ye(t,i),height:ge(t,i)};var r=R(t),o=n&&n.includes("SubProcessMarker");i=o?{...i,seq:-21,parallel:-22,compensation:-42,loop:-18,adhoc:10}:{...i,seq:-5,parallel:-6,compensation:-27,loop:0,adhoc:10},f(n,(function(n){Z(n,e,t,i)})),r.get("isForCompensation")&&Z("CompensationMarker",e,t,i),A(r,"bpmn:AdHocSubProcess")&&Z("AdhocMarker",e,t,i);var a=r.get("loopCharacteristics"),s=a&&a.get("isSequential");a&&(void 0===s&&Z("LoopMarker",e,t,i),!1===s&&Z("ParallelMarker",e,t,i),!0===s&&Z("SequentialMarker",e,t,i))}function Q(e,t,n={}){n=E({size:{width:100}},n);var i=o.createText(t||"",n);return F(i).add("djs-label"),D(e,i),i}function ee(e,t,n,i={}){var r=R(t),o=de({x:t.x,y:t.y,width:t.width,height:t.height},i);return Q(e,r.name,{align:n,box:o,padding:7,style:{fill:me(t,c,p,i.stroke)}})}function te(e,t,n,i={}){var r=C(n),o=Q(e,t,{box:{height:30,width:r?ge(n,i):ye(n,i)},align:"center-middle",style:{fill:me(n,c,p,i.stroke)}});r&&Ke(o,0,-(-1*ge(n,i)),270)}function ie(e,t,n={}){var{width:i,height:r}=de(t,n);return g(e,i,r,10,{...n,fill:he(t,l,n.fill),fillOpacity:Ze,stroke:fe(t,p,n.stroke)})}function re(e,t,n={}){var i=R(t),r=he(t,l,n.fill),o=fe(t,p,n.stroke);return"One"!==i.get("associationDirection")&&"Both"!==i.get("associationDirection")||(n.markerEnd=d(e,"association-end",r,o)),"Both"===i.get("associationDirection")&&(n.markerStart=d(e,"association-start",r,o)),n=Qe(n,["markerStart","markerEnd"]),x(e,t.waypoints,{...n,stroke:o,strokeDasharray:"0, 5"})}function oe(e,t,n={}){var r=he(t,l,n.fill),o=fe(t,p,n.stroke),a=w(e,i.getScaledPath("DATA_OBJECT_PATH",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.474,my:.296}}),{fill:r,fillOpacity:Ze,stroke:o});(function(e){var t=e.dataObjectRef;return e.isCollection||t&&t.isCollection})(R(t))&&w(e,i.getScaledPath("DATA_OBJECT_COLLECTION_PATH",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:.33,my:(t.height-18)/t.height}}),{strokeWidth:2,fill:r,stroke:o});return a}function ae(e,t,n={}){return y(e,t.width,t.height,{fillOpacity:Ze,...n,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)})}function se(e,t,n={}){return function(e,t,n,i){var r=t/2,o=n/2,a=[{x:r,y:0},{x:t,y:o},{x:r,y:n},{x:0,y:o}].map((function(e){return e.x+","+e.y})).join(" ");i=u(i);var s=z("polygon",{...i,points:a});return D(e,s),s}(e,t.width,t.height,{fill:he(t,l,n.fill),fillOpacity:Ze,stroke:fe(t,p,n.stroke)})}function pe(e,t,n={}){var i=g(e,ye(t,n),ge(t,n),0,{fill:he(t,l,n.fill),fillOpacity:n.fillOpacity||Ze,stroke:fe(t,p,n.stroke),strokeWidth:1.5}),r=R(t);A(r,"bpmn:Lane")&&te(e,r.get("name"),t,n);return i}function ve(e,t,n={}){var i=ie(e,t,n);(function(e){return e&&!!R(e).triggeredByEvent})(t)&&L(i,{strokeDasharray:"0, 5.5",strokeWidth:2.5});var r=S(t);return ee(e,t,r?"center-top":"center-middle",n),J(e,t,r?void 0:["SubProcessMarker"],n),i}function xe(e,t,n={}){var i=ie(e,t,n);return ee(e,t,"center-middle",n),J(e,t,void 0,n),i}var we=this.handlers={"bpmn:AdHocSubProcess":function(e,t,n={}){return ve(e,t,n=S(t)?Qe(n,["fill","stroke","width","height"]):Qe(n,["fill","stroke"]))},"bpmn:Association":function(e,t,n={}){return re(e,t,n=Qe(n,["fill","stroke"]))},"bpmn:BoundaryEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=Qe(n,["fill","stroke"]);var r=R(t).get("cancelActivity");n={strokeWidth:1.5,fill:he(t,l,n.fill),fillOpacity:1,stroke:fe(t,p,n.stroke)},r||(n.strokeDasharray="6");var o=ae(e,t,n);return y(e,t.width,t.height,3,{...n,fill:"none"}),i&&Y(t,e,n),o},"bpmn:BusinessRuleTask":function(e,t,n={}){var r=xe(e,t,n=Qe(n,["fill","stroke"]));return L(w(e,i.getScaledPath("TASK_TYPE_BUSINESS_RULE_MAIN",{abspos:{x:8,y:8}})),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),L(w(e,i.getScaledPath("TASK_TYPE_BUSINESS_RULE_HEADER",{abspos:{x:8,y:8}})),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:CallActivity":function(e,t,n={}){return n=Qe(n,["fill","stroke"]),ve(e,t,{strokeWidth:5,...n})},"bpmn:ComplexGateway":function(e,t,n={}){var r=se(e,t,n=Qe(n,["fill","stroke"]));return w(e,i.getScaledPath("GATEWAY_COMPLEX",{xScaleFactor:.5,yScaleFactor:.5,containerWidth:t.width,containerHeight:t.height,position:{mx:.46,my:.26}}),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:DataInput":function(e,t,n={}){n=Qe(n,["fill","stroke"]);var r=i.getRawPath("DATA_ARROW"),o=oe(e,t,n);return w(e,r,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1}),o},"bpmn:DataInputAssociation":function(e,t,n={}){return n=Qe(n,["fill","stroke"]),re(e,t,{...n,markerEnd:d(e,"association-end",he(t,l,n.fill),fe(t,p,n.stroke))})},"bpmn:DataObject":function(e,t,n={}){return oe(e,t,n=Qe(n,["fill","stroke"]))},"bpmn:DataObjectReference":P("bpmn:DataObject"),"bpmn:DataOutput":function(e,t,n={}){n=Qe(n,["fill","stroke"]);var r=i.getRawPath("DATA_ARROW"),o=oe(e,t,n);return w(e,r,{strokeWidth:1,fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke)}),o},"bpmn:DataOutputAssociation":function(e,t,n={}){return n=Qe(n,["fill","stroke"]),re(e,t,{...n,markerEnd:d(e,"association-end",he(t,l,n.fill),fe(t,p,n.stroke))})},"bpmn:DataStoreReference":function(e,t,n={}){return n=Qe(n,["fill","stroke"]),w(e,i.getScaledPath("DATA_STORE",{xScaleFactor:1,yScaleFactor:1,containerWidth:t.width,containerHeight:t.height,position:{mx:0,my:.133}}),{fill:he(t,l,n.fill),fillOpacity:Ze,stroke:fe(t,p,n.stroke),strokeWidth:2})},"bpmn:EndEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=Qe(n,["fill","stroke"]);var r=ae(e,t,{...n,strokeWidth:4});return i&&Y(t,e,n),r},"bpmn:EventBasedGateway":function(e,t,n={}){n=Qe(n,["fill","stroke"]);var r=R(t),o=se(e,t,n);y(e,t.width,t.height,.2*t.height,{fill:he(t,"none",n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1});var a=r.get("eventGatewayType"),s=!!r.get("instantiate");if("Parallel"===a){var l=i.getScaledPath("GATEWAY_PARALLEL",{xScaleFactor:.4,yScaleFactor:.4,containerWidth:t.width,containerHeight:t.height,position:{mx:.474,my:.296}});w(e,l,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1})}else"Exclusive"===a&&(s||y(e,t.width,t.height,.26*t.height,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1}),function(){var r=i.getScaledPath("GATEWAY_EVENT_BASED",{xScaleFactor:.18,yScaleFactor:.18,containerWidth:t.width,containerHeight:t.height,position:{mx:.36,my:.44}});w(e,r,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:2})}());return o},"bpmn:ExclusiveGateway":function(e,t,n={}){var r=se(e,t,n=Qe(n,["fill","stroke"])),o=i.getScaledPath("GATEWAY_EXCLUSIVE",{xScaleFactor:.4,yScaleFactor:.4,containerWidth:t.width,containerHeight:t.height,position:{mx:.32,my:.3}});return k(t).get("isMarkerVisible")&&w(e,o,{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:Gateway":function(e,t,n={}){return se(e,t,n=Qe(n,["fill","stroke"]))},"bpmn:Group":function(e,t,n={}){return n=Qe(n,["fill","stroke","width","height"]),g(e,t.width,t.height,10,{stroke:fe(t,p,n.stroke),strokeWidth:1.5,strokeDasharray:"10, 6, 0, 6",fill:"none",pointerEvents:"none",width:ye(t,n),height:ge(t,n)})},"bpmn:InclusiveGateway":function(e,t,n={}){var i=se(e,t,n=Qe(n,["fill","stroke"]));return y(e,t.width,t.height,.24*t.height,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:2.5}),i},"bpmn:IntermediateEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=Qe(n,["fill","stroke"]);var r=ae(e,t,{...n,strokeWidth:1.5});return y(e,t.width,t.height,3,{fill:"none",stroke:fe(t,p,n.stroke),strokeWidth:1.5}),i&&Y(t,e,n),r},"bpmn:IntermediateCatchEvent":P("bpmn:IntermediateEvent"),"bpmn:IntermediateThrowEvent":P("bpmn:IntermediateEvent"),"bpmn:Lane":function(e,t,n={}){return n=Qe(n,["fill","stroke","width","height"]),pe(e,t,{...n,fillOpacity:.25})},"bpmn:ManualTask":function(e,t,n={}){var r=xe(e,t,n=Qe(n,["fill","stroke"]));return w(e,i.getScaledPath("TASK_TYPE_MANUAL",{abspos:{x:17,y:15}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:.5}),r},"bpmn:MessageFlow":function(e,t,n={}){n=Qe(n,["fill","stroke"]);var r=R(t),o=k(t),a=he(t,l,n.fill),s=fe(t,p,n.stroke),c=x(e,t.waypoints,{markerEnd:d(e,"messageflow-end",a,s),markerStart:d(e,"messageflow-start",a,s),stroke:s,strokeDasharray:"10, 11",strokeWidth:1.5});if(r.get("messageRef")){var u=c.getPointAtLength(c.getTotalLength()/2),h=i.getScaledPath("MESSAGE_FLOW_MARKER",{abspos:{x:u.x,y:u.y}}),f={strokeWidth:1};"initiating"===o.get("messageVisibleKind")?(f.fill=a,f.stroke=s):(f.fill=s,f.stroke=a);var m=w(e,h,f),y=Q(e,r.get("messageRef").get("name"),{align:"center-top",fitBox:!0,style:{fill:s}}),g=m.getBBox(),v=y.getBBox();Ke(y,u.x-v.width/2,u.y+g.height/2+10,0)}return c},"bpmn:ParallelGateway":function(e,t,n={}){var r=se(e,t,n=Qe(n,["fill","stroke"]));return w(e,i.getScaledPath("GATEWAY_PARALLEL",{xScaleFactor:.6,yScaleFactor:.6,containerWidth:t.width,containerHeight:t.height,position:{mx:.46,my:.2}}),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:Participant":function(e,t,n={}){var i=pe(e,t,n=Qe(n,["fill","stroke","width","height"])),r=S(t),o=C(t),a=R(t),s=a.get("name");if(r){v(e,o?[{x:30,y:0},{x:30,y:ge(t,n)}]:[{x:0,y:30},{x:ye(t,n),y:30}],{stroke:fe(t,p,n.stroke),strokeWidth:1.5}),te(e,s,t,n)}else{var l=de(t,n);o||(l.height=ye(t,n),l.width=ge(t,n));var u=Q(e,s,{box:l,align:"center-middle",style:{fill:me(t,c,p,n.stroke)}});if(!o)Ke(u,0,-(-1*ge(t,n)),270)}return a.get("participantMultiplicity")&&Z("ParticipantMultiplicityMarker",e,t,n),i},"bpmn:ReceiveTask":function(e,t,n={}){n=Qe(n,["fill","stroke"]);var r,o=R(t),a=xe(e,t,n);return o.get("instantiate")?(y(e,28,28,4.4,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),r=i.getScaledPath("TASK_TYPE_INSTANTIATING_SEND",{abspos:{x:7.77,y:9.52}})):r=i.getScaledPath("TASK_TYPE_SEND",{xScaleFactor:.9,yScaleFactor:.9,containerWidth:21,containerHeight:14,position:{mx:.3,my:.4}}),w(e,r,{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),a},"bpmn:ScriptTask":function(e,t,n={}){var r=xe(e,t,n=Qe(n,["fill","stroke"]));return w(e,i.getScaledPath("TASK_TYPE_SCRIPT",{abspos:{x:15,y:20}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:SendTask":function(e,t,n={}){var r=xe(e,t,n=Qe(n,["fill","stroke"]));return w(e,i.getScaledPath("TASK_TYPE_SEND",{xScaleFactor:1,yScaleFactor:1,containerWidth:21,containerHeight:14,position:{mx:.285,my:.357}}),{fill:fe(t,p,n.stroke),stroke:he(t,l,n.fill),strokeWidth:1}),r},"bpmn:SequenceFlow":function(e,t,n={}){n=Qe(n,["fill","stroke"]);var i=he(t,l,n.fill),r=fe(t,p,n.stroke),o=x(e,t.waypoints,{markerEnd:d(e,"sequenceflow-end",i,r),stroke:r}),a=R(t),{source:s}=t;if(s){var c=R(s);a.get("conditionExpression")&&A(c,"bpmn:Activity")&&L(o,{markerStart:d(e,"conditional-flow-marker",i,r)}),c.get("default")&&(A(c,"bpmn:Gateway")||A(c,"bpmn:Activity"))&&c.get("default")===a&&L(o,{markerStart:d(e,"conditional-default-flow-marker",i,r)})}return o},"bpmn:ServiceTask":function(e,t,n={}){var r=xe(e,t,n=Qe(n,["fill","stroke"]));return y(e,10,10,{fill:he(t,l,n.fill),stroke:"none",transform:"translate(6, 6)"}),w(e,i.getScaledPath("TASK_TYPE_SERVICE",{abspos:{x:12,y:18}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),y(e,10,10,{fill:he(t,l,n.fill),stroke:"none",transform:"translate(11, 10)"}),w(e,i.getScaledPath("TASK_TYPE_SERVICE",{abspos:{x:17,y:22}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:1}),r},"bpmn:StartEvent":function(e,t,n={}){var{renderIcon:i=!0}=n;n=Qe(n,["fill","stroke"]),R(t).get("isInterrupting")||(n={...n,strokeDasharray:"6"});var r=ae(e,t,n);return i&&Y(t,e,n),r},"bpmn:SubProcess":function(e,t,n={}){return ve(e,t,n=S(t)?Qe(n,["fill","stroke","width","height"]):Qe(n,["fill","stroke"]))},"bpmn:Task":function(e,t,n={}){return xe(e,t,n=Qe(n,["fill","stroke"]))},"bpmn:TextAnnotation":function(e,t,n={}){n=Qe(n,["fill","stroke","width","height"]);var{width:r,height:o}=de(t,n),a=g(e,r,o,0,0,{fill:"none",stroke:"none"});return w(e,i.getScaledPath("TEXT_ANNOTATION",{xScaleFactor:1,yScaleFactor:1,containerWidth:r,containerHeight:o,position:{mx:0,my:0}}),{stroke:fe(t,p,n.stroke)}),Q(e,R(t).get("text")||"",{align:"left-top",box:de(t,n),padding:7,style:{fill:me(t,c,p,n.stroke)}}),a},"bpmn:Transaction":function(e,t,i={}){i=S(t)?Qe(i,["fill","stroke","width","height"]):Qe(i,["fill","stroke"]);var r=ve(e,t,{strokeWidth:1.5,...i}),o=n.style(["no-fill","no-events"],{stroke:fe(t,p,i.stroke),strokeWidth:1.5});return S(t)||(i={}),g(e,ye(t,i),ge(t,i),7,3,o),r},"bpmn:UserTask":function(e,t,n={}){var r=xe(e,t,n=Qe(n,["fill","stroke"]));return w(e,i.getScaledPath("TASK_TYPE_USER_1",{abspos:{x:15,y:12}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:.5}),w(e,i.getScaledPath("TASK_TYPE_USER_2",{abspos:{x:15,y:12}}),{fill:he(t,l,n.fill),stroke:fe(t,p,n.stroke),strokeWidth:.5}),w(e,i.getScaledPath("TASK_TYPE_USER_3",{abspos:{x:15,y:12}}),{fill:fe(t,p,n.stroke),stroke:fe(t,p,n.stroke),strokeWidth:.5}),r},label:function(e,t,n={}){return function(e,t,n={}){var i={width:90,height:30,x:t.width/2+t.x,y:t.height/2+t.y};return Q(e,T(t),{box:i,fitBox:!0,style:E({},o.getExternalStyle(),{fill:me(t,c,p,n.stroke)})})}(e,t,n)}};this._drawPath=w,this._renderer=M}function Qe(e,t=[]){return t.reduce(((t,n)=>(e[n]&&(t[n]=e[n]),t)),{})}e(Je,_),Je.$inject=["config.bpmnRenderer","eventBus","styles","pathMap","canvas","textRenderer"],Je.prototype.canRender=function(e){return A(e,"bpmn:BaseElement")},Je.prototype.drawShape=function(e,t,n={}){var{type:i}=t;return this._renderer(i)(e,t,n)},Je.prototype.drawConnection=function(e,t,n={}){var{type:i}=t;return this._renderer(i)(e,t,n)},Je.prototype.getShapePath=function(e){return A(e,"bpmn:Event")?function(e){var t=e.x+e.width/2,n=e.y+e.height/2,i=e.width/2;return ie([["M",t,n],["m",0,-i],["a",i,i,0,1,1,0,2*i],["a",i,i,0,1,1,0,-2*i],["z"]])}(e):A(e,"bpmn:Activity")?function(e,t){var n=e.x,i=e.y,r=e.width,o=e.height;return ie([["M",n+t,i],["l",r-2*t,0],["a",t,t,0,0,1,t,t],["l",0,o-2*t],["a",t,t,0,0,1,-t,t],["l",2*t-r,0],["a",t,t,0,0,1,-t,-t],["l",0,2*t-o],["a",t,t,0,0,1,t,-t],["z"]])}(e,10):A(e,"bpmn:Gateway")?function(e){var t=e.width/2,n=e.height/2;return ie([["M",e.x+t,e.y],["l",t,n],["l",-t,n],["l",-t,-n],["z"]])}(e):function(e){var t=e.x,n=e.y,i=e.width;return ie([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])}(e)};var et={width:150,height:50};function tt(e,t){var n;t.textContent=e;try{var i,r=""===e;return t.textContent=r?"dummy":e,i={width:(n=t.getBBox()).width+2*n.x,height:n.height},r&&(i.width=0),i}catch(e){return console.log(e),{width:0,height:0}}}function nt(e,t,n){for(var i,r=e.shift(),o=r;;){if((i=tt(o,n)).width=o?i.width:0," "===o||""===o||i.width<Math.round(t)||o.length<2)return it(e,o,r,i);o=ot(o,i.width,t)}}function it(e,t,n,i){if(t.length<n.length){var r=n.slice(t.length).trim();e.unshift(r)}return{width:i.width,height:i.height,text:t}}var rt="­";function ot(e,t,n){var i=Math.max(e.length*(n/t),1),r=function(e,t){var n,i=e.split(/(\s|-|\u00AD)/g),r=[],o=0;if(i.length>1)for(;n=i.shift();){if(!(n.length+o<t)){"-"!==n&&n!==rt||r.pop();break}r.push(n),o+=n.length}var a=r[r.length-1];return a&&a===rt&&(r[r.length-1]="-"),r.join("")}(e,i);return r||(r=e.slice(0,Math.max(Math.round(i-1),1))),r}function at(e){this._config=E({},{size:et,padding:0,style:{},align:"center-top"},e||{})}at.prototype.createText=function(e,t){return this.layoutText(e,t).element},at.prototype.getDimensions=function(e,t){return this.layoutText(e,t).dimensions},at.prototype.layoutText=function(e,t){var n=E({},this._config.size,t.box),i=E({},this._config.style,t.style),r=function(e){var t=e.split("-");return{horizontal:t[0]||"center",vertical:t[1]||"top"}}(t.align||this._config.align),o=function(e){return a(e)?E({top:0,left:0,right:0,bottom:0},e):{top:e,left:e,right:e,bottom:e}}(void 0!==t.padding?t.padding:this._config.padding),s=t.fitBox||!1,l=function(e){if("fontSize"in e&&"lineHeight"in e)return e.lineHeight*parseInt(e.fontSize,10)}(i),p=e.split(/\u00AD?\r?\n/),c=[],u=n.width-o.left-o.right,h=z("text");for(L(h,{x:0,y:0}),L(h,i),D(function(){var e=document.getElementById("helper-svg");return e||(L(e=z("svg"),{id:"helper-svg"}),Re(e,{visibility:"hidden",position:"fixed",width:0,height:0}),document.body.appendChild(e)),e}(),h);p.length;)c.push(nt(p,u,h));"middle"===r.vertical&&(o.top=o.bottom=0);var d=m(c,(function(e,t,n){return e+(l||t.height)}),0)+o.top+o.bottom,y=m(c,(function(e,t,n){return t.width>e?t.width:e}),0),g=o.top;"middle"===r.vertical&&(g+=(n.height-d)/2),g-=(l||c[0].height)/4;var v=z("text");return L(v,i),f(c,(function(e){var t;switch(g+=l||e.height,r.horizontal){case"left":t=o.left;break;case"right":t=(s?y:u)-o.right-e.width;break;default:t=Math.max(((s?y:u)-e.width)/2+o.left,0)}var n=z("tspan");L(n,{x:t,y:g}),n.textContent=e.text,D(v,n)})),ee(h),{dimensions:{width:y,height:d},element:v}};function st(e){var t=E({fontFamily:"Arial, sans-serif",fontSize:12,fontWeight:"normal",lineHeight:1.2},e&&e.defaultStyle||{}),n=parseInt(t.fontSize,10)-1,i=E({},t,{fontSize:n},e&&e.externalStyle||{}),r=new at({style:t});this.getExternalLabelBounds=function(e,t){var n=r.getDimensions(t,{box:{width:90,height:30},style:i});return{x:Math.round(e.x+e.width/2-n.width/2),y:Math.round(e.y),width:Math.ceil(n.width),height:Math.ceil(n.height)}},this.getTextAnnotationBounds=function(e,n){var i=r.getDimensions(n,{box:e,style:t,align:"left-top",padding:5});return{x:e.x,y:e.y,width:e.width,height:Math.max(30,Math.round(i.height))}},this.createText=function(e,t){return r.createText(e,t||{})},this.getDefaultStyle=function(){return t},this.getExternalStyle=function(){return i}}st.$inject=["config.textRenderer"];var lt=/\{([^{}]+)\}/g,pt=/(?:(?:^|\.)(.+?)(?=\[|\.|$|\()|\[('|")(.+?)\2\])(\(\))?/g;var ct={__init__:["bpmnRenderer"],bpmnRenderer:["type",Je],textRenderer:["type",st],pathMap:["type",function(){this.pathMap={EVENT_MESSAGE:{d:"m {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}",height:36,width:36,heightElements:[6,14],widthElements:[10.5,21]},EVENT_SIGNAL:{d:"M {mx},{my} l {e.x0},{e.y0} l -{e.x1},0 Z",height:36,width:36,heightElements:[18],widthElements:[10,20]},EVENT_ESCALATION:{d:"M {mx},{my} l {e.x0},{e.y0} l -{e.x0},-{e.y1} l -{e.x0},{e.y1} Z",height:36,width:36,heightElements:[20,7],widthElements:[8]},EVENT_CONDITIONAL:{d:"M {e.x0},{e.y0} l {e.x1},0 l 0,{e.y2} l -{e.x1},0 Z M {e.x2},{e.y3} l {e.x0},0 M {e.x2},{e.y4} l {e.x0},0 M {e.x2},{e.y5} l {e.x0},0 M {e.x2},{e.y6} l {e.x0},0 M {e.x2},{e.y7} l {e.x0},0 M {e.x2},{e.y8} l {e.x0},0 ",height:36,width:36,heightElements:[8.5,14.5,18,11.5,14.5,17.5,20.5,23.5,26.5],widthElements:[10.5,14.5,12.5]},EVENT_LINK:{d:"m {mx},{my} 0,{e.y0} -{e.x1},0 0,{e.y1} {e.x1},0 0,{e.y0} {e.x0},-{e.y2} -{e.x0},-{e.y2} z",height:36,width:36,heightElements:[4.4375,6.75,7.8125],widthElements:[9.84375,13.5]},EVENT_ERROR:{d:"m {mx},{my} {e.x0},-{e.y0} {e.x1},-{e.y1} {e.x2},{e.y2} {e.x3},-{e.y3} -{e.x4},{e.y4} -{e.x5},-{e.y5} z",height:36,width:36,heightElements:[.023,8.737,8.151,16.564,10.591,8.714],widthElements:[.085,6.672,6.97,4.273,5.337,6.636]},EVENT_CANCEL_45:{d:"m {mx},{my} -{e.x1},0 0,{e.x0} {e.x1},0 0,{e.y1} {e.x0},0 0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z",height:36,width:36,heightElements:[4.75,8.5],widthElements:[4.75,8.5]},EVENT_COMPENSATION:{d:"m {mx},{my} {e.x0},-{e.y0} 0,{e.y1} z m {e.x1},-{e.y2} {e.x2},-{e.y3} 0,{e.y1} -{e.x2},-{e.y3} z",height:36,width:36,heightElements:[6.5,13,.4,6.1],widthElements:[9,9.3,8.7]},EVENT_TIMER_WH:{d:"M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ",height:36,width:36,heightElements:[10,2],widthElements:[3,7]},EVENT_TIMER_LINE:{d:"M {mx},{my} m {e.x0},{e.y0} l -{e.x1},{e.y1} ",height:36,width:36,heightElements:[10,3],widthElements:[0,0]},EVENT_MULTIPLE:{d:"m {mx},{my} {e.x1},-{e.y0} {e.x1},{e.y0} -{e.x0},{e.y1} -{e.x2},0 z",height:36,width:36,heightElements:[6.28099,12.56199],widthElements:[3.1405,9.42149,12.56198]},EVENT_PARALLEL_MULTIPLE:{d:"m {mx},{my} {e.x0},0 0,{e.y1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} -{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z",height:36,width:36,heightElements:[2.56228,7.68683],widthElements:[2.56228,7.68683]},GATEWAY_EXCLUSIVE:{d:"m {mx},{my} {e.x0},{e.y0} {e.x1},{e.y0} {e.x2},0 {e.x4},{e.y2} {e.x4},{e.y1} {e.x2},0 {e.x1},{e.y3} {e.x0},{e.y3} {e.x3},0 {e.x5},{e.y1} {e.x5},{e.y2} {e.x3},0 z",height:17.5,width:17.5,heightElements:[8.5,6.5312,-6.5312,-8.5],widthElements:[6.5,-6.5,3,-3,5,-5]},GATEWAY_PARALLEL:{d:"m {mx},{my} 0,{e.y1} -{e.x1},0 0,{e.y0} {e.x1},0 0,{e.y1} {e.x0},0 0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z",height:30,width:30,heightElements:[5,12.5],widthElements:[5,12.5]},GATEWAY_EVENT_BASED:{d:"m {mx},{my} {e.x0},{e.y0} {e.x0},{e.y1} {e.x1},{e.y2} {e.x2},0 z",height:11,width:11,heightElements:[-6,6,12,-12],widthElements:[9,-3,-12]},GATEWAY_COMPLEX:{d:"m {mx},{my} 0,{e.y0} -{e.x0},-{e.y1} -{e.x1},{e.y2} {e.x0},{e.y1} -{e.x2},0 0,{e.y3} {e.x2},0 -{e.x0},{e.y1} l {e.x1},{e.y2} {e.x0},-{e.y1} 0,{e.y0} {e.x3},0 0,-{e.y0} {e.x0},{e.y1} {e.x1},-{e.y2} -{e.x0},-{e.y1} {e.x2},0 0,-{e.y3} -{e.x2},0 {e.x0},-{e.y1} -{e.x1},-{e.y2} -{e.x0},{e.y1} 0,-{e.y0} -{e.x3},0 z",height:17.125,width:17.125,heightElements:[4.875,3.4375,2.125,3],widthElements:[3.4375,2.125,4.875,3]},DATA_OBJECT_PATH:{d:"m 0,0 {e.x1},0 {e.x0},{e.y0} 0,{e.y1} -{e.x2},0 0,-{e.y2} {e.x1},0 0,{e.y0} {e.x0},0",height:61,width:51,heightElements:[10,50,60],widthElements:[10,40,50,60]},DATA_OBJECT_COLLECTION_PATH:{d:"m{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10",height:10,width:10,heightElements:[],widthElements:[]},DATA_ARROW:{d:"m 5,9 9,0 0,-3 5,5 -5,5 0,-3 -9,0 z",height:61,width:51,heightElements:[],widthElements:[]},DATA_STORE:{d:"m {mx},{my} l 0,{e.y2} c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 l 0,-{e.y2} c -{e.x0},-{e.y1} -{e.x1},-{e.y1} -{e.x2},0c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 m -{e.x2},{e.y0}c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0m -{e.x2},{e.y0}c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0",height:61,width:61,heightElements:[7,10,45],widthElements:[2,58,60]},TEXT_ANNOTATION:{d:"m {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0",height:30,width:10,heightElements:[30],widthElements:[10]},MARKER_SUB_PROCESS:{d:"m{mx},{my} m 7,2 l 0,10 m -5,-5 l 10,0",height:10,width:10,heightElements:[],widthElements:[]},MARKER_PARALLEL:{d:"m{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10",height:10,width:10,heightElements:[],widthElements:[]},MARKER_SEQUENTIAL:{d:"m{mx},{my} m 0,3 l 10,0 m -10,3 l 10,0 m -10,3 l 10,0",height:10,width:10,heightElements:[],widthElements:[]},MARKER_COMPENSATION:{d:"m {mx},{my} 7,-5 0,10 z m 7.1,-0.3 6.9,-4.7 0,10 -6.9,-4.7 z",height:10,width:21,heightElements:[],widthElements:[]},MARKER_LOOP:{d:"m {mx},{my} c 3.526979,0 6.386161,-2.829858 6.386161,-6.320661 0,-3.490806 -2.859182,-6.320661 -6.386161,-6.320661 -3.526978,0 -6.38616,2.829855 -6.38616,6.320661 0,1.745402 0.714797,3.325567 1.870463,4.469381 0.577834,0.571908 1.265885,1.034728 2.029916,1.35457 l -0.718163,-3.909793 m 0.718163,3.909793 -3.885211,0.802902",height:13.9,width:13.7,heightElements:[],widthElements:[]},MARKER_ADHOC:{d:"m {mx},{my} m 0.84461,2.64411 c 1.05533,-1.23780996 2.64337,-2.07882 4.29653,-1.97997996 2.05163,0.0805 3.85579,1.15803 5.76082,1.79107 1.06385,0.34139996 2.24454,0.1438 3.18759,-0.43767 0.61743,-0.33642 1.2775,-0.64078 1.7542,-1.17511 0,0.56023 0,1.12046 0,1.6807 -0.98706,0.96237996 -2.29792,1.62393996 -3.6918,1.66181996 -1.24459,0.0927 -2.46671,-0.2491 -3.59505,-0.74812 -1.35789,-0.55965 -2.75133,-1.33436996 -4.27027,-1.18121996 -1.37741,0.14601 -2.41842,1.13685996 -3.44288,1.96782996 z",height:4,width:15,heightElements:[],widthElements:[]},TASK_TYPE_SEND:{d:"m {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}",height:14,width:21,heightElements:[6,14],widthElements:[10.5,21]},TASK_TYPE_SCRIPT:{d:"m {mx},{my} c 9.966553,-6.27276 -8.000926,-7.91932 2.968968,-14.938 l -8.802728,0 c -10.969894,7.01868 6.997585,8.66524 -2.968967,14.938 z m -7,-12 l 5,0 m -4.5,3 l 4.5,0 m -3,3 l 5,0m -4,3 l 5,0",height:15,width:12.6,heightElements:[6,14],widthElements:[10.5,21]},TASK_TYPE_USER_1:{d:"m {mx},{my} c 0.909,-0.845 1.594,-2.049 1.594,-3.385 0,-2.554 -1.805,-4.62199999 -4.357,-4.62199999 -2.55199998,0 -4.28799998,2.06799999 -4.28799998,4.62199999 0,1.348 0.974,2.562 1.89599998,3.405 -0.52899998,0.187 -5.669,2.097 -5.794,4.7560005 v 6.718 h 17 v -6.718 c 0,-2.2980005 -5.5279996,-4.5950005 -6.0509996,-4.7760005 zm -8,6 l 0,5.5 m 11,0 l 0,-5"},TASK_TYPE_USER_2:{d:"m {mx},{my} m 2.162,1.009 c 0,2.4470005 -2.158,4.4310005 -4.821,4.4310005 -2.66499998,0 -4.822,-1.981 -4.822,-4.4310005 "},TASK_TYPE_USER_3:{d:"m {mx},{my} m -6.9,-3.80 c 0,0 2.25099998,-2.358 4.27399998,-1.177 2.024,1.181 4.221,1.537 4.124,0.965 -0.098,-0.57 -0.117,-3.79099999 -4.191,-4.13599999 -3.57499998,0.001 -4.20799998,3.36699999 -4.20699998,4.34799999 z"},TASK_TYPE_MANUAL:{d:"m {mx},{my} c 0.234,-0.01 5.604,0.008 8.029,0.004 0.808,0 1.271,-0.172 1.417,-0.752 0.227,-0.898 -0.334,-1.314 -1.338,-1.316 -2.467,-0.01 -7.886,-0.004 -8.108,-0.004 -0.014,-0.079 0.016,-0.533 0,-0.61 0.195,-0.042 8.507,0.006 9.616,0.002 0.877,-0.007 1.35,-0.438 1.353,-1.208 0.003,-0.768 -0.479,-1.09 -1.35,-1.091 -2.968,-0.002 -9.619,-0.013 -9.619,-0.013 v -0.591 c 0,0 5.052,-0.016 7.225,-0.016 0.888,-0.002 1.354,-0.416 1.351,-1.193 -0.006,-0.761 -0.492,-1.196 -1.361,-1.196 -3.473,-0.005 -10.86,-0.003 -11.0829995,-0.003 -0.022,-0.047 -0.045,-0.094 -0.069,-0.139 0.3939995,-0.319 2.0409995,-1.626 2.4149995,-2.017 0.469,-0.4870005 0.519,-1.1650005 0.162,-1.6040005 -0.414,-0.511 -0.973,-0.5 -1.48,-0.236 -1.4609995,0.764 -6.5999995,3.6430005 -7.7329995,4.2710005 -0.9,0.499 -1.516,1.253 -1.882,2.19 -0.37000002,0.95 -0.17,2.01 -0.166,2.979 0.004,0.718 -0.27300002,1.345 -0.055,2.063 0.629,2.087 2.425,3.312 4.859,3.318 4.6179995,0.014 9.2379995,-0.139 13.8569995,-0.158 0.755,-0.004 1.171,-0.301 1.182,-1.033 0.012,-0.754 -0.423,-0.969 -1.183,-0.973 -1.778,-0.01 -5.824,-0.004 -6.04,-0.004 10e-4,-0.084 0.003,-0.586 10e-4,-0.67 z"},TASK_TYPE_INSTANTIATING_SEND:{d:"m {mx},{my} l 0,8.4 l 12.6,0 l 0,-8.4 z l 6.3,3.6 l 6.3,-3.6"},TASK_TYPE_SERVICE:{d:"m {mx},{my} v -1.71335 c 0.352326,-0.0705 0.703932,-0.17838 1.047628,-0.32133 0.344416,-0.14465 0.665822,-0.32133 0.966377,-0.52145 l 1.19431,1.18005 1.567487,-1.57688 -1.195028,-1.18014 c 0.403376,-0.61394 0.683079,-1.29908 0.825447,-2.01824 l 1.622133,-0.01 v -2.2196 l -1.636514,0.01 c -0.07333,-0.35153 -0.178319,-0.70024 -0.323564,-1.04372 -0.145244,-0.34406 -0.321407,-0.6644 -0.522735,-0.96217 l 1.131035,-1.13631 -1.583305,-1.56293 -1.129598,1.13589 c -0.614052,-0.40108 -1.302883,-0.68093 -2.022633,-0.82247 l 0.0093,-1.61852 h -2.241173 l 0.0042,1.63124 c -0.353763,0.0736 -0.705369,0.17977 -1.049785,0.32371 -0.344415,0.14437 -0.665102,0.32092 -0.9635006,0.52046 l -1.1698628,-1.15823 -1.5667691,1.5792 1.1684265,1.15669 c -0.4026573,0.61283 -0.68308,1.29797 -0.8247287,2.01713 l -1.6588041,0.003 v 2.22174 l 1.6724648,-0.006 c 0.073327,0.35077 0.1797598,0.70243 0.3242851,1.04472 0.1452428,0.34448 0.3214064,0.6644 0.5227339,0.96066 l -1.1993431,1.19723 1.5840256,1.56011 1.1964668,-1.19348 c 0.6140517,0.40346 1.3028827,0.68232 2.0233517,0.82331 l 7.19e-4,1.69892 h 2.226848 z m 0.221462,-3.9957 c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z"},TASK_TYPE_SERVICE_FILL:{d:"m {mx},{my} c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z"},TASK_TYPE_BUSINESS_RULE_HEADER:{d:"m {mx},{my} 0,4 20,0 0,-4 z"},TASK_TYPE_BUSINESS_RULE_MAIN:{d:"m {mx},{my} 0,12 20,0 0,-12 zm 0,8 l 20,0 m -13,-4 l 0,8"},MESSAGE_FLOW_MARKER:{d:"m {mx},{my} m -10.5 ,-7 l 0,14 l 21,0 l 0,-14 z l 10.5,6 l 10.5,-6"}},this.getRawPath=function(e){return this.pathMap[e].d},this.getScaledPath=function(e,t){var n,i,r=this.pathMap[e];t.abspos?(n=t.abspos.x,i=t.abspos.y):(n=t.containerWidth*t.position.mx,i=t.containerHeight*t.position.my);var o={};if(t.position){for(var a=t.containerHeight/r.height*t.yScaleFactor,s=t.containerWidth/r.width*t.xScaleFactor,l=0;l<r.heightElements.length;l++)o["y"+l]=r.heightElements[l]*a;for(var p=0;p<r.widthElements.length;p++)o["x"+p]=r.widthElements[p]*s}var c,u,h=(c=r.d,u={mx:n,my:i,e:o},String(c).replace(lt,(function(e,t){return function(e,t,n){var i=n;return t.replace(pt,(function(e,t,n,r,o){t=t||r,i&&(t in i&&(i=i[t]),"function"==typeof i&&o&&(i=i()))})),i=(null==i||i==n?e:i)+""}(e,t,u)})));return h}}]};var ut={translate:["value",function(e,t){return t=t||{},e.replace(/{([^}]+)}/g,(function(e,n){return t[n]||"{"+n+"}"}))}]};function ht(e){return{top:e.y,right:e.x+(e.width||0),bottom:e.y+(e.height||0),left:e.x}}function ft(e){return t={x:e.x+(e.width||0)/2,y:e.y+(e.height||0)/2},{x:Math.round(t.x),y:Math.round(t.y)};var t}function mt(e){for(var t=e.waypoints,n=t.reduce((function(e,n,i){var r,o,a=t[i-1];if(a){var s=e[e.length-1],l=s&&s.endLength||0,p=(r=a,o=n,Math.sqrt(Math.pow(r.x-o.x,2)+Math.pow(r.y-o.y,2)));e.push({start:a,end:n,startLength:l,endLength:l+p,length:p})}return e}),[]),i=n.reduce((function(e,t){return e+t.length}),0)/2,r=0,o=n[r];o.endLength<i;)o=n[++r];var a=(i-o.startLength)/o.length;return{x:o.start.x+(o.end.x-o.start.x)*a,y:o.start.y+(o.end.y-o.start.y)*a}}function dt(e){return a(t=e)&&c(t,"waypoints")?mt(e):ft(e);var t}function yt(e){return e?"<"+e.$type+(e.id?' id="'+e.id:"")+'" />':"<null>"}function gt(e,t,n){return E({id:e.id,type:e.$type,businessObject:e,di:t},n)}function vt(e,t,n){var i=e.waypoint;return!i||i.length<2?[dt(t),dt(n)]:i.map((function(e){return{x:e.x,y:e.y}}))}function xt(e,t,n){return new Error(`element ${yt(t)} referenced by ${yt(e)}#${n} not yet drawn`)}function wt(e,t,n,i,r){this._eventBus=e,this._canvas=t,this._elementFactory=n,this._elementRegistry=i,this._textRenderer=r}wt.$inject=["eventBus","canvas","elementFactory","elementRegistry","textRenderer"],wt.prototype.add=function(e,t,n){var i,r,o,a,s,l,p;if(A(t,"bpmndi:BPMNPlane")){var c=A(e,"bpmn:SubProcess")?{id:e.id+"_plane"}:{};i=this._elementFactory.createRoot(gt(e,t,c)),this._canvas.addRootElement(i)}else if(A(t,"bpmndi:BPMNShape")){var u=!S(e,t),h=function(e){return A(e,"bpmn:Group")}(e);r=n&&(n.hidden||n.collapsed);var f=t.bounds;i=this._elementFactory.createShape(gt(e,t,{collapsed:u,hidden:r,x:Math.round(f.x),y:Math.round(f.y),width:Math.round(f.width),height:Math.round(f.height),isFrame:h})),A(e,"bpmn:BoundaryEvent")&&this._attachBoundary(e,i),A(e,"bpmn:Lane")&&(o=0),A(e,"bpmn:DataStoreReference")&&(a=n,s=dt(f),l=s.x,p=s.y,l>=a.x&&l<=a.x+a.width&&p>=a.y&&p<=a.y+a.height||(n=this._canvas.findRoot(n))),this._canvas.addShape(i,n,o)}else{if(!A(t,"bpmndi:BPMNEdge"))throw new Error(`unknown di ${yt(t)} for element ${yt(e)}`);var m=this._getSource(e),d=this._getTarget(e);r=n&&(n.hidden||n.collapsed),i=this._elementFactory.createConnection(gt(e,t,{hidden:r,source:m,target:d,waypoints:vt(t,m,d)})),A(e,"bpmn:DataAssociation")&&(n=this._canvas.findRoot(n)),this._canvas.addConnection(i,n,o)}return function(e){return A(e,"bpmn:Event")||A(e,"bpmn:Gateway")||A(e,"bpmn:DataStoreReference")||A(e,"bpmn:DataObjectReference")||A(e,"bpmn:DataInput")||A(e,"bpmn:DataOutput")||A(e,"bpmn:SequenceFlow")||A(e,"bpmn:MessageFlow")||A(e,"bpmn:Group")}(e)&&T(i)&&this.addLabel(e,t,i),this._eventBus.fire("bpmnElement.added",{element:i}),i},wt.prototype._attachBoundary=function(e,t){var n=e.attachedToRef;if(!n)throw new Error(`missing ${yt(e)}#attachedToRef`);var i=this._elementRegistry.get(n.id),r=i&&i.attachers;if(!i)throw xt(e,n,"attachedToRef");t.host=i,r||(i.attachers=r=[]),-1===r.indexOf(t)&&r.push(t)},wt.prototype.addLabel=function(e,t,n){var i,r,o;return i=N(t,n),(r=T(n))&&(i=this._textRenderer.getExternalLabelBounds(i,r)),o=this._elementFactory.createLabel(gt(e,t,{id:e.id+"_label",labelTarget:n,type:"label",hidden:n.hidden||!T(n),x:Math.round(i.x),y:Math.round(i.y),width:Math.round(i.width),height:Math.round(i.height)})),this._canvas.addShape(o,n.parent)},wt.prototype._getConnectedElement=function(e,t){var n,i,r=e.$type;if(i=e[t+"Ref"],"source"===t&&"bpmn:DataInputAssociation"===r&&(i=i&&i[0]),("source"===t&&"bpmn:DataOutputAssociation"===r||"target"===t&&"bpmn:DataInputAssociation"===r)&&(i=e.$parent),n=i&&this._getElement(i))return n;throw i?xt(e,i,t+"Ref"):new Error(`${yt(e)}#${t} Ref not specified`)},wt.prototype._getSource=function(e){return this._getConnectedElement(e,"source")},wt.prototype._getTarget=function(e){return this._getConnectedElement(e,"target")},wt.prototype._getElement=function(e){return this._elementRegistry.get(e.id)};var bt={__depends__:[ct,{__depends__:[ut],bpmnImporter:["type",wt]}]};function Et(e,t){var n,i,r,a;return t=!!t,o(e)||(e=[e]),f(e,(function(e){var o=e;e.waypoints&&!t&&(o=Et(e.waypoints,!0));var s=o.x,l=o.y,p=o.height||0,c=o.width||0;(s<n||void 0===n)&&(n=s),(l<i||void 0===i)&&(i=l),(s+c>r||void 0===r)&&(r=s+c),(l+p>a||void 0===a)&&(a=l+p)})),{x:n,y:i,height:a-i,width:r-n}}function _t(e){return"waypoints"in e?"connection":"x"in e?"shape":"root"}function At(e){return!(!e||!e.isFrame)}function Rt(e){this._counter=0,this._prefix=(e?e+"-":"")+Math.floor(1e9*Math.random())+"-"}Rt.prototype.next=function(){return this._prefix+ ++this._counter};var kt=new Rt("ov");function St(e,t,n,i){var r,o;this._eventBus=t,this._canvas=n,this._elementRegistry=i,this._ids=kt,this._overlayDefaults=E({show:null,scale:!0},e&&e.defaults),this._overlays={},this._overlayContainers=[],this._overlayRoot=(r=n.getContainer(),Re(o=ze('<div class="djs-overlay-container" />'),{position:"absolute",width:0,height:0}),r.insertBefore(o,r.firstChild),o),this._init()}function Ct(e,t,n){Re(e,{left:t+"px",top:n+"px"})}function Mt(e,t){e.style.display=!1===t?"none":""}function Pt(e,t){e.style["transform-origin"]="top left",["","-ms-","-webkit-"].forEach((function(n){e.style[n+"transform"]=t}))}St.$inject=["config.overlays","eventBus","canvas","elementRegistry"],St.prototype.get=function(e){if(p(e)&&(e={id:e}),p(e.element)&&(e.element=this._elementRegistry.get(e.element)),e.element){var t=this._getOverlayContainer(e.element,!0);return t?e.type?h(t.overlays,g({type:e.type})):t.overlays.slice():[]}return e.type?h(this._overlays,g({type:e.type})):e.id?this._overlays[e.id]:null},St.prototype.add=function(e,t,n){if(a(t)&&(n=t,t=null),e.id||(e=this._elementRegistry.get(e)),!n.position)throw new Error("must specifiy overlay position");if(!n.html)throw new Error("must specifiy overlay html");if(!e)throw new Error("invalid element specified");var i=this._ids.next();return n=E({},this._overlayDefaults,n,{id:i,type:t,element:e,html:n.html}),this._addOverlay(n),i},St.prototype.remove=function(e){var t=this.get(e)||[];o(t)||(t=[t]);var n=this;f(t,(function(e){var t=n._getOverlayContainer(e.element,!0);if(e&&(He(e.html),He(e.htmlContainer),delete e.htmlContainer,delete e.element,delete n._overlays[e.id]),t){var i=t.overlays.indexOf(e);-1!==i&&t.overlays.splice(i,1)}}))},St.prototype.isShown=function(){return"none"!==this._overlayRoot.style.display},St.prototype.show=function(){Mt(this._overlayRoot)},St.prototype.hide=function(){Mt(this._overlayRoot,!1)},St.prototype.clear=function(){this._overlays={},this._overlayContainers=[],Pe(this._overlayRoot)},St.prototype._updateOverlayContainer=function(e){var t=e.element,n=e.html,i=t.x,r=t.y;if(t.waypoints){var o=Et(t);i=o.x,r=o.y}Ct(n,i,r),ke(e.html,"data-container-id",t.id)},St.prototype._updateOverlay=function(e){var t,n,i=e.position,r=e.htmlContainer,o=e.element,a=i.left,s=i.top;void 0!==i.right&&(t=o.waypoints?Et(o).width:o.width,a=-1*i.right+t);void 0!==i.bottom&&(n=o.waypoints?Et(o).height:o.height,s=-1*i.bottom+n);Ct(r,a||0,s||0),this._updateOverlayVisibilty(e,this._canvas.viewbox())},St.prototype._createOverlayContainer=function(e){var t=ze('<div class="djs-overlays" />');Re(t,{position:"absolute"}),this._overlayRoot.appendChild(t);var n={html:t,element:e,overlays:[]};return this._updateOverlayContainer(n),this._overlayContainers.push(n),n},St.prototype._updateRoot=function(e){var t=e.scale||1,n="matrix("+[t,0,0,t,-1*e.x*t,-1*e.y*t].join(",")+")";Pt(this._overlayRoot,n)},St.prototype._getOverlayContainer=function(e,t){var n=u(this._overlayContainers,(function(t){return t.element===e}));return n||t?n:this._createOverlayContainer(e)},St.prototype._addOverlay=function(e){var t,n,i=e.id,r=e.element,o=e.html;o.get&&o.constructor.prototype.jquery&&(o=o.get(0)),p(o)&&(o=ze(o)),n=this._getOverlayContainer(r),Re(t=ze('<div class="djs-overlay" data-overlay-id="'+i+'">'),{position:"absolute"}),t.appendChild(o),e.type&&Ce(t).add("djs-overlay-"+e.type),Mt(t,this._canvas.findRoot(r)===this._canvas.getRootElement()),e.htmlContainer=t,n.overlays.push(e),n.html.appendChild(t),this._overlays[i]=e,this._updateOverlay(e),this._updateOverlayVisibilty(e,this._canvas.viewbox())},St.prototype._updateOverlayVisibilty=function(e,t){var n=e.show,i=this._canvas.findRoot(e.element),o=n&&n.minZoom,a=n&&n.maxZoom,s=e.htmlContainer,l=!0;(i!==this._canvas.getRootElement()||n&&(r(o)&&o>t.scale||r(a)&&a<t.scale))&&(l=!1),Mt(s,l),this._updateOverlayScale(e,t)},St.prototype._updateOverlayScale=function(e,t){var n,i,o,a=e.scale,s=e.htmlContainer,l="";!0!==a&&(!1===a?(n=1,i=1):(n=a.min,i=a.max),r(n)&&t.scale<n&&(o=(1/t.scale||1)*n),r(i)&&t.scale>i&&(o=(1/t.scale||1)*i)),r(o)&&(l="scale("+o+","+o+")"),Pt(s,l)},St.prototype._updateOverlaysVisibilty=function(e){var t=this;f(this._overlays,(function(n){t._updateOverlayVisibilty(n,e)}))},St.prototype._init=function(){var e=this._eventBus,t=this;e.on("canvas.viewbox.changing",(function(e){t.hide()})),e.on("canvas.viewbox.changed",(function(e){var n;n=e.viewbox,t._updateRoot(n),t._updateOverlaysVisibilty(n),t.show()})),e.on(["shape.remove","connection.remove"],(function(e){var n=e.element;f(t.get({element:n}),(function(e){t.remove(e.id)}));var i=t._getOverlayContainer(n);if(i){He(i.html);var r=t._overlayContainers.indexOf(i);-1!==r&&t._overlayContainers.splice(r,1)}})),e.on("element.changed",500,(function(e){var n=e.element,i=t._getOverlayContainer(n,!0);i&&(f(i.overlays,(function(e){t._updateOverlay(e)})),t._updateOverlayContainer(i))})),e.on("element.marker.update",(function(e){var n=t._getOverlayContainer(e.element,!0);n&&Ce(n.html)[e.add?"add":"remove"](e.marker)})),e.on("root.set",(function(){t._updateOverlaysVisibilty(t._canvas.viewbox())})),e.on("diagram.clear",this.clear,this)};var Nt={__init__:["overlays"],overlays:["type",St]};function Tt(e,t,n,i){e.on("element.changed",(function(i){var r=i.element;(r.parent||r===t.getRootElement())&&(i.gfx=n.getGraphics(r)),i.gfx&&e.fire(_t(r)+".changed",i)})),e.on("elements.changed",(function(t){var n=t.elements;n.forEach((function(t){e.fire("element.changed",{element:t})})),i.updateContainments(n)})),e.on("shape.changed",(function(e){i.update("shape",e.element,e.gfx)})),e.on("connection.changed",(function(e){i.update("connection",e.element,e.gfx)}))}Tt.$inject=["eventBus","canvas","elementRegistry","graphicsFactory"];var Dt={__init__:["changeSupport"],changeSupport:["type",Tt]};function Bt(e){this._eventBus=e}function Ot(e){return function(t,n,i,r,o){(l(t)||s(t))&&(o=r,r=i,i=n,n=t,t=null),this.on(t,e,n,i,r,o)}}function Lt(e,t){t.invoke(Bt,this),this.executed((function(t){var n=t.context;n.rootElement?e.setRootElement(n.rootElement):n.rootElement=e.getRootElement()})),this.revert((function(t){var n=t.context;n.rootElement&&e.setRootElement(n.rootElement)}))}Bt.$inject=["eventBus"],Bt.prototype.on=function(e,t,n,i,r,p){if((l(t)||s(t))&&(p=r,r=i,i=n,n=t,t=null),l(n)&&(p=r,r=i,i=n,n=1e3),a(r)&&(p=r,r=!1),!l(i))throw new Error("handlerFn must be a function");o(e)||(e=[e]);var c=this._eventBus;f(e,(function(e){var o=["commandStack",e,t].filter((function(e){return e})).join(".");c.on(o,n,r?function(e,t){return function(n){return e.call(t||null,n.context,n.command,n)}}(i,p):i,p)}))},Bt.prototype.canExecute=Ot("canExecute"),Bt.prototype.preExecute=Ot("preExecute"),Bt.prototype.preExecuted=Ot("preExecuted"),Bt.prototype.execute=Ot("execute"),Bt.prototype.executed=Ot("executed"),Bt.prototype.postExecute=Ot("postExecute"),Bt.prototype.postExecuted=Ot("postExecuted"),Bt.prototype.revert=Ot("revert"),Bt.prototype.reverted=Ot("reverted"),e(Lt,Bt),Lt.$inject=["canvas","injector"];var It={__init__:["rootElementsBehavior"],rootElementsBehavior:["type",Lt]},Ft={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};var jt="_plane";function Vt(e){var t=e.id;return A(e,"bpmn:SubProcess")?function(e){return e+jt}(t):t}function Wt(e,t,n){var i=ze('<ul class="bjs-breadcrumbs"></ul>'),r=n.getContainer(),o=Ce(r);r.appendChild(i);var a=[];function s(e){e&&(a=function(e){for(var t=R(e),n=[],i=t;i;i=i.$parent)(A(i,"bpmn:SubProcess")||A(i,"bpmn:Process"))&&n.push(i);return n.reverse()}(e));var r=a.flatMap((function(e){var i=n.findRoot(Vt(e))||n.findRoot(e.id);if(!i&&A(e,"bpmn:Process")){var r=t.find((function(t){var n=R(t);return n&&n.get("processRef")===e}));i=r&&n.findRoot(r.id)}if(!i)return[];var o,a=(o=""+(o=e.name||e.id))&&o.replace(/[&<>"']/g,(function(e){return Ft[e]})),s=ze('<li><span class="bjs-crumb"><a title="'+a+'">'+a+"</a></span></li>");return s.addEventListener("click",(function(){n.setRootElement(i)})),s}));i.innerHTML="";var s=r.length>1;o.toggle("bjs-breadcrumbs-shown",s),r.forEach((function(e){i.appendChild(e)}))}e.on("element.changed",(function(e){var t=R(e.element);u(a,(function(e){return e===t}))&&s()})),e.on("root.set",(function(e){s(e.element)}))}function $t(e,t){var n=null,i=new zt;e.on("root.set",(function(e){var r=e.element,o=t.viewbox(),a=i.get(r);if(i.set(n,{x:o.x,y:o.y,zoom:o.scale}),n=r,A(r,"bpmn:SubProcess")||a){a=a||{x:0,y:0,zoom:1};var s=(o.x-a.x)*o.scale,l=(o.y-a.y)*o.scale;0===s&&0===l||t.scroll({dx:s,dy:l}),a.zoom!==o.scale&&t.zoom(a.zoom,{x:0,y:0})}})),e.on("diagram.clear",(function(){i.clear(),n=null}))}function zt(){this._entries=[],this.set=function(e,t){var n=!1;for(var i in this._entries)if(this._entries[i][0]===e){this._entries[i][1]=t,n=!0;break}n||this._entries.push([e,t])},this.get=function(e){for(var t in this._entries)if(this._entries[t][0]===e)return this._entries[t][1];return null},this.clear=function(){this._entries.length=0},this.remove=function(e){var t=-1;for(var n in this._entries)if(this._entries[n][0]===e){t=n;break}-1!==t&&this._entries.splice(t,1)}}Wt.$inject=["eventBus","elementRegistry","canvas"],$t.$inject=["eventBus","canvas"];var Gt=180,Ht=160;function Kt(e,t){this._eventBus=e,this._moddle=t;var n=this;e.on("import.render.start",1500,(function(e,t){n._handleImport(t.definitions)}))}function Ut(e){return A(e,"bpmndi:BPMNDiagram")?e:Ut(e.$parent)}Kt.prototype._handleImport=function(e){if(e.diagrams){var t=this;this._definitions=e,this._processToDiagramMap={},e.diagrams.forEach((function(e){e.plane&&e.plane.bpmnElement&&(t._processToDiagramMap[e.plane.bpmnElement.id]=e)})),e.diagrams.filter((e=>e.plane)).flatMap((e=>t._createNewDiagrams(e.plane))).forEach((function(e){t._movePlaneElementsToOrigin(e.plane)}))}},Kt.prototype._createNewDiagrams=function(e){var t=this,n=[],i=[];e.get("planeElement").forEach((function(t){var r=t.bpmnElement;if(r){var o=r.$parent;A(r,"bpmn:SubProcess")&&!t.isExpanded&&n.push(r),function(e,t){var n=e.$parent;if(!A(n,"bpmn:SubProcess")||n===t.bpmnElement)return!1;if(function(e,t){return y(t,(function(t){return A(e,t)}))}(e,["bpmn:DataInputAssociation","bpmn:DataOutputAssociation"]))return!1;return!0}(r,e)&&i.push({diElement:t,parent:o})}}));var r=[];return n.forEach((function(e){if(!t._processToDiagramMap[e.id]){var n=t._createDiagram(e);t._processToDiagramMap[e.id]=n,r.push(n)}})),i.forEach((function(e){for(var i=e.diElement,r=e.parent;r&&-1===n.indexOf(r);)r=r.$parent;if(r){var o=t._processToDiagramMap[r.id];t._moveToDiPlane(i,o.plane)}})),r},Kt.prototype._movePlaneElementsToOrigin=function(e){var t=e.get("planeElement"),n=function(e){var t={top:1/0,right:-1/0,bottom:-1/0,left:1/0};return e.planeElement.forEach((function(e){if(e.bounds){var n=ht(e.bounds);t.top=Math.min(n.top,t.top),t.left=Math.min(n.left,t.left)}})),function(e){return{x:e.left,y:e.top,width:e.right-e.left,height:e.bottom-e.top}}(t)}(e),i=n.x-Gt,r=n.y-Ht;t.forEach((function(e){e.waypoint?e.waypoint.forEach((function(e){e.x=e.x-i,e.y=e.y-r})):e.bounds&&(e.bounds.x=e.bounds.x-i,e.bounds.y=e.bounds.y-r)}))},Kt.prototype._moveToDiPlane=function(e,t){var n=Ut(e).plane.get("planeElement");n.splice(n.indexOf(e),1),t.get("planeElement").push(e)},Kt.prototype._createDiagram=function(e){var t=this._moddle.create("bpmndi:BPMNPlane",{bpmnElement:e}),n=this._moddle.create("bpmndi:BPMNDiagram",{plane:t});return t.$parent=n,t.bpmnElement=e,n.$parent=this._definitions,this._definitions.diagrams.push(n),n},Kt.$inject=["eventBus","moddle"];var qt=250;function Yt(e,t,n,i,r){Bt.call(this,t),this._canvas=e,this._eventBus=t,this._elementRegistry=n,this._overlays=i,this._translate=r;var o=this;this.executed("shape.toggleCollapse",qt,(function(e){var t=e.shape;o._canDrillDown(t)?o._addOverlay(t):o._removeOverlay(t)}),!0),this.reverted("shape.toggleCollapse",qt,(function(e){var t=e.shape;o._canDrillDown(t)?o._addOverlay(t):o._removeOverlay(t)}),!0),this.executed(["shape.create","shape.move","shape.delete"],qt,(function(e){var t=e.oldParent,n=e.newParent||e.parent,i=e.shape;o._canDrillDown(i)&&o._addOverlay(i),o._updateDrilldownOverlay(t),o._updateDrilldownOverlay(n),o._updateDrilldownOverlay(i)}),!0),this.reverted(["shape.create","shape.move","shape.delete"],qt,(function(e){var t=e.oldParent,n=e.newParent||e.parent,i=e.shape;o._canDrillDown(i)&&o._addOverlay(i),o._updateDrilldownOverlay(t),o._updateDrilldownOverlay(n),o._updateDrilldownOverlay(i)}),!0),t.on("import.render.complete",(function(){n.filter((function(e){return o._canDrillDown(e)})).map((function(e){o._addOverlay(e)}))}))}e(Yt,Bt),Yt.prototype._updateDrilldownOverlay=function(e){var t=this._canvas;if(e){var n=t.findRoot(e);n&&this._updateOverlayVisibility(n)}},Yt.prototype._canDrillDown=function(e){var t=this._canvas;return A(e,"bpmn:SubProcess")&&t.findRoot(Vt(e))},Yt.prototype._updateOverlayVisibility=function(e){var t=this._overlays,n=R(e),i=t.get({element:n.id,type:"drilldown"})[0];if(i){var r=n&&n.get("flowElements")&&n.get("flowElements").length;Ce(i.html).toggle("bjs-drilldown-empty",!r)}},Yt.prototype._addOverlay=function(e){var t=this._canvas,n=this._overlays,i=R(e);n.get({element:e,type:"drilldown"}).length&&this._removeOverlay(e);var r=ze('<button type="button" class="bjs-drilldown"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M4.81801948,3.50735931 L10.4996894,9.1896894 L10.5,4 L12,4 L12,12 L4,12 L4,10.5 L9.6896894,10.4996894 L3.75735931,4.56801948 C3.46446609,4.27512627 3.46446609,3.80025253 3.75735931,3.50735931 C4.05025253,3.21446609 4.52512627,3.21446609 4.81801948,3.50735931 Z"/></svg></button>'),o=i.get("name")||i.get("id"),a=this._translate("Open {element}",{element:o});r.setAttribute("title",a),r.addEventListener("click",(function(){t.setRootElement(t.findRoot(Vt(e)))})),n.add(e,"drilldown",{position:{bottom:-7,right:-8},html:r}),this._updateOverlayVisibility(e)},Yt.prototype._removeOverlay=function(e){this._overlays.remove({element:e,type:"drilldown"})},Yt.$inject=["canvas","eventBus","elementRegistry","overlays","translate"];var Xt={__depends__:[Nt,Dt,It],__init__:["drilldownBreadcrumbs","drilldownOverlayBehavior","drilldownCentering","subprocessCompatibility"],drilldownBreadcrumbs:["type",Wt],drilldownCentering:["type",$t],drilldownOverlayBehavior:["type",Yt],subprocessCompatibility:["type",Kt]};function Zt(e){return e.originalEvent||e.srcEvent}function Jt(e,t){return(Zt(e)||e).button===t}function Qt(e){return Jt(e,0)}function en(e){return!0}function tn(e){return Qt(e)||function(e){return Jt(e,1)}(e)}function nn(e,t,n){var i=this;function r(n,i,r){var o,a;(function(e,t){var n=l[e]||Qt;return!n(t)})(n,i)||(r?a=t.getGraphics(r):(o=i.delegateTarget||i.target)&&(a=o,r=t.get(a)),a&&r&&!1===e.fire(n,{element:r,gfx:a,originalEvent:i})&&(i.stopPropagation(),i.preventDefault()))}var o={};function a(e){return o[e]}var s={click:"element.click",contextmenu:"element.contextmenu",dblclick:"element.dblclick",mousedown:"element.mousedown",mousemove:"element.mousemove",mouseover:"element.hover",mouseout:"element.out",mouseup:"element.mouseup"},l={"element.contextmenu":en,"element.mousedown":tn,"element.mouseup":tn,"element.click":tn,"element.dblclick":tn};function p(e,t,n,i){var a=o[n]=function(e){r(n,e)};i&&(l[n]=i),a.$delegate=je.bind(e,"svg, .djs-element",t,a)}function c(e,t,n){var i=a(n);i&&je.unbind(e,t,i.$delegate)}e.on("canvas.destroy",(function(e){var t;t=e.svg,f(s,(function(e,n){c(t,n,e)}))})),e.on("canvas.init",(function(e){var t;t=e.svg,f(s,(function(e,n){p(t,n,e)}))})),e.on(["shape.added","connection.added"],(function(t){var n=t.element,i=t.gfx;e.fire("interactionEvents.createHit",{element:n,gfx:i})})),e.on(["shape.changed","connection.changed"],500,(function(t){var n=t.element,i=t.gfx;e.fire("interactionEvents.updateHit",{element:n,gfx:i})})),e.on("interactionEvents.createHit",500,(function(e){var t=e.element,n=e.gfx;i.createDefaultHit(t,n)})),e.on("interactionEvents.updateHit",(function(e){var t=e.element,n=e.gfx;i.updateDefaultHit(t,n)}));var u=d("djs-hit djs-hit-stroke"),h=d("djs-hit djs-hit-click-stroke"),m={all:d("djs-hit djs-hit-all"),"click-stroke":h,stroke:u,"no-move":d("djs-hit djs-hit-no-move")};function d(e,t){return t=E({stroke:"white",strokeWidth:15},t||{}),n.cls(e,["no-fill","no-border"],t)}function y(e,t){var n=m[t];if(!n)throw new Error("invalid hit type <"+t+">");return L(e,n),e}function g(e,t){D(e,t)}this.removeHits=function(e){var t;f((t=".djs-hit",(e||document).querySelectorAll(t)),ee)},this.createDefaultHit=function(e,t){var n,i=e.waypoints,r=e.isFrame;return i?this.createWaypointsHit(t,i):(n=r?"stroke":"all",this.createBoxHit(t,n,{width:e.width,height:e.height}))},this.createWaypointsHit=function(e,t){var n=le(t);return y(n,"stroke"),g(e,n),n},this.createBoxHit=function(e,t,n){n=E({x:0,y:0},n);var i=z("rect");return y(i,t),L(i,n),g(e,i),i},this.updateDefaultHit=function(e,t){var n=Ge(".djs-hit",t);if(n)return e.waypoints?pe(n,e.waypoints):L(n,{width:e.width,height:e.height}),n},this.fire=r,this.triggerMouseEvent=function(e,t,n){var i=s[e];if(!i)throw new Error("unmapped DOM event name <"+e+">");return r(i,t,n)},this.mouseHandler=a,this.registerEvent=p,this.unregisterEvent=c}nn.$inject=["eventBus","elementRegistry","styles"];var rn={__init__:["interactionEvents"],interactionEvents:["type",nn]};function on(e,t){this._eventBus=e,this._canvas=t,this._selectedElements=[];var n=this;e.on(["shape.remove","connection.remove"],(function(e){var t=e.element;n.deselect(t)})),e.on(["diagram.clear","root.set"],(function(e){n.select(null)}))}on.$inject=["eventBus","canvas"],on.prototype.deselect=function(e){var t=this._selectedElements,n=t.indexOf(e);if(-1!==n){var i=t.slice();t.splice(n,1),this._eventBus.fire("selection.changed",{oldSelection:i,newSelection:t})}},on.prototype.get=function(){return this._selectedElements},on.prototype.isSelected=function(e){return-1!==this._selectedElements.indexOf(e)},on.prototype.select=function(e,t){var n=this._selectedElements,i=n.slice();o(e)||(e=e?[e]:[]);var r=this._canvas,a=r.getRootElement();e=e.filter((function(e){var t=r.findRoot(e);return a===t})),t?f(e,(function(e){-1===n.indexOf(e)&&n.push(e)})):this._selectedElements=n=e.slice(),this._eventBus.fire("selection.changed",{oldSelection:i,newSelection:n})};var an="hover",sn="selected";function ln(e,t){function n(t,n){e.addMarker(t,n)}function i(t,n){e.removeMarker(t,n)}this._canvas=e,t.on("element.hover",(function(e){n(e.element,an)})),t.on("element.out",(function(e){i(e.element,an)})),t.on("selection.changed",(function(e){var t=e.oldSelection,r=e.newSelection;f(t,(function(e){-1===r.indexOf(e)&&i(e,sn)})),f(r,(function(e){-1===t.indexOf(e)&&n(e,sn)}))}))}function pn(e,t,n,i){e.on("create.end",500,(function(e){var n=e.context,i=n.canExecute,r=n.elements,a=(n.hints||{}).autoSelect;if(i){if(!1===a)return;o(a)?t.select(a):t.select(r.filter(cn))}})),e.on("connect.end",500,(function(e){var n=e.context.connection;n&&t.select(n)})),e.on("shape.move.end",500,(function(e){var n=e.previousSelection||[],r=i.get(e.context.shape.id);u(n,(function(e){return r.id===e.id}))||t.select(r)})),e.on("element.click",(function(e){if(Qt(e)){var i=e.element;i===n.getRootElement()&&(i=null);var r=t.isSelected(i),o=t.get().length>1,a=function(e){var t=Zt(e)||e;return Qt(e)&&t.shiftKey}(e);if(r&&o)return a?t.deselect(i):t.select(i);r?t.deselect(i):t.select(i,a)}}))}function cn(e){return!e.hidden}ln.$inject=["canvas","eventBus"],pn.$inject=["eventBus","selection","canvas","elementRegistry"];var un={__init__:["selectionVisuals","selectionBehavior"],__depends__:[rn],selection:["type",on],selectionVisuals:["type",ln],selectionBehavior:["type",pn]};const hn=/^class[ {]/;function fn(e){return Array.isArray(e)}function mn(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function dn(...e){1===e.length&&fn(e[0])&&(e=e[0]);const t=(e=[...e]).pop();return t.$inject=e,t}const yn=/constructor\s*[^(]*\(\s*([^)]*)\)/m,gn=/^(?:async\s+)?(?:function\s*[^(]*)?(?:\(\s*([^)]*)\)|(\w+))/m,vn=/\/\*([^*]*)\*\//m;function xn(e){if("function"!=typeof e)throw new Error(`Cannot annotate "${e}". Expected a function!`);const t=e.toString().match(function(e){return hn.test(e.toString())}(e)?yn:gn);if(!t)return[];const n=t[1]||t[2];return n&&n.split(",").map((e=>{const t=e.match(vn);return(t&&t[1]||e).trim()}))||[]}function wn(e,t){const n=t||{get:function(e,t){if(i.push(e),!1===t)return null;throw s(`No provider for "${e}"!`)}},i=[],r=this._providers=Object.create(n._providers||null),o=this._instances=Object.create(null),a=o.injector=this,s=function(e){const t=i.join(" -> ");return i.length=0,new Error(t?`${e} (Resolving: ${t})`:e)};function l(e,t){if(!r[e]&&e.includes(".")){const t=e.split(".");let n=l(t.shift());for(;t.length;)n=n[t.shift()];return n}if(mn(o,e))return o[e];if(mn(r,e)){if(-1!==i.indexOf(e))throw i.push(e),s("Cannot resolve circular dependency!");return i.push(e),o[e]=r[e][0](r[e][1]),i.pop(),o[e]}return n.get(e,t)}function p(e,t){if(void 0===t&&(t={}),"function"!=typeof e){if(!fn(e))throw s(`Cannot invoke "${e}". Expected a function!`);e=dn(e.slice())}return{fn:e,dependencies:(e.$inject||xn(e)).map((e=>mn(t,e)?t[e]:l(e)))}}function c(e){const{fn:t,dependencies:n}=p(e);return new(Function.prototype.bind.call(t,null,...n))}function u(e,t,n){const{fn:i,dependencies:r}=p(e,n);return i.apply(t,r)}function h(e){return dn((t=>e.get(t)))}function f(e,t){if(t&&t.length){const n=Object.create(null),i=Object.create(null),o=[],a=[],s=[];let l,p,c,u;for(let e in r)l=r[e],-1!==t.indexOf(e)&&("private"===l[2]?(p=o.indexOf(l[3]),-1===p?(c=l[3].createChild([],t),u=h(c),o.push(l[3]),a.push(c),s.push(u),n[e]=[u,e,"private",c]):n[e]=[s[p],e,"private",a[p]]):n[e]=[l[2],l[1]],i[e]=!0),"factory"!==l[2]&&"type"!==l[2]||!l[1].$scope||t.forEach((t=>{-1!==l[1].$scope.indexOf(t)&&(n[e]=[l[2],l[1]],i[t]=!0)}));t.forEach((e=>{if(!i[e])throw new Error('No provider for "'+e+'". Cannot use provider from the parent!')})),e.unshift(n)}return new wn(e,a)}const m={factory:u,type:c,value:function(e){return e}};function d(e,t){const n=e.__init__||[];return function(){n.forEach((e=>{"string"==typeof e?t.get(e):t.invoke(e)}))}}function y(e){const t=e.__exports__;if(t){const n=e.__modules__,i=Object.keys(e).reduce(((t,n)=>("__exports__"!==n&&"__modules__"!==n&&"__init__"!==n&&"__depends__"!==n&&(t[n]=e[n]),t)),Object.create(null)),o=f((n||[]).concat(i)),a=dn((function(e){return o.get(e)}));t.forEach((function(e){r[e]=[a,e,"private",o]}));const s=(e.__init__||[]).slice();return s.unshift((function(){o.init()})),d(e=Object.assign({},e,{__init__:s}),o)}return Object.keys(e).forEach((function(t){if("__init__"===t||"__depends__"===t)return;const n=e[t];if("private"===n[2])return void(r[t]=n);const i=n[0],o=n[1];r[t]=[m[i],bn(i,o),i]})),d(e,a)}function g(e,t){return-1!==e.indexOf(t)||-1!==(e=(t.__depends__||[]).reduce(g,e)).indexOf(t)?e:e.concat(t)}this.get=l,this.invoke=u,this.instantiate=c,this.createChild=f,this.init=function(e){const t=e.reduce(g,[]).map(y);let n=!1;return function(){n||(n=!0,t.forEach((e=>e())))}}(e)}function bn(e,t){return"value"!==e&&fn(t)&&(t=dn(t.slice())),t}function En(e,t){_.call(this,e,1),this.CONNECTION_STYLE=t.style(["no-fill"],{strokeWidth:5,stroke:"fuchsia"}),this.SHAPE_STYLE=t.style({fill:"white",stroke:"fuchsia",strokeWidth:2}),this.FRAME_STYLE=t.style(["no-fill"],{stroke:"fuchsia",strokeDasharray:4,strokeWidth:2})}e(En,_),En.prototype.canRender=function(){return!0},En.prototype.drawShape=function(e,t,n){var i=z("rect");return L(i,{x:0,y:0,width:t.width||0,height:t.height||0}),At(t)?L(i,E({},this.FRAME_STYLE,n||{})):L(i,E({},this.SHAPE_STYLE,n||{})),D(e,i),i},En.prototype.drawConnection=function(e,t,n){var i=le(t.waypoints,E({},this.CONNECTION_STYLE,n||{}));return D(e,i),i},En.prototype.getShapePath=function(e){var t=e.x,n=e.y,i=e.width;return ie([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])},En.prototype.getConnectionPath=function(e){var t,n,i=e.waypoints,r=[];for(t=0;n=i[t];t++)n=n.original||n,r.push([0===t?"M":"L",n.x,n.y]);return ie(r)},En.$inject=["eventBus","styles"];var _n={__init__:["defaultRenderer"],defaultRenderer:["type",En],styles:["type",function(){var e={"no-fill":{fill:"none"},"no-border":{strokeOpacity:0},"no-events":{pointerEvents:"none"}},t=this;this.cls=function(e,t,n){return E(this.style(t,n),{class:e})},this.style=function(t,n){o(t)||n||(n=t,t=[]);var i=m(t,(function(t,n){return E(t,e[n]||{})}),{});return n?E(i,n):i},this.computeStyle=function(e,n,i){return o(n)||(i=n,n=[]),t.style(n||[],E({},i,e||{}))}}]};function An(e,t){return Math.round(e*t)/t}function Rn(e){return s(e)?e+"px":e}function kn(e,t,n){const i=z("g");F(i).add(t);const r=void 0!==n?n:e.childNodes.length-1;return e.insertBefore(i,e.childNodes[r]||null),i}const Sn={shape:["x","y","width","height"],connection:["waypoints"]};function Cn(e,t,n,i){this._eventBus=t,this._elementRegistry=i,this._graphicsFactory=n,this._rootsIdx=0,this._layers={},this._planes=[],this._rootElement=null,this._focused=!1,this._init(e||{})}function Mn(e,t){const n="matrix("+t.a+","+t.b+","+t.c+","+t.d+","+t.e+","+t.f+")";e.setAttribute("transform",n)}Cn.$inject=["config.canvas","eventBus","graphicsFactory","elementRegistry"],Cn.prototype._init=function(e){const t=this._eventBus,n=this._container=function(e){const t=(e=E({},{width:"100%",height:"100%"},e)).container||document.body,n=document.createElement("div");return n.setAttribute("class","djs-container djs-parent"),Re(n,{position:"relative",overflow:"hidden",width:Rn(e.width),height:Rn(e.height)}),t.appendChild(n),n}(e),i=this._svg=z("svg");L(i,{width:"100%",height:"100%"}),ke(i,"tabindex",0),e.autoFocus&&t.on("element.hover",(()=>{this.restoreFocus()})),t.on("element.mousedown",500,(e=>{this.focus()})),i.addEventListener("focusin",(()=>{this._setFocused(!0)})),i.addEventListener("focusout",(()=>{this._setFocused(!1)})),D(n,i);const r=this._viewport=kn(i,"viewport");e.deferUpdate&&(this._viewboxChanged=function(e,t){let n,i,r,o;function a(n){let a=Date.now(),p=n?0:o+t-a;if(p>0)return s(p);e.apply(r,i),l()}function s(e){n=setTimeout(a,e)}function l(){n&&clearTimeout(n),n=o=i=r=void 0}function p(...e){o=Date.now(),i=e,r=this,n||s(t)}return p.flush=function(){n&&a(!0),l()},p.cancel=l,p}(b(this._viewboxChanged,this),300)),t.on("diagram.init",(()=>{t.fire("canvas.init",{svg:i,viewport:r})})),t.on(["shape.added","connection.added","shape.removed","connection.removed","elements.changed","root.set"],(()=>{delete this._cachedViewbox})),t.on("diagram.destroy",500,this._destroy,this),t.on("diagram.clear",500,this._clear,this)},Cn.prototype._destroy=function(){this._eventBus.fire("canvas.destroy",{svg:this._svg,viewport:this._viewport});const e=this._container.parentNode;e&&e.removeChild(this._container),delete this._svg,delete this._container,delete this._layers,delete this._planes,delete this._rootElement,delete this._viewport},Cn.prototype._setFocused=function(e){e!=this._focused&&(this._focused=e,this._eventBus.fire("canvas.focus.changed",{focused:e}))},Cn.prototype._clear=function(){this._elementRegistry.getAll().forEach((e=>{const t=_t(e);"root"===t?this.removeRootElement(e):this._removeElement(e,t)})),this._planes=[],this._rootElement=null,delete this._cachedViewbox},Cn.prototype.focus=function(){this._svg.focus({preventScroll:!0}),this._setFocused(!0)},Cn.prototype.restoreFocus=function(){document.activeElement===document.body&&this.focus()},Cn.prototype.isFocused=function(){return this._focused},Cn.prototype.getDefaultLayer=function(){return this.getLayer("base",0)},Cn.prototype.getLayer=function(e,t){if(!e)throw new Error("must specify a name");let n=this._layers[e];if(n||(n=this._layers[e]=this._createLayer(e,t)),void 0!==t&&n.index!==t)throw new Error("layer <"+e+"> already created at index <"+t+">");return n.group},Cn.prototype._getChildIndex=function(e){return m(this._layers,(function(t,n){return n.visible&&e>=n.index&&t++,t}),0)},Cn.prototype._createLayer=function(e,t){void 0===t&&(t=1);const n=this._getChildIndex(t);return{group:kn(this._viewport,"layer-"+e,n),index:t,visible:!0}},Cn.prototype.showLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=this._viewport,i=t.group,r=t.index;if(t.visible)return i;const o=this._getChildIndex(r);return n.insertBefore(i,n.childNodes[o]||null),t.visible=!0,i},Cn.prototype.hideLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=t.group;return t.visible?(ee(n),t.visible=!1,n):n},Cn.prototype._removeLayer=function(e){const t=this._layers[e];t&&(delete this._layers[e],ee(t.group))},Cn.prototype.getActiveLayer=function(){const e=this._findPlaneForRoot(this.getRootElement());return e?e.layer:null},Cn.prototype.findRoot=function(e){if("string"==typeof e&&(e=this._elementRegistry.get(e)),!e)return;const t=this._findPlaneForRoot(function(e){for(;e.parent;)e=e.parent;return e}(e))||{};return t.rootElement},Cn.prototype.getRootElements=function(){return this._planes.map((function(e){return e.rootElement}))},Cn.prototype._findPlaneForRoot=function(e){return u(this._planes,(function(t){return t.rootElement===e}))},Cn.prototype.getContainer=function(){return this._container},Cn.prototype._updateMarker=function(e,t,n){let i;e.id||(e=this._elementRegistry.get(e)),e.markers=e.markers||new Set,i=this._elementRegistry._elements[e.id],i&&(f([i.gfx,i.secondaryGfx],(function(i){i&&(n?(e.markers.add(t),F(i).add(t)):(e.markers.delete(t),F(i).remove(t)))})),this._eventBus.fire("element.marker.update",{element:e,gfx:i.gfx,marker:t,add:!!n}))},Cn.prototype.addMarker=function(e,t){this._updateMarker(e,t,!0)},Cn.prototype.removeMarker=function(e,t){this._updateMarker(e,t,!1)},Cn.prototype.hasMarker=function(e,t){return e.id||(e=this._elementRegistry.get(e)),!!e.markers&&e.markers.has(t)},Cn.prototype.toggleMarker=function(e,t){this.hasMarker(e,t)?this.removeMarker(e,t):this.addMarker(e,t)},Cn.prototype.getRootElement=function(){const e=this._rootElement;return e||this._planes.length?e:this.setRootElement(this.addRootElement(null))},Cn.prototype.addRootElement=function(e){const t=this._rootsIdx++;e||(e={id:"__implicitroot_"+t,children:[],isImplicit:!0});const n=e.layer="root-"+t;this._ensureValid("root",e);const i=this.getLayer(n,0);return this.hideLayer(n),this._addRoot(e,i),this._planes.push({rootElement:e,layer:i}),e},Cn.prototype.removeRootElement=function(e){"string"==typeof e&&(e=this._elementRegistry.get(e));if(this._findPlaneForRoot(e))return this._removeRoot(e),this._removeLayer(e.layer),this._planes=this._planes.filter((function(t){return t.rootElement!==e})),this._rootElement===e&&(this._rootElement=null),e},Cn.prototype.setRootElement=function(e){if(e===this._rootElement)return e;let t;if(!e)throw new Error("rootElement required");return t=this._findPlaneForRoot(e),t||(e=this.addRootElement(e)),this._setRoot(e),e},Cn.prototype._removeRoot=function(e){const t=this._elementRegistry,n=this._eventBus;n.fire("root.remove",{element:e}),n.fire("root.removed",{element:e}),t.remove(e)},Cn.prototype._addRoot=function(e,t){const n=this._elementRegistry,i=this._eventBus;i.fire("root.add",{element:e}),n.add(e,t),i.fire("root.added",{element:e,gfx:t})},Cn.prototype._setRoot=function(e,t){const n=this._rootElement;n&&(this._elementRegistry.updateGraphics(n,null,!0),this.hideLayer(n.layer)),e&&(t||(t=this._findPlaneForRoot(e).layer),this._elementRegistry.updateGraphics(e,this._svg,!0),this.showLayer(e.layer)),this._rootElement=e,this._eventBus.fire("root.set",{element:e})},Cn.prototype._ensureValid=function(e,t){if(!t.id)throw new Error("element must have an id");if(this._elementRegistry.get(t.id))throw new Error("element <"+t.id+"> already exists");const n=Sn[e],i=d(n,(function(e){return void 0!==t[e]}));if(!i)throw new Error("must supply { "+n.join(", ")+" } with "+e)},Cn.prototype._setParent=function(e,t,n){!function(e,t,n){if(e&&t){"number"!=typeof n&&(n=-1);var i=e.indexOf(t);if(-1!==i){if(i===n)return;if(-1===n)return;e.splice(i,1)}-1!==n?e.splice(n,0,t):e.push(t)}}(t.children,e,n),e.parent=t},Cn.prototype._addElement=function(e,t,n,i){n=n||this.getRootElement();const r=this._eventBus,o=this._graphicsFactory;this._ensureValid(e,t),r.fire(e+".add",{element:t,parent:n}),this._setParent(t,n,i);const a=o.create(e,t,i);return this._elementRegistry.add(t,a),o.update(e,t,a),r.fire(e+".added",{element:t,gfx:a}),t},Cn.prototype.addShape=function(e,t,n){return this._addElement("shape",e,t,n)},Cn.prototype.addConnection=function(e,t,n){return this._addElement("connection",e,t,n)},Cn.prototype._removeElement=function(e,t){const n=this._elementRegistry,i=this._graphicsFactory,r=this._eventBus;if(e=n.get(e.id||e))return r.fire(t+".remove",{element:e}),i.remove(e),function(e,t){if(!e||!t)return-1;var n=e.indexOf(t);-1!==n&&e.splice(n,1)}(e.parent&&e.parent.children,e),e.parent=null,r.fire(t+".removed",{element:e}),n.remove(e),e},Cn.prototype.removeShape=function(e){return this._removeElement(e,"shape")},Cn.prototype.removeConnection=function(e){return this._removeElement(e,"connection")},Cn.prototype.getGraphics=function(e,t){return this._elementRegistry.getGraphics(e,t)},Cn.prototype._changeViewbox=function(e){this._eventBus.fire("canvas.viewbox.changing"),e.apply(this),this._cachedViewbox=null,this._viewboxChanged()},Cn.prototype._viewboxChanged=function(){this._eventBus.fire("canvas.viewbox.changed",{viewbox:this.viewbox()})},Cn.prototype.viewbox=function(e){if(void 0===e&&this._cachedViewbox)return structuredClone(this._cachedViewbox);const t=this._viewport,n=this.getSize();let i,r,o,a,s,l,p;return e?(this._changeViewbox((function(){s=Math.min(n.width/e.width,n.height/e.height);const i=this._svg.createSVGMatrix().scale(s).translate(-e.x,-e.y);ne(t,i)})),e):(o=this._rootElement?this.getActiveLayer():null,i=o&&o.getBBox()||{},a=ne(t),r=a?a.matrix:function(e,t,n,i,r,o){var a=H().createSVGMatrix();switch(arguments.length){case 0:return a;case 1:return K(a,e);case 6:return K(a,{a:e,b:t,c:n,d:i,e:r,f:o})}}(),s=An(r.a,1e3),l=An(-r.e||0,1e3),p=An(-r.f||0,1e3),e=this._cachedViewbox={x:l?l/s:0,y:p?p/s:0,width:n.width/s,height:n.height/s,scale:s,inner:{width:i.width||0,height:i.height||0,x:i.x||0,y:i.y||0},outer:n})},Cn.prototype.scroll=function(e){const t=this._viewport;let n=t.getCTM();return e&&this._changeViewbox((function(){e=E({dx:0,dy:0},e||{}),n=this._svg.createSVGMatrix().translate(e.dx,e.dy).multiply(n),Mn(t,n)})),{x:n.e,y:n.f}},Cn.prototype.scrollToElement=function(e,t){let n=100;"string"==typeof e&&(e=this._elementRegistry.get(e));const i=this.findRoot(e);if(i!==this.getRootElement()&&this.setRootElement(i),i===e)return;t||(t={}),"number"==typeof t&&(n=t),t={top:t.top||n,right:t.right||n,bottom:t.bottom||n,left:t.left||n};const r=Et(e),o=ht(r),a=this.viewbox(),s=this.zoom();let l,p;a.y+=t.top/s,a.x+=t.left/s,a.width-=(t.right+t.left)/s,a.height-=(t.bottom+t.top)/s;const c=ht(a);if(r.width<a.width&&r.height<a.height){const e=Math.max(0,o.right-c.right),t=Math.min(0,o.left-c.left),n=Math.max(0,o.bottom-c.bottom),i=Math.min(0,o.top-c.top);l=e||t,p=n||i}else l=r.x-a.x,p=r.y-a.y;this.scroll({dx:-l*s,dy:-p*s})},Cn.prototype.zoom=function(e,t){if(!e)return this.viewbox(e).scale;if("fit-viewport"===e)return this._fitViewport(t);let n,i;return this._changeViewbox((function(){"object"!=typeof t&&(n=this.viewbox().outer,t={x:n.width/2,y:n.height/2}),i=this._setZoom(e,t)})),An(i.a,1e3)},Cn.prototype._fitViewport=function(e){const t=this.viewbox(),n=t.outer,i=t.inner;let r,o;return i.x>=0&&i.y>=0&&i.x+i.width<=n.width&&i.y+i.height<=n.height&&!e?o={x:0,y:0,width:Math.max(i.width+i.x,n.width),height:Math.max(i.height+i.y,n.height)}:(r=Math.min(1,n.width/i.width,n.height/i.height),o={x:i.x+(e?i.width/2-n.width/r/2:0),y:i.y+(e?i.height/2-n.height/r/2:0),width:n.width/r,height:n.height/r}),this.viewbox(o),this.viewbox(!1).scale},Cn.prototype._setZoom=function(e,t){const n=this._svg,i=this._viewport,r=n.createSVGMatrix(),o=n.createSVGPoint();let a,s,l,p,c;l=i.getCTM();const u=l.a;return t?(a=E(o,t),s=a.matrixTransform(l.inverse()),p=r.translate(s.x,s.y).scale(1/u*e).translate(-s.x,-s.y),c=l.multiply(p)):c=r.scale(e),Mn(this._viewport,c),c},Cn.prototype.getSize=function(){return{width:this._container.clientWidth,height:this._container.clientHeight}},Cn.prototype.getAbsoluteBBox=function(e){const t=this.viewbox();let n;if(e.waypoints){n=this.getGraphics(e).getBBox()}else n=e;return{x:n.x*t.scale-t.x*t.scale,y:n.y*t.scale-t.y*t.scale,width:n.width*t.scale,height:n.height*t.scale}},Cn.prototype.resized=function(){delete this._cachedViewbox,this._eventBus.fire("canvas.resized")};var Pn="data-element-id";function Nn(e){this._elements={},this._eventBus=e}function Tn(e,t,n){var i=function(e,t,n,i){var r=n.inverse;return Object.defineProperty(e,"remove",{value:function(e){var n=this.indexOf(e);return-1!==n&&(this.splice(n,1),t.unset(e,r,i)),e}}),Object.defineProperty(e,"contains",{value:function(e){return-1!==this.indexOf(e)}}),Object.defineProperty(e,"add",{value:function(e,n){var o=this.indexOf(e);if(void 0===n){if(-1!==o)return;n=this.length}-1!==o&&this.splice(o,1),this.splice(n,0,e),-1===o&&t.set(e,r,i)}}),Object.defineProperty(e,"__refs_collection",{value:!0}),e}(n[t.name]||[],e,t,n);Object.defineProperty(n,t.name,{enumerable:t.enumerable,value:i}),i.length&&i.forEach((function(i){e.set(i,t.inverse,n)}))}function Dn(e,t){if(!(this instanceof Dn))return new Dn(e,t);e.inverse=t,t.inverse=e,this.props={},this.props[e.name]=e,this.props[t.name]=t}Nn.$inject=["eventBus"],Nn.prototype.add=function(e,t,n){var i=e.id;this._validateId(i),L(t,Pn,i),n&&L(n,Pn,i),this._elements[i]={element:e,gfx:t,secondaryGfx:n}},Nn.prototype.remove=function(e){var t=this._elements,n=e.id||e,i=n&&t[n];i&&(L(i.gfx,Pn,""),i.secondaryGfx&&L(i.secondaryGfx,Pn,""),delete t[n])},Nn.prototype.updateId=function(e,t){this._validateId(t),"string"==typeof e&&(e=this.get(e)),this._eventBus.fire("element.updateId",{element:e,newId:t});var n=this.getGraphics(e),i=this.getGraphics(e,!0);this.remove(e),e.id=t,this.add(e,n,i)},Nn.prototype.updateGraphics=function(e,t,n){var i=e.id||e,r=this._elements[i];return n?r.secondaryGfx=t:r.gfx=t,t&&L(t,Pn,i),t},Nn.prototype.get=function(e){var t;t="string"==typeof e?e:e&&L(e,Pn);var n=this._elements[t];return n&&n.element},Nn.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(n)})),t},Nn.prototype.find=function(e){for(var t=this._elements,n=Object.keys(t),i=0;i<n.length;i++){var r=t[n[i]],o=r.element;if(e(o,r.gfx))return o}},Nn.prototype.getAll=function(){return this.filter((function(e){return e}))},Nn.prototype.forEach=function(e){var t=this._elements;Object.keys(t).forEach((function(n){var i=t[n],r=i.element,o=i.gfx;return e(r,o)}))},Nn.prototype.getGraphics=function(e,t){var n=e.id||e,i=this._elements[n];return i&&(t?i.secondaryGfx:i.gfx)},Nn.prototype._validateId=function(e){if(!e)throw new Error("element must have an id");if(this._elements[e])throw new Error("element with id "+e+" already added")},Dn.prototype.bind=function(e,t){if("string"==typeof t){if(!this.props[t])throw new Error("no property <"+t+"> in ref");t=this.props[t]}t.collection?Tn(this,t,e):function(e,t,n){var i=t.inverse,r=n[t.name];Object.defineProperty(n,t.name,{configurable:t.configurable,enumerable:t.enumerable,get:function(){return r},set:function(t){if(t!==r){var o=r;r=null,o&&e.unset(o,i,n),r=t,e.set(r,i,n)}}})}(this,t,e)},Dn.prototype.ensureRefsCollection=function(e,t){var n=e[t.name];return function(e){return!0===e.__refs_collection}(n)||Tn(this,t,e),n},Dn.prototype.ensureBound=function(e,t){(function(e,t){return Object.prototype.hasOwnProperty.call(e,t.name||t)})(e,t)||this.bind(e,t)},Dn.prototype.unset=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).remove(n):e[t.name]=void 0)},Dn.prototype.set=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).add(n):e[t.name]=n)};var Bn=new Dn({name:"children",enumerable:!0,collection:!0},{name:"parent"}),On=new Dn({name:"labels",enumerable:!0,collection:!0},{name:"labelTarget"}),Ln=new Dn({name:"attachers",collection:!0},{name:"host"}),In=new Dn({name:"outgoing",collection:!0},{name:"source"}),Fn=new Dn({name:"incoming",collection:!0},{name:"target"});function jn(){Object.defineProperty(this,"businessObject",{writable:!0}),Object.defineProperty(this,"label",{get:function(){return this.labels[0]},set:function(e){var t=this.label,n=this.labels;!e&&t?n.remove(t):n.add(e,0)}}),Bn.bind(this,"parent"),On.bind(this,"labels"),In.bind(this,"outgoing"),Fn.bind(this,"incoming")}function Vn(){jn.call(this),Bn.bind(this,"children"),Ln.bind(this,"host"),Ln.bind(this,"attachers")}function Wn(){jn.call(this),Bn.bind(this,"children")}function $n(){Vn.call(this),On.bind(this,"labelTarget")}function zn(){jn.call(this),In.bind(this,"source"),Fn.bind(this,"target")}e(Vn,jn),e(Wn,Vn),e($n,Vn),e(zn,jn);var Gn={connection:zn,shape:Vn,label:$n,root:Wn};function Hn(){this._uid=12}Hn.prototype.createRoot=function(e){return this.create("root",e)},Hn.prototype.createLabel=function(e){return this.create("label",e)},Hn.prototype.createShape=function(e){return this.create("shape",e)},Hn.prototype.createConnection=function(e){return this.create("connection",e)},Hn.prototype.create=function(e,t){return(t=E({},t||{})).id||(t.id=e+"_"+this._uid++),function(e,t){var n=Gn[e];if(!n)throw new Error("unknown type: <"+e+">");return E(new n,t)}(e,t)};var Kn="__fn",Un=Array.prototype.slice;function qn(){this._listeners={},this.on("diagram.destroy",1,this._destroy,this)}function Yn(){}function Xn(e,t){this._eventBus=e,this._elementRegistry=t}function Zn(e,t,n){var i=n||t.firstChild;e!==i&&t.insertBefore(e,i)}qn.prototype.on=function(e,t,n,i){if(e=o(e)?e:[e],l(t)&&(i=n,n=t,t=1e3),!s(t))throw new Error("priority must be a number");var r=n;i&&((r=b(n,i))[Kn]=n[Kn]||n);var a=this;e.forEach((function(e){a._addListener(e,{priority:t,callback:r,next:null})}))},qn.prototype.once=function(e,t,n,i){var r=this;if(l(t)&&(i=n,n=t,t=1e3),!s(t))throw new Error("priority must be a number");function o(){o.__isTomb=!0;var t=n.apply(i,arguments);return r.off(e,o),t}o[Kn]=n,this.on(e,t,o)},qn.prototype.off=function(e,t){e=o(e)?e:[e];var n=this;e.forEach((function(e){n._removeListener(e,t)}))},qn.prototype.createEvent=function(e){var t=new Yn;return t.init(e),t},qn.prototype.fire=function(e,t){var n,i,r,o;if(o=Un.call(arguments),"object"==typeof e&&(e=(t=e).type),!e)throw new Error("no event type specified");if(i=this._listeners[e]){n=t instanceof Yn?t:this.createEvent(t),o[0]=n;var a=n.type;e!==a&&(n.type=e);try{r=this._invokeListeners(n,o,i)}finally{e!==a&&(n.type=a)}return void 0===r&&n.defaultPrevented&&(r=!1),r}},qn.prototype.handleError=function(e){return!1===this.fire("error",{error:e})},qn.prototype._destroy=function(){this._listeners={}},qn.prototype._invokeListeners=function(e,t,n){for(var i;n&&!e.cancelBubble;)i=this._invokeListener(e,t,n),n=n.next;return i},qn.prototype._invokeListener=function(e,t,n){var i;if(n.callback.__isTomb)return i;try{i=function(e,t){return e.apply(null,t)}(n.callback,t),void 0!==i&&(e.returnValue=i,e.stopPropagation()),!1===i&&e.preventDefault()}catch(e){if(!this.handleError(e))throw console.error("unhandled error in event listener",e),e}return i},qn.prototype._addListener=function(e,t){var n,i=this._getListeners(e);if(i){for(;i;){if(i.priority<t.priority)return t.next=i,void(n?n.next=t:this._setListeners(e,t));n=i,i=i.next}n.next=t}else this._setListeners(e,t)},qn.prototype._getListeners=function(e){return this._listeners[e]},qn.prototype._setListeners=function(e,t){this._listeners[e]=t},qn.prototype._removeListener=function(e,t){var n,i,r,o=this._getListeners(e);if(t)for(;o;)n=o.next,(r=o.callback)!==t&&r[Kn]!==t||(i?i.next=n:this._setListeners(e,n)),i=o,o=n;else this._setListeners(e,null)},Yn.prototype.stopPropagation=function(){this.cancelBubble=!0},Yn.prototype.preventDefault=function(){this.defaultPrevented=!0},Yn.prototype.init=function(e){E(this,e||{})},Xn.$inject=["eventBus","elementRegistry"],Xn.prototype._getChildrenContainer=function(e){var t,n=this._elementRegistry.getGraphics(e);return e.parent?(t=function(e){return e.parentNode.childNodes[1]}(n),t||(F(t=z("g")).add("djs-children"),D(n.parentNode,t))):t=n,t},Xn.prototype._clear=function(e){var t=function(e){return e.childNodes[0]}(e);return Pe(t),t},Xn.prototype._createContainer=function(e,t,n,i){var r=z("g");F(r).add("djs-group"),void 0!==n?Zn(r,t,t.childNodes[n]):D(t,r);var o=z("g");F(o).add("djs-element"),F(o).add("djs-"+e),i&&F(o).add("djs-frame"),D(r,o);var a=z("g");return F(a).add("djs-visual"),D(o,a),o},Xn.prototype.create=function(e,t,n){var i=this._getChildrenContainer(t.parent);return this._createContainer(e,i,n,At(t))},Xn.prototype.updateContainments=function(e){var t,n=this,i=this._elementRegistry;t=m(e,(function(e,t){return t.parent&&(e[t.parent.id]=t.parent),e}),{}),f(t,(function(e){var t=e.children;if(t){var r=n._getChildrenContainer(e);f(t.slice().reverse(),(function(e){Zn(i.getGraphics(e).parentNode,r)}))}}))},Xn.prototype.drawShape=function(e,t,n={}){return this._eventBus.fire("render.shape",{gfx:e,element:t,attrs:n})},Xn.prototype.getShapePath=function(e){return this._eventBus.fire("render.getShapePath",e)},Xn.prototype.drawConnection=function(e,t,n={}){return this._eventBus.fire("render.connection",{gfx:e,element:t,attrs:n})},Xn.prototype.getConnectionPath=function(e){return this._eventBus.fire("render.getConnectionPath",e)},Xn.prototype.update=function(e,t,n){if(t.parent){var i=this._clear(n);if("shape"===e)this.drawShape(i,t),Ue(n,t.x,t.y);else{if("connection"!==e)throw new Error("unknown type: "+e);this.drawConnection(i,t)}t.hidden?L(n,"display","none"):L(n,"display","block")}},Xn.prototype.remove=function(e){ee(this._elementRegistry.getGraphics(e).parentNode)};var Jn={__depends__:[_n],__init__:["canvas"],canvas:["type",Cn],elementRegistry:["type",Nn],elementFactory:["type",Hn],eventBus:["type",qn],graphicsFactory:["type",Xn]};function Qn(e){return function(e){var t=new wn(e);return t.init(),t}([{config:["value",e=e||{}]},Jn].concat(e.modules||[]))}function ei(e,t){this._injector=t||Qn(e),this.get("eventBus").fire("diagram.init")}function ti(){}function ni(e,t){this.model=e,this.properties=t}ei.prototype.get=function(e,t){return this._injector.get(e,t)},ei.prototype.invoke=function(e,t,n){return this._injector.invoke(e,t,n)},ei.prototype.destroy=function(){this.get("eventBus").fire("diagram.destroy")},ei.prototype.clear=function(){this.get("eventBus").fire("diagram.clear")},ti.prototype.get=function(e){return this.$model.properties.get(this,e)},ti.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},ni.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(ti.prototype);f(e.properties,(function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)})),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function o(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),f(e,b((function(e,t){this.set(t,e)}),this))}return o.prototype=i,o.hasType=i.$instanceOf=this.model.hasType,n.defineModel(o,t),n.defineDescriptor(o,e),o};var ii={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},ri={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e)}};function oi(e,t){var n=ri[e];return n?n(t):t}function ai(e){return!!ii[e]}function si(e){return!!ri[e]}function li(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function pi(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function ci(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,f(e,b(this.registerPackage,this))}function ui(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function hi(e){this.model=e}function fi(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function mi(e){return e.replace(/^:/,"")}function di(e,t={}){this.properties=new hi(this),this.factory=new ni(this,this.properties),this.registry=new ci(e,this.properties),this.typeCache={},this.config=t}pi.prototype.build=function(){return function(e,t){let n={},i=Object(e);return f(t,(function(t){t in i&&(n[t]=e[t])})),n}(this,["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"])},pi.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},pi.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,o=this.propertiesByName,a=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var s=r.indexOf(e);if(-1===s)throw new Error("property <"+i.name+"> not found in property list");r.splice(s,1),this.addProperty(t,n?void 0:s,a),o[i.name]=o[i.localName]=t},pi.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),o=li(r[0],i),a=li(r[1],o.prefix).name,s=this.propertiesByName[a];if(!s)throw new Error("refined property <"+a+"> not found");this.replaceProperty(s,e,n),delete e.redefines},pi.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},pi.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},pi.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},pi.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},pi.prototype.assertNotTrait=function(e){if((e.extends||[]).length)throw new Error(`cannot create <${e.name}> extending <${e.extends}>`)},pi.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},pi.prototype.hasProperty=function(e){return this.propertiesByName[e]},pi.prototype.addTrait=function(e,t){t&&this.assertNotTrait(e);var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(f(e.properties,b((function(n){n=E({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))}),this)),i.push(e),n[r]=e)},ci.prototype.getPackage=function(e){return this.packageMap[e]},ci.prototype.getPackages=function(){return this.packages},ci.prototype.registerPackage=function(e){e=E({},e);var t=this.packageMap;ui(t,e,"prefix"),ui(t,e,"uri"),f(e.types,b((function(t){this.registerType(t,e)}),this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},ci.prototype.registerType=function(e,t){var n=li((e=E({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:E(e.meta||{})})).name,t.prefix),i=n.name,r={};f(e.properties,b((function(e){var t=li(e.name,n.prefix),i=t.name;ai(e.type)||(e.type=li(e.type,t.prefix).name),E(e,{ns:t,name:i}),r[i]=e}),this)),E(e,{ns:n,name:i,propertiesByName:r}),f(e.extends,b((function(e){var t=li(e,n.prefix),r=this.typeMap[t.name];r.traits=r.traits||[],r.traits.push(i)}),this)),this.definePackage(e,t),this.typeMap[i]=e},ci.prototype.mapTypes=function(e,t,n){var i=ai(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function o(n,i){var o=li(n,ai(n)?"":e.prefix);r.mapTypes(o,t,i)}function a(e){return o(e,!0)}if(!i)throw new Error("unknown type <"+e.name+">");f(i.superClass,n?a:function(e){return o(e,!1)}),t(i,!n),f(i.traits,a)},ci.prototype.getEffectiveDescriptor=function(e){var t=li(e),n=new pi(t);this.mapTypes(t,(function(e,t){n.addTrait(e,t)}));var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},ci.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},hi.prototype.set=function(e,t,n){if(!p(t)||!t.length)throw new TypeError("property name must be a non-empty string");var i=this.getProperty(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[mi(t)]:i?r in e?e[r]=n:fi(e,i,n):e.$attrs[mi(t)]=n},hi.prototype.get=function(e,t){var n=this.getProperty(e,t);if(!n)return e.$attrs[mi(t)];var i=n.name;return!e[i]&&n.isMany&&fi(e,n,[]),e[i]},hi.prototype.define=function(e,t,n){if(!n.writable){var i=n.value;delete(n=E({},n,{get:function(){return i}})).value}Object.defineProperty(e,t,n)},hi.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},hi.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},hi.prototype.getProperty=function(e,t){var n=this.model,i=n.getPropertyDescriptor(e,t);if(i)return i;if(t.includes(":"))return null;const r=n.config.strict;if(void 0!==r){const n=new TypeError(`unknown property <${t}> on <${e.$type}>`);if(r)throw n;"undefined"!=typeof console&&console.warn(n)}return null},di.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},di.prototype.getType=function(e){var t=this.typeCache,n=p(e)?e:e.ns.name,i=t[n];return i||(e=this.registry.getEffectiveDescriptor(n),i=t[n]=this.factory.createType(e)),i},di.prototype.createAny=function(e,t,n){var o=li(e),s={$type:e,$instanceOf:function(e){return e===this.$type},get:function(e){return this[e]},set:function(e,t){!function(e,t,n){let o=e;f(t,(function(e,a){if("number"!=typeof e&&"string"!=typeof e)throw new Error("illegal key type: "+typeof e+". Key should be of type number or string.");if("constructor"===e)throw new Error("illegal key: constructor");if("__proto__"===e)throw new Error("illegal key: __proto__");let s=t[a+1],l=o[e];r(s)&&null==l&&(l=o[e]=isNaN(+s)?{}:[]),i(s)?i(n)?delete o[e]:o[e]=n:o=l}))}(this,[e],t)}},l={name:e,isGeneric:!0,ns:{prefix:o.prefix,localName:o.localName,uri:t}};return this.properties.defineDescriptor(s,l),this.properties.defineModel(s,this),this.properties.define(s,"get",{enumerable:!1,writable:!0}),this.properties.define(s,"set",{enumerable:!1,writable:!0}),this.properties.define(s,"$parent",{enumerable:!1,writable:!0}),this.properties.define(s,"$instanceOf",{enumerable:!1,writable:!0}),f(n,(function(e,t){a(e)&&void 0!==e.value?s[e.name]=e.value:s[t]=e})),s},di.prototype.getPackage=function(e){return this.registry.getPackage(e)},di.prototype.getPackages=function(){return this.registry.getPackages()},di.prototype.getElementDescriptor=function(e){return e.$descriptor},di.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},di.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},di.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var yi=String.fromCharCode,gi=Object.prototype.hasOwnProperty,vi=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,xi={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function wi(e,t,n,i){return i?gi.call(xi,i)?xi[i]:"&"+i+";":yi(t||parseInt(n,16))}function bi(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(vi,wi):e}Object.keys(xi).forEach((function(e){xi[e.toUpperCase()]=xi[e]}));var Ei="non-whitespace outside of root node";function _i(e){return new Error(e)}function Ai(e){return"missing namespace for prefix <"+e+">"}function Ri(e){return{get:e,enumerable:!0}}function ki(e){var t,n={};for(t in e)n[t]=e[t];return n}function Si(e){return e+"$uri"}function Ci(){return{line:0,column:0}}function Mi(e){throw e}function Pi(e){if(!this)return new Pi(e);var t,n,i,r,o,a,s,l,p,c=e&&e.proxy,u=Mi,h=Ci,f=!1,m=!1,d=null,y=!1;function g(e){e instanceof Error||(e=_i(e)),d=e,u(e,h)}function v(e){o&&(e instanceof Error||(e=_i(e)),o(e,h))}this.on=function(e,p){if("function"!=typeof p)throw _i("required args <name, cb>");switch(e){case"openTag":n=p;break;case"text":t=p;break;case"closeTag":i=p;break;case"error":u=p;break;case"warn":o=p;break;case"cdata":r=p;break;case"attention":l=p;break;case"question":s=p;break;case"comment":a=p;break;default:throw _i("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw _i("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return m=!0,p=n,this},this.parse=function(e){if("string"!=typeof e)throw _i("required args <xml=string>");return d=null,function(e){var o,u,d,x,w,b,E,_,A,R,k,S=m?[]:null,C=m?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[Si(n)]=t;return i}(p):null,M=[],P=0,N=!1,T=!1,D=0,B=0,O="",L=0;function I(){if(null!==k)return k;var e,t,n,i,r,o,a,s,l,c,u,h=m&&C.xmlns,d=m&&f?[]:null,y=L,g=O,x=g.length,w={},b={};e:for(;y<x;y++)if(l=!1,!(32===(c=g.charCodeAt(y))||c<14&&c>8)){for((c<65||c>122||c>90&&c<97)&&95!==c&&58!==c&&(v("illegal first char attribute name"),l=!0),u=y+1;u<x;u++)if(!((c=g.charCodeAt(u))>96&&c<123||c>64&&c<91||c>47&&c<59||46===c||45===c||95===c)){if(32===c||c<14&&c>8){v("missing attribute value"),y=u;continue e}if(61===c)break;v("illegal attribute name char"),l=!0}if("xmlns:xmlns"===(s=g.substring(y,u))&&(v("illegal declaration of xmlns"),l=!0),34===(c=g.charCodeAt(u+1)))-1===(u=g.indexOf('"',y=u+2))&&-1!==(u=g.indexOf("'",y))&&(v("attribute value quote missmatch"),l=!0);else if(39===c)-1===(u=g.indexOf("'",y=u+2))&&-1!==(u=g.indexOf('"',y))&&(v("attribute value quote missmatch"),l=!0);else for(v("missing attribute value quotes"),l=!0,u+=1;u<x&&!(32===(c=g.charCodeAt(u+1))||c<14&&c>8);u++);for(-1===u&&(v("missing closing quotes"),u=x,l=!0),l||(o=g.substring(y,u)),y=u;u+1<x&&!(32===(c=g.charCodeAt(u+1))||c<14&&c>8);u++)y===u&&(v("illegal character after attribute end"),l=!0);if(y=u+1,!l)if(s in b)v("attribute <"+s+"> already defined");else if(b[s]=!0,m)if(f){if(null!==(r="xmlns"===s?"xmlns":120===s.charCodeAt(0)&&"xmlns:"===s.substr(0,6)?s.substr(6):null)){if(e=bi(o),t=Si(r),!(a=p[e])){if("xmlns"===r||t in C&&C[t]!==e)do{a="ns"+P++}while(void 0!==C[a]);else a=r;p[e]=a}C[r]!==a&&(i||(C=ki(C),i=!0),C[r]=a,"xmlns"===r&&(C[Si(a)]=e,h=a),C[t]=e),w[s]=o;continue}d.push(s,o)}else-1!==(c=s.indexOf(":"))?(n=C[s.substring(0,c)])?w[s=h===n?s.substr(c+1):n+s.substr(c)]=o:v(Ai(s.substring(0,c))):w[s]=o;else w[s]=o}if(f)for(y=0,x=d.length;y<x;y++){if(s=d[y++],o=d[y],-1!==(c=s.indexOf(":"))){if(!(n=C[s.substring(0,c)])){v(Ai(s.substring(0,c)));continue}s=h===n?s.substr(c+1):n+s.substr(c)}w[s]=o}return k=w}function F(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,o=0,a=0,s=B;D>=a&&(t=i.exec(e))&&!((s=t[0].length+t.index)>D);)r+=1,a=s;return-1==D?(o=s,n=e.substring(B)):0===B?n=e.substring(B,D):(o=D-a,n=-1==B?e.substring(D):e.substring(D,B+1)),{data:n,line:r,column:o}}h=F,c&&(R=Object.create({},{name:Ri((function(){return _})),originalName:Ri((function(){return A})),attrs:Ri(I),ns:Ri((function(){return C}))}));for(;-1!==B;){if(-1===(D=60===e.charCodeAt(B)?B:e.indexOf("<",B)))return M.length?g("unexpected end of file"):0===B?g("missing start tag"):void(B<e.length&&e.substring(B).trim()&&v(Ei));if(B!==D)if(M.length){if(t&&(t(e.substring(B,D),bi,h),y))return}else if(e.substring(B,D).trim()&&(v(Ei),y))return;if(33===(w=e.charCodeAt(D+1))){if(91===(x=e.charCodeAt(D+2))&&"CDATA["===e.substr(D+3,6)){if(-1===(B=e.indexOf("]]>",D)))return g("unclosed cdata");if(r&&(r(e.substring(D+9,B),h),y))return;B+=3;continue}if(45===x&&45===e.charCodeAt(D+3)){if(-1===(B=e.indexOf("--\x3e",D)))return g("unclosed comment");if(a&&(a(e.substring(D+4,B),bi,h),y))return;B+=3;continue}}if(63!==w){for(u=D+1;;u++){if(b=e.charCodeAt(u),isNaN(b))return B=-1,g("unclosed tag");if(34===b)u=-1!==(x=e.indexOf('"',u+1))?x:u;else if(39===b)u=-1!==(x=e.indexOf("'",u+1))?x:u;else if(62===b){B=u;break}}if(33!==w){if(k={},47===w){if(N=!1,T=!0,!M.length)return g("missing open tag");if(u=_=M.pop(),x=D+2+u.length,e.substring(D+2,x)!==u)return g("closing tag mismatch");for(;x<B;x++)if(!(32===(w=e.charCodeAt(x))||w>8&&w<14))return g("close tag")}else{if(47===e.charCodeAt(B-1)?(u=_=e.substring(D+1,B-1),N=!0,T=!0):(u=_=e.substring(D+1,B),N=!0,T=!1),!(w>96&&w<123||w>64&&w<91||95===w||58===w))return g("illegal first char nodeName");for(x=1,d=u.length;x<d;x++)if(!((w=u.charCodeAt(x))>96&&w<123||w>64&&w<91||w>47&&w<59||45===w||95===w||46==w)){if(32===w||w<14&&w>8){_=u.substring(0,x),k=null;break}return g("invalid nodeName")}T||M.push(_)}if(m){if(o=C,N&&(T||S.push(o),null===k&&(f=-1!==u.indexOf("xmlns",x))&&(L=x,O=u,I(),f=!1)),A=_,-1!==(w=_.indexOf(":"))){if(!(E=C[_.substring(0,w)]))return g("missing namespace on <"+A+">");_=_.substr(w+1)}else E=C.xmlns;E&&(_=E+":"+_)}if(N&&(L=x,O=u,n&&(c?n(R,bi,T,h):n(_,I,bi,T,h),y)))return;if(T){if(i&&(i(c?R:_,bi,N,h),y))return;m&&(C=N?o:S.pop())}B+=1}else{if(l&&(l(e.substring(D,B+1),bi,h),y))return;B+=1}}else{if(-1===(B=e.indexOf("?>",D)))return g("unclosed question");if(s&&(s(e.substring(D,B+2),h),y))return;B+=2}}}(e),h=Ci,y=!1,d},this.stop=function(){y=!0}}function Ni(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var Ti={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},Di="property";function Bi(e){return e.xml&&e.xml.serialize}function Oi(e,t){return Ni(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function Li(e){return new Error(e)}function Ii(e){return e.$descriptor}function Fi(e){E(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw Li("expected element");var t,n=this.elementsById,i=Ii(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw Li("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function ji(){}function Vi(){}function Wi(){}function $i(e,t){this.property=e,this.context=t}function zi(e,t){this.element=t,this.propertyDesc=e}function Gi(){}function Hi(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function Ki(e,t,n){Hi.call(this,e,t,n)}function Ui(e,t,n){this.model=e,this.context=n}function qi(e){e instanceof di&&(e={model:e}),E(this,{lax:!1},e)}ji.prototype.handleEnd=function(){},ji.prototype.handleText=function(){},ji.prototype.handleNode=function(){},Vi.prototype=Object.create(ji.prototype),Vi.prototype.handleNode=function(){return this},Wi.prototype=Object.create(ji.prototype),Wi.prototype.handleText=function(e){this.body=(this.body||"")+e},$i.prototype=Object.create(Wi.prototype),$i.prototype.handleNode=function(e){if(this.element)throw Li("expected no sub nodes");return this.element=this.createReference(e),this},$i.prototype.handleEnd=function(){this.element.id=this.body},$i.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},zi.prototype=Object.create(Wi.prototype),zi.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=oi(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},Gi.prototype=Object.create(Wi.prototype),Gi.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},Hi.prototype=Object.create(Gi.prototype),Hi.prototype.addReference=function(e){this.context.addReference(e)},Hi.prototype.handleText=function(e){if(!Ii(this.element).bodyProperty)throw Li("unexpected body text <"+e+">");Wi.prototype.handleText.call(this,e)},Hi.prototype.handleEnd=function(){var e=this.body,t=this.element,n=Ii(t).bodyProperty;n&&void 0!==e&&(e=oi(n.type,e),t.set(n.name,e))},Hi.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=Ii(i),o=this.context,a=new i({}),s=this.model;return f(n,(function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?f(e.split(" "),(function(e){o.addReference({element:a,property:i.ns.name,id:e})})):o.addReference({element:a,property:i.ns.name,id:e}):(i?e=oi(i.type,e):"xmlns"===n?n=":"+n:(t=li(n,r.ns.prefix),s.getPackage(t.prefix)&&o.addWarning({message:"unknown attribute <"+n+">",element:a,property:n,value:e})),a.set(n,e))})),a},Hi.prototype.getPropertyForNode=function(e){var t=li(e.name),n=this.type,i=this.model,r=Ii(n),o=t.name,a=r.propertiesByName[o];if(a&&!a.isAttr){const t=function(e){const t=Bi(e);return t!==Di&&(t||null)}(a);if(t){const n=e.attributes[t];if(n){const t=function(e,t,n){const i=li(e,t.xmlns),r=li(`${t[i.prefix]||i.prefix}:${i.localName}`);return function(e,t){var n=e.name,i=e.localName,r=t&&t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(r,n.getPackage(r.prefix))}(n,e.ns,i);return E({},a,{effectiveType:Ii(i.getType(t)).name})}}return a}var s=i.getPackage(t.prefix);if(s){const e=Oi(t,s),n=i.getType(e);if(a=u(r.properties,(function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)})))return E({},a,{effectiveType:Ii(n).name})}else if(a=u(r.properties,(function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type})))return a;throw Li("unrecognized element <"+t.name+">")},Hi.prototype.toString=function(){return"ElementDescriptor["+Ii(this.type).name+"]"},Hi.prototype.valueHandler=function(e,t){return new zi(e,t)},Hi.prototype.referenceHandler=function(e){return new $i(e,this.context)},Hi.prototype.handler=function(e){return"Element"===e?new Ui(this.model,e,this.context):new Hi(this.model,e,this.context)},Hi.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,si(n=t.effectiveType||t.type))return this.valueHandler(t,i);var o=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==o&&(t.isMany?i.get(t.name).push(o):i.set(t.name,o),t.isReference?(E(o,{element:i}),this.context.addReference(o)):o.$parent=i),r},Ki.prototype=Object.create(Hi.prototype),Ki.prototype.createElement=function(e){var t=e.name,n=li(t),i=this.model,r=this.type,o=i.getPackage(n.prefix),a=o&&Oi(n,o)||t;if(!r.hasType(a))throw Li("unexpected element <"+e.originalName+">");return Hi.prototype.createElement.call(this,e)},Ui.prototype=Object.create(Gi.prototype),Ui.prototype.createElement=function(e){var t=e.name,n=li(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},Ui.prototype.handleChild=function(e){var t=new Ui(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},Ui.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},qi.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof Hi?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,o=this.lax,a=new Fi(E({},t,{rootHandler:i})),s=new Pi({proxy:!0}),l=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function p(e,t,n){var i=t(),r=i.line,o=i.column,s=i.data;"<"===s.charAt(0)&&-1!==s.indexOf(" ")&&(s=s.slice(0,s.indexOf(" "))+">");var l="unparsable content "+(s?s+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+o+"\n\tnested error: "+e.message;if(n)return a.addWarning({message:l,error:e}),!0;throw Li(l)}function c(e,t){return p(e,t,!0)}i.context=a,l.push(i);var u=/^<\?xml /i,h=/ encoding="([^"]+)"/i,f=/^utf-8$/i;function m(e,t){try{l.peek().handleText(e)}catch(e){c(e,t)}}var d=r.getPackages().reduce((function(e,t){return e[t.uri]=t.prefix,e}),Object.entries(Ti).reduce((function(e,[t,n]){return e[n]=t,e}),r.config&&r.config.nsMap||{}));return s.ns(d).on("openTag",(function(e,t,n,i){var r=e.attrs||{},a=Object.keys(r).reduce((function(e,n){var i=t(r[n]);return e[n]=i,e}),{});!function(e,t){var n=l.peek();try{l.push(n.handleNode(e))}catch(e){p(e,t,o)&&l.push(new Vi)}}({name:e.name,originalName:e.originalName,attributes:a,ns:e.ns},i)})).on("question",(function(e){if(u.test(e)){var t=h.exec(e),n=t&&t[1];n&&!f.test(n)&&a.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}})).on("closeTag",(function(){l.pop().handleEnd()})).on("cdata",m).on("text",(function(e,t,n){!function(e,t){e.trim()&&m(e,t)}(t(e),n)})).on("error",p).on("warn",c),new Promise((function(t,n){var r;try{s.parse(e),function(){var e,t,n=a.elementsById,i=a.references;for(e=0;t=i[e];e++){var r=t.element,o=n[t.id],s=Ii(r).propertiesByName[t.property];if(o||a.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),s.isMany){var l=r.get(s.name),p=l.indexOf(t);-1===p&&(p=l.length),o?l[p]=o:l.splice(p,1)}else r.set(s.name,o)}}()}catch(e){r=e}var o=i.element;r||o||(r=Li("failed to parse document as <"+i.type.$descriptor.name+">"));var l=a.warnings,p=a.references,c=a.elementsById;return r?(r.warnings=l,n(r)):t({rootElement:o,elementsById:c,references:p,warnings:l})}))},qi.prototype.handler=function(e){return new Ki(this.model,e)};var Yi=/<|>|'|"|&|\n\r|\n/g,Xi=/<|>|&/g;function Zi(e){this.prefixMap={},this.uriMap={},this.used={},this.wellknown=[],this.custom=[],this.parent=e,this.defaultPrefixMap=e&&e.defaultPrefixMap||{}}function Ji(e,t){return Ni(t)?(n=e).charAt(0).toLowerCase()+n.slice(1):e;var n}function Qi(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function er(e){return p(e)?e:(e.prefix?e.prefix+":":"")+e.localName}Zi.prototype.mapDefaultPrefixes=function(e){this.defaultPrefixMap=e},Zi.prototype.defaultUriByPrefix=function(e){return this.defaultPrefixMap[e]},Zi.prototype.byUri=function(e){return this.uriMap[e]||this.parent&&this.parent.byUri(e)},Zi.prototype.add=function(e,t){this.uriMap[e.uri]=e,t?this.wellknown.push(e):this.custom.push(e),this.mapPrefix(e.prefix,e.uri)},Zi.prototype.uriByPrefix=function(e){return this.prefixMap[e||"xmlns"]||this.parent&&this.parent.uriByPrefix(e)},Zi.prototype.mapPrefix=function(e,t){this.prefixMap[e||"xmlns"]=t},Zi.prototype.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},Zi.prototype.logUsed=function(e){var t=e.uri,n=this.getNSKey(e);this.used[n]=this.byUri(t),this.parent&&this.parent.logUsed(e)},Zi.prototype.getUsed=function(e){return[].concat(this.wellknown,this.custom).filter((e=>{var t=this.getNSKey(e);return this.used[t]}))};var tr={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},nr={"<":"lt",">":"gt","&":"amp"};function ir(e,t,n){return(e=p(e)?e:""+e).replace(t,(function(e){return"&"+n[e]+";"}))}function rr(e){this.tagName=e}function or(){}function ar(e){this.tagName=e}function sr(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function lr(e,t,n){sr.call(this,e,t),this.serialization=n}function pr(){this.value="",this.write=function(e){this.value+=e}}function cr(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function ur(e){return e=E({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new pr,r=new cr(i,e.format);e.preamble&&r.append('<?xml version="1.0" encoding="UTF-8"?>\n');var o=new sr,a=t.$model;if(o.getNamespaces().mapDefaultPrefixes(function(e){const t=e.config&&e.config.nsMap||{},n={};for(const e in Ti)n[e]=Ti[e];for(const e in t){n[t[e]]=e}for(const t of e.getPackages())n[t.prefix]=t.uri;return n}(a)),o.build(t).serializeTo(r),!n)return i.value}}}function hr(e,t){di.call(this,e,t)}rr.prototype.build=function(e){return this.element=e,this},rr.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},or.prototype.serializeValue=or.prototype.serializeTo=function(e){e.append(this.escape?ir(this.value,Xi,nr):this.value)},or.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(Xi)&&(this.escape=!0),this},Qi(ar,or),ar.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},sr.prototype.build=function(e){this.element=e;var t,n,i=e.$descriptor,r=this.propertyDescriptor,o=i.isGeneric;return t=o?this.parseGenericNsAttributes(e):this.parseNsAttributes(e),this.ns=r?this.nsPropertyTagName(r):this.nsTagName(i),this.tagName=this.addTagName(this.ns),o?this.parseGenericContainments(e):(n=function(e){return h(e.$descriptor.properties,(function(t){var n=t.name;if(t.isVirtual)return!1;if(!c(e,n))return!1;var i=e[n];return i!==t.default&&null!==i&&(!t.isMany||i.length)}))}(e),this.parseAttributes(h(n,(function(e){return e.isAttr}))),this.parseContainments(function(e){return h(e,(function(e){return!e.isAttr}))}(n))),this.parseGenericAttributes(e,t),this},sr.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?E({localName:t.ns.localName},e):E({localName:Ji(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},sr.prototype.nsPropertyTagName=function(e){return function(e,t){return E({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},sr.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},sr.prototype.nsAttributeName=function(e){var t;if(t=p(e)?li(e):e.ns,e.inherited)return{localName:t.localName};var n=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(n),this.isLocalNs(n)?{localName:t.localName}:E({localName:t.localName},n)},sr.prototype.parseGenericNsAttributes=function(e){return Object.entries(e).filter((([t,n])=>!t.startsWith("$")&&this.parseNsAttribute(e,t,n))).map((([e,t])=>({name:e,value:t})))},sr.prototype.parseGenericContainments=function(e){var t=e.$body;t&&this.body.push((new or).build({type:"String"},t));var n=e.$children;n&&f(n,(e=>{this.body.push(new sr(this).build(e))}))},sr.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,o=li(t);if("xmlns"===o.prefix&&(i={prefix:o.localName,uri:n}),o.prefix||"xmlns"!==o.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var a=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(a)}},sr.prototype.parseNsAttributes=function(e){var t=this,n=e.$attrs,i=[];return f(n,(function(n,r){var o=t.parseNsAttribute(e,r,n);o&&i.push(o)})),i},sr.prototype.parseGenericAttributes=function(e,t){var n=this;f(t,(function(t){try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){"undefined"!=typeof console&&console.warn(`missing namespace information for <${t.name}=${t.value}> on`,e,n)}}))},sr.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;f(e,(function(e){var r=i.get(e.name),o=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new or).build(e,r[0]));else if(si(e.type))f(r,(function(i){n.push(new ar(t.addTagName(t.nsPropertyTagName(e))).build(e,i))}));else if(o)f(r,(function(i){n.push(new rr(t.addTagName(t.nsPropertyTagName(e))).build(i))}));else{var a=Bi(e);f(r,(function(i){var r;r=a?a===Di?new sr(t,e):new lr(t,e,a):new sr(t),n.push(r.build(i))}))}}))},sr.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new Zi(t):n=t),n},sr.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,o=e.prefix;return i.byUri(r)&&!n||i.add(e,t),i.mapPrefix(o,r),e},sr.prototype.logNamespaceUsed=function(e,t){var n,i,r,o=this.getNamespaces(t),a=e.prefix,s=e.uri;if(!a&&!s)return{localName:e.localName};if(r=o.defaultUriByPrefix(a),!(s=s||r||o.uriByPrefix(a)))throw new Error("no namespace uri given for prefix <"+a+">");if((e=o.byUri(s))||a||(e=this.logNamespace({uri:s},r===s,!0)),!e){for(n=a,i=1;o.uriByPrefix(n);)n=a+"_"+i++;e=this.logNamespace({prefix:n,uri:s},r===s)}return a&&o.mapPrefix(a,s),e},sr.prototype.parseAttributes=function(e){var t=this,n=this.element;f(e,(function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];f(i,(function(e){r.push(e.id)})),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)}))},sr.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),er(e)},sr.prototype.addAttribute=function(e,t){var n=this.attrs;p(t)&&(t=ir(t,Yi,tr));var i=function(e,t){const n=v(t);let i=o(e)?-1:void 0;return f(e,(function(e,t){if(n(e,t))return i=t,!1})),i}(n,(function(t){return t.name.localName===e.localName&&t.name.uri===e.uri&&t.name.prefix===e.prefix})),r={name:e,value:t};-1!==i?n.splice(i,1,r):n.push(r)},sr.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=function(e){return e.getUsed().filter((function(e){return"xml"!==e.prefix})).map((function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}}))}(n).concat(t)),f(t,(function(t){e.append(" ").append(er(t.name)).append('="').append(t.value).append('"')}))},sr.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==or;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),f(this.body,(function(t){t.serializeTo(e)})),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},Qi(lr,sr),lr.prototype.parseNsAttributes=function(e){var t=sr.prototype.parseNsAttributes.call(this,e).filter((e=>e.name!==this.serialization)),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),o=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(this.serialization),(i.prefix?i.prefix+":":"")+o+n.ns.localName),t},lr.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},hr.prototype=Object.create(di.prototype),hr.prototype.fromXML=function(e,t,n){p(t)||(n=t,t="bpmn:Definitions");var i=new qi(E({model:this,lax:!0},n)),r=i.handler(t);return i.fromXML(e,r)},hr.prototype.toXML=function(e,t){var n=new ur(t);return new Promise((function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}}))};const fr={bpmn:{name:"BPMN20",uri:"http://www.omg.org/spec/BPMN/20100524/MODEL",prefix:"bpmn",associations:[],types:[{name:"Interface",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"operations",type:"Operation",isMany:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"Operation",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"inMessageRef",type:"Message",isReference:!0},{name:"outMessageRef",type:"Message",isReference:!0},{name:"errorRef",type:"Error",isMany:!0,isReference:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"EndPoint",superClass:["RootElement"]},{name:"Auditing",superClass:["BaseElement"]},{name:"GlobalTask",superClass:["CallableElement"],properties:[{name:"resources",type:"ResourceRole",isMany:!0}]},{name:"Monitoring",superClass:["BaseElement"]},{name:"Performer",superClass:["ResourceRole"]},{name:"Process",superClass:["FlowElementsContainer","CallableElement"],properties:[{name:"processType",type:"ProcessType",isAttr:!0},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"properties",type:"Property",isMany:!0},{name:"laneSets",isMany:!0,replaces:"FlowElementsContainer#laneSets",type:"LaneSet"},{name:"flowElements",isMany:!0,replaces:"FlowElementsContainer#flowElements",type:"FlowElement"},{name:"artifacts",type:"Artifact",isMany:!0},{name:"resources",type:"ResourceRole",isMany:!0},{name:"correlationSubscriptions",type:"CorrelationSubscription",isMany:!0},{name:"supports",type:"Process",isMany:!0,isReference:!0},{name:"definitionalCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"isExecutable",isAttr:!0,type:"Boolean"}]},{name:"LaneSet",superClass:["BaseElement"],properties:[{name:"lanes",type:"Lane",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Lane",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"partitionElementRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"partitionElement",type:"BaseElement"},{name:"flowNodeRef",type:"FlowNode",isMany:!0,isReference:!0},{name:"childLaneSet",type:"LaneSet",xml:{serialize:"xsi:type"}}]},{name:"GlobalManualTask",superClass:["GlobalTask"]},{name:"ManualTask",superClass:["Task"]},{name:"UserTask",superClass:["Task"],properties:[{name:"renderings",type:"Rendering",isMany:!0},{name:"implementation",isAttr:!0,type:"String"}]},{name:"Rendering",superClass:["BaseElement"]},{name:"HumanPerformer",superClass:["Performer"]},{name:"PotentialOwner",superClass:["HumanPerformer"]},{name:"GlobalUserTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"renderings",type:"Rendering",isMany:!0}]},{name:"Gateway",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"gatewayDirection",type:"GatewayDirection",default:"Unspecified",isAttr:!0}]},{name:"EventBasedGateway",superClass:["Gateway"],properties:[{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"eventGatewayType",type:"EventBasedGatewayType",isAttr:!0,default:"Exclusive"}]},{name:"ComplexGateway",superClass:["Gateway"],properties:[{name:"activationCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ExclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"InclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ParallelGateway",superClass:["Gateway"]},{name:"RootElement",isAbstract:!0,superClass:["BaseElement"]},{name:"Relationship",superClass:["BaseElement"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"direction",type:"RelationshipDirection",isAttr:!0},{name:"source",isMany:!0,isReference:!0,type:"Element"},{name:"target",isMany:!0,isReference:!0,type:"Element"}]},{name:"BaseElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,type:"String",isId:!0},{name:"documentation",type:"Documentation",isMany:!0},{name:"extensionDefinitions",type:"ExtensionDefinition",isMany:!0,isReference:!0},{name:"extensionElements",type:"ExtensionElements"}]},{name:"Extension",properties:[{name:"mustUnderstand",default:!1,isAttr:!0,type:"Boolean"},{name:"definition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"extensionAttributeDefinitions",type:"ExtensionAttributeDefinition",isMany:!0}]},{name:"ExtensionAttributeDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"type",isAttr:!0,type:"String"},{name:"isReference",default:!1,isAttr:!0,type:"Boolean"},{name:"extensionDefinition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionElements",properties:[{name:"valueRef",isAttr:!0,isReference:!0,type:"Element"},{name:"values",type:"Element",isMany:!0},{name:"extensionAttributeDefinition",type:"ExtensionAttributeDefinition",isAttr:!0,isReference:!0}]},{name:"Documentation",superClass:["BaseElement"],properties:[{name:"text",type:"String",isBody:!0},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Event",isAbstract:!0,superClass:["FlowNode","InteractionNode"],properties:[{name:"properties",type:"Property",isMany:!0}]},{name:"IntermediateCatchEvent",superClass:["CatchEvent"]},{name:"IntermediateThrowEvent",superClass:["ThrowEvent"]},{name:"EndEvent",superClass:["ThrowEvent"]},{name:"StartEvent",superClass:["CatchEvent"],properties:[{name:"isInterrupting",default:!0,isAttr:!0,type:"Boolean"}]},{name:"ThrowEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"inputSet",type:"InputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"CatchEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"parallelMultiple",isAttr:!0,type:"Boolean",default:!1},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"outputSet",type:"OutputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"BoundaryEvent",superClass:["CatchEvent"],properties:[{name:"cancelActivity",default:!0,isAttr:!0,type:"Boolean"},{name:"attachedToRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"EventDefinition",isAbstract:!0,superClass:["RootElement"]},{name:"CancelEventDefinition",superClass:["EventDefinition"]},{name:"ErrorEventDefinition",superClass:["EventDefinition"],properties:[{name:"errorRef",type:"Error",isAttr:!0,isReference:!0}]},{name:"TerminateEventDefinition",superClass:["EventDefinition"]},{name:"EscalationEventDefinition",superClass:["EventDefinition"],properties:[{name:"escalationRef",type:"Escalation",isAttr:!0,isReference:!0}]},{name:"Escalation",properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"escalationCode",isAttr:!0,type:"String"}],superClass:["RootElement"]},{name:"CompensateEventDefinition",superClass:["EventDefinition"],properties:[{name:"waitForCompletion",isAttr:!0,type:"Boolean",default:!0},{name:"activityRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"TimerEventDefinition",superClass:["EventDefinition"],properties:[{name:"timeDate",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeCycle",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeDuration",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"LinkEventDefinition",superClass:["EventDefinition"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"target",type:"LinkEventDefinition",isReference:!0},{name:"source",type:"LinkEventDefinition",isMany:!0,isReference:!0}]},{name:"MessageEventDefinition",superClass:["EventDefinition"],properties:[{name:"messageRef",type:"Message",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"ConditionalEventDefinition",superClass:["EventDefinition"],properties:[{name:"condition",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"SignalEventDefinition",superClass:["EventDefinition"],properties:[{name:"signalRef",type:"Signal",isAttr:!0,isReference:!0}]},{name:"Signal",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ImplicitThrowEvent",superClass:["ThrowEvent"]},{name:"DataState",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ItemAwareElement",superClass:["BaseElement"],properties:[{name:"itemSubjectRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"dataState",type:"DataState"}]},{name:"DataAssociation",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"ItemAwareElement",isMany:!0,isReference:!0},{name:"targetRef",type:"ItemAwareElement",isReference:!0},{name:"transformation",type:"FormalExpression",xml:{serialize:"property"}},{name:"assignment",type:"Assignment",isMany:!0}]},{name:"DataInput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"inputSetRef",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithOptional",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithWhileExecuting",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"DataOutput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"outputSetRef",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithOptional",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithWhileExecuting",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"InputSet",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"dataInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"optionalInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"whileExecutingInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"outputSetRefs",type:"OutputSet",isMany:!0,isReference:!0}]},{name:"OutputSet",superClass:["BaseElement"],properties:[{name:"dataOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"inputSetRefs",type:"InputSet",isMany:!0,isReference:!0},{name:"optionalOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"whileExecutingOutputRefs",type:"DataOutput",isMany:!0,isReference:!0}]},{name:"Property",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"DataInputAssociation",superClass:["DataAssociation"]},{name:"DataOutputAssociation",superClass:["DataAssociation"]},{name:"InputOutputSpecification",superClass:["BaseElement"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"inputSets",type:"InputSet",isMany:!0},{name:"outputSets",type:"OutputSet",isMany:!0}]},{name:"DataObject",superClass:["FlowElement","ItemAwareElement"],properties:[{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"}]},{name:"InputOutputBinding",properties:[{name:"inputDataRef",type:"InputSet",isAttr:!0,isReference:!0},{name:"outputDataRef",type:"OutputSet",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"Assignment",superClass:["BaseElement"],properties:[{name:"from",type:"Expression",xml:{serialize:"xsi:type"}},{name:"to",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"DataStore",superClass:["RootElement","ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"capacity",isAttr:!0,type:"Integer"},{name:"isUnlimited",default:!0,isAttr:!0,type:"Boolean"}]},{name:"DataStoreReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataStoreRef",type:"DataStore",isAttr:!0,isReference:!0}]},{name:"DataObjectReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataObjectRef",type:"DataObject",isAttr:!0,isReference:!0}]},{name:"ConversationLink",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ConversationAssociation",superClass:["BaseElement"],properties:[{name:"innerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0},{name:"outerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0}]},{name:"CallConversation",superClass:["ConversationNode"],properties:[{name:"calledCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"Conversation",superClass:["ConversationNode"]},{name:"SubConversation",superClass:["ConversationNode"],properties:[{name:"conversationNodes",type:"ConversationNode",isMany:!0}]},{name:"ConversationNode",isAbstract:!0,superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"messageFlowRefs",type:"MessageFlow",isMany:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0}]},{name:"GlobalConversation",superClass:["Collaboration"]},{name:"PartnerEntity",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"PartnerRole",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"CorrelationProperty",superClass:["RootElement"],properties:[{name:"correlationPropertyRetrievalExpression",type:"CorrelationPropertyRetrievalExpression",isMany:!0},{name:"name",isAttr:!0,type:"String"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Error",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"errorCode",isAttr:!0,type:"String"}]},{name:"CorrelationKey",superClass:["BaseElement"],properties:[{name:"correlationPropertyRef",type:"CorrelationProperty",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Expression",superClass:["BaseElement"],isAbstract:!1,properties:[{name:"body",isBody:!0,type:"String"}]},{name:"FormalExpression",superClass:["Expression"],properties:[{name:"language",isAttr:!0,type:"String"},{name:"evaluatesToTypeRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Message",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"itemRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"ItemDefinition",superClass:["RootElement"],properties:[{name:"itemKind",type:"ItemKind",isAttr:!0},{name:"structureRef",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"import",type:"Import",isAttr:!0,isReference:!0}]},{name:"FlowElement",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"categoryValueRef",type:"CategoryValue",isMany:!0,isReference:!0}]},{name:"SequenceFlow",superClass:["FlowElement"],properties:[{name:"isImmediate",isAttr:!0,type:"Boolean"},{name:"conditionExpression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"sourceRef",type:"FlowNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"FlowNode",isAttr:!0,isReference:!0}]},{name:"FlowElementsContainer",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"laneSets",type:"LaneSet",isMany:!0},{name:"flowElements",type:"FlowElement",isMany:!0}]},{name:"CallableElement",isAbstract:!0,superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"supportedInterfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"ioBinding",type:"InputOutputBinding",isMany:!0,xml:{serialize:"property"}}]},{name:"FlowNode",isAbstract:!0,superClass:["FlowElement"],properties:[{name:"incoming",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"outgoing",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"lanes",type:"Lane",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"CorrelationPropertyRetrievalExpression",superClass:["BaseElement"],properties:[{name:"messagePath",type:"FormalExpression"},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"CorrelationPropertyBinding",superClass:["BaseElement"],properties:[{name:"dataPath",type:"FormalExpression"},{name:"correlationPropertyRef",type:"CorrelationProperty",isAttr:!0,isReference:!0}]},{name:"Resource",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"resourceParameters",type:"ResourceParameter",isMany:!0}]},{name:"ResourceParameter",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isRequired",isAttr:!0,type:"Boolean"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"CorrelationSubscription",superClass:["BaseElement"],properties:[{name:"correlationKeyRef",type:"CorrelationKey",isAttr:!0,isReference:!0},{name:"correlationPropertyBinding",type:"CorrelationPropertyBinding",isMany:!0}]},{name:"MessageFlow",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"MessageFlowAssociation",superClass:["BaseElement"],properties:[{name:"innerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0},{name:"outerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0}]},{name:"InteractionNode",isAbstract:!0,properties:[{name:"incomingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0},{name:"outgoingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"Participant",superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"interfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"participantMultiplicity",type:"ParticipantMultiplicity"},{name:"endPointRefs",type:"EndPoint",isMany:!0,isReference:!0},{name:"processRef",type:"Process",isAttr:!0,isReference:!0}]},{name:"ParticipantAssociation",superClass:["BaseElement"],properties:[{name:"innerParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"outerParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"ParticipantMultiplicity",properties:[{name:"minimum",default:0,isAttr:!0,type:"Integer"},{name:"maximum",default:1,isAttr:!0,type:"Integer"}],superClass:["BaseElement"]},{name:"Collaboration",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"participants",type:"Participant",isMany:!0},{name:"messageFlows",type:"MessageFlow",isMany:!0},{name:"artifacts",type:"Artifact",isMany:!0},{name:"conversations",type:"ConversationNode",isMany:!0},{name:"conversationAssociations",type:"ConversationAssociation"},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0},{name:"messageFlowAssociations",type:"MessageFlowAssociation",isMany:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"choreographyRef",type:"Choreography",isMany:!0,isReference:!0},{name:"conversationLinks",type:"ConversationLink",isMany:!0}]},{name:"ChoreographyActivity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"loopType",type:"ChoreographyLoopType",default:"None",isAttr:!0}]},{name:"CallChoreography",superClass:["ChoreographyActivity"],properties:[{name:"calledChoreographyRef",type:"Choreography",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"SubChoreography",superClass:["ChoreographyActivity","FlowElementsContainer"],properties:[{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"ChoreographyTask",superClass:["ChoreographyActivity"],properties:[{name:"messageFlowRef",type:"MessageFlow",isMany:!0,isReference:!0}]},{name:"Choreography",superClass:["Collaboration","FlowElementsContainer"]},{name:"GlobalChoreographyTask",superClass:["Choreography"],properties:[{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Group",superClass:["Artifact"],properties:[{name:"categoryValueRef",type:"CategoryValue",isAttr:!0,isReference:!0}]},{name:"Association",superClass:["Artifact"],properties:[{name:"associationDirection",type:"AssociationDirection",isAttr:!0},{name:"sourceRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"targetRef",type:"BaseElement",isAttr:!0,isReference:!0}]},{name:"Category",superClass:["RootElement"],properties:[{name:"categoryValue",type:"CategoryValue",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Artifact",isAbstract:!0,superClass:["BaseElement"]},{name:"CategoryValue",superClass:["BaseElement"],properties:[{name:"categorizedFlowElements",type:"FlowElement",isMany:!0,isVirtual:!0,isReference:!0},{name:"value",isAttr:!0,type:"String"}]},{name:"Activity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"isForCompensation",default:!1,isAttr:!0,type:"Boolean"},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"boundaryEventRefs",type:"BoundaryEvent",isMany:!0,isReference:!0},{name:"properties",type:"Property",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"startQuantity",default:1,isAttr:!0,type:"Integer"},{name:"resources",type:"ResourceRole",isMany:!0},{name:"completionQuantity",default:1,isAttr:!0,type:"Integer"},{name:"loopCharacteristics",type:"LoopCharacteristics"}]},{name:"ServiceTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"SubProcess",superClass:["Activity","FlowElementsContainer","InteractionNode"],properties:[{name:"triggeredByEvent",default:!1,isAttr:!0,type:"Boolean"},{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"LoopCharacteristics",isAbstract:!0,superClass:["BaseElement"]},{name:"MultiInstanceLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"isSequential",default:!1,isAttr:!0,type:"Boolean"},{name:"behavior",type:"MultiInstanceBehavior",default:"All",isAttr:!0},{name:"loopCardinality",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopDataInputRef",type:"ItemAwareElement",isReference:!0},{name:"loopDataOutputRef",type:"ItemAwareElement",isReference:!0},{name:"inputDataItem",type:"DataInput",xml:{serialize:"property"}},{name:"outputDataItem",type:"DataOutput",xml:{serialize:"property"}},{name:"complexBehaviorDefinition",type:"ComplexBehaviorDefinition",isMany:!0},{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"oneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0},{name:"noneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0}]},{name:"StandardLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"testBefore",default:!1,isAttr:!0,type:"Boolean"},{name:"loopCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopMaximum",type:"Integer",isAttr:!0}]},{name:"CallActivity",superClass:["Activity","InteractionNode"],properties:[{name:"calledElement",type:"String",isAttr:!0}]},{name:"Task",superClass:["Activity","InteractionNode"]},{name:"SendTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ReceiveTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ScriptTask",superClass:["Task"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"script",type:"String"}]},{name:"BusinessRuleTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"AdHocSubProcess",superClass:["SubProcess"],properties:[{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"ordering",type:"AdHocOrdering",isAttr:!0},{name:"cancelRemainingInstances",default:!0,isAttr:!0,type:"Boolean"}]},{name:"Transaction",superClass:["SubProcess"],properties:[{name:"protocol",isAttr:!0,type:"String"},{name:"method",isAttr:!0,type:"String"}]},{name:"GlobalScriptTask",superClass:["GlobalTask"],properties:[{name:"scriptLanguage",isAttr:!0,type:"String"},{name:"script",isAttr:!0,type:"String"}]},{name:"GlobalBusinessRuleTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"ComplexBehaviorDefinition",superClass:["BaseElement"],properties:[{name:"condition",type:"FormalExpression"},{name:"event",type:"ImplicitThrowEvent"}]},{name:"ResourceRole",superClass:["BaseElement"],properties:[{name:"resourceRef",type:"Resource",isReference:!0},{name:"resourceParameterBindings",type:"ResourceParameterBinding",isMany:!0},{name:"resourceAssignmentExpression",type:"ResourceAssignmentExpression"},{name:"name",isAttr:!0,type:"String"}]},{name:"ResourceParameterBinding",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"parameterRef",type:"ResourceParameter",isAttr:!0,isReference:!0}],superClass:["BaseElement"]},{name:"ResourceAssignmentExpression",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}}],superClass:["BaseElement"]},{name:"Import",properties:[{name:"importType",isAttr:!0,type:"String"},{name:"location",isAttr:!0,type:"String"},{name:"namespace",isAttr:!0,type:"String"}]},{name:"Definitions",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"targetNamespace",isAttr:!0,type:"String"},{name:"expressionLanguage",default:"http://www.w3.org/1999/XPath",isAttr:!0,type:"String"},{name:"typeLanguage",default:"http://www.w3.org/2001/XMLSchema",isAttr:!0,type:"String"},{name:"imports",type:"Import",isMany:!0},{name:"extensions",type:"Extension",isMany:!0},{name:"rootElements",type:"RootElement",isMany:!0},{name:"diagrams",isMany:!0,type:"bpmndi:BPMNDiagram"},{name:"exporter",isAttr:!0,type:"String"},{name:"relationships",type:"Relationship",isMany:!0},{name:"exporterVersion",isAttr:!0,type:"String"}]}],enumerations:[{name:"ProcessType",literalValues:[{name:"None"},{name:"Public"},{name:"Private"}]},{name:"GatewayDirection",literalValues:[{name:"Unspecified"},{name:"Converging"},{name:"Diverging"},{name:"Mixed"}]},{name:"EventBasedGatewayType",literalValues:[{name:"Parallel"},{name:"Exclusive"}]},{name:"RelationshipDirection",literalValues:[{name:"None"},{name:"Forward"},{name:"Backward"},{name:"Both"}]},{name:"ItemKind",literalValues:[{name:"Physical"},{name:"Information"}]},{name:"ChoreographyLoopType",literalValues:[{name:"None"},{name:"Standard"},{name:"MultiInstanceSequential"},{name:"MultiInstanceParallel"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"MultiInstanceBehavior",literalValues:[{name:"None"},{name:"One"},{name:"All"},{name:"Complex"}]},{name:"AdHocOrdering",literalValues:[{name:"Parallel"},{name:"Sequential"}]}],xml:{tagAlias:"lowerCase",typePrefix:"t"}},bpmndi:{name:"BPMNDI",uri:"http://www.omg.org/spec/BPMN/20100524/DI",prefix:"bpmndi",types:[{name:"BPMNDiagram",properties:[{name:"plane",type:"BPMNPlane",redefines:"di:Diagram#rootElement"},{name:"labelStyle",type:"BPMNLabelStyle",isMany:!0}],superClass:["di:Diagram"]},{name:"BPMNPlane",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"}],superClass:["di:Plane"]},{name:"BPMNShape",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"isHorizontal",isAttr:!0,type:"Boolean"},{name:"isExpanded",isAttr:!0,type:"Boolean"},{name:"isMarkerVisible",isAttr:!0,type:"Boolean"},{name:"label",type:"BPMNLabel"},{name:"isMessageVisible",isAttr:!0,type:"Boolean"},{name:"participantBandKind",type:"ParticipantBandKind",isAttr:!0},{name:"choreographyActivityShape",type:"BPMNShape",isAttr:!0,isReference:!0}],superClass:["di:LabeledShape"]},{name:"BPMNEdge",properties:[{name:"label",type:"BPMNLabel"},{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"sourceElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#source"},{name:"targetElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#target"},{name:"messageVisibleKind",type:"MessageVisibleKind",isAttr:!0,default:"initiating"}],superClass:["di:LabeledEdge"]},{name:"BPMNLabel",properties:[{name:"labelStyle",type:"BPMNLabelStyle",isAttr:!0,isReference:!0,redefines:"di:DiagramElement#style"}],superClass:["di:Label"]},{name:"BPMNLabelStyle",properties:[{name:"font",type:"dc:Font"}],superClass:["di:Style"]}],enumerations:[{name:"ParticipantBandKind",literalValues:[{name:"top_initiating"},{name:"middle_initiating"},{name:"bottom_initiating"},{name:"top_non_initiating"},{name:"middle_non_initiating"},{name:"bottom_non_initiating"}]},{name:"MessageVisibleKind",literalValues:[{name:"initiating"},{name:"non_initiating"}]}],associations:[]},dc:{name:"DC",uri:"http://www.omg.org/spec/DD/20100524/DC",prefix:"dc",types:[{name:"Boolean"},{name:"Integer"},{name:"Real"},{name:"String"},{name:"Font",properties:[{name:"name",type:"String",isAttr:!0},{name:"size",type:"Real",isAttr:!0},{name:"isBold",type:"Boolean",isAttr:!0},{name:"isItalic",type:"Boolean",isAttr:!0},{name:"isUnderline",type:"Boolean",isAttr:!0},{name:"isStrikeThrough",type:"Boolean",isAttr:!0}]},{name:"Point",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0}]},{name:"Bounds",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0},{name:"width",type:"Real",isAttr:!0},{name:"height",type:"Real",isAttr:!0}]}],associations:[]},di:{name:"DI",uri:"http://www.omg.org/spec/DD/20100524/DI",prefix:"di",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"extension",type:"Extension"},{name:"owningDiagram",type:"Diagram",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"owningElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"modelElement",isReadOnly:!0,isVirtual:!0,isReference:!0,type:"Element"},{name:"style",type:"Style",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"ownedElement",type:"DiagramElement",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Node",isAbstract:!0,superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,superClass:["DiagramElement"],properties:[{name:"source",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"target",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"waypoint",isUnique:!1,isMany:!0,type:"dc:Point",xml:{serialize:"xsi:type"}}]},{name:"Diagram",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"rootElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0},{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"},{name:"ownedStyle",type:"Style",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Shape",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Plane",isAbstract:!0,superClass:["Node"],properties:[{name:"planeElement",type:"DiagramElement",subsettedProperty:"DiagramElement-ownedElement",isMany:!0}]},{name:"LabeledEdge",isAbstract:!0,superClass:["Edge"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"LabeledShape",isAbstract:!0,superClass:["Shape"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"Label",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],xml:{tagAlias:"lowerCase"}},bioc:{name:"bpmn.io colors for BPMN",uri:"http://bpmn.io/schema/bpmn/biocolor/1.0",prefix:"bioc",types:[{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]},color:{name:"BPMN in Color",uri:"http://www.omg.org/spec/BPMN/non-normative/color/1.0",prefix:"color",types:[{name:"ColoredLabel",extends:["bpmndi:BPMNLabel"],properties:[{name:"color",isAttr:!0,type:"String"}]},{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"background-color",isAttr:!0,type:"String"},{name:"border-color",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"border-color",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]}};function mr(e,t){return new hr(E({},fr,e),t)}function dr(e,t){return e.$instanceOf(t)}function yr(e){var t={},n=[],i={};function r(e,t){return function(n){e(n,t)}}function o(e){t[e.id]=e}function a(t,n){try{var r=i[t.id]&&function(t,n){if(t.gfx)throw new Error(`already rendered ${yt(t)}`);return e.element(t,i[t.id],n)}(t,n);return o(t),r}catch(e){s(e.message,{element:t,error:e}),console.error(`failed to import ${yt(t)}`,e)}}function s(t,n){e.error(t,n)}var l=this.registerDi=function(e){var t,n=e.bpmnElement;n?i[n.id]?s(`multiple DI elements defined for ${yt(n)}`,{element:n}):(i[n.id]=e,c(t=n,"di")||Object.defineProperty(t,"di",{enumerable:!1,get:function(){throw new Error("Tried to access di from the businessObject. The di is available through the diagram element only. For more information, see https://github.com/bpmn-io/bpmn-js/issues/1472")}})):s(`no bpmnElement referenced in ${yt(e)}`,{element:e})};function p(e){var t;t=e.plane,l(t),f(t.planeElement,m)}function m(e){l(e)}this.handleDefinitions=function(o,a){var c=o.diagrams;if(a&&-1===c.indexOf(a))throw new Error("diagram not part of <bpmn:Definitions />");if(!a&&c&&c.length&&(a=c[0]),!a)throw new Error("no diagram to display");i={},p(a);var m=a.plane;if(!m)throw new Error(`no plane for ${yt(a)}`);var v=m.bpmnElement;if(!v){if(v=function(e){return u(e.rootElements,(function(e){return dr(e,"bpmn:Process")||dr(e,"bpmn:Collaboration")}))}(o),!v)throw new Error("no process or collaboration to display");s(`correcting missing bpmnElement on ${yt(m)} to ${yt(v)}`),m.bpmnElement=v,l(m)}var x,w,b=function(t,n){return e.root(t,i[t.id],n)}(v,m);if(dr(v,"bpmn:Process")||dr(v,"bpmn:SubProcess"))y(v,b);else{if(!dr(v,"bpmn:Collaboration"))throw new Error(`unsupported bpmnElement for ${yt(m)}: ${yt(v)}`);w=b,f((x=v).participants,r(P,w)),E(x.artifacts,w),n.push((function(){!function(e,t){f(e,r(g,t))}(x.messageFlows,w)})),function(e,n){var i=h(e,(function(e){return!t[e.id]&&dr(e,"bpmn:Process")&&e.laneSets}));i.forEach(r(y,n))}(o.rootElements,b)}d(n)};var d=this.handleDeferred=function(){for(;n.length;)n.shift()()};function y(e,t){M(e,t),_(e.ioSpecification,t),E(e.artifacts,t),o(e)}function g(e,t){a(e,t)}function v(e,t){a(e,t)}function x(e,t){a(e,t)}function w(e,t){a(e,t)}function b(e,t){a(e,t)}function E(e,t){f(e,(function(e){dr(e,"bpmn:Association")?n.push((function(){b(e,t)})):b(e,t)}))}function _(e,t){e&&(f(e.dataInputs,r(x,t)),f(e.dataOutputs,r(w,t)))}var A=this.handleSubProcess=function(e,t){M(e,t),E(e.artifacts,t)};function R(e,t){var i=a(e,t);dr(e,"bpmn:SubProcess")&&A(e,i||t),dr(e,"bpmn:Activity")&&_(e.ioSpecification,t),n.push((function(){f(e.dataInputAssociations,r(v,t)),f(e.dataOutputAssociations,r(v,t))}))}function k(e,t){a(e,t)}function S(e,t){n.push((function(){var n=a(e,t);e.childLaneSet&&C(e.childLaneSet,n||t),function(e){f(e.flowNodeRef,(function(t){var n=t.get("lanes");n&&n.push(e)}))}(e)}))}function C(e,t){f(e.lanes,r(S,t))}function M(e,t){!function(e,t){f(e,(function(e){dr(e,"bpmn:SequenceFlow")?n.push((function(){!function(e,t){a(e,t)}(e,t)})):dr(e,"bpmn:BoundaryEvent")?n.unshift((function(){R(e,t)})):dr(e,"bpmn:FlowNode")?R(e,t):dr(e,"bpmn:DataObject")||(dr(e,"bpmn:DataStoreReference")||dr(e,"bpmn:DataObjectReference")?k(e,t):s(`unrecognized flowElement ${yt(e)} in context ${yt(t&&t.businessObject)}`,{element:e,context:t}))}))}(e.flowElements,t),e.laneSets&&function(e,t){f(e,r(C,t))}(e.laneSets,t)}function P(e,t){var n=a(e,t),i=e.processRef;i&&y(i,n||t)}}function gr(e,t,n){var i,r,o,a=[];function s(e,t){var n=new yr({root:function(e,t){return i.add(e,t)},element:function(e,t,n){return i.add(e,t,n)},error:function(e,t){a.push({message:e,context:t})}});t=t||e.diagrams&&e.diagrams[0];var r=function(e,t){if(!t||!t.plane)return;var n,i=t.plane.bpmnElement,r=i;A(i,"bpmn:Process")||A(i,"bpmn:Collaboration")||(r=function(e){var t=e;for(;t;){if(A(t,"bpmn:Process"))return t;t=t.$parent}} class
H A Dbpmn-modeler.production.min.js7 */var Pt=/,?([a-z]),?/gi,At=parseFloat,Mt=Math,Tt=Mt.PI,Dt=Mt.min,Bt=Mt.max,Nt=Mt.pow,jt=Mt.abs,Ot=/([a-z])[\s,]*((-?\d*\.?\d*(?:e[-+]?\d+)?[\s]*,?[\s]*)+)/gi,Lt=/(-?\d*\.?\d*(?:e[-+]?\d+)?)[\s]*,?[\s]*/gi,$t=Array.isArray||function(e){return e instanceof Array};function It(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Ft(e){if("function"==typeof e||Object(e)!==e)return e;var t=new e.constructor;for(var n in e)It(e,n)&&(t[n]=Ft(e[n]));return t}function zt(e){var t=zt.ps=zt.ps||{};return t[e]?t[e].sleep=100:t[e]={sleep:100},setTimeout((function(){for(var n in t)It(t,n)&&n!=e&&(t[n].sleep--,!t[n].sleep&&delete t[n])})),t[e]}function Ht(e,t,n,i){return 1===arguments.length&&(t=e.y,n=e.width,i=e.height,e=e.x),{x:e,y:t,width:n,height:i,x2:e+n,y2:t+i}}function Vt(){return this.join(",").replace(Pt,"$1")}function Gt(e){var t=Ft(e);return t.toString=Vt,t}function Wt(e,t,n,i,r,o,a,s,c){var p=1-c,l=Nt(p,3),u=Nt(p,2),h=c*c*c,d=l*t+3*u*c*i+3*p*c*c*o+h*s;return{x:Zt(l*e+3*u*c*n+3*p*c*c*r+h*a),y:Zt(d)}}function Ut(e){var t=function(e,t,n,i,r,o,a,s){for(var c,p,l,u,h,d,f,m,v=[],y=[[],[]],g=0;g<2;++g)if(0==g?(p=6*e-12*n+6*r,c=-3*e+9*n-9*r+3*a,l=3*n-3*e):(p=6*t-12*i+6*o,c=-3*t+9*i-9*o+3*s,l=3*i-3*t),jt(c)<1e-12){if(jt(p)<1e-12)continue;0<(u=-l/p)&&u<1&&v.push(u)}else f=p*p-4*l*c,m=Mt.sqrt(f),f<0||(0<(h=(-p+m)/(2*c))&&h<1&&v.push(h),0<(d=(-p-m)/(2*c))&&d<1&&v.push(d));var b,_=v.length,x=_;for(;_--;)b=1-(u=v[_]),y[0][_]=b*b*b*e+3*b*b*u*n+3*b*u*u*r+u*u*u*a,y[1][_]=b*b*b*t+3*b*b*u*i+3*b*u*u*o+u*u*u*s;return y[0][x]=e,y[1][x]=t,y[0][x+1]=a,y[1][x+1]=s,y[0].length=y[1].length=x+2,{x0:Dt(...y[0]),y0:Dt(...y[1]),x1:Bt(...y[0]),y1:Bt(...y[1])}}(...e);return Ht(t.x0,t.y0,t.x1-t.x0,t.y1-t.y0)}function qt(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height}function Kt(e,t,n,i,r){return e*(e*(-3*t+9*n-9*i+3*r)+6*t-12*n+6*i)-3*t+3*n}function Yt(e,t,n,i,r,o,a,s,c){null==c&&(c=1);for(var p=(c=c>1?1:c<0?0:c)/2,l=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],u=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],h=0,d=0;d<12;d++){var f=p*l[d]+p,m=Kt(f,e,n,r,a),v=Kt(f,t,i,o,s),y=m*m+v*v;h+=u[d]*Mt.sqrt(y)}return p*h}function Xt(e,t,n,i,r,o,a,s){if(!(Bt(e,n)<Dt(r,a)||Dt(e,n)>Bt(r,a)||Bt(t,i)<Dt(o,s)||Dt(t,i)>Bt(o,s))){var c=(e*i-t*n)*(o-s)-(t-i)*(r*s-o*a),p=(e-n)*(o-s)-(t-i)*(r-a);if(p){var l=Zt(((e*i-t*n)*(r-a)-(e-n)*(r*s-o*a))/p),u=Zt(c/p),h=+l.toFixed(2),d=+u.toFixed(2);if(!(h<+Dt(e,n).toFixed(2)||h>+Bt(e,n).toFixed(2)||h<+Dt(r,a).toFixed(2)||h>+Bt(r,a).toFixed(2)||d<+Dt(t,i).toFixed(2)||d>+Bt(t,i).toFixed(2)||d<+Dt(o,s).toFixed(2)||d>+Bt(o,s).toFixed(2)))return{x:l,y:u}}}}function Zt(e){return Math.round(1e11*e)/1e11}function Qt(e,t,n){if(!function(e,t){return e=Ht(e),qt(t=Ht(t),e.x,e.y)||qt(t,e.x2,e.y)||qt(t,e.x,e.y2)||qt(t,e.x2,e.y2)||qt(e,t.x,t.y)||qt(e,t.x2,t.y)||qt(e,t.x,t.y2)||qt(e,t.x2,t.y2)||(e.x<t.x2&&e.x>t.x||t.x<e.x2&&t.x>e.x)&&(e.y<t.y2&&e.y>t.y||t.y<e.y2&&t.y>e.y)}(Ut(e),Ut(t)))return n?0:[];for(var i=Yt(...e),r=Yt(...t),o=tn(e)?1:~~(i/5)||1,a=tn(t)?1:~~(r/5)||1,s=[],c=[],p={},l=n?0:[],u=0;u<o+1;u++){var h=Wt(...e,u/o);s.push({x:h.x,y:h.y,t:u/o})}for(u=0;u<a+1;u++)h=Wt(...t,u/a),c.push({x:h.x,y:h.y,t:u/a});for(u=0;u<o;u++)for(var d=0;d<a;d++){var f,m=s[u],v=s[u+1],y=c[d],g=c[d+1],b=jt(v.x-m.x)<.01?"y":"x",_=jt(g.x-y.x)<.01?"y":"x",x=Xt(m.x,m.y,v.x,v.y,y.x,y.y,g.x,g.y);if(x){if(p[f=x.x.toFixed(9)+"#"+x.y.toFixed(9)])continue;p[f]=!0;var w=m.t+jt((x[b]-m[b])/(v[b]-m[b]))*(v.t-m.t),E=y.t+jt((x[_]-y[_])/(g[_]-y[_]))*(g.t-y.t);w>=0&&w<=1&&E>=0&&E<=1&&(n?l++:l.push({x:x.x,y:x.y,t1:w,t2:E}))}}return l}function Jt(e,t,n){e=an(e),t=an(t);for(var i,r,o,a,s,c,p,l,u,h,d=n?0:[],f=0,m=e.length;f<m;f++){var v=e[f];if("M"==v[0])i=s=v[1],r=c=v[2];else{"C"==v[0]?(i=(u=[i,r,...v.slice(1)])[6],r=u[7]):(u=[i,r,i,r,s,c,s,c],i=s,r=c);for(var y=0,g=t.length;y<g;y++){var b=t[y];if("M"==b[0])o=p=b[1],a=l=b[2];else{"C"==b[0]?(o=(h=[o,a,...b.slice(1)])[6],a=h[7]):(h=[o,a,o,a,p,l,p,l],o=p,a=l);var _=Qt(u,h,n);if(n)d+=_;else{for(var x=0,w=_.length;x<w;x++)_[x].segment1=f,_[x].segment2=y,_[x].bez1=u,_[x].bez2=h;d=d.concat(_)}}}}}return d}function en(e){var t=zt(e);if(t.abs)return Gt(t.abs);if($t(e)&&$t(e&&e[0])||(e=function(e){if(!e)return null;var t=zt(e);if(t.arr)return Ft(t.arr);var n={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},i=[];return $t(e)&&$t(e[0])&&(i=Ft(e)),i.length||String(e).replace(Ot,(function(e,t,r){var o=[],a=t.toLowerCase();for(r.replace(Lt,(function(e,t){t&&o.push(+t)})),"m"==a&&o.length>2&&(i.push([t,...o.splice(0,2)]),a="l",t="m"==t?"l":"L");o.length>=n[a]&&(i.push([t,...o.splice(0,n[a])]),n[a]););})),i.toString=zt.toString,t.arr=Ft(i),i}(e)),!e||!e.length)return[["M",0,0]];var n,i=[],r=0,o=0,a=0,s=0,c=0;"M"==e[0][0]&&(a=r=+e[0][1],s=o=+e[0][2],c++,i[0]=["M",r,o]);for(var p,l,u=c,h=e.length;u<h;u++){if(i.push(p=[]),(n=(l=e[u])[0])!=n.toUpperCase())switch(p[0]=n.toUpperCase(),p[0]){case"A":p[1]=l[1],p[2]=l[2],p[3]=l[3],p[4]=l[4],p[5]=l[5],p[6]=+l[6]+r,p[7]=+l[7]+o;break;case"V":p[1]=+l[1]+o;break;case"H":p[1]=+l[1]+r;break;case"M":a=+l[1]+r,s=+l[2]+o;default:for(var d=1,f=l.length;d<f;d++)p[d]=+l[d]+(d%2?r:o)}else for(var m=0,v=l.length;m<v;m++)p[m]=l[m];switch(n=n.toUpperCase(),p[0]){case"Z":r=+a,o=+s;break;case"H":r=p[1];break;case"V":o=p[1];break;case"M":a=p[p.length-2],s=p[p.length-1];default:r=p[p.length-2],o=p[p.length-1]}}return i.toString=Vt,t.abs=Gt(i),i}function tn(e){return e[0]===e[2]&&e[1]===e[3]&&e[4]===e[6]&&e[5]===e[7]}function nn(e,t,n,i){return[e,t,n,i,n,i]}function rn(e,t,n,i,r,o){var a=1/3,s=2/3;return[a*e+s*n,a*t+s*i,a*r+s*n,a*o+s*i,r,o]}function on(e,t,n,i,r,o,a,s,c,p){var l,u=120*Tt/180,h=Tt/180*(+r||0),d=[],f=function(e){return function t(){var n=Array.prototype.slice.call(arguments,0).join("␀"),i=t.cache=t.cache||{},r=t.count=t.count||[];return It(i,n)?(function(e,t){for(var n=0,i=e.length;n<i;n++)if(e[n]===t)return e.push(e.splice(n,1)[0])}(r,n),i[n]):(r.length>=1e3&&delete i[r.shift()],r.push(n),i[n]=e(...arguments),i[n])}}((function(e,t,n){return{x:e*Mt.cos(n)-t*Mt.sin(n),y:e*Mt.sin(n)+t*Mt.cos(n)}}));if(p)E=p[0],S=p[1],x=p[2],w=p[3];else{e=(l=f(e,t,-h)).x,t=l.y;var m=(e-(s=(l=f(s,c,-h)).x))/2,v=(t-(c=l.y))/2,y=m*m/(n*n)+v*v/(i*i);y>1&&(n*=y=Mt.sqrt(y),i*=y);var g=n*n,b=i*i,_=(o==a?-1:1)*Mt.sqrt(jt((g*b-g*v*v-b*m*m)/(g*v*v+b*m*m))),x=_*n*v/i+(e+s)/2,w=_*-i*m/n+(t+c)/2,E=Mt.asin(((t-w)/i).toFixed(9)),S=Mt.asin(((c-w)/i).toFixed(9));(E=e<x?Tt-E:E)<0&&(E=2*Tt+E),(S=s<x?Tt-S:S)<0&&(S=2*Tt+S),a&&E>S&&(E-=2*Tt),!a&&S>E&&(S-=2*Tt)}var C=S-E;if(jt(C)>u){var k=S,R=s,P=c;S=E+u*(a&&S>E?1:-1),d=on(s=x+n*Mt.cos(S),c=w+i*Mt.sin(S),n,i,r,0,a,R,P,[S,k,x,w])}C=S-E;var A=Mt.cos(E),M=Mt.sin(E),T=Mt.cos(S),D=Mt.sin(S),B=Mt.tan(C/4),N=4/3*n*B,j=4/3*i*B,O=[e,t],L=[e+N*M,t-j*A],$=[s+N*D,c-j*T],I=[s,c];if(L[0]=2*O[0]-L[0],L[1]=2*O[1]-L[1],p)return[L,$,I].concat(d);for(var F=[],z=0,H=(d=[L,$,I].concat(d).join().split(",")).length;z<H;z++)F[z]=z%2?f(d[z-1],d[z],h).y:f(d[z],d[z+1],h).x;return F}function an(e){var t=zt(e);if(t.curve)return Gt(t.curve);for(var n=en(e),i={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},r=function(e,t,n){var i,r;if(!e)return["C",t.x,t.y,t.x,t.y,t.x,t.y];switch(!(e[0]in{T:1,Q:1})&&(t.qx=t.qy=null),e[0]){case"M":t.X=e[1],t.Y=e[2];break;case"A":e=["C",...on(t.x,t.y,...e.slice(1))];break;case"S":"C"==n||"S"==n?(i=2*t.x-t.bx,r=2*t.y-t.by):(i=t.x,r=t.y),e=["C",i,r,...e.slice(1)];break;case"T":"Q"==n||"T"==n?(t.qx=2*t.x-t.qx,t.qy=2*t.y-t.qy):(t.qx=t.x,t.qy=t.y),e=["C",...rn(t.x,t.y,t.qx,t.qy,e[1],e[2])];break;case"Q":t.qx=e[1],t.qy=e[2],e=["C",...rn(t.x,t.y,e[1],e[2],e[3],e[4])];break;case"L":e=["C",...nn(t.x,t.y,e[1],e[2])];break;case"H":e=["C",...nn(t.x,t.y,e[1],t.y)];break;case"V":e=["C",...nn(t.x,t.y,t.x,e[1])];break;case"Z":e=["C",...nn(t.x,t.y,t.X,t.Y)]}return e},o=function(e,t){if(e[t].length>7){e[t].shift();for(var i=e[t];i.length;)a[t]="A",e.splice(t++,0,["C",...i.splice(0,6)]);e.splice(t,1),l=n.length}},a=[],s="",c="",p=0,l=n.length;p<l;p++){n[p]&&(s=n[p][0]),"C"!=s&&(a[p]=s,p&&(c=a[p-1])),n[p]=r(n[p],i,c),"A"!=a[p]&&"C"==s&&(a[p]="C"),o(n,p);var u=n[p],h=u.length;i.x=u[h-2],i.y=u[h-1],i.bx=At(u[h-4])||i.x,i.by=At(u[h-3])||i.y}return t.curve=Gt(n),n}function sn(e){return l(e)&&f(e,"waypoints")}function cn(e){return l(e)&&f(e,"labelTarget")}function pn(e){return{x:Math.round(e.x),y:Math.round(e.y),width:Math.round(e.width),height:Math.round(e.height)}}function ln(e){return{x:Math.round(e.x),y:Math.round(e.y)}}function un(e){return{top:e.y,right:e.x+(e.width||0),bottom:e.y+(e.height||0),left:e.x}}function hn(e){return{x:e.left,y:e.top,width:e.right-e.left,height:e.bottom-e.top}}function dn(e){for(var t=e.waypoints,n=t.reduce((function(e,n,i){var r=t[i-1];if(r){var o=e[e.length-1],a=o&&o.endLength||0,s=function(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}(r,n);e.push({start:r,end:n,startLength:a,endLength:a+s,length:s})}return e}),[]),i=n.reduce((function(e,t){return e+t.length}),0),r=i/2,o=0,a=n[o];a.endLength<r;)a=n[++o];var s=(r-a.startLength)/a.length;return{x:a.start.x+(a.end.x-a.start.x)*s,y:a.start.y+(a.end.y-a.start.y)*s}}function fn(e){return sn(e)?dn(e):ln({x:(t=e).x+(t.width||0)/2,y:t.y+(t.height||0)/2});var t}function mn(e,t,n){l(n=n||0)||(n={x:n,y:n});var i=un(e),r=un(t),o=i.bottom+n.y<=r.top,a=i.left-n.x>=r.right,s=i.top-n.y>=r.bottom,c=o?"top":s?"bottom":null,p=i.right+n.x<=r.left?"left":a?"right":null;return p&&c?c+"-"+p:p||c||"intersect"}function vn(e,t,n){var i=function(e,t){return Jt(e,t)}(e,t);return 1===i.length||2===i.length&&wt(i[0],i[1])<1?ln(i[0]):i.length>1?(i=A(i,(function(e){var t=Math.floor(100*e.t2)||1;return t=((t=100-t)<10?"0":"")+t,e.segment2+"#"+t})),ln(i[n?0:i.length-1])):null}function yn(e,t){return Math.round(e*t)/t}function gn(e){return u(e)?e+"px":e}function bn(e,t,n){const i=Ae("g");we(i).add(t);const r=void 0!==n?n:e.childNodes.length-1;return e.insertBefore(i,e.childNodes[r]||null),i}const _n={shape:["x","y","width","height"],connection:["waypoints"]};function xn(e,t,n,i){this._eventBus=t,this._elementRegistry=i,this._graphicsFactory=n,this._rootsIdx=0,this._layers={},this._planes=[],this._rootElement=null,this._focused=!1,this._init(e||{})}function wn(e,t){const n="matrix("+t.a+","+t.b+","+t.c+","+t.d+","+t.e+","+t.f+")";e.setAttribute("transform",n)}xn.$inject=["config.canvas","eventBus","graphicsFactory","elementRegistry"],xn.prototype._init=function(e){const t=this._eventBus,n=this._container=function(e){const t=(e=L({},{width:"100%",height:"100%"},e)).container||document.body,n=document.createElement("div");return n.setAttribute("class","djs-container djs-parent"),q(n,{position:"relative",overflow:"hidden",width:gn(e.width),height:gn(e.height)}),t.appendChild(n),n}(e),i=this._svg=Ae("svg");_e(i,{width:"100%",height:"100%"}),K(i,"tabindex",0),e.autoFocus&&t.on("element.hover",(()=>{this.restoreFocus()})),t.on("element.mousedown",500,(e=>{this.focus()})),i.addEventListener("focusin",(()=>{this._setFocused(!0)})),i.addEventListener("focusout",(()=>{this._setFocused(!1)})),ye(n,i);const r=this._viewport=bn(i,"viewport");e.deferUpdate&&(this._viewboxChanged=j(O(this._viewboxChanged,this),300)),t.on("diagram.init",(()=>{t.fire("canvas.init",{svg:i,viewport:r})})),t.on(["shape.added","connection.added","shape.removed","connection.removed","elements.changed","root.set"],(()=>{delete this._cachedViewbox})),t.on("diagram.destroy",500,this._destroy,this),t.on("diagram.clear",500,this._clear,this)},xn.prototype._destroy=function(){this._eventBus.fire("canvas.destroy",{svg:this._svg,viewport:this._viewport});const e=this._container.parentNode;e&&e.removeChild(this._container),delete this._svg,delete this._container,delete this._layers,delete this._planes,delete this._rootElement,delete this._viewport},xn.prototype._setFocused=function(e){e!=this._focused&&(this._focused=e,this._eventBus.fire("canvas.focus.changed",{focused:e}))},xn.prototype._clear=function(){this._elementRegistry.getAll().forEach((e=>{const t=ft(e);"root"===t?this.removeRootElement(e):this._removeElement(e,t)})),this._planes=[],this._rootElement=null,delete this._cachedViewbox},xn.prototype.focus=function(){this._svg.focus({preventScroll:!0}),this._setFocused(!0)},xn.prototype.restoreFocus=function(){document.activeElement===document.body&&this.focus()},xn.prototype.isFocused=function(){return this._focused},xn.prototype.getDefaultLayer=function(){return this.getLayer("base",0)},xn.prototype.getLayer=function(e,t){if(!e)throw new Error("must specify a name");let n=this._layers[e];if(n||(n=this._layers[e]=this._createLayer(e,t)),void 0!==t&&n.index!==t)throw new Error("layer <"+e+"> already created at index <"+t+">");return n.group},xn.prototype._getChildIndex=function(e){return _(this._layers,(function(t,n){return n.visible&&e>=n.index&&t++,t}),0)},xn.prototype._createLayer=function(e,t){void 0===t&&(t=1);const n=this._getChildIndex(t);return{group:bn(this._viewport,"layer-"+e,n),index:t,visible:!0}},xn.prototype.showLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=this._viewport,i=t.group,r=t.index;if(t.visible)return i;const o=this._getChildIndex(r);return n.insertBefore(i,n.childNodes[o]||null),t.visible=!0,i},xn.prototype.hideLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=t.group;return t.visible?(Fe(n),t.visible=!1,n):n},xn.prototype._removeLayer=function(e){const t=this._layers[e];t&&(delete this._layers[e],Fe(t.group))},xn.prototype.getActiveLayer=function(){const e=this._findPlaneForRoot(this.getRootElement());return e?e.layer:null},xn.prototype.findRoot=function(e){if("string"==typeof e&&(e=this._elementRegistry.get(e)),!e)return;const t=this._findPlaneForRoot(function(e){for(;e.parent;)e=e.parent;return e}(e))||{};return t.rootElement},xn.prototype.getRootElements=function(){return this._planes.map((function(e){return e.rootElement}))},xn.prototype._findPlaneForRoot=function(e){return m(this._planes,(function(t){return t.rootElement===e}))},xn.prototype.getContainer=function(){return this._container},xn.prototype._updateMarker=function(e,t,n){let i;e.id||(e=this._elementRegistry.get(e)),e.markers=e.markers||new Set,i=this._elementRegistry._elements[e.id],i&&(g([i.gfx,i.secondaryGfx],(function(i){i&&(n?(e.markers.add(t),we(i).add(t)):(e.markers.delete(t),we(i).remove(t)))})),this._eventBus.fire("element.marker.update",{element:e,gfx:i.gfx,marker:t,add:!!n}))},xn.prototype.addMarker=function(e,t){this._updateMarker(e,t,!0)},xn.prototype.removeMarker=function(e,t){this._updateMarker(e,t,!1)},xn.prototype.hasMarker=function(e,t){return e.id||(e=this._elementRegistry.get(e)),!!e.markers&&e.markers.has(t)},xn.prototype.toggleMarker=function(e,t){this.hasMarker(e,t)?this.removeMarker(e,t):this.addMarker(e,t)},xn.prototype.getRootElement=function(){const e=this._rootElement;return e||this._planes.length?e:this.setRootElement(this.addRootElement(null))},xn.prototype.addRootElement=function(e){const t=this._rootsIdx++;e||(e={id:"__implicitroot_"+t,children:[],isImplicit:!0});const n=e.layer="root-"+t;this._ensureValid("root",e);const i=this.getLayer(n,0);return this.hideLayer(n),this._addRoot(e,i),this._planes.push({rootElement:e,layer:i}),e},xn.prototype.removeRootElement=function(e){"string"==typeof e&&(e=this._elementRegistry.get(e));if(this._findPlaneForRoot(e))return this._removeRoot(e),this._removeLayer(e.layer),this._planes=this._planes.filter((function(t){return t.rootElement!==e})),this._rootElement===e&&(this._rootElement=null),e},xn.prototype.setRootElement=function(e){if(e===this._rootElement)return e;let t;if(!e)throw new Error("rootElement required");return t=this._findPlaneForRoot(e),t||(e=this.addRootElement(e)),this._setRoot(e),e},xn.prototype._removeRoot=function(e){const t=this._elementRegistry,n=this._eventBus;n.fire("root.remove",{element:e}),n.fire("root.removed",{element:e}),t.remove(e)},xn.prototype._addRoot=function(e,t){const n=this._elementRegistry,i=this._eventBus;i.fire("root.add",{element:e}),n.add(e,t),i.fire("root.added",{element:e,gfx:t})},xn.prototype._setRoot=function(e,t){const n=this._rootElement;n&&(this._elementRegistry.updateGraphics(n,null,!0),this.hideLayer(n.layer)),e&&(t||(t=this._findPlaneForRoot(e).layer),this._elementRegistry.updateGraphics(e,this._svg,!0),this.showLayer(e.layer)),this._rootElement=e,this._eventBus.fire("root.set",{element:e})},xn.prototype._ensureValid=function(e,t){if(!t.id)throw new Error("element must have an id");if(this._elementRegistry.get(t.id))throw new Error("element <"+t.id+"> already exists");const n=_n[e],i=x(n,(function(e){return void 0!==t[e]}));if(!i)throw new Error("must supply { "+n.join(", ")+" } with "+e)},xn.prototype._setParent=function(e,t,n){_t(t.children,e,n),e.parent=t},xn.prototype._addElement=function(e,t,n,i){n=n||this.getRootElement();const r=this._eventBus,o=this._graphicsFactory;this._ensureValid(e,t),r.fire(e+".add",{element:t,parent:n}),this._setParent(t,n,i);const a=o.create(e,t,i);return this._elementRegistry.add(t,a),o.update(e,t,a),r.fire(e+".added",{element:t,gfx:a}),t},xn.prototype.addShape=function(e,t,n){return this._addElement("shape",e,t,n)},xn.prototype.addConnection=function(e,t,n){return this._addElement("connection",e,t,n)},xn.prototype._removeElement=function(e,t){const n=this._elementRegistry,i=this._graphicsFactory,r=this._eventBus;if(e=n.get(e.id||e))return r.fire(t+".remove",{element:e}),i.remove(e),bt(e.parent&&e.parent.children,e),e.parent=null,r.fire(t+".removed",{element:e}),n.remove(e),e},xn.prototype.removeShape=function(e){return this._removeElement(e,"shape")},xn.prototype.removeConnection=function(e){return this._removeElement(e,"connection")},xn.prototype.getGraphics=function(e,t){return this._elementRegistry.getGraphics(e,t)},xn.prototype._changeViewbox=function(e){this._eventBus.fire("canvas.viewbox.changing"),e.apply(this),this._cachedViewbox=null,this._viewboxChanged()},xn.prototype._viewboxChanged=function(){this._eventBus.fire("canvas.viewbox.changed",{viewbox:this.viewbox()})},xn.prototype.viewbox=function(e){if(void 0===e&&this._cachedViewbox)return structuredClone(this._cachedViewbox);const t=this._viewport,n=this.getSize();let i,r,o,a,s,c,p;return e?(this._changeViewbox((function(){s=Math.min(n.width/e.width,n.height/e.height);const i=this._svg.createSVGMatrix().scale(s).translate(-e.x,-e.y);He(t,i)})),e):(o=this._rootElement?this.getActiveLayer():null,i=o&&o.getBBox()||{},a=He(t),r=a?a.matrix:function(e,t,n,i,r,o){var a=Te().createSVGMatrix();switch(arguments.length){case 0:return a;case 1:return De(a,e);case 6:return De(a,{a:e,b:t,c:n,d:i,e:r,f:o})}}(),s=yn(r.a,1e3),c=yn(-r.e||0,1e3),p=yn(-r.f||0,1e3),e=this._cachedViewbox={x:c?c/s:0,y:p?p/s:0,width:n.width/s,height:n.height/s,scale:s,inner:{width:i.width||0,height:i.height||0,x:i.x||0,y:i.y||0},outer:n})},xn.prototype.scroll=function(e){const t=this._viewport;let n=t.getCTM();return e&&this._changeViewbox((function(){e=L({dx:0,dy:0},e||{}),n=this._svg.createSVGMatrix().translate(e.dx,e.dy).multiply(n),wn(t,n)})),{x:n.e,y:n.f}},xn.prototype.scrollToElement=function(e,t){let n=100;"string"==typeof e&&(e=this._elementRegistry.get(e));const i=this.findRoot(e);if(i!==this.getRootElement()&&this.setRootElement(i),i===e)return;t||(t={}),"number"==typeof t&&(n=t),t={top:t.top||n,right:t.right||n,bottom:t.bottom||n,left:t.left||n};const r=ht(e),o=un(r),a=this.viewbox(),s=this.zoom();let c,p;a.y+=t.top/s,a.x+=t.left/s,a.width-=(t.right+t.left)/s,a.height-=(t.bottom+t.top)/s;const l=un(a);if(r.width<a.width&&r.height<a.height){const e=Math.max(0,o.right-l.right),t=Math.min(0,o.left-l.left),n=Math.max(0,o.bottom-l.bottom),i=Math.min(0,o.top-l.top);c=e||t,p=n||i}else c=r.x-a.x,p=r.y-a.y;this.scroll({dx:-c*s,dy:-p*s})},xn.prototype.zoom=function(e,t){if(!e)return this.viewbox(e).scale;if("fit-viewport"===e)return this._fitViewport(t);let n,i;return this._changeViewbox((function(){"object"!=typeof t&&(n=this.viewbox().outer,t={x:n.width/2,y:n.height/2}),i=this._setZoom(e,t)})),yn(i.a,1e3)},xn.prototype._fitViewport=function(e){const t=this.viewbox(),n=t.outer,i=t.inner;let r,o;return i.x>=0&&i.y>=0&&i.x+i.width<=n.width&&i.y+i.height<=n.height&&!e?o={x:0,y:0,width:Math.max(i.width+i.x,n.width),height:Math.max(i.height+i.y,n.height)}:(r=Math.min(1,n.width/i.width,n.height/i.height),o={x:i.x+(e?i.width/2-n.width/r/2:0),y:i.y+(e?i.height/2-n.height/r/2:0),width:n.width/r,height:n.height/r}),this.viewbox(o),this.viewbox(!1).scale},xn.prototype._setZoom=function(e,t){const n=this._svg,i=this._viewport,r=n.createSVGMatrix(),o=n.createSVGPoint();let a,s,c,p,l;c=i.getCTM();const u=c.a;return t?(a=L(o,t),s=a.matrixTransform(c.inverse()),p=r.translate(s.x,s.y).scale(1/u*e).translate(-s.x,-s.y),l=c.multiply(p)):l=r.scale(e),wn(this._viewport,l),l},xn.prototype.getSize=function(){return{width:this._container.clientWidth,height:this._container.clientHeight}},xn.prototype.getAbsoluteBBox=function(e){const t=this.viewbox();let n;if(e.waypoints){n=this.getGraphics(e).getBBox()}else n=e;return{x:n.x*t.scale-t.x*t.scale,y:n.y*t.scale-t.y*t.scale,width:n.width*t.scale,height:n.height*t.scale}},xn.prototype.resized=function(){delete this._cachedViewbox,this._eventBus.fire("canvas.resized")};var En="data-element-id";function Sn(e){this._elements={},this._eventBus=e}function Cn(e,t,n){var i=function(e,t,n,i){var r=n.inverse;return Object.defineProperty(e,"remove",{value:function(e){var n=this.indexOf(e);return-1!==n&&(this.splice(n,1),t.unset(e,r,i)),e}}),Object.defineProperty(e,"contains",{value:function(e){return-1!==this.indexOf(e)}}),Object.defineProperty(e,"add",{value:function(e,n){var o=this.indexOf(e);if(void 0===n){if(-1!==o)return;n=this.length}-1!==o&&this.splice(o,1),this.splice(n,0,e),-1===o&&t.set(e,r,i)}}),Object.defineProperty(e,"__refs_collection",{value:!0}),e}(n[t.name]||[],e,t,n);Object.defineProperty(n,t.name,{enumerable:t.enumerable,value:i}),i.length&&i.forEach((function(i){e.set(i,t.inverse,n)}))}function kn(e,t){if(!(this instanceof kn))return new kn(e,t);e.inverse=t,t.inverse=e,this.props={},this.props[e.name]=e,this.props[t.name]=t}Sn.$inject=["eventBus"],Sn.prototype.add=function(e,t,n){var i=e.id;this._validateId(i),_e(t,En,i),n&&_e(n,En,i),this._elements[i]={element:e,gfx:t,secondaryGfx:n}},Sn.prototype.remove=function(e){var t=this._elements,n=e.id||e,i=n&&t[n];i&&(_e(i.gfx,En,""),i.secondaryGfx&&_e(i.secondaryGfx,En,""),delete t[n])},Sn.prototype.updateId=function(e,t){this._validateId(t),"string"==typeof e&&(e=this.get(e)),this._eventBus.fire("element.updateId",{element:e,newId:t});var n=this.getGraphics(e),i=this.getGraphics(e,!0);this.remove(e),e.id=t,this.add(e,n,i)},Sn.prototype.updateGraphics=function(e,t,n){var i=e.id||e,r=this._elements[i];return n?r.secondaryGfx=t:r.gfx=t,t&&_e(t,En,i),t},Sn.prototype.get=function(e){var t;t="string"==typeof e?e:e&&_e(e,En);var n=this._elements[t];return n&&n.element},Sn.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(n)})),t},Sn.prototype.find=function(e){for(var t=this._elements,n=Object.keys(t),i=0;i<n.length;i++){var r=t[n[i]],o=r.element;if(e(o,r.gfx))return o}},Sn.prototype.getAll=function(){return this.filter((function(e){return e}))},Sn.prototype.forEach=function(e){var t=this._elements;Object.keys(t).forEach((function(n){var i=t[n],r=i.element,o=i.gfx;return e(r,o)}))},Sn.prototype.getGraphics=function(e,t){var n=e.id||e,i=this._elements[n];return i&&(t?i.secondaryGfx:i.gfx)},Sn.prototype._validateId=function(e){if(!e)throw new Error("element must have an id");if(this._elements[e])throw new Error("element with id "+e+" already added")},kn.prototype.bind=function(e,t){if("string"==typeof t){if(!this.props[t])throw new Error("no property <"+t+"> in ref");t=this.props[t]}t.collection?Cn(this,t,e):function(e,t,n){var i=t.inverse,r=n[t.name];Object.defineProperty(n,t.name,{configurable:t.configurable,enumerable:t.enumerable,get:function(){return r},set:function(t){if(t!==r){var o=r;r=null,o&&e.unset(o,i,n),r=t,e.set(r,i,n)}}})}(this,t,e)},kn.prototype.ensureRefsCollection=function(e,t){var n=e[t.name];return function(e){return!0===e.__refs_collection}(n)||Cn(this,t,e),n},kn.prototype.ensureBound=function(e,t){(function(e,t){return Object.prototype.hasOwnProperty.call(e,t.name||t)})(e,t)||this.bind(e,t)},kn.prototype.unset=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).remove(n):e[t.name]=void 0)},kn.prototype.set=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).add(n):e[t.name]=n)};var Rn=new kn({name:"children",enumerable:!0,collection:!0},{name:"parent"}),Pn=new kn({name:"labels",enumerable:!0,collection:!0},{name:"labelTarget"}),An=new kn({name:"attachers",collection:!0},{name:"host"}),Mn=new kn({name:"outgoing",collection:!0},{name:"source"}),Tn=new kn({name:"incoming",collection:!0},{name:"target"});function Dn(){Object.defineProperty(this,"businessObject",{writable:!0}),Object.defineProperty(this,"label",{get:function(){return this.labels[0]},set:function(e){var t=this.label,n=this.labels;!e&&t?n.remove(t):n.add(e,0)}}),Rn.bind(this,"parent"),Pn.bind(this,"labels"),Mn.bind(this,"outgoing"),Tn.bind(this,"incoming")}function Bn(){Dn.call(this),Rn.bind(this,"children"),An.bind(this,"host"),An.bind(this,"attachers")}function Nn(){Dn.call(this),Rn.bind(this,"children")}function jn(){Bn.call(this),Pn.bind(this,"labelTarget")}function On(){Dn.call(this),Mn.bind(this,"source"),Tn.bind(this,"target")}e(Bn,Dn),e(Nn,Bn),e(jn,Bn),e(On,Dn);var Ln={connection:On,shape:Bn,label:jn,root:Nn};function $n(){this._uid=12}$n.prototype.createRoot=function(e){return this.create("root",e)},$n.prototype.createLabel=function(e){return this.create("label",e)},$n.prototype.createShape=function(e){return this.create("shape",e)},$n.prototype.createConnection=function(e){return this.create("connection",e)},$n.prototype.create=function(e,t){return(t=L({},t||{})).id||(t.id=e+"_"+this._uid++),function(e,t){var n=Ln[e];if(!n)throw new Error("unknown type: <"+e+">");return L(new n,t)}(e,t)};var In="__fn",Fn=Array.prototype.slice;function zn(){this._listeners={},this.on("diagram.destroy",1,this._destroy,this)}function Hn(){}function Vn(e){return e.childNodes[0]}function Gn(e,t,n,i,r){var o=Be();o.setTranslate(t,n);var a=Be();a.setRotate(i||0,0,0);var s=Be();s.setScale(1,1),He(e,[o,a,s])}function Wn(e,t,n){var i=Be();i.setTranslate(t,n),He(e,i)}function Un(e,t){var n=Be();n.setRotate(t,0,0),He(e,n)}function qn(e,t){this._eventBus=e,this._elementRegistry=t}function Kn(e,t,n){var i=n||t.firstChild;e!==i&&t.insertBefore(e,i)}zn.prototype.on=function(e,t,n,i){if(e=p(e)?e:[e],h(t)&&(i=n,n=t,t=1e3),!u(t))throw new Error("priority must be a number");var r=n;i&&((r=O(n,i))[In]=n[In]||n);var o=this;e.forEach((function(e){o._addListener(e,{priority:t,callback:r,next:null})}))},zn.prototype.once=function(e,t,n,i){var r=this;if(h(t)&&(i=n,n=t,t=1e3),!u(t))throw new Error("priority must be a number");function o(){o.__isTomb=!0;var t=n.apply(i,arguments);return r.off(e,o),t}o[In]=n,this.on(e,t,o)},zn.prototype.off=function(e,t){e=p(e)?e:[e];var n=this;e.forEach((function(e){n._removeListener(e,t)}))},zn.prototype.createEvent=function(e){var t=new Hn;return t.init(e),t},zn.prototype.fire=function(e,t){var n,i,r,o;if(o=Fn.call(arguments),"object"==typeof e&&(e=(t=e).type),!e)throw new Error("no event type specified");if(i=this._listeners[e]){n=t instanceof Hn?t:this.createEvent(t),o[0]=n;var a=n.type;e!==a&&(n.type=e);try{r=this._invokeListeners(n,o,i)}finally{e!==a&&(n.type=a)}return void 0===r&&n.defaultPrevented&&(r=!1),r}},zn.prototype.handleError=function(e){return!1===this.fire("error",{error:e})},zn.prototype._destroy=function(){this._listeners={}},zn.prototype._invokeListeners=function(e,t,n){for(var i;n&&!e.cancelBubble;)i=this._invokeListener(e,t,n),n=n.next;return i},zn.prototype._invokeListener=function(e,t,n){var i;if(n.callback.__isTomb)return i;try{i=function(e,t){return e.apply(null,t)}(n.callback,t),void 0!==i&&(e.returnValue=i,e.stopPropagation()),!1===i&&e.preventDefault()}catch(e){if(!this.handleError(e))throw console.error("unhandled error in event listener",e),e}return i},zn.prototype._addListener=function(e,t){var n,i=this._getListeners(e);if(i){for(;i;){if(i.priority<t.priority)return t.next=i,void(n?n.next=t:this._setListeners(e,t));n=i,i=i.next}n.next=t}else this._setListeners(e,t)},zn.prototype._getListeners=function(e){return this._listeners[e]},zn.prototype._setListeners=function(e,t){this._listeners[e]=t},zn.prototype._removeListener=function(e,t){var n,i,r,o=this._getListeners(e);if(t)for(;o;)n=o.next,(r=o.callback)!==t&&r[In]!==t||(i?i.next=n:this._setListeners(e,n)),i=o,o=n;else this._setListeners(e,null)},Hn.prototype.stopPropagation=function(){this.cancelBubble=!0},Hn.prototype.preventDefault=function(){this.defaultPrevented=!0},Hn.prototype.init=function(e){L(this,e||{})},qn.$inject=["eventBus","elementRegistry"],qn.prototype._getChildrenContainer=function(e){var t,n=this._elementRegistry.getGraphics(e);return e.parent?(t=function(e){return e.parentNode.childNodes[1]}(n),t||(we(t=Ae("g")).add("djs-children"),ye(n.parentNode,t))):t=n,t},qn.prototype._clear=function(e){var t=Vn(e);return Q(t),t},qn.prototype._createContainer=function(e,t,n,i){var r=Ae("g");we(r).add("djs-group"),void 0!==n?Kn(r,t,t.childNodes[n]):ye(t,r);var o=Ae("g");we(o).add("djs-element"),we(o).add("djs-"+e),i&&we(o).add("djs-frame"),ye(r,o);var a=Ae("g");return we(a).add("djs-visual"),ye(o,a),o},qn.prototype.create=function(e,t,n){var i=this._getChildrenContainer(t.parent);return this._createContainer(e,i,n,mt(t))},qn.prototype.updateContainments=function(e){var t,n=this,i=this._elementRegistry;t=_(e,(function(e,t){return t.parent&&(e[t.parent.id]=t.parent),e}),{}),g(t,(function(e){var t=e.children;if(t){var r=n._getChildrenContainer(e);g(t.slice().reverse(),(function(e){Kn(i.getGraphics(e).parentNode,r)}))}}))},qn.prototype.drawShape=function(e,t,n={}){return this._eventBus.fire("render.shape",{gfx:e,element:t,attrs:n})},qn.prototype.getShapePath=function(e){return this._eventBus.fire("render.getShapePath",e)},qn.prototype.drawConnection=function(e,t,n={}){return this._eventBus.fire("render.connection",{gfx:e,element:t,attrs:n})},qn.prototype.getConnectionPath=function(e){return this._eventBus.fire("render.getConnectionPath",e)},qn.prototype.update=function(e,t,n){if(t.parent){var i=this._clear(n);if("shape"===e)this.drawShape(i,t),Wn(n,t.x,t.y);else{if("connection"!==e)throw new Error("unknown type: "+e);this.drawConnection(i,t)}t.hidden?_e(n,"display","none"):_e(n,"display","block")}},qn.prototype.remove=function(e){Fe(this._elementRegistry.getGraphics(e).parentNode)};var Yn={__depends__:[gt],__init__:["canvas"],canvas:["type",xn],elementRegistry:["type",Sn],elementFactory:["type",$n],eventBus:["type",zn],graphicsFactory:["type",qn]};function Xn(e){return function(e){var t=new Ze(e);return t.init(),t}([{config:["value",e=e||{}]},Yn].concat(e.modules||[]))}function Zn(e,t){this._injector=t||Xn(e),this.get("eventBus").fire("diagram.init")}function Qn(){}function Jn(e,t){this.model=e,this.properties=t}Zn.prototype.get=function(e,t){return this._injector.get(e,t)},Zn.prototype.invoke=function(e,t,n){return this._injector.invoke(e,t,n)},Zn.prototype.destroy=function(){this.get("eventBus").fire("diagram.destroy")},Zn.prototype.clear=function(){this.get("eventBus").fire("diagram.clear")},Qn.prototype.get=function(e){return this.$model.properties.get(this,e)},Qn.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},Jn.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(Qn.prototype);g(e.properties,(function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)})),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function o(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),g(e,O((function(e,t){this.set(t,e)}),this))}return o.prototype=i,o.hasType=i.$instanceOf=this.model.hasType,n.defineModel(o,t),n.defineDescriptor(o,e),o};var ei={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},ti={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e)}};function ni(e,t){var n=ti[e];return n?n(t):t}function ii(e){return!!ei[e]}function ri(e){return!!ti[e]}function oi(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function ai(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function si(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,g(e,O(this.registerPackage,this))}function ci(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function pi(e){this.model=e}function li(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function ui(e){return e.replace(/^:/,"")}function hi(e,t={}){this.properties=new pi(this),this.factory=new Jn(this,this.properties),this.registry=new si(e,this.properties),this.typeCache={},this.config=t}ai.prototype.build=function(){return $(this,["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"])},ai.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},ai.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,o=this.propertiesByName,a=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var s=r.indexOf(e);if(-1===s)throw new Error("property <"+i.name+"> not found in property list");r.splice(s,1),this.addProperty(t,n?void 0:s,a),o[i.name]=o[i.localName]=t},ai.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),o=oi(r[0],i),a=oi(r[1],o.prefix).name,s=this.propertiesByName[a];if(!s)throw new Error("refined property <"+a+"> not found");this.replaceProperty(s,e,n),delete e.redefines},ai.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},ai.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},ai.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},ai.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},ai.prototype.assertNotTrait=function(e){if((e.extends||[]).length)throw new Error(`cannot create <${e.name}> extending <${e.extends}>`)},ai.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},ai.prototype.hasProperty=function(e){return this.propertiesByName[e]},ai.prototype.addTrait=function(e,t){t&&this.assertNotTrait(e);var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(g(e.properties,O((function(n){n=L({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))}),this)),i.push(e),n[r]=e)},si.prototype.getPackage=function(e){return this.packageMap[e]},si.prototype.getPackages=function(){return this.packages},si.prototype.registerPackage=function(e){e=L({},e);var t=this.packageMap;ci(t,e,"prefix"),ci(t,e,"uri"),g(e.types,O((function(t){this.registerType(t,e)}),this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},si.prototype.registerType=function(e,t){var n=oi((e=L({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:L(e.meta||{})})).name,t.prefix),i=n.name,r={};g(e.properties,O((function(e){var t=oi(e.name,n.prefix),i=t.name;ii(e.type)||(e.type=oi(e.type,t.prefix).name),L(e,{ns:t,name:i}),r[i]=e}),this)),L(e,{ns:n,name:i,propertiesByName:r}),g(e.extends,O((function(e){var t=oi(e,n.prefix),r=this.typeMap[t.name];r.traits=r.traits||[],r.traits.push(i)}),this)),this.definePackage(e,t),this.typeMap[i]=e},si.prototype.mapTypes=function(e,t,n){var i=ii(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function o(n,i){var o=oi(n,ii(n)?"":e.prefix);r.mapTypes(o,t,i)}function a(e){return o(e,!0)}if(!i)throw new Error("unknown type <"+e.name+">");g(i.superClass,n?a:function(e){return o(e,!1)}),t(i,!n),g(i.traits,a)},si.prototype.getEffectiveDescriptor=function(e){var t=oi(e),n=new ai(t);this.mapTypes(t,(function(e,t){n.addTrait(e,t)}));var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},si.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},pi.prototype.set=function(e,t,n){if(!d(t)||!t.length)throw new TypeError("property name must be a non-empty string");var i=this.getProperty(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[ui(t)]:i?r in e?e[r]=n:li(e,i,n):e.$attrs[ui(t)]=n},pi.prototype.get=function(e,t){var n=this.getProperty(e,t);if(!n)return e.$attrs[ui(t)];var i=n.name;return!e[i]&&n.isMany&&li(e,n,[]),e[i]},pi.prototype.define=function(e,t,n){if(!n.writable){var i=n.value;delete(n=L({},n,{get:function(){return i}})).value}Object.defineProperty(e,t,n)},pi.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},pi.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},pi.prototype.getProperty=function(e,t){var n=this.model,i=n.getPropertyDescriptor(e,t);if(i)return i;if(t.includes(":"))return null;const r=n.config.strict;if(void 0!==r){const n=new TypeError(`unknown property <${t}> on <${e.$type}>`);if(r)throw n;"undefined"!=typeof console&&console.warn(n)}return null},hi.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},hi.prototype.getType=function(e){var t=this.typeCache,n=d(e)?e:e.ns.name,i=t[n];return i||(e=this.registry.getEffectiveDescriptor(n),i=t[n]=this.factory.createType(e)),i},hi.prototype.createAny=function(e,t,n){var i=oi(e),r={$type:e,$instanceOf:function(e){return e===this.$type},get:function(e){return this[e]},set:function(e,t){!function(e,t,n){let i=e;g(t,(function(e,r){if("number"!=typeof e&&"string"!=typeof e)throw new Error("illegal key type: "+typeof e+". Key should be of type number or string.");if("constructor"===e)throw new Error("illegal key: constructor");if("__proto__"===e)throw new Error("illegal key: __proto__");let o=t[r+1],p=i[e];s(o)&&c(p)&&(p=i[e]=isNaN(+o)?{}:[]),a(o)?a(n)?delete i[e]:i[e]=n:i=p}))}(this,[e],t)}},o={name:e,isGeneric:!0,ns:{prefix:i.prefix,localName:i.localName,uri:t}};return this.properties.defineDescriptor(r,o),this.properties.defineModel(r,this),this.properties.define(r,"get",{enumerable:!1,writable:!0}),this.properties.define(r,"set",{enumerable:!1,writable:!0}),this.properties.define(r,"$parent",{enumerable:!1,writable:!0}),this.properties.define(r,"$instanceOf",{enumerable:!1,writable:!0}),g(n,(function(e,t){l(e)&&void 0!==e.value?r[e.name]=e.value:r[t]=e})),r},hi.prototype.getPackage=function(e){return this.registry.getPackage(e)},hi.prototype.getPackages=function(){return this.registry.getPackages()},hi.prototype.getElementDescriptor=function(e){return e.$descriptor},hi.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},hi.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},hi.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var di=String.fromCharCode,fi=Object.prototype.hasOwnProperty,mi=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,vi={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function yi(e,t,n,i){return i?fi.call(vi,i)?vi[i]:"&"+i+";":di(t||parseInt(n,16))}function gi(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(mi,yi):e}Object.keys(vi).forEach((function(e){vi[e.toUpperCase()]=vi[e]}));var bi="non-whitespace outside of root node";function _i(e){return new Error(e)}function xi(e){return"missing namespace for prefix <"+e+">"}function wi(e){return{get:e,enumerable:!0}}function Ei(e){var t,n={};for(t in e)n[t]=e[t];return n}function Si(e){return e+"$uri"}function Ci(){return{line:0,column:0}}function ki(e){throw e}function Ri(e){if(!this)return new Ri(e);var t,n,i,r,o,a,s,c,p,l=e&&e.proxy,u=ki,h=Ci,d=!1,f=!1,m=null,v=!1;function y(e){e instanceof Error||(e=_i(e)),m=e,u(e,h)}function g(e){o&&(e instanceof Error||(e=_i(e)),o(e,h))}this.on=function(e,p){if("function"!=typeof p)throw _i("required args <name, cb>");switch(e){case"openTag":n=p;break;case"text":t=p;break;case"closeTag":i=p;break;case"error":u=p;break;case"warn":o=p;break;case"cdata":r=p;break;case"attention":c=p;break;case"question":s=p;break;case"comment":a=p;break;default:throw _i("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw _i("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return f=!0,p=n,this},this.parse=function(e){if("string"!=typeof e)throw _i("required args <xml=string>");return m=null,function(e){var o,u,m,b,_,x,w,E,S,C,k,R=f?[]:null,P=f?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[Si(n)]=t;return i}(p):null,A=[],M=0,T=!1,D=!1,B=0,N=0,j="",O=0;function L(){if(null!==k)return k;var e,t,n,i,r,o,a,s,c,l,u,h=f&&P.xmlns,m=f&&d?[]:null,v=O,y=j,b=y.length,_={},x={};e:for(;v<b;v++)if(c=!1,!(32===(l=y.charCodeAt(v))||l<14&&l>8)){for((l<65||l>122||l>90&&l<97)&&95!==l&&58!==l&&(g("illegal first char attribute name"),c=!0),u=v+1;u<b;u++)if(!((l=y.charCodeAt(u))>96&&l<123||l>64&&l<91||l>47&&l<59||46===l||45===l||95===l)){if(32===l||l<14&&l>8){g("missing attribute value"),v=u;continue e}if(61===l)break;g("illegal attribute name char"),c=!0}if("xmlns:xmlns"===(s=y.substring(v,u))&&(g("illegal declaration of xmlns"),c=!0),34===(l=y.charCodeAt(u+1)))-1===(u=y.indexOf('"',v=u+2))&&-1!==(u=y.indexOf("'",v))&&(g("attribute value quote missmatch"),c=!0);else if(39===l)-1===(u=y.indexOf("'",v=u+2))&&-1!==(u=y.indexOf('"',v))&&(g("attribute value quote missmatch"),c=!0);else for(g("missing attribute value quotes"),c=!0,u+=1;u<b&&!(32===(l=y.charCodeAt(u+1))||l<14&&l>8);u++);for(-1===u&&(g("missing closing quotes"),u=b,c=!0),c||(o=y.substring(v,u)),v=u;u+1<b&&!(32===(l=y.charCodeAt(u+1))||l<14&&l>8);u++)v===u&&(g("illegal character after attribute end"),c=!0);if(v=u+1,!c)if(s in x)g("attribute <"+s+"> already defined");else if(x[s]=!0,f)if(d){if(null!==(r="xmlns"===s?"xmlns":120===s.charCodeAt(0)&&"xmlns:"===s.substr(0,6)?s.substr(6):null)){if(e=gi(o),t=Si(r),!(a=p[e])){if("xmlns"===r||t in P&&P[t]!==e)do{a="ns"+M++}while(void 0!==P[a]);else a=r;p[e]=a}P[r]!==a&&(i||(P=Ei(P),i=!0),P[r]=a,"xmlns"===r&&(P[Si(a)]=e,h=a),P[t]=e),_[s]=o;continue}m.push(s,o)}else-1!==(l=s.indexOf(":"))?(n=P[s.substring(0,l)])?_[s=h===n?s.substr(l+1):n+s.substr(l)]=o:g(xi(s.substring(0,l))):_[s]=o;else _[s]=o}if(d)for(v=0,b=m.length;v<b;v++){if(s=m[v++],o=m[v],-1!==(l=s.indexOf(":"))){if(!(n=P[s.substring(0,l)])){g(xi(s.substring(0,l)));continue}s=h===n?s.substr(l+1):n+s.substr(l)}_[s]=o}return k=_}function $(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,o=0,a=0,s=N;B>=a&&(t=i.exec(e))&&!((s=t[0].length+t.index)>B);)r+=1,a=s;return-1==B?(o=s,n=e.substring(N)):0===N?n=e.substring(N,B):(o=B-a,n=-1==N?e.substring(B):e.substring(B,N+1)),{data:n,line:r,column:o}}h=$,l&&(C=Object.create({},{name:wi((function(){return E})),originalName:wi((function(){return S})),attrs:wi(L),ns:wi((function(){return P}))}));for(;-1!==N;){if(-1===(B=60===e.charCodeAt(N)?N:e.indexOf("<",N)))return A.length?y("unexpected end of file"):0===N?y("missing start tag"):void(N<e.length&&e.substring(N).trim()&&g(bi));if(N!==B)if(A.length){if(t&&(t(e.substring(N,B),gi,h),v))return}else if(e.substring(N,B).trim()&&(g(bi),v))return;if(33===(_=e.charCodeAt(B+1))){if(91===(b=e.charCodeAt(B+2))&&"CDATA["===e.substr(B+3,6)){if(-1===(N=e.indexOf("]]>",B)))return y("unclosed cdata");if(r&&(r(e.substring(B+9,N),h),v))return;N+=3;continue}if(45===b&&45===e.charCodeAt(B+3)){if(-1===(N=e.indexOf("--\x3e",B)))return y("unclosed comment");if(a&&(a(e.substring(B+4,N),gi,h),v))return;N+=3;continue}}if(63!==_){for(u=B+1;;u++){if(x=e.charCodeAt(u),isNaN(x))return N=-1,y("unclosed tag");if(34===x)u=-1!==(b=e.indexOf('"',u+1))?b:u;else if(39===x)u=-1!==(b=e.indexOf("'",u+1))?b:u;else if(62===x){N=u;break}}if(33!==_){if(k={},47===_){if(T=!1,D=!0,!A.length)return y("missing open tag");if(u=E=A.pop(),b=B+2+u.length,e.substring(B+2,b)!==u)return y("closing tag mismatch");for(;b<N;b++)if(!(32===(_=e.charCodeAt(b))||_>8&&_<14))return y("close tag")}else{if(47===e.charCodeAt(N-1)?(u=E=e.substring(B+1,N-1),T=!0,D=!0):(u=E=e.substring(B+1,N),T=!0,D=!1),!(_>96&&_<123||_>64&&_<91||95===_||58===_))return y("illegal first char nodeName");for(b=1,m=u.length;b<m;b++)if(!((_=u.charCodeAt(b))>96&&_<123||_>64&&_<91||_>47&&_<59||45===_||95===_||46==_)){if(32===_||_<14&&_>8){E=u.substring(0,b),k=null;break}return y("invalid nodeName")}D||A.push(E)}if(f){if(o=P,T&&(D||R.push(o),null===k&&(d=-1!==u.indexOf("xmlns",b))&&(O=b,j=u,L(),d=!1)),S=E,-1!==(_=E.indexOf(":"))){if(!(w=P[E.substring(0,_)]))return y("missing namespace on <"+S+">");E=E.substr(_+1)}else w=P.xmlns;w&&(E=w+":"+E)}if(T&&(O=b,j=u,n&&(l?n(C,gi,D,h):n(E,L,gi,D,h),v)))return;if(D){if(i&&(i(l?C:E,gi,T,h),v))return;f&&(P=T?o:R.pop())}N+=1}else{if(c&&(c(e.substring(B,N+1),gi,h),v))return;N+=1}}else{if(-1===(N=e.indexOf("?>",B)))return y("unclosed question");if(s&&(s(e.substring(B,N+2),h),v))return;N+=2}}}(e),h=Ci,v=!1,m},this.stop=function(){v=!0}}function Pi(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var Ai={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},Mi="property";function Ti(e){return e.xml&&e.xml.serialize}function Di(e,t){return Pi(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function Bi(e){return new Error(e)}function Ni(e){return e.$descriptor}function ji(e){L(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw Bi("expected element");var t,n=this.elementsById,i=Ni(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw Bi("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function Oi(){}function Li(){}function $i(){}function Ii(e,t){this.property=e,this.context=t}function Fi(e,t){this.element=t,this.propertyDesc=e}function zi(){}function Hi(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function Vi(e,t,n){Hi.call(this,e,t,n)}function Gi(e,t,n){this.model=e,this.context=n}function Wi(e){e instanceof hi&&(e={model:e}),L(this,{lax:!1},e)}Oi.prototype.handleEnd=function(){},Oi.prototype.handleText=function(){},Oi.prototype.handleNode=function(){},Li.prototype=Object.create(Oi.prototype),Li.prototype.handleNode=function(){return this},$i.prototype=Object.create(Oi.prototype),$i.prototype.handleText=function(e){this.body=(this.body||"")+e},Ii.prototype=Object.create($i.prototype),Ii.prototype.handleNode=function(e){if(this.element)throw Bi("expected no sub nodes");return this.element=this.createReference(e),this},Ii.prototype.handleEnd=function(){this.element.id=this.body},Ii.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},Fi.prototype=Object.create($i.prototype),Fi.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=ni(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},zi.prototype=Object.create($i.prototype),zi.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},Hi.prototype=Object.create(zi.prototype),Hi.prototype.addReference=function(e){this.context.addReference(e)},Hi.prototype.handleText=function(e){if(!Ni(this.element).bodyProperty)throw Bi("unexpected body text <"+e+">");$i.prototype.handleText.call(this,e)},Hi.prototype.handleEnd=function(){var e=this.body,t=this.element,n=Ni(t).bodyProperty;n&&void 0!==e&&(e=ni(n.type,e),t.set(n.name,e))},Hi.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=Ni(i),o=this.context,a=new i({}),s=this.model;return g(n,(function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?g(e.split(" "),(function(e){o.addReference({element:a,property:i.ns.name,id:e})})):o.addReference({element:a,property:i.ns.name,id:e}):(i?e=ni(i.type,e):"xmlns"===n?n=":"+n:(t=oi(n,r.ns.prefix),s.getPackage(t.prefix)&&o.addWarning({message:"unknown attribute <"+n+">",element:a,property:n,value:e})),a.set(n,e))})),a},Hi.prototype.getPropertyForNode=function(e){var t=oi(e.name),n=this.type,i=this.model,r=Ni(n),o=t.name,a=r.propertiesByName[o];if(a&&!a.isAttr){const t=function(e){const t=Ti(e);return t!==Mi&&(t||null)}(a);if(t){const n=e.attributes[t];if(n){const t=function(e,t,n){const i=oi(e,t.xmlns),r=oi(`${t[i.prefix]||i.prefix}:${i.localName}`);return function(e,t){var n=e.name,i=e.localName,r=t&&t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(r,n.getPackage(r.prefix))}(n,e.ns,i);return L({},a,{effectiveType:Ni(i.getType(t)).name})}}return a}var s=i.getPackage(t.prefix);if(s){const e=Di(t,s),n=i.getType(e);if(a=m(r.properties,(function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)})),a)return L({},a,{effectiveType:Ni(n).name})}else if(a=m(r.properties,(function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type})),a)return a;throw Bi("unrecognized element <"+t.name+">")},Hi.prototype.toString=function(){return"ElementDescriptor["+Ni(this.type).name+"]"},Hi.prototype.valueHandler=function(e,t){return new Fi(e,t)},Hi.prototype.referenceHandler=function(e){return new Ii(e,this.context)},Hi.prototype.handler=function(e){return"Element"===e?new Gi(this.model,e,this.context):new Hi(this.model,e,this.context)},Hi.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,ri(n=t.effectiveType||t.type))return this.valueHandler(t,i);var o=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==o&&(t.isMany?i.get(t.name).push(o):i.set(t.name,o),t.isReference?(L(o,{element:i}),this.context.addReference(o)):o.$parent=i),r},Vi.prototype=Object.create(Hi.prototype),Vi.prototype.createElement=function(e){var t=e.name,n=oi(t),i=this.model,r=this.type,o=i.getPackage(n.prefix),a=o&&Di(n,o)||t;if(!r.hasType(a))throw Bi("unexpected element <"+e.originalName+">");return Hi.prototype.createElement.call(this,e)},Gi.prototype=Object.create(zi.prototype),Gi.prototype.createElement=function(e){var t=e.name,n=oi(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},Gi.prototype.handleChild=function(e){var t=new Gi(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},Gi.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},Wi.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof Hi?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,o=this.lax,a=new ji(L({},t,{rootHandler:i})),s=new Ri({proxy:!0}),c=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function p(e,t,n){var i=t(),r=i.line,o=i.column,s=i.data;"<"===s.charAt(0)&&-1!==s.indexOf(" ")&&(s=s.slice(0,s.indexOf(" "))+">");var c="unparsable content "+(s?s+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+o+"\n\tnested error: "+e.message;if(n)return a.addWarning({message:c,error:e}),!0;throw Bi(c)}function l(e,t){return p(e,t,!0)}i.context=a,c.push(i);var u=/^<\?xml /i,h=/ encoding="([^"]+)"/i,d=/^utf-8$/i;function f(e,t){try{c.peek().handleText(e)}catch(e){l(e,t)}}var m=r.getPackages().reduce((function(e,t){return e[t.uri]=t.prefix,e}),Object.entries(Ai).reduce((function(e,[t,n]){return e[n]=t,e}),r.config&&r.config.nsMap||{}));return s.ns(m).on("openTag",(function(e,t,n,i){var r=e.attrs||{},a=Object.keys(r).reduce((function(e,n){var i=t(r[n]);return e[n]=i,e}),{});!function(e,t){var n=c.peek();try{c.push(n.handleNode(e))}catch(e){p(e,t,o)&&c.push(new Li)}}({name:e.name,originalName:e.originalName,attributes:a,ns:e.ns},i)})).on("question",(function(e){if(u.test(e)){var t=h.exec(e),n=t&&t[1];n&&!d.test(n)&&a.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}})).on("closeTag",(function(){c.pop().handleEnd()})).on("cdata",f).on("text",(function(e,t,n){!function(e,t){e.trim()&&f(e,t)}(t(e),n)})).on("error",p).on("warn",l),new Promise((function(t,n){var r;try{s.parse(e),function(){var e,t,n=a.elementsById,i=a.references;for(e=0;t=i[e];e++){var r=t.element,o=n[t.id],s=Ni(r).propertiesByName[t.property];if(o||a.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),s.isMany){var c=r.get(s.name),p=c.indexOf(t);-1===p&&(p=c.length),o?c[p]=o:c.splice(p,1)}else r.set(s.name,o)}}()}catch(e){r=e}var o=i.element;r||o||(r=Bi("failed to parse document as <"+i.type.$descriptor.name+">"));var c=a.warnings,p=a.references,l=a.elementsById;return r?(r.warnings=c,n(r)):t({rootElement:o,elementsById:l,references:p,warnings:c})}))},Wi.prototype.handler=function(e){return new Vi(this.model,e)};var Ui=/<|>|'|"|&|\n\r|\n/g,qi=/<|>|&/g;function Ki(e){this.prefixMap={},this.uriMap={},this.used={},this.wellknown=[],this.custom=[],this.parent=e,this.defaultPrefixMap=e&&e.defaultPrefixMap||{}}function Yi(e,t){return Pi(t)?(n=e).charAt(0).toLowerCase()+n.slice(1):e;var n}function Xi(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function Zi(e){return d(e)?e:(e.prefix?e.prefix+":":"")+e.localName}Ki.prototype.mapDefaultPrefixes=function(e){this.defaultPrefixMap=e},Ki.prototype.defaultUriByPrefix=function(e){return this.defaultPrefixMap[e]},Ki.prototype.byUri=function(e){return this.uriMap[e]||this.parent&&this.parent.byUri(e)},Ki.prototype.add=function(e,t){this.uriMap[e.uri]=e,t?this.wellknown.push(e):this.custom.push(e),this.mapPrefix(e.prefix,e.uri)},Ki.prototype.uriByPrefix=function(e){return this.prefixMap[e||"xmlns"]||this.parent&&this.parent.uriByPrefix(e)},Ki.prototype.mapPrefix=function(e,t){this.prefixMap[e||"xmlns"]=t},Ki.prototype.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},Ki.prototype.logUsed=function(e){var t=e.uri,n=this.getNSKey(e);this.used[n]=this.byUri(t),this.parent&&this.parent.logUsed(e)},Ki.prototype.getUsed=function(e){return[].concat(this.wellknown,this.custom).filter((e=>{var t=this.getNSKey(e);return this.used[t]}))};var Qi={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},Ji={"<":"lt",">":"gt","&":"amp"};function er(e,t,n){return(e=d(e)?e:""+e).replace(t,(function(e){return"&"+n[e]+";"}))}function tr(e){this.tagName=e}function nr(){}function ir(e){this.tagName=e}function rr(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function or(e,t,n){rr.call(this,e,t),this.serialization=n}function ar(){this.value="",this.write=function(e){this.value+=e}}function sr(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function cr(e){return e=L({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new ar,r=new sr(i,e.format);e.preamble&&r.append('<?xml version="1.0" encoding="UTF-8"?>\n');var o=new rr,a=t.$model;if(o.getNamespaces().mapDefaultPrefixes(function(e){const t=e.config&&e.config.nsMap||{},n={};for(const e in Ai)n[e]=Ai[e];for(const e in t){n[t[e]]=e}for(const t of e.getPackages())n[t.prefix]=t.uri;return n}(a)),o.build(t).serializeTo(r),!n)return i.value}}}function pr(e,t){hi.call(this,e,t)}tr.prototype.build=function(e){return this.element=e,this},tr.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},nr.prototype.serializeValue=nr.prototype.serializeTo=function(e){e.append(this.escape?er(this.value,qi,Ji):this.value)},nr.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(qi)&&(this.escape=!0),this},Xi(ir,nr),ir.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},rr.prototype.build=function(e){this.element=e;var t,n,i=e.$descriptor,r=this.propertyDescriptor,o=i.isGeneric;return t=o?this.parseGenericNsAttributes(e):this.parseNsAttributes(e),this.ns=r?this.nsPropertyTagName(r):this.nsTagName(i),this.tagName=this.addTagName(this.ns),o?this.parseGenericContainments(e):(n=function(e){return y(e.$descriptor.properties,(function(t){var n=t.name;if(t.isVirtual)return!1;if(!f(e,n))return!1;var i=e[n];return i!==t.default&&null!==i&&(!t.isMany||i.length)}))}(e),this.parseAttributes(y(n,(function(e){return e.isAttr}))),this.parseContainments(function(e){return y(e,(function(e){return!e.isAttr}))}(n))),this.parseGenericAttributes(e,t),this},rr.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?L({localName:t.ns.localName},e):L({localName:Yi(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},rr.prototype.nsPropertyTagName=function(e){return function(e,t){return L({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},rr.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},rr.prototype.nsAttributeName=function(e){var t;if(t=d(e)?oi(e):e.ns,e.inherited)return{localName:t.localName};var n=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(n),this.isLocalNs(n)?{localName:t.localName}:L({localName:t.localName},n)},rr.prototype.parseGenericNsAttributes=function(e){return Object.entries(e).filter((([t,n])=>!t.startsWith("$")&&this.parseNsAttribute(e,t,n))).map((([e,t])=>({name:e,value:t})))},rr.prototype.parseGenericContainments=function(e){var t=e.$body;t&&this.body.push((new nr).build({type:"String"},t));var n=e.$children;n&&g(n,(e=>{this.body.push(new rr(this).build(e))}))},rr.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,o=oi(t);if("xmlns"===o.prefix&&(i={prefix:o.localName,uri:n}),o.prefix||"xmlns"!==o.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var a=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(a)}},rr.prototype.parseNsAttributes=function(e){var t=this,n=e.$attrs,i=[];return g(n,(function(n,r){var o=t.parseNsAttribute(e,r,n);o&&i.push(o)})),i},rr.prototype.parseGenericAttributes=function(e,t){var n=this;g(t,(function(t){try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){"undefined"!=typeof console&&console.warn(`missing namespace information for <${t.name}=${t.value}> on`,e,n)}}))},rr.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;g(e,(function(e){var r=i.get(e.name),o=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new nr).build(e,r[0]));else if(ri(e.type))g(r,(function(i){n.push(new ir(t.addTagName(t.nsPropertyTagName(e))).build(e,i))}));else if(o)g(r,(function(i){n.push(new tr(t.addTagName(t.nsPropertyTagName(e))).build(i))}));else{var a=Ti(e);g(r,(function(i){var r;r=a?a===Mi?new rr(t,e):new or(t,e,a):new rr(t),n.push(r.build(i))}))}}))},rr.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new Ki(t):n=t),n},rr.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,o=e.prefix;return i.byUri(r)&&!n||i.add(e,t),i.mapPrefix(o,r),e},rr.prototype.logNamespaceUsed=function(e,t){var n,i,r,o=this.getNamespaces(t),a=e.prefix,s=e.uri;if(!a&&!s)return{localName:e.localName};if(r=o.defaultUriByPrefix(a),!(s=s||r||o.uriByPrefix(a)))throw new Error("no namespace uri given for prefix <"+a+">");if((e=o.byUri(s))||a||(e=this.logNamespace({uri:s},r===s,!0)),!e){for(n=a,i=1;o.uriByPrefix(n);)n=a+"_"+i++;e=this.logNamespace({prefix:n,uri:s},r===s)}return a&&o.mapPrefix(a,s),e},rr.prototype.parseAttributes=function(e){var t=this,n=this.element;g(e,(function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];g(i,(function(e){r.push(e.id)})),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)}))},rr.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),Zi(e)},rr.prototype.addAttribute=function(e,t){var n=this.attrs;d(t)&&(t=er(t,Ui,Qi));var i=v(n,(function(t){return t.name.localName===e.localName&&t.name.uri===e.uri&&t.name.prefix===e.prefix})),r={name:e,value:t};-1!==i?n.splice(i,1,r):n.push(r)},rr.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=function(e){return e.getUsed().filter((function(e){return"xml"!==e.prefix})).map((function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}}))}(n).concat(t)),g(t,(function(t){e.append(" ").append(Zi(t.name)).append('="').append(t.value).append('"')}))},rr.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==nr;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),g(this.body,(function(t){t.serializeTo(e)})),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},Xi(or,rr),or.prototype.parseNsAttributes=function(e){var t=rr.prototype.parseNsAttributes.call(this,e).filter((e=>e.name!==this.serialization)),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),o=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(this.serialization),(i.prefix?i.prefix+":":"")+o+n.ns.localName),t},or.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},pr.prototype=Object.create(hi.prototype),pr.prototype.fromXML=function(e,t,n){d(t)||(n=t,t="bpmn:Definitions");var i=new Wi(L({model:this,lax:!0},n)),r=i.handler(t);return i.fromXML(e,r)},pr.prototype.toXML=function(e,t){var n=new cr(t);return new Promise((function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}}))};const lr={bpmn:{name:"BPMN20",uri:"http://www.omg.org/spec/BPMN/20100524/MODEL",prefix:"bpmn",associations:[],types:[{name:"Interface",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"operations",type:"Operation",isMany:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"Operation",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"inMessageRef",type:"Message",isReference:!0},{name:"outMessageRef",type:"Message",isReference:!0},{name:"errorRef",type:"Error",isMany:!0,isReference:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"EndPoint",superClass:["RootElement"]},{name:"Auditing",superClass:["BaseElement"]},{name:"GlobalTask",superClass:["CallableElement"],properties:[{name:"resources",type:"ResourceRole",isMany:!0}]},{name:"Monitoring",superClass:["BaseElement"]},{name:"Performer",superClass:["ResourceRole"]},{name:"Process",superClass:["FlowElementsContainer","CallableElement"],properties:[{name:"processType",type:"ProcessType",isAttr:!0},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"properties",type:"Property",isMany:!0},{name:"laneSets",isMany:!0,replaces:"FlowElementsContainer#laneSets",type:"LaneSet"},{name:"flowElements",isMany:!0,replaces:"FlowElementsContainer#flowElements",type:"FlowElement"},{name:"artifacts",type:"Artifact",isMany:!0},{name:"resources",type:"ResourceRole",isMany:!0},{name:"correlationSubscriptions",type:"CorrelationSubscription",isMany:!0},{name:"supports",type:"Process",isMany:!0,isReference:!0},{name:"definitionalCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"isExecutable",isAttr:!0,type:"Boolean"}]},{name:"LaneSet",superClass:["BaseElement"],properties:[{name:"lanes",type:"Lane",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Lane",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"partitionElementRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"partitionElement",type:"BaseElement"},{name:"flowNodeRef",type:"FlowNode",isMany:!0,isReference:!0},{name:"childLaneSet",type:"LaneSet",xml:{serialize:"xsi:type"}}]},{name:"GlobalManualTask",superClass:["GlobalTask"]},{name:"ManualTask",superClass:["Task"]},{name:"UserTask",superClass:["Task"],properties:[{name:"renderings",type:"Rendering",isMany:!0},{name:"implementation",isAttr:!0,type:"String"}]},{name:"Rendering",superClass:["BaseElement"]},{name:"HumanPerformer",superClass:["Performer"]},{name:"PotentialOwner",superClass:["HumanPerformer"]},{name:"GlobalUserTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"renderings",type:"Rendering",isMany:!0}]},{name:"Gateway",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"gatewayDirection",type:"GatewayDirection",default:"Unspecified",isAttr:!0}]},{name:"EventBasedGateway",superClass:["Gateway"],properties:[{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"eventGatewayType",type:"EventBasedGatewayType",isAttr:!0,default:"Exclusive"}]},{name:"ComplexGateway",superClass:["Gateway"],properties:[{name:"activationCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ExclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"InclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ParallelGateway",superClass:["Gateway"]},{name:"RootElement",isAbstract:!0,superClass:["BaseElement"]},{name:"Relationship",superClass:["BaseElement"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"direction",type:"RelationshipDirection",isAttr:!0},{name:"source",isMany:!0,isReference:!0,type:"Element"},{name:"target",isMany:!0,isReference:!0,type:"Element"}]},{name:"BaseElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,type:"String",isId:!0},{name:"documentation",type:"Documentation",isMany:!0},{name:"extensionDefinitions",type:"ExtensionDefinition",isMany:!0,isReference:!0},{name:"extensionElements",type:"ExtensionElements"}]},{name:"Extension",properties:[{name:"mustUnderstand",default:!1,isAttr:!0,type:"Boolean"},{name:"definition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"extensionAttributeDefinitions",type:"ExtensionAttributeDefinition",isMany:!0}]},{name:"ExtensionAttributeDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"type",isAttr:!0,type:"String"},{name:"isReference",default:!1,isAttr:!0,type:"Boolean"},{name:"extensionDefinition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionElements",properties:[{name:"valueRef",isAttr:!0,isReference:!0,type:"Element"},{name:"values",type:"Element",isMany:!0},{name:"extensionAttributeDefinition",type:"ExtensionAttributeDefinition",isAttr:!0,isReference:!0}]},{name:"Documentation",superClass:["BaseElement"],properties:[{name:"text",type:"String",isBody:!0},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Event",isAbstract:!0,superClass:["FlowNode","InteractionNode"],properties:[{name:"properties",type:"Property",isMany:!0}]},{name:"IntermediateCatchEvent",superClass:["CatchEvent"]},{name:"IntermediateThrowEvent",superClass:["ThrowEvent"]},{name:"EndEvent",superClass:["ThrowEvent"]},{name:"StartEvent",superClass:["CatchEvent"],properties:[{name:"isInterrupting",default:!0,isAttr:!0,type:"Boolean"}]},{name:"ThrowEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"inputSet",type:"InputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"CatchEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"parallelMultiple",isAttr:!0,type:"Boolean",default:!1},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"outputSet",type:"OutputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"BoundaryEvent",superClass:["CatchEvent"],properties:[{name:"cancelActivity",default:!0,isAttr:!0,type:"Boolean"},{name:"attachedToRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"EventDefinition",isAbstract:!0,superClass:["RootElement"]},{name:"CancelEventDefinition",superClass:["EventDefinition"]},{name:"ErrorEventDefinition",superClass:["EventDefinition"],properties:[{name:"errorRef",type:"Error",isAttr:!0,isReference:!0}]},{name:"TerminateEventDefinition",superClass:["EventDefinition"]},{name:"EscalationEventDefinition",superClass:["EventDefinition"],properties:[{name:"escalationRef",type:"Escalation",isAttr:!0,isReference:!0}]},{name:"Escalation",properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"escalationCode",isAttr:!0,type:"String"}],superClass:["RootElement"]},{name:"CompensateEventDefinition",superClass:["EventDefinition"],properties:[{name:"waitForCompletion",isAttr:!0,type:"Boolean",default:!0},{name:"activityRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"TimerEventDefinition",superClass:["EventDefinition"],properties:[{name:"timeDate",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeCycle",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeDuration",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"LinkEventDefinition",superClass:["EventDefinition"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"target",type:"LinkEventDefinition",isReference:!0},{name:"source",type:"LinkEventDefinition",isMany:!0,isReference:!0}]},{name:"MessageEventDefinition",superClass:["EventDefinition"],properties:[{name:"messageRef",type:"Message",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"ConditionalEventDefinition",superClass:["EventDefinition"],properties:[{name:"condition",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"SignalEventDefinition",superClass:["EventDefinition"],properties:[{name:"signalRef",type:"Signal",isAttr:!0,isReference:!0}]},{name:"Signal",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ImplicitThrowEvent",superClass:["ThrowEvent"]},{name:"DataState",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ItemAwareElement",superClass:["BaseElement"],properties:[{name:"itemSubjectRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"dataState",type:"DataState"}]},{name:"DataAssociation",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"ItemAwareElement",isMany:!0,isReference:!0},{name:"targetRef",type:"ItemAwareElement",isReference:!0},{name:"transformation",type:"FormalExpression",xml:{serialize:"property"}},{name:"assignment",type:"Assignment",isMany:!0}]},{name:"DataInput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"inputSetRef",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithOptional",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithWhileExecuting",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"DataOutput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"outputSetRef",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithOptional",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithWhileExecuting",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"InputSet",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"dataInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"optionalInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"whileExecutingInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"outputSetRefs",type:"OutputSet",isMany:!0,isReference:!0}]},{name:"OutputSet",superClass:["BaseElement"],properties:[{name:"dataOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"inputSetRefs",type:"InputSet",isMany:!0,isReference:!0},{name:"optionalOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"whileExecutingOutputRefs",type:"DataOutput",isMany:!0,isReference:!0}]},{name:"Property",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"DataInputAssociation",superClass:["DataAssociation"]},{name:"DataOutputAssociation",superClass:["DataAssociation"]},{name:"InputOutputSpecification",superClass:["BaseElement"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"inputSets",type:"InputSet",isMany:!0},{name:"outputSets",type:"OutputSet",isMany:!0}]},{name:"DataObject",superClass:["FlowElement","ItemAwareElement"],properties:[{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"}]},{name:"InputOutputBinding",properties:[{name:"inputDataRef",type:"InputSet",isAttr:!0,isReference:!0},{name:"outputDataRef",type:"OutputSet",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"Assignment",superClass:["BaseElement"],properties:[{name:"from",type:"Expression",xml:{serialize:"xsi:type"}},{name:"to",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"DataStore",superClass:["RootElement","ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"capacity",isAttr:!0,type:"Integer"},{name:"isUnlimited",default:!0,isAttr:!0,type:"Boolean"}]},{name:"DataStoreReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataStoreRef",type:"DataStore",isAttr:!0,isReference:!0}]},{name:"DataObjectReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataObjectRef",type:"DataObject",isAttr:!0,isReference:!0}]},{name:"ConversationLink",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ConversationAssociation",superClass:["BaseElement"],properties:[{name:"innerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0},{name:"outerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0}]},{name:"CallConversation",superClass:["ConversationNode"],properties:[{name:"calledCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"Conversation",superClass:["ConversationNode"]},{name:"SubConversation",superClass:["ConversationNode"],properties:[{name:"conversationNodes",type:"ConversationNode",isMany:!0}]},{name:"ConversationNode",isAbstract:!0,superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"messageFlowRefs",type:"MessageFlow",isMany:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0}]},{name:"GlobalConversation",superClass:["Collaboration"]},{name:"PartnerEntity",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"PartnerRole",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"CorrelationProperty",superClass:["RootElement"],properties:[{name:"correlationPropertyRetrievalExpression",type:"CorrelationPropertyRetrievalExpression",isMany:!0},{name:"name",isAttr:!0,type:"String"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Error",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"errorCode",isAttr:!0,type:"String"}]},{name:"CorrelationKey",superClass:["BaseElement"],properties:[{name:"correlationPropertyRef",type:"CorrelationProperty",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Expression",superClass:["BaseElement"],isAbstract:!1,properties:[{name:"body",isBody:!0,type:"String"}]},{name:"FormalExpression",superClass:["Expression"],properties:[{name:"language",isAttr:!0,type:"String"},{name:"evaluatesToTypeRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Message",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"itemRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"ItemDefinition",superClass:["RootElement"],properties:[{name:"itemKind",type:"ItemKind",isAttr:!0},{name:"structureRef",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"import",type:"Import",isAttr:!0,isReference:!0}]},{name:"FlowElement",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"categoryValueRef",type:"CategoryValue",isMany:!0,isReference:!0}]},{name:"SequenceFlow",superClass:["FlowElement"],properties:[{name:"isImmediate",isAttr:!0,type:"Boolean"},{name:"conditionExpression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"sourceRef",type:"FlowNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"FlowNode",isAttr:!0,isReference:!0}]},{name:"FlowElementsContainer",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"laneSets",type:"LaneSet",isMany:!0},{name:"flowElements",type:"FlowElement",isMany:!0}]},{name:"CallableElement",isAbstract:!0,superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"supportedInterfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"ioBinding",type:"InputOutputBinding",isMany:!0,xml:{serialize:"property"}}]},{name:"FlowNode",isAbstract:!0,superClass:["FlowElement"],properties:[{name:"incoming",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"outgoing",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"lanes",type:"Lane",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"CorrelationPropertyRetrievalExpression",superClass:["BaseElement"],properties:[{name:"messagePath",type:"FormalExpression"},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"CorrelationPropertyBinding",superClass:["BaseElement"],properties:[{name:"dataPath",type:"FormalExpression"},{name:"correlationPropertyRef",type:"CorrelationProperty",isAttr:!0,isReference:!0}]},{name:"Resource",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"resourceParameters",type:"ResourceParameter",isMany:!0}]},{name:"ResourceParameter",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isRequired",isAttr:!0,type:"Boolean"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"CorrelationSubscription",superClass:["BaseElement"],properties:[{name:"correlationKeyRef",type:"CorrelationKey",isAttr:!0,isReference:!0},{name:"correlationPropertyBinding",type:"CorrelationPropertyBinding",isMany:!0}]},{name:"MessageFlow",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"MessageFlowAssociation",superClass:["BaseElement"],properties:[{name:"innerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0},{name:"outerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0}]},{name:"InteractionNode",isAbstract:!0,properties:[{name:"incomingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0},{name:"outgoingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"Participant",superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"interfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"participantMultiplicity",type:"ParticipantMultiplicity"},{name:"endPointRefs",type:"EndPoint",isMany:!0,isReference:!0},{name:"processRef",type:"Process",isAttr:!0,isReference:!0}]},{name:"ParticipantAssociation",superClass:["BaseElement"],properties:[{name:"innerParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"outerParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"ParticipantMultiplicity",properties:[{name:"minimum",default:0,isAttr:!0,type:"Integer"},{name:"maximum",default:1,isAttr:!0,type:"Integer"}],superClass:["BaseElement"]},{name:"Collaboration",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"participants",type:"Participant",isMany:!0},{name:"messageFlows",type:"MessageFlow",isMany:!0},{name:"artifacts",type:"Artifact",isMany:!0},{name:"conversations",type:"ConversationNode",isMany:!0},{name:"conversationAssociations",type:"ConversationAssociation"},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0},{name:"messageFlowAssociations",type:"MessageFlowAssociation",isMany:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"choreographyRef",type:"Choreography",isMany:!0,isReference:!0},{name:"conversationLinks",type:"ConversationLink",isMany:!0}]},{name:"ChoreographyActivity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"loopType",type:"ChoreographyLoopType",default:"None",isAttr:!0}]},{name:"CallChoreography",superClass:["ChoreographyActivity"],properties:[{name:"calledChoreographyRef",type:"Choreography",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"SubChoreography",superClass:["ChoreographyActivity","FlowElementsContainer"],properties:[{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"ChoreographyTask",superClass:["ChoreographyActivity"],properties:[{name:"messageFlowRef",type:"MessageFlow",isMany:!0,isReference:!0}]},{name:"Choreography",superClass:["Collaboration","FlowElementsContainer"]},{name:"GlobalChoreographyTask",superClass:["Choreography"],properties:[{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Group",superClass:["Artifact"],properties:[{name:"categoryValueRef",type:"CategoryValue",isAttr:!0,isReference:!0}]},{name:"Association",superClass:["Artifact"],properties:[{name:"associationDirection",type:"AssociationDirection",isAttr:!0},{name:"sourceRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"targetRef",type:"BaseElement",isAttr:!0,isReference:!0}]},{name:"Category",superClass:["RootElement"],properties:[{name:"categoryValue",type:"CategoryValue",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Artifact",isAbstract:!0,superClass:["BaseElement"]},{name:"CategoryValue",superClass:["BaseElement"],properties:[{name:"categorizedFlowElements",type:"FlowElement",isMany:!0,isVirtual:!0,isReference:!0},{name:"value",isAttr:!0,type:"String"}]},{name:"Activity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"isForCompensation",default:!1,isAttr:!0,type:"Boolean"},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"boundaryEventRefs",type:"BoundaryEvent",isMany:!0,isReference:!0},{name:"properties",type:"Property",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"startQuantity",default:1,isAttr:!0,type:"Integer"},{name:"resources",type:"ResourceRole",isMany:!0},{name:"completionQuantity",default:1,isAttr:!0,type:"Integer"},{name:"loopCharacteristics",type:"LoopCharacteristics"}]},{name:"ServiceTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"SubProcess",superClass:["Activity","FlowElementsContainer","InteractionNode"],properties:[{name:"triggeredByEvent",default:!1,isAttr:!0,type:"Boolean"},{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"LoopCharacteristics",isAbstract:!0,superClass:["BaseElement"]},{name:"MultiInstanceLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"isSequential",default:!1,isAttr:!0,type:"Boolean"},{name:"behavior",type:"MultiInstanceBehavior",default:"All",isAttr:!0},{name:"loopCardinality",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopDataInputRef",type:"ItemAwareElement",isReference:!0},{name:"loopDataOutputRef",type:"ItemAwareElement",isReference:!0},{name:"inputDataItem",type:"DataInput",xml:{serialize:"property"}},{name:"outputDataItem",type:"DataOutput",xml:{serialize:"property"}},{name:"complexBehaviorDefinition",type:"ComplexBehaviorDefinition",isMany:!0},{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"oneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0},{name:"noneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0}]},{name:"StandardLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"testBefore",default:!1,isAttr:!0,type:"Boolean"},{name:"loopCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopMaximum",type:"Integer",isAttr:!0}]},{name:"CallActivity",superClass:["Activity","InteractionNode"],properties:[{name:"calledElement",type:"String",isAttr:!0}]},{name:"Task",superClass:["Activity","InteractionNode"]},{name:"SendTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ReceiveTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ScriptTask",superClass:["Task"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"script",type:"String"}]},{name:"BusinessRuleTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"AdHocSubProcess",superClass:["SubProcess"],properties:[{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"ordering",type:"AdHocOrdering",isAttr:!0},{name:"cancelRemainingInstances",default:!0,isAttr:!0,type:"Boolean"}]},{name:"Transaction",superClass:["SubProcess"],properties:[{name:"protocol",isAttr:!0,type:"String"},{name:"method",isAttr:!0,type:"String"}]},{name:"GlobalScriptTask",superClass:["GlobalTask"],properties:[{name:"scriptLanguage",isAttr:!0,type:"String"},{name:"script",isAttr:!0,type:"String"}]},{name:"GlobalBusinessRuleTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"ComplexBehaviorDefinition",superClass:["BaseElement"],properties:[{name:"condition",type:"FormalExpression"},{name:"event",type:"ImplicitThrowEvent"}]},{name:"ResourceRole",superClass:["BaseElement"],properties:[{name:"resourceRef",type:"Resource",isReference:!0},{name:"resourceParameterBindings",type:"ResourceParameterBinding",isMany:!0},{name:"resourceAssignmentExpression",type:"ResourceAssignmentExpression"},{name:"name",isAttr:!0,type:"String"}]},{name:"ResourceParameterBinding",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"parameterRef",type:"ResourceParameter",isAttr:!0,isReference:!0}],superClass:["BaseElement"]},{name:"ResourceAssignmentExpression",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}}],superClass:["BaseElement"]},{name:"Import",properties:[{name:"importType",isAttr:!0,type:"String"},{name:"location",isAttr:!0,type:"String"},{name:"namespace",isAttr:!0,type:"String"}]},{name:"Definitions",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"targetNamespace",isAttr:!0,type:"String"},{name:"expressionLanguage",default:"http://www.w3.org/1999/XPath",isAttr:!0,type:"String"},{name:"typeLanguage",default:"http://www.w3.org/2001/XMLSchema",isAttr:!0,type:"String"},{name:"imports",type:"Import",isMany:!0},{name:"extensions",type:"Extension",isMany:!0},{name:"rootElements",type:"RootElement",isMany:!0},{name:"diagrams",isMany:!0,type:"bpmndi:BPMNDiagram"},{name:"exporter",isAttr:!0,type:"String"},{name:"relationships",type:"Relationship",isMany:!0},{name:"exporterVersion",isAttr:!0,type:"String"}]}],enumerations:[{name:"ProcessType",literalValues:[{name:"None"},{name:"Public"},{name:"Private"}]},{name:"GatewayDirection",literalValues:[{name:"Unspecified"},{name:"Converging"},{name:"Diverging"},{name:"Mixed"}]},{name:"EventBasedGatewayType",literalValues:[{name:"Parallel"},{name:"Exclusive"}]},{name:"RelationshipDirection",literalValues:[{name:"None"},{name:"Forward"},{name:"Backward"},{name:"Both"}]},{name:"ItemKind",literalValues:[{name:"Physical"},{name:"Information"}]},{name:"ChoreographyLoopType",literalValues:[{name:"None"},{name:"Standard"},{name:"MultiInstanceSequential"},{name:"MultiInstanceParallel"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"MultiInstanceBehavior",literalValues:[{name:"None"},{name:"One"},{name:"All"},{name:"Complex"}]},{name:"AdHocOrdering",literalValues:[{name:"Parallel"},{name:"Sequential"}]}],xml:{tagAlias:"lowerCase",typePrefix:"t"}},bpmndi:{name:"BPMNDI",uri:"http://www.omg.org/spec/BPMN/20100524/DI",prefix:"bpmndi",types:[{name:"BPMNDiagram",properties:[{name:"plane",type:"BPMNPlane",redefines:"di:Diagram#rootElement"},{name:"labelStyle",type:"BPMNLabelStyle",isMany:!0}],superClass:["di:Diagram"]},{name:"BPMNPlane",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"}],superClass:["di:Plane"]},{name:"BPMNShape",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"isHorizontal",isAttr:!0,type:"Boolean"},{name:"isExpanded",isAttr:!0,type:"Boolean"},{name:"isMarkerVisible",isAttr:!0,type:"Boolean"},{name:"label",type:"BPMNLabel"},{name:"isMessageVisible",isAttr:!0,type:"Boolean"},{name:"participantBandKind",type:"ParticipantBandKind",isAttr:!0},{name:"choreographyActivityShape",type:"BPMNShape",isAttr:!0,isReference:!0}],superClass:["di:LabeledShape"]},{name:"BPMNEdge",properties:[{name:"label",type:"BPMNLabel"},{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"sourceElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#source"},{name:"targetElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#target"},{name:"messageVisibleKind",type:"MessageVisibleKind",isAttr:!0,default:"initiating"}],superClass:["di:LabeledEdge"]},{name:"BPMNLabel",properties:[{name:"labelStyle",type:"BPMNLabelStyle",isAttr:!0,isReference:!0,redefines:"di:DiagramElement#style"}],superClass:["di:Label"]},{name:"BPMNLabelStyle",properties:[{name:"font",type:"dc:Font"}],superClass:["di:Style"]}],enumerations:[{name:"ParticipantBandKind",literalValues:[{name:"top_initiating"},{name:"middle_initiating"},{name:"bottom_initiating"},{name:"top_non_initiating"},{name:"middle_non_initiating"},{name:"bottom_non_initiating"}]},{name:"MessageVisibleKind",literalValues:[{name:"initiating"},{name:"non_initiating"}]}],associations:[]},dc:{name:"DC",uri:"http://www.omg.org/spec/DD/20100524/DC",prefix:"dc",types:[{name:"Boolean"},{name:"Integer"},{name:"Real"},{name:"String"},{name:"Font",properties:[{name:"name",type:"String",isAttr:!0},{name:"size",type:"Real",isAttr:!0},{name:"isBold",type:"Boolean",isAttr:!0},{name:"isItalic",type:"Boolean",isAttr:!0},{name:"isUnderline",type:"Boolean",isAttr:!0},{name:"isStrikeThrough",type:"Boolean",isAttr:!0}]},{name:"Point",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0}]},{name:"Bounds",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0},{name:"width",type:"Real",isAttr:!0},{name:"height",type:"Real",isAttr:!0}]}],associations:[]},di:{name:"DI",uri:"http://www.omg.org/spec/DD/20100524/DI",prefix:"di",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"extension",type:"Extension"},{name:"owningDiagram",type:"Diagram",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"owningElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"modelElement",isReadOnly:!0,isVirtual:!0,isReference:!0,type:"Element"},{name:"style",type:"Style",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"ownedElement",type:"DiagramElement",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Node",isAbstract:!0,superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,superClass:["DiagramElement"],properties:[{name:"source",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"target",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"waypoint",isUnique:!1,isMany:!0,type:"dc:Point",xml:{serialize:"xsi:type"}}]},{name:"Diagram",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"rootElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0},{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"},{name:"ownedStyle",type:"Style",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Shape",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Plane",isAbstract:!0,superClass:["Node"],properties:[{name:"planeElement",type:"DiagramElement",subsettedProperty:"DiagramElement-ownedElement",isMany:!0}]},{name:"LabeledEdge",isAbstract:!0,superClass:["Edge"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"LabeledShape",isAbstract:!0,superClass:["Shape"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"Label",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],xml:{tagAlias:"lowerCase"}},bioc:{name:"bpmn.io colors for BPMN",uri:"http://bpmn.io/schema/bpmn/biocolor/1.0",prefix:"bioc",types:[{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]},color:{name:"BPMN in Color",uri:"http://www.omg.org/spec/BPMN/non-normative/color/1.0",prefix:"color",types:[{name:"ColoredLabel",extends:["bpmndi:BPMNLabel"],properties:[{name:"color",isAttr:!0,type:"String"}]},{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"background-color",isAttr:!0,type:"String"},{name:"border-color",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"border-color",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]}};function ur(e,t){return new pr(L({},lr,e),t)}function hr(e){return e?"<"+e.$type+(e.id?' id="'+e.id:"")+'" />':"<null>"}function dr(e){f(e,"di")||Object.defineProperty(e,"di",{enumerable:!1,get:function(){throw new Error("Tried to access di from the businessObject. The di is available through the diagram element only. For more information, see https://github.com/bpmn-io/bpmn-js/issues/1472")}})}function fr(e,t){return e.$instanceOf(t)}function mr(e){var t={},n=[],i={};function r(e,t){return function(n){e(n,t)}}function o(e){t[e.id]=e}function a(t,n){try{var r=i[t.id]&&function(t,n){if(t.gfx)throw new Error(`already rendered ${hr(t)}`);return e.element(t,i[t.id],n)}(t,n);return o(t),r}catch(e){s(e.message,{element:t,error:e}),console.error(`failed to import ${hr(t)}`,e)}}function s(t,n){e.error(t,n)}var c=this.registerDi=function(e){var t=e.bpmnElement;t?i[t.id]?s(`multiple DI elements defined for ${hr(t)}`,{element:t}):(i[t.id]=e,dr(t)):s(`no bpmnElement referenced in ${hr(e)}`,{element:e})};function p(e){var t;t=e.plane,c(t),g(t.planeElement,l)}function l(e){c(e)}this.handleDefinitions=function(o,a){var l=o.diagrams;if(a&&-1===l.indexOf(a))throw new Error("diagram not part of <bpmn:Definitions />");if(!a&&l&&l.length&&(a=l[0]),!a)throw new Error("no diagram to display");i={},p(a);var f=a.plane;if(!f)throw new Error(`no plane for ${hr(a)}`);var v=f.bpmnElement;if(!v){if(v=function(e){return m(e.rootElements,(function(e){return fr(e,"bpmn:Process")||fr(e,"bpmn:Collaboration")}))}(o),!v)throw new Error("no process or collaboration to display");s(`correcting missing bpmnElement on ${hr(f)} to ${hr(v)}`),f.bpmnElement=v,c(f)}var b,_,w=function(t,n){return e.root(t,i[t.id],n)}(v,f);if(fr(v,"bpmn:Process")||fr(v,"bpmn:SubProcess"))h(v,w);else{if(!fr(v,"bpmn:Collaboration"))throw new Error(`unsupported bpmnElement for ${hr(f)}: ${hr(v)}`);_=w,g((b=v).participants,r(A,_)),x(b.artifacts,_),n.push((function(){!function(e,t){g(e,r(d,t))}(b.messageFlows,_)})),function(e,n){var i=y(e,(function(e){return!t[e.id]&&fr(e,"bpmn:Process")&&e.laneSets}));i.forEach(r(h,n))}(o.rootElements,w)}u(n)};var u=this.handleDeferred=function(){for(;n.length;)n.shift()()};function h(e,t){P(e,t),w(e.ioSpecification,t),x(e.artifacts,t),o(e)}function d(e,t){a(e,t)}function f(e,t){a(e,t)}function v(e,t){a(e,t)}function b(e,t){a(e,t)}function _(e,t){a(e,t)}function x(e,t){g(e,(function(e){fr(e,"bpmn:Association")?n.push((function(){_(e,t)})):_(e,t)}))}function w(e,t){e&&(g(e.dataInputs,r(v,t)),g(e.dataOutputs,r(b,t)))}var E=this.handleSubProcess=function(e,t){P(e,t),x(e.artifacts,t)};function S(e,t){var i=a(e,t);fr(e,"bpmn:SubProcess")&&E(e,i||t),fr(e,"bpmn:Activity")&&w(e.ioSpecification,t),n.push((function(){g(e.dataInputAssociations,r(f,t)),g(e.dataOutputAssociations,r(f,t))}))}function C(e,t){a(e,t)}function k(e,t){n.push((function(){var n=a(e,t);e.childLaneSet&&R(e.childLaneSet,n||t),function(e){g(e.flowNodeRef,(function(t){var n=t.get("lanes");n&&n.push(e)}))}(e)}))}function R(e,t){g(e.lanes,r(k,t))}function P(e,t){!function(e,t){g(e,(function(e){fr(e,"bpmn:SequenceFlow")?n.push((function(){!function(e,t){a(e,t)}(e,t)})):fr(e,"bpmn:BoundaryEvent")?n.unshift((function(){S(e,t)})):fr(e,"bpmn:FlowNode")?S(e,t):fr(e,"bpmn:DataObject")||(fr(e,"bpmn:DataStoreReference")||fr(e,"bpmn:DataObjectReference")?C(e,t):s(`unrecognized flowElement ${hr(e)} in context ${hr(t&&t.businessObject)}`,{element:e,context:t}))}))}(e.flowElements,t),e.laneSets&&function(e,t){g(e,r(R,t))}(e.laneSets,t)}function A(e,t){var n=a(e,t),i=e.processRef;i&&h(i,n||t)}}function vr(e,t){var n=gr(e);return n&&"function"==typeof n.$instanceOf&&n.$instanceOf(t)}function yr(e,t){return w(t,(function(t){return vr(e,t)}))}function gr(e){return e&&e.businessObject||e}function br(e){return e&&e.di}function _r(e,t,n){var i,r,o,a=[];function s(e,t){var n=new mr({root:function(e,t){return i.add(e,t)},element:function(e,t,n){return i.add(e,t,n)},error:function(e,t){a.push({message:e,context:t})}});t=t||e.diagrams&&e.diagrams[0];var r=function(e,t){if(!t||!t.plane)return;var n,i=t.plane.bpmnElement,r=i;vr(i,"bpmn:Process")||vr(i,"bpmn:Collaboration")||(r=function(e){var t=e;for(;t;){if(vr(t,"bpmn:Process"))return t;t=t.$parent}} function
/plugin/elasticsearch/vendor/patrickschur/language-detection/resources/ku/
H A Dku.txt77 1. Ji temenê (emrê) balixiyê pê ve, mêr û jin, bê tu tahdîdên ji ber nijad, netewahî an olê, maf hene ku hev mehr bikin û malbatek deynin. Li hemberî zewacê, di domahiyê zewacê û di dema berdanê de ew xwedî mafên wekhev in.
/plugin/dirtylittlehelper/mermaid/editor/
H A Dbundle.js426Ji=n(5);const Xi={base:"vs",inherit:!1,rules:[{token:"",foreground:"000000",background:"fffffe"},{…
/plugin/dirtylittlehelper/mermaid/editor/docs/
H A Dbundle.js426Ji=n(5);const Xi={base:"vs",inherit:!1,rules:[{token:"",foreground:"000000",background:"fffffe"},{…
/plugin/mermaid/
H A Dmermaid.min.js329 `)},"setAccDescription"),Lr=o(()=>tS,"getAccDescription"),nn=o(t=>{eS=rS(t)},"setDiagramTitle"),Xr=o(()=>eS,"getDiagramTitle")});var R$,Gbe,de,iS,_4,$be,aS,Vbe,A4,Jf,cy,nS,_t=R(()=>{"use strict";Hf();ut();qs();rr();Yn();Z7();bi();R$=V,Gbe=$1,de=Or,iS=Zb,_4=uh,$be=o(t=>qr(t,de()),"sanitizeText"),aS=Lo,Vbe=o(()=>ly,"getCommonDb"),A4={},Jf=o((t,e,r)=>{A4[t]&&R$.warn(`Diagram with id ${t} already registered. Overwriting.`),A4[t]=e,r&&$C(t,r),L$(t,e.styles),e.injectUtils?.(R$,Gbe,de,$be,aS,Vbe(),()=>{})},"registerDiagram"),cy=o(t=>{if(t in A4)return A4[t];throw new nS(t)},"getDiagram"),nS=class extends Error{static{o(this,"DiagramNotFoundError")}constructor(e){super(`Diagram ${e} not found.`)}}});var ul,vh,ja,cl,nc,uy,sS,oS,L4,D4,N$,Ube,Hbe,Ybe,Wbe,qbe,Xbe,jbe,Kbe,Qbe,Zbe,Jbe,e4e,t4e,r4e,n4e,i4e,a4e,M$,s4e,o4e,I$,l4e,c4e,u4e,h4e,xh,f4e,d4e,p4e,m4e,g4e,hy,lS=R(()=>{"use strict";_t();rr();bi();ul=[],vh=[""],ja="global",cl="",nc=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],uy=[],sS="",oS=!1,L4=4,D4=2,Ube=o(function(){return N$},"getC4Type"),Hbe=o(function(t){N$=qr(t,de())},"setC4Type"),Ybe=o(function(t,e,r,n,i,a,s,l,u){if(t==null||e===void 0||e===null||r===void 0||r===null||n===void 0||n===null)return;let h={},f=uy.find(d=>d.from===e&&d.to===r);if(f?h=f:uy.push(h),h.type=t,h.from=e,h.to=r,h.label={text:n},i==null)h.techn={text:""};else if(typeof i=="object"){let[d,p]=Object.entries(i)[0];h[d]={text:p}}else h.techn={text:i};if(a==null)h.descr={text:""};else if(typeof a=="object"){let[d,p]=Object.entries(a)[0];h[d]={text:p}}else h.descr={text:a};if(typeof s=="object"){let[d,p]=Object.entries(s)[0];h[d]=p}else h.sprite=s;if(typeof l=="object"){let[d,p]=Object.entries(l)[0];h[d]=p}else h.tags=l;if(typeof u=="object"){let[d,p]=Object.entries(u)[0];h[d]=p}else h.link=u;h.wrap=xh()},"addRel"),Wbe=o(function(t,e,r,n,i,a,s){if(e===null||r===null)return;let l={},u=ul.find(h=>h.alias===e);if(u&&e===u.alias?l=u:(l.alias=e,ul.push(l)),r==null?l.label={text:""}:l.label={text:r},n==null)l.descr={text:""};else if(typeof n=="object"){let[h,f]=Object.entries(n)[0];l[h]={text:f}}else l.descr={text:n};if(typeof i=="object"){let[h,f]=Object.entries(i)[0];l[h]=f}else l.sprite=i;if(typeof a=="object"){let[h,f]=Object.entries(a)[0];l[h]=f}else l.tags=a;if(typeof s=="object"){let[h,f]=Object.entries(s)[0];l[h]=f}else l.link=s;l.typeC4Shape={text:t},l.parentBoundary=ja,l.wrap=xh()},"addPersonOrSystem"),qbe=o(function(t,e,r,n,i,a,s,l){if(e===null||r===null)return;let u={},h=ul.find(f=>f.alias===e);if(h&&e===h.alias?u=h:(u.alias=e,ul.push(u)),r==null?u.label={text:""}:u.label={text:r},n==null)u.techn={text:""};else if(typeof n=="object"){let[f,d]=Object.entries(n)[0];u[f]={text:d}}else u.techn={text:n};if(i==null)u.descr={text:""};else if(typeof i=="object"){let[f,d]=Object.entries(i)[0];u[f]={text:d}}else u.descr={text:i};if(typeof a=="object"){let[f,d]=Object.entries(a)[0];u[f]=d}else u.sprite=a;if(typeof s=="object"){let[f,d]=Object.entries(s)[0];u[f]=d}else u.tags=s;if(typeof l=="object"){let[f,d]=Object.entries(l)[0];u[f]=d}else u.link=l;u.wrap=xh(),u.typeC4Shape={text:t},u.parentBoundary=ja},"addContainer"),Xbe=o(function(t,e,r,n,i,a,s,l){if(e===null||r===null)return;let u={},h=ul.find(f=>f.alias===e);if(h&&e===h.alias?u=h:(u.alias=e,ul.push(u)),r==null?u.label={text:""}:u.label={text:r},n==null)u.techn={text:""};else if(typeof n=="object"){let[f,d]=Object.entries(n)[0];u[f]={text:d}}else u.techn={text:n};if(i==null)u.descr={text:""};else if(typeof i=="object"){let[f,d]=Object.entries(i)[0];u[f]={text:d}}else u.descr={text:i};if(typeof a=="object"){let[f,d]=Object.entries(a)[0];u[f]=d}else u.sprite=a;if(typeof s=="object"){let[f,d]=Object.entries(s)[0];u[f]=d}else u.tags=s;if(typeof l=="object"){let[f,d]=Object.entries(l)[0];u[f]=d}else u.link=l;u.wrap=xh(),u.typeC4Shape={text:t},u.parentBoundary=ja},"addComponent"),jbe=o(function(t,e,r,n,i){if(t===null||e===null)return;let a={},s=nc.find(l=>l.alias===t);if(s&&t===s.alias?a=s:(a.alias=t,nc.push(a)),e==null?a.label={text:""}:a.label={text:e},r==null)a.type={text:"system"};else if(typeof r=="object"){let[l,u]=Object.entries(r)[0];a[l]={text:u}}else a.type={text:r};if(typeof n=="object"){let[l,u]=Object.entries(n)[0];a[l]=u}else a.tags=n;if(typeof i=="object"){let[l,u]=Object.entries(i)[0];a[l]=u}else a.link=i;a.parentBoundary=ja,a.wrap=xh(),cl=ja,ja=t,vh.push(cl)},"addPersonOrSystemBoundary"),Kbe=o(function(t,e,r,n,i){if(t===null||e===null)return;let a={},s=nc.find(l=>l.alias===t);if(s&&t===s.alias?a=s:(a.alias=t,nc.push(a)),e==null?a.label={text:""}:a.label={text:e},r==null)a.type={text:"container"};else if(typeof r=="object"){let[l,u]=Object.entries(r)[0];a[l]={text:u}}else a.type={text:r};if(typeof n=="object"){let[l,u]=Object.entries(n)[0];a[l]=u}else a.tags=n;if(typeof i=="object"){let[l,u]=Object.entries(i)[0];a[l]=u}else a.link=i;a.parentBoundary=ja,a.wrap=xh(),cl=ja,ja=t,vh.push(cl)},"addContainerBoundary"),Qbe=o(function(t,e,r,n,i,a,s,l){if(e===null||r===null)return;let u={},h=nc.find(f=>f.alias===e);if(h&&e===h.alias?u=h:(u.alias=e,nc.push(u)),r==null?u.label={text:""}:u.label={text:r},n==null)u.type={text:"node"};else if(typeof n=="object"){let[f,d]=Object.entries(n)[0];u[f]={text:d}}else u.type={text:n};if(i==null)u.descr={text:""};else if(typeof i=="object"){let[f,d]=Object.entries(i)[0];u[f]={text:d}}else u.descr={text:i};if(typeof s=="object"){let[f,d]=Object.entries(s)[0];u[f]=d}else u.tags=s;if(typeof l=="object"){let[f,d]=Object.entries(l)[0];u[f]=d}else u.link=l;u.nodeType=t,u.parentBoundary=ja,u.wrap=xh(),cl=ja,ja=e,vh.push(cl)},"addDeploymentNode"),Zbe=o(function(){ja=cl,vh.pop(),cl=vh.pop(),vh.push(cl)},"popBoundaryParseStack"),Jbe=o(function(t,e,r,n,i,a,s,l,u,h,f){let d=ul.find(p=>p.alias===e);if(!(d===void 0&&(d=nc.find(p=>p.alias===e),d===void 0))){if(r!=null)if(typeof r=="object"){let[p,m]=Object.entries(r)[0];d[p]=m}else d.bgColor=r;if(n!=null)if(typeof n=="object"){let[p,m]=Object.entries(n)[0];d[p]=m}else d.fontColor=n;if(i!=null)if(typeof i=="object"){let[p,m]=Object.entries(i)[0];d[p]=m}else d.borderColor=i;if(a!=null)if(typeof a=="object"){let[p,m]=Object.entries(a)[0];d[p]=m}else d.shadowing=a;if(s!=null)if(typeof s=="object"){let[p,m]=Object.entries(s)[0];d[p]=m}else d.shape=s;if(l!=null)if(typeof l=="object"){let[p,m]=Object.entries(l)[0];d[p]=m}else d.sprite=l;if(u!=null)if(typeof u=="object"){let[p,m]=Object.entries(u)[0];d[p]=m}else d.techn=u;if(h!=null)if(typeof h=="object"){let[p,m]=Object.entries(h)[0];d[p]=m}else d.legendText=h;if(f!=null)if(typeof f=="object"){let[p,m]=Object.entries(f)[0];d[p]=m}else d.legendSprite=f}},"updateElStyle"),e4e=o(function(t,e,r,n,i,a,s){let l=uy.find(u=>u.from===e&&u.to===r);if(l!==void 0){if(n!=null)if(typeof n=="object"){let[u,h]=Object.entries(n)[0];l[u]=h}else l.textColor=n;if(i!=null)if(typeof i=="object"){let[u,h]=Object.entries(i)[0];l[u]=h}else l.lineColor=i;if(a!=null)if(typeof a=="object"){let[u,h]=Object.entries(a)[0];l[u]=parseInt(h)}else l.offsetX=parseInt(a);if(s!=null)if(typeof s=="object"){let[u,h]=Object.entries(s)[0];l[u]=parseInt(h)}else l.offsetY=parseInt(s)}},"updateRelStyle"),t4e=o(function(t,e,r){let n=L4,i=D4;if(typeof e=="object"){let a=Object.values(e)[0];n=parseInt(a)}else n=parseInt(e);if(typeof r=="object"){let a=Object.values(r)[0];i=parseInt(a)}else i=parseInt(r);n>=1&&(L4=n),i>=1&&(D4=i)},"updateLayoutConfig"),r4e=o(function(){return L4},"getC4ShapeInRow"),n4e=o(function(){return D4},"getC4BoundaryInRow"),i4e=o(function(){return ja},"getCurrentBoundaryParse"),a4e=o(function(){return cl},"getParentBoundaryParse"),M$=o(function(t){return t==null?ul:ul.filter(e=>e.parentBoundary===t)},"getC4ShapeArray"),s4e=o(function(t){return ul.find(e=>e.alias===t)},"getC4Shape"),o4e=o(function(t){return Object.keys(M$(t))},"getC4ShapeKeys"),I$=o(function(t){return t==null?nc:nc.filter(e=>e.parentBoundary===t)},"getBoundaries"),l4e=I$,c4e=o(function(){return uy},"getRels"),u4e=o(function(){return sS},"getTitle"),h4e=o(function(t){oS=t},"setWrap"),xh=o(function(){return oS},"autoWrap"),f4e=o(function(){ul=[],nc=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],cl="",ja="global",vh=[""],uy=[],vh=[""],sS="",oS=!1,L4=4,D4=2},"clear"),d4e={SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25},p4e={FILLED:0,OPEN:1},m4e={LEFTOF:0,RIGHTOF:1,OVER:2},g4e=o(function(t){sS=qr(t,de())},"setTitle"),hy={addPersonOrSystem:Wbe,addPersonOrSystemBoundary:jbe,addContainer:qbe,addContainerBoundary:Kbe,addComponent:Xbe,addDeploymentNode:Qbe,popBoundaryParseStack:Zbe,addRel:Ybe,updateElStyle:Jbe,updateRelStyle:e4e,updateLayoutConfig:t4e,autoWrap:xh,setWrap:h4e,getC4ShapeArray:M$,getC4Shape:s4e,getC4ShapeKeys:o4e,getBoundaries:I$,getBoundarys:l4e,getCurrentBoundaryParse:i4e,getParentBoundaryParse:a4e,getRels:c4e,getTitle:u4e,getC4Type:Ube,getC4ShapeInRow:r4e,getC4BoundaryInRow:n4e,setAccTitle:kr,getAccTitle:Ar,getAccDescription:Lr,setAccDescription:_r,getConfig:o(()=>de().c4,"getConfig"),clear:f4e,LINETYPE:d4e,ARROWTYPE:p4e,PLACEMENT:m4e,setTitle:g4e,setC4Type:Hbe}});function ed(t,e){return t==null||e==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}var cS=R(()=>{"use strict";o(ed,"ascending")});function uS(t,e){return t==null||e==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}var O$=R(()=>{"use strict";o(uS,"descending")});function td(t){let e,r,n;t.length!==2?(e=ed,r=o((l,u)=>ed(t(l),u),"compare2"),n=o((l,u)=>t(l)-u,"delta")):(e=t===ed||t===uS?t:y4e,r=t,n=t);function i(l,u,h=0,f=l.length){if(h<f){if(e(u,u)!==0)return f;do{let d=h+f>>>1;r(l[d],u)<0?h=d+1:f=d}while(h<f)}return h}o(i,"left");function a(l,u,h=0,f=l.length){if(h<f){if(e(u,u)!==0)return f;do{let d=h+f>>>1;r(l[d],u)<=0?h=d+1:f=d}while(h<f)}return h}o(a,"right");function s(l,u,h=0,f=l.length){let d=i(l,u,h,f-1);return d>h&&n(l[d-1],u)>-n(l[d],u)?d-1:d}return o(s,"center"),{left:i,center:s,right:a}}function y4e(){return 0}var hS=R(()=>{"use strict";cS();O$();o(td,"bisector");o(y4e,"zero")});function fS(t){return t===null?NaN:+t}var P$=R(()=>{"use strict";o(fS,"number")});var B$,F$,v4e,x4e,dS,z$=R(()=>{"use strict";cS();hS();P$();B$=td(ed),F$=B$.right,v4e=B$.left,x4e=td(fS).center,dS=F$});function G$({_intern:t,_key:e},r){let n=e(r);return t.has(n)?t.get(n):r}function b4e({_intern:t,_key:e},r){let n=e(r);return t.has(n)?t.get(n):(t.set(n,r),r)}function w4e({_intern:t,_key:e},r){let n=e(r);return t.has(n)&&(r=t.get(n),t.delete(n)),r}function T4e(t){return t!==null&&typeof t=="object"?t.valueOf():t}var wp,$$=R(()=>{"use strict";wp=class extends Map{static{o(this,"InternMap")}constructor(e,r=T4e){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(let[n,i]of e)this.set(n,i)}get(e){return super.get(G$(this,e))}has(e){return super.has(G$(this,e))}set(e,r){return super.set(b4e(this,e),r)}delete(e){return super.delete(w4e(this,e))}};o(G$,"intern_get");o(b4e,"intern_set");o(w4e,"intern_delete");o(T4e,"keyof")});function R4(t,e,r){let n=(e-t)/Math.max(0,r),i=Math.floor(Math.log10(n)),a=n/Math.pow(10,i),s=a>=k4e?10:a>=E4e?5:a>=C4e?2:1,l,u,h;return i<0?(h=Math.pow(10,-i)/s,l=Math.round(t*h),u=Math.round(e*h),l/h<t&&++l,u/h>e&&--u,h=-h):(h=Math.pow(10,i)*s,l=Math.round(t/h),u=Math.round(e/h),l*h<t&&++l,u*h>e&&--u),u<l&&.5<=r&&r<2?R4(t,e,r*2):[l,u,h]}function N4(t,e,r){if(e=+e,t=+t,r=+r,!(r>0))return[];if(t===e)return[t];let n=e<t,[i,a,s]=n?R4(e,t,r):R4(t,e,r);if(!(a>=i))return[];let l=a-i+1,u=new Array(l);if(n)if(s<0)for(let h=0;h<l;++h)u[h]=(a-h)/-s;else for(let h=0;h<l;++h)u[h]=(a-h)*s;else if(s<0)for(let h=0;h<l;++h)u[h]=(i+h)/-s;else for(let h=0;h<l;++h)u[h]=(i+h)*s;return u}function fy(t,e,r){return e=+e,t=+t,r=+r,R4(t,e,r)[2]}function Tp(t,e,r){e=+e,t=+t,r=+r;let n=e<t,i=n?fy(e,t,r):fy(t,e,r);return(n?-1:1)*(i<0?1/-i:i)}var k4e,E4e,C4e,V$=R(()=>{"use strict";k4e=Math.sqrt(50),E4e=Math.sqrt(10),C4e=Math.sqrt(2);o(R4,"tickSpec");o(N4,"ticks");o(fy,"tickIncrement");o(Tp,"tickStep")});function M4(t,e){let r;if(e===void 0)for(let n of t)n!=null&&(r<n||r===void 0&&n>=n)&&(r=n);else{let n=-1;for(let i of t)(i=e(i,++n,t))!=null&&(r<i||r===void 0&&i>=i)&&(r=i)}return r}var U$=R(()=>{"use strict";o(M4,"max")});function I4(t,e){let r;if(e===void 0)for(let n of t)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);else{let n=-1;for(let i of t)(i=e(i,++n,t))!=null&&(r>i||r===void 0&&i>=i)&&(r=i)}return r}var H$=R(()=>{"use strict";o(I4,"min")});function O4(t,e,r){t=+t,e=+e,r=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+r;for(var n=-1,i=Math.max(0,Math.ceil((e-t)/r))|0,a=new Array(i);++n<i;)a[n]=t+n*r;return a}var Y$=R(()=>{"use strict";o(O4,"range")});var bh=R(()=>{"use strict";z$();hS();U$();H$();Y$();V$();$$()});function pS(t){return t}var W$=R(()=>{"use strict";o(pS,"default")});function S4e(t){return"translate("+t+",0)"}function A4e(t){return"translate(0,"+t+")"}function _4e(t){return e=>+t(e)}function L4e(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}function D4e(){return!this.__axis}function X$(t,e){var r=[],n=null,i=null,a=6,s=6,l=3,u=typeof window<"u"&&window.devicePixelRatio>1?0:.5,h=t===B4||t===P4?-1:1,f=t===P4||t===mS?"x":"y",d=t===B4||t===gS?S4e:A4e;function p(m){var g=n??(e.ticks?e.ticks.apply(e,r):e.domain()),y=i??(e.tickFormat?e.tickFormat.apply(e,r):pS),v=Math.max(a,0)+l,x=e.range(),b=+x[0]+u,w=+x[x.length-1]+u,S=(e.bandwidth?L4e:_4e)(e.copy(),u),T=m.selection?m.selection():m,E=T.selectAll(".domain").data([null]),_=T.selectAll(".tick").data(g,e).order(),A=_.exit(),L=_.enter().append("g").attr("class","tick"),M=_.select("line"),N=_.select("text");E=E.merge(E.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),_=_.merge(L),M=M.merge(L.append("line").attr("stroke","currentColor").attr(f+"2",h*a)),N=N.merge(L.append("text").attr("fill","currentColor").attr(f,h*v).attr("dy",t===B4?"0em":t===gS?"0.71em":"0.32em")),m!==T&&(E=E.transition(m),_=_.transition(m),M=M.transition(m),N=N.transition(m),A=A.transition(m).attr("opacity",q$).attr("transform",function(k){return isFinite(k=S(k))?d(k+u):this.getAttribute("transform")}),L.attr("opacity",q$).attr("transform",function(k){var I=this.parentNode.__axis;return d((I&&isFinite(I=I(k))?I:S(k))+u)})),A.remove(),E.attr("d",t===P4||t===mS?s?"M"+h*s+","+b+"H"+u+"V"+w+"H"+h*s:"M"+u+","+b+"V"+w:s?"M"+b+","+h*s+"V"+u+"H"+w+"V"+h*s:"M"+b+","+u+"H"+w),_.attr("opacity",1).attr("transform",function(k){return d(S(k)+u)}),M.attr(f+"2",h*a),N.attr(f,h*v).text(y),T.filter(D4e).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===mS?"start":t===P4?"end":"middle"),T.each(function(){this.__axis=S})}return o(p,"axis"),p.scale=function(m){return arguments.length?(e=m,p):e},p.ticks=function(){return r=Array.from(arguments),p},p.tickArguments=function(m){return arguments.length?(r=m==null?[]:Array.from(m),p):r.slice()},p.tickValues=function(m){return arguments.length?(n=m==null?null:Array.from(m),p):n&&n.slice()},p.tickFormat=function(m){return arguments.length?(i=m,p):i},p.tickSize=function(m){return arguments.length?(a=s=+m,p):a},p.tickSizeInner=function(m){return arguments.length?(a=+m,p):a},p.tickSizeOuter=function(m){return arguments.length?(s=+m,p):s},p.tickPadding=function(m){return arguments.length?(l=+m,p):l},p.offset=function(m){return arguments.length?(u=+m,p):u},p}function yS(t){return X$(B4,t)}function vS(t){return X$(gS,t)}var B4,mS,gS,P4,q$,j$=R(()=>{"use strict";W$();B4=1,mS=2,gS=3,P4=4,q$=1e-6;o(S4e,"translateX");o(A4e,"translateY");o(_4e,"number");o(L4e,"center");o(D4e,"entering");o(X$,"axis");o(yS,"axisTop");o(vS,"axisBottom")});var K$=R(()=>{"use strict";j$()});function Z$(){for(var t=0,e=arguments.length,r={},n;t<e;++t){if(!(n=arguments[t]+"")||n in r||/[\s.]/.test(n))throw new Error("illegal type: "+n);r[n]=[]}return new F4(r)}function F4(t){this._=t}function N4e(t,e){return t.trim().split(/^|\s+/).map(function(r){var n="",i=r.indexOf(".");if(i>=0&&(n=r.slice(i+1),r=r.slice(0,i)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:n}})}function M4e(t,e){for(var r=0,n=t.length,i;r<n;++r)if((i=t[r]).name===e)return i.value}function Q$(t,e,r){for(var n=0,i=t.length;n<i;++n)if(t[n].name===e){t[n]=R4e,t=t.slice(0,n).concat(t.slice(n+1));break}return r!=null&&t.push({name:e,value:r}),t}var R4e,xS,J$=R(()=>{"use strict";R4e={value:o(()=>{},"value")};o(Z$,"dispatch");o(F4,"Dispatch");o(N4e,"parseTypenames");F4.prototype=Z$.prototype={constructor:F4,on:o(function(t,e){var r=this._,n=N4e(t+"",r),i,a=-1,s=n.length;if(arguments.length<2){for(;++a<s;)if((i=(t=n[a]).type)&&(i=M4e(r[i],t.name)))return i;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++a<s;)if(i=(t=n[a]).type)r[i]=Q$(r[i],t.name,e);else if(e==null)for(i in r)r[i]=Q$(r[i],t.name,null);return this},"on"),copy:o(function(){var t={},e=this._;for(var r in e)t[r]=e[r].slice();return new F4(t)},"copy"),call:o(function(t,e){if((i=arguments.length-2)>0)for(var r=new Array(i),n=0,i,a;n<i;++n)r[n]=arguments[n+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(a=this._[t],n=0,i=a.length;n<i;++n)a[n].value.apply(e,r)},"call"),apply:o(function(t,e,r){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var n=this._[t],i=0,a=n.length;i<a;++i)n[i].value.apply(e,r)},"apply")};o(M4e,"get");o(Q$,"set");xS=Z$});var bS=R(()=>{"use strict";J$()});var z4,wS,TS=R(()=>{"use strict";z4="http://www.w3.org/1999/xhtml",wS={svg:"http://www.w3.org/2000/svg",xhtml:z4,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"}});function ic(t){var e=t+="",r=e.indexOf(":");return r>=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),wS.hasOwnProperty(e)?{space:wS[e],local:t}:t}var G4=R(()=>{"use strict";TS();o(ic,"default")});function I4e(t){return function(){var e=this.ownerDocument,r=this.namespaceURI;return r===z4&&e.documentElement.namespaceURI===z4?e.createElement(t):e.createElementNS(r,t)}}function O4e(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function dy(t){var e=ic(t);return(e.local?O4e:I4e)(e)}var kS=R(()=>{"use strict";G4();TS();o(I4e,"creatorInherit");o(O4e,"creatorFixed");o(dy,"default")});function P4e(){}function wh(t){return t==null?P4e:function(){return this.querySelector(t)}}var $4=R(()=>{"use strict";o(P4e,"none");o(wh,"default")});function ES(t){typeof t!="function"&&(t=wh(t));for(var e=this._groups,r=e.length,n=new Array(r),i=0;i<r;++i)for(var a=e[i],s=a.length,l=n[i]=new Array(s),u,h,f=0;f<s;++f)(u=a[f])&&(h=t.call(u,u.__data__,f,a))&&("__data__"in u&&(h.__data__=u.__data__),l[f]=h);return new Zn(n,this._parents)}var eV=R(()=>{"use strict";hl();$4();o(ES,"default")});function CS(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}var tV=R(()=>{"use strict";o(CS,"array")});function B4e(){return[]}function kp(t){return t==null?B4e:function(){return this.querySelectorAll(t)}}var SS=R(()=>{"use strict";o(B4e,"empty");o(kp,"default")});function F4e(t){return function(){return CS(t.apply(this,arguments))}}function AS(t){typeof t=="function"?t=F4e(t):t=kp(t);for(var e=this._groups,r=e.length,n=[],i=[],a=0;a<r;++a)for(var s=e[a],l=s.length,u,h=0;h<l;++h)(u=s[h])&&(n.push(t.call(u,u.__data__,h,s)),i.push(u));return new Zn(n,i)}var rV=R(()=>{"use strict";hl();tV();SS();o(F4e,"arrayAll");o(AS,"default")});function Ep(t){return function(){return this.matches(t)}}function V4(t){return function(e){return e.matches(t)}}var py=R(()=>{"use strict";o(Ep,"default");o(V4,"childMatcher")});function G4e(t){return function(){return z4e.call(this.children,t)}}function $4e(){return this.firstElementChild}function _S(t){return this.select(t==null?$4e:G4e(typeof t=="function"?t:V4(t)))}var z4e,nV=R(()=>{"use strict";py();z4e=Array.prototype.find;o(G4e,"childFind");o($4e,"childFirst");o(_S,"default")});function U4e(){return Array.from(this.children)}function H4e(t){return function(){return V4e.call(this.children,t)}}function LS(t){return this.selectAll(t==null?U4e:H4e(typeof t=="function"?t:V4(t)))}var V4e,iV=R(()=>{"use strict";py();V4e=Array.prototype.filter;o(U4e,"children");o(H4e,"childrenFilter");o(LS,"default")});function DS(t){typeof t!="function"&&(t=Ep(t));for(var e=this._groups,r=e.length,n=new Array(r),i=0;i<r;++i)for(var a=e[i],s=a.length,l=n[i]=[],u,h=0;h<s;++h)(u=a[h])&&t.call(u,u.__data__,h,a)&&l.push(u);return new Zn(n,this._parents)}var aV=R(()=>{"use strict";hl();py();o(DS,"default")});function my(t){return new Array(t.length)}var RS=R(()=>{"use strict";o(my,"default")});function NS(){return new Zn(this._enter||this._groups.map(my),this._parents)}function gy(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}var MS=R(()=>{"use strict";RS();hl();o(NS,"default");o(gy,"EnterNode");gy.prototype={constructor:gy,appendChild:o(function(t){return this._parent.insertBefore(t,this._next)},"appendChild"),insertBefore:o(function(t,e){return this._parent.insertBefore(t,e)},"insertBefore"),querySelector:o(function(t){return this._parent.querySelector(t)},"querySelector"),querySelectorAll:o(function(t){return this._parent.querySelectorAll(t)},"querySelectorAll")}});function IS(t){return function(){return t}}var sV=R(()=>{"use strict";o(IS,"default")});function Y4e(t,e,r,n,i,a){for(var s=0,l,u=e.length,h=a.length;s<h;++s)(l=e[s])?(l.__data__=a[s],n[s]=l):r[s]=new gy(t,a[s]);for(;s<u;++s)(l=e[s])&&(i[s]=l)}function W4e(t,e,r,n,i,a,s){var l,u,h=new Map,f=e.length,d=a.length,p=new Array(f),m;for(l=0;l<f;++l)(u=e[l])&&(p[l]=m=s.call(u,u.__data__,l,e)+"",h.has(m)?i[l]=u:h.set(m,u));for(l=0;l<d;++l)m=s.call(t,a[l],l,a)+"",(u=h.get(m))?(n[l]=u,u.__data__=a[l],h.delete(m)):r[l]=new gy(t,a[l]);for(l=0;l<f;++l)(u=e[l])&&h.get(p[l])===u&&(i[l]=u)}function q4e(t){return t.__data__}function OS(t,e){if(!arguments.length)return Array.from(this,q4e);var r=e?W4e:Y4e,n=this._parents,i=this._groups;typeof t!="function"&&(t=IS(t));for(var a=i.length,s=new Array(a),l=new Array(a),u=new Array(a),h=0;h<a;++h){var f=n[h],d=i[h],p=d.length,m=X4e(t.call(f,f&&f.__data__,h,n)),g=m.length,y=l[h]=new Array(g),v=s[h]=new Array(g),x=u[h]=new Array(p);r(f,d,y,v,x,m,e);for(var b=0,w=0,S,T;b<g;++b)if(S=y[b]){for(b>=w&&(w=b+1);!(T=v[w])&&++w<g;);S._next=T||null}}return s=new Zn(s,n),s._enter=l,s._exit=u,s}function X4e(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}var oV=R(()=>{"use strict";hl();MS();sV();o(Y4e,"bindIndex");o(W4e,"bindKey");o(q4e,"datum");o(OS,"default");o(X4e,"arraylike")});function PS(){return new Zn(this._exit||this._groups.map(my),this._parents)}var lV=R(()=>{"use strict";RS();hl();o(PS,"default")});function BS(t,e,r){var n=this.enter(),i=this,a=this.exit();return typeof t=="function"?(n=t(n),n&&(n=n.selection())):n=n.append(t+""),e!=null&&(i=e(i),i&&(i=i.selection())),r==null?a.remove():r(a),n&&i?n.merge(i).order():i}var cV=R(()=>{"use strict";o(BS,"default")});function FS(t){for(var e=t.selection?t.selection():t,r=this._groups,n=e._groups,i=r.length,a=n.length,s=Math.min(i,a),l=new Array(i),u=0;u<s;++u)for(var h=r[u],f=n[u],d=h.length,p=l[u]=new Array(d),m,g=0;g<d;++g)(m=h[g]||f[g])&&(p[g]=m);for(;u<i;++u)l[u]=r[u];return new Zn(l,this._parents)}var uV=R(()=>{"use strict";hl();o(FS,"default")});function zS(){for(var t=this._groups,e=-1,r=t.length;++e<r;)for(var n=t[e],i=n.length-1,a=n[i],s;--i>=0;)(s=n[i])&&(a&&s.compareDocumentPosition(a)^4&&a.parentNode.insertBefore(s,a),a=s);return this}var hV=R(()=>{"use strict";o(zS,"default")});function GS(t){t||(t=j4e);function e(d,p){return d&&p?t(d.__data__,p.__data__):!d-!p}o(e,"compareNode");for(var r=this._groups,n=r.length,i=new Array(n),a=0;a<n;++a){for(var s=r[a],l=s.length,u=i[a]=new Array(l),h,f=0;f<l;++f)(h=s[f])&&(u[f]=h);u.sort(e)}return new Zn(i,this._parents).order()}function j4e(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}var fV=R(()=>{"use strict";hl();o(GS,"default");o(j4e,"ascending")});function $S(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}var dV=R(()=>{"use strict";o($S,"default")});function VS(){return Array.from(this)}var pV=R(()=>{"use strict";o(VS,"default")});function US(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var n=t[e],i=0,a=n.length;i<a;++i){var s=n[i];if(s)return s}return null}var mV=R(()=>{"use strict";o(US,"default")});function HS(){let t=0;for(let e of this)++t;return t}var gV=R(()=>{"use strict";o(HS,"default")});function YS(){return!this.node()}var yV=R(()=>{"use strict";o(YS,"default")});function WS(t){for(var e=this._groups,r=0,n=e.length;r<n;++r)for(var i=e[r],a=0,s=i.length,l;a<s;++a)(l=i[a])&&t.call(l,l.__data__,a,i);return this}var vV=R(()=>{"use strict";o(WS,"default")});function K4e(t){return function(){this.removeAttribute(t)}}function Q4e(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Z4e(t,e){return function(){this.setAttribute(t,e)}}function J4e(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function e3e(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}function t3e(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function qS(t,e){var r=ic(t);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((e==null?r.local?Q4e:K4e:typeof e=="function"?r.local?t3e:e3e:r.local?J4e:Z4e)(r,e))}var xV=R(()=>{"use strict";G4();o(K4e,"attrRemove");o(Q4e,"attrRemoveNS");o(Z4e,"attrConstant");o(J4e,"attrConstantNS");o(e3e,"attrFunction");o(t3e,"attrFunctionNS");o(qS,"default")});function yy(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}var XS=R(()=>{"use strict";o(yy,"default")});function r3e(t){return function(){this.style.removeProperty(t)}}function n3e(t,e,r){return function(){this.style.setProperty(t,e,r)}}function i3e(t,e,r){return function(){var n=e.apply(this,arguments);n==null?this.style.removeProperty(t):this.style.setProperty(t,n,r)}}function jS(t,e,r){return arguments.length>1?this.each((e==null?r3e:typeof e=="function"?i3e:n3e)(t,e,r??"")):Th(this.node(),t)}function Th(t,e){return t.style.getPropertyValue(e)||yy(t).getComputedStyle(t,null).getPropertyValue(e)}var KS=R(()=>{"use strict";XS();o(r3e,"styleRemove");o(n3e,"styleConstant");o(i3e,"styleFunction");o(jS,"default");o(Th,"styleValue")});function a3e(t){return function(){delete this[t]}}function s3e(t,e){return function(){this[t]=e}}function o3e(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}function QS(t,e){return arguments.length>1?this.each((e==null?a3e:typeof e=="function"?o3e:s3e)(t,e)):this.node()[t]}var bV=R(()=>{"use strict";o(a3e,"propertyRemove");o(s3e,"propertyConstant");o(o3e,"propertyFunction");o(QS,"default")});function wV(t){return t.trim().split(/^|\s+/)}function ZS(t){return t.classList||new TV(t)}function TV(t){this._node=t,this._names=wV(t.getAttribute("class")||"")}function kV(t,e){for(var r=ZS(t),n=-1,i=e.length;++n<i;)r.add(e[n])}function EV(t,e){for(var r=ZS(t),n=-1,i=e.length;++n<i;)r.remove(e[n])}function l3e(t){return function(){kV(this,t)}}function c3e(t){return function(){EV(this,t)}}function u3e(t,e){return function(){(e.apply(this,arguments)?kV:EV)(this,t)}}function JS(t,e){var r=wV(t+"");if(arguments.length<2){for(var n=ZS(this.node()),i=-1,a=r.length;++i<a;)if(!n.contains(r[i]))return!1;return!0}return this.each((typeof e=="function"?u3e:e?l3e:c3e)(r,e))}var CV=R(()=>{"use strict";o(wV,"classArray");o(ZS,"classList");o(TV,"ClassList");TV.prototype={add:o(function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},"add"),remove:o(function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},"remove"),contains:o(function(t){return this._names.indexOf(t)>=0},"contains")};o(kV,"classedAdd");o(EV,"classedRemove");o(l3e,"classedTrue");o(c3e,"classedFalse");o(u3e,"classedFunction");o(JS,"default")});function h3e(){this.textContent=""}function f3e(t){return function(){this.textContent=t}}function d3e(t){return function(){var e=t.apply(this,arguments);this.textContent=e??""}}function eA(t){return arguments.length?this.each(t==null?h3e:(typeof t=="function"?d3e:f3e)(t)):this.node().textContent}var SV=R(()=>{"use strict";o(h3e,"textRemove");o(f3e,"textConstant");o(d3e,"textFunction");o(eA,"default")});function p3e(){this.innerHTML=""}function m3e(t){return function(){this.innerHTML=t}}function g3e(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e??""}}function tA(t){return arguments.length?this.each(t==null?p3e:(typeof t=="function"?g3e:m3e)(t)):this.node().innerHTML}var AV=R(()=>{"use strict";o(p3e,"htmlRemove");o(m3e,"htmlConstant");o(g3e,"htmlFunction");o(tA,"default")});function y3e(){this.nextSibling&&this.parentNode.appendChild(this)}function rA(){return this.each(y3e)}var _V=R(()=>{"use strict";o(y3e,"raise");o(rA,"default")});function v3e(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function nA(){return this.each(v3e)}var LV=R(()=>{"use strict";o(v3e,"lower");o(nA,"default")});function iA(t){var e=typeof t=="function"?t:dy(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}var DV=R(()=>{"use strict";kS();o(iA,"default")});function x3e(){return null}function aA(t,e){var r=typeof t=="function"?t:dy(t),n=e==null?x3e:typeof e=="function"?e:wh(e);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})}var RV=R(()=>{"use strict";kS();$4();o(x3e,"constantNull");o(aA,"default")});function b3e(){var t=this.parentNode;t&&t.removeChild(this)}function sA(){return this.each(b3e)}var NV=R(()=>{"use strict";o(b3e,"remove");o(sA,"default")});function w3e(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function T3e(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function oA(t){return this.select(t?T3e:w3e)}var MV=R(()=>{"use strict";o(w3e,"selection_cloneShallow");o(T3e,"selection_cloneDeep");o(oA,"default")});function lA(t){return arguments.length?this.property("__data__",t):this.node().__data__}var IV=R(()=>{"use strict";o(lA,"default")});function k3e(t){return function(e){t.call(this,e,this.__data__)}}function E3e(t){return t.trim().split(/^|\s+/).map(function(e){var r="",n=e.indexOf(".");return n>=0&&(r=e.slice(n+1),e=e.slice(0,n)),{type:e,name:r}})}function C3e(t){return function(){var e=this.__on;if(e){for(var r=0,n=-1,i=e.length,a;r<i;++r)a=e[r],(!t.type||a.type===t.type)&&a.name===t.name?this.removeEventListener(a.type,a.listener,a.options):e[++n]=a;++n?e.length=n:delete this.__on}}}function S3e(t,e,r){return function(){var n=this.__on,i,a=k3e(e);if(n){for(var s=0,l=n.length;s<l;++s)if((i=n[s]).type===t.type&&i.name===t.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=a,i.options=r),i.value=e;return}}this.addEventListener(t.type,a,r),i={type:t.type,name:t.name,value:e,listener:a,options:r},n?n.push(i):this.__on=[i]}}function cA(t,e,r){var n=E3e(t+""),i,a=n.length,s;if(arguments.length<2){var l=this.node().__on;if(l){for(var u=0,h=l.length,f;u<h;++u)for(i=0,f=l[u];i<a;++i)if((s=n[i]).type===f.type&&s.name===f.name)return f.value}return}for(l=e?S3e:C3e,i=0;i<a;++i)this.each(l(n[i],e,r));return this}var OV=R(()=>{"use strict";o(k3e,"contextListener");o(E3e,"parseTypenames");o(C3e,"onRemove");o(S3e,"onAdd");o(cA,"default")});function PV(t,e,r){var n=yy(t),i=n.CustomEvent;typeof i=="function"?i=new i(e,r):(i=n.document.createEvent("Event"),r?(i.initEvent(e,r.bubbles,r.cancelable),i.detail=r.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function A3e(t,e){return function(){return PV(this,t,e)}}function _3e(t,e){return function(){return PV(this,t,e.apply(this,arguments))}}function uA(t,e){return this.each((typeof e=="function"?_3e:A3e)(t,e))}var BV=R(()=>{"use strict";XS();o(PV,"dispatchEvent");o(A3e,"dispatchConstant");o(_3e,"dispatchFunction");o(uA,"default")});function*hA(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var n=t[e],i=0,a=n.length,s;i<a;++i)(s=n[i])&&(yield s)}var FV=R(()=>{"use strict";o(hA,"default")});function Zn(t,e){this._groups=t,this._parents=e}function zV(){return new Zn([[document.documentElement]],fA)}function L3e(){return this}var fA,cu,hl=R(()=>{"use strict";eV();rV();nV();iV();aV();oV();MS();lV();cV();uV();hV();fV();dV();pV();mV();gV();yV();vV();xV();KS();bV();CV();SV();AV();_V();LV();DV();RV();NV();MV();IV();OV();BV();FV();fA=[null];o(Zn,"Selection");o(zV,"selection");o(L3e,"selection_selection");Zn.prototype=zV.prototype={constructor:Zn,select:ES,selectAll:AS,selectChild:_S,selectChildren:LS,filter:DS,data:OS,enter:NS,exit:PS,join:BS,merge:FS,selection:L3e,order:zS,sort:GS,call:$S,nodes:VS,node:US,size:HS,empty:YS,each:WS,attr:qS,style:jS,property:QS,classed:JS,text:eA,html:tA,raise:rA,lower:nA,append:iA,insert:aA,remove:sA,clone:oA,datum:lA,on:cA,dispatch:uA,[Symbol.iterator]:hA};cu=zV});function $e(t){return typeof t=="string"?new Zn([[document.querySelector(t)]],[document.documentElement]):new Zn([[t]],fA)}var GV=R(()=>{"use strict";hl();o($e,"default")});var fl=R(()=>{"use strict";py();G4();GV();hl();$4();SS();KS()});var $V=R(()=>{"use strict"});function kh(t,e,r){t.prototype=e.prototype=r,r.constructor=t}function Cp(t,e){var r=Object.create(t.prototype);for(var n in e)r[n]=e[n];return r}var dA=R(()=>{"use strict";o(kh,"default");o(Cp,"extend")});function Eh(){}function UV(){return this.rgb().formatHex()}function B3e(){return this.rgb().formatHex8()}function F3e(){return KV(this).formatHsl()}function HV(){return this.rgb().formatRgb()}function pl(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=D3e.exec(t))?(r=e[1].length,e=parseInt(e[1],16),r===6?YV(e):r===3?new la(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?U4(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?U4(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=R3e.exec(t))?new la(e[1],e[2],e[3],1):(e=N3e.exec(t))?new la(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=M3e.exec(t))?U4(e[1],e[2],e[3],e[4]):(e=I3e.exec(t))?U4(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=O3e.exec(t))?XV(e[1],e[2]/100,e[3]/100,1):(e=P3e.exec(t))?XV(e[1],e[2]/100,e[3]/100,e[4]):VV.hasOwnProperty(t)?YV(VV[t]):t==="transparent"?new la(NaN,NaN,NaN,0):null}function YV(t){return new la(t>>16&255,t>>8&255,t&255,1)}function U4(t,e,r,n){return n<=0&&(t=e=r=NaN),new la(t,e,r,n)}function mA(t){return t instanceof Eh||(t=pl(t)),t?(t=t.rgb(),new la(t.r,t.g,t.b,t.opacity)):new la}function Ap(t,e,r,n){return arguments.length===1?mA(t):new la(t,e,r,n??1)}function la(t,e,r,n){this.r=+t,this.g=+e,this.b=+r,this.opacity=+n}function WV(){return`#${rd(this.r)}${rd(this.g)}${rd(this.b)}`}function z3e(){return`#${rd(this.r)}${rd(this.g)}${rd(this.b)}${rd((isNaN(this.opacity)?1:this.opacity)*255)}`}function qV(){let t=W4(this.opacity);return`${t===1?"rgb(":"rgba("}${nd(this.r)}, ${nd(this.g)}, ${nd(this.b)}${t===1?")":`, ${t})`}`}function W4(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function nd(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function rd(t){return t=nd(t),(t<16?"0":"")+t.toString(16)}function XV(t,e,r,n){return n<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new dl(t,e,r,n)}function KV(t){if(t instanceof dl)return new dl(t.h,t.s,t.l,t.opacity);if(t instanceof Eh||(t=pl(t)),!t)return new dl;if(t instanceof dl)return t;t=t.rgb();var e=t.r/255,r=t.g/255,n=t.b/255,i=Math.min(e,r,n),a=Math.max(e,r,n),s=NaN,l=a-i,u=(a+i)/2;return l?(e===a?s=(r-n)/l+(r<n)*6:r===a?s=(n-e)/l+2:s=(e-r)/l+4,l/=u<.5?a+i:2-a-i,s*=60):l=u>0&&u<1?0:s,new dl(s,l,u,t.opacity)}function QV(t,e,r,n){return arguments.length===1?KV(t):new dl(t,e,r,n??1)}function dl(t,e,r,n){this.h=+t,this.s=+e,this.l=+r,this.opacity=+n}function jV(t){return t=(t||0)%360,t<0?t+360:t}function H4(t){return Math.max(0,Math.min(1,t||0))}function pA(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}var vy,Y4,Sp,xy,ac,D3e,R3e,N3e,M3e,I3e,O3e,P3e,VV,gA=R(()=>{"use strict";dA();o(Eh,"Color");vy=.7,Y4=1/vy,Sp="\\s*([+-]?\\d+)\\s*",xy="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ac="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",D3e=/^#([0-9a-f]{3,8})$/,R3e=new RegExp(`^rgb\\(${Sp},${Sp},${Sp}\\)$`),N3e=new RegExp(`^rgb\\(${ac},${ac},${ac}\\)$`),M3e=new RegExp(`^rgba\\(${Sp},${Sp},${Sp},${xy}\\)$`),I3e=new RegExp(`^rgba\\(${ac},${ac},${ac},${xy}\\)$`),O3e=new RegExp(`^hsl\\(${xy},${ac},${ac}\\)$`),P3e=new RegExp(`^hsla\\(${xy},${ac},${ac},${xy}\\)$`),VV={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};kh(Eh,pl,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:UV,formatHex:UV,formatHex8:B3e,formatHsl:F3e,formatRgb:HV,toString:HV});o(UV,"color_formatHex");o(B3e,"color_formatHex8");o(F3e,"color_formatHsl");o(HV,"color_formatRgb");o(pl,"color");o(YV,"rgbn");o(U4,"rgba");o(mA,"rgbConvert");o(Ap,"rgb");o(la,"Rgb");kh(la,Ap,Cp(Eh,{brighter(t){return t=t==null?Y4:Math.pow(Y4,t),new la(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?vy:Math.pow(vy,t),new la(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new la(nd(this.r),nd(this.g),nd(this.b),W4(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:WV,formatHex:WV,formatHex8:z3e,formatRgb:qV,toString:qV}));o(WV,"rgb_formatHex");o(z3e,"rgb_formatHex8");o(qV,"rgb_formatRgb");o(W4,"clampa");o(nd,"clampi");o(rd,"hex");o(XV,"hsla");o(KV,"hslConvert");o(QV,"hsl");o(dl,"Hsl");kh(dl,QV,Cp(Eh,{brighter(t){return t=t==null?Y4:Math.pow(Y4,t),new dl(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?vy:Math.pow(vy,t),new dl(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*e,i=2*r-n;return new la(pA(t>=240?t-240:t+120,i,n),pA(t,i,n),pA(t<120?t+240:t-120,i,n),this.opacity)},clamp(){return new dl(jV(this.h),H4(this.s),H4(this.l),W4(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(){let t=W4(this.opacity);return`${t===1?"hsl(":"hsla("}${jV(this.h)}, ${H4(this.s)*100}%, ${H4(this.l)*100}%${t===1?")":`, ${t})`}`}}));o(jV,"clamph");o(H4,"clampt");o(pA,"hsl2rgb")});var ZV,JV,eU=R(()=>{"use strict";ZV=Math.PI/180,JV=180/Math.PI});function sU(t){if(t instanceof sc)return new sc(t.l,t.a,t.b,t.opacity);if(t instanceof uu)return oU(t);t instanceof la||(t=mA(t));var e=bA(t.r),r=bA(t.g),n=bA(t.b),i=yA((.2225045*e+.7168786*r+.0606169*n)/rU),a,s;return e===r&&r===n?a=s=i:(a=yA((.4360747*e+.3850649*r+.1430804*n)/tU),s=yA((.0139322*e+.0971045*r+.7141733*n)/nU)),new sc(116*i-16,500*(a-i),200*(i-s),t.opacity)}function wA(t,e,r,n){return arguments.length===1?sU(t):new sc(t,e,r,n??1)}function sc(t,e,r,n){this.l=+t,this.a=+e,this.b=+r,this.opacity=+n}function yA(t){return t>G3e?Math.pow(t,1/3):t/aU+iU}function vA(t){return t>_p?t*t*t:aU*(t-iU)}function xA(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function bA(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function $3e(t){if(t instanceof uu)return new uu(t.h,t.c,t.l,t.opacity);if(t instanceof sc||(t=sU(t)),t.a===0&&t.b===0)return new uu(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*JV;return new uu(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function by(t,e,r,n){return arguments.length===1?$3e(t):new uu(t,e,r,n??1)}function uu(t,e,r,n){this.h=+t,this.c=+e,this.l=+r,this.opacity=+n}function oU(t){if(isNaN(t.h))return new sc(t.l,0,0,t.opacity);var e=t.h*ZV;return new sc(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}var q4,tU,rU,nU,iU,_p,aU,G3e,lU=R(()=>{"use strict";dA();gA();eU();q4=18,tU=.96422,rU=1,nU=.82521,iU=4/29,_p=6/29,aU=3*_p*_p,G3e=_p*_p*_p;o(sU,"labConvert");o(wA,"lab");o(sc,"Lab");kh(sc,wA,Cp(Eh,{brighter(t){return new sc(this.l+q4*(t??1),this.a,this.b,this.opacity)},darker(t){return new sc(this.l-q4*(t??1),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,r=isNaN(this.b)?t:t-this.b/200;return e=tU*vA(e),t=rU*vA(t),r=nU*vA(r),new la(xA(3.1338561*e-1.6168667*t-.4906146*r),xA(-.9787684*e+1.9161415*t+.033454*r),xA(.0719453*e-.2289914*t+1.4052427*r),this.opacity)}}));o(yA,"xyz2lab");o(vA,"lab2xyz");o(xA,"lrgb2rgb");o(bA,"rgb2lrgb");o($3e,"hclConvert");o(by,"hcl");o(uu,"Hcl");o(oU,"hcl2lab");kh(uu,by,Cp(Eh,{brighter(t){return new uu(this.h,this.c,this.l+q4*(t??1),this.opacity)},darker(t){return new uu(this.h,this.c,this.l-q4*(t??1),this.opacity)},rgb(){return oU(this).rgb()}}))});var Lp=R(()=>{"use strict";gA();lU()});function TA(t,e,r,n,i){var a=t*t,s=a*t;return((1-3*t+3*a-s)*e+(4-6*a+3*s)*r+(1+3*t+3*a-3*s)*n+s*i)/6}function kA(t){var e=t.length-1;return function(r){var n=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),i=t[n],a=t[n+1],s=n>0?t[n-1]:2*i-a,l=n<e-1?t[n+2]:2*a-i;return TA((r-n/e)*e,s,i,a,l)}}var EA=R(()=>{"use strict";o(TA,"basis");o(kA,"default")});function CA(t){var e=t.length;return function(r){var n=Math.floor(((r%=1)<0?++r:r)*e),i=t[(n+e-1)%e],a=t[n%e],s=t[(n+1)%e],l=t[(n+2)%e];return TA((r-n/e)*e,i,a,s,l)}}var cU=R(()=>{"use strict";EA();o(CA,"default")});var Dp,SA=R(()=>{"use strict";Dp=o(t=>()=>t,"default")});function uU(t,e){return function(r){return t+r*e}}function V3e(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(n){return Math.pow(t+n*e,r)}}function hU(t,e){var r=e-t;return r?uU(t,r>180||r<-180?r-360*Math.round(r/360):r):Dp(isNaN(t)?e:t)}function fU(t){return(t=+t)==1?hu:function(e,r){return r-e?V3e(e,r,t):Dp(isNaN(e)?r:e)}}function hu(t,e){var r=e-t;return r?uU(t,r):Dp(isNaN(t)?e:t)}var AA=R(()=>{"use strict";SA();o(uU,"linear");o(V3e,"exponential");o(hU,"hue");o(fU,"gamma");o(hu,"nogamma")});function dU(t){return function(e){var r=e.length,n=new Array(r),i=new Array(r),a=new Array(r),s,l;for(s=0;s<r;++s)l=Ap(e[s]),n[s]=l.r||0,i[s]=l.g||0,a[s]=l.b||0;return n=t(n),i=t(i),a=t(a),l.opacity=1,function(u){return l.r=n(u),l.g=i(u),l.b=a(u),l+""}}}var id,U3e,H3e,_A=R(()=>{"use strict";Lp();EA();cU();AA();id=o(function t(e){var r=fU(e);function n(i,a){var s=r((i=Ap(i)).r,(a=Ap(a)).r),l=r(i.g,a.g),u=r(i.b,a.b),h=hu(i.opacity,a.opacity);return function(f){return i.r=s(f),i.g=l(f),i.b=u(f),i.opacity=h(f),i+""}}return o(n,"rgb"),n.gamma=t,n},"rgbGamma")(1);o(dU,"rgbSpline");U3e=dU(kA),H3e=dU(CA)});function LA(t,e){e||(e=[]);var r=t?Math.min(e.length,t.length):0,n=e.slice(),i;return function(a){for(i=0;i<r;++i)n[i]=t[i]*(1-a)+e[i]*a;return n}}function pU(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}var mU=R(()=>{"use strict";o(LA,"default");o(pU,"isNumberArray")});function gU(t,e){var r=e?e.length:0,n=t?Math.min(r,t.length):0,i=new Array(n),a=new Array(r),s;for(s=0;s<n;++s)i[s]=Ch(t[s],e[s]);for(;s<r;++s)a[s]=e[s];return function(l){for(s=0;s<n;++s)a[s]=i[s](l);return a}}var yU=R(()=>{"use strict";X4();o(gU,"genericArray")});function DA(t,e){var r=new Date;return t=+t,e=+e,function(n){return r.setTime(t*(1-n)+e*n),r}}var vU=R(()=>{"use strict";o(DA,"default")});function ji(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}}var wy=R(()=>{"use strict";o(ji,"default")});function RA(t,e){var r={},n={},i;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(i in e)i in t?r[i]=Ch(t[i],e[i]):n[i]=e[i];return function(a){for(i in r)n[i]=r[i](a);return n}}var xU=R(()=>{"use strict";X4();o(RA,"default")});function Y3e(t){return function(){return t}}function W3e(t){return function(e){return t(e)+""}}function Rp(t,e){var r=MA.lastIndex=NA.lastIndex=0,n,i,a,s=-1,l=[],u=[];for(t=t+"",e=e+"";(n=MA.exec(t))&&(i=NA.exec(e));)(a=i.index)>r&&(a=e.slice(r,a),l[s]?l[s]+=a:l[++s]=a),(n=n[0])===(i=i[0])?l[s]?l[s]+=i:l[++s]=i:(l[++s]=null,u.push({i:s,x:ji(n,i)})),r=NA.lastIndex;return r<e.length&&(a=e.slice(r),l[s]?l[s]+=a:l[++s]=a),l.length<2?u[0]?W3e(u[0].x):Y3e(e):(e=u.length,function(h){for(var f=0,d;f<e;++f)l[(d=u[f]).i]=d.x(h);return l.join("")})}var MA,NA,IA=R(()=>{"use strict";wy();MA=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,NA=new RegExp(MA.source,"g");o(Y3e,"zero");o(W3e,"one");o(Rp,"default")});function Ch(t,e){var r=typeof e,n;return e==null||r==="boolean"?Dp(e):(r==="number"?ji:r==="string"?(n=pl(e))?(e=n,id):Rp:e instanceof pl?id:e instanceof Date?DA:pU(e)?LA:Array.isArray(e)?gU:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?RA:ji)(t,e)}var X4=R(()=>{"use strict";Lp();_A();yU();vU();wy();xU();IA();SA();mU();o(Ch,"default")});function j4(t,e){return t=+t,e=+e,function(r){return Math.round(t*(1-r)+e*r)}}var bU=R(()=>{"use strict";o(j4,"default")});function Q4(t,e,r,n,i,a){var s,l,u;return(s=Math.sqrt(t*t+e*e))&&(t/=s,e/=s),(u=t*r+e*n)&&(r-=t*u,n-=e*u),(l=Math.sqrt(r*r+n*n))&&(r/=l,n/=l,u/=l),t*n<e*r&&(t=-t,e=-e,u=-u,s=-s),{translateX:i,translateY:a,rotate:Math.atan2(e,t)*wU,skewX:Math.atan(u)*wU,scaleX:s,scaleY:l}}var wU,K4,TU=R(()=>{"use strict";wU=180/Math.PI,K4={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};o(Q4,"default")});function kU(t){let e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?K4:Q4(e.a,e.b,e.c,e.d,e.e,e.f)}function EU(t){return t==null?K4:(Z4||(Z4=document.createElementNS("http://www.w3.org/2000/svg","g")),Z4.setAttribute("transform",t),(t=Z4.transform.baseVal.consolidate())?(t=t.matrix,Q4(t.a,t.b,t.c,t.d,t.e,t.f)):K4)}var Z4,CU=R(()=>{"use strict";TU();o(kU,"parseCss");o(EU,"parseSvg")});function SU(t,e,r,n){function i(h){return h.length?h.pop()+" ":""}o(i,"pop");function a(h,f,d,p,m,g){if(h!==d||f!==p){var y=m.push("translate(",null,e,null,r);g.push({i:y-4,x:ji(h,d)},{i:y-2,x:ji(f,p)})}else(d||p)&&m.push("translate("+d+e+p+r)}o(a,"translate");function s(h,f,d,p){h!==f?(h-f>180?f+=360:f-h>180&&(h+=360),p.push({i:d.push(i(d)+"rotate(",null,n)-2,x:ji(h,f)})):f&&d.push(i(d)+"rotate("+f+n)}o(s,"rotate");function l(h,f,d,p){h!==f?p.push({i:d.push(i(d)+"skewX(",null,n)-2,x:ji(h,f)}):f&&d.push(i(d)+"skewX("+f+n)}o(l,"skewX");function u(h,f,d,p,m,g){if(h!==d||f!==p){var y=m.push(i(m)+"scale(",null,",",null,")");g.push({i:y-4,x:ji(h,d)},{i:y-2,x:ji(f,p)})}else(d!==1||p!==1)&&m.push(i(m)+"scale("+d+","+p+")")}return o(u,"scale"),function(h,f){var d=[],p=[];return h=t(h),f=t(f),a(h.translateX,h.translateY,f.translateX,f.translateY,d,p),s(h.rotate,f.rotate,d,p),l(h.skewX,f.skewX,d,p),u(h.scaleX,h.scaleY,f.scaleX,f.scaleY,d,p),h=f=null,function(m){for(var g=-1,y=p.length,v;++g<y;)d[(v=p[g]).i]=v.x(m);return d.join("")}}}var OA,PA,AU=R(()=>{"use strict";wy();CU();o(SU,"interpolateTransform");OA=SU(kU,"px, ","px)","deg)"),PA=SU(EU,", ",")",")")});function _U(t){return function(e,r){var n=t((e=by(e)).h,(r=by(r)).h),i=hu(e.c,r.c),a=hu(e.l,r.l),s=hu(e.opacity,r.opacity);return function(l){return e.h=n(l),e.c=i(l),e.l=a(l),e.opacity=s(l),e+""}}}var BA,q3e,LU=R(()=>{"use strict";Lp();AA();o(_U,"hcl");BA=_U(hU),q3e=_U(hu)});var Np=R(()=>{"use strict";X4();wy();bU();IA();AU();_A();LU()});function Ay(){return ad||(NU(X3e),ad=Cy.now()+t3)}function X3e(){ad=0}function Sy(){this._call=this._time=this._next=null}function r3(t,e,r){var n=new Sy;return n.restart(t,e,r),n}function MU(){Ay(),++Mp;for(var t=J4,e;t;)(e=ad-t._time)>=0&&t._call.call(void 0,e),t=t._next;--Mp}function DU(){ad=(e3=Cy.now())+t3,Mp=ky=0;try{MU()}finally{Mp=0,K3e(),ad=0}}function j3e(){var t=Cy.now(),e=t-e3;e>RU&&(t3-=e,e3=t)}function K3e(){for(var t,e=J4,r,n=1/0;e;)e._call?(n>e._time&&(n=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:J4=r);Ey=t,FA(n)}function FA(t){if(!Mp){ky&&(ky=clearTimeout(ky));var e=t-ad;e>24?(t<1/0&&(ky=setTimeout(DU,t-Cy.now()-t3)),Ty&&(Ty=clearInterval(Ty))):(Ty||(e3=Cy.now(),Ty=setInterval(j3e,RU)),Mp=1,NU(DU))}}var Mp,ky,Ty,RU,J4,Ey,e3,ad,t3,Cy,NU,zA=R(()=>{"use strict";Mp=0,ky=0,Ty=0,RU=1e3,e3=0,ad=0,t3=0,Cy=typeof performance=="object"&&performance.now?performance:Date,NU=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};o(Ay,"now");o(X3e,"clearNow");o(Sy,"Timer");Sy.prototype=r3.prototype={constructor:Sy,restart:o(function(t,e,r){if(typeof t!="function")throw new TypeError("callback is not a function");r=(r==null?Ay():+r)+(e==null?0:+e),!this._next&&Ey!==this&&(Ey?Ey._next=this:J4=this,Ey=this),this._call=t,this._time=r,FA()},"restart"),stop:o(function(){this._call&&(this._call=null,this._time=1/0,FA())},"stop")};o(r3,"timer");o(MU,"timerFlush");o(DU,"wake");o(j3e,"poke");o(K3e,"nap");o(FA,"sleep")});function _y(t,e,r){var n=new Sy;return e=e==null?0:+e,n.restart(i=>{n.stop(),t(i+e)},e,r),n}var IU=R(()=>{"use strict";zA();o(_y,"default")});var n3=R(()=>{"use strict";zA();IU()});function fu(t,e,r,n,i,a){var s=t.__transition;if(!s)t.__transition={};else if(r in s)return;J3e(t,r,{name:e,index:n,group:i,on:Q3e,tween:Z3e,time:a.time,delay:a.delay,duration:a.duration,ease:a.ease,timer:null,state:BU})}function Dy(t,e){var r=Mi(t,e);if(r.state>BU)throw new Error("too late; already scheduled");return r}function ca(t,e){var r=Mi(t,e);if(r.state>i3)throw new Error("too late; already running");return r}function Mi(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function J3e(t,e,r){var n=t.__transition,i;n[e]=r,r.timer=r3(a,0,r.time);function a(h){r.state=OU,r.timer.restart(s,r.delay,r.time),r.delay<=h&&s(h-r.delay)}o(a,"schedule");function s(h){var f,d,p,m;if(r.state!==OU)return u();for(f in n)if(m=n[f],m.name===r.name){if(m.state===i3)return _y(s);m.state===PU?(m.state=Ly,m.timer.stop(),m.on.call("interrupt",t,t.__data__,m.index,m.group),delete n[f]):+f<e&&(m.state=Ly,m.timer.stop(),m.on.call("cancel",t,t.__data__,m.index,m.group),delete n[f])}if(_y(function(){r.state===i3&&(r.state=PU,r.timer.restart(l,r.delay,r.time),l(h))}),r.state=a3,r.on.call("start",t,t.__data__,r.index,r.group),r.state===a3){for(r.state=i3,i=new Array(p=r.tween.length),f=0,d=-1;f<p;++f)(m=r.tween[f].value.call(t,t.__data__,r.index,r.group))&&(i[++d]=m);i.length=d+1}}o(s,"start");function l(h){for(var f=h<r.duration?r.ease.call(null,h/r.duration):(r.timer.restart(u),r.state=s3,1),d=-1,p=i.length;++d<p;)i[d].call(t,f);r.state===s3&&(r.on.call("end",t,t.__data__,r.index,r.group),u())}o(l,"tick");function u(){r.state=Ly,r.timer.stop(),delete n[e];for(var h in n)return;delete t.__transition}o(u,"stop")}var Q3e,Z3e,BU,OU,a3,i3,PU,s3,Ly,ys=R(()=>{"use strict";bS();n3();Q3e=xS("start","end","cancel","interrupt"),Z3e=[],BU=0,OU=1,a3=2,i3=3,PU=4,s3=5,Ly=6;o(fu,"default");o(Dy,"init");o(ca,"set");o(Mi,"get");o(J3e,"create")});function Ry(t,e){var r=t.__transition,n,i,a=!0,s;if(r){e=e==null?null:e+"";for(s in r){if((n=r[s]).name!==e){a=!1;continue}i=n.state>a3&&n.state<s3,n.state=Ly,n.timer.stop(),n.on.call(i?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete r[s]}a&&delete t.__transition}}var FU=R(()=>{"use strict";ys();o(Ry,"default")});function GA(t){return this.each(function(){Ry(this,t)})}var zU=R(()=>{"use strict";FU();o(GA,"default")});function e5e(t,e){var r,n;return function(){var i=ca(this,t),a=i.tween;if(a!==r){n=r=a;for(var s=0,l=n.length;s<l;++s)if(n[s].name===e){n=n.slice(),n.splice(s,1);break}}i.tween=n}}function t5e(t,e,r){var n,i;if(typeof r!="function")throw new Error;return function(){var a=ca(this,t),s=a.tween;if(s!==n){i=(n=s).slice();for(var l={name:e,value:r},u=0,h=i.length;u<h;++u)if(i[u].name===e){i[u]=l;break}u===h&&i.push(l)}a.tween=i}}function $A(t,e){var r=this._id;if(t+="",arguments.length<2){for(var n=Mi(this.node(),r).tween,i=0,a=n.length,s;i<a;++i)if((s=n[i]).name===t)return s.value;return null}return this.each((e==null?e5e:t5e)(r,t,e))}function Ip(t,e,r){var n=t._id;return t.each(function(){var i=ca(this,n);(i.value||(i.value={}))[e]=r.apply(this,arguments)}),function(i){return Mi(i,n).value[e]}}var Ny=R(()=>{"use strict";ys();o(e5e,"tweenRemove");o(t5e,"tweenFunction");o($A,"default");o(Ip,"tweenValue")});function My(t,e){var r;return(typeof e=="number"?ji:e instanceof pl?id:(r=pl(e))?(e=r,id):Rp)(t,e)}var VA=R(()=>{"use strict";Lp();Np();o(My,"default")});function r5e(t){return function(){this.removeAttribute(t)}}function n5e(t){return function(){this.removeAttributeNS(t.space,t.local)}}function i5e(t,e,r){var n,i=r+"",a;return function(){var s=this.getAttribute(t);return s===i?null:s===n?a:a=e(n=s,r)}}function a5e(t,e,r){var n,i=r+"",a;return function(){var s=this.getAttributeNS(t.space,t.local);return s===i?null:s===n?a:a=e(n=s,r)}}function s5e(t,e,r){var n,i,a;return function(){var s,l=r(this),u;return l==null?void this.removeAttribute(t):(s=this.getAttribute(t),u=l+"",s===u?null:s===n&&u===i?a:(i=u,a=e(n=s,l)))}}function o5e(t,e,r){var n,i,a;return function(){var s,l=r(this),u;return l==null?void this.removeAttributeNS(t.space,t.local):(s=this.getAttributeNS(t.space,t.local),u=l+"",s===u?null:s===n&&u===i?a:(i=u,a=e(n=s,l)))}}function UA(t,e){var r=ic(t),n=r==="transform"?PA:My;return this.attrTween(t,typeof e=="function"?(r.local?o5e:s5e)(r,n,Ip(this,"attr."+t,e)):e==null?(r.local?n5e:r5e)(r):(r.local?a5e:i5e)(r,n,e))}var GU=R(()=>{"use strict";Np();fl();Ny();VA();o(r5e,"attrRemove");o(n5e,"attrRemoveNS");o(i5e,"attrConstant");o(a5e,"attrConstantNS");o(s5e,"attrFunction");o(o5e,"attrFunctionNS");o(UA,"default")});function l5e(t,e){return function(r){this.setAttribute(t,e.call(this,r))}}function c5e(t,e){return function(r){this.setAttributeNS(t.space,t.local,e.call(this,r))}}function u5e(t,e){var r,n;function i(){var a=e.apply(this,arguments);return a!==n&&(r=(n=a)&&c5e(t,a)),r}return o(i,"tween"),i._value=e,i}function h5e(t,e){var r,n;function i(){var a=e.apply(this,arguments);return a!==n&&(r=(n=a)&&l5e(t,a)),r}return o(i,"tween"),i._value=e,i}function HA(t,e){var r="attr."+t;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(e==null)return this.tween(r,null);if(typeof e!="function")throw new Error;var n=ic(t);return this.tween(r,(n.local?u5e:h5e)(n,e))}var $U=R(()=>{"use strict";fl();o(l5e,"attrInterpolate");o(c5e,"attrInterpolateNS");o(u5e,"attrTweenNS");o(h5e,"attrTween");o(HA,"default")});function f5e(t,e){return function(){Dy(this,t).delay=+e.apply(this,arguments)}}function d5e(t,e){return e=+e,function(){Dy(this,t).delay=e}}function YA(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?f5e:d5e)(e,t)):Mi(this.node(),e).delay}var VU=R(()=>{"use strict";ys();o(f5e,"delayFunction");o(d5e,"delayConstant");o(YA,"default")});function p5e(t,e){return function(){ca(this,t).duration=+e.apply(this,arguments)}}function m5e(t,e){return e=+e,function(){ca(this,t).duration=e}}function WA(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?p5e:m5e)(e,t)):Mi(this.node(),e).duration}var UU=R(()=>{"use strict";ys();o(p5e,"durationFunction");o(m5e,"durationConstant");o(WA,"default")});function g5e(t,e){if(typeof e!="function")throw new Error;return function(){ca(this,t).ease=e}}function qA(t){var e=this._id;return arguments.length?this.each(g5e(e,t)):Mi(this.node(),e).ease}var HU=R(()=>{"use strict";ys();o(g5e,"easeConstant");o(qA,"default")});function y5e(t,e){return function(){var r=e.apply(this,arguments);if(typeof r!="function")throw new Error;ca(this,t).ease=r}}function XA(t){if(typeof t!="function")throw new Error;return this.each(y5e(this._id,t))}var YU=R(()=>{"use strict";ys();o(y5e,"easeVarying");o(XA,"default")});function jA(t){typeof t!="function"&&(t=Ep(t));for(var e=this._groups,r=e.length,n=new Array(r),i=0;i<r;++i)for(var a=e[i],s=a.length,l=n[i]=[],u,h=0;h<s;++h)(u=a[h])&&t.call(u,u.__data__,h,a)&&l.push(u);return new Ka(n,this._parents,this._name,this._id)}var WU=R(()=>{"use strict";fl();sd();o(jA,"default")});function KA(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,r=t._groups,n=e.length,i=r.length,a=Math.min(n,i),s=new Array(n),l=0;l<a;++l)for(var u=e[l],h=r[l],f=u.length,d=s[l]=new Array(f),p,m=0;m<f;++m)(p=u[m]||h[m])&&(d[m]=p);for(;l<n;++l)s[l]=e[l];return new Ka(s,this._parents,this._name,this._id)}var qU=R(()=>{"use strict";sd();o(KA,"default")});function v5e(t){return(t+"").trim().split(/^|\s+/).every(function(e){var r=e.indexOf(".");return r>=0&&(e=e.slice(0,r)),!e||e==="start"})}function x5e(t,e,r){var n,i,a=v5e(e)?Dy:ca;return function(){var s=a(this,t),l=s.on;l!==n&&(i=(n=l).copy()).on(e,r),s.on=i}}function QA(t,e){var r=this._id;return arguments.length<2?Mi(this.node(),r).on.on(t):this.each(x5e(r,t,e))}var XU=R(()=>{"use strict";ys();o(v5e,"start");o(x5e,"onFunction");o(QA,"default")});function b5e(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}function ZA(){return this.on("end.remove",b5e(this._id))}var jU=R(()=>{"use strict";o(b5e,"removeFunction");o(ZA,"default")});function JA(t){var e=this._name,r=this._id;typeof t!="function"&&(t=wh(t));for(var n=this._groups,i=n.length,a=new Array(i),s=0;s<i;++s)for(var l=n[s],u=l.length,h=a[s]=new Array(u),f,d,p=0;p<u;++p)(f=l[p])&&(d=t.call(f,f.__data__,p,l))&&("__data__"in f&&(d.__data__=f.__data__),h[p]=d,fu(h[p],e,r,p,h,Mi(f,r)));return new Ka(a,this._parents,e,r)}var KU=R(()=>{"use strict";fl();sd();ys();o(JA,"default")});function e8(t){var e=this._name,r=this._id;typeof t!="function"&&(t=kp(t));for(var n=this._groups,i=n.length,a=[],s=[],l=0;l<i;++l)for(var u=n[l],h=u.length,f,d=0;d<h;++d)if(f=u[d]){for(var p=t.call(f,f.__data__,d,u),m,g=Mi(f,r),y=0,v=p.length;y<v;++y)(m=p[y])&&fu(m,e,r,y,p,g);a.push(p),s.push(f)}return new Ka(a,s,e,r)}var QU=R(()=>{"use strict";fl();sd();ys();o(e8,"default")});function t8(){return new w5e(this._groups,this._parents)}var w5e,ZU=R(()=>{"use strict";fl();w5e=cu.prototype.constructor;o(t8,"default")});function T5e(t,e){var r,n,i;return function(){var a=Th(this,t),s=(this.style.removeProperty(t),Th(this,t));return a===s?null:a===r&&s===n?i:i=e(r=a,n=s)}}function JU(t){return function(){this.style.removeProperty(t)}}function k5e(t,e,r){var n,i=r+"",a;return function(){var s=Th(this,t);return s===i?null:s===n?a:a=e(n=s,r)}}function E5e(t,e,r){var n,i,a;return function(){var s=Th(this,t),l=r(this),u=l+"";return l==null&&(u=l=(this.style.removeProperty(t),Th(this,t))),s===u?null:s===n&&u===i?a:(i=u,a=e(n=s,l))}}function C5e(t,e){var r,n,i,a="style."+e,s="end."+a,l;return function(){var u=ca(this,t),h=u.on,f=u.value[a]==null?l||(l=JU(e)):void 0;(h!==r||i!==f)&&(n=(r=h).copy()).on(s,i=f),u.on=n}}function r8(t,e,r){var n=(t+="")=="transform"?OA:My;return e==null?this.styleTween(t,T5e(t,n)).on("end.style."+t,JU(t)):typeof e=="function"?this.styleTween(t,E5e(t,n,Ip(this,"style."+t,e))).each(C5e(this._id,t)):this.styleTween(t,k5e(t,n,e),r).on("end.style."+t,null)}var eH=R(()=>{"use strict";Np();fl();ys();Ny();VA();o(T5e,"styleNull");o(JU,"styleRemove");o(k5e,"styleConstant");o(E5e,"styleFunction");o(C5e,"styleMaybeRemove");o(r8,"default")});function S5e(t,e,r){return function(n){this.style.setProperty(t,e.call(this,n),r)}}function A5e(t,e,r){var n,i;function a(){var s=e.apply(this,arguments);return s!==i&&(n=(i=s)&&S5e(t,s,r)),n}return o(a,"tween"),a._value=e,a}function n8(t,e,r){var n="style."+(t+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;return this.tween(n,A5e(t,e,r??""))}var tH=R(()=>{"use strict";o(S5e,"styleInterpolate");o(A5e,"styleTween");o(n8,"default")});function _5e(t){return function(){this.textContent=t}}function L5e(t){return function(){var e=t(this);this.textContent=e??""}}function i8(t){return this.tween("text",typeof t=="function"?L5e(Ip(this,"text",t)):_5e(t==null?"":t+""))}var rH=R(()=>{"use strict";Ny();o(_5e,"textConstant");o(L5e,"textFunction");o(i8,"default")});function D5e(t){return function(e){this.textContent=t.call(this,e)}}function R5e(t){var e,r;function n(){var i=t.apply(this,arguments);return i!==r&&(e=(r=i)&&D5e(i)),e}return o(n,"tween"),n._value=t,n}function a8(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,R5e(t))}var nH=R(()=>{"use strict";o(D5e,"textInterpolate");o(R5e,"textTween");o(a8,"default")});function s8(){for(var t=this._name,e=this._id,r=o3(),n=this._groups,i=n.length,a=0;a<i;++a)for(var s=n[a],l=s.length,u,h=0;h<l;++h)if(u=s[h]){var f=Mi(u,e);fu(u,t,r,h,s,{time:f.time+f.delay+f.duration,delay:0,duration:f.duration,ease:f.ease})}return new Ka(n,this._parents,t,r)}var iH=R(()=>{"use strict";sd();ys();o(s8,"default")});function o8(){var t,e,r=this,n=r._id,i=r.size();return new Promise(function(a,s){var l={value:s},u={value:o(function(){--i===0&&a()},"value")};r.each(function(){var h=ca(this,n),f=h.on;f!==t&&(e=(t=f).copy(),e._.cancel.push(l),e._.interrupt.push(l),e._.end.push(u)),h.on=e}),i===0&&a()})}var aH=R(()=>{"use strict";ys();o(o8,"default")});function Ka(t,e,r,n){this._groups=t,this._parents=e,this._name=r,this._id=n}function sH(t){return cu().transition(t)}function o3(){return++N5e}var N5e,du,sd=R(()=>{"use strict";fl();GU();$U();VU();UU();HU();YU();WU();qU();XU();jU();KU();QU();ZU();eH();tH();rH();nH();iH();Ny();aH();N5e=0;o(Ka,"Transition");o(sH,"transition");o(o3,"newId");du=cu.prototype;Ka.prototype=sH.prototype={constructor:Ka,select:JA,selectAll:e8,selectChild:du.selectChild,selectChildren:du.selectChildren,filter:jA,merge:KA,selection:t8,transition:s8,call:du.call,nodes:du.nodes,node:du.node,size:du.size,empty:du.empty,each:du.each,on:QA,attr:UA,attrTween:HA,style:r8,styleTween:n8,text:i8,textTween:a8,remove:ZA,tween:$A,delay:YA,duration:WA,ease:qA,easeVarying:XA,end:o8,[Symbol.iterator]:du[Symbol.iterator]}});function l3(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var oH=R(()=>{"use strict";o(l3,"cubicInOut")});var l8=R(()=>{"use strict";oH()});function I5e(t,e){for(var r;!(r=t.__transition)||!(r=r[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return r}function c8(t){var e,r;t instanceof Ka?(e=t._id,t=t._name):(e=o3(),(r=M5e).time=Ay(),t=t==null?null:t+"");for(var n=this._groups,i=n.length,a=0;a<i;++a)for(var s=n[a],l=s.length,u,h=0;h<l;++h)(u=s[h])&&fu(u,t,e,h,s,r||I5e(u,e));return new Ka(n,this._parents,t,e)}var M5e,lH=R(()=>{"use strict";sd();ys();l8();n3();M5e={time:null,delay:0,duration:250,ease:l3};o(I5e,"inherit");o(c8,"default")});var cH=R(()=>{"use strict";fl();zU();lH();cu.prototype.interrupt=GA;cu.prototype.transition=c8});var c3=R(()=>{"use strict";cH()});var uH=R(()=>{"use strict"});var hH=R(()=>{"use strict"});var fH=R(()=>{"use strict"});function dH(t){return[+t[0],+t[1]]}function O5e(t){return[dH(t[0]),dH(t[1])]}function u8(t){return{type:t}}var Kpt,Qpt,Zpt,Jpt,emt,tmt,pH=R(()=>{"use strict";c3();uH();hH();fH();({abs:Kpt,max:Qpt,min:Zpt}=Math);o(dH,"number1");o(O5e,"number2");Jpt={name:"x",handles:["w","e"].map(u8),input:o(function(t,e){return t==null?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},"input"),output:o(function(t){return t&&[t[0][0],t[1][0]]},"output")},emt={name:"y",handles:["n","s"].map(u8),input:o(function(t,e){return t==null?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},"input"),output:o(function(t){return t&&[t[0][1],t[1][1]]},"output")},tmt={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(u8),input:o(function(t){return t==null?null:O5e(t)},"input"),output:o(function(t){return t},"output")};o(u8,"type")});var mH=R(()=>{"use strict";pH()});function gH(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=arguments[e]+t[e]}function B5e(t){let e=Math.floor(t);if(!(e>=0))throw new Error(`invalid digits: ${t}`);if(e>15)return gH;let r=10**e;return function(n){this._+=n[0];for(let i=1,a=n.length;i<a;++i)this._+=Math.round(arguments[i]*r)/r+n[i]}}function yH(){return new ld}var h8,f8,od,P5e,ld,vH=R(()=>{"use strict";h8=Math.PI,f8=2*h8,od=1e-6,P5e=f8-od;o(gH,"append");o(B5e,"appendRound");ld=class{static{o(this,"Path")}constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=e==null?gH:B5e(e)}moveTo(e,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,r){this._append`L${this._x1=+e},${this._y1=+r}`}quadraticCurveTo(e,r,n,i){this._append`Q${+e},${+r},${this._x1=+n},${this._y1=+i}`}bezierCurveTo(e,r,n,i,a,s){this._append`C${+e},${+r},${+n},${+i},${this._x1=+a},${this._y1=+s}`}arcTo(e,r,n,i,a){if(e=+e,r=+r,n=+n,i=+i,a=+a,a<0)throw new Error(`negative radius: ${a}`);let s=this._x1,l=this._y1,u=n-e,h=i-r,f=s-e,d=l-r,p=f*f+d*d;if(this._x1===null)this._append`M${this._x1=e},${this._y1=r}`;else if(p>od)if(!(Math.abs(d*u-h*f)>od)||!a)this._append`L${this._x1=e},${this._y1=r}`;else{let m=n-s,g=i-l,y=u*u+h*h,v=m*m+g*g,x=Math.sqrt(y),b=Math.sqrt(p),w=a*Math.tan((h8-Math.acos((y+p-v)/(2*x*b)))/2),S=w/b,T=w/x;Math.abs(S-1)>od&&this._append`L${e+S*f},${r+S*d}`,this._append`A${a},${a},0,0,${+(d*m>f*g)},${this._x1=e+T*u},${this._y1=r+T*h}`}}arc(e,r,n,i,a,s){if(e=+e,r=+r,n=+n,s=!!s,n<0)throw new Error(`negative radius: ${n}`);let l=n*Math.cos(i),u=n*Math.sin(i),h=e+l,f=r+u,d=1^s,p=s?i-a:a-i;this._x1===null?this._append`M${h},${f}`:(Math.abs(this._x1-h)>od||Math.abs(this._y1-f)>od)&&this._append`L${h},${f}`,n&&(p<0&&(p=p%f8+f8),p>P5e?this._append`A${n},${n},0,1,${d},${e-l},${r-u}A${n},${n},0,1,${d},${this._x1=h},${this._y1=f}`:p>od&&this._append`A${n},${n},0,${+(p>=h8)},${d},${this._x1=e+n*Math.cos(a)},${this._y1=r+n*Math.sin(a)}`)}rect(e,r,n,i){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}h${n=+n}v${+i}h${-n}Z`}toString(){return this._}};o(yH,"path");yH.prototype=ld.prototype});var d8=R(()=>{"use strict";vH()});var xH=R(()=>{"use strict"});var bH=R(()=>{"use strict"});var wH=R(()=>{"use strict"});var TH=R(()=>{"use strict"});var kH=R(()=>{"use strict"});var EH=R(()=>{"use strict"});var CH=R(()=>{"use strict"});function p8(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function cd(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,n=t.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+t.slice(r+1)]}var Iy=R(()=>{"use strict";o(p8,"default");o(cd,"formatDecimalParts")});function ml(t){return t=cd(Math.abs(t)),t?t[1]:NaN}var Oy=R(()=>{"use strict";Iy();o(ml,"default")});function m8(t,e){return function(r,n){for(var i=r.length,a=[],s=0,l=t[0],u=0;i>0&&l>0&&(u+l+1>n&&(l=Math.max(1,n-u)),a.push(r.substring(i-=l,i+l)),!((u+=l+1)>n));)l=t[s=(s+1)%t.length];return a.reverse().join(e)}}var SH=R(()=>{"use strict";o(m8,"default")});function g8(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}var AH=R(()=>{"use strict";o(g8,"default")});function Sh(t){if(!(e=F5e.exec(t)))throw new Error("invalid format: "+t);var e;return new u3({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function u3(t){this.fill=t.fill===void 0?" ":t.fill+"",this.align=t.align===void 0?">":t.align+"",this.sign=t.sign===void 0?"-":t.sign+"",this.symbol=t.symbol===void 0?"":t.symbol+"",this.zero=!!t.zero,this.width=t.width===void 0?void 0:+t.width,this.comma=!!t.comma,this.precision=t.precision===void 0?void 0:+t.precision,this.trim=!!t.trim,this.type=t.type===void 0?"":t.type+""}var F5e,y8=R(()=>{"use strict";F5e=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;o(Sh,"formatSpecifier");Sh.prototype=u3.prototype;o(u3,"FormatSpecifier");u3.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type}});function v8(t){e:for(var e=t.length,r=1,n=-1,i;r<e;++r)switch(t[r]){case".":n=i=r;break;case"0":n===0&&(n=r),i=r;break;default:if(!+t[r])break e;n>0&&(n=0);break}return n>0?t.slice(0,n)+t.slice(i+1):t}var _H=R(()=>{"use strict";o(v8,"default")});function b8(t,e){var r=cd(t,e);if(!r)return t+"";var n=r[0],i=r[1],a=i-(x8=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,s=n.length;return a===s?n:a>s?n+new Array(a-s+1).join("0"):a>0?n.slice(0,a)+"."+n.slice(a):"0."+new Array(1-a).join("0")+cd(t,Math.max(0,e+a-1))[0]}var x8,w8=R(()=>{"use strict";Iy();o(b8,"default")});function h3(t,e){var r=cd(t,e);if(!r)return t+"";var n=r[0],i=r[1];return i<0?"0."+new Array(-i).join("0")+n:n.length>i+1?n.slice(0,i+1)+"."+n.slice(i+1):n+new Array(i-n.length+2).join("0")}var LH=R(()=>{"use strict";Iy();o(h3,"default")});var T8,DH=R(()=>{"use strict";Iy();w8();LH();T8={"%":o((t,e)=>(t*100).toFixed(e),"%"),b:o(t=>Math.round(t).toString(2),"b"),c:o(t=>t+"","c"),d:p8,e:o((t,e)=>t.toExponential(e),"e"),f:o((t,e)=>t.toFixed(e),"f"),g:o((t,e)=>t.toPrecision(e),"g"),o:o(t=>Math.round(t).toString(8),"o"),p:o((t,e)=>h3(t*100,e),"p"),r:h3,s:b8,X:o(t=>Math.round(t).toString(16).toUpperCase(),"X"),x:o(t=>Math.round(t).toString(16),"x")}});function f3(t){return t}var RH=R(()=>{"use strict";o(f3,"default")});function k8(t){var e=t.grouping===void 0||t.thousands===void 0?f3:m8(NH.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",n=t.currency===void 0?"":t.currency[1]+"",i=t.decimal===void 0?".":t.decimal+"",a=t.numerals===void 0?f3:g8(NH.call(t.numerals,String)),s=t.percent===void 0?"%":t.percent+"",l=t.minus===void 0?"\u2212":t.minus+"",u=t.nan===void 0?"NaN":t.nan+"";function h(d){d=Sh(d);var p=d.fill,m=d.align,g=d.sign,y=d.symbol,v=d.zero,x=d.width,b=d.comma,w=d.precision,S=d.trim,T=d.type;T==="n"?(b=!0,T="g"):T8[T]||(w===void 0&&(w=12),S=!0,T="g"),(v||p==="0"&&m==="=")&&(v=!0,p="0",m="=");var E=y==="$"?r:y==="#"&&/[boxX]/.test(T)?"0"+T.toLowerCase():"",_=y==="$"?n:/[%p]/.test(T)?s:"",A=T8[T],L=/[defgprs%]/.test(T);w=w===void 0?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w));function M(N){var k=E,I=_,C,O,D;if(T==="c")I=A(N)+I,N="";else{N=+N;var P=N<0||1/N<0;if(N=isNaN(N)?u:A(Math.abs(N),w),S&&(N=v8(N)),P&&+N==0&&g!=="+"&&(P=!1),k=(P?g==="("?g:l:g==="-"||g==="("?"":g)+k,I=(T==="s"?MH[8+x8/3]:"")+I+(P&&g==="("?")":""),L){for(C=-1,O=N.length;++C<O;)if(D=N.charCodeAt(C),48>D||D>57){I=(D===46?i+N.slice(C+1):N.slice(C))+I,N=N.slice(0,C);break}}}b&&!v&&(N=e(N,1/0));var F=k.length+N.length+I.length,B=F<x?new Array(x-F+1).join(p):"";switch(b&&v&&(N=e(B+N,B.length?x-I.length:1/0),B=""),m){case"<":N=k+N+I+B;break;case"=":N=k+B+N+I;break;case"^":N=B.slice(0,F=B.length>>1)+k+N+I+B.slice(F);break;default:N=B+k+N+I;break}return a(N)}return o(M,"format"),M.toString=function(){return d+""},M}o(h,"newFormat");function f(d,p){var m=h((d=Sh(d),d.type="f",d)),g=Math.max(-8,Math.min(8,Math.floor(ml(p)/3)))*3,y=Math.pow(10,-g),v=MH[8+g/3];return function(x){return m(y*x)+v}}return o(f,"formatPrefix"),{format:h,formatPrefix:f}}var NH,MH,IH=R(()=>{"use strict";Oy();SH();AH();y8();_H();DH();w8();RH();NH=Array.prototype.map,MH=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];o(k8,"default")});function E8(t){return d3=k8(t),p3=d3.format,m3=d3.formatPrefix,d3}var d3,p3,m3,OH=R(()=>{"use strict";IH();E8({thousands:",",grouping:[3],currency:["$",""]});o(E8,"defaultLocale")});function g3(t){return Math.max(0,-ml(Math.abs(t)))}var PH=R(()=>{"use strict";Oy();o(g3,"default")});function y3(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ml(e)/3)))*3-ml(Math.abs(t)))}var BH=R(()=>{"use strict";Oy();o(y3,"default")});function v3(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,ml(e)-ml(t))+1}var FH=R(()=>{"use strict";Oy();o(v3,"default")});var C8=R(()=>{"use strict";OH();y8();PH();BH();FH()});var zH=R(()=>{"use strict"});var GH=R(()=>{"use strict"});var $H=R(()=>{"use strict"});var VH=R(()=>{"use strict"});function Ah(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}var Py=R(()=>{"use strict";o(Ah,"initRange")});function pu(){var t=new wp,e=[],r=[],n=S8;function i(a){let s=t.get(a);if(s===void 0){if(n!==S8)return n;t.set(a,s=e.push(a)-1)}return r[s%r.length]}return o(i,"scale"),i.domain=function(a){if(!arguments.length)return e.slice();e=[],t=new wp;for(let s of a)t.has(s)||t.set(s,e.push(s)-1);return i},i.range=function(a){return arguments.length?(r=Array.from(a),i):r.slice()},i.unknown=function(a){return arguments.length?(n=a,i):n},i.copy=function(){return pu(e,r).unknown(n)},Ah.apply(i,arguments),i}var S8,A8=R(()=>{"use strict";bh();Py();S8=Symbol("implicit");o(pu,"ordinal")});function Op(){var t=pu().unknown(void 0),e=t.domain,r=t.range,n=0,i=1,a,s,l=!1,u=0,h=0,f=.5;delete t.unknown;function d(){var p=e().length,m=i<n,g=m?i:n,y=m?n:i;a=(y-g)/Math.max(1,p-u+h*2),l&&(a=Math.floor(a)),g+=(y-g-a*(p-u))*f,s=a*(1-u),l&&(g=Math.round(g),s=Math.round(s));var v=O4(p).map(function(x){return g+a*x});return r(m?v.reverse():v)}return o(d,"rescale"),t.domain=function(p){return arguments.length?(e(p),d()):e()},t.range=function(p){return arguments.length?([n,i]=p,n=+n,i=+i,d()):[n,i]},t.rangeRound=function(p){return[n,i]=p,n=+n,i=+i,l=!0,d()},t.bandwidth=function(){return s},t.step=function(){return a},t.round=function(p){return arguments.length?(l=!!p,d()):l},t.padding=function(p){return arguments.length?(u=Math.min(1,h=+p),d()):u},t.paddingInner=function(p){return arguments.length?(u=Math.min(1,p),d()):u},t.paddingOuter=function(p){return arguments.length?(h=+p,d()):h},t.align=function(p){return arguments.length?(f=Math.max(0,Math.min(1,p)),d()):f},t.copy=function(){return Op(e(),[n,i]).round(l).paddingInner(u).paddingOuter(h).align(f)},Ah.apply(d(),arguments)}var UH=R(()=>{"use strict";bh();Py();A8();o(Op,"band")});function _8(t){return function(){return t}}var HH=R(()=>{"use strict";o(_8,"constants")});function L8(t){return+t}var YH=R(()=>{"use strict";o(L8,"number")});function Pp(t){return t}function D8(t,e){return(e-=t=+t)?function(r){return(r-t)/e}:_8(isNaN(e)?NaN:.5)}function z5e(t,e){var r;return t>e&&(r=t,t=e,e=r),function(n){return Math.max(t,Math.min(e,n))}}function G5e(t,e,r){var n=t[0],i=t[1],a=e[0],s=e[1];return i<n?(n=D8(i,n),a=r(s,a)):(n=D8(n,i),a=r(a,s)),function(l){return a(n(l))}}function $5e(t,e,r){var n=Math.min(t.length,e.length)-1,i=new Array(n),a=new Array(n),s=-1;for(t[n]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++s<n;)i[s]=D8(t[s],t[s+1]),a[s]=r(e[s],e[s+1]);return function(l){var u=dS(t,l,1,n)-1;return a[u](i[u](l))}}function x3(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function V5e(){var t=WH,e=WH,r=Ch,n,i,a,s=Pp,l,u,h;function f(){var p=Math.min(t.length,e.length);return s!==Pp&&(s=z5e(t[0],t[p-1])),l=p>2?$5e:G5e,u=h=null,d}o(f,"rescale");function d(p){return p==null||isNaN(p=+p)?a:(u||(u=l(t.map(n),e,r)))(n(s(p)))}return o(d,"scale"),d.invert=function(p){return s(i((h||(h=l(e,t.map(n),ji)))(p)))},d.domain=function(p){return arguments.length?(t=Array.from(p,L8),f()):t.slice()},d.range=function(p){return arguments.length?(e=Array.from(p),f()):e.slice()},d.rangeRound=function(p){return e=Array.from(p),r=j4,f()},d.clamp=function(p){return arguments.length?(s=p?!0:Pp,f()):s!==Pp},d.interpolate=function(p){return arguments.length?(r=p,f()):r},d.unknown=function(p){return arguments.length?(a=p,d):a},function(p,m){return n=p,i=m,f()}}function By(){return V5e()(Pp,Pp)}var WH,R8=R(()=>{"use strict";bh();Np();HH();YH();WH=[0,1];o(Pp,"identity");o(D8,"normalize");o(z5e,"clamper");o(G5e,"bimap");o($5e,"polymap");o(x3,"copy");o(V5e,"transformer");o(By,"continuous")});function N8(t,e,r,n){var i=Tp(t,e,r),a;switch(n=Sh(n??",f"),n.type){case"s":{var s=Math.max(Math.abs(t),Math.abs(e));return n.precision==null&&!isNaN(a=y3(i,s))&&(n.precision=a),m3(n,s)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(a=v3(i,Math.max(Math.abs(t),Math.abs(e))))&&(n.precision=a-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(a=g3(i))&&(n.precision=a-(n.type==="%")*2);break}}return p3(n)}var qH=R(()=>{"use strict";bh();C8();o(N8,"tickFormat")});function U5e(t){var e=t.domain;return t.ticks=function(r){var n=e();return N4(n[0],n[n.length-1],r??10)},t.tickFormat=function(r,n){var i=e();return N8(i[0],i[i.length-1],r??10,n)},t.nice=function(r){r==null&&(r=10);var n=e(),i=0,a=n.length-1,s=n[i],l=n[a],u,h,f=10;for(l<s&&(h=s,s=l,l=h,h=i,i=a,a=h);f-- >0;){if(h=fy(s,l,r),h===u)return n[i]=s,n[a]=l,e(n);if(h>0)s=Math.floor(s/h)*h,l=Math.ceil(l/h)*h;else if(h<0)s=Math.ceil(s*h)/h,l=Math.floor(l*h)/h;else break;u=h}return t},t}function gl(){var t=By();return t.copy=function(){return x3(t,gl())},Ah.apply(t,arguments),U5e(t)}var XH=R(()=>{"use strict";bh();R8();Py();qH();o(U5e,"linearish");o(gl,"linear")});function M8(t,e){t=t.slice();var r=0,n=t.length-1,i=t[r],a=t[n],s;return a<i&&(s=r,r=n,n=s,s=i,i=a,a=s),t[r]=e.floor(i),t[n]=e.ceil(a),t}var jH=R(()=>{"use strict";o(M8,"nice")});function dn(t,e,r,n){function i(a){return t(a=arguments.length===0?new Date:new Date(+a)),a}return o(i,"interval"),i.floor=a=>(t(a=new Date(+a)),a),i.ceil=a=>(t(a=new Date(a-1)),e(a,1),t(a),a),i.round=a=>{let s=i(a),l=i.ceil(a);return a-s<l-a?s:l},i.offset=(a,s)=>(e(a=new Date(+a),s==null?1:Math.floor(s)),a),i.range=(a,s,l)=>{let u=[];if(a=i.ceil(a),l=l==null?1:Math.floor(l),!(a<s)||!(l>0))return u;let h;do u.push(h=new Date(+a)),e(a,l),t(a);while(h<a&&a<s);return u},i.filter=a=>dn(s=>{if(s>=s)for(;t(s),!a(s);)s.setTime(s-1)},(s,l)=>{if(s>=s)if(l<0)for(;++l<=0;)for(;e(s,-1),!a(s););else for(;--l>=0;)for(;e(s,1),!a(s););}),r&&(i.count=(a,s)=>(I8.setTime(+a),O8.setTime(+s),t(I8),t(O8),Math.floor(r(I8,O8))),i.every=a=>(a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?i.filter(n?s=>n(s)%a===0:s=>i.count(0,s)%a===0):i)),i}var I8,O8,mu=R(()=>{"use strict";I8=new Date,O8=new Date;o(dn,"timeInterval")});var oc,KH,P8=R(()=>{"use strict";mu();oc=dn(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);oc.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?dn(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):oc);KH=oc.range});var Ks,QH,B8=R(()=>{"use strict";mu();Ks=dn(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*1e3)},(t,e)=>(e-t)/1e3,t=>t.getUTCSeconds()),QH=Ks.range});var gu,H5e,b3,Y5e,F8=R(()=>{"use strict";mu();gu=dn(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getMinutes()),H5e=gu.range,b3=dn(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getUTCMinutes()),Y5e=b3.range});var yu,W5e,w3,q5e,z8=R(()=>{"use strict";mu();yu=dn(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3-t.getMinutes()*6e4)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getHours()),W5e=yu.range,w3=dn(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getUTCHours()),q5e=w3.range});var Do,X5e,zy,j5e,T3,K5e,G8=R(()=>{"use strict";mu();Do=dn(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*6e4)/864e5,t=>t.getDate()-1),X5e=Do.range,zy=dn(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>t.getUTCDate()-1),j5e=zy.range,T3=dn(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>Math.floor(t/864e5)),K5e=T3.range});function fd(t){return dn(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,r)=>{e.setDate(e.getDate()+r*7)},(e,r)=>(r-e-(r.getTimezoneOffset()-e.getTimezoneOffset())*6e4)/6048e5)}function dd(t){return dn(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCDate(e.getUTCDate()+r*7)},(e,r)=>(r-e)/6048e5)}var yl,_h,k3,E3,cc,C3,S3,JH,Q5e,Z5e,J5e,ewe,twe,rwe,pd,Bp,eY,tY,Lh,rY,nY,iY,nwe,iwe,awe,swe,owe,lwe,$8=R(()=>{"use strict";mu();o(fd,"timeWeekday");yl=fd(0),_h=fd(1),k3=fd(2),E3=fd(3),cc=fd(4),C3=fd(5),S3=fd(6),JH=yl.range,Q5e=_h.range,Z5e=k3.range,J5e=E3.range,ewe=cc.range,twe=C3.range,rwe=S3.range;o(dd,"utcWeekday");pd=dd(0),Bp=dd(1),eY=dd(2),tY=dd(3),Lh=dd(4),rY=dd(5),nY=dd(6),iY=pd.range,nwe=Bp.range,iwe=eY.range,awe=tY.range,swe=Lh.range,owe=rY.range,lwe=nY.range});var vu,cwe,A3,uwe,V8=R(()=>{"use strict";mu();vu=dn(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+(e.getFullYear()-t.getFullYear())*12,t=>t.getMonth()),cwe=vu.range,A3=dn(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+(e.getUTCFullYear()-t.getUTCFullYear())*12,t=>t.getUTCMonth()),uwe=A3.range});var Qs,hwe,vl,fwe,U8=R(()=>{"use strict";mu();Qs=dn(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear());Qs.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:dn(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,r)=>{e.setFullYear(e.getFullYear()+r*t)});hwe=Qs.range,vl=dn(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());vl.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:dn(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)});fwe=vl.range});function sY(t,e,r,n,i,a){let s=[[Ks,1,1e3],[Ks,5,5*1e3],[Ks,15,15*1e3],[Ks,30,30*1e3],[a,1,6e4],[a,5,5*6e4],[a,15,15*6e4],[a,30,30*6e4],[i,1,36e5],[i,3,3*36e5],[i,6,6*36e5],[i,12,12*36e5],[n,1,864e5],[n,2,2*864e5],[r,1,6048e5],[e,1,2592e6],[e,3,3*2592e6],[t,1,31536e6]];function l(h,f,d){let p=f<h;p&&([h,f]=[f,h]);let m=d&&typeof d.range=="function"?d:u(h,f,d),g=m?m.range(h,+f+1):[];return p?g.reverse():g}o(l,"ticks");function u(h,f,d){let p=Math.abs(f-h)/d,m=td(([,,v])=>v).right(s,p);if(m===s.length)return t.every(Tp(h/31536e6,f/31536e6,d));if(m===0)return oc.every(Math.max(Tp(h,f,d),1));let[g,y]=s[p/s[m-1][2]<s[m][2]/p?m-1:m];return g.every(y)}return o(u,"tickInterval"),[l,u]}var pwe,mwe,H8,Y8,oY=R(()=>{"use strict";bh();P8();B8();F8();z8();G8();$8();V8();U8();o(sY,"ticker");[pwe,mwe]=sY(vl,A3,pd,T3,w3,b3),[H8,Y8]=sY(Qs,vu,yl,Do,yu,gu)});var _3=R(()=>{"use strict";P8();B8();F8();z8();G8();$8();V8();U8();oY()});function W8(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function q8(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Gy(t,e,r){return{y:t,m:e,d:r,H:0,M:0,S:0,L:0}}function X8(t){var e=t.dateTime,r=t.date,n=t.time,i=t.periods,a=t.days,s=t.shortDays,l=t.months,u=t.shortMonths,h=$y(i),f=Vy(i),d=$y(a),p=Vy(a),m=$y(s),g=Vy(s),y=$y(l),v=Vy(l),x=$y(u),b=Vy(u),w={a:P,A:F,b:B,B:$,c:null,d:dY,e:dY,f:Fwe,g:Xwe,G:Kwe,H:Owe,I:Pwe,j:Bwe,L:vY,m:zwe,M:Gwe,p:z,q:Y,Q:gY,s:yY,S:$we,u:Vwe,U:Uwe,V:Hwe,w:Ywe,W:Wwe,x:null,X:null,y:qwe,Y:jwe,Z:Qwe,"%":mY},S={a:Q,A:X,b:ie,B:j,c:null,d:pY,e:pY,f:tTe,g:hTe,G:dTe,H:Zwe,I:Jwe,j:eTe,L:bY,m:rTe,M:nTe,p:J,q:Z,Q:gY,s:yY,S:iTe,u:aTe,U:sTe,V:oTe,w:lTe,W:cTe,x:null,X:null,y:uTe,Y:fTe,Z:pTe,"%":mY},T={a:M,A:N,b:k,B:I,c:C,d:hY,e:hY,f:Rwe,g:uY,G:cY,H:fY,I:fY,j:Awe,L:Dwe,m:Swe,M:_we,p:L,q:Cwe,Q:Mwe,s:Iwe,S:Lwe,u:bwe,U:wwe,V:Twe,w:xwe,W:kwe,x:O,X:D,y:uY,Y:cY,Z:Ewe,"%":Nwe};w.x=E(r,w),w.X=E(n,w),w.c=E(e,w),S.x=E(r,S),S.X=E(n,S),S.c=E(e,S);function E(H,q){return function(K){var se=[],ce=-1,ue=0,te=H.length,De,oe,ke;for(K instanceof Date||(K=new Date(+K));++ce<te;)H.charCodeAt(ce)===37&&(se.push(H.slice(ue,ce)),(oe=lY[De=H.charAt(++ce)])!=null?De=H.charAt(++ce):oe=De==="e"?" ":"0",(ke=q[De])&&(De=ke(K,oe)),se.push(De),ue=ce+1);return se.push(H.slice(ue,ce)),se.join("")}}o(E,"newFormat");function _(H,q){return function(K){var se=Gy(1900,void 0,1),ce=A(se,H,K+="",0),ue,te;if(ce!=K.length)return null;if("Q"in se)return new Date(se.Q);if("s"in se)return new Date(se.s*1e3+("L"in se?se.L:0));if(q&&!("Z"in se)&&(se.Z=0),"p"in se&&(se.H=se.H%12+se.p*12),se.m===void 0&&(se.m="q"in se?se.q:0),"V"in se){if(se.V<1||se.V>53)return null;"w"in se||(se.w=1),"Z"in se?(ue=q8(Gy(se.y,0,1)),te=ue.getUTCDay(),ue=te>4||te===0?Bp.ceil(ue):Bp(ue),ue=zy.offset(ue,(se.V-1)*7),se.y=ue.getUTCFullYear(),se.m=ue.getUTCMonth(),se.d=ue.getUTCDate()+(se.w+6)%7):(ue=W8(Gy(se.y,0,1)),te=ue.getDay(),ue=te>4||te===0?_h.ceil(ue):_h(ue),ue=Do.offset(ue,(se.V-1)*7),se.y=ue.getFullYear(),se.m=ue.getMonth(),se.d=ue.getDate()+(se.w+6)%7)}else("W"in se||"U"in se)&&("w"in se||(se.w="u"in se?se.u%7:"W"in se?1:0),te="Z"in se?q8(Gy(se.y,0,1)).getUTCDay():W8(Gy(se.y,0,1)).getDay(),se.m=0,se.d="W"in se?(se.w+6)%7+se.W*7-(te+5)%7:se.w+se.U*7-(te+6)%7);return"Z"in se?(se.H+=se.Z/100|0,se.M+=se.Z%100,q8(se)):W8(se)}}o(_,"newParse");function A(H,q,K,se){for(var ce=0,ue=q.length,te=K.length,De,oe;ce<ue;){if(se>=te)return-1;if(De=q.charCodeAt(ce++),De===37){if(De=q.charAt(ce++),oe=T[De in lY?q.charAt(ce++):De],!oe||(se=oe(H,K,se))<0)return-1}else if(De!=K.charCodeAt(se++))return-1}return se}o(A,"parseSpecifier");function L(H,q,K){var se=h.exec(q.slice(K));return se?(H.p=f.get(se[0].toLowerCase()),K+se[0].length):-1}o(L,"parsePeriod");function M(H,q,K){var se=m.exec(q.slice(K));return se?(H.w=g.get(se[0].toLowerCase()),K+se[0].length):-1}o(M,"parseShortWeekday");function N(H,q,K){var se=d.exec(q.slice(K));return se?(H.w=p.get(se[0].toLowerCase()),K+se[0].length):-1}o(N,"parseWeekday");function k(H,q,K){var se=x.exec(q.slice(K));return se?(H.m=b.get(se[0].toLowerCase()),K+se[0].length):-1}o(k,"parseShortMonth");function I(H,q,K){var se=y.exec(q.slice(K));return se?(H.m=v.get(se[0].toLowerCase()),K+se[0].length):-1}o(I,"parseMonth");function C(H,q,K){return A(H,e,q,K)}o(C,"parseLocaleDateTime");function O(H,q,K){return A(H,r,q,K)}o(O,"parseLocaleDate");function D(H,q,K){return A(H,n,q,K)}o(D,"parseLocaleTime");function P(H){return s[H.getDay()]}o(P,"formatShortWeekday");function F(H){return a[H.getDay()]}o(F,"formatWeekday");function B(H){return u[H.getMonth()]}o(B,"formatShortMonth");function $(H){return l[H.getMonth()]}o($,"formatMonth");function z(H){return i[+(H.getHours()>=12)]}o(z,"formatPeriod");function Y(H){return 1+~~(H.getMonth()/3)}o(Y,"formatQuarter");function Q(H){return s[H.getUTCDay()]}o(Q,"formatUTCShortWeekday");function X(H){return a[H.getUTCDay()]}o(X,"formatUTCWeekday");function ie(H){return u[H.getUTCMonth()]}o(ie,"formatUTCShortMonth");function j(H){return l[H.getUTCMonth()]}o(j,"formatUTCMonth");function J(H){return i[+(H.getUTCHours()>=12)]}o(J,"formatUTCPeriod");function Z(H){return 1+~~(H.getUTCMonth()/3)}return o(Z,"formatUTCQuarter"),{format:o(function(H){var q=E(H+="",w);return q.toString=function(){return H},q},"format"),parse:o(function(H){var q=_(H+="",!1);return q.toString=function(){return H},q},"parse"),utcFormat:o(function(H){var q=E(H+="",S);return q.toString=function(){return H},q},"utcFormat"),utcParse:o(function(H){var q=_(H+="",!0);return q.toString=function(){return H},q},"utcParse")}}function Pr(t,e,r){var n=t<0?"-":"",i=(n?-t:t)+"",a=i.length;return n+(a<r?new Array(r-a+1).join(e)+i:i)}function vwe(t){return t.replace(ywe,"\\$&")}function $y(t){return new RegExp("^(?:"+t.map(vwe).join("|")+")","i")}function Vy(t){return new Map(t.map((e,r)=>[e.toLowerCase(),r]))}function xwe(t,e,r){var n=Ki.exec(e.slice(r,r+1));return n?(t.w=+n[0],r+n[0].length):-1}function bwe(t,e,r){var n=Ki.exec(e.slice(r,r+1));return n?(t.u=+n[0],r+n[0].length):-1}function wwe(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.U=+n[0],r+n[0].length):-1}function Twe(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.V=+n[0],r+n[0].length):-1}function kwe(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.W=+n[0],r+n[0].length):-1}function cY(t,e,r){var n=Ki.exec(e.slice(r,r+4));return n?(t.y=+n[0],r+n[0].length):-1}function uY(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function Ewe(t,e,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return n?(t.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Cwe(t,e,r){var n=Ki.exec(e.slice(r,r+1));return n?(t.q=n[0]*3-3,r+n[0].length):-1}function Swe(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.m=n[0]-1,r+n[0].length):-1}function hY(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.d=+n[0],r+n[0].length):-1}function Awe(t,e,r){var n=Ki.exec(e.slice(r,r+3));return n?(t.m=0,t.d=+n[0],r+n[0].length):-1}function fY(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.H=+n[0],r+n[0].length):-1}function _we(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.M=+n[0],r+n[0].length):-1}function Lwe(t,e,r){var n=Ki.exec(e.slice(r,r+2));return n?(t.S=+n[0],r+n[0].length):-1}function Dwe(t,e,r){var n=Ki.exec(e.slice(r,r+3));return n?(t.L=+n[0],r+n[0].length):-1}function Rwe(t,e,r){var n=Ki.exec(e.slice(r,r+6));return n?(t.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function Nwe(t,e,r){var n=gwe.exec(e.slice(r,r+1));return n?r+n[0].length:-1}function Mwe(t,e,r){var n=Ki.exec(e.slice(r));return n?(t.Q=+n[0],r+n[0].length):-1}function Iwe(t,e,r){var n=Ki.exec(e.slice(r));return n?(t.s=+n[0],r+n[0].length):-1}function dY(t,e){return Pr(t.getDate(),e,2)}function Owe(t,e){return Pr(t.getHours(),e,2)}function Pwe(t,e){return Pr(t.getHours()%12||12,e,2)}function Bwe(t,e){return Pr(1+Do.count(Qs(t),t),e,3)}function vY(t,e){return Pr(t.getMilliseconds(),e,3)}function Fwe(t,e){return vY(t,e)+"000"}function zwe(t,e){return Pr(t.getMonth()+1,e,2)}function Gwe(t,e){return Pr(t.getMinutes(),e,2)}function $we(t,e){return Pr(t.getSeconds(),e,2)}function Vwe(t){var e=t.getDay();return e===0?7:e}function Uwe(t,e){return Pr(yl.count(Qs(t)-1,t),e,2)}function xY(t){var e=t.getDay();return e>=4||e===0?cc(t):cc.ceil(t)}function Hwe(t,e){return t=xY(t),Pr(cc.count(Qs(t),t)+(Qs(t).getDay()===4),e,2)}function Ywe(t){return t.getDay()}function Wwe(t,e){return Pr(_h.count(Qs(t)-1,t),e,2)}function qwe(t,e){return Pr(t.getFullYear()%100,e,2)}function Xwe(t,e){return t=xY(t),Pr(t.getFullYear()%100,e,2)}function jwe(t,e){return Pr(t.getFullYear()%1e4,e,4)}function Kwe(t,e){var r=t.getDay();return t=r>=4||r===0?cc(t):cc.ceil(t),Pr(t.getFullYear()%1e4,e,4)}function Qwe(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Pr(e/60|0,"0",2)+Pr(e%60,"0",2)}function pY(t,e){return Pr(t.getUTCDate(),e,2)}function Zwe(t,e){return Pr(t.getUTCHours(),e,2)}function Jwe(t,e){return Pr(t.getUTCHours()%12||12,e,2)}function eTe(t,e){return Pr(1+zy.count(vl(t),t),e,3)}function bY(t,e){return Pr(t.getUTCMilliseconds(),e,3)}function tTe(t,e){return bY(t,e)+"000"}function rTe(t,e){return Pr(t.getUTCMonth()+1,e,2)}function nTe(t,e){return Pr(t.getUTCMinutes(),e,2)}function iTe(t,e){return Pr(t.getUTCSeconds(),e,2)}function aTe(t){var e=t.getUTCDay();return e===0?7:e}function sTe(t,e){return Pr(pd.count(vl(t)-1,t),e,2)}function wY(t){var e=t.getUTCDay();return e>=4||e===0?Lh(t):Lh.ceil(t)}function oTe(t,e){return t=wY(t),Pr(Lh.count(vl(t),t)+(vl(t).getUTCDay()===4),e,2)}function lTe(t){return t.getUTCDay()}function cTe(t,e){return Pr(Bp.count(vl(t)-1,t),e,2)}function uTe(t,e){return Pr(t.getUTCFullYear()%100,e,2)}function hTe(t,e){return t=wY(t),Pr(t.getUTCFullYear()%100,e,2)}function fTe(t,e){return Pr(t.getUTCFullYear()%1e4,e,4)}function dTe(t,e){var r=t.getUTCDay();return t=r>=4||r===0?Lh(t):Lh.ceil(t),Pr(t.getUTCFullYear()%1e4,e,4)}function pTe(){return"+0000"}function mY(){return"%"}function gY(t){return+t}function yY(t){return Math.floor(+t/1e3)}var lY,Ki,gwe,ywe,TY=R(()=>{"use strict";_3();o(W8,"localDate");o(q8,"utcDate");o(Gy,"newDate");o(X8,"formatLocale");lY={"-":"",_:" ",0:"0"},Ki=/^\s*\d+/,gwe=/^%/,ywe=/[\\^$*+?|[\]().{}]/g;o(Pr,"pad");o(vwe,"requote");o($y,"formatRe");o(Vy,"formatLookup");o(xwe,"parseWeekdayNumberSunday");o(bwe,"parseWeekdayNumberMonday");o(wwe,"parseWeekNumberSunday");o(Twe,"parseWeekNumberISO");o(kwe,"parseWeekNumberMonday");o(cY,"parseFullYear");o(uY,"parseYear");o(Ewe,"parseZone");o(Cwe,"parseQuarter");o(Swe,"parseMonthNumber");o(hY,"parseDayOfMonth");o(Awe,"parseDayOfYear");o(fY,"parseHour24");o(_we,"parseMinutes");o(Lwe,"parseSeconds");o(Dwe,"parseMilliseconds");o(Rwe,"parseMicroseconds");o(Nwe,"parseLiteralPercent");o(Mwe,"parseUnixTimestamp");o(Iwe,"parseUnixTimestampSeconds");o(dY,"formatDayOfMonth");o(Owe,"formatHour24");o(Pwe,"formatHour12");o(Bwe,"formatDayOfYear");o(vY,"formatMilliseconds");o(Fwe,"formatMicroseconds");o(zwe,"formatMonthNumber");o(Gwe,"formatMinutes");o($we,"formatSeconds");o(Vwe,"formatWeekdayNumberMonday");o(Uwe,"formatWeekNumberSunday");o(xY,"dISO");o(Hwe,"formatWeekNumberISO");o(Ywe,"formatWeekdayNumberSunday");o(Wwe,"formatWeekNumberMonday");o(qwe,"formatYear");o(Xwe,"formatYearISO");o(jwe,"formatFullYear");o(Kwe,"formatFullYearISO");o(Qwe,"formatZone");o(pY,"formatUTCDayOfMonth");o(Zwe,"formatUTCHour24");o(Jwe,"formatUTCHour12");o(eTe,"formatUTCDayOfYear");o(bY,"formatUTCMilliseconds");o(tTe,"formatUTCMicroseconds");o(rTe,"formatUTCMonthNumber");o(nTe,"formatUTCMinutes");o(iTe,"formatUTCSeconds");o(aTe,"formatUTCWeekdayNumberMonday");o(sTe,"formatUTCWeekNumberSunday");o(wY,"UTCdISO");o(oTe,"formatUTCWeekNumberISO");o(lTe,"formatUTCWeekdayNumberSunday");o(cTe,"formatUTCWeekNumberMonday");o(uTe,"formatUTCYear");o(hTe,"formatUTCYearISO");o(fTe,"formatUTCFullYear");o(dTe,"formatUTCFullYearISO");o(pTe,"formatUTCZone");o(mY,"formatLiteralPercent");o(gY,"formatUnixTimestamp");o(yY,"formatUnixTimestampSeconds")});function j8(t){return Fp=X8(t),md=Fp.format,kY=Fp.parse,EY=Fp.utcFormat,CY=Fp.utcParse,Fp}var Fp,md,kY,EY,CY,SY=R(()=>{"use strict";TY();j8({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});o(j8,"defaultLocale")});var K8=R(()=>{"use strict";SY()});function mTe(t){return new Date(t)}function gTe(t){return t instanceof Date?+t:+new Date(+t)}function AY(t,e,r,n,i,a,s,l,u,h){var f=By(),d=f.invert,p=f.domain,m=h(".%L"),g=h(":%S"),y=h("%I:%M"),v=h("%I %p"),x=h("%a %d"),b=h("%b %d"),w=h("%B"),S=h("%Y");function T(E){return(u(E)<E?m:l(E)<E?g:s(E)<E?y:a(E)<E?v:n(E)<E?i(E)<E?x:b:r(E)<E?w:S)(E)}return o(T,"tickFormat"),f.invert=function(E){return new Date(d(E))},f.domain=function(E){return arguments.length?p(Array.from(E,gTe)):p().map(mTe)},f.ticks=function(E){var _=p();return t(_[0],_[_.length-1],E??10)},f.tickFormat=function(E,_){return _==null?T:h(_)},f.nice=function(E){var _=p();return(!E||typeof E.range!="function")&&(E=e(_[0],_[_.length-1],E??10)),E?p(M8(_,E)):f},f.copy=function(){return x3(f,AY(t,e,r,n,i,a,s,l,u,h))},f}function L3(){return Ah.apply(AY(H8,Y8,Qs,vu,yl,Do,yu,gu,Ks,md).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var _Y=R(()=>{"use strict";_3();K8();R8();Py();jH();o(mTe,"date");o(gTe,"number");o(AY,"calendar");o(L3,"time")});var LY=R(()=>{"use strict";UH();XH();A8();_Y()});function Q8(t){for(var e=t.length/6|0,r=new Array(e),n=0;n<e;)r[n]="#"+t.slice(n*6,++n*6);return r}var DY=R(()=>{"use strict";o(Q8,"default")});var Z8,RY=R(()=>{"use strict";DY();Z8=Q8("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab")});var NY=R(()=>{"use strict";RY()});function Nn(t){return o(function(){return t},"constant")}var D3=R(()=>{"use strict";o(Nn,"default")});function IY(t){return t>1?0:t<-1?zp:Math.acos(t)}function e_(t){return t>=1?Uy:t<=-1?-Uy:Math.asin(t)}var J8,ua,Dh,MY,R3,xl,gd,Qi,zp,Uy,Gp,N3=R(()=>{"use strict";J8=Math.abs,ua=Math.atan2,Dh=Math.cos,MY=Math.max,R3=Math.min,xl=Math.sin,gd=Math.sqrt,Qi=1e-12,zp=Math.PI,Uy=zp/2,Gp=2*zp;o(IY,"acos");o(e_,"asin")});function M3(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(r==null)e=null;else{let n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);e=n}return t},()=>new ld(e)}var t_=R(()=>{"use strict";d8();o(M3,"withPath")});function yTe(t){return t.innerRadius}function vTe(t){return t.outerRadius}function xTe(t){return t.startAngle}function bTe(t){return t.endAngle}function wTe(t){return t&&t.padAngle}function TTe(t,e,r,n,i,a,s,l){var u=r-t,h=n-e,f=s-i,d=l-a,p=d*u-f*h;if(!(p*p<Qi))return p=(f*(e-a)-d*(t-i))/p,[t+p*u,e+p*h]}function I3(t,e,r,n,i,a,s){var l=t-r,u=e-n,h=(s?a:-a)/gd(l*l+u*u),f=h*u,d=-h*l,p=t+f,m=e+d,g=r+f,y=n+d,v=(p+g)/2,x=(m+y)/2,b=g-p,w=y-m,S=b*b+w*w,T=i-a,E=p*y-g*m,_=(w<0?-1:1)*gd(MY(0,T*T*S-E*E)),A=(E*w-b*_)/S,L=(-E*b-w*_)/S,M=(E*w+b*_)/S,N=(-E*b+w*_)/S,k=A-v,I=L-x,C=M-v,O=N-x;return k*k+I*I>C*C+O*O&&(A=M,L=N),{cx:A,cy:L,x01:-f,y01:-d,x11:A*(i/T-1),y11:L*(i/T-1)}}function bl(){var t=yTe,e=vTe,r=Nn(0),n=null,i=xTe,a=bTe,s=wTe,l=null,u=M3(h);function h(){var f,d,p=+t.apply(this,arguments),m=+e.apply(this,arguments),g=i.apply(this,arguments)-Uy,y=a.apply(this,arguments)-Uy,v=J8(y-g),x=y>g;if(l||(l=f=u()),m<p&&(d=m,m=p,p=d),!(m>Qi))l.moveTo(0,0);else if(v>Gp-Qi)l.moveTo(m*Dh(g),m*xl(g)),l.arc(0,0,m,g,y,!x),p>Qi&&(l.moveTo(p*Dh(y),p*xl(y)),l.arc(0,0,p,y,g,x));else{var b=g,w=y,S=g,T=y,E=v,_=v,A=s.apply(this,arguments)/2,L=A>Qi&&(n?+n.apply(this,arguments):gd(p*p+m*m)),M=R3(J8(m-p)/2,+r.apply(this,arguments)),N=M,k=M,I,C;if(L>Qi){var O=e_(L/p*xl(A)),D=e_(L/m*xl(A));(E-=O*2)>Qi?(O*=x?1:-1,S+=O,T-=O):(E=0,S=T=(g+y)/2),(_-=D*2)>Qi?(D*=x?1:-1,b+=D,w-=D):(_=0,b=w=(g+y)/2)}var P=m*Dh(b),F=m*xl(b),B=p*Dh(T),$=p*xl(T);if(M>Qi){var z=m*Dh(w),Y=m*xl(w),Q=p*Dh(S),X=p*xl(S),ie;if(v<zp)if(ie=TTe(P,F,Q,X,z,Y,B,$)){var j=P-ie[0],J=F-ie[1],Z=z-ie[0],H=Y-ie[1],q=1/xl(IY((j*Z+J*H)/(gd(j*j+J*J)*gd(Z*Z+H*H)))/2),K=gd(ie[0]*ie[0]+ie[1]*ie[1]);N=R3(M,(p-K)/(q-1)),k=R3(M,(m-K)/(q+1))}else N=k=0}_>Qi?k>Qi?(I=I3(Q,X,P,F,m,k,x),C=I3(z,Y,B,$,m,k,x),l.moveTo(I.cx+I.x01,I.cy+I.y01),k<M?l.arc(I.cx,I.cy,k,ua(I.y01,I.x01),ua(C.y01,C.x01),!x):(l.arc(I.cx,I.cy,k,ua(I.y01,I.x01),ua(I.y11,I.x11),!x),l.arc(0,0,m,ua(I.cy+I.y11,I.cx+I.x11),ua(C.cy+C.y11,C.cx+C.x11),!x),l.arc(C.cx,C.cy,k,ua(C.y11,C.x11),ua(C.y01,C.x01),!x))):(l.moveTo(P,F),l.arc(0,0,m,b,w,!x)):l.moveTo(P,F),!(p>Qi)||!(E>Qi)?l.lineTo(B,$):N>Qi?(I=I3(B,$,z,Y,p,-N,x),C=I3(P,F,Q,X,p,-N,x),l.lineTo(I.cx+I.x01,I.cy+I.y01),N<M?l.arc(I.cx,I.cy,N,ua(I.y01,I.x01),ua(C.y01,C.x01),!x):(l.arc(I.cx,I.cy,N,ua(I.y01,I.x01),ua(I.y11,I.x11),!x),l.arc(0,0,p,ua(I.cy+I.y11,I.cx+I.x11),ua(C.cy+C.y11,C.cx+C.x11),x),l.arc(C.cx,C.cy,N,ua(C.y11,C.x11),ua(C.y01,C.x01),!x))):l.arc(0,0,p,T,S,x)}if(l.closePath(),f)return l=null,f+""||null}return o(h,"arc"),h.centroid=function(){var f=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,d=(+i.apply(this,arguments)+ +a.apply(this,arguments))/2-zp/2;return[Dh(d)*f,xl(d)*f]},h.innerRadius=function(f){return arguments.length?(t=typeof f=="function"?f:Nn(+f),h):t},h.outerRadius=function(f){return arguments.length?(e=typeof f=="function"?f:Nn(+f),h):e},h.cornerRadius=function(f){return arguments.length?(r=typeof f=="function"?f:Nn(+f),h):r},h.padRadius=function(f){return arguments.length?(n=f==null?null:typeof f=="function"?f:Nn(+f),h):n},h.startAngle=function(f){return arguments.length?(i=typeof f=="function"?f:Nn(+f),h):i},h.endAngle=function(f){return arguments.length?(a=typeof f=="function"?f:Nn(+f),h):a},h.padAngle=function(f){return arguments.length?(s=typeof f=="function"?f:Nn(+f),h):s},h.context=function(f){return arguments.length?(l=f??null,h):l},h}var OY=R(()=>{"use strict";D3();N3();t_();o(yTe,"arcInnerRadius");o(vTe,"arcOuterRadius");o(xTe,"arcStartAngle");o(bTe,"arcEndAngle");o(wTe,"arcPadAngle");o(TTe,"intersect");o(I3,"cornerTangents");o(bl,"default")});function Hy(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}var Dyt,r_=R(()=>{"use strict";Dyt=Array.prototype.slice;o(Hy,"default")});function PY(t){this._context=t}function xu(t){return new PY(t)}var n_=R(()=>{"use strict";o(PY,"Linear");PY.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._point=0},"lineStart"),lineEnd:o(function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e);break}},"point")};o(xu,"default")});function BY(t){return t[0]}function FY(t){return t[1]}var zY=R(()=>{"use strict";o(BY,"x");o(FY,"y")});function ha(t,e){var r=Nn(!0),n=null,i=xu,a=null,s=M3(l);t=typeof t=="function"?t:t===void 0?BY:Nn(t),e=typeof e=="function"?e:e===void 0?FY:Nn(e);function l(u){var h,f=(u=Hy(u)).length,d,p=!1,m;for(n==null&&(a=i(m=s())),h=0;h<=f;++h)!(h<f&&r(d=u[h],h,u))===p&&((p=!p)?a.lineStart():a.lineEnd()),p&&a.point(+t(d,h,u),+e(d,h,u));if(m)return a=null,m+""||null}return o(l,"line"),l.x=function(u){return arguments.length?(t=typeof u=="function"?u:Nn(+u),l):t},l.y=function(u){return arguments.length?(e=typeof u=="function"?u:Nn(+u),l):e},l.defined=function(u){return arguments.length?(r=typeof u=="function"?u:Nn(!!u),l):r},l.curve=function(u){return arguments.length?(i=u,n!=null&&(a=i(n)),l):i},l.context=function(u){return arguments.length?(u==null?n=a=null:a=i(n=u),l):n},l}var GY=R(()=>{"use strict";r_();D3();n_();t_();zY();o(ha,"default")});function i_(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}var $Y=R(()=>{"use strict";o(i_,"default")});function a_(t){return t}var VY=R(()=>{"use strict";o(a_,"default")});function O3(){var t=a_,e=i_,r=null,n=Nn(0),i=Nn(Gp),a=Nn(0);function s(l){var u,h=(l=Hy(l)).length,f,d,p=0,m=new Array(h),g=new Array(h),y=+n.apply(this,arguments),v=Math.min(Gp,Math.max(-Gp,i.apply(this,arguments)-y)),x,b=Math.min(Math.abs(v)/h,a.apply(this,arguments)),w=b*(v<0?-1:1),S;for(u=0;u<h;++u)(S=g[m[u]=u]=+t(l[u],u,l))>0&&(p+=S);for(e!=null?m.sort(function(T,E){return e(g[T],g[E])}):r!=null&&m.sort(function(T,E){return r(l[T],l[E])}),u=0,d=p?(v-h*w)/p:0;u<h;++u,y=x)f=m[u],S=g[f],x=y+(S>0?S*d:0)+w,g[f]={data:l[f],index:u,value:S,startAngle:y,endAngle:x,padAngle:b};return g}return o(s,"pie"),s.value=function(l){return arguments.length?(t=typeof l=="function"?l:Nn(+l),s):t},s.sortValues=function(l){return arguments.length?(e=l,r=null,s):e},s.sort=function(l){return arguments.length?(r=l,e=null,s):r},s.startAngle=function(l){return arguments.length?(n=typeof l=="function"?l:Nn(+l),s):n},s.endAngle=function(l){return arguments.length?(i=typeof l=="function"?l:Nn(+l),s):i},s.padAngle=function(l){return arguments.length?(a=typeof l=="function"?l:Nn(+l),s):a},s}var UY=R(()=>{"use strict";r_();D3();$Y();VY();N3();o(O3,"default")});function s_(t){return new P3(t,!0)}function o_(t){return new P3(t,!1)}var P3,HY=R(()=>{"use strict";P3=class{static{o(this,"Bump")}constructor(e,r){this._context=e,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(e,r){switch(e=+e,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(e,r):this._context.moveTo(e,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,r,e,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,e,this._y0,e,r);break}}this._x0=e,this._y0=r}};o(s_,"bumpX");o(o_,"bumpY")});function Zs(){}var Yy=R(()=>{"use strict";o(Zs,"default")});function $p(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}function Wy(t){this._context=t}function vs(t){return new Wy(t)}var qy=R(()=>{"use strict";o($p,"point");o(Wy,"Basis");Wy.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},"lineStart"),lineEnd:o(function(){switch(this._point){case 3:$p(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},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);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:$p(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e},"point")};o(vs,"default")});function YY(t){this._context=t}function B3(t){return new YY(t)}var WY=R(()=>{"use strict";Yy();qy();o(YY,"BasisClosed");YY.prototype={areaStart:Zs,areaEnd:Zs,lineStart:o(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},"lineStart"),lineEnd:o(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}}},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:$p(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e},"point")};o(B3,"default")});function qY(t){this._context=t}function F3(t){return new qY(t)}var XY=R(()=>{"use strict";qy();o(qY,"BasisOpen");qY.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},"lineStart"),lineEnd:o(function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,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+t)/6,n=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:$p(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e},"point")};o(F3,"default")});function jY(t,e){this._basis=new Wy(t),this._beta=e}var l_,KY=R(()=>{"use strict";qy();o(jY,"Bundle");jY.prototype={lineStart:o(function(){this._x=[],this._y=[],this._basis.lineStart()},"lineStart"),lineEnd:o(function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var n=t[0],i=e[0],a=t[r]-n,s=e[r]-i,l=-1,u;++l<=r;)u=l/r,this._basis.point(this._beta*t[l]+(1-this._beta)*(n+u*a),this._beta*e[l]+(1-this._beta)*(i+u*s));this._x=this._y=null,this._basis.lineEnd()},"lineEnd"),point:o(function(t,e){this._x.push(+t),this._y.push(+e)},"point")};l_=o(function t(e){function r(n){return e===1?new Wy(n):new jY(n,e)}return o(r,"bundle"),r.beta=function(n){return t(+n)},r},"custom")(.85)});function Vp(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}function z3(t,e){this._context=t,this._k=(1-e)/6}var c_,Xy=R(()=>{"use strict";o(Vp,"point");o(z3,"Cardinal");z3.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},"lineStart"),lineEnd:o(function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Vp(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:Vp(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};c_=o(function t(e){function r(n){return new z3(n,e)}return o(r,"cardinal"),r.tension=function(n){return t(+n)},r},"custom")(0)});function G3(t,e){this._context=t,this._k=(1-e)/6}var u_,h_=R(()=>{"use strict";Yy();Xy();o(G3,"CardinalClosed");G3.prototype={areaStart:Zs,areaEnd:Zs,lineStart:o(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},"lineStart"),lineEnd:o(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}}},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:Vp(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};u_=o(function t(e){function r(n){return new G3(n,e)}return o(r,"cardinal"),r.tension=function(n){return t(+n)},r},"custom")(0)});function $3(t,e){this._context=t,this._k=(1-e)/6}var f_,d_=R(()=>{"use strict";Xy();o($3,"CardinalOpen");$3.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},"lineStart"),lineEnd:o(function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,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:Vp(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};f_=o(function t(e){function r(n){return new $3(n,e)}return o(r,"cardinal"),r.tension=function(n){return t(+n)},r},"custom")(0)});function jy(t,e,r){var n=t._x1,i=t._y1,a=t._x2,s=t._y2;if(t._l01_a>Qi){var l=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);n=(n*l-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*l-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>Qi){var h=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,f=3*t._l23_a*(t._l23_a+t._l12_a);a=(a*h+t._x1*t._l23_2a-e*t._l12_2a)/f,s=(s*h+t._y1*t._l23_2a-r*t._l12_2a)/f}t._context.bezierCurveTo(n,i,a,s,t._x2,t._y2)}function QY(t,e){this._context=t,this._alpha=e}var p_,V3=R(()=>{"use strict";N3();Xy();o(jy,"point");o(QY,"CatmullRom");QY.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(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},"lineStart"),lineEnd:o(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},"lineEnd"),point:o(function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,n=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:jy(this,t,e);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=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};p_=o(function t(e){function r(n){return e?new QY(n,e):new z3(n,0)}return o(r,"catmullRom"),r.alpha=function(n){return t(+n)},r},"custom")(.5)});function ZY(t,e){this._context=t,this._alpha=e}var m_,JY=R(()=>{"use strict";h_();Yy();V3();o(ZY,"CatmullRomClosed");ZY.prototype={areaStart:Zs,areaEnd:Zs,lineStart:o(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},"lineStart"),lineEnd:o(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}}},"lineEnd"),point:o(function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,n=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:jy(this,t,e);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=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};m_=o(function t(e){function r(n){return e?new ZY(n,e):new G3(n,0)}return o(r,"catmullRom"),r.alpha=function(n){return t(+n)},r},"custom")(.5)});function eW(t,e){this._context=t,this._alpha=e}var g_,tW=R(()=>{"use strict";d_();V3();o(eW,"CatmullRomOpen");eW.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(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},"lineStart"),lineEnd:o(function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:o(function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,n=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,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:jy(this,t,e);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=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};g_=o(function t(e){function r(n){return e?new eW(n,e):new $3(n,0)}return o(r,"catmullRom"),r.alpha=function(n){return t(+n)},r},"custom")(.5)});function rW(t){this._context=t}function U3(t){return new rW(t)}var nW=R(()=>{"use strict";Yy();o(rW,"LinearClosed");rW.prototype={areaStart:Zs,areaEnd:Zs,lineStart:o(function(){this._point=0},"lineStart"),lineEnd:o(function(){this._point&&this._context.closePath()},"lineEnd"),point:o(function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))},"point")};o(U3,"default")});function iW(t){return t<0?-1:1}function aW(t,e,r){var n=t._x1-t._x0,i=e-t._x1,a=(t._y1-t._y0)/(n||i<0&&-0),s=(r-t._y1)/(i||n<0&&-0),l=(a*i+s*n)/(n+i);return(iW(a)+iW(s))*Math.min(Math.abs(a),Math.abs(s),.5*Math.abs(l))||0}function sW(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}function y_(t,e,r){var n=t._x0,i=t._y0,a=t._x1,s=t._y1,l=(a-n)/3;t._context.bezierCurveTo(n+l,i+l*e,a-l,s-l*r,a,s)}function H3(t){this._context=t}function oW(t){this._context=new lW(t)}function lW(t){this._context=t}function v_(t){return new H3(t)}function x_(t){return new oW(t)}var cW=R(()=>{"use strict";o(iW,"sign");o(aW,"slope3");o(sW,"slope2");o(y_,"point");o(H3,"MonotoneX");H3.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},"lineStart"),lineEnd:o(function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:y_(this,this._t0,sW(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:o(function(t,e){var r=NaN;if(t=+t,e=+e,!(t===this._x1&&e===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,y_(this,sW(this,r=aW(this,t,e)),r);break;default:y_(this,this._t0,r=aW(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=r}},"point")};o(oW,"MonotoneY");(oW.prototype=Object.create(H3.prototype)).point=function(t,e){H3.prototype.point.call(this,e,t)};o(lW,"ReflectContext");lW.prototype={moveTo:o(function(t,e){this._context.moveTo(e,t)},"moveTo"),closePath:o(function(){this._context.closePath()},"closePath"),lineTo:o(function(t,e){this._context.lineTo(e,t)},"lineTo"),bezierCurveTo:o(function(t,e,r,n,i,a){this._context.bezierCurveTo(e,t,n,r,a,i)},"bezierCurveTo")};o(v_,"monotoneX");o(x_,"monotoneY")});function hW(t){this._context=t}function uW(t){var e,r=t.length-1,n,i=new Array(r),a=new Array(r),s=new Array(r);for(i[0]=0,a[0]=2,s[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,a[e]=4,s[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,a[r-1]=7,s[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/a[e-1],a[e]-=n,s[e]-=n*s[e-1];for(i[r-1]=s[r-1]/a[r-1],e=r-2;e>=0;--e)i[e]=(s[e]-i[e+1])/a[e];for(a[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)a[e]=2*t[e+1]-i[e+1];return[i,a]}function Y3(t){return new hW(t)}var fW=R(()=>{"use strict";o(hW,"Natural");hW.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x=[],this._y=[]},"lineStart"),lineEnd:o(function(){var t=this._x,e=this._y,r=t.length;if(r)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),r===2)this._context.lineTo(t[1],e[1]);else for(var n=uW(t),i=uW(e),a=0,s=1;s<r;++a,++s)this._context.bezierCurveTo(n[0][a],i[0][a],n[1][a],i[1][a],t[s],e[s]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},"lineEnd"),point:o(function(t,e){this._x.push(+t),this._y.push(+e)},"point")};o(uW,"controlPoints");o(Y3,"default")});function W3(t,e){this._context=t,this._t=e}function q3(t){return new W3(t,.5)}function b_(t){return new W3(t,0)}function w_(t){return new W3(t,1)}var dW=R(()=>{"use strict";o(W3,"Step");W3.prototype={areaStart:o(function(){this._line=0},"areaStart"),areaEnd:o(function(){this._line=NaN},"areaEnd"),lineStart:o(function(){this._x=this._y=NaN,this._point=0},"lineStart"),lineEnd:o(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)},"lineEnd"),point:o(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}break}}this._x=t,this._y=e},"point")};o(q3,"default");o(b_,"stepBefore");o(w_,"stepAfter")});var pW=R(()=>{"use strict";OY();GY();UY();WY();XY();qy();HY();KY();h_();d_();Xy();JY();tW();V3();nW();n_();cW();fW();dW()});var mW=R(()=>{"use strict"});var gW=R(()=>{"use strict"});function Rh(t,e,r){this.k=t,this.x=e,this.y=r}function k_(t){for(;!t.__zoom;)if(!(t=t.parentNode))return T_;return t.__zoom}var T_,E_=R(()=>{"use strict";o(Rh,"Transform");Rh.prototype={constructor:Rh,scale:o(function(t){return t===1?this:new Rh(this.k*t,this.x,this.y)},"scale"),translate:o(function(t,e){return t===0&e===0?this:new Rh(this.k,this.x+this.k*t,this.y+this.k*e)},"translate"),apply:o(function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},"apply"),applyX:o(function(t){return t*this.k+this.x},"applyX"),applyY:o(function(t){return t*this.k+this.y},"applyY"),invert:o(function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},"invert"),invertX:o(function(t){return(t-this.x)/this.k},"invertX"),invertY:o(function(t){return(t-this.y)/this.k},"invertY"),rescaleX:o(function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},"rescaleX"),rescaleY:o(function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},"rescaleY"),toString:o(function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"},"toString")};T_=new Rh(1,0,0);k_.prototype=Rh.prototype;o(k_,"transform")});var yW=R(()=>{"use strict"});var vW=R(()=>{"use strict";c3();mW();gW();E_();yW()});var xW=R(()=>{"use strict";vW();E_()});var Zt=R(()=>{"use strict";bh();K$();mH();xH();Lp();bH();wH();bS();$V();TH();l8();kH();CH();C8();zH();GH();Np();d8();$H();EH();VH();LY();NY();fl();pW();_3();K8();n3();c3();xW()});var bW=gi(Zi=>{"use strict";Object.defineProperty(Zi,"__esModule",{value:!0});Zi.BLANK_URL=Zi.relativeFirstCharacters=Zi.whitespaceEscapeCharsRegex=Zi.urlSchemeRegex=Zi.ctrlCharactersRegex=Zi.htmlCtrlEntityRegex=Zi.htmlEntitiesRegex=Zi.invalidProtocolRegex=void 0;Zi.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im;Zi.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g;Zi.htmlCtrlEntityRegex=/&(newline|tab);/gi;Zi.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim;Zi.urlSchemeRegex=/^.+(:|&colon;)/gim;Zi.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g;Zi.relativeFirstCharacters=[".","/"];Zi.BLANK_URL="about:blank"});var Up=gi(X3=>{"use strict";Object.defineProperty(X3,"__esModule",{value:!0});X3.sanitizeUrl=void 0;var Na=bW();function kTe(t){return Na.relativeFirstCharacters.indexOf(t[0])>-1}o(kTe,"isRelativeUrlWithoutProtocol");function ETe(t){var e=t.replace(Na.ctrlCharactersRegex,"");return e.replace(Na.htmlEntitiesRegex,function(r,n){return String.fromCharCode(n)})}o(ETe,"decodeHtmlCharacters");function CTe(t){return URL.canParse(t)}o(CTe,"isValidUrl");function wW(t){try{return decodeURIComponent(t)}catch{return t}}o(wW,"decodeURI");function STe(t){if(!t)return Na.BLANK_URL;var e,r=wW(t.trim());do r=ETe(r).replace(Na.htmlCtrlEntityRegex,"").replace(Na.ctrlCharactersRegex,"").replace(Na.whitespaceEscapeCharsRegex,"").trim(),r=wW(r),e=r.match(Na.ctrlCharactersRegex)||r.match(Na.htmlEntitiesRegex)||r.match(Na.htmlCtrlEntityRegex)||r.match(Na.whitespaceEscapeCharsRegex);while(e&&e.length>0);var n=r;if(!n)return Na.BLANK_URL;if(kTe(n))return n;var i=n.trimStart(),a=i.match(Na.urlSchemeRegex);if(!a)return n;var s=a[0].toLowerCase().trim();if(Na.invalidProtocolRegex.test(s))return Na.BLANK_URL;var l=i.replace(/\\/g,"/");if(s==="mailto:"||s.includes("://"))return l;if(s==="http:"||s==="https:"){if(!CTe(l))return Na.BLANK_URL;var u=new URL(l);return u.protocol=u.protocol.toLowerCase(),u.hostname=u.hostname.toLowerCase(),u.toString()}return l}o(STe,"sanitizeUrl");X3.sanitizeUrl=STe});var C_,yd,j3,TW,kW,EW,wl,Ky,Qy=R(()=>{"use strict";C_=Xi(Up(),1);rr();yd=o((t,e)=>{let r=t.append("rect");if(r.attr("x",e.x),r.attr("y",e.y),r.attr("fill",e.fill),r.attr("stroke",e.stroke),r.attr("width",e.width),r.attr("height",e.height),e.name&&r.attr("name",e.name),e.rx&&r.attr("rx",e.rx),e.ry&&r.attr("ry",e.ry),e.attrs!==void 0)for(let n in e.attrs)r.attr(n,e.attrs[n]);return e.class&&r.attr("class",e.class),r},"drawRect"),j3=o((t,e)=>{let r={x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,stroke:e.stroke,class:"rect"};yd(t,r).lower()},"drawBackgroundRect"),TW=o((t,e)=>{let r=e.text.replace(Qf," "),n=t.append("text");n.attr("x",e.x),n.attr("y",e.y),n.attr("class","legend"),n.style("text-anchor",e.anchor),e.class&&n.attr("class",e.class);let i=n.append("tspan");return i.attr("x",e.x+e.textMargin*2),i.text(r),n},"drawText"),kW=o((t,e,r,n)=>{let i=t.append("image");i.attr("x",e),i.attr("y",r);let a=(0,C_.sanitizeUrl)(n);i.attr("xlink:href",a)},"drawImage"),EW=o((t,e,r,n)=>{let i=t.append("use");i.attr("x",e),i.attr("y",r);let a=(0,C_.sanitizeUrl)(n);i.attr("xlink:href",`#${a}`)},"drawEmbeddedImage"),wl=o(()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),"getNoteRect"),Ky=o(()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0}),"getTextObj")});var CW,S_,SW,ATe,_Te,LTe,DTe,RTe,NTe,MTe,ITe,OTe,PTe,BTe,FTe,bu,Tl,AW=R(()=>{"use strict";rr();Qy();CW=Xi(Up(),1),S_=o(function(t,e){return yd(t,e)},"drawRect"),SW=o(function(t,e,r,n,i,a){let s=t.append("image");s.attr("width",e),s.attr("height",r),s.attr("x",n),s.attr("y",i);let l=a.startsWith("data:image/png;base64")?a:(0,CW.sanitizeUrl)(a);s.attr("xlink:href",l)},"drawImage"),ATe=o((t,e,r)=>{let n=t.append("g"),i=0;for(let a of e){let s=a.textColor?a.textColor:"#444444",l=a.lineColor?a.lineColor:"#444444",u=a.offsetX?parseInt(a.offsetX):0,h=a.offsetY?parseInt(a.offsetY):0,f="";if(i===0){let p=n.append("line");p.attr("x1",a.startPoint.x),p.attr("y1",a.startPoint.y),p.attr("x2",a.endPoint.x),p.attr("y2",a.endPoint.y),p.attr("stroke-width","1"),p.attr("stroke",l),p.style("fill","none"),a.type!=="rel_b"&&p.attr("marker-end","url("+f+"#arrowhead)"),(a.type==="birel"||a.type==="rel_b")&&p.attr("marker-start","url("+f+"#arrowend)"),i=-1}else{let p=n.append("path");p.attr("fill","none").attr("stroke-width","1").attr("stroke",l).attr("d","Mstartx,starty Qcontrolx,controly stopx,stopy ".replaceAll("startx",a.startPoint.x).replaceAll("starty",a.startPoint.y).replaceAll("controlx",a.startPoint.x+(a.endPoint.x-a.startPoint.x)/2-(a.endPoint.x-a.startPoint.x)/4).replaceAll("controly",a.startPoint.y+(a.endPoint.y-a.startPoint.y)/2).replaceAll("stopx",a.endPoint.x).replaceAll("stopy",a.endPoint.y)),a.type!=="rel_b"&&p.attr("marker-end","url("+f+"#arrowhead)"),(a.type==="birel"||a.type==="rel_b")&&p.attr("marker-start","url("+f+"#arrowend)")}let d=r.messageFont();bu(r)(a.label.text,n,Math.min(a.startPoint.x,a.endPoint.x)+Math.abs(a.endPoint.x-a.startPoint.x)/2+u,Math.min(a.startPoint.y,a.endPoint.y)+Math.abs(a.endPoint.y-a.startPoint.y)/2+h,a.label.width,a.label.height,{fill:s},d),a.techn&&a.techn.text!==""&&(d=r.messageFont(),bu(r)("["+a.techn.text+"]",n,Math.min(a.startPoint.x,a.endPoint.x)+Math.abs(a.endPoint.x-a.startPoint.x)/2+u,Math.min(a.startPoint.y,a.endPoint.y)+Math.abs(a.endPoint.y-a.startPoint.y)/2+r.messageFontSize+5+h,Math.max(a.label.width,a.techn.width),a.techn.height,{fill:s,"font-style":"italic"},d))}},"drawRels"),_Te=o(function(t,e,r){let n=t.append("g"),i=e.bgColor?e.bgColor:"none",a=e.borderColor?e.borderColor:"#444444",s=e.fontColor?e.fontColor:"black",l={"stroke-width":1,"stroke-dasharray":"7.0,7.0"};e.nodeType&&(l={"stroke-width":1});let u={x:e.x,y:e.y,fill:i,stroke:a,width:e.width,height:e.height,rx:2.5,ry:2.5,attrs:l};S_(n,u);let h=r.boundaryFont();h.fontWeight="bold",h.fontSize=h.fontSize+2,h.fontColor=s,bu(r)(e.label.text,n,e.x,e.y+e.label.Y,e.width,e.height,{fill:"#444444"},h),e.type&&e.type.text!==""&&(h=r.boundaryFont(),h.fontColor=s,bu(r)(e.type.text,n,e.x,e.y+e.type.Y,e.width,e.height,{fill:"#444444"},h)),e.descr&&e.descr.text!==""&&(h=r.boundaryFont(),h.fontSize=h.fontSize-2,h.fontColor=s,bu(r)(e.descr.text,n,e.x,e.y+e.descr.Y,e.width,e.height,{fill:"#444444"},h))},"drawBoundary"),LTe=o(function(t,e,r){let n=e.bgColor?e.bgColor:r[e.typeC4Shape.text+"_bg_color"],i=e.borderColor?e.borderColor:r[e.typeC4Shape.text+"_border_color"],a=e.fontColor?e.fontColor:"#FFFFFF",s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";switch(e.typeC4Shape.text){case"person":s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";break;case"external_person":s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAAB6ElEQVR4Xu2YLY+EMBCG9+dWr0aj0Wg0Go1Go0+j8Xdv2uTCvv1gpt0ebHKPuhDaeW4605Z9mJvx4AdXUyTUdd08z+u6flmWZRnHsWkafk9DptAwDPu+f0eAYtu2PEaGWuj5fCIZrBAC2eLBAnRCsEkkxmeaJp7iDJ2QMDdHsLg8SxKFEJaAo8lAXnmuOFIhTMpxxKATebo4UiFknuNo4OniSIXQyRxEA3YsnjGCVEjVXD7yLUAqxBGUyPv/Y4W2beMgGuS7kVQIBycH0fD+oi5pezQETxdHKmQKGk1eQEYldK+jw5GxPfZ9z7Mk0Qnhf1W1m3w//EUn5BDmSZsbR44QQLBEqrBHqOrmSKaQAxdnLArCrxZcM7A7ZKs4ioRq8LFC+NpC3WCBJsvpVw5edm9iEXFuyNfxXAgSwfrFQ1c0iNda8AdejvUgnktOtJQQxmcfFzGglc5WVCj7oDgFqU18boeFSs52CUh8LE8BIVQDT1ABrB0HtgSEYlX5doJnCwv9TXocKCaKbnwhdDKPq4lf3SwU3HLq4V/+WYhHVMa/3b4IlfyikAduCkcBc7mQ3/z/Qq/cTuikhkzB12Ae/mcJC9U+Vo8Ej1gWAtgbeGgFsAMHr50BIWOLCbezvhpBFUdY6EJuJ/QDW0XoMX60zZ0AAAAASUVORK5CYII=";break}let l=t.append("g");l.attr("class","person-man");let u=wl();switch(e.typeC4Shape.text){case"person":case"external_person":case"system":case"external_system":case"container":case"external_container":case"component":case"external_component":u.x=e.x,u.y=e.y,u.fill=n,u.width=e.width,u.height=e.height,u.stroke=i,u.rx=2.5,u.ry=2.5,u.attrs={"stroke-width":.5},S_(l,u);break;case"system_db":case"external_system_db":case"container_db":case"external_container_db":case"component_db":case"external_component_db":l.append("path").attr("fill",n).attr("stroke-width","0.5").attr("stroke",i).attr("d","Mstartx,startyc0,-10 half,-10 half,-10c0,0 half,0 half,10l0,heightc0,10 -half,10 -half,10c0,0 -half,0 -half,-10l0,-height".replaceAll("startx",e.x).replaceAll("starty",e.y).replaceAll("half",e.width/2).replaceAll("height",e.height)),l.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",i).attr("d","Mstartx,startyc0,10 half,10 half,10c0,0 half,0 half,-10".replaceAll("startx",e.x).replaceAll("starty",e.y).replaceAll("half",e.width/2));break;case"system_queue":case"external_system_queue":case"container_queue":case"external_container_queue":case"component_queue":case"external_component_queue":l.append("path").attr("fill",n).attr("stroke-width","0.5").attr("stroke",i).attr("d","Mstartx,startylwidth,0c5,0 5,half 5,halfc0,0 0,half -5,halfl-width,0c-5,0 -5,-half -5,-halfc0,0 0,-half 5,-half".replaceAll("startx",e.x).replaceAll("starty",e.y).replaceAll("width",e.width).replaceAll("half",e.height/2)),l.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",i).attr("d","Mstartx,startyc-5,0 -5,half -5,halfc0,half 5,half 5,half".replaceAll("startx",e.x+e.width).replaceAll("starty",e.y).replaceAll("half",e.height/2));break}let h=FTe(r,e.typeC4Shape.text);switch(l.append("text").attr("fill",a).attr("font-family",h.fontFamily).attr("font-size",h.fontSize-2).attr("font-style","italic").attr("lengthAdjust","spacing").attr("textLength",e.typeC4Shape.width).attr("x",e.x+e.width/2-e.typeC4Shape.width/2).attr("y",e.y+e.typeC4Shape.Y).text("<<"+e.typeC4Shape.text+">>"),e.typeC4Shape.text){case"person":case"external_person":SW(l,48,48,e.x+e.width/2-24,e.y+e.image.Y,s);break}let f=r[e.typeC4Shape.text+"Font"]();return f.fontWeight="bold",f.fontSize=f.fontSize+2,f.fontColor=a,bu(r)(e.label.text,l,e.x,e.y+e.label.Y,e.width,e.height,{fill:a},f),f=r[e.typeC4Shape.text+"Font"](),f.fontColor=a,e.techn&&e.techn?.text!==""?bu(r)(e.techn.text,l,e.x,e.y+e.techn.Y,e.width,e.height,{fill:a,"font-style":"italic"},f):e.type&&e.type.text!==""&&bu(r)(e.type.text,l,e.x,e.y+e.type.Y,e.width,e.height,{fill:a,"font-style":"italic"},f),e.descr&&e.descr.text!==""&&(f=r.personFont(),f.fontColor=a,bu(r)(e.descr.text,l,e.x,e.y+e.descr.Y,e.width,e.height,{fill:a},f)),e.height},"drawC4Shape"),DTe=o(function(t){t.append("defs").append("symbol").attr("id","database").attr("fill-rule","evenodd").attr("clip-rule","evenodd").append("path").attr("transform","scale(.5)").attr("d","M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z")},"insertDatabaseIcon"),RTe=o(function(t){t.append("defs").append("symbol").attr("id","computer").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z")},"insertComputerIcon"),NTe=o(function(t){t.append("defs").append("symbol").attr("id","clock").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z")},"insertClockIcon"),MTe=o(function(t){t.append("defs").append("marker").attr("id","arrowhead").attr("refX",9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z")},"insertArrowHead"),ITe=o(function(t){t.append("defs").append("marker").attr("id","arrowend").attr("refX",1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 z")},"insertArrowEnd"),OTe=o(function(t){t.append("defs").append("marker").attr("id","filled-head").attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"insertArrowFilledHead"),PTe=o(function(t){t.append("defs").append("marker").attr("id","sequencenumber").attr("refX",15).attr("refY",15).attr("markerWidth",60).attr("markerHeight",40).attr("orient","auto").append("circle").attr("cx",15).attr("cy",15).attr("r",6)},"insertDynamicNumber"),BTe=o(function(t){let r=t.append("defs").append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);r.append("path").attr("fill","black").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 9,2 V 6 L16,4 Z"),r.append("path").attr("fill","none").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 0,1 L 6,7 M 6,1 L 0,7")},"insertArrowCrossHead"),FTe=o((t,e)=>({fontFamily:t[e+"FontFamily"],fontSize:t[e+"FontSize"],fontWeight:t[e+"FontWeight"]}),"getC4ShapeFont"),bu=function(){function t(i,a,s,l,u,h,f){let d=a.append("text").attr("x",s+u/2).attr("y",l+h/2+5).style("text-anchor","middle").text(i);n(d,f)}o(t,"byText");function e(i,a,s,l,u,h,f,d){let{fontSize:p,fontFamily:m,fontWeight:g}=d,y=i.split(We.lineBreakRegex);for(let v=0;v<y.length;v++){let x=v*p-p*(y.length-1)/2,b=a.append("text").attr("x",s+u/2).attr("y",l).style("text-anchor","middle").attr("dominant-baseline","middle").style("font-size",p).style("font-weight",g).style("font-family",m);b.append("tspan").attr("dy",x).text(y[v]).attr("alignment-baseline","mathematical"),n(b,f)}}o(e,"byTspan");function r(i,a,s,l,u,h,f,d){let p=a.append("switch"),g=p.append("foreignObject").attr("x",s).attr("y",l).attr("width",u).attr("height",h).append("xhtml:div").style("display","table").style("height","100%").style("width","100%");g.append("div").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(i),e(i,p,s,l,u,h,f,d),n(g,f)}o(r,"byFo");function n(i,a){for(let s in a)a.hasOwnProperty(s)&&i.attr(s,a[s])}return o(n,"_setTextAttrs"),function(i){return i.textPlacement==="fo"?r:i.textPlacement==="old"?t:e}}(),Tl={drawRect:S_,drawBoundary:_Te,drawC4Shape:LTe,drawRels:ATe,drawImage:SW,insertArrowHead:MTe,insertArrowEnd:ITe,insertArrowFilledHead:OTe,insertDynamicNumber:PTe,insertArrowCrossHead:BTe,insertDatabaseIcon:DTe,insertComputerIcon:RTe,insertClockIcon:NTe}});var zTe,Q3,A_=R(()=>{"use strict";zTe=typeof global=="object"&&global&&global.Object===Object&&global,Q3=zTe});var GTe,$Te,Jn,Ro=R(()=>{"use strict";A_();GTe=typeof self=="object"&&self&&self.Object===Object&&self,$Te=Q3||GTe||Function("return this")(),Jn=$Te});var VTe,Ji,vd=R(()=>{"use strict";Ro();VTe=Jn.Symbol,Ji=VTe});function YTe(t){var e=UTe.call(t,Zy),r=t[Zy];try{t[Zy]=void 0;var n=!0}catch{}var i=HTe.call(t);return n&&(e?t[Zy]=r:delete t[Zy]),i}var _W,UTe,HTe,Zy,LW,DW=R(()=>{"use strict";vd();_W=Object.prototype,UTe=_W.hasOwnProperty,HTe=_W.toString,Zy=Ji?Ji.toStringTag:void 0;o(YTe,"getRawTag");LW=YTe});function XTe(t){return qTe.call(t)}var WTe,qTe,RW,NW=R(()=>{"use strict";WTe=Object.prototype,qTe=WTe.toString;o(XTe,"objectToString");RW=XTe});function QTe(t){return t==null?t===void 0?KTe:jTe:MW&&MW in Object(t)?LW(t):RW(t)}var jTe,KTe,MW,fa,wu=R(()=>{"use strict";vd();DW();NW();jTe="[object Null]",KTe="[object Undefined]",MW=Ji?Ji.toStringTag:void 0;o(QTe,"baseGetTag");fa=QTe});function ZTe(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var pn,Js=R(()=>{"use strict";o(ZTe,"isObject");pn=ZTe});function nke(t){if(!pn(t))return!1;var e=fa(t);return e==eke||e==tke||e==JTe||e==rke}var JTe,eke,tke,rke,wi,Jy=R(()=>{"use strict";wu();Js();JTe="[object AsyncFunction]",eke="[object Function]",tke="[object GeneratorFunction]",rke="[object Proxy]";o(nke,"isFunction");wi=nke});var ike,Z3,IW=R(()=>{"use strict";Ro();ike=Jn["__core-js_shared__"],Z3=ike});function ake(t){return!!OW&&OW in t}var OW,PW,BW=R(()=>{"use strict";IW();OW=function(){var t=/[^.]+$/.exec(Z3&&Z3.keys&&Z3.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();o(ake,"isMasked");PW=ake});function lke(t){if(t!=null){try{return oke.call(t)}catch{}try{return t+""}catch{}}return""}var ske,oke,Tu,__=R(()=>{"use strict";ske=Function.prototype,oke=ske.toString;o(lke,"toSource");Tu=lke});function gke(t){if(!pn(t)||PW(t))return!1;var e=wi(t)?mke:uke;return e.test(Tu(t))}var cke,uke,hke,fke,dke,pke,mke,FW,zW=R(()=>{"use strict";Jy();BW();Js();__();cke=/[\\^$.*+?()[\]{}|]/g,uke=/^\[object .+?Constructor\]$/,hke=Function.prototype,fke=Object.prototype,dke=hke.toString,pke=fke.hasOwnProperty,mke=RegExp("^"+dke.call(pke).replace(cke,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");o(gke,"baseIsNative");FW=gke});function yke(t,e){return t?.[e]}var GW,$W=R(()=>{"use strict";o(yke,"getValue");GW=yke});function vke(t,e){var r=GW(t,e);return FW(r)?r:void 0}var xs,Nh=R(()=>{"use strict";zW();$W();o(vke,"getNative");xs=vke});var xke,ku,ev=R(()=>{"use strict";Nh();xke=xs(Object,"create"),ku=xke});function bke(){this.__data__=ku?ku(null):{},this.size=0}var VW,UW=R(()=>{"use strict";ev();o(bke,"hashClear");VW=bke});function wke(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var HW,YW=R(()=>{"use strict";o(wke,"hashDelete");HW=wke});function Cke(t){var e=this.__data__;if(ku){var r=e[t];return r===Tke?void 0:r}return Eke.call(e,t)?e[t]:void 0}var Tke,kke,Eke,WW,qW=R(()=>{"use strict";ev();Tke="__lodash_hash_undefined__",kke=Object.prototype,Eke=kke.hasOwnProperty;o(Cke,"hashGet");WW=Cke});function _ke(t){var e=this.__data__;return ku?e[t]!==void 0:Ake.call(e,t)}var Ske,Ake,XW,jW=R(()=>{"use strict";ev();Ske=Object.prototype,Ake=Ske.hasOwnProperty;o(_ke,"hashHas");XW=_ke});function Dke(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=ku&&e===void 0?Lke:e,this}var Lke,KW,QW=R(()=>{"use strict";ev();Lke="__lodash_hash_undefined__";o(Dke,"hashSet");KW=Dke});function Hp(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}var L_,ZW=R(()=>{"use strict";UW();YW();qW();jW();QW();o(Hp,"Hash");Hp.prototype.clear=VW;Hp.prototype.delete=HW;Hp.prototype.get=WW;Hp.prototype.has=XW;Hp.prototype.set=KW;L_=Hp});function Rke(){this.__data__=[],this.size=0}var JW,eq=R(()=>{"use strict";o(Rke,"listCacheClear");JW=Rke});function Nke(t,e){return t===e||t!==t&&e!==e}var No,xd=R(()=>{"use strict";o(Nke,"eq");No=Nke});function Mke(t,e){for(var r=t.length;r--;)if(No(t[r][0],e))return r;return-1}var Mh,tv=R(()=>{"use strict";xd();o(Mke,"assocIndexOf");Mh=Mke});function Pke(t){var e=this.__data__,r=Mh(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():Oke.call(e,r,1),--this.size,!0}var Ike,Oke,tq,rq=R(()=>{"use strict";tv();Ike=Array.prototype,Oke=Ike.splice;o(Pke,"listCacheDelete");tq=Pke});function Bke(t){var e=this.__data__,r=Mh(e,t);return r<0?void 0:e[r][1]}var nq,iq=R(()=>{"use strict";tv();o(Bke,"listCacheGet");nq=Bke});function Fke(t){return Mh(this.__data__,t)>-1}var aq,sq=R(()=>{"use strict";tv();o(Fke,"listCacheHas");aq=Fke});function zke(t,e){var r=this.__data__,n=Mh(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}var oq,lq=R(()=>{"use strict";tv();o(zke,"listCacheSet");oq=zke});function Yp(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}var Ih,rv=R(()=>{"use strict";eq();rq();iq();sq();lq();o(Yp,"ListCache");Yp.prototype.clear=JW;Yp.prototype.delete=tq;Yp.prototype.get=nq;Yp.prototype.has=aq;Yp.prototype.set=oq;Ih=Yp});var Gke,Oh,J3=R(()=>{"use strict";Nh();Ro();Gke=xs(Jn,"Map"),Oh=Gke});function $ke(){this.size=0,this.__data__={hash:new L_,map:new(Oh||Ih),string:new L_}}var cq,uq=R(()=>{"use strict";ZW();rv();J3();o($ke,"mapCacheClear");cq=$ke});function Vke(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}var hq,fq=R(()=>{"use strict";o(Vke,"isKeyable");hq=Vke});function Uke(t,e){var r=t.__data__;return hq(e)?r[typeof e=="string"?"string":"hash"]:r.map}var Ph,nv=R(()=>{"use strict";fq();o(Uke,"getMapData");Ph=Uke});function Hke(t){var e=Ph(this,t).delete(t);return this.size-=e?1:0,e}var dq,pq=R(()=>{"use strict";nv();o(Hke,"mapCacheDelete");dq=Hke});function Yke(t){return Ph(this,t).get(t)}var mq,gq=R(()=>{"use strict";nv();o(Yke,"mapCacheGet");mq=Yke});function Wke(t){return Ph(this,t).has(t)}var yq,vq=R(()=>{"use strict";nv();o(Wke,"mapCacheHas");yq=Wke});function qke(t,e){var r=Ph(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}var xq,bq=R(()=>{"use strict";nv();o(qke,"mapCacheSet");xq=qke});function Wp(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}var bd,e5=R(()=>{"use strict";uq();pq();gq();vq();bq();o(Wp,"MapCache");Wp.prototype.clear=cq;Wp.prototype.delete=dq;Wp.prototype.get=mq;Wp.prototype.has=yq;Wp.prototype.set=xq;bd=Wp});function D_(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(Xke);var r=o(function(){var n=arguments,i=e?e.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var s=t.apply(this,n);return r.cache=a.set(i,s)||a,s},"memoized");return r.cache=new(D_.Cache||bd),r}var Xke,qp,R_=R(()=>{"use strict";e5();Xke="Expected a function";o(D_,"memoize");D_.Cache=bd;qp=D_});function jke(){this.__data__=new Ih,this.size=0}var wq,Tq=R(()=>{"use strict";rv();o(jke,"stackClear");wq=jke});function Kke(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}var kq,Eq=R(()=>{"use strict";o(Kke,"stackDelete");kq=Kke});function Qke(t){return this.__data__.get(t)}var Cq,Sq=R(()=>{"use strict";o(Qke,"stackGet");Cq=Qke});function Zke(t){return this.__data__.has(t)}var Aq,_q=R(()=>{"use strict";o(Zke,"stackHas");Aq=Zke});function eEe(t,e){var r=this.__data__;if(r instanceof Ih){var n=r.__data__;if(!Oh||n.length<Jke-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new bd(n)}return r.set(t,e),this.size=r.size,this}var Jke,Lq,Dq=R(()=>{"use strict";rv();J3();e5();Jke=200;o(eEe,"stackSet");Lq=eEe});function Xp(t){var e=this.__data__=new Ih(t);this.size=e.size}var uc,iv=R(()=>{"use strict";rv();Tq();Eq();Sq();_q();Dq();o(Xp,"Stack");Xp.prototype.clear=wq;Xp.prototype.delete=kq;Xp.prototype.get=Cq;Xp.prototype.has=Aq;Xp.prototype.set=Lq;uc=Xp});var tEe,jp,N_=R(()=>{"use strict";Nh();tEe=function(){try{var t=xs(Object,"defineProperty");return t({},"",{}),t}catch{}}(),jp=tEe});function rEe(t,e,r){e=="__proto__"&&jp?jp(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var hc,Kp=R(()=>{"use strict";N_();o(rEe,"baseAssignValue");hc=rEe});function nEe(t,e,r){(r!==void 0&&!No(t[e],r)||r===void 0&&!(e in t))&&hc(t,e,r)}var av,M_=R(()=>{"use strict";Kp();xd();o(nEe,"assignMergeValue");av=nEe});function iEe(t){return function(e,r,n){for(var i=-1,a=Object(e),s=n(e),l=s.length;l--;){var u=s[t?l:++i];if(r(a[u],u,a)===!1)break}return e}}var Rq,Nq=R(()=>{"use strict";o(iEe,"createBaseFor");Rq=iEe});var aEe,Qp,t5=R(()=>{"use strict";Nq();aEe=Rq(),Qp=aEe});function oEe(t,e){if(e)return t.slice();var r=t.length,n=Oq?Oq(r):new t.constructor(r);return t.copy(n),n}var Pq,Mq,sEe,Iq,Oq,r5,I_=R(()=>{"use strict";Ro();Pq=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Mq=Pq&&typeof module=="object"&&module&&!module.nodeType&&module,sEe=Mq&&Mq.exports===Pq,Iq=sEe?Jn.Buffer:void 0,Oq=Iq?Iq.allocUnsafe:void 0;o(oEe,"cloneBuffer");r5=oEe});var lEe,Zp,O_=R(()=>{"use strict";Ro();lEe=Jn.Uint8Array,Zp=lEe});function cEe(t){var e=new t.constructor(t.byteLength);return new Zp(e).set(new Zp(t)),e}var Jp,n5=R(()=>{"use strict";O_();o(cEe,"cloneArrayBuffer");Jp=cEe});function uEe(t,e){var r=e?Jp(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}var i5,P_=R(()=>{"use strict";n5();o(uEe,"cloneTypedArray");i5=uEe});function hEe(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}var a5,B_=R(()=>{"use strict";o(hEe,"copyArray");a5=hEe});var Bq,fEe,Fq,zq=R(()=>{"use strict";Js();Bq=Object.create,fEe=function(){function t(){}return o(t,"object"),function(e){if(!pn(e))return{};if(Bq)return Bq(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}(),Fq=fEe});function dEe(t,e){return function(r){return t(e(r))}}var s5,F_=R(()=>{"use strict";o(dEe,"overArg");s5=dEe});var pEe,em,o5=R(()=>{"use strict";F_();pEe=s5(Object.getPrototypeOf,Object),em=pEe});function gEe(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||mEe;return t===r}var mEe,fc,tm=R(()=>{"use strict";mEe=Object.prototype;o(gEe,"isPrototype");fc=gEe});function yEe(t){return typeof t.constructor=="function"&&!fc(t)?Fq(em(t)):{}}var l5,z_=R(()=>{"use strict";zq();o5();tm();o(yEe,"initCloneObject");l5=yEe});function vEe(t){return t!=null&&typeof t=="object"}var Wn,Mo=R(()=>{"use strict";o(vEe,"isObjectLike");Wn=vEe});function bEe(t){return Wn(t)&&fa(t)==xEe}var xEe,G_,Gq=R(()=>{"use strict";wu();Mo();xEe="[object Arguments]";o(bEe,"baseIsArguments");G_=bEe});var $q,wEe,TEe,kEe,kl,rm=R(()=>{"use strict";Gq();Mo();$q=Object.prototype,wEe=$q.hasOwnProperty,TEe=$q.propertyIsEnumerable,kEe=G_(function(){return arguments}())?G_:function(t){return Wn(t)&&wEe.call(t,"callee")&&!TEe.call(t,"callee")},kl=kEe});var EEe,wt,Bn=R(()=>{"use strict";EEe=Array.isArray,wt=EEe});function SEe(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=CEe}var CEe,nm,c5=R(()=>{"use strict";CEe=9007199254740991;o(SEe,"isLength");nm=SEe});function AEe(t){return t!=null&&nm(t.length)&&!wi(t)}var ei,Io=R(()=>{"use strict";Jy();c5();o(AEe,"isArrayLike");ei=AEe});function _Ee(t){return Wn(t)&&ei(t)}var wd,u5=R(()=>{"use strict";Io();Mo();o(_Ee,"isArrayLikeObject");wd=_Ee});function LEe(){return!1}var Vq,Uq=R(()=>{"use strict";o(LEe,"stubFalse");Vq=LEe});var Wq,Hq,DEe,Yq,REe,NEe,El,im=R(()=>{"use strict";Ro();Uq();Wq=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Hq=Wq&&typeof module=="object"&&module&&!module.nodeType&&module,DEe=Hq&&Hq.exports===Wq,Yq=DEe?Jn.Buffer:void 0,REe=Yq?Yq.isBuffer:void 0,NEe=REe||Vq,El=NEe});function FEe(t){if(!Wn(t)||fa(t)!=MEe)return!1;var e=em(t);if(e===null)return!0;var r=PEe.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&qq.call(r)==BEe}var MEe,IEe,OEe,qq,PEe,BEe,Xq,jq=R(()=>{"use strict";wu();o5();Mo();MEe="[object Object]",IEe=Function.prototype,OEe=Object.prototype,qq=IEe.toString,PEe=OEe.hasOwnProperty,BEe=qq.call(Object);o(FEe,"isPlainObject");Xq=FEe});function c6e(t){return Wn(t)&&nm(t.length)&&!!Mn[fa(t)]}var zEe,GEe,$Ee,VEe,UEe,HEe,YEe,WEe,qEe,XEe,jEe,KEe,QEe,ZEe,JEe,e6e,t6e,r6e,n6e,i6e,a6e,s6e,o6e,l6e,Mn,Kq,Qq=R(()=>{"use strict";wu();c5();Mo();zEe="[object Arguments]",GEe="[object Array]",$Ee="[object Boolean]",VEe="[object Date]",UEe="[object Error]",HEe="[object Function]",YEe="[object Map]",WEe="[object Number]",qEe="[object Object]",XEe="[object RegExp]",jEe="[object Set]",KEe="[object String]",QEe="[object WeakMap]",ZEe="[object ArrayBuffer]",JEe="[object DataView]",e6e="[object Float32Array]",t6e="[object Float64Array]",r6e="[object Int8Array]",n6e="[object Int16Array]",i6e="[object Int32Array]",a6e="[object Uint8Array]",s6e="[object Uint8ClampedArray]",o6e="[object Uint16Array]",l6e="[object Uint32Array]",Mn={};Mn[e6e]=Mn[t6e]=Mn[r6e]=Mn[n6e]=Mn[i6e]=Mn[a6e]=Mn[s6e]=Mn[o6e]=Mn[l6e]=!0;Mn[zEe]=Mn[GEe]=Mn[ZEe]=Mn[$Ee]=Mn[JEe]=Mn[VEe]=Mn[UEe]=Mn[HEe]=Mn[YEe]=Mn[WEe]=Mn[qEe]=Mn[XEe]=Mn[jEe]=Mn[KEe]=Mn[QEe]=!1;o(c6e,"baseIsTypedArray");Kq=c6e});function u6e(t){return function(e){return t(e)}}var Oo,Td=R(()=>{"use strict";o(u6e,"baseUnary");Oo=u6e});var Zq,sv,h6e,$_,f6e,Po,ov=R(()=>{"use strict";A_();Zq=typeof exports=="object"&&exports&&!exports.nodeType&&exports,sv=Zq&&typeof module=="object"&&module&&!module.nodeType&&module,h6e=sv&&sv.exports===Zq,$_=h6e&&Q3.process,f6e=function(){try{var t=sv&&sv.require&&sv.require("util").types;return t||$_&&$_.binding&&$_.binding("util")}catch{}}(),Po=f6e});var Jq,d6e,Bh,lv=R(()=>{"use strict";Qq();Td();ov();Jq=Po&&Po.isTypedArray,d6e=Jq?Oo(Jq):Kq,Bh=d6e});function p6e(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}var cv,V_=R(()=>{"use strict";o(p6e,"safeGet");cv=p6e});function y6e(t,e,r){var n=t[e];(!(g6e.call(t,e)&&No(n,r))||r===void 0&&!(e in t))&&hc(t,e,r)}var m6e,g6e,dc,am=R(()=>{"use strict";Kp();xd();m6e=Object.prototype,g6e=m6e.hasOwnProperty;o(y6e,"assignValue");dc=y6e});function v6e(t,e,r,n){var i=!r;r||(r={});for(var a=-1,s=e.length;++a<s;){var l=e[a],u=n?n(r[l],t[l],l,r,t):void 0;u===void 0&&(u=t[l]),i?hc(r,l,u):dc(r,l,u)}return r}var Bo,kd=R(()=>{"use strict";am();Kp();o(v6e,"copyObject");Bo=v6e});function x6e(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}var eX,tX=R(()=>{"use strict";o(x6e,"baseTimes");eX=x6e});function T6e(t,e){var r=typeof t;return e=e??b6e,!!e&&(r=="number"||r!="symbol"&&w6e.test(t))&&t>-1&&t%1==0&&t<e}var b6e,w6e,Fh,uv=R(()=>{"use strict";b6e=9007199254740991,w6e=/^(?:0|[1-9]\d*)$/;o(T6e,"isIndex");Fh=T6e});function C6e(t,e){var r=wt(t),n=!r&&kl(t),i=!r&&!n&&El(t),a=!r&&!n&&!i&&Bh(t),s=r||n||i||a,l=s?eX(t.length,String):[],u=l.length;for(var h in t)(e||E6e.call(t,h))&&!(s&&(h=="length"||i&&(h=="offset"||h=="parent")||a&&(h=="buffer"||h=="byteLength"||h=="byteOffset")||Fh(h,u)))&&l.push(h);return l}var k6e,E6e,h5,U_=R(()=>{"use strict";tX();rm();Bn();im();uv();lv();k6e=Object.prototype,E6e=k6e.hasOwnProperty;o(C6e,"arrayLikeKeys");h5=C6e});function S6e(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}var rX,nX=R(()=>{"use strict";o(S6e,"nativeKeysIn");rX=S6e});function L6e(t){if(!pn(t))return rX(t);var e=fc(t),r=[];for(var n in t)n=="constructor"&&(e||!_6e.call(t,n))||r.push(n);return r}var A6e,_6e,iX,aX=R(()=>{"use strict";Js();tm();nX();A6e=Object.prototype,_6e=A6e.hasOwnProperty;o(L6e,"baseKeysIn");iX=L6e});function D6e(t){return ei(t)?h5(t,!0):iX(t)}var bs,zh=R(()=>{"use strict";U_();aX();Io();o(D6e,"keysIn");bs=D6e});function R6e(t){return Bo(t,bs(t))}var sX,oX=R(()=>{"use strict";kd();zh();o(R6e,"toPlainObject");sX=R6e});function N6e(t,e,r,n,i,a,s){var l=cv(t,r),u=cv(e,r),h=s.get(u);if(h){av(t,r,h);return}var f=a?a(l,u,r+"",t,e,s):void 0,d=f===void 0;if(d){var p=wt(u),m=!p&&El(u),g=!p&&!m&&Bh(u);f=u,p||m||g?wt(l)?f=l:wd(l)?f=a5(l):m?(d=!1,f=r5(u,!0)):g?(d=!1,f=i5(u,!0)):f=[]:Xq(u)||kl(u)?(f=l,kl(l)?f=sX(l):(!pn(l)||wi(l))&&(f=l5(u))):d=!1}d&&(s.set(u,f),i(f,u,n,a,s),s.delete(u)),av(t,r,f)}var lX,cX=R(()=>{"use strict";M_();I_();P_();B_();z_();rm();Bn();u5();im();Jy();Js();jq();lv();V_();oX();o(N6e,"baseMergeDeep");lX=N6e});function uX(t,e,r,n,i){t!==e&&Qp(e,function(a,s){if(i||(i=new uc),pn(a))lX(t,e,s,r,uX,n,i);else{var l=n?n(cv(t,s),a,s+"",t,e,i):void 0;l===void 0&&(l=a),av(t,s,l)}},bs)}var hX,fX=R(()=>{"use strict";iv();M_();t5();cX();Js();zh();V_();o(uX,"baseMerge");hX=uX});function M6e(t){return t}var ea,Eu=R(()=>{"use strict";o(M6e,"identity");ea=M6e});function I6e(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}var dX,pX=R(()=>{"use strict";o(I6e,"apply");dX=I6e});function O6e(t,e,r){return e=mX(e===void 0?t.length-1:e,0),function(){for(var n=arguments,i=-1,a=mX(n.length-e,0),s=Array(a);++i<a;)s[i]=n[e+i];i=-1;for(var l=Array(e+1);++i<e;)l[i]=n[i];return l[e]=r(s),dX(t,this,l)}}var mX,f5,H_=R(()=>{"use strict";pX();mX=Math.max;o(O6e,"overRest");f5=O6e});function P6e(t){return function(){return t}}var ws,Y_=R(()=>{"use strict";o(P6e,"constant");ws=P6e});var B6e,gX,yX=R(()=>{"use strict";Y_();N_();Eu();B6e=jp?function(t,e){return jp(t,"toString",{configurable:!0,enumerable:!1,value:ws(e),writable:!0})}:ea,gX=B6e});function $6e(t){var e=0,r=0;return function(){var n=G6e(),i=z6e-(n-r);if(r=n,i>0){if(++e>=F6e)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var F6e,z6e,G6e,vX,xX=R(()=>{"use strict";F6e=800,z6e=16,G6e=Date.now;o($6e,"shortOut");vX=$6e});var V6e,d5,W_=R(()=>{"use strict";yX();xX();V6e=vX(gX),d5=V6e});function U6e(t,e){return d5(f5(t,e,ea),t+"")}var pc,sm=R(()=>{"use strict";Eu();H_();W_();o(U6e,"baseRest");pc=U6e});function H6e(t,e,r){if(!pn(r))return!1;var n=typeof e;return(n=="number"?ei(r)&&Fh(e,r.length):n=="string"&&e in r)?No(r[e],t):!1}var eo,Ed=R(()=>{"use strict";xd();Io();uv();Js();o(H6e,"isIterateeCall");eo=H6e});function Y6e(t){return pc(function(e,r){var n=-1,i=r.length,a=i>1?r[i-1]:void 0,s=i>2?r[2]:void 0;for(a=t.length>3&&typeof a=="function"?(i--,a):void 0,s&&eo(r[0],r[1],s)&&(a=i<3?void 0:a,i=1),e=Object(e);++n<i;){var l=r[n];l&&t(e,l,n,a)}return e})}var p5,q_=R(()=>{"use strict";sm();Ed();o(Y6e,"createAssigner");p5=Y6e});var W6e,Gh,X_=R(()=>{"use strict";fX();q_();W6e=p5(function(t,e,r){hX(t,e,r)}),Gh=W6e});function om(t,e){if(!t)return e;let r=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return q6e[r]??e}function Q6e(t,e){let r=t.trim();if(r)return e.securityLevel!=="loose"?(0,TX.sanitizeUrl)(r):r}function CX(t,e){return!t||!e?0:Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function J6e(t){let e,r=0;t.forEach(i=>{r+=CX(i,e),e=i});let n=r/2;return Q_(t,n)}function eCe(t){return t.length===1?t[0]:J6e(t)}function rCe(t,e,r){let n=structuredClone(r);V.info("our points",n),e!=="start_left"&&e!=="start_right"&&n.reverse();let i=25+t,a=Q_(n,i),s=10+t*.5,l=Math.atan2(n[0].y-a.y,n[0].x-a.x),u={x:0,y:0};return e==="start_left"?(u.x=Math.sin(l+Math.PI)*s+(n[0].x+a.x)/2,u.y=-Math.cos(l+Math.PI)*s+(n[0].y+a.y)/2):e==="end_right"?(u.x=Math.sin(l-Math.PI)*s+(n[0].x+a.x)/2-5,u.y=-Math.cos(l-Math.PI)*s+(n[0].y+a.y)/2-5):e==="end_left"?(u.x=Math.sin(l)*s+(n[0].x+a.x)/2-5,u.y=-Math.cos(l)*s+(n[0].y+a.y)/2-5):(u.x=Math.sin(l)*s+(n[0].x+a.x)/2,u.y=-Math.cos(l)*s+(n[0].y+a.y)/2),u}function lm(t){let e="",r="";for(let n of t)n!==void 0&&(n.startsWith("color:")||n.startsWith("text-align:")?r=r+n+";":e=e+n+";");return{style:e,labelStyle:r}}function nCe(t){let e="",r="0123456789abcdef",n=r.length;for(let i=0;i<t;i++)e+=r.charAt(Math.floor(Math.random()*n));return e}function g5(t,e){return t9(t,e).height}function Cl(t,e){return t9(t,e).width}function r9(t){return"str"in t}function Ts(t,e){return Gh({},t,e)}var TX,K_,q6e,X6e,j6e,kX,EX,K6e,Z6e,bX,Q_,tCe,wX,Z_,J_,iCe,aCe,e9,sCe,t9,j_,m5,oCe,lCe,mc,Lt,SX,to,y5,xr=R(()=>{"use strict";TX=Xi(Up(),1);Zt();rr();r7();ut();Hf();cp();R_();X_();Vb();K_="\u200B",q6e={curveBasis:vs,curveBasisClosed:B3,curveBasisOpen:F3,curveBumpX:s_,curveBumpY:o_,curveBundle:l_,curveCardinalClosed:u_,curveCardinalOpen:f_,curveCardinal:c_,curveCatmullRomClosed:m_,curveCatmullRomOpen:g_,curveCatmullRom:p_,curveLinear:xu,curveLinearClosed:U3,curveMonotoneX:v_,curveMonotoneY:x_,curveNatural:Y3,curveStep:q3,curveStepAfter:w_,curveStepBefore:b_},X6e=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,j6e=o(function(t,e){let r=kX(t,/(?:init\b)|(?:initialize\b)/),n={};if(Array.isArray(r)){let s=r.map(l=>l.args);fp(s),n=On(n,[...s])}else n=r.args;if(!n)return;let i=lp(t,e),a="config";return n[a]!==void 0&&(i==="flowchart-v2"&&(i="flowchart"),n[i]=n[a],delete n[a]),n},"detectInit"),kX=o(function(t,e=null){try{let r=new RegExp(`[%]{2}(?![{]${X6e.source})(?=[}][%]{2}).*
406 res:`,sr.polygon(e,h,p)),sr.polygon(e,h,p)},i},"question")});var nAe,jK,KK=R(()=>{"use strict";ri();hi();ki();ti();Du();nAe=o((t,e,r,n,i)=>[`M${t+i},${e}`,`L${t+r-i},${e}`,`L${t+r},${e-n/2}`,`L${t+r-i},${e-n}`,`L${t+i},${e-n}`,`L${t},${e-n/2}`,"Z"].join(" "),"createHexagonPathD"),jK=o(async(t,e)=>{let{labelStyles:r,nodeStyles:n}=Br(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await zr(t,e,En(e)),s=4,l=a.height+e.padding,u=l/s,h=a.width+2*u+e.padding,f=[{x:u,y:0},{x:h-u,y:0},{x:h,y:-l/2},{x:h-u,y:-l},{x:u,y:-l},{x:0,y:-l/2}],d,{cssStyles:p}=e;if(e.look==="handDrawn"){let m=Jt.svg(i),g=Fr(e,{}),y=nAe(0,0,h,l,u),v=m.path(y,g);d=i.insert(()=>v,":first-child").attr("transform",`translate(${-h/2}, ${l/2})`),p&&d.attr("style",p)}else d=Ma(i,h,l,f);return n&&d.attr("style",n),e.width=h,e.height=l,ar(e,d),e.intersect=function(m){return sr.polygon(e,f,m)},i},"hexagon")});var iAe,QK,ZK=R(()=>{"use strict";ri();hi();ki();ti();Du();iAe=o((t,e,r,n)=>[`M${t-2*n/6},${e}`,`L${t+r-n/6},${e}`,`L${t+r+2*n/6},${e-n}`,`L${t+n/6},${e-n}`,"Z"].join(" "),"createLeanRightPathD"),QK=o(async(t,e)=>{let{labelStyles:r,nodeStyles:n}=Br(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await zr(t,e,En(e)),s=a.width+e.padding,l=a.height+e.padding,u=[{x:-2*l/6,y:0},{x:s-l/6,y:0},{x:s+2*l/6,y:-l},{x:l/6,y:-l}],h,{cssStyles:f}=e;if(e.look==="handDrawn"){let d=Jt.svg(i),p=Fr(e,{}),m=iAe(0,0,s,l),g=d.path(m,p);h=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${l/2})`),f&&h.attr("style",f)}else h=Ma(i,s,l,u);return n&&h.attr("style",n),e.width=s,e.height=l,ar(e,h),e.intersect=function(d){return sr.polygon(e,u,d)},i},"lean_right")});var aAe,JK,eQ=R(()=>{"use strict";ri();hi();ki();ti();Du();aAe=o((t,e,r,n)=>[`M${t+2*n/6},${e}`,`L${t+r+n/6},${e}`,`L${t+r-2*n/6},${e-n}`,`L${t-n/6},${e-n}`,"Z"].join(" "),"createLeanLeftPathD"),JK=o(async(t,e)=>{let{labelStyles:r,nodeStyles:n}=Br(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await zr(t,e,En(e)),s=a.width+e.padding,l=a.height+e.padding,u=[{x:2*l/6,y:0},{x:s+l/6,y:0},{x:s-2*l/6,y:-l},{x:-l/6,y:-l}],h,{cssStyles:f}=e;if(e.look==="handDrawn"){let d=Jt.svg(i),p=Fr(e,{}),m=aAe(0,0,s,l),g=d.path(m,p);h=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${l/2})`),f&&h.attr("style",f)}else h=Ma(i,s,l,u);return n&&h.attr("style",n),e.width=s,e.height=l,ar(e,h),e.intersect=function(d){return sr.polygon(e,u,d)},i},"lean_left")});var sAe,tQ,rQ=R(()=>{"use strict";ri();hi();ki();ti();Du();sAe=o((t,e,r,n)=>[`M${t-2*n/6},${e}`,`L${t+r+2*n/6},${e}`,`L${t+r-n/6},${e-n}`,`L${t+n/6},${e-n}`,"Z"].join(" "),"createTrapezoidPathD"),tQ=o(async(t,e)=>{let{labelStyles:r,nodeStyles:n}=Br(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await zr(t,e,En(e)),s=a.width+e.padding,l=a.height+e.padding,u=[{x:-2*l/6,y:0},{x:s+2*l/6,y:0},{x:s-l/6,y:-l},{x:l/6,y:-l}],h,{cssStyles:f}=e;if(e.look==="handDrawn"){let d=Jt.svg(i),p=Fr(e,{}),m=sAe(0,0,s,l),g=d.path(m,p);h=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${l/2})`),f&&h.attr("style",f)}else h=Ma(i,s,l,u);return n&&h.attr("style",n),e.width=s,e.height=l,ar(e,h),e.intersect=function(d){return sr.polygon(e,u,d)},i},"trapezoid")});var oAe,nQ,iQ=R(()=>{"use strict";ri();hi();ki();ti();Du();oAe=o((t,e,r,n)=>[`M${t+n/6},${e}`,`L${t+r-n/6},${e}`,`L${t+r+2*n/6},${e-n}`,`L${t-2*n/6},${e-n}`,"Z"].join(" "),"createInvertedTrapezoidPathD"),nQ=o(async(t,e)=>{let{labelStyles:r,nodeStyles:n}=Br(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await zr(t,e,En(e)),s=a.width+e.padding,l=a.height+e.padding,u=[{x:l/6,y:0},{x:s-l/6,y:0},{x:s+2*l/6,y:-l},{x:-2*l/6,y:-l}],h,{cssStyles:f}=e;if(e.look==="handDrawn"){let d=Jt.svg(i),p=Fr(e,{}),m=oAe(0,0,s,l),g=d.path(m,p);h=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${l/2})`),f&&h.attr("style",f)}else h=Ma(i,s,l,u);return n&&h.attr("style",n),e.width=s,e.height=l,ar(e,h),e.intersect=function(d){return sr.polygon(e,u,d)},i},"inv_trapezoid")});var aQ,sQ=R(()=>{"use strict";_v();ri();hi();aQ=o(async(t,e)=>{let{shapeSvg:r}=await zr(t,e,"label"),n=r.insert("rect",":first-child");return n.attr("width",.1).attr("height",.1),r.attr("class","label edgeLabel"),ar(e,n),e.intersect=function(s){return sr.rect(e,s)},r},"labelRect")});var oQ,ym,rw,lQ,cQ,eL,tL=R(()=>{"use strict";ut();xK();wK();kK();CK();AK();_K();DK();NK();IK();PK();_t();FK();GK();VK();HK();WK();XK();KK();ZK();eQ();rQ();iQ();sQ();oQ={state:vK,stateStart:EK,stateEnd:SK,fork:J9,join:J9,choice:LK,note:RK,roundedRect:bK,rectWithTitle:OK,squareRect:TK,stadium:MK,subroutine:BK,cylinder:zK,circle:$K,doublecircle:UK,odd:YK,diamond:qK,hexagon:jK,lean_right:QK,lean_left:JK,trapezoid:tQ,inv_trapezoid:nQ,labelRect:aQ},ym=new Map,rw=o(async(t,e,r)=>{let n,i;if(e.shape==="rect"&&(e.rx&&e.ry?e.shape="roundedRect":e.shape="squareRect"),e.link){let a;de().securityLevel==="sandbox"?a="_top":e.linkTarget&&(a=e.linkTarget||"_blank"),n=t.insert("svg:a").attr("xlink:href",e.link).attr("target",a),i=await oQ[e.shape](n,e,r)}else i=await oQ[e.shape](t,e,r),n=i;return e.tooltip&&i.attr("title",e.tooltip),ym.set(e.id,n),e.haveCallback&&ym.get(e.id).attr("class",ym.get(e.id).attr("class")+" clickable"),n},"insertNode"),lQ=o((t,e)=>{ym.set(e.id,t)},"setNodeElem"),cQ=o(()=>{ym.clear()},"clear"),eL=o(t=>{let e=ym.get(t.id);V.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");let r=8,n=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+n-t.width/2)+", "+(t.y-t.height/2-r)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),n},"positionNode")});var uQ,hQ=R(()=>{"use strict";qs();rr();ut();X9();K9();Q9();tL();ri();xr();uQ={common:We,getConfig:Or,insertCluster:Y5,insertEdge:J5,insertEdgeLabel:Q5,insertMarkers:ew,insertNode:rw,interpolateToCurve:om,labelHelper:zr,log:V,positionEdgeLabel:Z5}});function cAe(t){return typeof t=="symbol"||Wn(t)&&fa(t)==lAe}var lAe,so,Nd=R(()=>{"use strict";wu();Mo();lAe="[object Symbol]";o(cAe,"isSymbol");so=cAe});function uAe(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var Ss,Md=R(()=>{"use strict";o(uAe,"arrayMap");Ss=uAe});function pQ(t){if(typeof t=="string")return t;if(wt(t))return Ss(t,pQ)+"";if(so(t))return dQ?dQ.call(t):"";var e=t+"";return e=="0"&&1/t==-hAe?"-0":e}var hAe,fQ,dQ,mQ,gQ=R(()=>{"use strict";vd();Md();Bn();Nd();hAe=1/0,fQ=Ji?Ji.prototype:void 0,dQ=fQ?fQ.toString:void 0;o(pQ,"baseToString");mQ=pQ});function dAe(t){for(var e=t.length;e--&&fAe.test(t.charAt(e)););return e}var fAe,yQ,vQ=R(()=>{"use strict";fAe=/\s/;o(dAe,"trimmedEndIndex");yQ=dAe});function mAe(t){return t&&t.slice(0,yQ(t)+1).replace(pAe,"")}var pAe,xQ,bQ=R(()=>{"use strict";vQ();pAe=/^\s+/;o(mAe,"baseTrim");xQ=mAe});function bAe(t){if(typeof t=="number")return t;if(so(t))return wQ;if(pn(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=pn(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=xQ(t);var r=yAe.test(t);return r||vAe.test(t)?xAe(t.slice(2),r?2:8):gAe.test(t)?wQ:+t}var wQ,gAe,yAe,vAe,xAe,TQ,kQ=R(()=>{"use strict";bQ();Js();Nd();wQ=NaN,gAe=/^[-+]0x[0-9a-f]+$/i,yAe=/^0b[01]+$/i,vAe=/^0o[0-7]+$/i,xAe=parseInt;o(bAe,"toNumber");TQ=bAe});function TAe(t){if(!t)return t===0?t:0;if(t=TQ(t),t===EQ||t===-EQ){var e=t<0?-1:1;return e*wAe}return t===t?t:0}var EQ,wAe,vm,rL=R(()=>{"use strict";kQ();EQ=1/0,wAe=17976931348623157e292;o(TAe,"toFinite");vm=TAe});function kAe(t){var e=vm(t),r=e%1;return e===e?r?e-r:e:0}var yc,xm=R(()=>{"use strict";rL();o(kAe,"toInteger");yc=kAe});var EAe,nw,CQ=R(()=>{"use strict";Nh();Ro();EAe=xs(Jn,"WeakMap"),nw=EAe});function CAe(){}var qn,nL=R(()=>{"use strict";o(CAe,"noop");qn=CAe});function SAe(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}var iw,iL=R(()=>{"use strict";o(SAe,"arrayEach");iw=SAe});function AAe(t,e,r,n){for(var i=t.length,a=r+(n?1:-1);n?a--:++a<i;)if(e(t[a],a,t))return a;return-1}var aw,aL=R(()=>{"use strict";o(AAe,"baseFindIndex");aw=AAe});function _Ae(t){return t!==t}var SQ,AQ=R(()=>{"use strict";o(_Ae,"baseIsNaN");SQ=_Ae});function LAe(t,e,r){for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return-1}var _Q,LQ=R(()=>{"use strict";o(LAe,"strictIndexOf");_Q=LAe});function DAe(t,e,r){return e===e?_Q(t,e,r):aw(t,SQ,r)}var bm,sw=R(()=>{"use strict";aL();AQ();LQ();o(DAe,"baseIndexOf");bm=DAe});function RAe(t,e){var r=t==null?0:t.length;return!!r&&bm(t,e,0)>-1}var ow,sL=R(()=>{"use strict";sw();o(RAe,"arrayIncludes");ow=RAe});var NAe,DQ,RQ=R(()=>{"use strict";F_();NAe=s5(Object.keys,Object),DQ=NAe});function OAe(t){if(!fc(t))return DQ(t);var e=[];for(var r in Object(t))IAe.call(t,r)&&r!="constructor"&&e.push(r);return e}var MAe,IAe,wm,lw=R(()=>{"use strict";tm();RQ();MAe=Object.prototype,IAe=MAe.hasOwnProperty;o(OAe,"baseKeys");wm=OAe});function PAe(t){return ei(t)?h5(t):wm(t)}var Dr,vc=R(()=>{"use strict";U_();lw();Io();o(PAe,"keys");Dr=PAe});var BAe,FAe,zAe,pa,NQ=R(()=>{"use strict";am();kd();q_();Io();tm();vc();BAe=Object.prototype,FAe=BAe.hasOwnProperty,zAe=p5(function(t,e){if(fc(e)||ei(e)){Bo(e,Dr(e),t);return}for(var r in e)FAe.call(e,r)&&dc(t,r,e[r])}),pa=zAe});function VAe(t,e){if(wt(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||so(t)?!0:$Ae.test(t)||!GAe.test(t)||e!=null&&t in Object(e)}var GAe,$Ae,Tm,cw=R(()=>{"use strict";Bn();Nd();GAe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,$Ae=/^\w*$/;o(VAe,"isKey");Tm=VAe});function HAe(t){var e=qp(t,function(n){return r.size===UAe&&r.clear(),n}),r=e.cache;return e}var UAe,MQ,IQ=R(()=>{"use strict";R_();UAe=500;o(HAe,"memoizeCapped");MQ=HAe});var YAe,WAe,qAe,OQ,PQ=R(()=>{"use strict";IQ();YAe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,WAe=/\\(\\)?/g,qAe=MQ(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(YAe,function(r,n,i,a){e.push(i?a.replace(WAe,"$1"):n||r)}),e}),OQ=qAe});function XAe(t){return t==null?"":mQ(t)}var uw,oL=R(()=>{"use strict";gQ();o(XAe,"toString");uw=XAe});function jAe(t,e){return wt(t)?t:Tm(t,e)?[t]:OQ(uw(t))}var Hh,Lv=R(()=>{"use strict";Bn();cw();PQ();oL();o(jAe,"castPath");Hh=jAe});function QAe(t){if(typeof t=="string"||so(t))return t;var e=t+"";return e=="0"&&1/t==-KAe?"-0":e}var KAe,xc,km=R(()=>{"use strict";Nd();KAe=1/0;o(QAe,"toKey");xc=QAe});function ZAe(t,e){e=Hh(e,t);for(var r=0,n=e.length;t!=null&&r<n;)t=t[xc(e[r++])];return r&&r==n?t:void 0}var Yh,Dv=R(()=>{"use strict";Lv();km();o(ZAe,"baseGet");Yh=ZAe});function JAe(t,e,r){var n=t==null?void 0:Yh(t,e);return n===void 0?r:n}var BQ,FQ=R(()=>{"use strict";Dv();o(JAe,"get");BQ=JAe});function e8e(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}var Em,hw=R(()=>{"use strict";o(e8e,"arrayPush");Em=e8e});function t8e(t){return wt(t)||kl(t)||!!(zQ&&t&&t[zQ])}var zQ,GQ,$Q=R(()=>{"use strict";vd();rm();Bn();zQ=Ji?Ji
[all...]
/plugin/ol3/
H A Dscript.js8Ji=0,Qi=1,to=2,eo=3,ro=4;function no(t){return Math.pow(t,3)}function io(t){return 1-no(1-t)}funct…
/plugin/xlsx2dw/packages/xmltojson/
H A Dxmltojson.js344 function Ji(a){return Lc(a,4)&&!Fc(a,4).T()?Zl(Fc(Fc(a,4).Y().Q().db(),8).ib()):''} function
586Ji(Ki((ps(h+1,g.a.length),g.a[h+1]))),rt);if(j==null){li(mi(b),'<'+(c==null?Jt:Ii(c,e))+(a.U()==1?…
/plugin/findologicxmlexport/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/
H A Dd3.min.js2Ji(n,t){return ao.rebind(n,t,"range","rangeRound","interpolate","clamp")}function Gi(n,t){return X… function
3 …tickFormat=function(){return e},r.copy=function(){return ro(n.copy(),t,e)},Ji(r,n)}function io(n){…
/plugin/sequencediagram/bower_components/lodash/dist/
H A Dlodash.min.js78 …Set"),qi=je(mn,"WeakMap"),Vi=je(Qu,"create"),Ki=qi&&new qi,Gi={},Hi=Te(Fi),Ji=Te(Ni),Yi=Te(Pi),Qi=…
85 …n.constructor:T)?Te(n):"")switch(n){case Hi:return"[object DataView]";case Ji:return"[object Map]"…
/plugin/flowcharts/
H A Dmermaid.min.js1Ji=Zi,Qi=function(){var t,e,n,r=[],i=[];function a(n,i,o,s){if(i>=r.length)return null!=t&&n.sort(…
/plugin/quickstats/GEOIP/vendor/composer/ca-bundle/res/
H A Dcacert.pem2067 Dx4JnW2PAJ8C2sH6H3p6CcRK5ogql5+Ji/03X186zjhZhkuvcQu02PJwT58yE+Owp1fl2tpDy4Q0
/plugin/xtern/ca/
H A Dcacert.pem2067 Dx4JnW2PAJ8C2sH6H3p6CcRK5ogql5+Ji/03X186zjhZhkuvcQu02PJwT58yE+Owp1fl2tpDy4Q0
/plugin/bpmnio/vendor/dmn-js/dist/
H A Ddmn-viewer.production.min.js2 !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).DmnJS=t()}(this,(function(){"use strict";const e=Object.prototype.toString,t=Object.prototype.hasOwnProperty;function n(e){return void 0!==e}function i(t){return"[object Array]"===e.call(t)}function r(t){return"[object Object]"===e.call(t)}function o(t){return"[object Number]"===e.call(t)}function s(t){const n=e.call(t);return"[object Function]"===n||"[object AsyncFunction]"===n||"[object GeneratorFunction]"===n||"[object AsyncGeneratorFunction]"===n||"[object Proxy]"===n}function a(t){return"[object String]"===e.call(t)}function l(e,n){return!(null==e)&&t.call(e,n)}function c(e,t){const n=g(t);let i;return u(e,(function(e,t){if(n(e,t))return i=e,!1})),i}function h(e,t){const n=g(t);let i=[];return u(e,(function(e,t){n(e,t)&&i.push(e)})),i}function u(e,t){let n,r;if(void 0===e)return;const o=i(e)?y:m;for(let i in e)if(l(e,i)&&(n=e[i],r=t(n,o(i)),!1===r))return n}function d(e,t,n){return u(e,(function(e,i){n=t(n,e,i)})),n}function p(e,t){return!!d(e,(function(e,n,i){return e&&t(n,i)}),!0)}function f(e){return function(t){return p(e,(function(e,n){return t[n]===e}))}}function g(e){return s(e)?e:t=>t===e}function m(e){return e}function y(e){return Number(e)}function v(e,t){let n,i,r,o;function s(n){let s=Date.now(),c=n?0:o+t-s;if(c>0)return a(c);e.apply(r,i),l()}function a(e){n=setTimeout(s,e)}function l(){n&&clearTimeout(n),n=o=i=r=void 0}function c(...e){o=Date.now(),i=e,r=this,n||a(t)}return c.flush=function(){n&&s(!0),l()},c.cancel=l,c}function w(e,t){return e.bind(t)}function b(e,...t){return Object.assign(e,...t)}var x="__fn",k=Array.prototype.slice;function _(){this._listeners={},this.on("diagram.destroy",1,this._destroy,this)}function S(){}_.prototype.on=function(e,t,n,r){if(e=i(e)?e:[e],s(t)&&(r=n,n=t,t=1e3),!o(t))throw new Error("priority must be a number");var a=n;r&&((a=w(n,r))[x]=n[x]||n);var l=this;e.forEach((function(e){l._addListener(e,{priority:t,callback:a,next:null})}))},_.prototype.once=function(e,t,n,i){var r=this;if(s(t)&&(i=n,n=t,t=1e3),!o(t))throw new Error("priority must be a number");function a(){a.__isTomb=!0;var t=n.apply(i,arguments);return r.off(e,a),t}a[x]=n,this.on(e,t,a)},_.prototype.off=function(e,t){e=i(e)?e:[e];var n=this;e.forEach((function(e){n._removeListener(e,t)}))},_.prototype.createEvent=function(e){var t=new S;return t.init(e),t},_.prototype.fire=function(e,t){var n,i,r,o;if(o=k.call(arguments),"object"==typeof e&&(e=(t=e).type),!e)throw new Error("no event type specified");if(i=this._listeners[e]){n=t instanceof S?t:this.createEvent(t),o[0]=n;var s=n.type;e!==s&&(n.type=e);try{r=this._invokeListeners(n,o,i)}finally{e!==s&&(n.type=s)}return void 0===r&&n.defaultPrevented&&(r=!1),r}},_.prototype.handleError=function(e){return!1===this.fire("error",{error:e})},_.prototype._destroy=function(){this._listeners={}},_.prototype._invokeListeners=function(e,t,n){for(var i;n&&!e.cancelBubble;)i=this._invokeListener(e,t,n),n=n.next;return i},_.prototype._invokeListener=function(e,t,n){var i;if(n.callback.__isTomb)return i;try{i=function(e,t){return e.apply(null,t)}(n.callback,t),void 0!==i&&(e.returnValue=i,e.stopPropagation()),!1===i&&e.preventDefault()}catch(e){if(!this.handleError(e))throw console.error("unhandled error in event listener",e),e}return i},_.prototype._addListener=function(e,t){var n,i=this._getListeners(e);if(i){for(;i;){if(i.priority<t.priority)return t.next=i,void(n?n.next=t:this._setListeners(e,t));n=i,i=i.next}n.next=t}else this._setListeners(e,t)},_.prototype._getListeners=function(e){return this._listeners[e]},_.prototype._setListeners=function(e,t){this._listeners[e]=t},_.prototype._removeListener=function(e,t){var n,i,r,o=this._getListeners(e);if(t)for(;o;)n=o.next,(r=o.callback)!==t&&r[x]!==t||(i?i.next=n:this._setListeners(e,n)),i=o,o=n;else this._setListeners(e,null)},S.prototype.stopPropagation=function(){this.cancelBubble=!0},S.prototype.preventDefault=function(){this.defaultPrevented=!0},S.prototype.init=function(e){b(this,e||{})};var C=Object.prototype.toString;function E(){return E=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},E.apply(this,arguments)}function M(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return E.apply(void 0,[e].concat(n))}var A=Object.prototype.toString,D=Object.prototype.hasOwnProperty;function R(e){return"[object String]"===A.call(e)}function O(e,t){return D.call(e,t)}function T(e,t){var n;if(void 0!==e){var i=function(e){return"[object Array]"===A.call(e)}(e)?P:N;for(var r in e)if(O(e,r)&&!1===t(n=e[r],i(r)))return n}}function N(e){return e}function P(e){return Number(e)}function q(e,t){return e.bind(t)}function B(){return B=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},B.apply(this,arguments)}function L(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return B.apply(void 0,[e].concat(n))}function I(){}function F(e,t){this.model=e,this.properties=t}I.prototype.get=function(e){return this.$model.properties.get(this,e)},I.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},F.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(I.prototype);T(e.properties,(function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)})),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function o(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),T(e,q((function(e,t){this.set(t,e)}),this))}return o.prototype=i,o.hasType=i.$instanceOf=this.model.hasType,n.defineModel(o,t),n.defineDescriptor(o,e),o};var j={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},V={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e)}};function $(e,t){var n=V[e];return n?n(t):t}function z(e){return!!j[e]}function H(e){return!!V[e]}function W(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function U(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function G(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,T(e,q(this.registerPackage,this))}function K(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function X(e){this.model=e}function Y(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function J(e){this.properties=new X(this),this.factory=new F(this,this.properties),this.registry=new G(e,this.properties),this.typeCache={}}U.prototype.build=function(){return e=this,t=["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"],n={},i=Object(e),T(t,(function(t){t in i&&(n[t]=e[t])})),n;var e,t,n,i},U.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},U.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,o=this.propertiesByName,s=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var a=r.indexOf(e);if(-1===a)throw new Error("property <"+i.name+"> not found in property list");r.splice(a,1),this.addProperty(t,n?void 0:a,s),o[i.name]=o[i.localName]=t},U.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),o=W(r[0],i),s=W(r[1],o.prefix).name,a=this.propertiesByName[s];if(!a)throw new Error("refined property <"+s+"> not found");this.replaceProperty(a,e,n),delete e.redefines},U.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},U.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},U.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},U.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},U.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},U.prototype.hasProperty=function(e){return this.propertiesByName[e]},U.prototype.addTrait=function(e,t){var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(T(e.properties,q((function(n){n=L({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))}),this)),i.push(e),n[r]=e)},G.prototype.getPackage=function(e){return this.packageMap[e]},G.prototype.getPackages=function(){return this.packages},G.prototype.registerPackage=function(e){e=L({},e);var t=this.packageMap;K(t,e,"prefix"),K(t,e,"uri"),T(e.types,q((function(t){this.registerType(t,e)}),this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},G.prototype.registerType=function(e,t){var n=W((e=L({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:L(e.meta||{})})).name,t.prefix),i=n.name,r={};T(e.properties,q((function(e){var t=W(e.name,n.prefix),i=t.name;z(e.type)||(e.type=W(e.type,t.prefix).name),L(e,{ns:t,name:i}),r[i]=e}),this)),L(e,{ns:n,name:i,propertiesByName:r}),T(e.extends,q((function(e){var t=this.typeMap[e];t.traits=t.traits||[],t.traits.push(i)}),this)),this.definePackage(e,t),this.typeMap[i]=e},G.prototype.mapTypes=function(e,t,n){var i=z(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function o(e){return s(e,!0)}function s(n,i){var o=W(n,z(n)?"":e.prefix);r.mapTypes(o,t,i)}if(!i)throw new Error("unknown type <"+e.name+">");T(i.superClass,n?o:s),t(i,!n),T(i.traits,o)},G.prototype.getEffectiveDescriptor=function(e){var t=W(e),n=new U(t);this.mapTypes(t,(function(e,t){n.addTrait(e,t)}));var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},G.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},X.prototype.set=function(e,t,n){if(!R(t)||!t.length)throw new TypeError("property name must be a non-empty string");var i=this.model.getPropertyDescriptor(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[t]:i?r in e?e[r]=n:Y(e,i,n):e.$attrs[t]=n},X.prototype.get=function(e,t){var n=this.model.getPropertyDescriptor(e,t);if(!n)return e.$attrs[t];var i=n.name;return!e[i]&&n.isMany&&Y(e,n,[]),e[i]},X.prototype.define=function(e,t,n){if(!n.writable){var i=n.value;delete(n=L({},n,{get:function(){return i}})).value}Object.defineProperty(e,t,n)},X.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},X.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},J.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},J.prototype.getType=function(e){var t=this.typeCache,n=R(e)?e:e.ns.name,i=t[n];return i||(e=this.registry.getEffectiveDescriptor(n),i=t[n]=this.factory.createType(e)),i},J.prototype.createAny=function(e,t,n){var i=W(e),r={$type:e,$instanceOf:function(e){return e===this.$type}},o={name:e,isGeneric:!0,ns:{prefix:i.prefix,localName:i.localName,uri:t}};return this.properties.defineDescriptor(r,o),this.properties.defineModel(r,this),this.properties.define(r,"$parent",{enumerable:!1,writable:!0}),this.properties.define(r,"$instanceOf",{enumerable:!1,writable:!0}),T(n,(function(e,t){var n;n=e,"[object Object]"===A.call(n)&&void 0!==e.value?r[e.name]=e.value:r[t]=e})),r},J.prototype.getPackage=function(e){return this.registry.getPackage(e)},J.prototype.getPackages=function(){return this.registry.getPackages()},J.prototype.getElementDescriptor=function(e){return e.$descriptor},J.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},J.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},J.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var Q=Object.prototype.toString,Z=Object.prototype.hasOwnProperty;function ee(e){return"[object Array]"===Q.call(e)}function te(e){return"[object String]"===Q.call(e)}function ne(e,t){return Z.call(e,t)}function ie(e,t){var n;return t=se(t),oe(e,(function(e,i){if(t(e,i))return n=e,!1})),n}function re(e,t){var n=[];return oe(e,(function(e,i){t(e,i)&&n.push(e)})),n}function oe(e,t){var n;if(void 0!==e){var i=ee(e)?le:ae;for(var r in e)if(ne(e,r)&&!1===t(n=e[r],i(r)))return n}}function se(e){return t=e,"[object Function]"===(n=Q.call(t))||"[object AsyncFunction]"===n||"[object GeneratorFunction]"===n||"[object AsyncGeneratorFunction]"===n||"[object Proxy]"===n?e:function(t){return t===e};var t,n}function ae(e){return e}function le(e){return Number(e)}function ce(){return ce=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},ce.apply(this,arguments)}function he(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return ce.apply(void 0,[e].concat(n))}var ue=String.fromCharCode,de=Object.prototype.hasOwnProperty,pe=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,fe={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function ge(e,t,n,i){return i?de.call(fe,i)?fe[i]:"&"+i+";":ue(t||parseInt(n,16))}function me(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(pe,ge):e}Object.keys(fe).forEach((function(e){fe[e.toUpperCase()]=fe[e]}));var ye="xsi:type",ve="non-whitespace outside of root node";function we(e){return new Error(e)}function be(e){return"missing namespace for prefix <"+e+">"}function xe(e){return{get:e,enumerable:!0}}function ke(e){var t,n={};for(t in e)n[t]=e[t];return n}function _e(e){return e+"$uri"}function Se(){return{line:0,column:0}}function Ce(e){throw e}function Ee(e){if(!this)return new Ee(e);var t,n,i,r,o,s,a,l,c,h=e&&e.proxy,u=Ce,d=Se,p=!1,f=!1,g=null,m=!1;function y(e){e instanceof Error||(e=we(e)),g=e,u(e,d)}function v(e){o&&(e instanceof Error||(e=we(e)),o(e,d))}this.on=function(e,c){if("function"!=typeof c)throw we("required args <name, cb>");switch(e){case"openTag":n=c;break;case"text":t=c;break;case"closeTag":i=c;break;case"error":u=c;break;case"warn":o=c;break;case"cdata":r=c;break;case"attention":l=c;break;case"question":a=c;break;case"comment":s=c;break;default:throw we("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw we("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return n["http://www.w3.org/2001/XMLSchema-instance"]="xsi",f=!0,c=n,this},this.parse=function(e){if("string"!=typeof e)throw we("required args <xml=string>");return g=null,function(e){var o,u,g,w,b,x,k,_,S,C,E,M=f?[]:null,A=f?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[_e(n)]=t;return i}(c):null,D=[],R=0,O=!1,T=!1,N=0,P=0,q="",B=0;function L(){if(null!==E)return E;var e,t,n,i,r,o,s,a,l,h,u,d=f&&A.xmlns,g=f&&p?[]:null,m=B,y=q,w=y.length,b={},x={};e:for(;m<w;m++)if(l=!1,!(32===(h=y.charCodeAt(m))||h<14&&h>8)){for((h<65||h>122||h>90&&h<97)&&95!==h&&58!==h&&(v("illegal first char attribute name"),l=!0),u=m+1;u<w;u++)if(!((h=y.charCodeAt(u))>96&&h<123||h>64&&h<91||h>47&&h<59||46===h||45===h||95===h)){if(32===h||h<14&&h>8){v("missing attribute value"),m=u;continue e}if(61===h)break;v("illegal attribute name char"),l=!0}if("xmlns:xmlns"===(a=y.substring(m,u))&&(v("illegal declaration of xmlns"),l=!0),34===(h=y.charCodeAt(u+1)))-1===(u=y.indexOf('"',m=u+2))&&-1!==(u=y.indexOf("'",m))&&(v("attribute value quote missmatch"),l=!0);else if(39===h)-1===(u=y.indexOf("'",m=u+2))&&-1!==(u=y.indexOf('"',m))&&(v("attribute value quote missmatch"),l=!0);else for(v("missing attribute value quotes"),l=!0,u+=1;u<w&&!(32===(h=y.charCodeAt(u+1))||h<14&&h>8);u++);for(-1===u&&(v("missing closing quotes"),u=w,l=!0),l||(o=y.substring(m,u)),m=u;u+1<w&&!(32===(h=y.charCodeAt(u+1))||h<14&&h>8);u++)m===u&&(v("illegal character after attribute end"),l=!0);if(m=u+1,!l)if(a in x)v("attribute <"+a+"> already defined");else if(x[a]=!0,f)if(p){if(null!==(r="xmlns"===a?"xmlns":120===a.charCodeAt(0)&&"xmlns:"===a.substr(0,6)?a.substr(6):null)){if(e=me(o),t=_e(r),!(s=c[e])){if("xmlns"===r||t in A&&A[t]!==e)do{s="ns"+R++}while(void 0!==A[s]);else s=r;c[e]=s}A[r]!==s&&(i||(A=ke(A),i=!0),A[r]=s,"xmlns"===r&&(A[_e(s)]=e,d=s),A[t]=e),b[a]=o;continue}g.push(a,o)}else-1!==(h=a.indexOf(":"))?(n=A[a.substring(0,h)])?((a=d===n?a.substr(h+1):n+a.substr(h))===ye&&(-1!==(h=o.indexOf(":"))?(n=o.substring(0,h),o=(n=A[n]||n)+o.substring(h)):o=d+":"+o),b[a]=o):v(be(a.substring(0,h))):b[a]=o;else b[a]=o}if(p)for(m=0,w=g.length;m<w;m++){if(a=g[m++],o=g[m],-1!==(h=a.indexOf(":"))){if(!(n=A[a.substring(0,h)])){v(be(a.substring(0,h)));continue}(a=d===n?a.substr(h+1):n+a.substr(h))===ye&&(-1!==(h=o.indexOf(":"))?(n=o.substring(0,h),o=(n=A[n]||n)+o.substring(h)):o=d+":"+o)}b[a]=o}return E=b}function I(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,o=0,s=0,a=P;N>=s&&(t=i.exec(e))&&!((a=t[0].length+t.index)>N);)r+=1,s=a;return-1==N?(o=a,n=e.substring(P)):0===P?n=e.substring(P,N):(o=N-s,n=-1==P?e.substring(N):e.substring(N,P+1)),{data:n,line:r,column:o}}d=I,h&&(C=Object.create({},{name:xe((function(){return _})),originalName:xe((function(){return S})),attrs:xe(L),ns:xe((function(){return A}))}));for(;-1!==P;){if(-1===(N=60===e.charCodeAt(P)?P:e.indexOf("<",P)))return D.length?y("unexpected end of file"):0===P?y("missing start tag"):void(P<e.length&&e.substring(P).trim()&&v(ve));if(P!==N)if(D.length){if(t&&(t(e.substring(P,N),me,d),m))return}else if(e.substring(P,N).trim()&&(v(ve),m))return;if(33===(b=e.charCodeAt(N+1))){if(91===(w=e.charCodeAt(N+2))&&"CDATA["===e.substr(N+3,6)){if(-1===(P=e.indexOf("]]>",N)))return y("unclosed cdata");if(r&&(r(e.substring(N+9,P),d),m))return;P+=3;continue}if(45===w&&45===e.charCodeAt(N+3)){if(-1===(P=e.indexOf("--\x3e",N)))return y("unclosed comment");if(s&&(s(e.substring(N+4,P),me,d),m))return;P+=3;continue}}if(63!==b){for(u=N+1;;u++){if(x=e.charCodeAt(u),isNaN(x))return P=-1,y("unclosed tag");if(34===x)u=-1!==(w=e.indexOf('"',u+1))?w:u;else if(39===x)u=-1!==(w=e.indexOf("'",u+1))?w:u;else if(62===x){P=u;break}}if(33!==b){if(E={},47===b){if(O=!1,T=!0,!D.length)return y("missing open tag");if(u=_=D.pop(),w=N+2+u.length,e.substring(N+2,w)!==u)return y("closing tag mismatch");for(;w<P;w++)if(!(32===(b=e.charCodeAt(w))||b>8&&b<14))return y("close tag")}else{if(47===e.charCodeAt(P-1)?(u=_=e.substring(N+1,P-1),O=!0,T=!0):(u=_=e.substring(N+1,P),O=!0,T=!1),!(b>96&&b<123||b>64&&b<91||95===b||58===b))return y("illegal first char nodeName");for(w=1,g=u.length;w<g;w++)if(!((b=u.charCodeAt(w))>96&&b<123||b>64&&b<91||b>47&&b<59||45===b||95===b||46==b)){if(32===b||b<14&&b>8){_=u.substring(0,w),E=null;break}return y("invalid nodeName")}T||D.push(_)}if(f){if(o=A,O&&(T||M.push(o),null===E&&(p=-1!==u.indexOf("xmlns",w))&&(B=w,q=u,L(),p=!1)),S=_,-1!==(b=_.indexOf(":"))){if(!(k=A[_.substring(0,b)]))return y("missing namespace on <"+S+">");_=_.substr(b+1)}else k=A.xmlns;k&&(_=k+":"+_)}if(O&&(B=w,q=u,n&&(h?n(C,me,T,d):n(_,L,me,T,d),m)))return;if(T){if(i&&(i(h?C:_,me,O,d),m))return;f&&(A=O?o:M.pop())}P+=1}else{if(l&&(l(e.substring(N,P+1),me,d),m))return;P+=1}}else{if(-1===(P=e.indexOf("?>",N)))return y("unclosed question");if(a&&(a(e.substring(N,P+2),d),m))return;P+=2}}}(e),d=Se,m=!1,g},this.stop=function(){m=!0}}function Me(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var Ae={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},De="xsi:type";function Re(e){return e.xml&&e.xml.serialize}function Oe(e){return Re(e)===De}function Te(e,t){return Me(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function Ne(e){return new Error(e)}function Pe(e){return e.$descriptor}function qe(e){he(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw Ne("expected element");var t,n=this.elementsById,i=Pe(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw Ne("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function Be(){}function Le(){}function Ie(){}function Fe(e,t){this.property=e,this.context=t}function je(e,t){this.element=t,this.propertyDesc=e}function Ve(){}function $e(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function ze(e,t,n){$e.call(this,e,t,n)}function He(e,t,n){this.model=e,this.context=n}function We(e){e instanceof J&&(e={model:e}),he(this,{lax:!1},e)}Be.prototype.handleEnd=function(){},Be.prototype.handleText=function(){},Be.prototype.handleNode=function(){},Le.prototype=Object.create(Be.prototype),Le.prototype.handleNode=function(){return this},Ie.prototype=Object.create(Be.prototype),Ie.prototype.handleText=function(e){this.body=(this.body||"")+e},Fe.prototype=Object.create(Ie.prototype),Fe.prototype.handleNode=function(e){if(this.element)throw Ne("expected no sub nodes");return this.element=this.createReference(e),this},Fe.prototype.handleEnd=function(){this.element.id=this.body},Fe.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},je.prototype=Object.create(Ie.prototype),je.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=$(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},Ve.prototype=Object.create(Ie.prototype),Ve.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},$e.prototype=Object.create(Ve.prototype),$e.prototype.addReference=function(e){this.context.addReference(e)},$e.prototype.handleText=function(e){if(!Pe(this.element).bodyProperty)throw Ne("unexpected body text <"+e+">");Ie.prototype.handleText.call(this,e)},$e.prototype.handleEnd=function(){var e=this.body,t=this.element,n=Pe(t).bodyProperty;n&&void 0!==e&&(e=$(n.type,e),t.set(n.name,e))},$e.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=Pe(i),o=this.context,s=new i({}),a=this.model;return oe(n,(function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?oe(e.split(" "),(function(e){o.addReference({element:s,property:i.ns.name,id:e})})):o.addReference({element:s,property:i.ns.name,id:e}):(i?e=$(i.type,e):"xmlns"!==n&&(t=W(n,r.ns.prefix),a.getPackage(t.prefix)&&o.addWarning({message:"unknown attribute <"+n+">",element:s,property:n,value:e})),s.set(n,e))})),s},$e.prototype.getPropertyForNode=function(e){var t,n,i=W(e.name),r=this.type,o=this.model,s=Pe(r),a=i.name,l=s.propertiesByName[a];if(l&&!l.isAttr)return Oe(l)&&(t=e.attributes[De])?(t=function(e,t){var n=W(e);return function(e,t){var n=e.name,i=e.localName,r=t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(n,t.getPackage(n.prefix))}(t,o),he({},l,{effectiveType:Pe(n=o.getType(t)).name})):l;var c=o.getPackage(i.prefix);if(c){if(t=Te(i,c),n=o.getType(t),l=ie(s.properties,(function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)})))return he({},l,{effectiveType:Pe(n).name})}else if(l=ie(s.properties,(function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type})))return l;throw Ne("unrecognized element <"+i.name+">")},$e.prototype.toString=function(){return"ElementDescriptor["+Pe(this.type).name+"]"},$e.prototype.valueHandler=function(e,t){return new je(e,t)},$e.prototype.referenceHandler=function(e){return new Fe(e,this.context)},$e.prototype.handler=function(e){return"Element"===e?new He(this.model,e,this.context):new $e(this.model,e,this.context)},$e.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,H(n=t.effectiveType||t.type))return this.valueHandler(t,i);var o=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==o&&(t.isMany?i.get(t.name).push(o):i.set(t.name,o),t.isReference?(he(o,{element:i}),this.context.addReference(o)):o.$parent=i),r},ze.prototype=Object.create($e.prototype),ze.prototype.createElement=function(e){var t=e.name,n=W(t),i=this.model,r=this.type,o=i.getPackage(n.prefix),s=o&&Te(n,o)||t;if(!r.hasType(s))throw Ne("unexpected element <"+e.originalName+">");return $e.prototype.createElement.call(this,e)},He.prototype=Object.create(Ve.prototype),He.prototype.createElement=function(e){var t=e.name,n=W(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},He.prototype.handleChild=function(e){var t=new He(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},He.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},We.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof $e?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,o=this.lax,s=new qe(he({},t,{rootHandler:i})),a=new Ee({proxy:!0}),l=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function c(e,t,n){var i=t(),r=i.line,o=i.column,a=i.data;"<"===a.charAt(0)&&-1!==a.indexOf(" ")&&(a=a.slice(0,a.indexOf(" "))+">");var l="unparsable content "+(a?a+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+o+"\n\tnested error: "+e.message;if(n)return s.addWarning({message:l,error:e}),!0;throw Ne(l)}function h(e,t){return c(e,t,!0)}i.context=s,l.push(i);var u=/^<\?xml /i,d=/ encoding="([^"]+)"/i,p=/^utf-8$/i;function f(e,t){try{l.peek().handleText(e)}catch(e){h(e,t)}}var g=r.getPackages().reduce((function(e,t){return e[t.uri]=t.prefix,e}),{"http://www.w3.org/XML/1998/namespace":"xml"});return a.ns(g).on("openTag",(function(e,t,n,i){var r=e.attrs||{},s=Object.keys(r).reduce((function(e,n){var i=t(r[n]);return e[n]=i,e}),{});!function(e,t){var n=l.peek();try{l.push(n.handleNode(e))}catch(e){c(e,t,o)&&l.push(new Le)}}({name:e.name,originalName:e.originalName,attributes:s,ns:e.ns},i)})).on("question",(function(e){if(u.test(e)){var t=d.exec(e),n=t&&t[1];n&&!p.test(n)&&s.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}})).on("closeTag",(function(){l.pop().handleEnd()})).on("cdata",f).on("text",(function(e,t,n){!function(e,t){e.trim()&&f(e,t)}(t(e),n)})).on("error",c).on("warn",h),new Promise((function(t,n){var r;try{a.parse(e),function(){var e,t,n=s.elementsById,i=s.references;for(e=0;t=i[e];e++){var r=t.element,o=n[t.id],a=Pe(r).propertiesByName[t.property];if(o||s.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),a.isMany){var l=r.get(a.name),c=l.indexOf(t);-1===c&&(c=l.length),o?l[c]=o:l.splice(c,1)}else r.set(a.name,o)}}()}catch(e){r=e}var o=i.element;r||o||(r=Ne("failed to parse document as <"+i.type.$descriptor.name+">"));var l=s.warnings,c=s.references,h=s.elementsById;return r?(r.warnings=l,n(r)):t({rootElement:o,elementsById:h,references:c,warnings:l})}))},We.prototype.handler=function(e){return new ze(this.model,e)};var Ue=/<|>|'|"|&|\n\r|\n/g,Ge=/<|>|&/g;function Ke(e){var t={},n={},i={},r=[],o=[];this.byUri=function(t){return n[t]||e&&e.byUri(t)},this.add=function(e,t){n[e.uri]=e,t?r.push(e):o.push(e),this.mapPrefix(e.prefix,e.uri)},this.uriByPrefix=function(e){return t[e||"xmlns"]},this.mapPrefix=function(e,n){t[e||"xmlns"]=n},this.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},this.logUsed=function(t){var n=t.uri,r=this.getNSKey(t);i[r]=this.byUri(n),e&&e.logUsed(t)},this.getUsed=function(e){var t=this;return[].concat(r,o).filter((function(e){var n=t.getNSKey(e);return i[n]}))}}function Xe(e,t){return Me(t)?function(e){return e.charAt(0).toLowerCase()+e.slice(1)}(e):e}function Ye(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function Je(e){return te(e)?e:(e.prefix?e.prefix+":":"")+e.localName}var Qe={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},Ze={"<":"lt",">":"gt","&":"amp"};function et(e,t,n){return(e=te(e)?e:""+e).replace(t,(function(e){return"&"+n[e]+";"}))}function tt(e){this.tagName=e}function nt(){}function it(e){this.tagName=e}function rt(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function ot(e,t){rt.call(this,e,t)}function st(){this.value="",this.write=function(e){this.value+=e}}function at(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function lt(e){return e=he({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new st,r=new at(i,e.format);if(e.preamble&&r.append('<?xml version="1.0" encoding="UTF-8"?>\n'),(new rt).build(t).serializeTo(r),!n)return i.value}}}function ct(e,t){J.call(this,e,t)}tt.prototype.build=function(e){return this.element=e,this},tt.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},nt.prototype.serializeValue=nt.prototype.serializeTo=function(e){e.append(this.escape?et(this.value,Ge,Ze):this.value)},nt.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(Ge)&&(this.escape=!0),this},Ye(it,nt),it.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},rt.prototype.build=function(e){this.element=e;var t,n,i=e.$descriptor,r=this.propertyDescriptor,o=i.isGeneric;return t=o?this.parseGeneric(e):this.parseNsAttributes(e),this.ns=r?this.nsPropertyTagName(r):this.nsTagName(i),this.tagName=this.addTagName(this.ns),o||(n=function(e){return re(e.$descriptor.properties,(function(t){var n=t.name;if(t.isVirtual)return!1;if(!ne(e,n))return!1;var i=e[n];return i!==t.default&&null!==i&&(!t.isMany||i.length)}))}(e),this.parseAttributes(re(n,(function(e){return e.isAttr}))),this.parseContainments(function(e){return re(e,(function(e){return!e.isAttr}))}(n))),this.parseGenericAttributes(e,t),this},rt.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?he({localName:t.ns.localName},e):he({localName:Xe(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},rt.prototype.nsPropertyTagName=function(e){return function(e,t){return he({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},rt.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},rt.prototype.nsAttributeName=function(e){var t;if(t=te(e)?W(e):e.ns,e.inherited)return{localName:t.localName};var n=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(n),this.isLocalNs(n)?{localName:t.localName}:he({localName:t.localName},n)},rt.prototype.parseGeneric=function(e){var t=this,n=this.body,i=[];return oe(e,(function(r,o){"$body"===o?n.push((new nt).build({type:"String"},r)):"$children"===o?oe(r,(function(e){n.push(new rt(t).build(e))})):0!==o.indexOf("$")&&t.parseNsAttribute(e,o,r)&&i.push({name:o,value:r})})),i},rt.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,o=W(t);if("xmlns"===o.prefix&&(i={prefix:o.localName,uri:n}),o.prefix||"xmlns"!==o.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var s=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(s)}},rt.prototype.parseNsAttributes=function(e,t){var n=this,i=e.$attrs,r=[];return oe(i,(function(t,i){var o=n.parseNsAttribute(e,i,t);o&&r.push(o)})),r},rt.prototype.parseGenericAttributes=function(e,t){var n=this;oe(t,(function(t){if(t.name!==De)try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){console.warn("missing namespace information for ",t.name,"=",t.value,"on",e,n)}}))},rt.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;oe(e,(function(e){var r=i.get(e.name),o=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new nt).build(e,r[0]));else if(H(e.type))oe(r,(function(i){n.push(new it(t.addTagName(t.nsPropertyTagName(e))).build(e,i))}));else if(o)oe(r,(function(i){n.push(new tt(t.addTagName(t.nsPropertyTagName(e))).build(i))}));else{var s=Oe(e),a=function(e){return"property"===Re(e)}(e);oe(r,(function(i){var r;r=s?new ot(t,e):a?new rt(t,e):new rt(t),n.push(r.build(i))}))}}))},rt.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new Ke(t):n=t),n},rt.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,o=e.prefix;return i.byUri(r)&&!n||i.add(e,t),i.mapPrefix(o,r),e},rt.prototype.logNamespaceUsed=function(e,t){var n,i,r,o=this.element.$model,s=this.getNamespaces(t),a=e.prefix,l=e.uri;if(!a&&!l)return{localName:e.localName};if(r=Ae[a]||o&&(o.getPackage(a)||{}).uri,!(l=l||r||s.uriByPrefix(a)))throw new Error("no namespace uri given for prefix <"+a+">");if(!(e=s.byUri(l))){for(n=a,i=1;s.uriByPrefix(n);)n=a+"_"+i++;e=this.logNamespace({prefix:n,uri:l},r===l)}return a&&s.mapPrefix(a,l),e},rt.prototype.parseAttributes=function(e){var t=this,n=this.element;oe(e,(function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];oe(i,(function(e){r.push(e.id)})),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)}))},rt.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),Je(e)},rt.prototype.addAttribute=function(e,t){var n=this.attrs;te(t)&&(t=et(t,Ue,Qe));var i=function(e,t){t=se(t);var n=ee(e)?-1:void 0;return oe(e,(function(e,i){if(t(e,i))return n=i,!1})),n}(n,(function(t){return t.name.localName===e.localName&&t.name.uri===e.uri&&t.name.prefix===e.prefix})),r={name:e,value:t};-1!==i?n.splice(i,1,r):n.push(r)},rt.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=function(e){return e.getUsed().filter((function(e){return"xml"!==e.prefix})).map((function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}}))}(n).concat(t)),oe(t,(function(t){e.append(" ").append(Je(t.name)).append('="').append(t.value).append('"')}))},rt.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==nt;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),oe(this.body,(function(t){t.serializeTo(e)})),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},Ye(ot,rt),ot.prototype.parseNsAttributes=function(e){var t=rt.prototype.parseNsAttributes.call(this,e),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),o=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(De),(i.prefix?i.prefix+":":"")+o+n.ns.localName),t},ot.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},ct.prototype=Object.create(J.prototype),ct.prototype.fromXML=function(e,t,n){var i;i=t,"[object String]"!==C.call(i)&&(n=t,t="dmn:Definitions");var r=new We(M({model:this,lax:!0},n)),o=r.handler(t);return r.fromXML(e,o)},ct.prototype.toXML=function(e,t){var n=new lt(t);return new Promise((function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}}))};var ht={dc:{name:"DC",prefix:"dc",uri:"http://www.omg.org/spec/DMN/20180521/DC/",types:[{name:"Dimension",properties:[{name:"width",isAttr:!0,type:"Real"},{name:"height",isAttr:!0,type:"Real"}]},{name:"Bounds",properties:[{name:"height",isAttr:!0,type:"Real"},{name:"width",isAttr:!0,type:"Real"},{name:"x",isAttr:!0,type:"Real"},{name:"y",isAttr:!0,type:"Real"}]},{name:"Point",properties:[{name:"x",isAttr:!0,type:"Real"},{name:"y",isAttr:!0,type:"Real"}]},{name:"Color",properties:[{name:"red",type:"UML_Standard_Profile.mdzip:eee_1045467100323_917313_65"},{name:"green",type:"UML_Standard_Profile.mdzip:eee_1045467100323_917313_65"},{name:"blue",type:"UML_Standard_Profile.mdzip:eee_1045467100323_917313_65"}]}],associations:[],enumerations:[{name:"AlignmentKind",literalValues:[{name:"start"},{name:"center"},{name:"end"}]}]},di:{name:"DI",prefix:"di",uri:"http://www.omg.org/spec/DMN/20180521/DI/",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"extension",type:"Extension"},{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"style",isReference:!0,type:"Style",xml:{serialize:"property"}},{name:"sharedStyle",isReference:!0,isVirtual:!0,type:"Style"}]},{name:"Diagram",superClass:["DiagramElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"}]},{name:"Shape",isAbstract:!0,properties:[{name:"bounds",type:"dc:Bounds"}],superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,properties:[{name:"waypoint",type:"dc:Point",isMany:!0,xml:{serialize:"property"}}],superClass:["DiagramElement"]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],enumerations:[],xml:{tagAlias:"lowerCase"}},dmn:{name:"DMN",prefix:"dmn",uri:"https://www.omg.org/spec/DMN/20191111/MODEL/",types:[{name:"AuthorityRequirement",superClass:["DMNElement"],properties:[{name:"requiredAuthority",type:"DMNElementReference",xml:{serialize:"property"}},{name:"requiredDecision",type:"DMNElementReference",xml:{serialize:"property"}},{name:"requiredInput",type:"DMNElementReference",xml:{serialize:"property"}}]},{name:"ItemDefinition",superClass:["NamedElement"],properties:[{name:"typeRef",type:"String"},{name:"allowedValues",type:"UnaryTests",xml:{serialize:"property"}},{name:"typeLanguage",type:"String",isAttr:!0},{name:"itemComponent",type:"ItemDefinition",isMany:!0,xml:{serialize:"property"}},{name:"functionItem",type:"FunctionItem"},{name:"isCollection",isAttr:!0,type:"Boolean"}]},{name:"Definitions",superClass:["NamedElement"],properties:[{name:"import",type:"Import",isMany:!0},{name:"itemDefinition",type:"ItemDefinition",isMany:!0},{name:"drgElement",type:"DRGElement",isMany:!0},{name:"artifact",type:"Artifact",isMany:!0},{name:"elementCollection",type:"ElementCollection",isMany:!0},{name:"businessContextElement",type:"BusinessContextElement",isMany:!0},{name:"namespace",type:"String",isAttr:!0},{name:"expressionLanguage",type:"String",isAttr:!0},{name:"typeLanguage",type:"String",isAttr:!0},{name:"exporter",isAttr:!0,type:"String"},{name:"exporterVersion",isAttr:!0,type:"String"},{name:"dmnDI",type:"dmndi:DMNDI"}]},{name:"KnowledgeSource",superClass:["DRGElement"],properties:[{name:"authorityRequirement",type:"AuthorityRequirement",isMany:!0},{name:"type",type:"String"},{name:"owner",type:"DMNElementReference",xml:{serialize:"property"}},{name:"locationURI",type:"String",isAttr:!0}]},{name:"DecisionRule",superClass:["DMNElement"],properties:[{name:"inputEntry",type:"UnaryTests",isMany:!0,xml:{serialize:"property"}},{name:"outputEntry",type:"LiteralExpression",isMany:!0,xml:{serialize:"property"}},{name:"annotationEntry",type:"RuleAnnotation",isMany:!0,xml:{serialize:"property"}}]},{name:"Expression",isAbstract:!0,superClass:["DMNElement"],properties:[{name:"typeRef",isAttr:!0,type:"String"}]},{name:"InformationItem",superClass:["NamedElement"],properties:[{name:"typeRef",isAttr:!0,type:"String"}]},{name:"Decision",superClass:["DRGElement"],properties:[{name:"question",type:"String",xml:{serialize:"property"}},{name:"allowedAnswers",type:"String",xml:{serialize:"property"}},{name:"variable",type:"InformationItem",xml:{serialize:"property"}},{name:"informationRequirement",type:"InformationRequirement",isMany:!0},{name:"knowledgeRequirement",type:"KnowledgeRequirement",isMany:!0},{name:"authorityRequirement",type:"AuthorityRequirement",isMany:!0},{name:"supportedObjective",isMany:!0,type:"DMNElementReference",xml:{serialize:"property"}},{name:"impactedPerformanceIndicator",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"decisionMaker",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"decisionOwner",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"usingProcess",isMany:!0,type:"DMNElementReference",xml:{serialize:"property"}},{name:"usingTask",isMany:!0,type:"DMNElementReference",xml:{serialize:"property"}},{name:"decisionLogic",type:"Expression"}]},{name:"Invocation",superClass:["Expression"],properties:[{name:"calledFunction",type:"Expression"},{name:"binding",type:"Binding",isMany:!0}]},{name:"OrganisationalUnit",superClass:["BusinessContextElement"],properties:[{name:"decisionMade",type:"Decision",isReference:!0,isMany:!0},{name:"decisionOwned",type:"Decision",isReference:!0,isMany:!0}]},{name:"Import",superClass:["NamedElement"],properties:[{name:"importType",type:"String",isAttr:!0},{name:"locationURI",type:"String",isAttr:!0},{name:"namespace",type:"String",isAttr:!0}]},{name:"InformationRequirement",superClass:["DMNElement"],properties:[{name:"requiredDecision",type:"DMNElementReference",xml:{serialize:"property"}},{name:"requiredInput",type:"DMNElementReference",xml:{serialize:"property"}}]},{name:"ElementCollection",superClass:["NamedElement"],properties:[{name:"drgElement",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}}]},{name:"DRGElement",isAbstract:!0,superClass:["NamedElement"],properties:[]},{name:"InputData",superClass:["DRGElement"],properties:[{name:"variable",type:"InformationItem",xml:{serialize:"property"}}]},{name:"DMNElement",isAbstract:!0,properties:[{name:"description",type:"String"},{name:"extensionElements",type:"ExtensionElements"},{name:"id",type:"String",isAttr:!0,isId:!0},{name:"extensionAttribute",type:"ExtensionAttribute",isMany:!0},{name:"label",isAttr:!0,type:"String"}]},{name:"InputClause",superClass:["DMNElement"],properties:[{name:"inputExpression",type:"LiteralExpression",xml:{serialize:"property"}},{name:"inputValues",type:"UnaryTests",xml:{serialize:"property"}}]},{name:"DecisionTable",superClass:["Expression"],properties:[{name:"input",type:"InputClause",isMany:!0,xml:{serialize:"property"}},{name:"output",type:"OutputClause",isMany:!0,xml:{serialize:"property"}},{name:"annotation",type:"RuleAnnotationClause",isMany:!0,xml:{serialize:"property"}},{name:"rule",type:"DecisionRule",isMany:!0,xml:{serialize:"property"}},{name:"hitPolicy",type:"HitPolicy",isAttr:!0,default:"UNIQUE"},{name:"aggregation",type:"BuiltinAggregator",isAttr:!0},{name:"preferredOrientation",type:"DecisionTableOrientation",isAttr:!0},{name:"outputLabel",isAttr:!0,type:"String"}]},{name:"LiteralExpression",superClass:["Expression"],properties:[{name:"expressionLanguage",type:"String",isAttr:!0},{name:"text",type:"String"},{name:"importedValues",type:"ImportedValues"}]},{name:"Binding",properties:[{name:"parameter",type:"InformationItem",xml:{serialize:"property"}},{name:"bindingFormula",type:"Expression"}]},{name:"KnowledgeRequirement",superClass:["DMNElement"],properties:[{name:"requiredKnowledge",type:"DMNElementReference",xml:{serialize:"property"}}]},{name:"BusinessKnowledgeModel",superClass:["Invocable"],properties:[{name:"encapsulatedLogic",type:"FunctionDefinition",xml:{serialize:"property"}},{name:"knowledgeRequirement",type:"KnowledgeRequirement",isMany:!0},{name:"authorityRequirement",type:"AuthorityRequirement",isMany:!0}]},{name:"BusinessContextElement",isAbstract:!0,superClass:["NamedElement"],properties:[{name:"URI",type:"String",isAttr:!0}]},{name:"PerformanceIndicator",superClass:["BusinessContextElement"],properties:[{name:"impactingDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}}]},{name:"FunctionDefinition",superClass:["Expression"],properties:[{name:"formalParameter",type:"InformationItem",isMany:!0,xml:{serialize:"property"}},{name:"body",type:"Expression"},{name:"kind",type:"FunctionKind",isAttr:!0}]},{name:"Context",superClass:["Expression"],properties:[{name:"contextEntry",type:"ContextEntry",isMany:!0}]},{name:"ContextEntry",superClass:["DMNElement"],properties:[{name:"variable",type:"InformationItem",xml:{serialize:"property"}},{name:"value",type:"Expression"}]},{name:"List",superClass:["Expression"],properties:[{name:"elements",isMany:!0,type:"Expression"}]},{name:"Relation",superClass:["Expression"],properties:[{name:"column",type:"InformationItem",isMany:!0,xml:{serialize:"property"}},{name:"row",type:"List",isMany:!0,xml:{serialize:"property"}}]},{name:"OutputClause",superClass:["DMNElement"],properties:[{name:"outputValues",type:"UnaryTests",xml:{serialize:"property"}},{name:"defaultOutputEntry",type:"LiteralExpression",xml:{serialize:"property"}},{name:"name",isAttr:!0,type:"String"},{name:"typeRef",isAttr:!0,type:"String"}]},{name:"UnaryTests",superClass:["Expression"],properties:[{name:"text",type:"String"},{name:"expressionLanguage",type:"String",isAttr:!0}]},{name:"NamedElement",isAbstract:!0,superClass:["DMNElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ImportedValues",superClass:["Import"],properties:[{name:"importedElement",type:"String"},{name:"expressionLanguage",type:"String",isAttr:!0}]},{name:"DecisionService",superClass:["Invocable"],properties:[{name:"outputDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"encapsulatedDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"inputDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"inputData",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}}]},{name:"ExtensionElements",properties:[{name:"values",type:"Element",isMany:!0}]},{name:"ExtensionAttribute",properties:[{name:"value",type:"Element"},{name:"valueRef",type:"Element",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Element",isAbstract:!0,properties:[{name:"extensionAttribute",type:"ExtensionAttribute",isAttr:!0,isReference:!0},{name:"elements",type:"ExtensionElements",isAttr:!0,isReference:!0}]},{name:"Artifact",isAbstract:!0,superClass:["DMNElement"],properties:[]},{name:"Association",superClass:["Artifact"],properties:[{name:"sourceRef",type:"DMNElementReference",xml:{serialize:"property"}},{name:"targetRef",type:"DMNElementReference",xml:{serialize:"property"}},{name:"associationDirection",type:"AssociationDirection",isAttr:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",isAttr:!0,type:"String",default:"text/plain"}]},{name:"RuleAnnotationClause",properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"RuleAnnotation",properties:[{name:"text",type:"String"}]},{name:"Invocable",isAbstract:!0,superClass:["DRGElement"],properties:[{name:"variable",type:"InformationItem",xml:{serialize:"property"}}]},{name:"Group",superClass:["Artifact"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"FunctionItem",superClass:["DMNElement"],properties:[{name:"parameters",isMany:!0,type:"InformationItem",xml:{serialize:"property"}},{name:"outputTypeRef",isAttr:!0,type:"String"}]},{name:"DMNElementReference",properties:[{isAttr:!0,name:"href",type:"String"}]}],enumerations:[{name:"HitPolicy",literalValues:[{name:"UNIQUE"},{name:"FIRST"},{name:"PRIORITY"},{name:"ANY"},{name:"COLLECT"},{name:"RULE ORDER"},{name:"OUTPUT ORDER"}]},{name:"BuiltinAggregator",literalValues:[{name:"SUM"},{name:"COUNT"},{name:"MIN"},{name:"MAX"}]},{name:"DecisionTableOrientation",literalValues:[{name:"Rule-as-Row"},{name:"Rule-as-Column"},{name:"CrossTable"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"FunctionKind",literalValues:[{name:"FEEL"},{name:"Java"},{name:"PMML"}]}],associations:[],xml:{tagAlias:"lowerCase"}},dmndi:{name:"DMNDI",prefix:"dmndi",uri:"https://www.omg.org/spec/DMN/20191111/DMNDI/",types:[{name:"DMNDI",properties:[{name:"diagrams",type:"DMNDiagram",isMany:!0},{name:"styles",type:"DMNStyle",isMany:!0}]},{name:"DMNStyle",superClass:["di:Style"],properties:[{name:"fillColor",type:"dc:Color",isAttr:!0},{name:"strokeColor",type:"dc:Color",isAttr:!0},{name:"fontColor",type:"dc:Color",isAttr:!0},{name:"fontSize",isAttr:!0,type:"Real"},{name:"fontFamily",isAttr:!0,type:"String"},{name:"fontItalic",isAttr:!0,type:"Boolean"},{name:"fontBold",isAttr:!0,type:"Boolean"},{name:"fontUnderline",isAttr:!0,type:"Boolean"},{name:"fontStrikeThrough",isAttr:!0,type:"Boolean"},{name:"labelHorizontalAlignment",type:"dc:AlignmentKind",isAttr:!0},{name:"labelVerticalAlignment",type:"dc:AlignmentKind",isAttr:!0}]},{name:"DMNDiagram",superClass:["di:Diagram"],properties:[{name:"dmnElementRef",type:"dmn:DMNElement",isAttr:!0,isReference:!0},{name:"size",type:"Size"},{name:"localStyle",type:"DMNStyle",isVirtual:!0},{name:"sharedStyle",type:"DMNStyle",isVirtual:!0,isReference:!0,redefines:"di:DiagramElement#sharedStyle"},{name:"diagramElements",type:"DMNDiagramElement",isMany:!0}]},{name:"DMNDiagramElement",isAbstract:!0,superClass:["di:DiagramElement"],properties:[{name:"dmnElementRef",type:"dmn:DMNElement",isAttr:!0,isReference:!0},{name:"sharedStyle",type:"DMNStyle",isVirtual:!0,isReference:!0,redefines:"di:DiagramElement#sharedStyle"},{name:"localStyle",type:"DMNStyle",isVirtual:!0},{name:"label",type:"DMNLabel"}]},{name:"DMNLabel",superClass:["di:Shape"],properties:[{name:"text",type:"Text"}]},{name:"DMNShape",superClass:["di:Shape","DMNDiagramElement"],properties:[{name:"isListedInputData",isAttr:!0,type:"Boolean"},{name:"decisionServiceDividerLine",type:"DMNDecisionServiceDividerLine"},{name:"isCollapsed",isAttr:!0,type:"Boolean"}]},{name:"DMNEdge",superClass:["di:Edge","DMNDiagramElement"],properties:[{name:"sourceElement",type:"DMNDiagramElement",isAttr:!0,isReference:!0},{name:"targetElement",type:"DMNDiagramElement",isAttr:!0,isReference:!0}]},{name:"DMNDecisionServiceDividerLine",superClass:["di:Edge"]},{name:"Text",properties:[{name:"text",isBody:!0,type:"String"}]},{name:"Size",superClass:["dc:Dimension"]}],associations:[],enumerations:[]},biodi:{name:"bpmn.io DI for DMN",uri:"http://bpmn.io/schema/dmn/biodi/2.0",prefix:"biodi",xml:{tagAlias:"lowerCase"},types:[{name:"DecisionTable",isAbstract:!0,extends:["dmn:DecisionTable"],properties:[{name:"annotationsWidth",isAttr:!0,type:"Integer"}]},{name:"OutputClause",isAbstract:!0,extends:["dmn:OutputClause"],properties:[{name:"width",isAttr:!0,type:"Integer"}]},{name:"InputClause",isAbstract:!0,extends:["dmn:InputClause"],properties:[{name:"width",isAttr:!0,type:"Integer"}]}]}};function ut(e,t){return new ct(M({},ht,e),t)}function dt(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}const pt=Object.prototype.toString,ft=Object.prototype.hasOwnProperty;function gt(e,t){return ft.call(e,t)}function mt(e,t){let n,i;if(void 0===e)return;const r=function(e){return"[object Array]"===pt.call(e)}(e)?vt:yt;for(let o in e)if(gt(e,o)&&(n=e[o],i=t(n,r(o)),!1===i))return n}function yt(e){return e}function vt(e){return Number(e)}function wt(e,...t){const n=e.style;return mt(t,(function(e){e&&mt(e,(function(e,t){n[t]=e}))})),e}function bt(e,t,n){return 2==arguments.length?e.getAttribute(t):null===n?e.removeAttribute(t):(e.setAttribute(t,n),e)}const xt=Object.prototype.toString;function kt(e){return new _t(e)}function _t(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}function St(e){for(var t;t=e.firstChild;)e.removeChild(t);return e}_t.prototype.add=function(e){return this.list.add(e),this},_t.prototype.remove=function(e){return"[object RegExp]"==xt.call(e)?this.removeMatching(e):(this.list.remove(e),this)},_t.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},_t.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},_t.prototype.array=function(){return Array.from(this.list)},_t.prototype.has=_t.prototype.contains=function(e){return this.list.contains(e)};var Ct,Et,Mt,At={};function Dt(){Ct=window.addEventListener?"addEventListener":"attachEvent",Et=window.removeEventListener?"removeEventListener":"detachEvent",Mt="addEventListener"!==Ct?"on":""}var Rt=dt({__proto__:null,bind:At.bind=function(e,t,n,i){return Ct||Dt(),e[Ct](Mt+t,n,i||!1),n},unbind:At.unbind=function(e,t,n,i){return Et||Dt(),e[Et](Mt+t,n,i||!1),n},default:At},[At]),Ot=["focus","blur"];var Tt,Nt={bind:function(e,t,n,i,r){return-1!==Ot.indexOf(n)&&(r=!0),Rt.bind(e,n,(function(n){var r=n.target||n.srcElement;n.delegateTarget=function(e,t,n){var i=n?e:e.parentNode;return i&&"function"==typeof i.closest&&i.closest(t)||null}(r,t,!0),n.delegateTarget&&i.call(e,n)}),r)},unbind:function(e,t,n,i){return-1!==Ot.indexOf(t)&&(i=!0),Rt.unbind(e,t,n,i)}},Pt=function(e,t){if("string"!=typeof e)throw new TypeError("String expected");t||(t=document);var n=/<([\w:]+)/.exec(e);if(!n)return t.createTextNode(e);e=e.replace(/^\s+|\s+$/g,"");var i=n[1];if("body"==i){return(l=t.createElement("html")).innerHTML=e,l.removeChild(l.lastChild)}var r=Object.prototype.hasOwnProperty.call(Bt,i)?Bt[i]:Bt._default,o=r[0],s=r[1],a=r[2],l=t.createElement("div");l.innerHTML=s+e+a;for(;o--;)l=l.lastChild;if(l.firstChild==l.lastChild)return l.removeChild(l.firstChild);var c=t.createDocumentFragment();for(;l.firstChild;)c.appendChild(l.removeChild(l.firstChild));return c},qt=!1;"undefined"!=typeof document&&((Tt=document.createElement("div")).innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',qt=!Tt.getElementsByTagName("link").length,Tt=void 0);var Bt={legend:[1,"<fieldset>","</fieldset>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],_default:qt?[1,"X<div>","</div>"]:[0,"",""]};Bt.td=Bt.th=[3,"<table><tbody><tr>","</tr></tbody></table>"],Bt.option=Bt.optgroup=[1,'<select multiple="multiple">',"</select>"],Bt.thead=Bt.tbody=Bt.colgroup=Bt.caption=Bt.tfoot=[1,"<table>","</table>"],Bt.polyline=Bt.ellipse=Bt.polygon=Bt.circle=Bt.text=Bt.line=Bt.path=Bt.rect=Bt.g=[1,'<svg xmlns="http://www.w3.org/2000/svg" version="1.1">',"</svg>"];var Lt=Pt;function It(e,t){return(t=t||document).querySelector(e)}function Ft(e){e.parentNode&&e.parentNode.removeChild(e)}function jt(e){return function(){if(!window.Promise)throw new Error("Promises is not supported in this environment. Please polyfill Promise.");var t=arguments.length;if(!(t>=1&&s(arguments[t-1])))return e.apply(this,arguments);var n=arguments[t-1];console.warn(new Error("Passing callbacks to "+function(e){return e.replace("bound ","")}(e.name)+" is deprecated and will be removed in a future major release. Please switch to promises: https://bpmn.io/l/moving-to-promises.html"));var i=Array.prototype.slice.call(arguments,0,-1);e.apply(this,i).then((function(e){var t=Object.keys(e)[0];return n(null,e[t])}),(function(e){return n(e,e.warnings)}))}}const Vt={width:"100%",height:"100%",position:"relative"};class $t{constructor(e={}){this._eventBus=new _,this._viewsChanged=v(this._viewsChanged,0),this._views=[],this._viewers={},this.open=jt(this.open.bind(this)),this.importXML=jt(this.importXML.bind(this)),this.saveXML=jt(this.saveXML.bind(this)),this._init(e)}importXML(e,t){var n=this;return t=t||{open:!0},new Promise((function(r,o){var s=n._activeView;n._clear().then((()=>{var a;e=n._emit("import.parse.start",{xml:e})||e,n._moddle.fromXML(e,"dmn:Definitions").then((e=>{var l=e.rootElement,c=e.references,h=e.elementsById;if(a=e.warnings,l=n._emit("import.parse.complete",i({error:null,definitions:l,elementsById:h,references:c,warnings:a}))||l,n._setDefinitions(l),!t.open)return n._emit("import.done",{error:null,warnings:a}),void r({warnings:a});var u=n._getInitialView(n._views,s);if(!u){var d=new Error("no displayable contents");return n._emit("import.done",{error:d,warnings:a}),d.warnings=a,o(d)}n.open(u).then((e=>({warnings:e.warnings}))).catch((e=>({error:e,warnings:e.warnings}))).then((e=>{var t=[].concat(a,e.warnings);n._emit("import.done",{error:e.error,warnings:t}),e.error?(e.error.warnings=t,o(e.error)):r({warnings:t})}))})).catch((t=>(a=t.warnings,t=function(e,t){if("failed to parse document as <dmn:Definitions>"!==e.message)return null;var n=-1!==t.indexOf('"http://www.omg.org/spec/DMN/20151101/dmn.xsd"')?"1.1":-1!==t.indexOf('"http://www.omg.org/spec/DMN/20180521/MODEL/"')&&"1.2";if(!n)return null;return e=new Error("unsupported DMN "+n+" file detected; only DMN 1.3 files can be opened"),console.error("Cannot open what looks like a DMN "+n+" diagram. Please refer to https://bpmn.io/l/dmn-compatibility.html to learn how to make the toolkit compatible with older DMN files",e),e}(t,e)||function(e){var t=/unparsable content <([^>]+)> detected([\s\S]*)$/.exec(e.message);if(!t)return null;return e.message="unparsable content <"+t[1]+"> detected; this may indicate an invalid DMN 1.3 diagram file"+t[2],e}(t)||t,n._emit("import.parse.complete",i({error:t,warnings:a})),n._emit("import.done",{error:t,warnings:a}),t.warnings=a,o(t))))})).catch((e=>(n._emit("import.done",{error:e,warnings:[]}),e.warnings=[],o(e))))}));function i(e){var t=n._eventBus.createEvent(e);return Object.defineProperty(t,"context",{enumerable:!0,get:function(){return console.warn(new Error("import.parse.complete <context> is deprecated and will be removed in future library versions")),{warnings:e.warnings,references:e.references,elementsById:e.elementsById}}}),t}}getDefinitions(){return this._definitions}getActiveView(){return this._activeView}getActiveViewer(){var e=this.getActiveView();return e&&this._getViewer(e)}getView(e){return this._views.filter((function(t){return t.element===e}))[0]}getViews(){return this._views}saveXML(e){var t=this;e=e||{};var n=this._definitions;return new Promise((function(i,r){n?(n=t._emit("saveXML.start",{definitions:n})||n,t._moddle.toXML(n,e).then((function(e){var n=e.xml;return{xml:n=t._emit("saveXML.serialized",{xml:n})||n}})).catch((e=>({error:e}))).then((e=>{t._emit("saveXML.done",e),e.error?r(e.error):i({xml:e.xml})}))):r(new Error("no definitions loaded"))}))}on(...e){this._eventBus.on(...e)}off(...e){this._eventBus.off(...e)}once(...e){this._eventBus.once(...e)}attachTo(e){e.get&&e.constructor.prototype.jquery&&(e=e.get(0)),"string"==typeof e&&(e=It(e)),e.appendChild(this._container),this._emit("attach",{})}detach(){this._emit("detach",{}),Ft(this._container)}destroy(){Object.keys(this._viewers).forEach((e=>{Ut(this._viewers[e],"destroy")})),Ft(this._container)}_init(e){this._options=e,this._moddle=this._createModdle(e),this._viewers={},this._views=[];const t=Lt('<div class="dmn-js-parent"></div>'),n=b({},Vt,e);b(t.style,{width:zt(n.width),height:zt(n.height),position:n.position}),this._container=t,e.container&&this.attachTo(e.container)}_clear(){return this._switchView(null)}open(e){return this._switchView(e)}_setDefinitions(e){this._definitions=e,this._updateViews()}_viewsChanged=()=>{this._emit("views.changed",{views:this._views,activeView:this._activeView})};_updateViews(){var e=this._definitions;if(!e)return this._views=[],void this._switchView(null);var t=this._getViewProviders(),n=[e,...e.drgElement||[]],i=this._views,r=[];for(var o of n){var s=c(t,(function(e){return"string"==typeof e.opens?e.opens===o.$type:e.opens(o)}));if(s){var a={element:o,id:o.id,name:o.name,type:s.id};r.push(a)}}var l,h=this._activeView;if(!h||(l=c(r,(function(e){return Ht(h,e)}))||this._getInitialView(r),l)){var u=!Ht(h,l)||Wt(h,l),d=i.length!==r.length||!p(r,(function(e){return c(i,(function(t){return Ht(t,e)&&!Wt(t,e)}))}));this._activeView=l,this._views=r,(u||d)&&this._viewsChanged()}else this._switchView(null)}_getInitialView(e,t){var n;return t&&(n=c(e,(function(e){return Ht(e,t)}))||c(e,(function(e){return e.type===t}))),n||e[0]}_switchView(e){var t=this;return new Promise((function(n,i){var r,o=(e,r)=>{t._viewsChanged(),e?i(e):n(r)},s=t.getActiveView(),a=e&&t._getViewer(e),l=e&&e.element;if(s&&(r=t._getViewer(s))!==a&&(Ut(r,"clear"),r.detach()),t._activeView=e,a)return r!==a&&a.attachTo(t._container),t._emit("import.render.start",{view:e,element:l}),void a.open(l).then((n=>{t._emit("import.render.complete",{view:e,error:null,warnings:n.warnings}),o(null,n)})).catch((n=>{t._emit("import.render.complete",{view:e,error:n,warnings:n.warnings}),o(n,null)}));o()}))}_getViewer(e){var t=e.type,n=this._viewers[t];return n||(n=this._viewers[t]=this._createViewer(e.type),this._emit("viewer.created",{type:t,viewer:n})),n}_createViewer(e){var t=c(this._getViewProviders(),(function(t){return t.id===e}));if(!t)throw new Error("no provider for view type <"+e+">");var n=t.constructor,i=this._options[e]||{};return new n({...this._options.common||{},...i,additionalModules:[...i.additionalModules||[],{_parent:["value",this],moddle:["value",this._moddle]}]})}_emit(...e){return this._eventBus.fire(...e)}_createModdle(e){return new ut(e.moddleExtensions)}_getViewProviders(){return[]}}function zt(e){return e+(o(e)?"px":"")}function Ht(e,t){return n(e)?!!n(t)&&(e.element===t.element||e.id===t.id):!n(t)}function Wt(e,t){return!e||!t||e.name!==t.name}function Ut(e,t){s(e[t])&&e[t]()}const Gt=/^class[ {]/;function Kt(e){return Array.isArray(e)}function Xt(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Yt(...e){1===e.length&&Kt(e[0])&&(e=e[0]);const t=(e=[...e]).pop();return t.$inject=e,t}const Jt=/constructor\s*[^(]*\(\s*([^)]*)\)/m,Qt=/^(?:async\s+)?(?:function\s*[^(]*)?(?:\(\s*([^)]*)\)|(\w+))/m,Zt=/\/\*([^*]*)\*\//m;function en(e){if("function"!=typeof e)throw new Error(`Cannot annotate "${e}". Expected a function!`);const t=e.toString().match(function(e){return Gt.test(e.toString())}(e)?Jt:Qt);if(!t)return[];const n=t[1]||t[2];return n&&n.split(",").map((e=>{const t=e.match(Zt);return(t&&t[1]||e).trim()}))||[]}function tn(e,t){const n=t||{get:function(e,t){if(i.push(e),!1===t)return null;throw a(`No provider for "${e}"!`)}},i=[],r=this._providers=Object.create(n._providers||null),o=this._instances=Object.create(null),s=o.injector=this,a=function(e){const t=i.join(" -> ");return i.length=0,new Error(t?`${e} (Resolving: ${t})`:e)};function l(e,t){if(!r[e]&&e.includes(".")){const t=e.split(".");let n=l(t.shift());for(;t.length;)n=n[t.shift()];return n}if(Xt(o,e))return o[e];if(Xt(r,e)){if(-1!==i.indexOf(e))throw i.push(e),a("Cannot resolve circular dependency!");return i.push(e),o[e]=r[e][0](r[e][1]),i.pop(),o[e]}return n.get(e,t)}function c(e,t){if(void 0===t&&(t={}),"function"!=typeof e){if(!Kt(e))throw a(`Cannot invoke "${e}". Expected a function!`);e=Yt(e.slice())}return{fn:e,dependencies:(e.$inject||en(e)).map((e=>Xt(t,e)?t[e]:l(e)))}}function h(e){const{fn:t,dependencies:n}=c(e);return new(Function.prototype.bind.call(t,null,...n))}function u(e,t,n){const{fn:i,dependencies:r}=c(e,n);return i.apply(t,r)}function d(e){return Yt((t=>e.get(t)))}function p(e,t){if(t&&t.length){const n=Object.create(null),i=Object.create(null),o=[],s=[],a=[];let l,c,h,u;for(let e in r)l=r[e],-1!==t.indexOf(e)&&("private"===l[2]?(c=o.indexOf(l[3]),-1===c?(h=l[3].createChild([],t),u=d(h),o.push(l[3]),s.push(h),a.push(u),n[e]=[u,e,"private",h]):n[e]=[a[c],e,"private",s[c]]):n[e]=[l[2],l[1]],i[e]=!0),"factory"!==l[2]&&"type"!==l[2]||!l[1].$scope||t.forEach((t=>{-1!==l[1].$scope.indexOf(t)&&(n[e]=[l[2],l[1]],i[t]=!0)}));t.forEach((e=>{if(!i[e])throw new Error('No provider for "'+e+'". Cannot use provider from the parent!')})),e.unshift(n)}return new tn(e,s)}const f={factory:u,type:h,value:function(e){return e}};function g(e,t){const n=e.__init__||[];return function(){n.forEach((e=>{"string"==typeof e?t.get(e):t.invoke(e)}))}}function m(e){const t=e.__exports__;if(t){const n=e.__modules__,i=Object.keys(e).reduce(((t,n)=>("__exports__"!==n&&"__modules__"!==n&&"__init__"!==n&&"__depends__"!==n&&(t[n]=e[n]),t)),Object.create(null)),o=p((n||[]).concat(i)),s=Yt((function(e){return o.get(e)}));t.forEach((function(e){r[e]=[s,e,"private",o]}));const a=(e.__init__||[]).slice();return a.unshift((function(){o.init()})),g(e=Object.assign({},e,{__init__:a}),o)}return Object.keys(e).forEach((function(t){if("__init__"===t||"__depends__"===t)return;const n=e[t];if("private"===n[2])return void(r[t]=n);const i=n[0],o=n[1];r[t]=[f[i],nn(i,o),i]})),g(e,s)}function y(e,t){return-1!==e.indexOf(t)||-1!==(e=(t.__depends__||[]).reduce(y,e)).indexOf(t)?e:e.concat(t)}this.get=l,this.invoke=u,this.instantiate=h,this.createChild=p,this.init=function(e){const t=e.reduce(y,[]).map(m);let n=!1;return function(){n||(n=!0,t.forEach((e=>e())))}}(e)}function nn(e,t){return"value"!==e&&Kt(t)&&(t=Yt(t.slice())),t}function rn(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}var on=1e3;function sn(e,t){var n=this;t=t||on,e.on(["render.shape","render.connection"],t,(function(e,t){var i=e.type,r=t.element,o=t.gfx,s=t.attrs;if(n.canRender(r))return"render.shape"===i?n.drawShape(o,r,s):n.drawConnection(o,r,s)})),e.on(["render.getShapePath","render.getConnectionPath"],t,(function(e,t){if(n.canRender(t))return"render.getShapePath"===e.type?n.getShapePath(t):n.getConnectionPath(t)}))}function an(e,t){return function(e,t){t.appendChild(function(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch(e){}return e}(e,t))}(t,e),e}sn.prototype.canRender=function(e){},sn.prototype.drawShape=function(e,t){},sn.prototype.drawConnection=function(e,t){},sn.prototype.getShapePath=function(e){},sn.prototype.getConnectionPath=function(e){};var ln=2,cn={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":ln,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":ln,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function hn(e,t,n){var i=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),r=cn[i];r?(r===ln&&"number"==typeof n&&(n=String(n)+"px"),e.style[i]=n):e.setAttributeNS(null,t,n)}function un(e,t,n){if("string"==typeof t){if(void 0===n)return function(e,t){return cn[t]?e.style[t]:e.getAttributeNS(null,t)}(e,t);hn(e,t,n)}else!function(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)hn(e,i,t[i])}(e,t);return e}const dn=Object.prototype.toString;function pn(e){return new fn(e)}function fn(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}fn.prototype.add=function(e){return this.list.add(e),this},fn.prototype.remove=function(e){return"[object RegExp]"==dn.call(e)?this.removeMatching(e):(this.list.remove(e),this)},fn.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},fn.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},fn.prototype.array=function(){return Array.from(this.list)},fn.prototype.has=fn.prototype.contains=function(e){return this.list.contains(e)};var gn={svg:"http://www.w3.org/2000/svg"},mn='<svg xmlns="'+gn.svg+'"';function yn(e){var t=!1;"<svg"===e.substring(0,4)?-1===e.indexOf(gn.svg)&&(e=mn+e.substring(4)):(e=mn+">"+e+"</svg>",t=!0);var n=function(e){var t;return(t=new DOMParser).async=!1,t.parseFromString(e,"text/xml")}(e);if(!t)return n;for(var i=document.createDocumentFragment(),r=n.firstChild;r.firstChild;)i.appendChild(r.firstChild);return i}function vn(e,t){var n;return"<"===(e=e.trim()).charAt(0)?(n=yn(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(gn.svg,e),t&&un(n,t),n}var wn=null;function bn(){return null===wn&&(wn=vn("svg")),wn}function xn(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)e[i]=t[i];return e}var kn=/([&<>]{1})/g,_n=/([&<>\n\r"]{1})/g,Sn={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"'"};function Cn(e,t){return e.replace(t,(function(e,t){return Sn[t]||t}))}function En(e,t){var n,i,r,o,s;switch(e.nodeType){case 3:t.push(Cn(e.textContent,kn));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(n=0,i=(r=e.attributes).length;n<i;++n)o=r.item(n),t.push(" ",o.name,'="',Cn(o.value,_n),'"');if(e.hasChildNodes()){for(t.push(">"),n=0,i=(s=e.childNodes).length;n<i;++n)En(s.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("\x3c!--",Cn(e.nodeValue,kn),"--\x3e");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function Mn(e,t){return function(e){for(var t=e.firstChild,n=[];t;)En(t,n),t=t.nextSibling;return n.join("")}(e)}function An(e){var t=e.parentNode;return t&&t.removeChild(e),e}function Dn(e,t){return t instanceof SVGMatrix?e.createSVGTransformFromMatrix(t):t}function Rn(e,t){var n=e.transform.baseVal;return t&&(Array.isArray(t)||(t=[t]),function(e,t){var n,i;for(e.clear(),n=0;i=t[n];n++)e.appendItem(Dn(e,i))}(n,t)),n.consolidate()}function On(e){return e.flat().join(",").replace(/,?([A-z]),?/g,"$1")}function Tn(e){return["L",e.x,e.y]}function Nn(e,t){const n=e.length,i=[(r=e[0],["M",r.x,r.y])];var r,o,s,a;for(let r=1;r<n;r++){const n=e[r-1],l=e[r],c=e[r+1];if(!c||!t){i.push(Tn(l));continue}const h=Math.min(t,qn(l.x-n.x,l.y-n.y),qn(c.x-l.x,c.y-l.y));if(!h){i.push(Tn(l));continue}const u=Pn(l,n,h),d=Pn(l,n,.5*h),p=Pn(l,c,h),f=Pn(l,c,.5*h);i.push(Tn(u)),i.push((s=f,a=p,["C",(o=d).x,o.y,s.x,s.y,a.x,a.y]))}return i}function Pn(e,t,n){const i=t.x-e.x,r=t.y-e.y,o=n/qn(i,r);return{x:e.x+i*o,y:e.y+r*o}}function qn(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}function Bn(e,t,n){o(t)&&(n=t,t=null),t||(t={});const i=vn("path",t);return o(n)&&(i.dataset.cornerRadius=String(n)),Ln(i,e)}function Ln(e,t){return un(e,{d:On(Nn(t,parseInt(e.dataset.cornerRadius,10)||0))}),e}function In(e,t){var n,r,o,s;return t=!!t,i(e)||(e=[e]),u(e,(function(e){var i=e;e.waypoints&&!t&&(i=In(e.waypoints,!0));var a=i.x,l=i.y,c=i.height||0,h=i.width||0;(a<n||void 0===n)&&(n=a),(l<r||void 0===r)&&(r=l),(a+h>o||void 0===o)&&(o=a+h),(l+c>s||void 0===s)&&(s=l+c)})),{x:n,y:r,height:s-r,width:o-n}}function Fn(e){return!(!e||!e.isFrame)}function jn(e,t){sn.call(this,e,1),this.CONNECTION_STYLE=t.style(["no-fill"],{strokeWidth:5,stroke:"fuchsia"}),this.SHAPE_STYLE=t.style({fill:"white",stroke:"fuchsia",strokeWidth:2}),this.FRAME_STYLE=t.style(["no-fill"],{stroke:"fuchsia",strokeDasharray:4,strokeWidth:2})}rn(jn,sn),jn.prototype.canRender=function(){return!0},jn.prototype.drawShape=function(e,t,n){var i=vn("rect");return un(i,{x:0,y:0,width:t.width||0,height:t.height||0}),Fn(t)?un(i,b({},this.FRAME_STYLE,n||{})):un(i,b({},this.SHAPE_STYLE,n||{})),an(e,i),i},jn.prototype.drawConnection=function(e,t,n){var i=Bn(t.waypoints,b({},this.CONNECTION_STYLE,n||{}));return an(e,i),i},jn.prototype.getShapePath=function(e){var t=e.x,n=e.y,i=e.width;return On([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])},jn.prototype.getConnectionPath=function(e){var t,n,i=e.waypoints,r=[];for(t=0;n=i[t];t++)n=n.original||n,r.push([0===t?"M":"L",n.x,n.y]);return On(r)},jn.$inject=["eventBus","styles"];var Vn={__init__:["defaultRenderer"],defaultRenderer:["type",jn],styles:["type",function(){var e={"no-fill":{fill:"none"},"no-border":{strokeOpacity:0},"no-events":{pointerEvents:"none"}},t=this;this.cls=function(e,t,n){return b(this.style(t,n),{class:e})},this.style=function(t,n){i(t)||n||(n=t,t=[]);var r=d(t,(function(t,n){return b(t,e[n]||{})}),{});return n?b(r,n):r},this.computeStyle=function(e,n,r){return i(n)||(r=n,n=[]),t.style(n||[],b({},r,e||{}))}}]};function $n(e){return{top:e.y,right:e.x+(e.width||0),bottom:e.y+(e.height||0),left:e.x}}function zn(e,t){return Math.round(e*t)/t}function Hn(e){return o(e)?e+"px":e}function Wn(e,t,n){const i=vn("g");pn(i).add(t);const r=void 0!==n?n:e.childNodes.length-1;return e.insertBefore(i,e.childNodes[r]||null),i}const Un={shape:["x","y","width","height"],connection:["waypoints"]};function Gn(e,t,n,i){this._eventBus=t,this._elementRegistry=i,this._graphicsFactory=n,this._rootsIdx=0,this._layers={},this._planes=[],this._rootElement=null,this._focused=!1,this._init(e||{})}function Kn(e,t){const n="matrix("+t.a+","+t.b+","+t.c+","+t.d+","+t.e+","+t.f+")";e.setAttribute("transform",n)}Gn.$inject=["config.canvas","eventBus","graphicsFactory","elementRegistry"],Gn.prototype._init=function(e){const t=this._eventBus,n=this._container=function(e){const t=(e=b({},{width:"100%",height:"100%"},e)).container||document.body,n=document.createElement("div");return n.setAttribute("class","djs-container djs-parent"),wt(n,{position:"relative",overflow:"hidden",width:Hn(e.width),height:Hn(e.height)}),t.appendChild(n),n}(e),i=this._svg=vn("svg");un(i,{width:"100%",height:"100%"}),bt(i,"tabindex",0),t.on("element.hover",(()=>{this.restoreFocus()})),i.addEventListener("focusin",(()=>{this._focused=!0,t.fire("canvas.focus.changed",{focused:!0})})),i.addEventListener("focusout",(()=>{this._focused=!1,t.fire("canvas.focus.changed",{focused:!1})})),an(n,i);const r=this._viewport=Wn(i,"viewport");e.deferUpdate&&(this._viewboxChanged=v(w(this._viewboxChanged,this),300)),t.on("diagram.init",(()=>{t.fire("canvas.init",{svg:i,viewport:r})})),t.on(["shape.added","connection.added","shape.removed","connection.removed","elements.changed","root.set"],(()=>{delete this._cachedViewbox})),t.on("diagram.destroy",500,this._destroy,this),t.on("diagram.clear",500,this._clear,this)},Gn.prototype._destroy=function(){this._eventBus.fire("canvas.destroy",{svg:this._svg,viewport:this._viewport});const e=this._container.parentNode;e&&e.removeChild(this._container),delete this._svg,delete this._container,delete this._layers,delete this._planes,delete this._rootElement,delete this._viewport},Gn.prototype._clear=function(){this._elementRegistry.getAll().forEach((e=>{const t=function(e){return"waypoints"in e?"connection":"x"in e?"shape":"root"}(e);"root"===t?this.removeRootElement(e):this._removeElement(e,t)})),this._planes=[],this._rootElement=null,delete this._cachedViewbox},Gn.prototype.focus=function(){this._svg.focus({preventScroll:!0})},Gn.prototype.restoreFocus=function(){document.activeElement===document.body&&this.focus()},Gn.prototype.isFocused=function(){return this._focused},Gn.prototype.getDefaultLayer=function(){return this.getLayer("base",0)},Gn.prototype.getLayer=function(e,t){if(!e)throw new Error("must specify a name");let n=this._layers[e];if(n||(n=this._layers[e]=this._createLayer(e,t)),void 0!==t&&n.index!==t)throw new Error("layer <"+e+"> already created at index <"+t+">");return n.group},Gn.prototype._getChildIndex=function(e){return d(this._layers,(function(t,n){return n.visible&&e>=n.index&&t++,t}),0)},Gn.prototype._createLayer=function(e,t){void 0===t&&(t=1);const n=this._getChildIndex(t);return{group:Wn(this._viewport,"layer-"+e,n),index:t,visible:!0}},Gn.prototype.showLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=this._viewport,i=t.group,r=t.index;if(t.visible)return i;const o=this._getChildIndex(r);return n.insertBefore(i,n.childNodes[o]||null),t.visible=!0,i},Gn.prototype.hideLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=t.group;return t.visible?(An(n),t.visible=!1,n):n},Gn.prototype._removeLayer=function(e){const t=this._layers[e];t&&(delete this._layers[e],An(t.group))},Gn.prototype.getActiveLayer=function(){const e=this._findPlaneForRoot(this.getRootElement());return e?e.layer:null},Gn.prototype.findRoot=function(e){if("string"==typeof e&&(e=this._elementRegistry.get(e)),!e)return;const t=this._findPlaneForRoot(function(e){for(;e.parent;)e=e.parent;return e}(e))||{};return t.rootElement},Gn.prototype.getRootElements=function(){return this._planes.map((function(e){return e.rootElement}))},Gn.prototype._findPlaneForRoot=function(e){return c(this._planes,(function(t){return t.rootElement===e}))},Gn.prototype.getContainer=function(){return this._container},Gn.prototype._updateMarker=function(e,t,n){let i;e.id||(e=this._elementRegistry.get(e)),e.markers=e.markers||new Set,i=this._elementRegistry._elements[e.id],i&&(u([i.gfx,i.secondaryGfx],(function(i){i&&(n?(e.markers.add(t),pn(i).add(t)):(e.markers.delete(t),pn(i).remove(t)))})),this._eventBus.fire("element.marker.update",{element:e,gfx:i.gfx,marker:t,add:!!n}))},Gn.prototype.addMarker=function(e,t){this._updateMarker(e,t,!0)},Gn.prototype.removeMarker=function(e,t){this._updateMarker(e,t,!1)},Gn.prototype.hasMarker=function(e,t){return e.id||(e=this._elementRegistry.get(e)),!!e.markers&&e.markers.has(t)},Gn.prototype.toggleMarker=function(e,t){this.hasMarker(e,t)?this.removeMarker(e,t):this.addMarker(e,t)},Gn.prototype.getRootElement=function(){const e=this._rootElement;return e||this._planes.length?e:this.setRootElement(this.addRootElement(null))},Gn.prototype.addRootElement=function(e){const t=this._rootsIdx++;e||(e={id:"__implicitroot_"+t,children:[],isImplicit:!0});const n=e.layer="root-"+t;this._ensureValid("root",e);const i=this.getLayer(n,0);return this.hideLayer(n),this._addRoot(e,i),this._planes.push({rootElement:e,layer:i}),e},Gn.prototype.removeRootElement=function(e){"string"==typeof e&&(e=this._elementRegistry.get(e));if(this._findPlaneForRoot(e))return this._removeRoot(e),this._removeLayer(e.layer),this._planes=this._planes.filter((function(t){return t.rootElement!==e})),this._rootElement===e&&(this._rootElement=null),e},Gn.prototype.setRootElement=function(e){if(e===this._rootElement)return e;let t;if(!e)throw new Error("rootElement required");return t=this._findPlaneForRoot(e),t||(e=this.addRootElement(e)),this._setRoot(e),e},Gn.prototype._removeRoot=function(e){const t=this._elementRegistry,n=this._eventBus;n.fire("root.remove",{element:e}),n.fire("root.removed",{element:e}),t.remove(e)},Gn.prototype._addRoot=function(e,t){const n=this._elementRegistry,i=this._eventBus;i.fire("root.add",{element:e}),n.add(e,t),i.fire("root.added",{element:e,gfx:t})},Gn.prototype._setRoot=function(e,t){const n=this._rootElement;n&&(this._elementRegistry.updateGraphics(n,null,!0),this.hideLayer(n.layer)),e&&(t||(t=this._findPlaneForRoot(e).layer),this._elementRegistry.updateGraphics(e,this._svg,!0),this.showLayer(e.layer)),this._rootElement=e,this._eventBus.fire("root.set",{element:e})},Gn.prototype._ensureValid=function(e,t){if(!t.id)throw new Error("element must have an id");if(this._elementRegistry.get(t.id))throw new Error("element <"+t.id+"> already exists");const n=Un[e],i=p(n,(function(e){return void 0!==t[e]}));if(!i)throw new Error("must supply { "+n.join(", ")+" } with "+e)},Gn.prototype._setParent=function(e,t,n){!function(e,t,n){if(e&&t){"number"!=typeof n&&(n=-1);var i=e.indexOf(t);if(-1!==i){if(i===n)return;if(-1===n)return;e.splice(i,1)}-1!==n?e.splice(n,0,t):e.push(t)}}(t.children,e,n),e.parent=t},Gn.prototype._addElement=function(e,t,n,i){n=n||this.getRootElement();const r=this._eventBus,o=this._graphicsFactory;this._ensureValid(e,t),r.fire(e+".add",{element:t,parent:n}),this._setParent(t,n,i);const s=o.create(e,t,i);return this._elementRegistry.add(t,s),o.update(e,t,s),r.fire(e+".added",{element:t,gfx:s}),t},Gn.prototype.addShape=function(e,t,n){return this._addElement("shape",e,t,n)},Gn.prototype.addConnection=function(e,t,n){return this._addElement("connection",e,t,n)},Gn.prototype._removeElement=function(e,t){const n=this._elementRegistry,i=this._graphicsFactory,r=this._eventBus;if(e=n.get(e.id||e))return r.fire(t+".remove",{element:e}),i.remove(e),function(e,t){if(!e||!t)return-1;var n=e.indexOf(t);-1!==n&&e.splice(n,1)}(e.parent&&e.parent.children,e),e.parent=null,r.fire(t+".removed",{element:e}),n.remove(e),e},Gn.prototype.removeShape=function(e){return this._removeElement(e,"shape")},Gn.prototype.removeConnection=function(e){return this._removeElement(e,"connection")},Gn.prototype.getGraphics=function(e,t){return this._elementRegistry.getGraphics(e,t)},Gn.prototype._changeViewbox=function(e){this._eventBus.fire("canvas.viewbox.changing"),e.apply(this),this._cachedViewbox=null,this._viewboxChanged()},Gn.prototype._viewboxChanged=function(){this._eventBus.fire("canvas.viewbox.changed",{viewbox:this.viewbox()})},Gn.prototype.viewbox=function(e){if(void 0===e&&this._cachedViewbox)return structuredClone(this._cachedViewbox);const t=this._viewport,n=this.getSize();let i,r,o,s,a,l,c;return e?(this._changeViewbox((function(){a=Math.min(n.width/e.width,n.height/e.height);const i=this._svg.createSVGMatrix().scale(a).translate(-e.x,-e.y);Rn(t,i)})),e):(o=this._rootElement?this.getActiveLayer():null,i=o&&o.getBBox()||{},s=Rn(t),r=s?s.matrix:function(e,t,n,i,r,o){var s=bn().createSVGMatrix();switch(arguments.length){case 0:return s;case 1:return xn(s,e);case 6:return xn(s,{a:e,b:t,c:n,d:i,e:r,f:o})}}(),a=zn(r.a,1e3),l=zn(-r.e||0,1e3),c=zn(-r.f||0,1e3),e=this._cachedViewbox={x:l?l/a:0,y:c?c/a:0,width:n.width/a,height:n.height/a,scale:a,inner:{width:i.width||0,height:i.height||0,x:i.x||0,y:i.y||0},outer:n})},Gn.prototype.scroll=function(e){const t=this._viewport;let n=t.getCTM();return e&&this._changeViewbox((function(){e=b({dx:0,dy:0},e||{}),n=this._svg.createSVGMatrix().translate(e.dx,e.dy).multiply(n),Kn(t,n)})),{x:n.e,y:n.f}},Gn.prototype.scrollToElement=function(e,t){let n=100;"string"==typeof e&&(e=this._elementRegistry.get(e));const i=this.findRoot(e);if(i!==this.getRootElement()&&this.setRootElement(i),i===e)return;t||(t={}),"number"==typeof t&&(n=t),t={top:t.top||n,right:t.right||n,bottom:t.bottom||n,left:t.left||n};const r=In(e),o=$n(r),s=this.viewbox(),a=this.zoom();let l,c;s.y+=t.top/a,s.x+=t.left/a,s.width-=(t.right+t.left)/a,s.height-=(t.bottom+t.top)/a;const h=$n(s);if(r.width<s.width&&r.height<s.height){const e=Math.max(0,o.right-h.right),t=Math.min(0,o.left-h.left),n=Math.max(0,o.bottom-h.bottom),i=Math.min(0,o.top-h.top);l=e||t,c=n||i}else l=r.x-s.x,c=r.y-s.y;this.scroll({dx:-l*a,dy:-c*a})},Gn.prototype.zoom=function(e,t){if(!e)return this.viewbox(e).scale;if("fit-viewport"===e)return this._fitViewport(t);let n,i;return this._changeViewbox((function(){"object"!=typeof t&&(n=this.viewbox().outer,t={x:n.width/2,y:n.height/2}),i=this._setZoom(e,t)})),zn(i.a,1e3)},Gn.prototype._fitViewport=function(e){const t=this.viewbox(),n=t.outer,i=t.inner;let r,o;return i.x>=0&&i.y>=0&&i.x+i.width<=n.width&&i.y+i.height<=n.height&&!e?o={x:0,y:0,width:Math.max(i.width+i.x,n.width),height:Math.max(i.height+i.y,n.height)}:(r=Math.min(1,n.width/i.width,n.height/i.height),o={x:i.x+(e?i.width/2-n.width/r/2:0),y:i.y+(e?i.height/2-n.height/r/2:0),width:n.width/r,height:n.height/r}),this.viewbox(o),this.viewbox(!1).scale},Gn.prototype._setZoom=function(e,t){const n=this._svg,i=this._viewport,r=n.createSVGMatrix(),o=n.createSVGPoint();let s,a,l,c,h;l=i.getCTM();const u=l.a;return t?(s=b(o,t),a=s.matrixTransform(l.inverse()),c=r.translate(a.x,a.y).scale(1/u*e).translate(-a.x,-a.y),h=l.multiply(c)):h=r.scale(e),Kn(this._viewport,h),h},Gn.prototype.getSize=function(){return{width:this._container.clientWidth,height:this._container.clientHeight}},Gn.prototype.getAbsoluteBBox=function(e){const t=this.viewbox();let n;if(e.waypoints){n=this.getGraphics(e).getBBox()}else n=e;return{x:n.x*t.scale-t.x*t.scale,y:n.y*t.scale-t.y*t.scale,width:n.width*t.scale,height:n.height*t.scale}},Gn.prototype.resized=function(){delete this._cachedViewbox,this._eventBus.fire("canvas.resized")};var Xn="data-element-id";function Yn(e){this._elements={},this._eventBus=e}function Jn(e,t,n){var i=function(e,t,n,i){var r=n.inverse;return Object.defineProperty(e,"remove",{value:function(e){var n=this.indexOf(e);return-1!==n&&(this.splice(n,1),t.unset(e,r,i)),e}}),Object.defineProperty(e,"contains",{value:function(e){return-1!==this.indexOf(e)}}),Object.defineProperty(e,"add",{value:function(e,n){var o=this.indexOf(e);if(void 0===n){if(-1!==o)return;n=this.length}-1!==o&&this.splice(o,1),this.splice(n,0,e),-1===o&&t.set(e,r,i)}}),Object.defineProperty(e,"__refs_collection",{value:!0}),e}(n[t.name]||[],e,t,n);Object.defineProperty(n,t.name,{enumerable:t.enumerable,value:i}),i.length&&i.forEach((function(i){e.set(i,t.inverse,n)}))}function Qn(e,t){if(!(this instanceof Qn))return new Qn(e,t);e.inverse=t,t.inverse=e,this.props={},this.props[e.name]=e,this.props[t.name]=t}Yn.$inject=["eventBus"],Yn.prototype.add=function(e,t,n){var i=e.id;this._validateId(i),un(t,Xn,i),n&&un(n,Xn,i),this._elements[i]={element:e,gfx:t,secondaryGfx:n}},Yn.prototype.remove=function(e){var t=this._elements,n=e.id||e,i=n&&t[n];i&&(un(i.gfx,Xn,""),i.secondaryGfx&&un(i.secondaryGfx,Xn,""),delete t[n])},Yn.prototype.updateId=function(e,t){this._validateId(t),"string"==typeof e&&(e=this.get(e)),this._eventBus.fire("element.updateId",{element:e,newId:t});var n=this.getGraphics(e),i=this.getGraphics(e,!0);this.remove(e),e.id=t,this.add(e,n,i)},Yn.prototype.updateGraphics=function(e,t,n){var i=e.id||e,r=this._elements[i];return n?r.secondaryGfx=t:r.gfx=t,t&&un(t,Xn,i),t},Yn.prototype.get=function(e){var t;t="string"==typeof e?e:e&&un(e,Xn);var n=this._elements[t];return n&&n.element},Yn.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(n)})),t},Yn.prototype.find=function(e){for(var t=this._elements,n=Object.keys(t),i=0;i<n.length;i++){var r=t[n[i]],o=r.element;if(e(o,r.gfx))return o}},Yn.prototype.getAll=function(){return this.filter((function(e){return e}))},Yn.prototype.forEach=function(e){var t=this._elements;Object.keys(t).forEach((function(n){var i=t[n],r=i.element,o=i.gfx;return e(r,o)}))},Yn.prototype.getGraphics=function(e,t){var n=e.id||e,i=this._elements[n];return i&&(t?i.secondaryGfx:i.gfx)},Yn.prototype._validateId=function(e){if(!e)throw new Error("element must have an id");if(this._elements[e])throw new Error("element with id "+e+" already added")},Qn.prototype.bind=function(e,t){if("string"==typeof t){if(!this.props[t])throw new Error("no property <"+t+"> in ref");t=this.props[t]}t.collection?Jn(this,t,e):function(e,t,n){var i=t.inverse,r=n[t.name];Object.defineProperty(n,t.name,{configurable:t.configurable,enumerable:t.enumerable,get:function(){return r},set:function(t){if(t!==r){var o=r;r=null,o&&e.unset(o,i,n),r=t,e.set(r,i,n)}}})}(this,t,e)},Qn.prototype.ensureRefsCollection=function(e,t){var n=e[t.name];return function(e){return!0===e.__refs_collection}(n)||Jn(this,t,e),n},Qn.prototype.ensureBound=function(e,t){(function(e,t){return Object.prototype.hasOwnProperty.call(e,t.name||t)})(e,t)||this.bind(e,t)},Qn.prototype.unset=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).remove(n):e[t.name]=void 0)},Qn.prototype.set=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).add(n):e[t.name]=n)};var Zn=new Qn({name:"children",enumerable:!0,collection:!0},{name:"parent"}),ei=new Qn({name:"labels",enumerable:!0,collection:!0},{name:"labelTarget"}),ti=new Qn({name:"attachers",collection:!0},{name:"host"}),ni=new Qn({name:"outgoing",collection:!0},{name:"source"}),ii=new Qn({name:"incoming",collection:!0},{name:"target"});function ri(){Object.defineProperty(this,"businessObject",{writable:!0}),Object.defineProperty(this,"label",{get:function(){return this.labels[0]},set:function(e){var t=this.label,n=this.labels;!e&&t?n.remove(t):n.add(e,0)}}),Zn.bind(this,"parent"),ei.bind(this,"labels"),ni.bind(this,"outgoing"),ii.bind(this,"incoming")}function oi(){ri.call(this),Zn.bind(this,"children"),ti.bind(this,"host"),ti.bind(this,"attachers")}function si(){ri.call(this),Zn.bind(this,"children")}function ai(){oi.call(this),ei.bind(this,"labelTarget")}function li(){ri.call(this),ni.bind(this,"source"),ii.bind(this,"target")}rn(oi,ri),rn(si,oi),rn(ai,oi),rn(li,ri);var ci={connection:li,shape:oi,label:ai,root:si};function hi(){this._uid=12}function ui(e,t,n){var i=bn().createSVGTransform();i.setTranslate(t,n),Rn(e,i)}function di(e,t){this._eventBus=e,this._elementRegistry=t}function pi(e,t,n){var i=n||t.firstChild;e!==i&&t.insertBefore(e,i)}hi.prototype.createRoot=function(e){return this.create("root",e)},hi.prototype.createLabel=function(e){return this.create("label",e)},hi.prototype.createShape=function(e){return this.create("shape",e)},hi.prototype.createConnection=function(e){return this.create("connection",e)},hi.prototype.create=function(e,t){return(t=b({},t||{})).id||(t.id=e+"_"+this._uid++),function(e,t){var n=ci[e];if(!n)throw new Error("unknown type: <"+e+">");return b(new n,t)}(e,t)},di.$inject=["eventBus","elementRegistry"],di.prototype._getChildrenContainer=function(e){var t,n=this._elementRegistry.getGraphics(e);return e.parent?(t=function(e){return e.parentNode.childNodes[1]}(n),t||(pn(t=vn("g")).add("djs-children"),an(n.parentNode,t))):t=n,t},di.prototype._clear=function(e){var t=function(e){return e.childNodes[0]}(e);return St(t),t},di.prototype._createContainer=function(e,t,n,i){var r=vn("g");pn(r).add("djs-group"),void 0!==n?pi(r,t,t.childNodes[n]):an(t,r);var o=vn("g");pn(o).add("djs-element"),pn(o).add("djs-"+e),i&&pn(o).add("djs-frame"),an(r,o);var s=vn("g");return pn(s).add("djs-visual"),an(o,s),o},di.prototype.create=function(e,t,n){var i=this._getChildrenContainer(t.parent);return this._createContainer(e,i,n,Fn(t))},di.prototype.updateContainments=function(e){var t,n=this,i=this._elementRegistry;t=d(e,(function(e,t){return t.parent&&(e[t.parent.id]=t.parent),e}),{}),u(t,(function(e){var t=e.children;if(t){var r=n._getChildrenContainer(e);u(t.slice().reverse(),(function(e){pi(i.getGraphics(e).parentNode,r)}))}}))},di.prototype.drawShape=function(e,t,n={}){return this._eventBus.fire("render.shape",{gfx:e,element:t,attrs:n})},di.prototype.getShapePath=function(e){return this._eventBus.fire("render.getShapePath",e)},di.prototype.drawConnection=function(e,t,n={}){return this._eventBus.fire("render.connection",{gfx:e,element:t,attrs:n})},di.prototype.getConnectionPath=function(e){return this._eventBus.fire("render.getConnectionPath",e)},di.prototype.update=function(e,t,n){if(t.parent){var i=this._clear(n);if("shape"===e)this.drawShape(i,t),ui(n,t.x,t.y);else{if("connection"!==e)throw new Error("unknown type: "+e);this.drawConnection(i,t)}t.hidden?un(n,"display","none"):un(n,"display","block")}},di.prototype.remove=function(e){An(this._elementRegistry.getGraphics(e).parentNode)};var fi={__depends__:[Vn],__init__:["canvas"],canvas:["type",Gn],elementRegistry:["type",Yn],elementFactory:["type",hi],eventBus:["type",_],graphicsFactory:["type",di]};function gi(e){return function(e){var t=new tn(e);return t.init(),t}([{config:["value",e=e||{}]},fi].concat(e.modules||[]))}function mi(e,t){this._injector=t||gi(e),this.get("eventBus").fire("diagram.init")}function yi(e,t){var n=vi(e);return n&&"function"==typeof n.$instanceOf&&n.$instanceOf(t)}function vi(e){return e&&e.businessObject||e}function wi(e){var t=vi(e);if(yi(t,"dmn:Decision"))return t.get("decisionLogic");if(yi(t,"dmn:BusinessKnowledgeModel")){var n=t.get("encapsulatedLogic");return n&&n.get("body")}}mi.prototype.get=function(e,t){return this._injector.get(e,t)},mi.prototype.invoke=function(e,t,n){return this._injector.invoke(e,t,n)},mi.prototype.destroy=function(){this.get("eventBus").fire("diagram.destroy")},mi.prototype.clear=function(){this.get("eventBus").fire("diagram.clear")};var bi=new Qn({name:"dmnElementRef",enumerable:!0},{name:"di",configurable:!0});function xi(e,t){var n=[];function i(t){try{var n=t.di&&function(t){if(t.gfx)throw new Error("already rendered "+t.id);return e.element(t)}(t);return n}catch(e){s(e.message,{element:t,error:e})}}function r(e){var t,n;(n=(t=e).dmnElementRef)?n.di?s("multiple DI elements defined for element",{element:n}):(bi.bind(n,"di"),n.di=t):s("no DMN element referenced in element",{element:t})}function o(e){n.push(e)}function s(t,n){e.error(t,n)}return{handleDefinitions:function(t,s){var a=t.dmnDI;if(!a)throw new Error("no dmndi:DMNDI");var l,c=a.diagrams||[];if(s&&-1===c.indexOf(s))throw new Error("diagram not part of dmndi:DMNDI");if(!s&&c&&c.length&&(s=c[0]),!s)throw new Error("no diagram to display");t.di=s,function(e){u(e.diagramElements,r)}(s),l=t,e.root(l),u(t.get("drgElement"),(function(e){i(e),function(e){u(["informationRequirement","knowledgeRequirement","authorityRequirement"],(function(t){u(e[t],(function(e){o((function(){i(e)}))}))}))}(e)})),function(e){u(e,(function(e){yi(e,"dmn:Association")?function(e){o((function(){i(e)}))}(e):i(e)}))}(t.get("artifact")),u(n,(function(e){e()}))}}}var ki="$NO_OP",_i="a runtime error occured! Use Inferno in development environment to find the error.",Si=!("undefined"==typeof window||!window.document),Ci=Array.isArray;function Ei(e){var t=typeof e;return"string"===t||"number"===t}function Mi(e){return Ni(e)||Ti(e)}function Ai(e){return Ti(e)||!1===e||function(e){return!0===e}(e)||Ni(e)}function Di(e){return"function"==typeof e}function Ri(e){return"string"==typeof e}function Oi(e){return"number"==typeof e}function Ti(e){return null===e}function Ni(e){return void 0===e}function Pi(e){throw e||(e=_i),new Error("Inferno Error: "+e)}function qi(e){console.error(e)}function Bi(e,t){var n={};if(e)for(var i in e)n[i]=e[i];if(t)for(var r in t)n[r]=t[r];return n}function Li(e){var t;if(Ci(e))t="Array("+(e.length>3?e.slice(0,3).toString()+",...":e.toString())+")";else if(Ei(e))t="Text("+e+")";else if(Ai(e))t="InvalidVNode("+e+")";else{var n=e.flags;if(481&n)t="<"+e.type+(e.className?' class="'+e.className+'"':"")+">";else if(16&n)t="Text("+e.children+")";else if(1024&n)t="Portal*";else{var i=e.type;t="<"+(i.name||i.displayName||i.constructor.name||(i.toString().match(/^function\s*([^\s(]+)/)||[])[1])+" />"}}return">> "+t+"\n"}function Ii(e,t){for(var n={},i=0,r=e.length;i<r;i++){var o=e[i];if(Ci(o))return"Encountered ARRAY in mount, array must be flattened, or normalize used. Location: \n"+Li(o);if(Ai(o)){if(t)return"Encountered invalid node when preparing to keyed algorithm. Location: \n"+Li(o);if(0!==Object.keys(n).length)return"Encountered invalid node with mixed keys. Location: \n"+Li(o)}else{"object"==typeof o&&(o.isValidated=!0);var s=o.key;if(!Mi(s)&&!Ei(s))return"Encountered child vNode where key property is not string or number. Location: \n"+Li(o);var a=o.children,l=o.childFlags;if(!Ai(a)){var c=void 0;if(12&l?c=Ii(a,8&o.childFlags):2===l&&(c=Ii([a],8&o.childFlags)),c)return c+=Li(o)}if(t&&Mi(s))return"Encountered child without key during keyed algorithm. If this error points to Array make sure children is flat list. Location: \n"+Li(o);if(t||!Mi(s)){if(n[s])return"Encountered two children with same key: {"+s+"}. Location: \n"+Li(o);n[s]=!0}else if(0!==Object.keys(n).length)return"Encountered children with key missing. Location: \n"+Li(o)}}}function Fi(e){if(!(1&e.childFlags)&&(64&e.flags&&Pi("input elements can't have children."),128&e.flags&&Pi("textarea elements can't have children."),481&e.flags)){var t=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],n=e.type.toLowerCase();"media"===n&&Pi("media elements can't have children.");var i=t.indexOf(n);-1!==i&&Pi(t[i]+" elements can't have children.")}}function ji(e){if(!1===e.isValidated&&e.children&&481&e.flags){var t=Ii(Array.isArray(e.children)?e.children:[e.children],(8&e.childFlags)>0);t&&Pi(t+Li(e))}e.isValidated=!0}var Vi="$";function $i(e,t,n,i,r,o,s,a){return{childFlags:e,children:t,className:n,dom:null,flags:i,isValidated:!1,key:void 0===r?null:r,parentVNode:null,props:void 0===o?null:o,ref:void 0===s?null:s,type:a}}function zi(e,t,n,i,r,o,s,a){14&e&&Pi("Creating Component vNodes using createVNode is not allowed. Use Inferno.createComponentVNode method.");var l=void 0===r?1:r,c=$i(l,i,n,e,s,o,a,t);return 0===l&&Yi(c,c.children),Fi(c),c}function Hi(e,t,n,i,r){1&e&&Pi("Creating element vNodes using createComponentVNode is not allowed. Use Inferno.createVNode method."),(2&e)>0&&(e=t.prototype&&Di(t.prototype.render)?4:8);var o=t.defaultProps;if(!Mi(o))for(var s in n||(n={}),o)Ni(n[s])&&(n[s]=o[s]);if((8&e)>0){var a=t.defaultHooks;if(!Mi(a))if(r)for(var l in a)Ni(r[l])&&(r[l]=a[l]);else r=a}var c=$i(1,null,null,e,i,n,r,t),h=Ji.createVNode;return Di(h)&&h(c),c}function Wi(e,t){return $i(1,Mi(e)?"":e,null,16,t,null,null,null)}function Ui(e){var t=e.props;if(t){var n=e.flags;481&n&&(void 0!==t.children&&Mi(e.children)&&Yi(e,t.children),void 0!==t.className&&(e.className=t.className||null,t.className=void 0)),void 0!==t.key&&(e.key=t.key,t.key=void 0),void 0!==t.ref&&(e.ref=8&n?Bi(e.ref,t.ref):t.ref,t.ref=void 0)}return e}function Gi(e){var t,n=e.flags;if(14&n){var i,r=e.props;if(!Ti(r))for(var o in i={},r)i[o]=r[o];t=Hi(n,e.type,i,e.key,e.ref)}else 481&n?t=zi(n,e.type,e.className,e.children,e.childFlags,e.props,e.key,e.ref):16&n?t=Wi(e.children,e.key):1024&n&&(t=e);return t}function Ki(){return Wi("",null)}function Xi(e,t,n,i){for(var r=e.length;n<r;n++){var o=e[n];if(!Ai(o)){var s=i+Vi+n;if(Ci(o))Xi(o,t,0,s);else{if(Ei(o))o=Wi(o,s);else{var a=o.key,l=Ri(a)&&a[0]===Vi;Ti(o.dom)&&!l||(o=Gi(o)),Ti(a)||l?o.key=s:o.key=i+a}t.push(o)}}}}function Yi(e,t){var n,i=1;if(Ai(t))n=t;else if(Ri(t))i=2,n=Wi(t);else if(Oi(t))i=2,n=Wi(t+"");else if(Ci(t)){var r=t.length;if(0===r)n=null,i=1;else{(Object.isFrozen(t)||!0===t.$)&&(t=t.slice()),i=8;for(var o=0;o<r;o++){var s=t[o];if(Ai(s)||Ci(s)){n=n||t.slice(0,o),Xi(t,n,o,"");break}if(Ei(s))(n=n||t.slice(0,o)).push(Wi(s,Vi+o));else{var a=s.key,l=Ti(s.dom),c=Ti(a),h=!c&&Ri(a)&&a[0]===Vi;!l||c||h?(n=n||t.slice(0,o),l&&!h||(s=Gi(s)),(c||h)&&(s.key=Vi+o),n.push(s)):n&&n.push(s)}}(n=n||t).$=!0}}else n=t,Ti(t.dom)||(n=Gi(t)),i=2;return e.children=n,e.childFlags=i,Fi(e),e}var Ji={afterRender:null,beforeRender:null,createVNode:null,renderComplete:null},Qi="http://www.w3.org/1999/xlink",Zi="http://www.w3.org/XML/1998/namespace",er="http://www.w3.org/2000/svg",tr={"xlink:actuate":Qi,"xlink:arcrole":Qi,"xlink:href":Qi,"xlink:role":Qi,"xlink:show":Qi,"xlink:title":Qi,"xlink:type":Qi,"xml:base":Zi,"xml:lang":Zi,"xml:space":Zi},nr={},ir=[];function rr(e,t){e.appendChild(t)}function or(e,t,n){Mi(n)?rr(e,t):e.insertBefore(t,n)}function sr(e,t,n){e.replaceChild(t,n)}function ar(e){for(var t;void 0!==(t=e.shift());)t()}Object.freeze(nr);var lr={},cr={};function hr(e,t,n){var i=lr[e],r=n.$EV;t?(i||(cr[e]=function(e){var t=function(t){var n=t.type,i="click"===n||"dblclick"===n;if(i&&0!==t.button)return t.stopPropagation(),!1;t.stopPropagation=dr;var r={dom:document};Object.defineProperty(t,"currentTarget",{configurable:!0,get:function(){return r.dom}}),function(e,t,n,i){var r=function(e){return Di(e.composedPath)?e.composedPath()[0]:e.target}(e);for(;!Ti(r);){if(t&&r.disabled)return;var o=r.$EV;if(o){var s=o[n];if(s&&(i.dom=r,s.event?s.event(s.data,e):s(e),e.cancelBubble))return}r=r.parentNode}}(t,i,e,r)};return document.addEventListener(ur(e),t),t}(e),lr[e]=0),r||(r=n.$EV={}),r[e]||lr[e]++,r[e]=t):r&&r[e]&&(lr[e]--,1===i&&(document.removeEventListener(ur(e),cr[e]),cr[e]=null),r[e]=t)}function ur(e){return e.substr(2).toLowerCase()}function dr(){this.cancelBubble=!0,this.immediatePropagationStopped||this.stopImmediatePropagation()}function pr(e,t){var n=document.createElement("i");return n.innerHTML=t,n.innerHTML===e.innerHTML}function fr(e,t,n){if(e[t]){var i=e[t];i.event?i.event(i.data,n):i(n)}else{var r=t.toLowerCase();e[r]&&e[r](n)}}function gr(e,t){var n=function(n){n.stopPropagation();var i=this.$V;if(i){var r=i.props||nr,o=i.dom;if(Ri(e))fr(r,e,n);else for(var s=0;s<e.length;s++)fr(r,e[s],n);if(Di(t)){var a=this.$V,l=a.props||nr;t(l,o,!1,a)}}};return Object.defineProperty(n,"wrapped",{configurable:!1,enumerable:!1,value:!0,writable:!1}),n}function mr(e){return"checkbox"===e||"radio"===e}var yr=gr("onInput",br),vr=gr(["onClick","onChange"],br);function wr(e){e.stopPropagation()}function br(e,t){var n=e.type,i=e.value,r=e.checked,o=e.multiple,s=e.defaultValue,a=!Mi(i);n&&n!==t.type&&t.setAttribute("type",n),Mi(o)||o===t.multiple||(t.multiple=o),Mi(s)||a||(t.defaultValue=s+""),mr(n)?(a&&(t.value=i),Mi(r)||(t.checked=r)):a&&t.value!==i?(t.defaultValue=i,t.value=i):Mi(r)||(t.checked=r)}function xr(e,t){if("optgroup"===e.type){var n=e.children,i=e.childFlags;if(12&i)for(var r=0,o=n.length;r<o;r++)kr(n[r],t);else 2===i&&kr(n,t)}else kr(e,t)}function kr(e,t){var n=e.props||nr,i=e.dom;i.value=n.value,Ci(t)&&-1!==t.indexOf(n.value)||n.value===t?i.selected=!0:Mi(t)&&Mi(n.selected)||(i.selected=n.selected||!1)}wr.wrapped=!0;var _r=gr("onChange",Sr);function Sr(e,t,n,i){var r=Boolean(e.multiple);Mi(e.multiple)||r===t.multiple||(t.multiple=r);var o=i.childFlags;if(!(1&o)){var s=i.children,a=e.value;if(n&&Mi(a)&&(a=e.defaultValue),12&o)for(var l=0,c=s.length;l<c;l++)xr(s[l],a);else 2===o&&xr(s,a)}}var Cr=gr("onInput",Mr),Er=gr("onChange");function Mr(e,t,n){var i=e.value,r=t.value;if(Mi(i)){if(n){var o=e.defaultValue;Mi(o)||o===r||(t.defaultValue=o,t.value=o)}}else r!==i&&(t.defaultValue=i,t.value=i)}function Ar(e,t,n,i,r,o){64&e?br(i,n):256&e?Sr(i,n,r,t):128&e&&Mr(i,n,r),o&&(n.$V=t)}function Dr(e,t,n){64&e?function(e,t){mr(t.type)?(e.onchange=vr,e.onclick=wr):e.oninput=yr}(t,n):256&e?function(e){e.onchange=_r}(t):128&e&&function(e,t){e.oninput=Cr,t.onChange&&(e.onchange=Er)}(t,n)}function Rr(e){return e.type&&mr(e.type)?!Mi(e.checked):!Mi(e.value)}function Or(e,t){Tr(e),t&&e.dom&&(!function(e,t){e.removeChild(t)}(t,e.dom),e.dom=null)}function Tr(e){var t=e.flags;if(481&t){var n=e.ref,i=e.props;Di(n)&&n(null);var r=e.children,o=e.childFlags;if(12&o?Nr(r):2===o&&Tr(r),!Ti(i))for(var s in i)switch(s){case"onClick":case"onDblClick":case"onFocusIn":case"onFocusOut":case"onKeyDown":case"onKeyPress":case"onKeyUp":case"onMouseDown":case"onMouseMove":case"onMouseUp":case"onSubmit":case"onTouchEnd":case"onTouchMove":case"onTouchStart":hr(s,null,e.dom)}}else{var a=e.children;if(a)if(14&t){var l=e.ref;4&t?(Di(a.componentWillUnmount)&&a.componentWillUnmount(),Di(l)&&l(null),a.$UN=!0,a.$LI&&Tr(a.$LI)):(!Mi(l)&&Di(l.onComponentWillUnmount)&&l.onComponentWillUnmount(e.dom,e.props||nr),Tr(a))}else 1024&t&&Or(a,e.type)}}function Nr(e){for(var t=0,n=e.length;t<n;t++)Tr(e[t])}function Pr(e,t){Nr(t),e.textContent=""}function qr(e,t){switch(e){case"animationIterationCount":case"borderImageOutset":case"borderImageSlice":case"borderImageWidth":case"boxFlex":case"boxFlexGroup":case"boxOrdinalGroup":case"columnCount":case"fillOpacity":case"flex":case"flexGrow":case"flexNegative":case"flexOrder":case"flexPositive":case"flexShrink":case"floodOpacity":case"fontWeight":case"gridColumn":case"gridRow":case"lineClamp":case"lineHeight":case"opacity":case"order":case"orphans":case"stopOpacity":case"strokeDasharray":case"strokeDashoffset":case"strokeMiterlimit":case"strokeOpacity":case"strokeWidth":case"tabSize":case"widows":case"zIndex":case"zoom":return t;default:return t+"px"}}function Br(e,t,n,i,r,o,s){switch(e){case"onClick":case"onDblClick":case"onFocusIn":case"onFocusOut":case"onKeyDown":case"onKeyPress":case"onKeyUp":case"onMouseDown":case"onMouseMove":case"onMouseUp":case"onSubmit":case"onTouchEnd":case"onTouchMove":case"onTouchStart":hr(e,n,i);break;case"children":case"childrenType":case"className":case"defaultValue":case"key":case"multiple":case"ref":break;case"autoFocus":i.autofocus=!!n;break;case"allowfullscreen":case"autoplay":case"capture":case"checked":case"controls":case"default":case"disabled":case"hidden":case"indeterminate":case"loop":case"muted":case"novalidate":case"open":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"selected":i[e]=!!n;break;case"defaultChecked":case"value":case"volume":if(o&&"value"===e)return;var a=Mi(n)?"":n;i[e]!==a&&(i[e]=a);break;case"dangerouslySetInnerHTML":var l=t&&t.__html||"",c=n&&n.__html||"";l!==c&&(Mi(c)||pr(i,c)||(Ti(s)||(12&s.childFlags?Nr(s.children):2===s.childFlags&&Tr(s.children),s.children=null,s.childFlags=1),i.innerHTML=c));break;default:"o"===e[0]&&"n"===e[1]?function(e,t,n){var i=e.toLowerCase();if(Di(t)||Mi(t)){var r=n[i];r&&r.wrapped||(n[i]=t)}else{var o=t.event;o&&Di(o)?n[i]=function(e,t){return function(n){e(t.data,n)}}(o,t):Pi('an event on a VNode "'+e+'". was not a function or a valid linkEvent.')}}(e,n,i):Mi(n)?i.removeAttribute(e):"style"===e?function(e,t,n){var i,r,o=n.style;if(Ri(t))o.cssText=t;else if(Mi(e)||Ri(e))for(i in t)r=t[i],o[i]=Oi(r)?qr(i,r):r;else{for(i in t)(r=t[i])!==e[i]&&(o[i]=Oi(r)?qr(i,r):r);for(i in e)Mi(t[i])&&(o[i]="")}}(t,n,i):r&&tr[e]?i.setAttributeNS(tr[e],e,n):i.setAttribute(e,n)}}function Lr(e,t,n,i,r){var o=!1,s=(448&t)>0;for(var a in s&&(o=Rr(n))&&Dr(t,i,n),n)Br(a,null,n[a],i,r,o,null);s&&Ar(t,e,i,n,!0,o)}function Ir(e,t,n,i){var r=new t(n,i);if(e.children=r,r.$V=e,r.$BS=!1,r.context=i,r.props===nr&&(r.props=n),r.$UN=!1,Di(r.componentWillMount)){if(r.$BR=!0,r.componentWillMount(),r.$PSS){var o=r.state,s=r.$PS;if(Ti(o))r.state=s;else for(var a in s)o[a]=s[a];r.$PSS=!1,r.$PS=null}r.$BR=!1}Di(Ji.beforeRender)&&Ji.beforeRender(r);var l,c=Fr(r.render(n,r.state,i),e);return Di(r.getChildContext)&&(l=r.getChildContext()),Mi(l)?r.$CX=i:r.$CX=Bi(i,l),Di(Ji.afterRender)&&Ji.afterRender(r),r.$LI=c,r}function Fr(e,t){return Ci(e)&&Pi("a valid Inferno VNode (or null) must be returned from a component render. You may have returned an array or an invalid object."),Ai(e)?e=Ki():Ei(e)?e=Wi(e,null):(e.dom&&(e=Gi(e)),14&e.flags&&(e.parentVNode=t)),e}function jr(e,t,n,i){var r=e.flags;return 481&r?$r(e,t,n,i):14&r?function(e,t,n,i,r){var o,s=e.type,a=e.props||nr,l=e.ref;if(r){var c=Ir(e,s,a,n);e.dom=o=jr(c.$LI,null,c.$CX,i),Hr(e,l,c),c.$UPD=!1}else{var h=Fr(s(a,n),e);e.children=h,e.dom=o=jr(h,null,n,i),Wr(a,l,o)}Ti(t)||rr(t,o);return o}(e,t,n,i,(4&r)>0):512&r||16&r?Vr(e,t):1024&r?(jr(e.children,e.type,n,!1),e.dom=Vr(Ki(),t)):void Pi("object"==typeof e?"mount() received an object that's not a valid VNode, you should stringify it first, fix createVNode flags or call normalizeChildren. Object: \""+JSON.stringify(e)+'".':'mount() expects a valid VNode, instead it received an object with the type "'+typeof e+'".')}function Vr(e,t){var n=e.dom=document.createTextNode(e.children);return Ti(t)||rr(t,n),n}function $r(e,t,n,i){var r=e.flags,o=e.children,s=e.props,a=e.className,l=e.ref,c=e.childFlags;i=i||(32&r)>0;var h=function(e,t){return t?document.createElementNS(er,e):document.createElement(e)}(e.type,i);if(e.dom=h,Mi(a)||""===a||(i?h.setAttribute("class",a):h.className=a),ji(e),Ti(t)||rr(t,h),!(1&c)){var u=!0===i&&"foreignObject"!==e.type;2===c?jr(o,h,n,u):12&c&&zr(o,h,n,u)}return Ti(s)||Lr(e,r,s,h,i),Ri(l)&&Pi('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.'),Di(l)&&Ur(h,l),h}function zr(e,t,n,i){for(var r=0,o=e.length;r<o;r++){var s=e[r];Ti(s.dom)||(e[r]=s=Gi(s)),jr(s,t,n,i)}}function Hr(e,t,n){Di(t)?t(n):Ei(t)?Pi('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.'):!Mi(t)&&"object"==typeof t&&4&e.flags&&Pi("functional component lifecycle events are not supported on ES2015 class components."),Di(n.componentDidMount)&&ir.push(function(e){return function(){e.$UPD=!0,e.componentDidMount(),e.$UPD=!1}}(n))}function Wr(e,t,n){Mi(t)||(Di(t.onComponentWillMount)&&t.onComponentWillMount(e),Di(t.onComponentDidMount)&&ir.push(function(e,t,n){return function(){return e.onComponentDidMount(t,n)}}(t,n,e)))}function Ur(e,t){ir.push((function(){return t(e)}))}function Gr(e,t,n,i){var r=e.children,o=e.props,s=e.className,a=e.flags,l=e.ref;if(i=i||(32&a)>0,1!==t.nodeType||t.tagName.toLowerCase()!==e.type){qi("Inferno hydration: Server-side markup doesn't match client-side markup or Initial render target is not empty");var c=$r(e,null,n,i);e.dom=c,sr(t.parentNode,c,t)}else{e.dom=t;var h=t.firstChild,u=e.childFlags;if(1&u)Ti(t.firstChild)||function(e,t){return Boolean(t&&t.dangerouslySetInnerHTML&&t.dangerouslySetInnerHTML.__html&&pr(e,t.dangerouslySetInnerHTML.__html))}(t,o)||(t.textContent="",448&a&&(t.defaultValue=""));else{for(var d=null;h;)d=h.nextSibling,8===h.nodeType&&("!"===h.data?t.replaceChild(document.createTextNode(""),h):t.removeChild(h)),h=d;if(h=t.firstChild,2===u)Ti(h)?jr(r,t,n,i):(d=h.nextSibling,Kr(r,h,n,i),h=d);else if(12&u)for(var p=0,f=r.length;p<f;p++){var g=r[p];Ti(h)?jr(g,t,n,i):(d=h.nextSibling,Kr(g,h,n,i),h=d)}for(;h;)d=h.nextSibling,t.removeChild(h),h=d}Ti(o)||Lr(e,a,o,t,i),Mi(s)?""!==t.className&&t.removeAttribute("class"):i?t.setAttribute("class",s):t.className=s,Di(l)?Ur(t,l):Ri(l)&&Pi('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.')}}function Kr(e,t,n,i){var r=e.flags;14&r?function(e,t,n,i,r){var o=e.type,s=e.ref,a=e.props||nr;if(r){var l=Ir(e,o,a,n),c=l.$LI;Kr(c,t,l.$CX,i),e.dom=c.dom,Hr(e,s,l),l.$UPD=!1}else{var h=Fr(o(a,n),e);Kr(h,t,n,i),e.children=h,e.dom=h.dom,Wr(a,s,t)}}(e,t,n,i,(4&r)>0):481&r?Gr(e,t,n,i):16&r?function(e,t){if(3!==t.nodeType){var n=Vr(e,null);e.dom=n,sr(t.parentNode,n,t)}else{var i=e.children;t.nodeValue!==i&&(t.nodeValue=i),e.dom=t}}(e,t):512&r?e.dom=t:(Pi('hydrate() expects a valid VNode, instead it received an object with the type "'+typeof e+'".'),Pi())}function Xr(e,t,n,i,r){Tr(e),sr(n,jr(t,null,i,r),e.dom)}function Yr(e,t,n,i,r){var o=0|t.flags;e.flags!==o||2048&o?Xr(e,t,n,i,r):481&o?function(e,t,n,i,r,o){var s=t.type;if(e.type!==s)Xr(e,t,n,i,r);else{var a,l=e.dom,c=e.props,h=t.props,u=!1,d=!1;if(t.dom=l,r=r||(32&o)>0,c!==h){var p=c||nr;if((a=h||nr)!==nr)for(var f in(u=(448&o)>0)&&(d=Rr(a)),a){var g=p[f],m=a[f];g!==m&&Br(f,g,m,l,r,d,e)}if(p!==nr)for(var y in p)a.hasOwnProperty(y)||Mi(p[y])||Br(y,p[y],null,l,r,d,e)}var v=e.children,w=t.children,b=t.ref,x=e.className,k=t.className;ji(t),4096&o?function(e,t){e.textContent!==t.children&&(e.textContent=t.children)}(l,w):Jr(e.childFlags,t.childFlags,v,w,l,i,r&&"foreignObject"!==s),u&&Ar(o,t,l,a,!1,d),x!==k&&(Mi(k)?l.removeAttribute("class"):r?l.setAttribute("class",k):l.className=k),Di(b)&&e.ref!==b?Ur(l,b):Ri(b)&&Pi('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.')}}(e,t,n,i,r,o):14&o?function(e,t,n,i,r,o){var s=t.type,a=e.key,l=t.key;if(e.type!==s||a!==l)Xr(e,t,n,i,r);else{var c=t.props||nr;if(o){var h=e.children;h.$UPD=!0,h.$V=t,Qr(h,h.state,t,c,n,i,r,!1,!1),h.$UPD=!1}else{var u=!0,d=e.props,p=t.ref,f=!Mi(p),g=e.children;if(t.dom=e.dom,t.children=g,f&&Di(p.onComponentShouldUpdate)&&(u=p.onComponentShouldUpdate(d,c)),!1!==u){f&&Di(p.onComponentWillUpdate)&&p.onComponentWillUpdate(d,c);var m=s(c,i);m!==ki&&(Yr(g,m=Fr(m,t),n,i,r),t.children=m,t.dom=m.dom,f&&Di(p.onComponentDidUpdate)&&p.onComponentDidUpdate(d,c))}else 14&g.flags&&(g.parentVNode=t)}}}(e,t,n,i,r,(4&o)>0):16&o?function(e,t){var n=t.children,i=e.dom;n!==e.children&&(i.nodeValue=n);t.dom=i}(e,t):512&o?t.dom=e.dom:function(e,t,n){var i=e.type,r=t.type,o=t.children;if(Jr(e.childFlags,t.childFlags,e.children,o,i,n,!1),t.dom=e.dom,i!==r&&!Ai(o)){var s=o.dom;i.removeChild(s),r.appendChild(s)}}(e,t,i)}function Jr(e,t,n,i,r,o,s){switch(e){case 2:switch(t){case 2:Yr(n,i,r,o,s);break;case 1:Or(n,r);break;default:Or(n,r),zr(i,r,o,s)}break;case 1:switch(t){case 2:jr(i,r,o,s);break;case 1:break;default:zr(i,r,o,s)}break;default:if(12&t){var a=n.length,l=i.length;0===a?l>0&&zr(i,r,o,s):0===l?Pr(r,n):8===t&&8===e?function(e,t,n,i,r,o,s){var a,l,c=o-1,h=s-1,u=0,d=e[u],p=t[u];e:{for(;d.key===p.key;){if(p.dom&&(t[u]=p=Gi(p)),Yr(d,p,n,i,r),e[u]=p,++u>c||u>h)break e;d=e[u],p=t[u]}for(d=e[c],p=t[h];d.key===p.key;){if(p.dom&&(t[h]=p=Gi(p)),Yr(d,p,n,i,r),e[c]=p,h--,u>--c||u>h)break e;d=e[c],p=t[h]}}if(u>c){if(u<=h)for(var f=(l=h+1)<s?t[l].dom:null;u<=h;)(p=t[u]).dom&&(t[u]=p=Gi(p)),u++,or(n,jr(p,null,i,r),f)}else if(u>h)for(;u<=c;)Or(e[u++],n);else{var g=u,m=u,y=c-u+1,v=h-u+1,w=[];for(a=0;a<v;a++)w.push(0);var b=y===o,x=!1,k=0,_=0;if(s<4||(y|v)<32)for(a=g;a<=c;a++)if(d=e[a],_<v){for(u=m;u<=h;u++)if(p=t[u],d.key===p.key){if(w[u-m]=a+1,b)for(b=!1;a>g;)Or(e[g++],n);k>u?x=!0:k=u,p.dom&&(t[u]=p=Gi(p)),Yr(d,p,n,i,r),_++;break}!b&&u>h&&Or(d,n)}else b||Or(d,n);else{var S={};for(a=m;a<=h;a++)S[t[a].key]=a;for(a=g;a<=c;a++)if(d=e[a],_<v)if(void 0!==(u=S[d.key])){if(b)for(b=!1;a>g;)Or(e[g++],n);p=t[u],w[u-m]=a+1,k>u?x=!0:k=u,p.dom&&(t[u]=p=Gi(p)),Yr(d,p,n,i,r),_++}else b||Or(d,n);else b||Or(d,n)}if(b)Pr(n,e),zr(t,n,i,r);else if(x){var C=function(e){var t,n,i,r,o,s=e.slice(),a=[0],l=e.length;for(t=0;t<l;t++){var c=e[t];if(0!==c){if(e[n=a[a.length-1]]<c){s[t]=n,a.push(t);continue}for(i=0,r=a.length-1;i<r;)e[a[o=(i+r)/2|0]]<c?i=o+1:r=o;c<e[a[i]]&&(i>0&&(s[t]=a[i-1]),a[i]=t)}}i=a.length,r=a[i-1];for(;i-- >0;)a[i]=r,r=s[r];return a}(w);for(u=C.length-1,a=v-1;a>=0;a--)0===w[a]?((p=t[k=a+m]).dom&&(t[k]=p=Gi(p)),l=k+1,or(n,jr(p,null,i,r),l<s?t[l].dom:null)):u<0||a!==C[u]?(l=(k=a+m)+1,or(n,(p=t[k]).dom,l<s?t[l].dom:null)):u--}else if(_!==v)for(a=v-1;a>=0;a--)0===w[a]&&((p=t[k=a+m]).dom&&(t[k]=p=Gi(p)),l=k+1,or(n,jr(p,null,i,r),l<s?t[l].dom:null))}}(n,i,r,o,s,a,l):function(e,t,n,i,r,o,s){for(var a,l,c=o>s?s:o,h=0;h<c;h++)a=t[h],l=e[h],a.dom&&(a=t[h]=Gi(a)),Yr(l,a,n,i,r),e[h]=a;if(o<s)for(h=c;h<s;h++)(a=t[h]).dom&&(a=t[h]=Gi(a)),jr(a,n,i,r);else if(o>s)for(h=c;h<o;h++)Or(e[h],n)}(n,i,r,o,s,a,l)}else 1===t?Pr(r,n):2===t&&(Pr(r,n),jr(i,r,o,s))}}function Qr(e,t,n,i,r,o,s,a,l){var c,h=e.state,u=e.props;if(n.children=e,e.$UN)qi("Inferno Error: Can only update a mounted or mounting component. This usually means you called setState() or forceUpdate() on an unmounted component. This is a no-op.");else{if(u!==i||i===nr){if(!l&&Di(e.componentWillReceiveProps)){if(e.$BR=!0,e.componentWillReceiveProps(i,o),e.$UN)return;e.$BR=!1}e.$PSS&&(t=Bi(t,e.$PS),e.$PSS=!1,e.$PS=null)}var d=Boolean(e.shouldComponentUpdate);if(a||!d||d&&e.shouldComponentUpdate(i,t,o)){Di(e.componentWillUpdate)&&(e.$BS=!0,e.componentWillUpdate(i,t,o),e.$BS=!1),e.props=i,e.state=t,e.context=o,Di(Ji.beforeRender)&&Ji.beforeRender(e),c=e.render(i,t,o),Di(Ji.afterRender)&&Ji
[all...]
H A Ddmn-navigated-viewer.production.min.js2 !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).DmnJS=t()}(this,(function(){"use strict";const e=Object.prototype.toString,t=Object.prototype.hasOwnProperty;function n(e){return void 0!==e}function i(t){return"[object Array]"===e.call(t)}function r(t){return"[object Object]"===e.call(t)}function o(t){return"[object Number]"===e.call(t)}function s(t){const n=e.call(t);return"[object Function]"===n||"[object AsyncFunction]"===n||"[object GeneratorFunction]"===n||"[object AsyncGeneratorFunction]"===n||"[object Proxy]"===n}function a(t){return"[object String]"===e.call(t)}function l(e,n){return!(null==e)&&t.call(e,n)}function c(e,t){const n=v(t);let i;return u(e,(function(e,t){if(n(e,t))return i=e,!1})),i}function h(e,t){const n=v(t);let i=[];return u(e,(function(e,t){n(e,t)&&i.push(e)})),i}function u(e,t){let n,r;if(void 0===e)return;const o=i(e)?w:y;for(let i in e)if(l(e,i)&&(n=e[i],r=t(n,o(i)),!1===r))return n}function d(e,t,n){return u(e,(function(e,i){n=t(n,e,i)})),n}function p(e,t){return!!d(e,(function(e,n,i){return e&&t(n,i)}),!0)}function f(e,t){let n=[];return u(e,(function(e,i){n.push(t(e,i))})),n}function g(e,t){t=function(e){return s(e)?e:t=>t[e]}(t);let n=[];return u(e,(function(e,i){let r=t(e,i),o={d:r,v:e};for(var s=0;s<n.length;s++){let{d:e}=n[s];if(r<e)return void n.splice(s,0,o)}n.push(o)})),f(n,(e=>e.v))}function m(e){return function(t){return p(e,(function(e,n){return t[n]===e}))}}function v(e){return s(e)?e:t=>t===e}function y(e){return e}function w(e){return Number(e)}function b(e,t){let n,i,r,o;function s(n){let s=Date.now(),c=n?0:o+t-s;if(c>0)return a(c);e.apply(r,i),l()}function a(e){n=setTimeout(s,e)}function l(){n&&clearTimeout(n),n=o=i=r=void 0}function c(...e){o=Date.now(),i=e,r=this,n||a(t)}return c.flush=function(){n&&s(!0),l()},c.cancel=l,c}function x(e,t){return e.bind(t)}function _(e,...t){return Object.assign(e,...t)}var S="__fn",k=Array.prototype.slice;function C(){this._listeners={},this.on("diagram.destroy",1,this._destroy,this)}function E(){}C.prototype.on=function(e,t,n,r){if(e=i(e)?e:[e],s(t)&&(r=n,n=t,t=1e3),!o(t))throw new Error("priority must be a number");var a=n;r&&((a=x(n,r))[S]=n[S]||n);var l=this;e.forEach((function(e){l._addListener(e,{priority:t,callback:a,next:null})}))},C.prototype.once=function(e,t,n,i){var r=this;if(s(t)&&(i=n,n=t,t=1e3),!o(t))throw new Error("priority must be a number");function a(){a.__isTomb=!0;var t=n.apply(i,arguments);return r.off(e,a),t}a[S]=n,this.on(e,t,a)},C.prototype.off=function(e,t){e=i(e)?e:[e];var n=this;e.forEach((function(e){n._removeListener(e,t)}))},C.prototype.createEvent=function(e){var t=new E;return t.init(e),t},C.prototype.fire=function(e,t){var n,i,r,o;if(o=k.call(arguments),"object"==typeof e&&(e=(t=e).type),!e)throw new Error("no event type specified");if(i=this._listeners[e]){n=t instanceof E?t:this.createEvent(t),o[0]=n;var s=n.type;e!==s&&(n.type=e);try{r=this._invokeListeners(n,o,i)}finally{e!==s&&(n.type=s)}return void 0===r&&n.defaultPrevented&&(r=!1),r}},C.prototype.handleError=function(e){return!1===this.fire("error",{error:e})},C.prototype._destroy=function(){this._listeners={}},C.prototype._invokeListeners=function(e,t,n){for(var i;n&&!e.cancelBubble;)i=this._invokeListener(e,t,n),n=n.next;return i},C.prototype._invokeListener=function(e,t,n){var i;if(n.callback.__isTomb)return i;try{i=function(e,t){return e.apply(null,t)}(n.callback,t),void 0!==i&&(e.returnValue=i,e.stopPropagation()),!1===i&&e.preventDefault()}catch(e){if(!this.handleError(e))throw console.error("unhandled error in event listener",e),e}return i},C.prototype._addListener=function(e,t){var n,i=this._getListeners(e);if(i){for(;i;){if(i.priority<t.priority)return t.next=i,void(n?n.next=t:this._setListeners(e,t));n=i,i=i.next}n.next=t}else this._setListeners(e,t)},C.prototype._getListeners=function(e){return this._listeners[e]},C.prototype._setListeners=function(e,t){this._listeners[e]=t},C.prototype._removeListener=function(e,t){var n,i,r,o=this._getListeners(e);if(t)for(;o;)n=o.next,(r=o.callback)!==t&&r[S]!==t||(i?i.next=n:this._setListeners(e,n)),i=o,o=n;else this._setListeners(e,null)},E.prototype.stopPropagation=function(){this.cancelBubble=!0},E.prototype.preventDefault=function(){this.defaultPrevented=!0},E.prototype.init=function(e){_(this,e||{})};var M=Object.prototype.toString;function A(){return A=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},A.apply(this,arguments)}function R(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return A.apply(void 0,[e].concat(n))}var T=Object.prototype.toString,D=Object.prototype.hasOwnProperty;function O(e){return"[object String]"===T.call(e)}function N(e,t){return D.call(e,t)}function P(e,t){var n;if(void 0!==e){var i=function(e){return"[object Array]"===T.call(e)}(e)?B:q;for(var r in e)if(N(e,r)&&!1===t(n=e[r],i(r)))return n}}function q(e){return e}function B(e){return Number(e)}function L(e,t){return e.bind(t)}function I(){return I=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},I.apply(this,arguments)}function j(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return I.apply(void 0,[e].concat(n))}function F(){}function V(e,t){this.model=e,this.properties=t}F.prototype.get=function(e){return this.$model.properties.get(this,e)},F.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},V.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(F.prototype);P(e.properties,(function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)})),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function o(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),P(e,L((function(e,t){this.set(t,e)}),this))}return o.prototype=i,o.hasType=i.$instanceOf=this.model.hasType,n.defineModel(o,t),n.defineDescriptor(o,e),o};var $={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},z={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e)}};function H(e,t){var n=z[e];return n?n(t):t}function W(e){return!!$[e]}function U(e){return!!z[e]}function G(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function K(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function X(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,P(e,L(this.registerPackage,this))}function Y(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function J(e){this.model=e}function Q(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function Z(e){this.properties=new J(this),this.factory=new V(this,this.properties),this.registry=new X(e,this.properties),this.typeCache={}}K.prototype.build=function(){return e=this,t=["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"],n={},i=Object(e),P(t,(function(t){t in i&&(n[t]=e[t])})),n;var e,t,n,i},K.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},K.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,o=this.propertiesByName,s=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var a=r.indexOf(e);if(-1===a)throw new Error("property <"+i.name+"> not found in property list");r.splice(a,1),this.addProperty(t,n?void 0:a,s),o[i.name]=o[i.localName]=t},K.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),o=G(r[0],i),s=G(r[1],o.prefix).name,a=this.propertiesByName[s];if(!a)throw new Error("refined property <"+s+"> not found");this.replaceProperty(a,e,n),delete e.redefines},K.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},K.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},K.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},K.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},K.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},K.prototype.hasProperty=function(e){return this.propertiesByName[e]},K.prototype.addTrait=function(e,t){var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(P(e.properties,L((function(n){n=j({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))}),this)),i.push(e),n[r]=e)},X.prototype.getPackage=function(e){return this.packageMap[e]},X.prototype.getPackages=function(){return this.packages},X.prototype.registerPackage=function(e){e=j({},e);var t=this.packageMap;Y(t,e,"prefix"),Y(t,e,"uri"),P(e.types,L((function(t){this.registerType(t,e)}),this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},X.prototype.registerType=function(e,t){var n=G((e=j({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:j(e.meta||{})})).name,t.prefix),i=n.name,r={};P(e.properties,L((function(e){var t=G(e.name,n.prefix),i=t.name;W(e.type)||(e.type=G(e.type,t.prefix).name),j(e,{ns:t,name:i}),r[i]=e}),this)),j(e,{ns:n,name:i,propertiesByName:r}),P(e.extends,L((function(e){var t=this.typeMap[e];t.traits=t.traits||[],t.traits.push(i)}),this)),this.definePackage(e,t),this.typeMap[i]=e},X.prototype.mapTypes=function(e,t,n){var i=W(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function o(e){return s(e,!0)}function s(n,i){var o=G(n,W(n)?"":e.prefix);r.mapTypes(o,t,i)}if(!i)throw new Error("unknown type <"+e.name+">");P(i.superClass,n?o:s),t(i,!n),P(i.traits,o)},X.prototype.getEffectiveDescriptor=function(e){var t=G(e),n=new K(t);this.mapTypes(t,(function(e,t){n.addTrait(e,t)}));var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},X.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},J.prototype.set=function(e,t,n){if(!O(t)||!t.length)throw new TypeError("property name must be a non-empty string");var i=this.model.getPropertyDescriptor(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[t]:i?r in e?e[r]=n:Q(e,i,n):e.$attrs[t]=n},J.prototype.get=function(e,t){var n=this.model.getPropertyDescriptor(e,t);if(!n)return e.$attrs[t];var i=n.name;return!e[i]&&n.isMany&&Q(e,n,[]),e[i]},J.prototype.define=function(e,t,n){if(!n.writable){var i=n.value;delete(n=j({},n,{get:function(){return i}})).value}Object.defineProperty(e,t,n)},J.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},J.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},Z.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},Z.prototype.getType=function(e){var t=this.typeCache,n=O(e)?e:e.ns.name,i=t[n];return i||(e=this.registry.getEffectiveDescriptor(n),i=t[n]=this.factory.createType(e)),i},Z.prototype.createAny=function(e,t,n){var i=G(e),r={$type:e,$instanceOf:function(e){return e===this.$type}},o={name:e,isGeneric:!0,ns:{prefix:i.prefix,localName:i.localName,uri:t}};return this.properties.defineDescriptor(r,o),this.properties.defineModel(r,this),this.properties.define(r,"$parent",{enumerable:!1,writable:!0}),this.properties.define(r,"$instanceOf",{enumerable:!1,writable:!0}),P(n,(function(e,t){var n;n=e,"[object Object]"===T.call(n)&&void 0!==e.value?r[e.name]=e.value:r[t]=e})),r},Z.prototype.getPackage=function(e){return this.registry.getPackage(e)},Z.prototype.getPackages=function(){return this.registry.getPackages()},Z.prototype.getElementDescriptor=function(e){return e.$descriptor},Z.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},Z.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},Z.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var ee=Object.prototype.toString,te=Object.prototype.hasOwnProperty;function ne(e){return"[object Array]"===ee.call(e)}function ie(e){return"[object String]"===ee.call(e)}function re(e,t){return te.call(e,t)}function oe(e,t){var n;return t=le(t),ae(e,(function(e,i){if(t(e,i))return n=e,!1})),n}function se(e,t){var n=[];return ae(e,(function(e,i){t(e,i)&&n.push(e)})),n}function ae(e,t){var n;if(void 0!==e){var i=ne(e)?he:ce;for(var r in e)if(re(e,r)&&!1===t(n=e[r],i(r)))return n}}function le(e){return t=e,"[object Function]"===(n=ee.call(t))||"[object AsyncFunction]"===n||"[object GeneratorFunction]"===n||"[object AsyncGeneratorFunction]"===n||"[object Proxy]"===n?e:function(t){return t===e};var t,n}function ce(e){return e}function he(e){return Number(e)}function ue(){return ue=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},ue.apply(this,arguments)}function de(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return ue.apply(void 0,[e].concat(n))}var pe=String.fromCharCode,fe=Object.prototype.hasOwnProperty,ge=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,me={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function ve(e,t,n,i){return i?fe.call(me,i)?me[i]:"&"+i+";":pe(t||parseInt(n,16))}function ye(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(ge,ve):e}Object.keys(me).forEach((function(e){me[e.toUpperCase()]=me[e]}));var we="xsi:type",be="non-whitespace outside of root node";function xe(e){return new Error(e)}function _e(e){return"missing namespace for prefix <"+e+">"}function Se(e){return{get:e,enumerable:!0}}function ke(e){var t,n={};for(t in e)n[t]=e[t];return n}function Ce(e){return e+"$uri"}function Ee(){return{line:0,column:0}}function Me(e){throw e}function Ae(e){if(!this)return new Ae(e);var t,n,i,r,o,s,a,l,c,h=e&&e.proxy,u=Me,d=Ee,p=!1,f=!1,g=null,m=!1;function v(e){e instanceof Error||(e=xe(e)),g=e,u(e,d)}function y(e){o&&(e instanceof Error||(e=xe(e)),o(e,d))}this.on=function(e,c){if("function"!=typeof c)throw xe("required args <name, cb>");switch(e){case"openTag":n=c;break;case"text":t=c;break;case"closeTag":i=c;break;case"error":u=c;break;case"warn":o=c;break;case"cdata":r=c;break;case"attention":l=c;break;case"question":a=c;break;case"comment":s=c;break;default:throw xe("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw xe("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return n["http://www.w3.org/2001/XMLSchema-instance"]="xsi",f=!0,c=n,this},this.parse=function(e){if("string"!=typeof e)throw xe("required args <xml=string>");return g=null,function(e){var o,u,g,w,b,x,_,S,k,C,E,M=f?[]:null,A=f?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[Ce(n)]=t;return i}(c):null,R=[],T=0,D=!1,O=!1,N=0,P=0,q="",B=0;function L(){if(null!==E)return E;var e,t,n,i,r,o,s,a,l,h,u,d=f&&A.xmlns,g=f&&p?[]:null,m=B,v=q,w=v.length,b={},x={};e:for(;m<w;m++)if(l=!1,!(32===(h=v.charCodeAt(m))||h<14&&h>8)){for((h<65||h>122||h>90&&h<97)&&95!==h&&58!==h&&(y("illegal first char attribute name"),l=!0),u=m+1;u<w;u++)if(!((h=v.charCodeAt(u))>96&&h<123||h>64&&h<91||h>47&&h<59||46===h||45===h||95===h)){if(32===h||h<14&&h>8){y("missing attribute value"),m=u;continue e}if(61===h)break;y("illegal attribute name char"),l=!0}if("xmlns:xmlns"===(a=v.substring(m,u))&&(y("illegal declaration of xmlns"),l=!0),34===(h=v.charCodeAt(u+1)))-1===(u=v.indexOf('"',m=u+2))&&-1!==(u=v.indexOf("'",m))&&(y("attribute value quote missmatch"),l=!0);else if(39===h)-1===(u=v.indexOf("'",m=u+2))&&-1!==(u=v.indexOf('"',m))&&(y("attribute value quote missmatch"),l=!0);else for(y("missing attribute value quotes"),l=!0,u+=1;u<w&&!(32===(h=v.charCodeAt(u+1))||h<14&&h>8);u++);for(-1===u&&(y("missing closing quotes"),u=w,l=!0),l||(o=v.substring(m,u)),m=u;u+1<w&&!(32===(h=v.charCodeAt(u+1))||h<14&&h>8);u++)m===u&&(y("illegal character after attribute end"),l=!0);if(m=u+1,!l)if(a in x)y("attribute <"+a+"> already defined");else if(x[a]=!0,f)if(p){if(null!==(r="xmlns"===a?"xmlns":120===a.charCodeAt(0)&&"xmlns:"===a.substr(0,6)?a.substr(6):null)){if(e=ye(o),t=Ce(r),!(s=c[e])){if("xmlns"===r||t in A&&A[t]!==e)do{s="ns"+T++}while(void 0!==A[s]);else s=r;c[e]=s}A[r]!==s&&(i||(A=ke(A),i=!0),A[r]=s,"xmlns"===r&&(A[Ce(s)]=e,d=s),A[t]=e),b[a]=o;continue}g.push(a,o)}else-1!==(h=a.indexOf(":"))?(n=A[a.substring(0,h)])?((a=d===n?a.substr(h+1):n+a.substr(h))===we&&(-1!==(h=o.indexOf(":"))?(n=o.substring(0,h),o=(n=A[n]||n)+o.substring(h)):o=d+":"+o),b[a]=o):y(_e(a.substring(0,h))):b[a]=o;else b[a]=o}if(p)for(m=0,w=g.length;m<w;m++){if(a=g[m++],o=g[m],-1!==(h=a.indexOf(":"))){if(!(n=A[a.substring(0,h)])){y(_e(a.substring(0,h)));continue}(a=d===n?a.substr(h+1):n+a.substr(h))===we&&(-1!==(h=o.indexOf(":"))?(n=o.substring(0,h),o=(n=A[n]||n)+o.substring(h)):o=d+":"+o)}b[a]=o}return E=b}function I(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,o=0,s=0,a=P;N>=s&&(t=i.exec(e))&&!((a=t[0].length+t.index)>N);)r+=1,s=a;return-1==N?(o=a,n=e.substring(P)):0===P?n=e.substring(P,N):(o=N-s,n=-1==P?e.substring(N):e.substring(N,P+1)),{data:n,line:r,column:o}}d=I,h&&(C=Object.create({},{name:Se((function(){return S})),originalName:Se((function(){return k})),attrs:Se(L),ns:Se((function(){return A}))}));for(;-1!==P;){if(-1===(N=60===e.charCodeAt(P)?P:e.indexOf("<",P)))return R.length?v("unexpected end of file"):0===P?v("missing start tag"):void(P<e.length&&e.substring(P).trim()&&y(be));if(P!==N)if(R.length){if(t&&(t(e.substring(P,N),ye,d),m))return}else if(e.substring(P,N).trim()&&(y(be),m))return;if(33===(b=e.charCodeAt(N+1))){if(91===(w=e.charCodeAt(N+2))&&"CDATA["===e.substr(N+3,6)){if(-1===(P=e.indexOf("]]>",N)))return v("unclosed cdata");if(r&&(r(e.substring(N+9,P),d),m))return;P+=3;continue}if(45===w&&45===e.charCodeAt(N+3)){if(-1===(P=e.indexOf("--\x3e",N)))return v("unclosed comment");if(s&&(s(e.substring(N+4,P),ye,d),m))return;P+=3;continue}}if(63!==b){for(u=N+1;;u++){if(x=e.charCodeAt(u),isNaN(x))return P=-1,v("unclosed tag");if(34===x)u=-1!==(w=e.indexOf('"',u+1))?w:u;else if(39===x)u=-1!==(w=e.indexOf("'",u+1))?w:u;else if(62===x){P=u;break}}if(33!==b){if(E={},47===b){if(D=!1,O=!0,!R.length)return v("missing open tag");if(u=S=R.pop(),w=N+2+u.length,e.substring(N+2,w)!==u)return v("closing tag mismatch");for(;w<P;w++)if(!(32===(b=e.charCodeAt(w))||b>8&&b<14))return v("close tag")}else{if(47===e.charCodeAt(P-1)?(u=S=e.substring(N+1,P-1),D=!0,O=!0):(u=S=e.substring(N+1,P),D=!0,O=!1),!(b>96&&b<123||b>64&&b<91||95===b||58===b))return v("illegal first char nodeName");for(w=1,g=u.length;w<g;w++)if(!((b=u.charCodeAt(w))>96&&b<123||b>64&&b<91||b>47&&b<59||45===b||95===b||46==b)){if(32===b||b<14&&b>8){S=u.substring(0,w),E=null;break}return v("invalid nodeName")}O||R.push(S)}if(f){if(o=A,D&&(O||M.push(o),null===E&&(p=-1!==u.indexOf("xmlns",w))&&(B=w,q=u,L(),p=!1)),k=S,-1!==(b=S.indexOf(":"))){if(!(_=A[S.substring(0,b)]))return v("missing namespace on <"+k+">");S=S.substr(b+1)}else _=A.xmlns;_&&(S=_+":"+S)}if(D&&(B=w,q=u,n&&(h?n(C,ye,O,d):n(S,L,ye,O,d),m)))return;if(O){if(i&&(i(h?C:S,ye,D,d),m))return;f&&(A=D?o:M.pop())}P+=1}else{if(l&&(l(e.substring(N,P+1),ye,d),m))return;P+=1}}else{if(-1===(P=e.indexOf("?>",N)))return v("unclosed question");if(a&&(a(e.substring(N,P+2),d),m))return;P+=2}}}(e),d=Ee,m=!1,g},this.stop=function(){m=!0}}function Re(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var Te={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},De="xsi:type";function Oe(e){return e.xml&&e.xml.serialize}function Ne(e){return Oe(e)===De}function Pe(e,t){return Re(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function qe(e){return new Error(e)}function Be(e){return e.$descriptor}function Le(e){de(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw qe("expected element");var t,n=this.elementsById,i=Be(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw qe("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function Ie(){}function je(){}function Fe(){}function Ve(e,t){this.property=e,this.context=t}function $e(e,t){this.element=t,this.propertyDesc=e}function ze(){}function He(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function We(e,t,n){He.call(this,e,t,n)}function Ue(e,t,n){this.model=e,this.context=n}function Ge(e){e instanceof Z&&(e={model:e}),de(this,{lax:!1},e)}Ie.prototype.handleEnd=function(){},Ie.prototype.handleText=function(){},Ie.prototype.handleNode=function(){},je.prototype=Object.create(Ie.prototype),je.prototype.handleNode=function(){return this},Fe.prototype=Object.create(Ie.prototype),Fe.prototype.handleText=function(e){this.body=(this.body||"")+e},Ve.prototype=Object.create(Fe.prototype),Ve.prototype.handleNode=function(e){if(this.element)throw qe("expected no sub nodes");return this.element=this.createReference(e),this},Ve.prototype.handleEnd=function(){this.element.id=this.body},Ve.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},$e.prototype=Object.create(Fe.prototype),$e.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=H(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},ze.prototype=Object.create(Fe.prototype),ze.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},He.prototype=Object.create(ze.prototype),He.prototype.addReference=function(e){this.context.addReference(e)},He.prototype.handleText=function(e){if(!Be(this.element).bodyProperty)throw qe("unexpected body text <"+e+">");Fe.prototype.handleText.call(this,e)},He.prototype.handleEnd=function(){var e=this.body,t=this.element,n=Be(t).bodyProperty;n&&void 0!==e&&(e=H(n.type,e),t.set(n.name,e))},He.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=Be(i),o=this.context,s=new i({}),a=this.model;return ae(n,(function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?ae(e.split(" "),(function(e){o.addReference({element:s,property:i.ns.name,id:e})})):o.addReference({element:s,property:i.ns.name,id:e}):(i?e=H(i.type,e):"xmlns"!==n&&(t=G(n,r.ns.prefix),a.getPackage(t.prefix)&&o.addWarning({message:"unknown attribute <"+n+">",element:s,property:n,value:e})),s.set(n,e))})),s},He.prototype.getPropertyForNode=function(e){var t,n,i=G(e.name),r=this.type,o=this.model,s=Be(r),a=i.name,l=s.propertiesByName[a];if(l&&!l.isAttr)return Ne(l)&&(t=e.attributes[De])?(t=function(e,t){var n=G(e);return function(e,t){var n=e.name,i=e.localName,r=t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(n,t.getPackage(n.prefix))}(t,o),de({},l,{effectiveType:Be(n=o.getType(t)).name})):l;var c=o.getPackage(i.prefix);if(c){if(t=Pe(i,c),n=o.getType(t),l=oe(s.properties,(function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)})))return de({},l,{effectiveType:Be(n).name})}else if(l=oe(s.properties,(function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type})))return l;throw qe("unrecognized element <"+i.name+">")},He.prototype.toString=function(){return"ElementDescriptor["+Be(this.type).name+"]"},He.prototype.valueHandler=function(e,t){return new $e(e,t)},He.prototype.referenceHandler=function(e){return new Ve(e,this.context)},He.prototype.handler=function(e){return"Element"===e?new Ue(this.model,e,this.context):new He(this.model,e,this.context)},He.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,U(n=t.effectiveType||t.type))return this.valueHandler(t,i);var o=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==o&&(t.isMany?i.get(t.name).push(o):i.set(t.name,o),t.isReference?(de(o,{element:i}),this.context.addReference(o)):o.$parent=i),r},We.prototype=Object.create(He.prototype),We.prototype.createElement=function(e){var t=e.name,n=G(t),i=this.model,r=this.type,o=i.getPackage(n.prefix),s=o&&Pe(n,o)||t;if(!r.hasType(s))throw qe("unexpected element <"+e.originalName+">");return He.prototype.createElement.call(this,e)},Ue.prototype=Object.create(ze.prototype),Ue.prototype.createElement=function(e){var t=e.name,n=G(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},Ue.prototype.handleChild=function(e){var t=new Ue(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},Ue.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},Ge.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof He?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,o=this.lax,s=new Le(de({},t,{rootHandler:i})),a=new Ae({proxy:!0}),l=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function c(e,t,n){var i=t(),r=i.line,o=i.column,a=i.data;"<"===a.charAt(0)&&-1!==a.indexOf(" ")&&(a=a.slice(0,a.indexOf(" "))+">");var l="unparsable content "+(a?a+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+o+"\n\tnested error: "+e.message;if(n)return s.addWarning({message:l,error:e}),!0;throw qe(l)}function h(e,t){return c(e,t,!0)}i.context=s,l.push(i);var u=/^<\?xml /i,d=/ encoding="([^"]+)"/i,p=/^utf-8$/i;function f(e,t){try{l.peek().handleText(e)}catch(e){h(e,t)}}var g=r.getPackages().reduce((function(e,t){return e[t.uri]=t.prefix,e}),{"http://www.w3.org/XML/1998/namespace":"xml"});return a.ns(g).on("openTag",(function(e,t,n,i){var r=e.attrs||{},s=Object.keys(r).reduce((function(e,n){var i=t(r[n]);return e[n]=i,e}),{});!function(e,t){var n=l.peek();try{l.push(n.handleNode(e))}catch(e){c(e,t,o)&&l.push(new je)}}({name:e.name,originalName:e.originalName,attributes:s,ns:e.ns},i)})).on("question",(function(e){if(u.test(e)){var t=d.exec(e),n=t&&t[1];n&&!p.test(n)&&s.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}})).on("closeTag",(function(){l.pop().handleEnd()})).on("cdata",f).on("text",(function(e,t,n){!function(e,t){e.trim()&&f(e,t)}(t(e),n)})).on("error",c).on("warn",h),new Promise((function(t,n){var r;try{a.parse(e),function(){var e,t,n=s.elementsById,i=s.references;for(e=0;t=i[e];e++){var r=t.element,o=n[t.id],a=Be(r).propertiesByName[t.property];if(o||s.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),a.isMany){var l=r.get(a.name),c=l.indexOf(t);-1===c&&(c=l.length),o?l[c]=o:l.splice(c,1)}else r.set(a.name,o)}}()}catch(e){r=e}var o=i.element;r||o||(r=qe("failed to parse document as <"+i.type.$descriptor.name+">"));var l=s.warnings,c=s.references,h=s.elementsById;return r?(r.warnings=l,n(r)):t({rootElement:o,elementsById:h,references:c,warnings:l})}))},Ge.prototype.handler=function(e){return new We(this.model,e)};var Ke=/<|>|'|"|&|\n\r|\n/g,Xe=/<|>|&/g;function Ye(e){var t={},n={},i={},r=[],o=[];this.byUri=function(t){return n[t]||e&&e.byUri(t)},this.add=function(e,t){n[e.uri]=e,t?r.push(e):o.push(e),this.mapPrefix(e.prefix,e.uri)},this.uriByPrefix=function(e){return t[e||"xmlns"]},this.mapPrefix=function(e,n){t[e||"xmlns"]=n},this.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},this.logUsed=function(t){var n=t.uri,r=this.getNSKey(t);i[r]=this.byUri(n),e&&e.logUsed(t)},this.getUsed=function(e){var t=this;return[].concat(r,o).filter((function(e){var n=t.getNSKey(e);return i[n]}))}}function Je(e,t){return Re(t)?function(e){return e.charAt(0).toLowerCase()+e.slice(1)}(e):e}function Qe(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function Ze(e){return ie(e)?e:(e.prefix?e.prefix+":":"")+e.localName}var et={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},tt={"<":"lt",">":"gt","&":"amp"};function nt(e,t,n){return(e=ie(e)?e:""+e).replace(t,(function(e){return"&"+n[e]+";"}))}function it(e){this.tagName=e}function rt(){}function ot(e){this.tagName=e}function st(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function at(e,t){st.call(this,e,t)}function lt(){this.value="",this.write=function(e){this.value+=e}}function ct(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function ht(e){return e=de({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new lt,r=new ct(i,e.format);if(e.preamble&&r.append('<?xml version="1.0" encoding="UTF-8"?>\n'),(new st).build(t).serializeTo(r),!n)return i.value}}}function ut(e,t){Z.call(this,e,t)}it.prototype.build=function(e){return this.element=e,this},it.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},rt.prototype.serializeValue=rt.prototype.serializeTo=function(e){e.append(this.escape?nt(this.value,Xe,tt):this.value)},rt.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(Xe)&&(this.escape=!0),this},Qe(ot,rt),ot.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},st.prototype.build=function(e){this.element=e;var t,n,i=e.$descriptor,r=this.propertyDescriptor,o=i.isGeneric;return t=o?this.parseGeneric(e):this.parseNsAttributes(e),this.ns=r?this.nsPropertyTagName(r):this.nsTagName(i),this.tagName=this.addTagName(this.ns),o||(n=function(e){return se(e.$descriptor.properties,(function(t){var n=t.name;if(t.isVirtual)return!1;if(!re(e,n))return!1;var i=e[n];return i!==t.default&&null!==i&&(!t.isMany||i.length)}))}(e),this.parseAttributes(se(n,(function(e){return e.isAttr}))),this.parseContainments(function(e){return se(e,(function(e){return!e.isAttr}))}(n))),this.parseGenericAttributes(e,t),this},st.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?de({localName:t.ns.localName},e):de({localName:Je(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},st.prototype.nsPropertyTagName=function(e){return function(e,t){return de({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},st.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},st.prototype.nsAttributeName=function(e){var t;if(t=ie(e)?G(e):e.ns,e.inherited)return{localName:t.localName};var n=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(n),this.isLocalNs(n)?{localName:t.localName}:de({localName:t.localName},n)},st.prototype.parseGeneric=function(e){var t=this,n=this.body,i=[];return ae(e,(function(r,o){"$body"===o?n.push((new rt).build({type:"String"},r)):"$children"===o?ae(r,(function(e){n.push(new st(t).build(e))})):0!==o.indexOf("$")&&t.parseNsAttribute(e,o,r)&&i.push({name:o,value:r})})),i},st.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,o=G(t);if("xmlns"===o.prefix&&(i={prefix:o.localName,uri:n}),o.prefix||"xmlns"!==o.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var s=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(s)}},st.prototype.parseNsAttributes=function(e,t){var n=this,i=e.$attrs,r=[];return ae(i,(function(t,i){var o=n.parseNsAttribute(e,i,t);o&&r.push(o)})),r},st.prototype.parseGenericAttributes=function(e,t){var n=this;ae(t,(function(t){if(t.name!==De)try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){console.warn("missing namespace information for ",t.name,"=",t.value,"on",e,n)}}))},st.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;ae(e,(function(e){var r=i.get(e.name),o=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new rt).build(e,r[0]));else if(U(e.type))ae(r,(function(i){n.push(new ot(t.addTagName(t.nsPropertyTagName(e))).build(e,i))}));else if(o)ae(r,(function(i){n.push(new it(t.addTagName(t.nsPropertyTagName(e))).build(i))}));else{var s=Ne(e),a=function(e){return"property"===Oe(e)}(e);ae(r,(function(i){var r;r=s?new at(t,e):a?new st(t,e):new st(t),n.push(r.build(i))}))}}))},st.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new Ye(t):n=t),n},st.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,o=e.prefix;return i.byUri(r)&&!n||i.add(e,t),i.mapPrefix(o,r),e},st.prototype.logNamespaceUsed=function(e,t){var n,i,r,o=this.element.$model,s=this.getNamespaces(t),a=e.prefix,l=e.uri;if(!a&&!l)return{localName:e.localName};if(r=Te[a]||o&&(o.getPackage(a)||{}).uri,!(l=l||r||s.uriByPrefix(a)))throw new Error("no namespace uri given for prefix <"+a+">");if(!(e=s.byUri(l))){for(n=a,i=1;s.uriByPrefix(n);)n=a+"_"+i++;e=this.logNamespace({prefix:n,uri:l},r===l)}return a&&s.mapPrefix(a,l),e},st.prototype.parseAttributes=function(e){var t=this,n=this.element;ae(e,(function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];ae(i,(function(e){r.push(e.id)})),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)}))},st.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),Ze(e)},st.prototype.addAttribute=function(e,t){var n=this.attrs;ie(t)&&(t=nt(t,Ke,et));var i=function(e,t){t=le(t);var n=ne(e)?-1:void 0;return ae(e,(function(e,i){if(t(e,i))return n=i,!1})),n}(n,(function(t){return t.name.localName===e.localName&&t.name.uri===e.uri&&t.name.prefix===e.prefix})),r={name:e,value:t};-1!==i?n.splice(i,1,r):n.push(r)},st.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=function(e){return e.getUsed().filter((function(e){return"xml"!==e.prefix})).map((function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}}))}(n).concat(t)),ae(t,(function(t){e.append(" ").append(Ze(t.name)).append('="').append(t.value).append('"')}))},st.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==rt;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),ae(this.body,(function(t){t.serializeTo(e)})),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},Qe(at,st),at.prototype.parseNsAttributes=function(e){var t=st.prototype.parseNsAttributes.call(this,e),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),o=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(De),(i.prefix?i.prefix+":":"")+o+n.ns.localName),t},at.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},ut.prototype=Object.create(Z.prototype),ut.prototype.fromXML=function(e,t,n){var i;i=t,"[object String]"!==M.call(i)&&(n=t,t="dmn:Definitions");var r=new Ge(R({model:this,lax:!0},n)),o=r.handler(t);return r.fromXML(e,o)},ut.prototype.toXML=function(e,t){var n=new ht(t);return new Promise((function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}}))};var dt={dc:{name:"DC",prefix:"dc",uri:"http://www.omg.org/spec/DMN/20180521/DC/",types:[{name:"Dimension",properties:[{name:"width",isAttr:!0,type:"Real"},{name:"height",isAttr:!0,type:"Real"}]},{name:"Bounds",properties:[{name:"height",isAttr:!0,type:"Real"},{name:"width",isAttr:!0,type:"Real"},{name:"x",isAttr:!0,type:"Real"},{name:"y",isAttr:!0,type:"Real"}]},{name:"Point",properties:[{name:"x",isAttr:!0,type:"Real"},{name:"y",isAttr:!0,type:"Real"}]},{name:"Color",properties:[{name:"red",type:"UML_Standard_Profile.mdzip:eee_1045467100323_917313_65"},{name:"green",type:"UML_Standard_Profile.mdzip:eee_1045467100323_917313_65"},{name:"blue",type:"UML_Standard_Profile.mdzip:eee_1045467100323_917313_65"}]}],associations:[],enumerations:[{name:"AlignmentKind",literalValues:[{name:"start"},{name:"center"},{name:"end"}]}]},di:{name:"DI",prefix:"di",uri:"http://www.omg.org/spec/DMN/20180521/DI/",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"extension",type:"Extension"},{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"style",isReference:!0,type:"Style",xml:{serialize:"property"}},{name:"sharedStyle",isReference:!0,isVirtual:!0,type:"Style"}]},{name:"Diagram",superClass:["DiagramElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"}]},{name:"Shape",isAbstract:!0,properties:[{name:"bounds",type:"dc:Bounds"}],superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,properties:[{name:"waypoint",type:"dc:Point",isMany:!0,xml:{serialize:"property"}}],superClass:["DiagramElement"]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],enumerations:[],xml:{tagAlias:"lowerCase"}},dmn:{name:"DMN",prefix:"dmn",uri:"https://www.omg.org/spec/DMN/20191111/MODEL/",types:[{name:"AuthorityRequirement",superClass:["DMNElement"],properties:[{name:"requiredAuthority",type:"DMNElementReference",xml:{serialize:"property"}},{name:"requiredDecision",type:"DMNElementReference",xml:{serialize:"property"}},{name:"requiredInput",type:"DMNElementReference",xml:{serialize:"property"}}]},{name:"ItemDefinition",superClass:["NamedElement"],properties:[{name:"typeRef",type:"String"},{name:"allowedValues",type:"UnaryTests",xml:{serialize:"property"}},{name:"typeLanguage",type:"String",isAttr:!0},{name:"itemComponent",type:"ItemDefinition",isMany:!0,xml:{serialize:"property"}},{name:"functionItem",type:"FunctionItem"},{name:"isCollection",isAttr:!0,type:"Boolean"}]},{name:"Definitions",superClass:["NamedElement"],properties:[{name:"import",type:"Import",isMany:!0},{name:"itemDefinition",type:"ItemDefinition",isMany:!0},{name:"drgElement",type:"DRGElement",isMany:!0},{name:"artifact",type:"Artifact",isMany:!0},{name:"elementCollection",type:"ElementCollection",isMany:!0},{name:"businessContextElement",type:"BusinessContextElement",isMany:!0},{name:"namespace",type:"String",isAttr:!0},{name:"expressionLanguage",type:"String",isAttr:!0},{name:"typeLanguage",type:"String",isAttr:!0},{name:"exporter",isAttr:!0,type:"String"},{name:"exporterVersion",isAttr:!0,type:"String"},{name:"dmnDI",type:"dmndi:DMNDI"}]},{name:"KnowledgeSource",superClass:["DRGElement"],properties:[{name:"authorityRequirement",type:"AuthorityRequirement",isMany:!0},{name:"type",type:"String"},{name:"owner",type:"DMNElementReference",xml:{serialize:"property"}},{name:"locationURI",type:"String",isAttr:!0}]},{name:"DecisionRule",superClass:["DMNElement"],properties:[{name:"inputEntry",type:"UnaryTests",isMany:!0,xml:{serialize:"property"}},{name:"outputEntry",type:"LiteralExpression",isMany:!0,xml:{serialize:"property"}},{name:"annotationEntry",type:"RuleAnnotation",isMany:!0,xml:{serialize:"property"}}]},{name:"Expression",isAbstract:!0,superClass:["DMNElement"],properties:[{name:"typeRef",isAttr:!0,type:"String"}]},{name:"InformationItem",superClass:["NamedElement"],properties:[{name:"typeRef",isAttr:!0,type:"String"}]},{name:"Decision",superClass:["DRGElement"],properties:[{name:"question",type:"String",xml:{serialize:"property"}},{name:"allowedAnswers",type:"String",xml:{serialize:"property"}},{name:"variable",type:"InformationItem",xml:{serialize:"property"}},{name:"informationRequirement",type:"InformationRequirement",isMany:!0},{name:"knowledgeRequirement",type:"KnowledgeRequirement",isMany:!0},{name:"authorityRequirement",type:"AuthorityRequirement",isMany:!0},{name:"supportedObjective",isMany:!0,type:"DMNElementReference",xml:{serialize:"property"}},{name:"impactedPerformanceIndicator",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"decisionMaker",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"decisionOwner",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"usingProcess",isMany:!0,type:"DMNElementReference",xml:{serialize:"property"}},{name:"usingTask",isMany:!0,type:"DMNElementReference",xml:{serialize:"property"}},{name:"decisionLogic",type:"Expression"}]},{name:"Invocation",superClass:["Expression"],properties:[{name:"calledFunction",type:"Expression"},{name:"binding",type:"Binding",isMany:!0}]},{name:"OrganisationalUnit",superClass:["BusinessContextElement"],properties:[{name:"decisionMade",type:"Decision",isReference:!0,isMany:!0},{name:"decisionOwned",type:"Decision",isReference:!0,isMany:!0}]},{name:"Import",superClass:["NamedElement"],properties:[{name:"importType",type:"String",isAttr:!0},{name:"locationURI",type:"String",isAttr:!0},{name:"namespace",type:"String",isAttr:!0}]},{name:"InformationRequirement",superClass:["DMNElement"],properties:[{name:"requiredDecision",type:"DMNElementReference",xml:{serialize:"property"}},{name:"requiredInput",type:"DMNElementReference",xml:{serialize:"property"}}]},{name:"ElementCollection",superClass:["NamedElement"],properties:[{name:"drgElement",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}}]},{name:"DRGElement",isAbstract:!0,superClass:["NamedElement"],properties:[]},{name:"InputData",superClass:["DRGElement"],properties:[{name:"variable",type:"InformationItem",xml:{serialize:"property"}}]},{name:"DMNElement",isAbstract:!0,properties:[{name:"description",type:"String"},{name:"extensionElements",type:"ExtensionElements"},{name:"id",type:"String",isAttr:!0,isId:!0},{name:"extensionAttribute",type:"ExtensionAttribute",isMany:!0},{name:"label",isAttr:!0,type:"String"}]},{name:"InputClause",superClass:["DMNElement"],properties:[{name:"inputExpression",type:"LiteralExpression",xml:{serialize:"property"}},{name:"inputValues",type:"UnaryTests",xml:{serialize:"property"}}]},{name:"DecisionTable",superClass:["Expression"],properties:[{name:"input",type:"InputClause",isMany:!0,xml:{serialize:"property"}},{name:"output",type:"OutputClause",isMany:!0,xml:{serialize:"property"}},{name:"annotation",type:"RuleAnnotationClause",isMany:!0,xml:{serialize:"property"}},{name:"rule",type:"DecisionRule",isMany:!0,xml:{serialize:"property"}},{name:"hitPolicy",type:"HitPolicy",isAttr:!0,default:"UNIQUE"},{name:"aggregation",type:"BuiltinAggregator",isAttr:!0},{name:"preferredOrientation",type:"DecisionTableOrientation",isAttr:!0},{name:"outputLabel",isAttr:!0,type:"String"}]},{name:"LiteralExpression",superClass:["Expression"],properties:[{name:"expressionLanguage",type:"String",isAttr:!0},{name:"text",type:"String"},{name:"importedValues",type:"ImportedValues"}]},{name:"Binding",properties:[{name:"parameter",type:"InformationItem",xml:{serialize:"property"}},{name:"bindingFormula",type:"Expression"}]},{name:"KnowledgeRequirement",superClass:["DMNElement"],properties:[{name:"requiredKnowledge",type:"DMNElementReference",xml:{serialize:"property"}}]},{name:"BusinessKnowledgeModel",superClass:["Invocable"],properties:[{name:"encapsulatedLogic",type:"FunctionDefinition",xml:{serialize:"property"}},{name:"knowledgeRequirement",type:"KnowledgeRequirement",isMany:!0},{name:"authorityRequirement",type:"AuthorityRequirement",isMany:!0}]},{name:"BusinessContextElement",isAbstract:!0,superClass:["NamedElement"],properties:[{name:"URI",type:"String",isAttr:!0}]},{name:"PerformanceIndicator",superClass:["BusinessContextElement"],properties:[{name:"impactingDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}}]},{name:"FunctionDefinition",superClass:["Expression"],properties:[{name:"formalParameter",type:"InformationItem",isMany:!0,xml:{serialize:"property"}},{name:"body",type:"Expression"},{name:"kind",type:"FunctionKind",isAttr:!0}]},{name:"Context",superClass:["Expression"],properties:[{name:"contextEntry",type:"ContextEntry",isMany:!0}]},{name:"ContextEntry",superClass:["DMNElement"],properties:[{name:"variable",type:"InformationItem",xml:{serialize:"property"}},{name:"value",type:"Expression"}]},{name:"List",superClass:["Expression"],properties:[{name:"elements",isMany:!0,type:"Expression"}]},{name:"Relation",superClass:["Expression"],properties:[{name:"column",type:"InformationItem",isMany:!0,xml:{serialize:"property"}},{name:"row",type:"List",isMany:!0,xml:{serialize:"property"}}]},{name:"OutputClause",superClass:["DMNElement"],properties:[{name:"outputValues",type:"UnaryTests",xml:{serialize:"property"}},{name:"defaultOutputEntry",type:"LiteralExpression",xml:{serialize:"property"}},{name:"name",isAttr:!0,type:"String"},{name:"typeRef",isAttr:!0,type:"String"}]},{name:"UnaryTests",superClass:["Expression"],properties:[{name:"text",type:"String"},{name:"expressionLanguage",type:"String",isAttr:!0}]},{name:"NamedElement",isAbstract:!0,superClass:["DMNElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ImportedValues",superClass:["Import"],properties:[{name:"importedElement",type:"String"},{name:"expressionLanguage",type:"String",isAttr:!0}]},{name:"DecisionService",superClass:["Invocable"],properties:[{name:"outputDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"encapsulatedDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"inputDecision",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}},{name:"inputData",type:"DMNElementReference",isMany:!0,xml:{serialize:"property"}}]},{name:"ExtensionElements",properties:[{name:"values",type:"Element",isMany:!0}]},{name:"ExtensionAttribute",properties:[{name:"value",type:"Element"},{name:"valueRef",type:"Element",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Element",isAbstract:!0,properties:[{name:"extensionAttribute",type:"ExtensionAttribute",isAttr:!0,isReference:!0},{name:"elements",type:"ExtensionElements",isAttr:!0,isReference:!0}]},{name:"Artifact",isAbstract:!0,superClass:["DMNElement"],properties:[]},{name:"Association",superClass:["Artifact"],properties:[{name:"sourceRef",type:"DMNElementReference",xml:{serialize:"property"}},{name:"targetRef",type:"DMNElementReference",xml:{serialize:"property"}},{name:"associationDirection",type:"AssociationDirection",isAttr:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",isAttr:!0,type:"String",default:"text/plain"}]},{name:"RuleAnnotationClause",properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"RuleAnnotation",properties:[{name:"text",type:"String"}]},{name:"Invocable",isAbstract:!0,superClass:["DRGElement"],properties:[{name:"variable",type:"InformationItem",xml:{serialize:"property"}}]},{name:"Group",superClass:["Artifact"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"FunctionItem",superClass:["DMNElement"],properties:[{name:"parameters",isMany:!0,type:"InformationItem",xml:{serialize:"property"}},{name:"outputTypeRef",isAttr:!0,type:"String"}]},{name:"DMNElementReference",properties:[{isAttr:!0,name:"href",type:"String"}]}],enumerations:[{name:"HitPolicy",literalValues:[{name:"UNIQUE"},{name:"FIRST"},{name:"PRIORITY"},{name:"ANY"},{name:"COLLECT"},{name:"RULE ORDER"},{name:"OUTPUT ORDER"}]},{name:"BuiltinAggregator",literalValues:[{name:"SUM"},{name:"COUNT"},{name:"MIN"},{name:"MAX"}]},{name:"DecisionTableOrientation",literalValues:[{name:"Rule-as-Row"},{name:"Rule-as-Column"},{name:"CrossTable"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"FunctionKind",literalValues:[{name:"FEEL"},{name:"Java"},{name:"PMML"}]}],associations:[],xml:{tagAlias:"lowerCase"}},dmndi:{name:"DMNDI",prefix:"dmndi",uri:"https://www.omg.org/spec/DMN/20191111/DMNDI/",types:[{name:"DMNDI",properties:[{name:"diagrams",type:"DMNDiagram",isMany:!0},{name:"styles",type:"DMNStyle",isMany:!0}]},{name:"DMNStyle",superClass:["di:Style"],properties:[{name:"fillColor",type:"dc:Color",isAttr:!0},{name:"strokeColor",type:"dc:Color",isAttr:!0},{name:"fontColor",type:"dc:Color",isAttr:!0},{name:"fontSize",isAttr:!0,type:"Real"},{name:"fontFamily",isAttr:!0,type:"String"},{name:"fontItalic",isAttr:!0,type:"Boolean"},{name:"fontBold",isAttr:!0,type:"Boolean"},{name:"fontUnderline",isAttr:!0,type:"Boolean"},{name:"fontStrikeThrough",isAttr:!0,type:"Boolean"},{name:"labelHorizontalAlignment",type:"dc:AlignmentKind",isAttr:!0},{name:"labelVerticalAlignment",type:"dc:AlignmentKind",isAttr:!0}]},{name:"DMNDiagram",superClass:["di:Diagram"],properties:[{name:"dmnElementRef",type:"dmn:DMNElement",isAttr:!0,isReference:!0},{name:"size",type:"Size"},{name:"localStyle",type:"DMNStyle",isVirtual:!0},{name:"sharedStyle",type:"DMNStyle",isVirtual:!0,isReference:!0,redefines:"di:DiagramElement#sharedStyle"},{name:"diagramElements",type:"DMNDiagramElement",isMany:!0}]},{name:"DMNDiagramElement",isAbstract:!0,superClass:["di:DiagramElement"],properties:[{name:"dmnElementRef",type:"dmn:DMNElement",isAttr:!0,isReference:!0},{name:"sharedStyle",type:"DMNStyle",isVirtual:!0,isReference:!0,redefines:"di:DiagramElement#sharedStyle"},{name:"localStyle",type:"DMNStyle",isVirtual:!0},{name:"label",type:"DMNLabel"}]},{name:"DMNLabel",superClass:["di:Shape"],properties:[{name:"text",type:"Text"}]},{name:"DMNShape",superClass:["di:Shape","DMNDiagramElement"],properties:[{name:"isListedInputData",isAttr:!0,type:"Boolean"},{name:"decisionServiceDividerLine",type:"DMNDecisionServiceDividerLine"},{name:"isCollapsed",isAttr:!0,type:"Boolean"}]},{name:"DMNEdge",superClass:["di:Edge","DMNDiagramElement"],properties:[{name:"sourceElement",type:"DMNDiagramElement",isAttr:!0,isReference:!0},{name:"targetElement",type:"DMNDiagramElement",isAttr:!0,isReference:!0}]},{name:"DMNDecisionServiceDividerLine",superClass:["di:Edge"]},{name:"Text",properties:[{name:"text",isBody:!0,type:"String"}]},{name:"Size",superClass:["dc:Dimension"]}],associations:[],enumerations:[]},biodi:{name:"bpmn.io DI for DMN",uri:"http://bpmn.io/schema/dmn/biodi/2.0",prefix:"biodi",xml:{tagAlias:"lowerCase"},types:[{name:"DecisionTable",isAbstract:!0,extends:["dmn:DecisionTable"],properties:[{name:"annotationsWidth",isAttr:!0,type:"Integer"}]},{name:"OutputClause",isAbstract:!0,extends:["dmn:OutputClause"],properties:[{name:"width",isAttr:!0,type:"Integer"}]},{name:"InputClause",isAbstract:!0,extends:["dmn:InputClause"],properties:[{name:"width",isAttr:!0,type:"Integer"}]}]}};function pt(e,t){return new ut(R({},dt,e),t)}function ft(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}const gt=Object.prototype.toString,mt=Object.prototype.hasOwnProperty;function vt(e,t){return mt.call(e,t)}function yt(e,t){let n,i;if(void 0===e)return;const r=function(e){return"[object Array]"===gt.call(e)}(e)?bt:wt;for(let o in e)if(vt(e,o)&&(n=e[o],i=t(n,r(o)),!1===i))return n}function wt(e){return e}function bt(e){return Number(e)}function xt(e,...t){const n=e.style;return yt(t,(function(e){e&&yt(e,(function(e,t){n[t]=e}))})),e}function _t(e,t,n){return 2==arguments.length?e.getAttribute(t):null===n?e.removeAttribute(t):(e.setAttribute(t,n),e)}const St=Object.prototype.toString;function kt(e){return new Ct(e)}function Ct(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}function Et(e){for(var t;t=e.firstChild;)e.removeChild(t);return e}function Mt(e,t,n){var i=n?e:e.parentNode;return i&&"function"==typeof i.closest&&i.closest(t)||null}Ct.prototype.add=function(e){return this.list.add(e),this},Ct.prototype.remove=function(e){return"[object RegExp]"==St.call(e)?this.removeMatching(e):(this.list.remove(e),this)},Ct.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Ct.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Ct.prototype.array=function(){return Array.from(this.list)},Ct.prototype.has=Ct.prototype.contains=function(e){return this.list.contains(e)};var At,Rt,Tt,Dt={};function Ot(){At=window.addEventListener?"addEventListener":"attachEvent",Rt=window.removeEventListener?"removeEventListener":"detachEvent",Tt="addEventListener"!==At?"on":""}var Nt=ft({__proto__:null,bind:Dt.bind=function(e,t,n,i){return At||Ot(),e[At](Tt+t,n,i||!1),n},unbind:Dt.unbind=function(e,t,n,i){return Rt||Ot(),e[Rt](Tt+t,n,i||!1),n},default:Dt},[Dt]),Pt=["focus","blur"];var qt,Bt={bind:function(e,t,n,i,r){return-1!==Pt.indexOf(n)&&(r=!0),Nt.bind(e,n,(function(n){var r=n.target||n.srcElement;n.delegateTarget=Mt(r,t,!0),n.delegateTarget&&i.call(e,n)}),r)},unbind:function(e,t,n,i){return-1!==Pt.indexOf(t)&&(i=!0),Nt.unbind(e,t,n,i)}},Lt=function(e,t){if("string"!=typeof e)throw new TypeError("String expected");t||(t=document);var n=/<([\w:]+)/.exec(e);if(!n)return t.createTextNode(e);e=e.replace(/^\s+|\s+$/g,"");var i=n[1];if("body"==i){return(l=t.createElement("html")).innerHTML=e,l.removeChild(l.lastChild)}var r=Object.prototype.hasOwnProperty.call(jt,i)?jt[i]:jt._default,o=r[0],s=r[1],a=r[2],l=t.createElement("div");l.innerHTML=s+e+a;for(;o--;)l=l.lastChild;if(l.firstChild==l.lastChild)return l.removeChild(l.firstChild);var c=t.createDocumentFragment();for(;l.firstChild;)c.appendChild(l.removeChild(l.firstChild));return c},It=!1;"undefined"!=typeof document&&((qt=document.createElement("div")).innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',It=!qt.getElementsByTagName("link").length,qt=void 0);var jt={legend:[1,"<fieldset>","</fieldset>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],_default:It?[1,"X<div>","</div>"]:[0,"",""]};jt.td=jt.th=[3,"<table><tbody><tr>","</tr></tbody></table>"],jt.option=jt.optgroup=[1,'<select multiple="multiple">',"</select>"],jt.thead=jt.tbody=jt.colgroup=jt.caption=jt.tfoot=[1,"<table>","</table>"],jt.polyline=jt.ellipse=jt.polygon=jt.circle=jt.text=jt.line=jt.path=jt.rect=jt.g=[1,'<svg xmlns="http://www.w3.org/2000/svg" version="1.1">',"</svg>"];var Ft=Lt;function Vt(e,t){return(t=t||document).querySelector(e)}function $t(e){e.parentNode&&e.parentNode.removeChild(e)}function zt(e){return function(){if(!window.Promise)throw new Error("Promises is not supported in this environment. Please polyfill Promise.");var t=arguments.length;if(!(t>=1&&s(arguments[t-1])))return e.apply(this,arguments);var n=arguments[t-1];console.warn(new Error("Passing callbacks to "+function(e){return e.replace("bound ","")}(e.name)+" is deprecated and will be removed in a future major release. Please switch to promises: https://bpmn.io/l/moving-to-promises.html"));var i=Array.prototype.slice.call(arguments,0,-1);e.apply(this,i).then((function(e){var t=Object.keys(e)[0];return n(null,e[t])}),(function(e){return n(e,e.warnings)}))}}const Ht={width:"100%",height:"100%",position:"relative"};class Wt{constructor(e={}){this._eventBus=new C,this._viewsChanged=b(this._viewsChanged,0),this._views=[],this._viewers={},this.open=zt(this.open.bind(this)),this.importXML=zt(this.importXML.bind(this)),this.saveXML=zt(this.saveXML.bind(this)),this._init(e)}importXML(e,t){var n=this;return t=t||{open:!0},new Promise((function(r,o){var s=n._activeView;n._clear().then((()=>{var a;e=n._emit("import.parse.start",{xml:e})||e,n._moddle.fromXML(e,"dmn:Definitions").then((e=>{var l=e.rootElement,c=e.references,h=e.elementsById;if(a=e.warnings,l=n._emit("import.parse.complete",i({error:null,definitions:l,elementsById:h,references:c,warnings:a}))||l,n._setDefinitions(l),!t.open)return n._emit("import.done",{error:null,warnings:a}),void r({warnings:a});var u=n._getInitialView(n._views,s);if(!u){var d=new Error("no displayable contents");return n._emit("import.done",{error:d,warnings:a}),d.warnings=a,o(d)}n.open(u).then((e=>({warnings:e.warnings}))).catch((e=>({error:e,warnings:e.warnings}))).then((e=>{var t=[].concat(a,e.warnings);n._emit("import.done",{error:e.error,warnings:t}),e.error?(e.error.warnings=t,o(e.error)):r({warnings:t})}))})).catch((t=>(a=t.warnings,t=function(e,t){if("failed to parse document as <dmn:Definitions>"!==e.message)return null;var n=-1!==t.indexOf('"http://www.omg.org/spec/DMN/20151101/dmn.xsd"')?"1.1":-1!==t.indexOf('"http://www.omg.org/spec/DMN/20180521/MODEL/"')&&"1.2";if(!n)return null;return e=new Error("unsupported DMN "+n+" file detected; only DMN 1.3 files can be opened"),console.error("Cannot open what looks like a DMN "+n+" diagram. Please refer to https://bpmn.io/l/dmn-compatibility.html to learn how to make the toolkit compatible with older DMN files",e),e}(t,e)||function(e){var t=/unparsable content <([^>]+)> detected([\s\S]*)$/.exec(e.message);if(!t)return null;return e.message="unparsable content <"+t[1]+"> detected; this may indicate an invalid DMN 1.3 diagram file"+t[2],e}(t)||t,n._emit("import.parse.complete",i({error:t,warnings:a})),n._emit("import.done",{error:t,warnings:a}),t.warnings=a,o(t))))})).catch((e=>(n._emit("import.done",{error:e,warnings:[]}),e.warnings=[],o(e))))}));function i(e){var t=n._eventBus.createEvent(e);return Object.defineProperty(t,"context",{enumerable:!0,get:function(){return console.warn(new Error("import.parse.complete <context> is deprecated and will be removed in future library versions")),{warnings:e.warnings,references:e.references,elementsById:e.elementsById}}}),t}}getDefinitions(){return this._definitions}getActiveView(){return this._activeView}getActiveViewer(){var e=this.getActiveView();return e&&this._getViewer(e)}getView(e){return this._views.filter((function(t){return t.element===e}))[0]}getViews(){return this._views}saveXML(e){var t=this;e=e||{};var n=this._definitions;return new Promise((function(i,r){n?(n=t._emit("saveXML.start",{definitions:n})||n,t._moddle.toXML(n,e).then((function(e){var n=e.xml;return{xml:n=t._emit("saveXML.serialized",{xml:n})||n}})).catch((e=>({error:e}))).then((e=>{t._emit("saveXML.done",e),e.error?r(e.error):i({xml:e.xml})}))):r(new Error("no definitions loaded"))}))}on(...e){this._eventBus.on(...e)}off(...e){this._eventBus.off(...e)}once(...e){this._eventBus.once(...e)}attachTo(e){e.get&&e.constructor.prototype.jquery&&(e=e.get(0)),"string"==typeof e&&(e=Vt(e)),e.appendChild(this._container),this._emit("attach",{})}detach(){this._emit("detach",{}),$t(this._container)}destroy(){Object.keys(this._viewers).forEach((e=>{Xt(this._viewers[e],"destroy")})),$t(this._container)}_init(e){this._options=e,this._moddle=this._createModdle(e),this._viewers={},this._views=[];const t=Ft('<div class="dmn-js-parent"></div>'),n=_({},Ht,e);_(t.style,{width:Ut(n.width),height:Ut(n.height),position:n.position}),this._container=t,e.container&&this.attachTo(e.container)}_clear(){return this._switchView(null)}open(e){return this._switchView(e)}_setDefinitions(e){this._definitions=e,this._updateViews()}_viewsChanged=()=>{this._emit("views.changed",{views:this._views,activeView:this._activeView})};_updateViews(){var e=this._definitions;if(!e)return this._views=[],void this._switchView(null);var t=this._getViewProviders(),n=[e,...e.drgElement||[]],i=this._views,r=[];for(var o of n){var s=c(t,(function(e){return"string"==typeof e.opens?e.opens===o.$type:e.opens(o)}));if(s){var a={element:o,id:o.id,name:o.name,type:s.id};r.push(a)}}var l,h=this._activeView;if(!h||(l=c(r,(function(e){return Gt(h,e)}))||this._getInitialView(r),l)){var u=!Gt(h,l)||Kt(h,l),d=i.length!==r.length||!p(r,(function(e){return c(i,(function(t){return Gt(t,e)&&!Kt(t,e)}))}));this._activeView=l,this._views=r,(u||d)&&this._viewsChanged()}else this._switchView(null)}_getInitialView(e,t){var n;return t&&(n=c(e,(function(e){return Gt(e,t)}))||c(e,(function(e){return e.type===t}))),n||e[0]}_switchView(e){var t=this;return new Promise((function(n,i){var r,o=(e,r)=>{t._viewsChanged(),e?i(e):n(r)},s=t.getActiveView(),a=e&&t._getViewer(e),l=e&&e.element;if(s&&(r=t._getViewer(s))!==a&&(Xt(r,"clear"),r.detach()),t._activeView=e,a)return r!==a&&a.attachTo(t._container),t._emit("import.render.start",{view:e,element:l}),void a.open(l).then((n=>{t._emit("import.render.complete",{view:e,error:null,warnings:n.warnings}),o(null,n)})).catch((n=>{t._emit("import.render.complete",{view:e,error:n,warnings:n.warnings}),o(n,null)}));o()}))}_getViewer(e){var t=e.type,n=this._viewers[t];return n||(n=this._viewers[t]=this._createViewer(e.type),this._emit("viewer.created",{type:t,viewer:n})),n}_createViewer(e){var t=c(this._getViewProviders(),(function(t){return t.id===e}));if(!t)throw new Error("no provider for view type <"+e+">");var n=t.constructor,i=this._options[e]||{};return new n({...this._options.common||{},...i,additionalModules:[...i.additionalModules||[],{_parent:["value",this],moddle:["value",this._moddle]}]})}_emit(...e){return this._eventBus.fire(...e)}_createModdle(e){return new pt(e.moddleExtensions)}_getViewProviders(){return[]}}function Ut(e){return e+(o(e)?"px":"")}function Gt(e,t){return n(e)?!!n(t)&&(e.element===t.element||e.id===t.id):!n(t)}function Kt(e,t){return!e||!t||e.name!==t.name}function Xt(e,t){s(e[t])&&e[t]()}function Yt(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}const Jt=/^class[ {]/;function Qt(e){return Array.isArray(e)}function Zt(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function en(...e){1===e.length&&Qt(e[0])&&(e=e[0]);const t=(e=[...e]).pop();return t.$inject=e,t}const tn=/constructor\s*[^(]*\(\s*([^)]*)\)/m,nn=/^(?:async\s+)?(?:function\s*[^(]*)?(?:\(\s*([^)]*)\)|(\w+))/m,rn=/\/\*([^*]*)\*\//m;function on(e){if("function"!=typeof e)throw new Error(`Cannot annotate "${e}". Expected a function!`);const t=e.toString().match(function(e){return Jt.test(e.toString())}(e)?tn:nn);if(!t)return[];const n=t[1]||t[2];return n&&n.split(",").map((e=>{const t=e.match(rn);return(t&&t[1]||e).trim()}))||[]}function sn(e,t){const n=t||{get:function(e,t){if(i.push(e),!1===t)return null;throw a(`No provider for "${e}"!`)}},i=[],r=this._providers=Object.create(n._providers||null),o=this._instances=Object.create(null),s=o.injector=this,a=function(e){const t=i.join(" -> ");return i.length=0,new Error(t?`${e} (Resolving: ${t})`:e)};function l(e,t){if(!r[e]&&e.includes(".")){const t=e.split(".");let n=l(t.shift());for(;t.length;)n=n[t.shift()];return n}if(Zt(o,e))return o[e];if(Zt(r,e)){if(-1!==i.indexOf(e))throw i.push(e),a("Cannot resolve circular dependency!");return i.push(e),o[e]=r[e][0](r[e][1]),i.pop(),o[e]}return n.get(e,t)}function c(e,t){if(void 0===t&&(t={}),"function"!=typeof e){if(!Qt(e))throw a(`Cannot invoke "${e}". Expected a function!`);e=en(e.slice())}return{fn:e,dependencies:(e.$inject||on(e)).map((e=>Zt(t,e)?t[e]:l(e)))}}function h(e){const{fn:t,dependencies:n}=c(e);return new(Function.prototype.bind.call(t,null,...n))}function u(e,t,n){const{fn:i,dependencies:r}=c(e,n);return i.apply(t,r)}function d(e){return en((t=>e.get(t)))}function p(e,t){if(t&&t.length){const n=Object.create(null),i=Object.create(null),o=[],s=[],a=[];let l,c,h,u;for(let e in r)l=r[e],-1!==t.indexOf(e)&&("private"===l[2]?(c=o.indexOf(l[3]),-1===c?(h=l[3].createChild([],t),u=d(h),o.push(l[3]),s.push(h),a.push(u),n[e]=[u,e,"private",h]):n[e]=[a[c],e,"private",s[c]]):n[e]=[l[2],l[1]],i[e]=!0),"factory"!==l[2]&&"type"!==l[2]||!l[1].$scope||t.forEach((t=>{-1!==l[1].$scope.indexOf(t)&&(n[e]=[l[2],l[1]],i[t]=!0)}));t.forEach((e=>{if(!i[e])throw new Error('No provider for "'+e+'". Cannot use provider from the parent!')})),e.unshift(n)}return new sn(e,s)}const f={factory:u,type:h,value:function(e){return e}};function g(e,t){const n=e.__init__||[];return function(){n.forEach((e=>{"string"==typeof e?t.get(e):t.invoke(e)}))}}function m(e){const t=e.__exports__;if(t){const n=e.__modules__,i=Object.keys(e).reduce(((t,n)=>("__exports__"!==n&&"__modules__"!==n&&"__init__"!==n&&"__depends__"!==n&&(t[n]=e[n]),t)),Object.create(null)),o=p((n||[]).concat(i)),s=en((function(e){return o.get(e)}));t.forEach((function(e){r[e]=[s,e,"private",o]}));const a=(e.__init__||[]).slice();return a.unshift((function(){o.init()})),g(e=Object.assign({},e,{__init__:a}),o)}return Object.keys(e).forEach((function(t){if("__init__"===t||"__depends__"===t)return;const n=e[t];if("private"===n[2])return void(r[t]=n);const i=n[0],o=n[1];r[t]=[f[i],an(i,o),i]})),g(e,s)}function v(e,t){return-1!==e.indexOf(t)||-1!==(e=(t.__depends__||[]).reduce(v,e)).indexOf(t)?e:e.concat(t)}this.get=l,this.invoke=u,this.instantiate=h,this.createChild=p,this.init=function(e){const t=e.reduce(v,[]).map(m);let n=!1;return function(){n||(n=!0,t.forEach((e=>e())))}}(e)}function an(e,t){return"value"!==e&&Qt(t)&&(t=en(t.slice())),t}var ln=1e3;function cn(e,t){var n=this;t=t||ln,e.on(["render.shape","render.connection"],t,(function(e,t){var i=e.type,r=t.element,o=t.gfx,s=t.attrs;if(n.canRender(r))return"render.shape"===i?n.drawShape(o,r,s):n.drawConnection(o,r,s)})),e.on(["render.getShapePath","render.getConnectionPath"],t,(function(e,t){if(n.canRender(t))return"render.getShapePath"===e.type?n.getShapePath(t):n.getConnectionPath(t)}))}function hn(e,t){return function(e,t){t.appendChild(function(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch(e){}return e}(e,t))}(t,e),e}cn.prototype.canRender=function(e){},cn.prototype.drawShape=function(e,t){},cn.prototype.drawConnection=function(e,t){},cn.prototype.getShapePath=function(e){},cn.prototype.getConnectionPath=function(e){};var un=2,dn={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":un,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":un,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function pn(e,t,n){var i=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),r=dn[i];r?(r===un&&"number"==typeof n&&(n=String(n)+"px"),e.style[i]=n):e.setAttributeNS(null,t,n)}function fn(e,t,n){if("string"==typeof t){if(void 0===n)return function(e,t){return dn[t]?e.style[t]:e.getAttributeNS(null,t)}(e,t);pn(e,t,n)}else!function(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)pn(e,i,t[i])}(e,t);return e}const gn=Object.prototype.toString;function mn(e){return new vn(e)}function vn(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}vn.prototype.add=function(e){return this.list.add(e),this},vn.prototype.remove=function(e){return"[object RegExp]"==gn.call(e)?this.removeMatching(e):(this.list.remove(e),this)},vn.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},vn.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},vn.prototype.array=function(){return Array.from(this.list)},vn.prototype.has=vn.prototype.contains=function(e){return this.list.contains(e)};var yn={svg:"http://www.w3.org/2000/svg"},wn='<svg xmlns="'+yn.svg+'"';function bn(e){var t=!1;"<svg"===e.substring(0,4)?-1===e.indexOf(yn.svg)&&(e=wn+e.substring(4)):(e=wn+">"+e+"</svg>",t=!0);var n=function(e){var t;return(t=new DOMParser).async=!1,t.parseFromString(e,"text/xml")}(e);if(!t)return n;for(var i=document.createDocumentFragment(),r=n.firstChild;r.firstChild;)i.appendChild(r.firstChild);return i}function xn(e,t){var n;return"<"===(e=e.trim()).charAt(0)?(n=bn(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(yn.svg,e),t&&fn(n,t),n}var _n=null;function Sn(){return null===_n&&(_n=xn("svg")),_n}function kn(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)e[i]=t[i];return e}var Cn=/([&<>]{1})/g,En=/([&<>\n\r"]{1})/g,Mn={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"'"};function An(e,t){return e.replace(t,(function(e,t){return Mn[t]||t}))}function Rn(e,t){var n,i,r,o,s;switch(e.nodeType){case 3:t.push(An(e.textContent,Cn));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(n=0,i=(r=e.attributes).length;n<i;++n)o=r.item(n),t.push(" ",o.name,'="',An(o.value,En),'"');if(e.hasChildNodes()){for(t.push(">"),n=0,i=(s=e.childNodes).length;n<i;++n)Rn(s.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("\x3c!--",An(e.nodeValue,Cn),"--\x3e");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function Tn(e,t){return function(e){for(var t=e.firstChild,n=[];t;)Rn(t,n),t=t.nextSibling;return n.join("")}(e)}function Dn(e){var t=e.parentNode;return t&&t.removeChild(e),e}function On(e,t){return t instanceof SVGMatrix?e.createSVGTransformFromMatrix(t):t}function Nn(e,t){var n=e.transform.baseVal;return t&&(Array.isArray(t)||(t=[t]),function(e,t){var n,i;for(e.clear(),n=0;i=t[n];n++)e.appendItem(On(e,i))}(n,t)),n.consolidate()}function Pn(e){return e.flat().join(",").replace(/,?([A-z]),?/g,"$1")}function qn(e){return["L",e.x,e.y]}function Bn(e,t){const n=e.length,i=[(r=e[0],["M",r.x,r.y])];var r,o,s,a;for(let r=1;r<n;r++){const n=e[r-1],l=e[r],c=e[r+1];if(!c||!t){i.push(qn(l));continue}const h=Math.min(t,In(l.x-n.x,l.y-n.y),In(c.x-l.x,c.y-l.y));if(!h){i.push(qn(l));continue}const u=Ln(l,n,h),d=Ln(l,n,.5*h),p=Ln(l,c,h),f=Ln(l,c,.5*h);i.push(qn(u)),i.push((s=f,a=p,["C",(o=d).x,o.y,s.x,s.y,a.x,a.y]))}return i}function Ln(e,t,n){const i=t.x-e.x,r=t.y-e.y,o=n/In(i,r);return{x:e.x+i*o,y:e.y+r*o}}function In(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}function jn(e,t,n){o(t)&&(n=t,t=null),t||(t={});const i=xn("path",t);return o(n)&&(i.dataset.cornerRadius=String(n)),Fn(i,e)}function Fn(e,t){return fn(e,{d:Pn(Bn(t,parseInt(e.dataset.cornerRadius,10)||0))}),e}function Vn(e,t){var n,r,o,s;return t=!!t,i(e)||(e=[e]),u(e,(function(e){var i=e;e.waypoints&&!t&&(i=Vn(e.waypoints,!0));var a=i.x,l=i.y,c=i.height||0,h=i.width||0;(a<n||void 0===n)&&(n=a),(l<r||void 0===r)&&(r=l),(a+h>o||void 0===o)&&(o=a+h),(l+c>s||void 0===s)&&(s=l+c)})),{x:n,y:r,height:s-r,width:o-n}}function $n(e){return!(!e||!e.isFrame)}function zn(e,t){cn.call(this,e,1),this.CONNECTION_STYLE=t.style(["no-fill"],{strokeWidth:5,stroke:"fuchsia"}),this.SHAPE_STYLE=t.style({fill:"white",stroke:"fuchsia",strokeWidth:2}),this.FRAME_STYLE=t.style(["no-fill"],{stroke:"fuchsia",strokeDasharray:4,strokeWidth:2})}Yt(zn,cn),zn.prototype.canRender=function(){return!0},zn.prototype.drawShape=function(e,t,n){var i=xn("rect");return fn(i,{x:0,y:0,width:t.width||0,height:t.height||0}),$n(t)?fn(i,_({},this.FRAME_STYLE,n||{})):fn(i,_({},this.SHAPE_STYLE,n||{})),hn(e,i),i},zn.prototype.drawConnection=function(e,t,n){var i=jn(t.waypoints,_({},this.CONNECTION_STYLE,n||{}));return hn(e,i),i},zn.prototype.getShapePath=function(e){var t=e.x,n=e.y,i=e.width;return Pn([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])},zn.prototype.getConnectionPath=function(e){var t,n,i=e.waypoints,r=[];for(t=0;n=i[t];t++)n=n.original||n,r.push([0===t?"M":"L",n.x,n.y]);return Pn(r)},zn.$inject=["eventBus","styles"];var Hn={__init__:["defaultRenderer"],defaultRenderer:["type",zn],styles:["type",function(){var e={"no-fill":{fill:"none"},"no-border":{strokeOpacity:0},"no-events":{pointerEvents:"none"}},t=this;this.cls=function(e,t,n){return _(this.style(t,n),{class:e})},this.style=function(t,n){i(t)||n||(n=t,t=[]);var r=d(t,(function(t,n){return _(t,e[n]||{})}),{});return n?_(r,n):r},this.computeStyle=function(e,n,r){return i(n)||(r=n,n=[]),t.style(n||[],_({},r,e||{}))}}]};function Wn(e){return{top:e.y,right:e.x+(e.width||0),bottom:e.y+(e.height||0),left:e.x}}function Un(e,t){return Math.round(e*t)/t}function Gn(e){return o(e)?e+"px":e}function Kn(e,t,n){const i=xn("g");mn(i).add(t);const r=void 0!==n?n:e.childNodes.length-1;return e.insertBefore(i,e.childNodes[r]||null),i}const Xn={shape:["x","y","width","height"],connection:["waypoints"]};function Yn(e,t,n,i){this._eventBus=t,this._elementRegistry=i,this._graphicsFactory=n,this._rootsIdx=0,this._layers={},this._planes=[],this._rootElement=null,this._focused=!1,this._init(e||{})}function Jn(e,t){const n="matrix("+t.a+","+t.b+","+t.c+","+t.d+","+t.e+","+t.f+")";e.setAttribute("transform",n)}Yn.$inject=["config.canvas","eventBus","graphicsFactory","elementRegistry"],Yn.prototype._init=function(e){const t=this._eventBus,n=this._container=function(e){const t=(e=_({},{width:"100%",height:"100%"},e)).container||document.body,n=document.createElement("div");return n.setAttribute("class","djs-container djs-parent"),xt(n,{position:"relative",overflow:"hidden",width:Gn(e.width),height:Gn(e.height)}),t.appendChild(n),n}(e),i=this._svg=xn("svg");fn(i,{width:"100%",height:"100%"}),_t(i,"tabindex",0),t.on("element.hover",(()=>{this.restoreFocus()})),i.addEventListener("focusin",(()=>{this._focused=!0,t.fire("canvas.focus.changed",{focused:!0})})),i.addEventListener("focusout",(()=>{this._focused=!1,t.fire("canvas.focus.changed",{focused:!1})})),hn(n,i);const r=this._viewport=Kn(i,"viewport");e.deferUpdate&&(this._viewboxChanged=b(x(this._viewboxChanged,this),300)),t.on("diagram.init",(()=>{t.fire("canvas.init",{svg:i,viewport:r})})),t.on(["shape.added","connection.added","shape.removed","connection.removed","elements.changed","root.set"],(()=>{delete this._cachedViewbox})),t.on("diagram.destroy",500,this._destroy,this),t.on("diagram.clear",500,this._clear,this)},Yn.prototype._destroy=function(){this._eventBus.fire("canvas.destroy",{svg:this._svg,viewport:this._viewport});const e=this._container.parentNode;e&&e.removeChild(this._container),delete this._svg,delete this._container,delete this._layers,delete this._planes,delete this._rootElement,delete this._viewport},Yn.prototype._clear=function(){this._elementRegistry.getAll().forEach((e=>{const t=function(e){return"waypoints"in e?"connection":"x"in e?"shape":"root"}(e);"root"===t?this.removeRootElement(e):this._removeElement(e,t)})),this._planes=[],this._rootElement=null,delete this._cachedViewbox},Yn.prototype.focus=function(){this._svg.focus({preventScroll:!0})},Yn.prototype.restoreFocus=function(){document.activeElement===document.body&&this.focus()},Yn.prototype.isFocused=function(){return this._focused},Yn.prototype.getDefaultLayer=function(){return this.getLayer("base",0)},Yn.prototype.getLayer=function(e,t){if(!e)throw new Error("must specify a name");let n=this._layers[e];if(n||(n=this._layers[e]=this._createLayer(e,t)),void 0!==t&&n.index!==t)throw new Error("layer <"+e+"> already created at index <"+t+">");return n.group},Yn.prototype._getChildIndex=function(e){return d(this._layers,(function(t,n){return n.visible&&e>=n.index&&t++,t}),0)},Yn.prototype._createLayer=function(e,t){void 0===t&&(t=1);const n=this._getChildIndex(t);return{group:Kn(this._viewport,"layer-"+e,n),index:t,visible:!0}},Yn.prototype.showLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=this._viewport,i=t.group,r=t.index;if(t.visible)return i;const o=this._getChildIndex(r);return n.insertBefore(i,n.childNodes[o]||null),t.visible=!0,i},Yn.prototype.hideLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=t.group;return t.visible?(Dn(n),t.visible=!1,n):n},Yn.prototype._removeLayer=function(e){const t=this._layers[e];t&&(delete this._layers[e],Dn(t.group))},Yn.prototype.getActiveLayer=function(){const e=this._findPlaneForRoot(this.getRootElement());return e?e.layer:null},Yn.prototype.findRoot=function(e){if("string"==typeof e&&(e=this._elementRegistry.get(e)),!e)return;const t=this._findPlaneForRoot(function(e){for(;e.parent;)e=e.parent;return e}(e))||{};return t.rootElement},Yn.prototype.getRootElements=function(){return this._planes.map((function(e){return e.rootElement}))},Yn.prototype._findPlaneForRoot=function(e){return c(this._planes,(function(t){return t.rootElement===e}))},Yn.prototype.getContainer=function(){return this._container},Yn.prototype._updateMarker=function(e,t,n){let i;e.id||(e=this._elementRegistry.get(e)),e.markers=e.markers||new Set,i=this._elementRegistry._elements[e.id],i&&(u([i.gfx,i.secondaryGfx],(function(i){i&&(n?(e.markers.add(t),mn(i).add(t)):(e.markers.delete(t),mn(i).remove(t)))})),this._eventBus.fire("element.marker.update",{element:e,gfx:i.gfx,marker:t,add:!!n}))},Yn.prototype.addMarker=function(e,t){this._updateMarker(e,t,!0)},Yn.prototype.removeMarker=function(e,t){this._updateMarker(e,t,!1)},Yn.prototype.hasMarker=function(e,t){return e.id||(e=this._elementRegistry.get(e)),!!e.markers&&e.markers.has(t)},Yn.prototype.toggleMarker=function(e,t){this.hasMarker(e,t)?this.removeMarker(e,t):this.addMarker(e,t)},Yn.prototype.getRootElement=function(){const e=this._rootElement;return e||this._planes.length?e:this.setRootElement(this.addRootElement(null))},Yn.prototype.addRootElement=function(e){const t=this._rootsIdx++;e||(e={id:"__implicitroot_"+t,children:[],isImplicit:!0});const n=e.layer="root-"+t;this._ensureValid("root",e);const i=this.getLayer(n,0);return this.hideLayer(n),this._addRoot(e,i),this._planes.push({rootElement:e,layer:i}),e},Yn.prototype.removeRootElement=function(e){"string"==typeof e&&(e=this._elementRegistry.get(e));if(this._findPlaneForRoot(e))return this._removeRoot(e),this._removeLayer(e.layer),this._planes=this._planes.filter((function(t){return t.rootElement!==e})),this._rootElement===e&&(this._rootElement=null),e},Yn.prototype.setRootElement=function(e){if(e===this._rootElement)return e;let t;if(!e)throw new Error("rootElement required");return t=this._findPlaneForRoot(e),t||(e=this.addRootElement(e)),this._setRoot(e),e},Yn.prototype._removeRoot=function(e){const t=this._elementRegistry,n=this._eventBus;n.fire("root.remove",{element:e}),n.fire("root.removed",{element:e}),t.remove(e)},Yn.prototype._addRoot=function(e,t){const n=this._elementRegistry,i=this._eventBus;i.fire("root.add",{element:e}),n.add(e,t),i.fire("root.added",{element:e,gfx:t})},Yn.prototype._setRoot=function(e,t){const n=this._rootElement;n&&(this._elementRegistry.updateGraphics(n,null,!0),this.hideLayer(n.layer)),e&&(t||(t=this._findPlaneForRoot(e).layer),this._elementRegistry.updateGraphics(e,this._svg,!0),this.showLayer(e.layer)),this._rootElement=e,this._eventBus.fire("root.set",{element:e})},Yn.prototype._ensureValid=function(e,t){if(!t.id)throw new Error("element must have an id");if(this._elementRegistry.get(t.id))throw new Error("element <"+t.id+"> already exists");const n=Xn[e],i=p(n,(function(e){return void 0!==t[e]}));if(!i)throw new Error("must supply { "+n.join(", ")+" } with "+e)},Yn.prototype._setParent=function(e,t,n){!function(e,t,n){if(e&&t){"number"!=typeof n&&(n=-1);var i=e.indexOf(t);if(-1!==i){if(i===n)return;if(-1===n)return;e.splice(i,1)}-1!==n?e.splice(n,0,t):e.push(t)}}(t.children,e,n),e.parent=t},Yn.prototype._addElement=function(e,t,n,i){n=n||this.getRootElement();const r=this._eventBus,o=this._graphicsFactory;this._ensureValid(e,t),r.fire(e+".add",{element:t,parent:n}),this._setParent(t,n,i);const s=o.create(e,t,i);return this._elementRegistry.add(t,s),o.update(e,t,s),r.fire(e+".added",{element:t,gfx:s}),t},Yn.prototype.addShape=function(e,t,n){return this._addElement("shape",e,t,n)},Yn.prototype.addConnection=function(e,t,n){return this._addElement("connection",e,t,n)},Yn.prototype._removeElement=function(e,t){const n=this._elementRegistry,i=this._graphicsFactory,r=this._eventBus;if(e=n.get(e.id||e))return r.fire(t+".remove",{element:e}),i.remove(e),function(e,t){if(!e||!t)return-1;var n=e.indexOf(t);-1!==n&&e.splice(n,1)}(e.parent&&e.parent.children,e),e.parent=null,r.fire(t+".removed",{element:e}),n.remove(e),e},Yn.prototype.removeShape=function(e){return this._removeElement(e,"shape")},Yn.prototype.removeConnection=function(e){return this._removeElement(e,"connection")},Yn.prototype.getGraphics=function(e,t){return this._elementRegistry.getGraphics(e,t)},Yn.prototype._changeViewbox=function(e){this._eventBus.fire("canvas.viewbox.changing"),e.apply(this),this._cachedViewbox=null,this._viewboxChanged()},Yn.prototype._viewboxChanged=function(){this._eventBus.fire("canvas.viewbox.changed",{viewbox:this.viewbox()})},Yn.prototype.viewbox=function(e){if(void 0===e&&this._cachedViewbox)return structuredClone(this._cachedViewbox);const t=this._viewport,n=this.getSize();let i,r,o,s,a,l,c;return e?(this._changeViewbox((function(){a=Math.min(n.width/e.width,n.height/e.height);const i=this._svg.createSVGMatrix().scale(a).translate(-e.x,-e.y);Nn(t,i)})),e):(o=this._rootElement?this.getActiveLayer():null,i=o&&o.getBBox()||{},s=Nn(t),r=s?s.matrix:function(e,t,n,i,r,o){var s=Sn().createSVGMatrix();switch(arguments.length){case 0:return s;case 1:return kn(s,e);case 6:return kn(s,{a:e,b:t,c:n,d:i,e:r,f:o})}}(),a=Un(r.a,1e3),l=Un(-r.e||0,1e3),c=Un(-r.f||0,1e3),e=this._cachedViewbox={x:l?l/a:0,y:c?c/a:0,width:n.width/a,height:n.height/a,scale:a,inner:{width:i.width||0,height:i.height||0,x:i.x||0,y:i.y||0},outer:n})},Yn.prototype.scroll=function(e){const t=this._viewport;let n=t.getCTM();return e&&this._changeViewbox((function(){e=_({dx:0,dy:0},e||{}),n=this._svg.createSVGMatrix().translate(e.dx,e.dy).multiply(n),Jn(t,n)})),{x:n.e,y:n.f}},Yn.prototype.scrollToElement=function(e,t){let n=100;"string"==typeof e&&(e=this._elementRegistry.get(e));const i=this.findRoot(e);if(i!==this.getRootElement()&&this.setRootElement(i),i===e)return;t||(t={}),"number"==typeof t&&(n=t),t={top:t.top||n,right:t.right||n,bottom:t.bottom||n,left:t.left||n};const r=Vn(e),o=Wn(r),s=this.viewbox(),a=this.zoom();let l,c;s.y+=t.top/a,s.x+=t.left/a,s.width-=(t.right+t.left)/a,s.height-=(t.bottom+t.top)/a;const h=Wn(s);if(r.width<s.width&&r.height<s.height){const e=Math.max(0,o.right-h.right),t=Math.min(0,o.left-h.left),n=Math.max(0,o.bottom-h.bottom),i=Math.min(0,o.top-h.top);l=e||t,c=n||i}else l=r.x-s.x,c=r.y-s.y;this.scroll({dx:-l*a,dy:-c*a})},Yn.prototype.zoom=function(e,t){if(!e)return this.viewbox(e).scale;if("fit-viewport"===e)return this._fitViewport(t);let n,i;return this._changeViewbox((function(){"object"!=typeof t&&(n=this.viewbox().outer,t={x:n.width/2,y:n.height/2}),i=this._setZoom(e,t)})),Un(i.a,1e3)},Yn.prototype._fitViewport=function(e){const t=this.viewbox(),n=t.outer,i=t.inner;let r,o;return i.x>=0&&i.y>=0&&i.x+i.width<=n.width&&i.y+i.height<=n.height&&!e?o={x:0,y:0,width:Math.max(i.width+i.x,n.width),height:Math.max(i.height+i.y,n.height)}:(r=Math.min(1,n.width/i.width,n.height/i.height),o={x:i.x+(e?i.width/2-n.width/r/2:0),y:i.y+(e?i.height/2-n.height/r/2:0),width:n.width/r,height:n.height/r}),this.viewbox(o),this.viewbox(!1).scale},Yn.prototype._setZoom=function(e,t){const n=this._svg,i=this._viewport,r=n.createSVGMatrix(),o=n.createSVGPoint();let s,a,l,c,h;l=i.getCTM();const u=l.a;return t?(s=_(o,t),a=s.matrixTransform(l.inverse()),c=r.translate(a.x,a.y).scale(1/u*e).translate(-a.x,-a.y),h=l.multiply(c)):h=r.scale(e),Jn(this._viewport,h),h},Yn.prototype.getSize=function(){return{width:this._container.clientWidth,height:this._container.clientHeight}},Yn.prototype.getAbsoluteBBox=function(e){const t=this.viewbox();let n;if(e.waypoints){n=this.getGraphics(e).getBBox()}else n=e;return{x:n.x*t.scale-t.x*t.scale,y:n.y*t.scale-t.y*t.scale,width:n.width*t.scale,height:n.height*t.scale}},Yn.prototype.resized=function(){delete this._cachedViewbox,this._eventBus.fire("canvas.resized")};var Qn="data-element-id";function Zn(e){this._elements={},this._eventBus=e}function ei(e,t,n){var i=function(e,t,n,i){var r=n.inverse;return Object.defineProperty(e,"remove",{value:function(e){var n=this.indexOf(e);return-1!==n&&(this.splice(n,1),t.unset(e,r,i)),e}}),Object.defineProperty(e,"contains",{value:function(e){return-1!==this.indexOf(e)}}),Object.defineProperty(e,"add",{value:function(e,n){var o=this.indexOf(e);if(void 0===n){if(-1!==o)return;n=this.length}-1!==o&&this.splice(o,1),this.splice(n,0,e),-1===o&&t.set(e,r,i)}}),Object.defineProperty(e,"__refs_collection",{value:!0}),e}(n[t.name]||[],e,t,n);Object.defineProperty(n,t.name,{enumerable:t.enumerable,value:i}),i.length&&i.forEach((function(i){e.set(i,t.inverse,n)}))}function ti(e,t){if(!(this instanceof ti))return new ti(e,t);e.inverse=t,t.inverse=e,this.props={},this.props[e.name]=e,this.props[t.name]=t}Zn.$inject=["eventBus"],Zn.prototype.add=function(e,t,n){var i=e.id;this._validateId(i),fn(t,Qn,i),n&&fn(n,Qn,i),this._elements[i]={element:e,gfx:t,secondaryGfx:n}},Zn.prototype.remove=function(e){var t=this._elements,n=e.id||e,i=n&&t[n];i&&(fn(i.gfx,Qn,""),i.secondaryGfx&&fn(i.secondaryGfx,Qn,""),delete t[n])},Zn.prototype.updateId=function(e,t){this._validateId(t),"string"==typeof e&&(e=this.get(e)),this._eventBus.fire("element.updateId",{element:e,newId:t});var n=this.getGraphics(e),i=this.getGraphics(e,!0);this.remove(e),e.id=t,this.add(e,n,i)},Zn.prototype.updateGraphics=function(e,t,n){var i=e.id||e,r=this._elements[i];return n?r.secondaryGfx=t:r.gfx=t,t&&fn(t,Qn,i),t},Zn.prototype.get=function(e){var t;t="string"==typeof e?e:e&&fn(e,Qn);var n=this._elements[t];return n&&n.element},Zn.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(n)})),t},Zn.prototype.find=function(e){for(var t=this._elements,n=Object.keys(t),i=0;i<n.length;i++){var r=t[n[i]],o=r.element;if(e(o,r.gfx))return o}},Zn.prototype.getAll=function(){return this.filter((function(e){return e}))},Zn.prototype.forEach=function(e){var t=this._elements;Object.keys(t).forEach((function(n){var i=t[n],r=i.element,o=i.gfx;return e(r,o)}))},Zn.prototype.getGraphics=function(e,t){var n=e.id||e,i=this._elements[n];return i&&(t?i.secondaryGfx:i.gfx)},Zn.prototype._validateId=function(e){if(!e)throw new Error("element must have an id");if(this._elements[e])throw new Error("element with id "+e+" already added")},ti.prototype.bind=function(e,t){if("string"==typeof t){if(!this.props[t])throw new Error("no property <"+t+"> in ref");t=this.props[t]}t.collection?ei(this,t,e):function(e,t,n){var i=t.inverse,r=n[t.name];Object.defineProperty(n,t.name,{configurable:t.configurable,enumerable:t.enumerable,get:function(){return r},set:function(t){if(t!==r){var o=r;r=null,o&&e.unset(o,i,n),r=t,e.set(r,i,n)}}})}(this,t,e)},ti.prototype.ensureRefsCollection=function(e,t){var n=e[t.name];return function(e){return!0===e.__refs_collection}(n)||ei(this,t,e),n},ti.prototype.ensureBound=function(e,t){(function(e,t){return Object.prototype.hasOwnProperty.call(e,t.name||t)})(e,t)||this.bind(e,t)},ti.prototype.unset=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).remove(n):e[t.name]=void 0)},ti.prototype.set=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).add(n):e[t.name]=n)};var ni=new ti({name:"children",enumerable:!0,collection:!0},{name:"parent"}),ii=new ti({name:"labels",enumerable:!0,collection:!0},{name:"labelTarget"}),ri=new ti({name:"attachers",collection:!0},{name:"host"}),oi=new ti({name:"outgoing",collection:!0},{name:"source"}),si=new ti({name:"incoming",collection:!0},{name:"target"});function ai(){Object.defineProperty(this,"businessObject",{writable:!0}),Object.defineProperty(this,"label",{get:function(){return this.labels[0]},set:function(e){var t=this.label,n=this.labels;!e&&t?n.remove(t):n.add(e,0)}}),ni.bind(this,"parent"),ii.bind(this,"labels"),oi.bind(this,"outgoing"),si.bind(this,"incoming")}function li(){ai.call(this),ni.bind(this,"children"),ri.bind(this,"host"),ri.bind(this,"attachers")}function ci(){ai.call(this),ni.bind(this,"children")}function hi(){li.call(this),ii.bind(this,"labelTarget")}function ui(){ai.call(this),oi.bind(this,"source"),si.bind(this,"target")}Yt(li,ai),Yt(ci,li),Yt(hi,li),Yt(ui,ai);var di={connection:ui,shape:li,label:hi,root:ci};function pi(){this._uid=12}function fi(e,t,n){var i=Sn().createSVGTransform();i.setTranslate(t,n),Nn(e,i)}function gi(e,t){this._eventBus=e,this._elementRegistry=t}function mi(e,t,n){var i=n||t.firstChild;e!==i&&t.insertBefore(e,i)}pi.prototype.createRoot=function(e){return this.create("root",e)},pi.prototype.createLabel=function(e){return this.create("label",e)},pi.prototype.createShape=function(e){return this.create("shape",e)},pi.prototype.createConnection=function(e){return this.create("connection",e)},pi.prototype.create=function(e,t){return(t=_({},t||{})).id||(t.id=e+"_"+this._uid++),function(e,t){var n=di[e];if(!n)throw new Error("unknown type: <"+e+">");return _(new n,t)}(e,t)},gi.$inject=["eventBus","elementRegistry"],gi.prototype._getChildrenContainer=function(e){var t,n=this._elementRegistry.getGraphics(e);return e.parent?(t=function(e){return e.parentNode.childNodes[1]}(n),t||(mn(t=xn("g")).add("djs-children"),hn(n.parentNode,t))):t=n,t},gi.prototype._clear=function(e){var t=function(e){return e.childNodes[0]}(e);return Et(t),t},gi.prototype._createContainer=function(e,t,n,i){var r=xn("g");mn(r).add("djs-group"),void 0!==n?mi(r,t,t.childNodes[n]):hn(t,r);var o=xn("g");mn(o).add("djs-element"),mn(o).add("djs-"+e),i&&mn(o).add("djs-frame"),hn(r,o);var s=xn("g");return mn(s).add("djs-visual"),hn(o,s),o},gi.prototype.create=function(e,t,n){var i=this._getChildrenContainer(t.parent);return this._createContainer(e,i,n,$n(t))},gi.prototype.updateContainments=function(e){var t,n=this,i=this._elementRegistry;t=d(e,(function(e,t){return t.parent&&(e[t.parent.id]=t.parent),e}),{}),u(t,(function(e){var t=e.children;if(t){var r=n._getChildrenContainer(e);u(t.slice().reverse(),(function(e){mi(i.getGraphics(e).parentNode,r)}))}}))},gi.prototype.drawShape=function(e,t,n={}){return this._eventBus.fire("render.shape",{gfx:e,element:t,attrs:n})},gi.prototype.getShapePath=function(e){return this._eventBus.fire("render.getShapePath",e)},gi.prototype.drawConnection=function(e,t,n={}){return this._eventBus.fire("render.connection",{gfx:e,element:t,attrs:n})},gi.prototype.getConnectionPath=function(e){return this._eventBus.fire("render.getConnectionPath",e)},gi.prototype.update=function(e,t,n){if(t.parent){var i=this._clear(n);if("shape"===e)this.drawShape(i,t),fi(n,t.x,t.y);else{if("connection"!==e)throw new Error("unknown type: "+e);this.drawConnection(i,t)}t.hidden?fn(n,"display","none"):fn(n,"display","block")}},gi.prototype.remove=function(e){Dn(this._elementRegistry.getGraphics(e).parentNode)};var vi={__depends__:[Hn],__init__:["canvas"],canvas:["type",Yn],elementRegistry:["type",Zn],elementFactory:["type",pi],eventBus:["type",C],graphicsFactory:["type",gi]};function yi(e){return function(e){var t=new sn(e);return t.init(),t}([{config:["value",e=e||{}]},vi].concat(e.modules||[]))}function wi(e,t){this._injector=t||yi(e),this.get("eventBus").fire("diagram.init")}function bi(e,t){var n=xi(e);return n&&"function"==typeof n.$instanceOf&&n.$instanceOf(t)}function xi(e){return e&&e.businessObject||e}function _i(e){var t=xi(e);if(bi(t,"dmn:Decision"))return t.get("decisionLogic");if(bi(t,"dmn:BusinessKnowledgeModel")){var n=t.get("encapsulatedLogic");return n&&n.get("body")}}wi.prototype.get=function(e,t){return this._injector.get(e,t)},wi.prototype.invoke=function(e,t,n){return this._injector.invoke(e,t,n)},wi.prototype.destroy=function(){this.get("eventBus").fire("diagram.destroy")},wi.prototype.clear=function(){this.get("eventBus").fire("diagram.clear")};var Si=new ti({name:"dmnElementRef",enumerable:!0},{name:"di",configurable:!0});function ki(e,t){var n=[];function i(t){try{var n=t.di&&function(t){if(t.gfx)throw new Error("already rendered "+t.id);return e.element(t)}(t);return n}catch(e){s(e.message,{element:t,error:e})}}function r(e){var t,n;(n=(t=e).dmnElementRef)?n.di?s("multiple DI elements defined for element",{element:n}):(Si.bind(n,"di"),n.di=t):s("no DMN element referenced in element",{element:t})}function o(e){n.push(e)}function s(t,n){e.error(t,n)}return{handleDefinitions:function(t,s){var a=t.dmnDI;if(!a)throw new Error("no dmndi:DMNDI");var l,c=a.diagrams||[];if(s&&-1===c.indexOf(s))throw new Error("diagram not part of dmndi:DMNDI");if(!s&&c&&c.length&&(s=c[0]),!s)throw new Error("no diagram to display");t.di=s,function(e){u(e.diagramElements,r)}(s),l=t,e.root(l),u(t.get("drgElement"),(function(e){i(e),function(e){u(["informationRequirement","knowledgeRequirement","authorityRequirement"],(function(t){u(e[t],(function(e){o((function(){i(e)}))}))}))}(e)})),function(e){u(e,(function(e){bi(e,"dmn:Association")?function(e){o((function(){i(e)}))}(e):i(e)}))}(t.get("artifact")),u(n,(function(e){e()}))}}}var Ci="$NO_OP",Ei="a runtime error occured! Use Inferno in development environment to find the error.",Mi=!("undefined"==typeof window||!window.document),Ai=Array.isArray;function Ri(e){var t=typeof e;return"string"===t||"number"===t}function Ti(e){return Bi(e)||qi(e)}function Di(e){return qi(e)||!1===e||function(e){return!0===e}(e)||Bi(e)}function Oi(e){return"function"==typeof e}function Ni(e){return"string"==typeof e}function Pi(e){return"number"==typeof e}function qi(e){return null===e}function Bi(e){return void 0===e}function Li(e){throw e||(e=Ei),new Error("Inferno Error: "+e)}function Ii(e){console.error(e)}function ji(e,t){var n={};if(e)for(var i in e)n[i]=e[i];if(t)for(var r in t)n[r]=t[r];return n}function Fi(e){var t;if(Ai(e))t="Array("+(e.length>3?e.slice(0,3).toString()+",...":e.toString())+")";else if(Ri(e))t="Text("+e+")";else if(Di(e))t="InvalidVNode("+e+")";else{var n=e.flags;if(481&n)t="<"+e.type+(e.className?' class="'+e.className+'"':"")+">";else if(16&n)t="Text("+e.children+")";else if(1024&n)t="Portal*";else{var i=e.type;t="<"+(i.name||i.displayName||i.constructor.name||(i.toString().match(/^function\s*([^\s(]+)/)||[])[1])+" />"}}return">> "+t+"\n"}function Vi(e,t){for(var n={},i=0,r=e.length;i<r;i++){var o=e[i];if(Ai(o))return"Encountered ARRAY in mount, array must be flattened, or normalize used. Location: \n"+Fi(o);if(Di(o)){if(t)return"Encountered invalid node when preparing to keyed algorithm. Location: \n"+Fi(o);if(0!==Object.keys(n).length)return"Encountered invalid node with mixed keys. Location: \n"+Fi(o)}else{"object"==typeof o&&(o.isValidated=!0);var s=o.key;if(!Ti(s)&&!Ri(s))return"Encountered child vNode where key property is not string or number. Location: \n"+Fi(o);var a=o.children,l=o.childFlags;if(!Di(a)){var c=void 0;if(12&l?c=Vi(a,8&o.childFlags):2===l&&(c=Vi([a],8&o.childFlags)),c)return c+=Fi(o)}if(t&&Ti(s))return"Encountered child without key during keyed algorithm. If this error points to Array make sure children is flat list. Location: \n"+Fi(o);if(t||!Ti(s)){if(n[s])return"Encountered two children with same key: {"+s+"}. Location: \n"+Fi(o);n[s]=!0}else if(0!==Object.keys(n).length)return"Encountered children with key missing. Location: \n"+Fi(o)}}}function $i(e){if(!(1&e.childFlags)&&(64&e.flags&&Li("input elements can't have children."),128&e.flags&&Li("textarea elements can't have children."),481&e.flags)){var t=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],n=e.type.toLowerCase();"media"===n&&Li("media elements can't have children.");var i=t.indexOf(n);-1!==i&&Li(t[i]+" elements can't have children.")}}function zi(e){if(!1===e.isValidated&&e.children&&481&e.flags){var t=Vi(Array.isArray(e.children)?e.children:[e.children],(8&e.childFlags)>0);t&&Li(t+Fi(e))}e.isValidated=!0}var Hi="$";function Wi(e,t,n,i,r,o,s,a){return{childFlags:e,children:t,className:n,dom:null,flags:i,isValidated:!1,key:void 0===r?null:r,parentVNode:null,props:void 0===o?null:o,ref:void 0===s?null:s,type:a}}function Ui(e,t,n,i,r,o,s,a){14&e&&Li("Creating Component vNodes using createVNode is not allowed. Use Inferno.createComponentVNode method.");var l=void 0===r?1:r,c=Wi(l,i,n,e,s,o,a,t);return 0===l&&Zi(c,c.children),$i(c),c}function Gi(e,t,n,i,r){1&e&&Li("Creating element vNodes using createComponentVNode is not allowed. Use Inferno.createVNode method."),(2&e)>0&&(e=t.prototype&&Oi(t.prototype.render)?4:8);var o=t.defaultProps;if(!Ti(o))for(var s in n||(n={}),o)Bi(n[s])&&(n[s]=o[s]);if((8&e)>0){var a=t.defaultHooks;if(!Ti(a))if(r)for(var l in a)Bi(r[l])&&(r[l]=a[l]);else r=a}var c=Wi(1,null,null,e,i,n,r,t),h=er.createVNode;return Oi(h)&&h(c),c}function Ki(e,t){return Wi(1,Ti(e)?"":e,null,16,t,null,null,null)}function Xi(e){var t=e.props;if(t){var n=e.flags;481&n&&(void 0!==t.children&&Ti(e.children)&&Zi(e,t.children),void 0!==t.className&&(e.className=t.className||null,t.className=void 0)),void 0!==t.key&&(e.key=t.key,t.key=void 0),void 0!==t.ref&&(e.ref=8&n?ji(e.ref,t.ref):t.ref,t.ref=void 0)}return e}function Yi(e){var t,n=e.flags;if(14&n){var i,r=e.props;if(!qi(r))for(var o in i={},r)i[o]=r[o];t=Gi(n,e.type,i,e.key,e.ref)}else 481&n?t=Ui(n,e.type,e.className,e.children,e.childFlags,e.props,e.key,e.ref):16&n?t=Ki(e.children,e.key):1024&n&&(t=e);return t}function Ji(){return Ki("",null)}function Qi(e,t,n,i){for(var r=e.length;n<r;n++){var o=e[n];if(!Di(o)){var s=i+Hi+n;if(Ai(o))Qi(o,t,0,s);else{if(Ri(o))o=Ki(o,s);else{var a=o.key,l=Ni(a)&&a[0]===Hi;qi(o.dom)&&!l||(o=Yi(o)),qi(a)||l?o.key=s:o.key=i+a}t.push(o)}}}}function Zi(e,t){var n,i=1;if(Di(t))n=t;else if(Ni(t))i=2,n=Ki(t);else if(Pi(t))i=2,n=Ki(t+"");else if(Ai(t)){var r=t.length;if(0===r)n=null,i=1;else{(Object.isFrozen(t)||!0===t.$)&&(t=t.slice()),i=8;for(var o=0;o<r;o++){var s=t[o];if(Di(s)||Ai(s)){n=n||t.slice(0,o),Qi(t,n,o,"");break}if(Ri(s))(n=n||t.slice(0,o)).push(Ki(s,Hi+o));else{var a=s.key,l=qi(s.dom),c=qi(a),h=!c&&Ni(a)&&a[0]===Hi;!l||c||h?(n=n||t.slice(0,o),l&&!h||(s=Yi(s)),(c||h)&&(s.key=Hi+o),n.push(s)):n&&n.push(s)}}(n=n||t).$=!0}}else n=t,qi(t.dom)||(n=Yi(t)),i=2;return e.children=n,e.childFlags=i,$i(e),e}var er={afterRender:null,beforeRender:null,createVNode:null,renderComplete:null},tr="http://www.w3.org/1999/xlink",nr="http://www.w3.org/XML/1998/namespace",ir="http://www.w3.org/2000/svg",rr={"xlink:actuate":tr,"xlink:arcrole":tr,"xlink:href":tr,"xlink:role":tr,"xlink:show":tr,"xlink:title":tr,"xlink:type":tr,"xml:base":nr,"xml:lang":nr,"xml:space":nr},or={},sr=[];function ar(e,t){e.appendChild(t)}function lr(e,t,n){Ti(n)?ar(e,t):e.insertBefore(t,n)}function cr(e,t,n){e.replaceChild(t,n)}function hr(e){for(var t;void 0!==(t=e.shift());)t()}Object.freeze(or);var ur={},dr={};function pr(e,t,n){var i=ur[e],r=n.$EV;t?(i||(dr[e]=function(e){var t=function(t){var n=t.type,i="click"===n||"dblclick"===n;if(i&&0!==t.button)return t.stopPropagation(),!1;t.stopPropagation=gr;var r={dom:document};Object.defineProperty(t,"currentTarget",{configurable:!0,get:function(){return r.dom}}),function(e,t,n,i){var r=function(e){return Oi(e.composedPath)?e.composedPath()[0]:e.target}(e);for(;!qi(r);){if(t&&r.disabled)return;var o=r.$EV;if(o){var s=o[n];if(s&&(i.dom=r,s.event?s.event(s.data,e):s(e),e.cancelBubble))return}r=r.parentNode}}(t,i,e,r)};return document.addEventListener(fr(e),t),t}(e),ur[e]=0),r||(r=n.$EV={}),r[e]||ur[e]++,r[e]=t):r&&r[e]&&(ur[e]--,1===i&&(document.removeEventListener(fr(e),dr[e]),dr[e]=null),r[e]=t)}function fr(e){return e.substr(2).toLowerCase()}function gr(){this.cancelBubble=!0,this.immediatePropagationStopped||this.stopImmediatePropagation()}function mr(e,t){var n=document.createElement("i");return n.innerHTML=t,n.innerHTML===e.innerHTML}function vr(e,t,n){if(e[t]){var i=e[t];i.event?i.event(i.data,n):i(n)}else{var r=t.toLowerCase();e[r]&&e[r](n)}}function yr(e,t){var n=function(n){n.stopPropagation();var i=this.$V;if(i){var r=i.props||or,o=i.dom;if(Ni(e))vr(r,e,n);else for(var s=0;s<e.length;s++)vr(r,e[s],n);if(Oi(t)){var a=this.$V,l=a.props||or;t(l,o,!1,a)}}};return Object.defineProperty(n,"wrapped",{configurable:!1,enumerable:!1,value:!0,writable:!1}),n}function wr(e){return"checkbox"===e||"radio"===e}var br=yr("onInput",Sr),xr=yr(["onClick","onChange"],Sr);function _r(e){e.stopPropagation()}function Sr(e,t){var n=e.type,i=e.value,r=e.checked,o=e.multiple,s=e.defaultValue,a=!Ti(i);n&&n!==t.type&&t.setAttribute("type",n),Ti(o)||o===t.multiple||(t.multiple=o),Ti(s)||a||(t.defaultValue=s+""),wr(n)?(a&&(t.value=i),Ti(r)||(t.checked=r)):a&&t.value!==i?(t.defaultValue=i,t.value=i):Ti(r)||(t.checked=r)}function kr(e,t){if("optgroup"===e.type){var n=e.children,i=e.childFlags;if(12&i)for(var r=0,o=n.length;r<o;r++)Cr(n[r],t);else 2===i&&Cr(n,t)}else Cr(e,t)}function Cr(e,t){var n=e.props||or,i=e.dom;i.value=n.value,Ai(t)&&-1!==t.indexOf(n.value)||n.value===t?i.selected=!0:Ti(t)&&Ti(n.selected)||(i.selected=n.selected||!1)}_r.wrapped=!0;var Er=yr("onChange",Mr);function Mr(e,t,n,i){var r=Boolean(e.multiple);Ti(e.multiple)||r===t.multiple||(t.multiple=r);var o=i.childFlags;if(!(1&o)){var s=i.children,a=e.value;if(n&&Ti(a)&&(a=e.defaultValue),12&o)for(var l=0,c=s.length;l<c;l++)kr(s[l],a);else 2===o&&kr(s,a)}}var Ar=yr("onInput",Tr),Rr=yr("onChange");function Tr(e,t,n){var i=e.value,r=t.value;if(Ti(i)){if(n){var o=e.defaultValue;Ti(o)||o===r||(t.defaultValue=o,t.value=o)}}else r!==i&&(t.defaultValue=i,t.value=i)}function Dr(e,t,n,i,r,o){64&e?Sr(i,n):256&e?Mr(i,n,r,t):128&e&&Tr(i,n,r),o&&(n.$V=t)}function Or(e,t,n){64&e?function(e,t){wr(t.type)?(e.onchange=xr,e.onclick=_r):e.oninput=br}(t,n):256&e?function(e){e.onchange=Er}(t):128&e&&function(e,t){e.oninput=Ar,t.onChange&&(e.onchange=Rr)}(t,n)}function Nr(e){return e.type&&wr(e.type)?!Ti(e.checked):!Ti(e.value)}function Pr(e,t){qr(e),t&&e.dom&&(!function(e,t){e.removeChild(t)}(t,e.dom),e.dom=null)}function qr(e){var t=e.flags;if(481&t){var n=e.ref,i=e.props;Oi(n)&&n(null);var r=e.children,o=e.childFlags;if(12&o?Br(r):2===o&&qr(r),!qi(i))for(var s in i)switch(s){case"onClick":case"onDblClick":case"onFocusIn":case"onFocusOut":case"onKeyDown":case"onKeyPress":case"onKeyUp":case"onMouseDown":case"onMouseMove":case"onMouseUp":case"onSubmit":case"onTouchEnd":case"onTouchMove":case"onTouchStart":pr(s,null,e.dom)}}else{var a=e.children;if(a)if(14&t){var l=e.ref;4&t?(Oi(a.componentWillUnmount)&&a.componentWillUnmount(),Oi(l)&&l(null),a.$UN=!0,a.$LI&&qr(a.$LI)):(!Ti(l)&&Oi(l.onComponentWillUnmount)&&l.onComponentWillUnmount(e.dom,e.props||or),qr(a))}else 1024&t&&Pr(a,e.type)}}function Br(e){for(var t=0,n=e.length;t<n;t++)qr(e[t])}function Lr(e,t){Br(t),e.textContent=""}function Ir(e,t){switch(e){case"animationIterationCount":case"borderImageOutset":case"borderImageSlice":case"borderImageWidth":case"boxFlex":case"boxFlexGroup":case"boxOrdinalGroup":case"columnCount":case"fillOpacity":case"flex":case"flexGrow":case"flexNegative":case"flexOrder":case"flexPositive":case"flexShrink":case"floodOpacity":case"fontWeight":case"gridColumn":case"gridRow":case"lineClamp":case"lineHeight":case"opacity":case"order":case"orphans":case"stopOpacity":case"strokeDasharray":case"strokeDashoffset":case"strokeMiterlimit":case"strokeOpacity":case"strokeWidth":case"tabSize":case"widows":case"zIndex":case"zoom":return t;default:return t+"px"}}function jr(e,t,n,i,r,o,s){switch(e){case"onClick":case"onDblClick":case"onFocusIn":case"onFocusOut":case"onKeyDown":case"onKeyPress":case"onKeyUp":case"onMouseDown":case"onMouseMove":case"onMouseUp":case"onSubmit":case"onTouchEnd":case"onTouchMove":case"onTouchStart":pr(e,n,i);break;case"children":case"childrenType":case"className":case"defaultValue":case"key":case"multiple":case"ref":break;case"autoFocus":i.autofocus=!!n;break;case"allowfullscreen":case"autoplay":case"capture":case"checked":case"controls":case"default":case"disabled":case"hidden":case"indeterminate":case"loop":case"muted":case"novalidate":case"open":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"selected":i[e]=!!n;break;case"defaultChecked":case"value":case"volume":if(o&&"value"===e)return;var a=Ti(n)?"":n;i[e]!==a&&(i[e]=a);break;case"dangerouslySetInnerHTML":var l=t&&t.__html||"",c=n&&n.__html||"";l!==c&&(Ti(c)||mr(i,c)||(qi(s)||(12&s.childFlags?Br(s.children):2===s.childFlags&&qr(s.children),s.children=null,s.childFlags=1),i.innerHTML=c));break;default:"o"===e[0]&&"n"===e[1]?function(e,t,n){var i=e.toLowerCase();if(Oi(t)||Ti(t)){var r=n[i];r&&r.wrapped||(n[i]=t)}else{var o=t.event;o&&Oi(o)?n[i]=function(e,t){return function(n){e(t.data,n)}}(o,t):Li('an event on a VNode "'+e+'". was not a function or a valid linkEvent.')}}(e,n,i):Ti(n)?i.removeAttribute(e):"style"===e?function(e,t,n){var i,r,o=n.style;if(Ni(t))o.cssText=t;else if(Ti(e)||Ni(e))for(i in t)r=t[i],o[i]=Pi(r)?Ir(i,r):r;else{for(i in t)(r=t[i])!==e[i]&&(o[i]=Pi(r)?Ir(i,r):r);for(i in e)Ti(t[i])&&(o[i]="")}}(t,n,i):r&&rr[e]?i.setAttributeNS(rr[e],e,n):i.setAttribute(e,n)}}function Fr(e,t,n,i,r){var o=!1,s=(448&t)>0;for(var a in s&&(o=Nr(n))&&Or(t,i,n),n)jr(a,null,n[a],i,r,o,null);s&&Dr(t,e,i,n,!0,o)}function Vr(e,t,n,i){var r=new t(n,i);if(e.children=r,r.$V=e,r.$BS=!1,r.context=i,r.props===or&&(r.props=n),r.$UN=!1,Oi(r.componentWillMount)){if(r.$BR=!0,r.componentWillMount(),r.$PSS){var o=r.state,s=r.$PS;if(qi(o))r.state=s;else for(var a in s)o[a]=s[a];r.$PSS=!1,r.$PS=null}r.$BR=!1}Oi(er.beforeRender)&&er.beforeRender(r);var l,c=$r(r.render(n,r.state,i),e);return Oi(r.getChildContext)&&(l=r.getChildContext()),Ti(l)?r.$CX=i:r.$CX=ji(i,l),Oi(er.afterRender)&&er.afterRender(r),r.$LI=c,r}function $r(e,t){return Ai(e)&&Li("a valid Inferno VNode (or null) must be returned from a component render. You may have returned an array or an invalid object."),Di(e)?e=Ji():Ri(e)?e=Ki(e,null):(e.dom&&(e=Yi(e)),14&e.flags&&(e.parentVNode=t)),e}function zr(e,t,n,i){var r=e.flags;return 481&r?Wr(e,t,n,i):14&r?function(e,t,n,i,r){var o,s=e.type,a=e.props||or,l=e.ref;if(r){var c=Vr(e,s,a,n);e.dom=o=zr(c.$LI,null,c.$CX,i),Gr(e,l,c),c.$UPD=!1}else{var h=$r(s(a,n),e);e.children=h,e.dom=o=zr(h,null,n,i),Kr(a,l,o)}qi(t)||ar(t,o);return o}(e,t,n,i,(4&r)>0):512&r||16&r?Hr(e,t):1024&r?(zr(e.children,e.type,n,!1),e.dom=Hr(Ji(),t)):void Li("object"==typeof e?"mount() received an object that's not a valid VNode, you should stringify it first, fix createVNode flags or call normalizeChildren. Object: \""+JSON.stringify(e)+'".':'mount() expects a valid VNode, instead it received an object with the type "'+typeof e+'".')}function Hr(e,t){var n=e.dom=document.createTextNode(e.children);return qi(t)||ar(t,n),n}function Wr(e,t,n,i){var r=e.flags,o=e.children,s=e.props,a=e.className,l=e.ref,c=e.childFlags;i=i||(32&r)>0;var h=function(e,t){return t?document.createElementNS(ir,e):document.createElement(e)}(e.type,i);if(e.dom=h,Ti(a)||""===a||(i?h.setAttribute("class",a):h.className=a),zi(e),qi(t)||ar(t,h),!(1&c)){var u=!0===i&&"foreignObject"!==e.type;2===c?zr(o,h,n,u):12&c&&Ur(o,h,n,u)}return qi(s)||Fr(e,r,s,h,i),Ni(l)&&Li('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.'),Oi(l)&&Xr(h,l),h}function Ur(e,t,n,i){for(var r=0,o=e.length;r<o;r++){var s=e[r];qi(s.dom)||(e[r]=s=Yi(s)),zr(s,t,n,i)}}function Gr(e,t,n){Oi(t)?t(n):Ri(t)?Li('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.'):!Ti(t)&&"object"==typeof t&&4&e.flags&&Li("functional component lifecycle events are not supported on ES2015 class components."),Oi(n.componentDidMount)&&sr.push(function(e){return function(){e.$UPD=!0,e.componentDidMount(),e.$UPD=!1}}(n))}function Kr(e,t,n){Ti(t)||(Oi(t.onComponentWillMount)&&t.onComponentWillMount(e),Oi(t.onComponentDidMount)&&sr.push(function(e,t,n){return function(){return e.onComponentDidMount(t,n)}}(t,n,e)))}function Xr(e,t){sr.push((function(){return t(e)}))}function Yr(e,t,n,i){var r=e.children,o=e.props,s=e.className,a=e.flags,l=e.ref;if(i=i||(32&a)>0,1!==t.nodeType||t.tagName.toLowerCase()!==e.type){Ii("Inferno hydration: Server-side markup doesn't match client-side markup or Initial render target is not empty");var c=Wr(e,null,n,i);e.dom=c,cr(t.parentNode,c,t)}else{e.dom=t;var h=t.firstChild,u=e.childFlags;if(1&u)qi(t.firstChild)||function(e,t){return Boolean(t&&t.dangerouslySetInnerHTML&&t.dangerouslySetInnerHTML.__html&&mr(e,t.dangerouslySetInnerHTML.__html))}(t,o)||(t.textContent="",448&a&&(t.defaultValue=""));else{for(var d=null;h;)d=h.nextSibling,8===h.nodeType&&("!"===h.data?t.replaceChild(document.createTextNode(""),h):t.removeChild(h)),h=d;if(h=t.firstChild,2===u)qi(h)?zr(r,t,n,i):(d=h.nextSibling,Jr(r,h,n,i),h=d);else if(12&u)for(var p=0,f=r.length;p<f;p++){var g=r[p];qi(h)?zr(g,t,n,i):(d=h.nextSibling,Jr(g,h,n,i),h=d)}for(;h;)d=h.nextSibling,t.removeChild(h),h=d}qi(o)||Fr(e,a,o,t,i),Ti(s)?""!==t.className&&t.removeAttribute("class"):i?t.setAttribute("class",s):t.className=s,Oi(l)?Xr(t,l):Ni(l)&&Li('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.')}}function Jr(e,t,n,i){var r=e.flags;14&r?function(e,t,n,i,r){var o=e.type,s=e.ref,a=e.props||or;if(r){var l=Vr(e,o,a,n),c=l.$LI;Jr(c,t,l.$CX,i),e.dom=c.dom,Gr(e,s,l),l.$UPD=!1}else{var h=$r(o(a,n),e);Jr(h,t,n,i),e.children=h,e.dom=h.dom,Kr(a,s,t)}}(e,t,n,i,(4&r)>0):481&r?Yr(e,t,n,i):16&r?function(e,t){if(3!==t.nodeType){var n=Hr(e,null);e.dom=n,cr(t.parentNode,n,t)}else{var i=e.children;t.nodeValue!==i&&(t.nodeValue=i),e.dom=t}}(e,t):512&r?e.dom=t:(Li('hydrate() expects a valid VNode, instead it received an object with the type "'+typeof e+'".'),Li())}function Qr(e,t,n,i,r){qr(e),cr(n,zr(t,null,i,r),e.dom)}function Zr(e,t,n,i,r){var o=0|t.flags;e.flags!==o||2048&o?Qr(e,t,n,i,r):481&o?function(e,t,n,i,r,o){var s=t.type;if(e.type!==s)Qr(e,t,n,i,r);else{var a,l=e.dom,c=e.props,h=t.props,u=!1,d=!1;if(t.dom=l,r=r||(32&o)>0,c!==h){var p=c||or;if((a=h||or)!==or)for(var f in(u=(448&o)>0)&&(d=Nr(a)),a){var g=p[f],m=a[f];g!==m&&jr(f,g,m,l,r,d,e)}if(p!==or)for(var v in p)a.hasOwnProperty(v)||Ti(p[v])||jr(v,p[v],null,l,r,d,e)}var y=e.children,w=t.children,b=t.ref,x=e.className,_=t.className;zi(t),4096&o?function(e,t){e.textContent!==t.children&&(e.textContent=t.children)}(l,w):eo(e.childFlags,t.childFlags,y,w,l,i,r&&"foreignObject"!==s),u&&Dr(o,t,l,a,!1,d),x!==_&&(Ti(_)?l.removeAttribute("class"):r?l.setAttribute("class",_):l.className=_),Oi(b)&&e.ref!==b?Xr(l,b):Ni(b)&&Li('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.')}}(e,t,n,i,r,o):14&o?function(e,t,n,i,r,o){var s=t.type,a=e.key,l=t.key;if(e.type!==s||a!==l)Qr(e,t,n,i,r);else{var c=t.props||or;if(o){var h=e.children;h.$UPD=!0,h.$V=t,to(h,h.state,t,c,n,i,r,!1,!1),h.$UPD=!1}else{var u=!0,d=e.props,p=t.ref,f=!Ti(p),g=e.children;if(t.dom=e.dom,t.children=g,f&&Oi(p.onComponentShouldUpdate)&&(u=p.onComponentShouldUpdate(d,c)),!1!==u){f&&Oi(p.onComponentWillUpdate)&&p.onComponentWillUpdate(d,c);var m=s(c,i);m!==Ci&&(Zr(g,m=$r(m,t),n,i,r),t.children=m,t.dom=m.dom,f&&Oi(p.onComponentDidUpdate)&&p.onComponentDidUpdate(d,c))}else 14&g.flags&&(g.parentVNode=t)}}}(e,t,n,i,r,(4&o)>0):16&o?function(e,t){var n=t.children,i=e.dom;n!==e.children&&(i.nodeValue=n);t.dom=i}(e,t):512&o?t.dom=e.dom:function(e,t,n){var i=e.type,r=t.type,o=t.children;if(eo(e.childFlags,t.childFlags,e.children,o,i,n,!1),t.dom=e.dom,i!==r&&!Di(o)){var s=o.dom;i.removeChild(s),r.appendChild(s)}}(e,t,i)}function eo(e,t,n,i,r,o,s){switch(e){case 2:switch(t){case 2:Zr(n,i,r,o,s);break;case 1:Pr(n,r);break;default:Pr(n,r),Ur(i,r,o,s)}break;case 1:switch(t){case 2:zr(i,r,o,s);break;case 1:break;default:Ur(i,r,o,s)}break;default:if(12&t){var a=n.length,l=i.length;0===a?l>0&&Ur(i,r,o,s):0===l?Lr(r,n):8===t&&8===e?function(e,t,n,i,r,o,s){var a,l,c=o-1,h=s-1,u=0,d=e[u],p=t[u];e:{for(;d.key===p.key;){if(p.dom&&(t[u]=p=Yi(p)),Zr(d,p,n,i,r),e[u]=p,++u>c||u>h)break e;d=e[u],p=t[u]}for(d=e[c],p=t[h];d.key===p.key;){if(p.dom&&(t[h]=p=Yi(p)),Zr(d,p,n,i,r),e[c]=p,h--,u>--c||u>h)break e;d=e[c],p=t[h]}}if(u>c){if(u<=h)for(var f=(l=h+1)<s?t[l].dom:null;u<=h;)(p=t[u]).dom&&(t[u]=p=Yi(p)),u++,lr(n,zr(p,null,i,r),f)}else if(u>h)for(;u<=c;)Pr(e[u++],n);else{var g=u,m=u,v=c-u+1,y=h-u+1,w=[];for(a=0;a<y;a++)w.push(0);var b=v===o,x=!1,_=0,S=0;if(s<4||(v|y)<32)for(a=g;a<=c;a++)if(d=e[a],S<y){for(u=m;u<=h;u++)if(p=t[u],d.key===p.key){if(w[u-m]=a+1,b)for(b=!1;a>g;)Pr(e[g++],n);_>u?x=!0:_=u,p.dom&&(t[u]=p=Yi(p)),Zr(d,p,n,i,r),S++;break}!b&&u>h&&Pr(d,n)}else b||Pr(d,n);else{var k={};for(a=m;a<=h;a++)k[t[a].key]=a;for(a=g;a<=c;a++)if(d=e[a],S<y)if(void 0!==(u=k[d.key])){if(b)for(b=!1;a>g;)Pr(e[g++],n);p=t[u],w[u-m]=a+1,_>u?x=!0:_=u,p.dom&&(t[u]=p=Yi(p)),Zr(d,p,n,i,r),S++}else b||Pr(d,n);else b||Pr(d,n)}if(b)Lr(n,e),Ur(t,n,i,r);else if(x){var C=function(e){var t,n,i,r,o,s=e.slice(),a=[0],l=e.length;for(t=0;t<l;t++){var c=e[t];if(0!==c){if(e[n=a[a.length-1]]<c){s[t]=n,a.push(t);continue}for(i=0,r=a.length-1;i<r;)e[a[o=(i+r)/2|0]]<c?i=o+1:r=o;c<e[a[i]]&&(i>0&&(s[t]=a[i-1]),a[i]=t)}}i=a.length,r=a[i-1];for(;i-- >0;)a[i]=r,r=s[r];return a}(w);for(u=C.length-1,a=y-1;a>=0;a--)0===w[a]?((p=t[_=a+m]).dom&&(t[_]=p=Yi(p)),l=_+1,lr(n,zr(p,null,i,r),l<s?t[l].dom:null)):u<0||a!==C[u]?(l=(_=a+m)+1,lr(n,(p=t[_]).dom,l<s?t[l].dom:null)):u--}else if(S!==y)for(a=y-1;a>=0;a--)0===w[a]&&((p=t[_=a+m]).dom&&(t[_]=p=Yi(p)),l=_+1,lr(n,zr(p,null,i,r),l<s?t[l].dom:null))}}(n,i,r,o,s,a,l):function(e,t,n,i,r,o,s){for(var a,l,c=o>s?s:o,h=0;h<c;h++)a=t[h],l=e[h],a.dom&&(a=t[h]=Yi(a)),Zr(l,a,n,i,r),e[h]=a;if(o<s)for(h=c;h<s;h++)(a=t[h]).dom&&(a=t[h]=Yi(a)),zr(a,n,i,r);else if(o>s)for(h=c;h<o;h++)Pr(e[h],n)}(n,i,r,o,s,a,l)}else 1===t?Lr(r,n):2===t&&(Lr(r,n),zr(i,r,o,s))}}function to(e,t,n,i,r,o,s,a,l){var c,h=e.state,u=e.props;if(n.children=e,e.$UN)Ii("Inferno Error: Can only update a mounted or mounting component. This usually means you called setState() or forceUpdate() on an unmounted component. This is a no-op.");else{if(u!==i||i===or){if(!l&&Oi(e.componentWillReceiveProps)){if(e.$BR=!0,e.componentWillReceiveProps(i,o),e.$UN)return;e.$BR=!1}e.$PSS&&(t=ji(t,e.$PS),e.$PSS=!1,e.$PS=null)}var d=Boolean(e.shouldComponentUpdate);if(a||!d||d&&e.shouldComponentUpdate(i,t,o)){Oi(e.componentWillUpdate)&&(e.$BS=!0,e.componentWillUpdate(i,t,o),e.$BS=!1),e.props=i,e.state=t,e.context=o,Oi(er.beforeRender)&&er.beforeRender(e),c=e.render(i,t,o),Oi(er.afterRender)&&er.afterRender(e);var p,f=c!==Ci;if(Oi(e.getChildContext)&&(p=e.getChildContext()),p=Ti(p)?o:ji(o,p),e.$CX=p,f){var g=e.$LI,m=$r(c,n);Zr(g,m,r,p,s),e.$LI=m,Oi(e.componentDidUpdate)&&e.componentDidUpdate(u,h)}}else e.props=i,e.state=t,e.context=o;n.dom=e.$LI.dom}}Mi&&null===document.body&&Ii('Inferno warning: you cannot initialize inferno without "document.body". Wait on "DOMContentLoaded" event, add script to bottom of body, or use async/defer attributes on script tag.');var no=Mi?document.body:null;function io(e,t,n){if(no===t&&Li('you cannot render() to the "document.body". Use an empty element as a container instead.'),e!==Ci){var i=t.$V;return Ti(i)?Di(e)||(e.dom&&(e=Yi(e)),qi(t.firstChild)?(zr(e,t,or,!1),t.$V=e):function(e,t,n){var i=t.firstChild;if(!qi(i))for(Di(e)||Jr(e,i,or,!1),i=t.firstChild;i=i.nextSibling;)t.removeChild(i);sr.length>0&&hr(sr),t.$V=e,Oi(n)&&n()}(e,t),i=e):Ti(e)?(Pr(i,t),t.$V=null):(e.dom&&(e=Yi(e)),Zr(i,e,t,or,!1),i=t.$V=e),sr.length>0&&hr(sr),Oi(n)&&n(),Oi(er.renderComplete)&&er.renderComplete(i),i&&14&i.flags?i.children:void 0}}var ro="undefined"==typeof Promise?null:Promise.resolve(),oo="undefined"==typeof requestAnimationFrame?setTimeout:requestAnimationFrame.bind(window);function so(e,t,n,i){Oi(t)&&(t=t(e.state,e.props,e.context));var r,o=e.$PS;if(Ti(o))e.$PS=t;else for(var s in t)o[s]=t[s];if(e.$PSS||e.$BR)e.$PSS=!0,e.$BR&&Oi(n)&&sr.push(n.bind(e));else if(e.$UPD){var a=e.$QU;qi(a)&&(a=e.$QU=[],r=function(e,t){return function(){e.$QU=null,e.$UPD=!0,ao(e,!1,(function(){for(var n=0,i=t.length;n<i;n++)t[n].call(e)})),e.$UPD=!1}}(e,a),ro?ro.then(r):oo(r)),Oi(n)&&a.push(n)}else e.$PSS=!0,e.$UPD=!0,ao(e,i,n),e.$UPD=!1}function ao(e,t,n){if(!e.$UN){if(t||!e.$BR){e.$PSS=!1;var i=e.$PS,r=ji(e.state,i),o=e.props,s=e.context;e.$PS=null;var a=e.$V,l=e.$LI;if(to(e,r,a,o,l.dom&&l.dom.parentNode,s,(32&a.flags)>0,t,!0),e.$UN)return;if(!(1024&e.$LI.flags))for(var c=e.$LI.dom;!qi(a=a.parentVNode);)(14&a.flags)>0&&(a.dom=c);sr.length>0&&hr(sr)}else e.state=e.$PS,e.$PS=null;Oi(n)&&n.call(e)}}var lo=function(){function e(e,t){this.state=null,this.props=void 0,this.context=void 0,this.refs=void 0,this.$BR=!1,this.$BS=!0,this.$PSS=!1,this.$PS=null,this.$LI=null,this.$V=null,this.$UN=!1,this.$CX=null,this.$UPD=!0,this.$QU=null,this.props=e||or,this.context=t||or}var t=e.prototype;return t.forceUpdate=function(e){this.$UN||so(this,{},e,!0)},t.setState=function(e,t){this.$UN||(this.$BS?Li("cannot update state via setState() in componentWillUpdate() or constructor."):so(this,e,t,!1))},t.render=function(e,t,n){},e}();lo.defaultProps=void 0;var co=function(){};console.info("Inferno is in development mode."),-1===(co.name||co.toString()).indexOf("testFn")&&Ii("It looks like you're using a minified copy of the development build of Inferno. When deploying Inferno apps to production, make sure to use the production build which skips development warnings and is faster. See http://infernojs.org for more details.");var ho='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 14.02 5.57" width="53" height="21" style="vertical-align:middle"><path fill="#000000" d="M1.88.92v.14c0 .41-.13.68-.4.8.33.14.46.44.46.86v.33c0 .61-.33.95-.95.95H0V0h.95c.65 0 .93.3.93.92zM.63.57v1.06h.24c.24 0 .38-.1.38-.43V.98c0-.28-.1-.4-.32-.4zm0 1.63v1.22h.36c.2 0 .32-.1.32-.39v-.35c0-.37-.12-.48-.4-.48H.63zM4.18.99v.52c0 .64-.31.98-.94.98h-.3V4h-.62V0h.92c.63 0 .94.35.94.99zM2.94.57v1.35h.3c.2 0 .3-.09.3-.37v-.6c0-.29-.1-.38-.3-.38h-.3zm2.89 2.27L6.25 0h.88v4h-.6V1.12L6.1 3.99h-.6l-.46-2.82v2.82h-.55V0h.87zM8.14 1.1V4h-.56V0h.79L9 2.4V0h.56v4h-.64zm2.49 2.29v.6h-.6v-.6zM12.12 1c0-.63.33-1 .95-1 .61 0 .95.37.95 1v2.04c0 .64-.34 1-.95 1-.62 0-.95-.37-.95-1zm.62 2.08c0 .28.13.39.33.39s.32-.1.32-.4V.98c0-.29-.12-.4-.32-.4s-.33.11-.33.4z"/><path fill="#000000" d="M0 4.53h14.02v1.04H0zM11.08 0h.63v.62h-.63zm.63 4V1h-.63v2.98z"/></svg>';
H A Ddmn-modeler.production.min.js7 */var Ai=/,?([a-z]),?/gi,Pi=parseFloat,Di=Math,$i=Di.PI,ji=Di.min,Ii=Di.max,Bi=Di.pow,Li=Di.abs,Ni=/([a-z])[\s,]*((-?\d*\.?\d*(?:e[-+]?\d+)?[\s]*,?[\s]*)+)/gi,qi=/(-?\d*\.?\d*(?:e[-+]?\d+)?)[\s]*,?[\s]*/gi,Vi=Array.isArray||function(e){return e instanceof Array};function Fi(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function zi(e){if("function"==typeof e||Object(e)!==e)return e;var t=new e.constructor;for(var n in e)Fi(e,n)&&(t[n]=zi(e[n]));return t}function Qi(e){var t=Qi.ps=Qi.ps||{};return t[e]?t[e].sleep=100:t[e]={sleep:100},setTimeout((function(){for(var n in t)Fi(t,n)&&n!=e&&(t[n].sleep--,!t[n].sleep&&delete t[n])})),t[e]}function Hi(e,t,n,i){return 1===arguments.length&&(t=e.y,n=e.width,i=e.height,e=e.x),{x:e,y:t,width:n,height:i,x2:e+n,y2:t+i}}function Wi(){return this.join(",").replace(Ai,"$1")}function Ui(e){var t=zi(e);return t.toString=Wi,t}function Xi(e,t,n,i,o,r,s,a,l){var c=1-l,u=Bi(c,3),h=Bi(c,2),d=l*l*l,p=u*t+3*h*l*i+3*c*l*l*r+d*a;return{x:eo(u*e+3*h*l*n+3*c*l*l*o+d*s),y:eo(p)}}function Ki(e){var t=function(e,t,n,i,o,r,s,a){for(var l,c,u,h,d,p,f,g,m=[],v=[[],[]],y=0;y<2;++y)if(0==y?(c=6*e-12*n+6*o,l=-3*e+9*n-9*o+3*s,u=3*n-3*e):(c=6*t-12*i+6*r,l=-3*t+9*i-9*r+3*a,u=3*i-3*t),Li(l)<1e-12){if(Li(c)<1e-12)continue;0<(h=-u/c)&&h<1&&m.push(h)}else f=c*c-4*u*l,g=Di.sqrt(f),f<0||(0<(d=(-c+g)/(2*l))&&d<1&&m.push(d),0<(p=(-c-g)/(2*l))&&p<1&&m.push(p));var x,b=m.length,_=b;for(;b--;)x=1-(h=m[b]),v[0][b]=x*x*x*e+3*x*x*h*n+3*x*h*h*o+h*h*h*s,v[1][b]=x*x*x*t+3*x*x*h*i+3*x*h*h*r+h*h*h*a;return v[0][_]=e,v[1][_]=t,v[0][_+1]=s,v[1][_+1]=a,v[0].length=v[1].length=_+2,{x0:ji(...v[0]),y0:ji(...v[1]),x1:Ii(...v[0]),y1:Ii(...v[1])}}(...e);return Hi(t.x0,t.y0,t.x1-t.x0,t.y1-t.y0)}function Gi(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height}function Yi(e,t,n,i,o){return e*(e*(-3*t+9*n-9*i+3*o)+6*t-12*n+6*i)-3*t+3*n}function Zi(e,t,n,i,o,r,s,a,l){null==l&&(l=1);for(var c=(l=l>1?1:l<0?0:l)/2,u=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],h=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],d=0,p=0;p<12;p++){var f=c*u[p]+c,g=Yi(f,e,n,o,s),m=Yi(f,t,i,r,a),v=g*g+m*m;d+=h[p]*Di.sqrt(v)}return c*d}function Ji(e,t,n,i,o,r,s,a){if(!(Ii(e,n)<ji(o,s)||ji(e,n)>Ii(o,s)||Ii(t,i)<ji(r,a)||ji(t,i)>Ii(r,a))){var l=(e*i-t*n)*(r-a)-(t-i)*(o*a-r*s),c=(e-n)*(r-a)-(t-i)*(o-s);if(c){var u=eo(((e*i-t*n)*(o-s)-(e-n)*(o*a-r*s))/c),h=eo(l/c),d=+u.toFixed(2),p=+h.toFixed(2);if(!(d<+ji(e,n).toFixed(2)||d>+Ii(e,n).toFixed(2)||d<+ji(o,s).toFixed(2)||d>+Ii(o,s).toFixed(2)||p<+ji(t,i).toFixed(2)||p>+Ii(t,i).toFixed(2)||p<+ji(r,a).toFixed(2)||p>+Ii(r,a).toFixed(2)))return{x:u,y:h}}}}function eo(e){return Math.round(1e11*e)/1e11}function to(e,t,n){if(!function(e,t){return e=Hi(e),Gi(t=Hi(t),e.x,e.y)||Gi(t,e.x2,e.y)||Gi(t,e.x,e.y2)||Gi(t,e.x2,e.y2)||Gi(e,t.x,t.y)||Gi(e,t.x2,t.y)||Gi(e,t.x,t.y2)||Gi(e,t.x2,t.y2)||(e.x<t.x2&&e.x>t.x||t.x<e.x2&&t.x>e.x)&&(e.y<t.y2&&e.y>t.y||t.y<e.y2&&t.y>e.y)}(Ki(e),Ki(t)))return n?0:[];for(var i=Zi(...e),o=Zi(...t),r=oo(e)?1:~~(i/5)||1,s=oo(t)?1:~~(o/5)||1,a=[],l=[],c={},u=n?0:[],h=0;h<r+1;h++){var d=Xi(...e,h/r);a.push({x:d.x,y:d.y,t:h/r})}for(h=0;h<s+1;h++)d=Xi(...t,h/s),l.push({x:d.x,y:d.y,t:h/s});for(h=0;h<r;h++)for(var p=0;p<s;p++){var f,g=a[h],m=a[h+1],v=l[p],y=l[p+1],x=Li(m.x-g.x)<.01?"y":"x",b=Li(y.x-v.x)<.01?"y":"x",_=Ji(g.x,g.y,m.x,m.y,v.x,v.y,y.x,y.y);if(_){if(c[f=_.x.toFixed(9)+"#"+_.y.toFixed(9)])continue;c[f]=!0;var w=g.t+Li((_[x]-g[x])/(m[x]-g[x]))*(m.t-g.t),C=v.t+Li((_[b]-v[b])/(y[b]-v[b]))*(y.t-v.t);w>=0&&w<=1&&C>=0&&C<=1&&(n?u++:u.push({x:_.x,y:_.y,t1:w,t2:C}))}}return u}function no(e,t,n){e=lo(e),t=lo(t);for(var i,o,r,s,a,l,c,u,h,d,p=n?0:[],f=0,g=e.length;f<g;f++){var m=e[f];if("M"==m[0])i=a=m[1],o=l=m[2];else{"C"==m[0]?(i=(h=[i,o,...m.slice(1)])[6],o=h[7]):(h=[i,o,i,o,a,l,a,l],i=a,o=l);for(var v=0,y=t.length;v<y;v++){var x=t[v];if("M"==x[0])r=c=x[1],s=u=x[2];else{"C"==x[0]?(r=(d=[r,s,...x.slice(1)])[6],s=d[7]):(d=[r,s,r,s,c,u,c,u],r=c,s=u);var b=to(h,d,n);if(n)p+=b;else{for(var _=0,w=b.length;_<w;_++)b[_].segment1=f,b[_].segment2=v,b[_].bez1=h,b[_].bez2=d;p=p.concat(b)}}}}}return p}function io(e){var t=Qi(e);if(t.abs)return Ui(t.abs);if(Vi(e)&&Vi(e&&e[0])||(e=function(e){if(!e)return null;var t=Qi(e);if(t.arr)return zi(t.arr);var n={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},i=[];return Vi(e)&&Vi(e[0])&&(i=zi(e)),i.length||String(e).replace(Ni,(function(e,t,o){var r=[],s=t.toLowerCase();for(o.replace(qi,(function(e,t){t&&r.push(+t)})),"m"==s&&r.length>2&&(i.push([t,...r.splice(0,2)]),s="l",t="m"==t?"l":"L");r.length>=n[s]&&(i.push([t,...r.splice(0,n[s])]),n[s]););})),i.toString=Qi.toString,t.arr=zi(i),i}(e)),!e||!e.length)return[["M",0,0]];var n,i=[],o=0,r=0,s=0,a=0,l=0;"M"==e[0][0]&&(s=o=+e[0][1],a=r=+e[0][2],l++,i[0]=["M",o,r]);for(var c,u,h=l,d=e.length;h<d;h++){if(i.push(c=[]),(n=(u=e[h])[0])!=n.toUpperCase())switch(c[0]=n.toUpperCase(),c[0]){case"A":c[1]=u[1],c[2]=u[2],c[3]=u[3],c[4]=u[4],c[5]=u[5],c[6]=+u[6]+o,c[7]=+u[7]+r;break;case"V":c[1]=+u[1]+r;break;case"H":c[1]=+u[1]+o;break;case"M":s=+u[1]+o,a=+u[2]+r;default:for(var p=1,f=u.length;p<f;p++)c[p]=+u[p]+(p%2?o:r)}else for(var g=0,m=u.length;g<m;g++)c[g]=u[g];switch(n=n.toUpperCase(),c[0]){case"Z":o=+s,r=+a;break;case"H":o=c[1];break;case"V":r=c[1];break;case"M":s=c[c.length-2],a=c[c.length-1];default:o=c[c.length-2],r=c[c.length-1]}}return i.toString=Wi,t.abs=Ui(i),i}function oo(e){return e[0]===e[2]&&e[1]===e[3]&&e[4]===e[6]&&e[5]===e[7]}function ro(e,t,n,i){return[e,t,n,i,n,i]}function so(e,t,n,i,o,r){var s=1/3,a=2/3;return[s*e+a*n,s*t+a*i,s*o+a*n,s*r+a*i,o,r]}function ao(e,t,n,i,o,r,s,a,l,c){var u,h=120*$i/180,d=$i/180*(+o||0),p=[],f=function(e){return function t(){var n=Array.prototype.slice.call(arguments,0).join("␀"),i=t.cache=t.cache||{},o=t.count=t.count||[];return Fi(i,n)?(function(e,t){for(var n=0,i=e.length;n<i;n++)if(e[n]===t)return e.push(e.splice(n,1)[0])}(o,n),i[n]):(o.length>=1e3&&delete i[o.shift()],o.push(n),i[n]=e(...arguments),i[n])}}((function(e,t,n){return{x:e*Di.cos(n)-t*Di.sin(n),y:e*Di.sin(n)+t*Di.cos(n)}}));if(c)C=c[0],O=c[1],_=c[2],w=c[3];else{e=(u=f(e,t,-d)).x,t=u.y;var g=(e-(a=(u=f(a,l,-d)).x))/2,m=(t-(l=u.y))/2,v=g*g/(n*n)+m*m/(i*i);v>1&&(n*=v=Di.sqrt(v),i*=v);var y=n*n,x=i*i,b=(r==s?-1:1)*Di.sqrt(Li((y*x-y*m*m-x*g*g)/(y*m*m+x*g*g))),_=b*n*m/i+(e+a)/2,w=b*-i*g/n+(t+l)/2,C=Di.asin(((t-w)/i).toFixed(9)),O=Di.asin(((l-w)/i).toFixed(9));(C=e<_?$i-C:C)<0&&(C=2*$i+C),(O=a<_?$i-O:O)<0&&(O=2*$i+O),s&&C>O&&(C-=2*$i),!s&&O>C&&(O-=2*$i)}var k=O-C;if(Li(k)>h){var E=O,S=a,R=l;O=C+h*(s&&O>C?1:-1),p=ao(a=_+n*Di.cos(O),l=w+i*Di.sin(O),n,i,o,0,s,S,R,[O,E,_,w])}k=O-C;var T=Di.cos(C),M=Di.sin(C),A=Di.cos(O),P=Di.sin(O),D=Di.tan(k/4),$=4/3*n*D,j=4/3*i*D,I=[e,t],B=[e+$*M,t-j*T],L=[a+$*P,l-j*A],N=[a,l];if(B[0]=2*I[0]-B[0],B[1]=2*I[1]-B[1],c)return[B,L,N].concat(p);for(var q=[],V=0,F=(p=[B,L,N].concat(p).join().split(",")).length;V<F;V++)q[V]=V%2?f(p[V-1],p[V],d).y:f(p[V],p[V+1],d).x;return q}function lo(e){var t=Qi(e);if(t.curve)return Ui(t.curve);for(var n=io(e),i={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},o=function(e,t,n){var i,o;if(!e)return["C",t.x,t.y,t.x,t.y,t.x,t.y];switch(!(e[0]in{T:1,Q:1})&&(t.qx=t.qy=null),e[0]){case"M":t.X=e[1],t.Y=e[2];break;case"A":e=["C",...ao(t.x,t.y,...e.slice(1))];break;case"S":"C"==n||"S"==n?(i=2*t.x-t.bx,o=2*t.y-t.by):(i=t.x,o=t.y),e=["C",i,o,...e.slice(1)];break;case"T":"Q"==n||"T"==n?(t.qx=2*t.x-t.qx,t.qy=2*t.y-t.qy):(t.qx=t.x,t.qy=t.y),e=["C",...so(t.x,t.y,t.qx,t.qy,e[1],e[2])];break;case"Q":t.qx=e[1],t.qy=e[2],e=["C",...so(t.x,t.y,e[1],e[2],e[3],e[4])];break;case"L":e=["C",...ro(t.x,t.y,e[1],e[2])];break;case"H":e=["C",...ro(t.x,t.y,e[1],t.y)];break;case"V":e=["C",...ro(t.x,t.y,t.x,e[1])];break;case"Z":e=["C",...ro(t.x,t.y,t.X,t.Y)]}return e},r=function(e,t){if(e[t].length>7){e[t].shift();for(var i=e[t];i.length;)s[t]="A",e.splice(t++,0,["C",...i.splice(0,6)]);e.splice(t,1),u=n.length}},s=[],a="",l="",c=0,u=n.length;c<u;c++){n[c]&&(a=n[c][0]),"C"!=a&&(s[c]=a,c&&(l=s[c-1])),n[c]=o(n[c],i,l),"A"!=s[c]&&"C"==a&&(s[c]="C"),r(n,c);var h=n[c],d=h.length;i.x=h[d-2],i.y=h[d-1],i.bx=Pi(h[d-4])||i.x,i.by=Pi(h[d-3])||i.y}return t.curve=Ui(n),n}function co(e){return s(e)&&u(e,"waypoints")}function uo(e){return s(e)&&u(e,"labelTarget")}function ho(e){return{x:Math.round(e.x),y:Math.round(e.y)}}function po(e){return{top:e.y,right:e.x+(e.width||0),bottom:e.y+(e.height||0),left:e.x}}function fo(e){return{x:e.left,y:e.top,width:e.right-e.left,height:e.bottom-e.top}}function go(e){for(var t=e.waypoints,n=t.reduce((function(e,n,i){var o=t[i-1];if(o){var r=e[e.length-1],s=r&&r.endLength||0,a=function(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}(o,n);e.push({start:o,end:n,startLength:s,endLength:s+a,length:a})}return e}),[]),i=n.reduce((function(e,t){return e+t.length}),0),o=i/2,r=0,s=n[r];s.endLength<o;)s=n[++r];var a=(o-s.startLength)/s.length;return{x:s.start.x+(s.end.x-s.start.x)*a,y:s.start.y+(s.end.y-s.start.y)*a}}function mo(e){return co(e)?go(e):ho({x:(t=e).x+(t.width||0)/2,y:t.y+(t.height||0)/2});var t}function vo(e,t,n){s(n=n||0)||(n={x:n,y:n});var i=po(e),o=po(t),r=i.bottom+n.y<=o.top,a=i.left-n.x>=o.right,l=i.top-n.y>=o.bottom,c=r?"top":l?"bottom":null,u=i.right+n.x<=o.left?"left":a?"right":null;return u&&c?c+"-"+u:u||c||"intersect"}function yo(e,t,n){var i=function(e,t){return no(e,t)}(e,t);return 1===i.length||2===i.length&&ki(i[0],i[1])<1?ho(i[0]):i.length>1?(i=w(i,(function(e){var t=Math.floor(100*e.t2)||1;return t=((t=100-t)<10?"0":"")+t,e.segment2+"#"+t})),ho(i[n?0:i.length-1])):null}function xo(e,t){return Math.round(e*t)/t}function bo(e){return a(e)?e+"px":e}function _o(e,t,n){const i=Qn("g");Bn(i).add(t);const o=void 0!==n?n:e.childNodes.length-1;return e.insertBefore(i,e.childNodes[o]||null),i}const wo={shape:["x","y","width","height"],connection:["waypoints"]};function Co(e,t,n,i){this._eventBus=t,this._elementRegistry=i,this._graphicsFactory=n,this._rootsIdx=0,this._layers={},this._planes=[],this._rootElement=null,this._focused=!1,this._init(e||{})}function Oo(e,t){const n="matrix("+t.a+","+t.b+","+t.c+","+t.d+","+t.e+","+t.f+")";e.setAttribute("transform",n)}Co.$inject=["config.canvas","eventBus","graphicsFactory","elementRegistry"],Co.prototype._init=function(e){const t=this._eventBus,n=this._container=function(e){const t=(e=M({},{width:"100%",height:"100%"},e)).container||document.body,n=document.createElement("div");return n.setAttribute("class","djs-container djs-parent"),At(n,{position:"relative",overflow:"hidden",width:bo(e.width),height:bo(e.height)}),t.appendChild(n),n}(e),i=this._svg=Qn("svg");jn(i,{width:"100%",height:"100%"}),Pt(i,"tabindex",0),t.on("element.hover",(()=>{this.restoreFocus()})),i.addEventListener("focusin",(()=>{this._focused=!0,t.fire("canvas.focus.changed",{focused:!0})})),i.addEventListener("focusout",(()=>{this._focused=!1,t.fire("canvas.focus.changed",{focused:!1})})),An(n,i);const o=this._viewport=_o(i,"viewport");e.deferUpdate&&(this._viewboxChanged=R(T(this._viewboxChanged,this),300)),t.on("diagram.init",(()=>{t.fire("canvas.init",{svg:i,viewport:o})})),t.on(["shape.added","connection.added","shape.removed","connection.removed","elements.changed","root.set"],(()=>{delete this._cachedViewbox})),t.on("diagram.destroy",500,this._destroy,this),t.on("diagram.clear",500,this._clear,this)},Co.prototype._destroy=function(){this._eventBus.fire("canvas.destroy",{svg:this._svg,viewport:this._viewport});const e=this._container.parentNode;e&&e.removeChild(this._container),delete this._svg,delete this._container,delete this._layers,delete this._planes,delete this._rootElement,delete this._viewport},Co.prototype._clear=function(){this._elementRegistry.getAll().forEach((e=>{const t=vi(e);"root"===t?this.removeRootElement(e):this._removeElement(e,t)})),this._planes=[],this._rootElement=null,delete this._cachedViewbox},Co.prototype.focus=function(){this._svg.focus({preventScroll:!0})},Co.prototype.restoreFocus=function(){document.activeElement===document.body&&this.focus()},Co.prototype.isFocused=function(){return this._focused},Co.prototype.getDefaultLayer=function(){return this.getLayer("base",0)},Co.prototype.getLayer=function(e,t){if(!e)throw new Error("must specify a name");let n=this._layers[e];if(n||(n=this._layers[e]=this._createLayer(e,t)),void 0!==t&&n.index!==t)throw new Error("layer <"+e+"> already created at index <"+t+">");return n.group},Co.prototype._getChildIndex=function(e){return f(this._layers,(function(t,n){return n.visible&&e>=n.index&&t++,t}),0)},Co.prototype._createLayer=function(e,t){void 0===t&&(t=1);const n=this._getChildIndex(t);return{group:_o(this._viewport,"layer-"+e,n),index:t,visible:!0}},Co.prototype.showLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=this._viewport,i=t.group,o=t.index;if(t.visible)return i;const r=this._getChildIndex(o);return n.insertBefore(i,n.childNodes[r]||null),t.visible=!0,i},Co.prototype.hideLayer=function(e){if(!e)throw new Error("must specify a name");const t=this._layers[e];if(!t)throw new Error("layer <"+e+"> does not exist");const n=t.group;return t.visible?(ti(n),t.visible=!1,n):n},Co.prototype._removeLayer=function(e){const t=this._layers[e];t&&(delete this._layers[e],ti(t.group))},Co.prototype.getActiveLayer=function(){const e=this._findPlaneForRoot(this.getRootElement());return e?e.layer:null},Co.prototype.findRoot=function(e){if("string"==typeof e&&(e=this._elementRegistry.get(e)),!e)return;const t=this._findPlaneForRoot(function(e){for(;e.parent;)e=e.parent;return e}(e))||{};return t.rootElement},Co.prototype.getRootElements=function(){return this._planes.map((function(e){return e.rootElement}))},Co.prototype._findPlaneForRoot=function(e){return h(this._planes,(function(t){return t.rootElement===e}))},Co.prototype.getContainer=function(){return this._container},Co.prototype._updateMarker=function(e,t,n){let i;e.id||(e=this._elementRegistry.get(e)),e.markers=e.markers||new Set,i=this._elementRegistry._elements[e.id],i&&(p([i.gfx,i.secondaryGfx],(function(i){i&&(n?(e.markers.add(t),Bn(i).add(t)):(e.markers.delete(t),Bn(i).remove(t)))})),this._eventBus.fire("element.marker.update",{element:e,gfx:i.gfx,marker:t,add:!!n}))},Co.prototype.addMarker=function(e,t){this._updateMarker(e,t,!0)},Co.prototype.removeMarker=function(e,t){this._updateMarker(e,t,!1)},Co.prototype.hasMarker=function(e,t){return e.id||(e=this._elementRegistry.get(e)),!!e.markers&&e.markers.has(t)},Co.prototype.toggleMarker=function(e,t){this.hasMarker(e,t)?this.removeMarker(e,t):this.addMarker(e,t)},Co.prototype.getRootElement=function(){const e=this._rootElement;return e||this._planes.length?e:this.setRootElement(this.addRootElement(null))},Co.prototype.addRootElement=function(e){const t=this._rootsIdx++;e||(e={id:"__implicitroot_"+t,children:[],isImplicit:!0});const n=e.layer="root-"+t;this._ensureValid("root",e);const i=this.getLayer(n,0);return this.hideLayer(n),this._addRoot(e,i),this._planes.push({rootElement:e,layer:i}),e},Co.prototype.removeRootElement=function(e){"string"==typeof e&&(e=this._elementRegistry.get(e));if(this._findPlaneForRoot(e))return this._removeRoot(e),this._removeLayer(e.layer),this._planes=this._planes.filter((function(t){return t.rootElement!==e})),this._rootElement===e&&(this._rootElement=null),e},Co.prototype.setRootElement=function(e){if(e===this._rootElement)return e;let t;if(!e)throw new Error("rootElement required");return t=this._findPlaneForRoot(e),t||(e=this.addRootElement(e)),this._setRoot(e),e},Co.prototype._removeRoot=function(e){const t=this._elementRegistry,n=this._eventBus;n.fire("root.remove",{element:e}),n.fire("root.removed",{element:e}),t.remove(e)},Co.prototype._addRoot=function(e,t){const n=this._elementRegistry,i=this._eventBus;i.fire("root.add",{element:e}),n.add(e,t),i.fire("root.added",{element:e,gfx:t})},Co.prototype._setRoot=function(e,t){const n=this._rootElement;n&&(this._elementRegistry.updateGraphics(n,null,!0),this.hideLayer(n.layer)),e&&(t||(t=this._findPlaneForRoot(e).layer),this._elementRegistry.updateGraphics(e,this._svg,!0),this.showLayer(e.layer)),this._rootElement=e,this._eventBus.fire("root.set",{element:e})},Co.prototype._ensureValid=function(e,t){if(!t.id)throw new Error("element must have an id");if(this._elementRegistry.get(t.id))throw new Error("element <"+t.id+"> already exists");const n=wo[e],i=g(n,(function(e){return void 0!==t[e]}));if(!i)throw new Error("must supply { "+n.join(", ")+" } with "+e)},Co.prototype._setParent=function(e,t,n){Ci(t.children,e,n),e.parent=t},Co.prototype._addElement=function(e,t,n,i){n=n||this.getRootElement();const o=this._eventBus,r=this._graphicsFactory;this._ensureValid(e,t),o.fire(e+".add",{element:t,parent:n}),this._setParent(t,n,i);const s=r.create(e,t,i);return this._elementRegistry.add(t,s),r.update(e,t,s),o.fire(e+".added",{element:t,gfx:s}),t},Co.prototype.addShape=function(e,t,n){return this._addElement("shape",e,t,n)},Co.prototype.addConnection=function(e,t,n){return this._addElement("connection",e,t,n)},Co.prototype._removeElement=function(e,t){const n=this._elementRegistry,i=this._graphicsFactory,o=this._eventBus;if(e=n.get(e.id||e))return o.fire(t+".remove",{element:e}),i.remove(e),wi(e.parent&&e.parent.children,e),e.parent=null,o.fire(t+".removed",{element:e}),n.remove(e),e},Co.prototype.removeShape=function(e){return this._removeElement(e,"shape")},Co.prototype.removeConnection=function(e){return this._removeElement(e,"connection")},Co.prototype.getGraphics=function(e,t){return this._elementRegistry.getGraphics(e,t)},Co.prototype._changeViewbox=function(e){this._eventBus.fire("canvas.viewbox.changing"),e.apply(this),this._cachedViewbox=null,this._viewboxChanged()},Co.prototype._viewboxChanged=function(){this._eventBus.fire("canvas.viewbox.changed",{viewbox:this.viewbox()})},Co.prototype.viewbox=function(e){if(void 0===e&&this._cachedViewbox)return structuredClone(this._cachedViewbox);const t=this._viewport,n=this.getSize();let i,o,r,s,a,l,c;return e?(this._changeViewbox((function(){a=Math.min(n.width/e.width,n.height/e.height);const i=this._svg.createSVGMatrix().scale(a).translate(-e.x,-e.y);ii(t,i)})),e):(r=this._rootElement?this.getActiveLayer():null,i=r&&r.getBBox()||{},s=ii(t),o=s?s.matrix:function(e,t,n,i,o,r){var s=Wn().createSVGMatrix();switch(arguments.length){case 0:return s;case 1:return Un(s,e);case 6:return Un(s,{a:e,b:t,c:n,d:i,e:o,f:r})}}(),a=xo(o.a,1e3),l=xo(-o.e||0,1e3),c=xo(-o.f||0,1e3),e=this._cachedViewbox={x:l?l/a:0,y:c?c/a:0,width:n.width/a,height:n.height/a,scale:a,inner:{width:i.width||0,height:i.height||0,x:i.x||0,y:i.y||0},outer:n})},Co.prototype.scroll=function(e){const t=this._viewport;let n=t.getCTM();return e&&this._changeViewbox((function(){e=M({dx:0,dy:0},e||{}),n=this._svg.createSVGMatrix().translate(e.dx,e.dy).multiply(n),Oo(t,n)})),{x:n.e,y:n.f}},Co.prototype.scrollToElement=function(e,t){let n=100;"string"==typeof e&&(e=this._elementRegistry.get(e));const i=this.findRoot(e);if(i!==this.getRootElement()&&this.setRootElement(i),i===e)return;t||(t={}),"number"==typeof t&&(n=t),t={top:t.top||n,right:t.right||n,bottom:t.bottom||n,left:t.left||n};const o=mi(e),r=po(o),s=this.viewbox(),a=this.zoom();let l,c;s.y+=t.top/a,s.x+=t.left/a,s.width-=(t.right+t.left)/a,s.height-=(t.bottom+t.top)/a;const u=po(s);if(o.width<s.width&&o.height<s.height){const e=Math.max(0,r.right-u.right),t=Math.min(0,r.left-u.left),n=Math.max(0,r.bottom-u.bottom),i=Math.min(0,r.top-u.top);l=e||t,c=n||i}else l=o.x-s.x,c=o.y-s.y;this.scroll({dx:-l*a,dy:-c*a})},Co.prototype.zoom=function(e,t){if(!e)return this.viewbox(e).scale;if("fit-viewport"===e)return this._fitViewport(t);let n,i;return this._changeViewbox((function(){"object"!=typeof t&&(n=this.viewbox().outer,t={x:n.width/2,y:n.height/2}),i=this._setZoom(e,t)})),xo(i.a,1e3)},Co.prototype._fitViewport=function(e){const t=this.viewbox(),n=t.outer,i=t.inner;let o,r;return i.x>=0&&i.y>=0&&i.x+i.width<=n.width&&i.y+i.height<=n.height&&!e?r={x:0,y:0,width:Math.max(i.width+i.x,n.width),height:Math.max(i.height+i.y,n.height)}:(o=Math.min(1,n.width/i.width,n.height/i.height),r={x:i.x+(e?i.width/2-n.width/o/2:0),y:i.y+(e?i.height/2-n.height/o/2:0),width:n.width/o,height:n.height/o}),this.viewbox(r),this.viewbox(!1).scale},Co.prototype._setZoom=function(e,t){const n=this._svg,i=this._viewport,o=n.createSVGMatrix(),r=n.createSVGPoint();let s,a,l,c,u;l=i.getCTM();const h=l.a;return t?(s=M(r,t),a=s.matrixTransform(l.inverse()),c=o.translate(a.x,a.y).scale(1/h*e).translate(-a.x,-a.y),u=l.multiply(c)):u=o.scale(e),Oo(this._viewport,u),u},Co.prototype.getSize=function(){return{width:this._container.clientWidth,height:this._container.clientHeight}},Co.prototype.getAbsoluteBBox=function(e){const t=this.viewbox();let n;if(e.waypoints){n=this.getGraphics(e).getBBox()}else n=e;return{x:n.x*t.scale-t.x*t.scale,y:n.y*t.scale-t.y*t.scale,width:n.width*t.scale,height:n.height*t.scale}},Co.prototype.resized=function(){delete this._cachedViewbox,this._eventBus.fire("canvas.resized")};var ko="data-element-id";function Eo(e){this._elements={},this._eventBus=e}function So(e,t,n){var i=function(e,t,n,i){var o=n.inverse;return Object.defineProperty(e,"remove",{value:function(e){var n=this.indexOf(e);return-1!==n&&(this.splice(n,1),t.unset(e,o,i)),e}}),Object.defineProperty(e,"contains",{value:function(e){return-1!==this.indexOf(e)}}),Object.defineProperty(e,"add",{value:function(e,n){var r=this.indexOf(e);if(void 0===n){if(-1!==r)return;n=this.length}-1!==r&&this.splice(r,1),this.splice(n,0,e),-1===r&&t.set(e,o,i)}}),Object.defineProperty(e,"__refs_collection",{value:!0}),e}(n[t.name]||[],e,t,n);Object.defineProperty(n,t.name,{enumerable:t.enumerable,value:i}),i.length&&i.forEach((function(i){e.set(i,t.inverse,n)}))}function Ro(e,t){if(!(this instanceof Ro))return new Ro(e,t);e.inverse=t,t.inverse=e,this.props={},this.props[e.name]=e,this.props[t.name]=t}Eo.$inject=["eventBus"],Eo.prototype.add=function(e,t,n){var i=e.id;this._validateId(i),jn(t,ko,i),n&&jn(n,ko,i),this._elements[i]={element:e,gfx:t,secondaryGfx:n}},Eo.prototype.remove=function(e){var t=this._elements,n=e.id||e,i=n&&t[n];i&&(jn(i.gfx,ko,""),i.secondaryGfx&&jn(i.secondaryGfx,ko,""),delete t[n])},Eo.prototype.updateId=function(e,t){this._validateId(t),"string"==typeof e&&(e=this.get(e)),this._eventBus.fire("element.updateId",{element:e,newId:t});var n=this.getGraphics(e),i=this.getGraphics(e,!0);this.remove(e),e.id=t,this.add(e,n,i)},Eo.prototype.updateGraphics=function(e,t,n){var i=e.id||e,o=this._elements[i];return n?o.secondaryGfx=t:o.gfx=t,t&&jn(t,ko,i),t},Eo.prototype.get=function(e){var t;t="string"==typeof e?e:e&&jn(e,ko);var n=this._elements[t];return n&&n.element},Eo.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(n)})),t},Eo.prototype.find=function(e){for(var t=this._elements,n=Object.keys(t),i=0;i<n.length;i++){var o=t[n[i]],r=o.element;if(e(r,o.gfx))return r}},Eo.prototype.getAll=function(){return this.filter((function(e){return e}))},Eo.prototype.forEach=function(e){var t=this._elements;Object.keys(t).forEach((function(n){var i=t[n],o=i.element,r=i.gfx;return e(o,r)}))},Eo.prototype.getGraphics=function(e,t){var n=e.id||e,i=this._elements[n];return i&&(t?i.secondaryGfx:i.gfx)},Eo.prototype._validateId=function(e){if(!e)throw new Error("element must have an id");if(this._elements[e])throw new Error("element with id "+e+" already added")},Ro.prototype.bind=function(e,t){if("string"==typeof t){if(!this.props[t])throw new Error("no property <"+t+"> in ref");t=this.props[t]}t.collection?So(this,t,e):function(e,t,n){var i=t.inverse,o=n[t.name];Object.defineProperty(n,t.name,{configurable:t.configurable,enumerable:t.enumerable,get:function(){return o},set:function(t){if(t!==o){var r=o;o=null,r&&e.unset(r,i,n),o=t,e.set(o,i,n)}}})}(this,t,e)},Ro.prototype.ensureRefsCollection=function(e,t){var n=e[t.name];return function(e){return!0===e.__refs_collection}(n)||So(this,t,e),n},Ro.prototype.ensureBound=function(e,t){(function(e,t){return Object.prototype.hasOwnProperty.call(e,t.name||t)})(e,t)||this.bind(e,t)},Ro.prototype.unset=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).remove(n):e[t.name]=void 0)},Ro.prototype.set=function(e,t,n){e&&(this.ensureBound(e,t),t.collection?this.ensureRefsCollection(e,t).add(n):e[t.name]=n)};var To=new Ro({name:"children",enumerable:!0,collection:!0},{name:"parent"}),Mo=new Ro({name:"labels",enumerable:!0,collection:!0},{name:"labelTarget"}),Ao=new Ro({name:"attachers",collection:!0},{name:"host"}),Po=new Ro({name:"outgoing",collection:!0},{name:"source"}),Do=new Ro({name:"incoming",collection:!0},{name:"target"});function $o(){Object.defineProperty(this,"businessObject",{writable:!0}),Object.defineProperty(this,"label",{get:function(){return this.labels[0]},set:function(e){var t=this.label,n=this.labels;!e&&t?n.remove(t):n.add(e,0)}}),To.bind(this,"parent"),Mo.bind(this,"labels"),Po.bind(this,"outgoing"),Do.bind(this,"incoming")}function jo(){$o.call(this),To.bind(this,"children"),Ao.bind(this,"host"),Ao.bind(this,"attachers")}function Io(){$o.call(this),To.bind(this,"children")}function Bo(){jo.call(this),Mo.bind(this,"labelTarget")}function Lo(){$o.call(this),Po.bind(this,"source"),Do.bind(this,"target")}yn(jo,$o),yn(Io,jo),yn(Bo,jo),yn(Lo,$o);var No={connection:Lo,shape:jo,label:Bo,root:Io};function qo(){this._uid=12}function Vo(e){return e.childNodes[0]}function Fo(e,t,n){var i=Xn();i.setTranslate(t,n),ii(e,i)}function zo(e,t){this._eventBus=e,this._elementRegistry=t}function Qo(e,t,n){var i=n||t.firstChild;e!==i&&t.insertBefore(e,i)}qo.prototype.createRoot=function(e){return this.create("root",e)},qo.prototype.createLabel=function(e){return this.create("label",e)},qo.prototype.createShape=function(e){return this.create("shape",e)},qo.prototype.createConnection=function(e){return this.create("connection",e)},qo.prototype.create=function(e,t){return(t=M({},t||{})).id||(t.id=e+"_"+this._uid++),function(e,t){var n=No[e];if(!n)throw new Error("unknown type: <"+e+">");return M(new n,t)}(e,t)},zo.$inject=["eventBus","elementRegistry"],zo.prototype._getChildrenContainer=function(e){var t,n=this._elementRegistry.getGraphics(e);return e.parent?(t=function(e){return e.parentNode.childNodes[1]}(n),t||(Bn(t=Qn("g")).add("djs-children"),An(n.parentNode,t))):t=n,t},zo.prototype._clear=function(e){var t=Vo(e);return It(t),t},zo.prototype._createContainer=function(e,t,n,i){var o=Qn("g");Bn(o).add("djs-group"),void 0!==n?Qo(o,t,t.childNodes[n]):An(t,o);var r=Qn("g");Bn(r).add("djs-element"),Bn(r).add("djs-"+e),i&&Bn(r).add("djs-frame"),An(o,r);var s=Qn("g");return Bn(s).add("djs-visual"),An(r,s),r},zo.prototype.create=function(e,t,n){var i=this._getChildrenContainer(t.parent);return this._createContainer(e,i,n,yi(t))},zo.prototype.updateContainments=function(e){var t,n=this,i=this._elementRegistry;t=f(e,(function(e,t){return t.parent&&(e[t.parent.id]=t.parent),e}),{}),p(t,(function(e){var t=e.children;if(t){var o=n._getChildrenContainer(e);p(t.slice().reverse(),(function(e){Qo(i.getGraphics(e).parentNode,o)}))}}))},zo.prototype.drawShape=function(e,t,n={}){return this._eventBus.fire("render.shape",{gfx:e,element:t,attrs:n})},zo.prototype.getShapePath=function(e){return this._eventBus.fire("render.getShapePath",e)},zo.prototype.drawConnection=function(e,t,n={}){return this._eventBus.fire("render.connection",{gfx:e,element:t,attrs:n})},zo.prototype.getConnectionPath=function(e){return this._eventBus.fire("render.getConnectionPath",e)},zo.prototype.update=function(e,t,n){if(t.parent){var i=this._clear(n);if("shape"===e)this.drawShape(i,t),Fo(n,t.x,t.y);else{if("connection"!==e)throw new Error("unknown type: "+e);this.drawConnection(i,t)}t.hidden?jn(n,"display","none"):jn(n,"display","block")}},zo.prototype.remove=function(e){ti(this._elementRegistry.getGraphics(e).parentNode)};var Ho={__depends__:[_i],__init__:["canvas"],canvas:["type",Co],elementRegistry:["type",Eo],elementFactory:["type",qo],eventBus:["type",j],graphicsFactory:["type",zo]};function Wo(e){return function(e){var t=new Sn(e);return t.init(),t}([{config:["value",e=e||{}]},Ho].concat(e.modules||[]))}function Uo(e,t){this._injector=t||Wo(e),this.get("eventBus").fire("diagram.init")}Uo.prototype.get=function(e,t){return this._injector.get(e,t)},Uo.prototype.invoke=function(e,t,n){return this._injector.invoke(e,t,n)},Uo.prototype.destroy=function(){this.get("eventBus").fire("diagram.destroy")},Uo.prototype.clear=function(){this.get("eventBus").fire("diagram.clear")};var Xo=new Ro({name:"dmnElementRef",enumerable:!0},{name:"di",configurable:!0});function Ko(e,t){var n=[];function i(t){try{var n=t.di&&function(t){if(t.gfx)throw new Error("already rendered "+t.id);return e.element(t)}(t);return n}catch(e){s(e.message,{element:t,error:e})}}function o(e){var t,n;(n=(t=e).dmnElementRef)?n.di?s("multiple DI elements defined for element",{element:n}):(Xo.bind(n,"di"),n.di=t):s("no DMN element referenced in element",{element:t})}function r(e){n.push(e)}function s(t,n){e.error(t,n)}return{handleDefinitions:function(t,s){var a=t.dmnDI;if(!a)throw new Error("no dmndi:DMNDI");var l,c=a.diagrams||[];if(s&&-1===c.indexOf(s))throw new Error("diagram not part of dmndi:DMNDI");if(!s&&c&&c.length&&(s=c[0]),!s)throw new Error("no diagram to display");t.di=s,function(e){p(e.diagramElements,o)}(s),l=t,e.root(l),p(t.get("drgElement"),(function(e){i(e),function(e){p(["informationRequirement","knowledgeRequirement","authorityRequirement"],(function(t){p(e[t],(function(e){r((function(){i(e)}))}))}))}(e)})),function(e){p(e,(function(e){hn(e,"dmn:Association")?function(e){r((function(){i(e)}))}(e):i(e)}))}(t.get("artifact")),p(n,(function(e){e()}))}}}var Go="$NO_OP",Yo="a runtime error occured! Use Inferno in development environment to find the error.",Zo=!("undefined"==typeof window||!window.document),Jo=Array.isArray;function er(e){var t=typeof e;return"string"===t||"number"===t}function tr(e){return ar(e)||sr(e)}function nr(e){return sr(e)||!1===e||function(e){return!0===e}(e)||ar(e)}function ir(e){return"function"==typeof e}function or(e){return"string"==typeof e}function rr(e){return"number"==typeof e}function sr(e){return null===e}function ar(e){return void 0===e}function lr(e){throw e||(e=Yo),new Error("Inferno Error: "+e)}function cr(e){console.error(e)}function ur(e,t){var n={};if(e)for(var i in e)n[i]=e[i];if(t)for(var o in t)n[o]=t[o];return n}function hr(e){var t;if(Jo(e))t="Array("+(e.length>3?e.slice(0,3).toString()+",...":e.toString())+")";else if(er(e))t="Text("+e+")";else if(nr(e))t="InvalidVNode("+e+")";else{var n=e.flags;if(481&n)t="<"+e.type+(e.className?' class="'+e.className+'"':"")+">";else if(16&n)t="Text("+e.children+")";else if(1024&n)t="Portal*";else{var i=e.type;t="<"+(i.name||i.displayName||i.constructor.name||(i.toString().match(/^function\s*([^\s(]+)/)||[])[1])+" />"}}return">> "+t+"\n"}function dr(e,t){for(var n={},i=0,o=e.length;i<o;i++){var r=e[i];if(Jo(r))return"Encountered ARRAY in mount, array must be flattened, or normalize used. Location: \n"+hr(r);if(nr(r)){if(t)return"Encountered invalid node when preparing to keyed algorithm. Location: \n"+hr(r);if(0!==Object.keys(n).length)return"Encountered invalid node with mixed keys. Location: \n"+hr(r)}else{"object"==typeof r&&(r.isValidated=!0);var s=r.key;if(!tr(s)&&!er(s))return"Encountered child vNode where key property is not string or number. Location: \n"+hr(r);var a=r.children,l=r.childFlags;if(!nr(a)){var c=void 0;if(12&l?c=dr(a,8&r.childFlags):2===l&&(c=dr([a],8&r.childFlags)),c)return c+=hr(r)}if(t&&tr(s))return"Encountered child without key during keyed algorithm. If this error points to Array make sure children is flat list. Location: \n"+hr(r);if(t||!tr(s)){if(n[s])return"Encountered two children with same key: {"+s+"}. Location: \n"+hr(r);n[s]=!0}else if(0!==Object.keys(n).length)return"Encountered children with key missing. Location: \n"+hr(r)}}}function pr(e){if(!(1&e.childFlags)&&(64&e.flags&&lr("input elements can't have children."),128&e.flags&&lr("textarea elements can't have children."),481&e.flags)){var t=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],n=e.type.toLowerCase();"media"===n&&lr("media elements can't have children.");var i=t.indexOf(n);-1!==i&&lr(t[i]+" elements can't have children.")}}function fr(e){if(!1===e.isValidated&&e.children&&481&e.flags){var t=dr(Array.isArray(e.children)?e.children:[e.children],(8&e.childFlags)>0);t&&lr(t+hr(e))}e.isValidated=!0}var gr="$";function mr(e,t,n,i,o,r,s,a){return{childFlags:e,children:t,className:n,dom:null,flags:i,isValidated:!1,key:void 0===o?null:o,parentVNode:null,props:void 0===r?null:r,ref:void 0===s?null:s,type:a}}function vr(e,t,n,i,o,r,s,a){14&e&&lr("Creating Component vNodes using createVNode is not allowed. Use Inferno.createComponentVNode method.");var l=void 0===o?1:o,c=mr(l,i,n,e,s,r,a,t);return 0===l&&Or(c,c.children),pr(c),c}function yr(e,t,n,i,o){1&e&&lr("Creating element vNodes using createComponentVNode is not allowed. Use Inferno.createVNode method."),(2&e)>0&&(e=t.prototype&&ir(t.prototype.render)?4:8);var r=t.defaultProps;if(!tr(r))for(var s in n||(n={}),r)ar(n[s])&&(n[s]=r[s]);if((8&e)>0){var a=t.defaultHooks;if(!tr(a))if(o)for(var l in a)ar(o[l])&&(o[l]=a[l]);else o=a}var c=mr(1,null,null,e,i,n,o,t),u=kr.createVNode;return ir(u)&&u(c),c}function xr(e,t){return mr(1,tr(e)?"":e,null,16,t,null,null,null)}function br(e){var t=e.props;if(t){var n=e.flags;481&n&&(void 0!==t.children&&tr(e.children)&&Or(e,t.children),void 0!==t.className&&(e.className=t.className||null,t.className=void 0)),void 0!==t.key&&(e.key=t.key,t.key=void 0),void 0!==t.ref&&(e.ref=8&n?ur(e.ref,t.ref):t.ref,t.ref=void 0)}return e}function _r(e){var t,n=e.flags;if(14&n){var i,o=e.props;if(!sr(o))for(var r in i={},o)i[r]=o[r];t=yr(n,e.type,i,e.key,e.ref)}else 481&n?t=vr(n,e.type,e.className,e.children,e.childFlags,e.props,e.key,e.ref):16&n?t=xr(e.children,e.key):1024&n&&(t=e);return t}function wr(){return xr("",null)}function Cr(e,t,n,i){for(var o=e.length;n<o;n++){var r=e[n];if(!nr(r)){var s=i+gr+n;if(Jo(r))Cr(r,t,0,s);else{if(er(r))r=xr(r,s);else{var a=r.key,l=or(a)&&a[0]===gr;sr(r.dom)&&!l||(r=_r(r)),sr(a)||l?r.key=s:r.key=i+a}t.push(r)}}}}function Or(e,t){var n,i=1;if(nr(t))n=t;else if(or(t))i=2,n=xr(t);else if(rr(t))i=2,n=xr(t+"");else if(Jo(t)){var o=t.length;if(0===o)n=null,i=1;else{(Object.isFrozen(t)||!0===t.$)&&(t=t.slice()),i=8;for(var r=0;r<o;r++){var s=t[r];if(nr(s)||Jo(s)){n=n||t.slice(0,r),Cr(t,n,r,"");break}if(er(s))(n=n||t.slice(0,r)).push(xr(s,gr+r));else{var a=s.key,l=sr(s.dom),c=sr(a),u=!c&&or(a)&&a[0]===gr;!l||c||u?(n=n||t.slice(0,r),l&&!u||(s=_r(s)),(c||u)&&(s.key=gr+r),n.push(s)):n&&n.push(s)}}(n=n||t).$=!0}}else n=t,sr(t.dom)||(n=_r(t)),i=2;return e.children=n,e.childFlags=i,pr(e),e}var kr={afterRender:null,beforeRender:null,createVNode:null,renderComplete:null},Er="http://www.w3.org/1999/xlink",Sr="http://www.w3.org/XML/1998/namespace",Rr="http://www.w3.org/2000/svg",Tr={"xlink:actuate":Er,"xlink:arcrole":Er,"xlink:href":Er,"xlink:role":Er,"xlink:show":Er,"xlink:title":Er,"xlink:type":Er,"xml:base":Sr,"xml:lang":Sr,"xml:space":Sr},Mr={},Ar=[];function Pr(e,t){e.appendChild(t)}function Dr(e,t,n){tr(n)?Pr(e,t):e.insertBefore(t,n)}function $r(e,t,n){e.replaceChild(t,n)}function jr(e){for(var t;void 0!==(t=e.shift());)t()}Object.freeze(Mr);var Ir={},Br={};function Lr(e,t,n){var i=Ir[e],o=n.$EV;t?(i||(Br[e]=function(e){var t=function(t){var n=t.type,i="click"===n||"dblclick"===n;if(i&&0!==t.button)return t.stopPropagation(),!1;t.stopPropagation=qr;var o={dom:document};Object.defineProperty(t,"currentTarget",{configurable:!0,get:function(){return o.dom}}),function(e,t,n,i){var o=function(e){return ir(e.composedPath)?e.composedPath()[0]:e.target}(e);for(;!sr(o);){if(t&&o.disabled)return;var r=o.$EV;if(r){var s=r[n];if(s&&(i.dom=o,s.event?s.event(s.data,e):s(e),e.cancelBubble))return}o=o.parentNode}}(t,i,e,o)};return document.addEventListener(Nr(e),t),t}(e),Ir[e]=0),o||(o=n.$EV={}),o[e]||Ir[e]++,o[e]=t):o&&o[e]&&(Ir[e]--,1===i&&(document.removeEventListener(Nr(e),Br[e]),Br[e]=null),o[e]=t)}function Nr(e){return e.substr(2).toLowerCase()}function qr(){this.cancelBubble=!0,this.immediatePropagationStopped||this.stopImmediatePropagation()}function Vr(e,t){var n=document.createElement("i");return n.innerHTML=t,n.innerHTML===e.innerHTML}function Fr(e,t,n){if(e[t]){var i=e[t];i.event?i.event(i.data,n):i(n)}else{var o=t.toLowerCase();e[o]&&e[o](n)}}function zr(e,t){var n=function(n){n.stopPropagation();var i=this.$V;if(i){var o=i.props||Mr,r=i.dom;if(or(e))Fr(o,e,n);else for(var s=0;s<e.length;s++)Fr(o,e[s],n);if(ir(t)){var a=this.$V,l=a.props||Mr;t(l,r,!1,a)}}};return Object.defineProperty(n,"wrapped",{configurable:!1,enumerable:!1,value:!0,writable:!1}),n}function Qr(e){return"checkbox"===e||"radio"===e}var Hr=zr("onInput",Xr),Wr=zr(["onClick","onChange"],Xr);function Ur(e){e.stopPropagation()}function Xr(e,t){var n=e.type,i=e.value,o=e.checked,r=e.multiple,s=e.defaultValue,a=!tr(i);n&&n!==t.type&&t.setAttribute("type",n),tr(r)||r===t.multiple||(t.multiple=r),tr(s)||a||(t.defaultValue=s+""),Qr(n)?(a&&(t.value=i),tr(o)||(t.checked=o)):a&&t.value!==i?(t.defaultValue=i,t.value=i):tr(o)||(t.checked=o)}function Kr(e,t){if("optgroup"===e.type){var n=e.children,i=e.childFlags;if(12&i)for(var o=0,r=n.length;o<r;o++)Gr(n[o],t);else 2===i&&Gr(n,t)}else Gr(e,t)}function Gr(e,t){var n=e.props||Mr,i=e.dom;i.value=n.value,Jo(t)&&-1!==t.indexOf(n.value)||n.value===t?i.selected=!0:tr(t)&&tr(n.selected)||(i.selected=n.selected||!1)}Ur.wrapped=!0;var Yr=zr("onChange",Zr);function Zr(e,t,n,i){var o=Boolean(e.multiple);tr(e.multiple)||o===t.multiple||(t.multiple=o);var r=i.childFlags;if(!(1&r)){var s=i.children,a=e.value;if(n&&tr(a)&&(a=e.defaultValue),12&r)for(var l=0,c=s.length;l<c;l++)Kr(s[l],a);else 2===r&&Kr(s,a)}}var Jr=zr("onInput",ts),es=zr("onChange");function ts(e,t,n){var i=e.value,o=t.value;if(tr(i)){if(n){var r=e.defaultValue;tr(r)||r===o||(t.defaultValue=r,t.value=r)}}else o!==i&&(t.defaultValue=i,t.value=i)}function ns(e,t,n,i,o,r){64&e?Xr(i,n):256&e?Zr(i,n,o,t):128&e&&ts(i,n,o),r&&(n.$V=t)}function is(e,t,n){64&e?function(e,t){Qr(t.type)?(e.onchange=Wr,e.onclick=Ur):e.oninput=Hr}(t,n):256&e?function(e){e.onchange=Yr}(t):128&e&&function(e,t){e.oninput=Jr,t.onChange&&(e.onchange=es)}(t,n)}function os(e){return e.type&&Qr(e.type)?!tr(e.checked):!tr(e.value)}function rs(e,t){ss(e),t&&e.dom&&(!function(e,t){e.removeChild(t)}(t,e.dom),e.dom=null)}function ss(e){var t=e.flags;if(481&t){var n=e.ref,i=e.props;ir(n)&&n(null);var o=e.children,r=e.childFlags;if(12&r?as(o):2===r&&ss(o),!sr(i))for(var s in i)switch(s){case"onClick":case"onDblClick":case"onFocusIn":case"onFocusOut":case"onKeyDown":case"onKeyPress":case"onKeyUp":case"onMouseDown":case"onMouseMove":case"onMouseUp":case"onSubmit":case"onTouchEnd":case"onTouchMove":case"onTouchStart":Lr(s,null,e.dom)}}else{var a=e.children;if(a)if(14&t){var l=e.ref;4&t?(ir(a.componentWillUnmount)&&a.componentWillUnmount(),ir(l)&&l(null),a.$UN=!0,a.$LI&&ss(a.$LI)):(!tr(l)&&ir(l.onComponentWillUnmount)&&l.onComponentWillUnmount(e.dom,e.props||Mr),ss(a))}else 1024&t&&rs(a,e.type)}}function as(e){for(var t=0,n=e.length;t<n;t++)ss(e[t])}function ls(e,t){as(t),e.textContent=""}function cs(e,t){switch(e){case"animationIterationCount":case"borderImageOutset":case"borderImageSlice":case"borderImageWidth":case"boxFlex":case"boxFlexGroup":case"boxOrdinalGroup":case"columnCount":case"fillOpacity":case"flex":case"flexGrow":case"flexNegative":case"flexOrder":case"flexPositive":case"flexShrink":case"floodOpacity":case"fontWeight":case"gridColumn":case"gridRow":case"lineClamp":case"lineHeight":case"opacity":case"order":case"orphans":case"stopOpacity":case"strokeDasharray":case"strokeDashoffset":case"strokeMiterlimit":case"strokeOpacity":case"strokeWidth":case"tabSize":case"widows":case"zIndex":case"zoom":return t;default:return t+"px"}}function us(e,t,n,i,o,r,s){switch(e){case"onClick":case"onDblClick":case"onFocusIn":case"onFocusOut":case"onKeyDown":case"onKeyPress":case"onKeyUp":case"onMouseDown":case"onMouseMove":case"onMouseUp":case"onSubmit":case"onTouchEnd":case"onTouchMove":case"onTouchStart":Lr(e,n,i);break;case"children":case"childrenType":case"className":case"defaultValue":case"key":case"multiple":case"ref":break;case"autoFocus":i.autofocus=!!n;break;case"allowfullscreen":case"autoplay":case"capture":case"checked":case"controls":case"default":case"disabled":case"hidden":case"indeterminate":case"loop":case"muted":case"novalidate":case"open":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"selected":i[e]=!!n;break;case"defaultChecked":case"value":case"volume":if(r&&"value"===e)return;var a=tr(n)?"":n;i[e]!==a&&(i[e]=a);break;case"dangerouslySetInnerHTML":var l=t&&t.__html||"",c=n&&n.__html||"";l!==c&&(tr(c)||Vr(i,c)||(sr(s)||(12&s.childFlags?as(s.children):2===s.childFlags&&ss(s.children),s.children=null,s.childFlags=1),i.innerHTML=c));break;default:"o"===e[0]&&"n"===e[1]?function(e,t,n){var i=e.toLowerCase();if(ir(t)||tr(t)){var o=n[i];o&&o.wrapped||(n[i]=t)}else{var r=t.event;r&&ir(r)?n[i]=function(e,t){return function(n){e(t.data,n)}}(r,t):lr('an event on a VNode "'+e+'". was not a function or a valid linkEvent.')}}(e,n,i):tr(n)?i.removeAttribute(e):"style"===e?function(e,t,n){var i,o,r=n.style;if(or(t))r.cssText=t;else if(tr(e)||or(e))for(i in t)o=t[i],r[i]=rr(o)?cs(i,o):o;else{for(i in t)(o=t[i])!==e[i]&&(r[i]=rr(o)?cs(i,o):o);for(i in e)tr(t[i])&&(r[i]="")}}(t,n,i):o&&Tr[e]?i.setAttributeNS(Tr[e],e,n):i.setAttribute(e,n)}}function hs(e,t,n,i,o){var r=!1,s=(448&t)>0;for(var a in s&&(r=os(n))&&is(t,i,n),n)us(a,null,n[a],i,o,r,null);s&&ns(t,e,i,n,!0,r)}function ds(e,t,n,i){var o=new t(n,i);if(e.children=o,o.$V=e,o.$BS=!1,o.context=i,o.props===Mr&&(o.props=n),o.$UN=!1,ir(o.componentWillMount)){if(o.$BR=!0,o.componentWillMount(),o.$PSS){var r=o.state,s=o.$PS;if(sr(r))o.state=s;else for(var a in s)r[a]=s[a];o.$PSS=!1,o.$PS=null}o.$BR=!1}ir(kr.beforeRender)&&kr.beforeRender(o);var l,c=ps(o.render(n,o.state,i),e);return ir(o.getChildContext)&&(l=o.getChildContext()),tr(l)?o.$CX=i:o.$CX=ur(i,l),ir(kr.afterRender)&&kr.afterRender(o),o.$LI=c,o}function ps(e,t){return Jo(e)&&lr("a valid Inferno VNode (or null) must be returned from a component render. You may have returned an array or an invalid object."),nr(e)?e=wr():er(e)?e=xr(e,null):(e.dom&&(e=_r(e)),14&e.flags&&(e.parentVNode=t)),e}function fs(e,t,n,i){var o=e.flags;return 481&o?ms(e,t,n,i):14&o?function(e,t,n,i,o){var r,s=e.type,a=e.props||Mr,l=e.ref;if(o){var c=ds(e,s,a,n);e.dom=r=fs(c.$LI,null,c.$CX,i),ys(e,l,c),c.$UPD=!1}else{var u=ps(s(a,n),e);e.children=u,e.dom=r=fs(u,null,n,i),xs(a,l,r)}sr(t)||Pr(t,r);return r}(e,t,n,i,(4&o)>0):512&o||16&o?gs(e,t):1024&o?(fs(e.children,e.type,n,!1),e.dom=gs(wr(),t)):void lr("object"==typeof e?"mount() received an object that's not a valid VNode, you should stringify it first, fix createVNode flags or call normalizeChildren. Object: \""+JSON.stringify(e)+'".':'mount() expects a valid VNode, instead it received an object with the type "'+typeof e+'".')}function gs(e,t){var n=e.dom=document.createTextNode(e.children);return sr(t)||Pr(t,n),n}function ms(e,t,n,i){var o=e.flags,r=e.children,s=e.props,a=e.className,l=e.ref,c=e.childFlags;i=i||(32&o)>0;var u=function(e,t){return t?document.createElementNS(Rr,e):document.createElement(e)}(e.type,i);if(e.dom=u,tr(a)||""===a||(i?u.setAttribute("class",a):u.className=a),fr(e),sr(t)||Pr(t,u),!(1&c)){var h=!0===i&&"foreignObject"!==e.type;2===c?fs(r,u,n,h):12&c&&vs(r,u,n,h)}return sr(s)||hs(e,o,s,u,i),or(l)&&lr('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.'),ir(l)&&bs(u,l),u}function vs(e,t,n,i){for(var o=0,r=e.length;o<r;o++){var s=e[o];sr(s.dom)||(e[o]=s=_r(s)),fs(s,t,n,i)}}function ys(e,t,n){ir(t)?t(n):er(t)?lr('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.'):!tr(t)&&function(e){return"object"==typeof e}(t)&&4&e.flags&&lr("functional component lifecycle events are not supported on ES2015 class components."),ir(n.componentDidMount)&&Ar.push(function(e){return function(){e.$UPD=!0,e.componentDidMount(),e.$UPD=!1}}(n))}function xs(e,t,n){tr(t)||(ir(t.onComponentWillMount)&&t.onComponentWillMount(e),ir(t.onComponentDidMount)&&Ar.push(function(e,t,n){return function(){return e.onComponentDidMount(t,n)}}(t,n,e)))}function bs(e,t){Ar.push((function(){return t(e)}))}function _s(e,t,n,i){var o=e.children,r=e.props,s=e.className,a=e.flags,l=e.ref;if(i=i||(32&a)>0,1!==t.nodeType||t.tagName.toLowerCase()!==e.type){cr("Inferno hydration: Server-side markup doesn't match client-side markup or Initial render target is not empty");var c=ms(e,null,n,i);e.dom=c,$r(t.parentNode,c,t)}else{e.dom=t;var u=t.firstChild,h=e.childFlags;if(1&h)sr(t.firstChild)||function(e,t){return Boolean(t&&t.dangerouslySetInnerHTML&&t.dangerouslySetInnerHTML.__html&&Vr(e,t.dangerouslySetInnerHTML.__html))}(t,r)||(t.textContent="",448&a&&(t.defaultValue=""));else{for(var d=null;u;)d=u.nextSibling,8===u.nodeType&&("!"===u.data?t.replaceChild(document.createTextNode(""),u):t.removeChild(u)),u=d;if(u=t.firstChild,2===h)sr(u)?fs(o,t,n,i):(d=u.nextSibling,ws(o,u,n,i),u=d);else if(12&h)for(var p=0,f=o.length;p<f;p++){var g=o[p];sr(u)?fs(g,t,n,i):(d=u.nextSibling,ws(g,u,n,i),u=d)}for(;u;)d=u.nextSibling,t.removeChild(u),u=d}sr(r)||hs(e,a,r,t,i),tr(s)?""!==t.className&&t.removeAttribute("class"):i?t.setAttribute("class",s):t.className=s,ir(l)?bs(t,l):or(l)&&lr('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.')}}function ws(e,t,n,i){var o=e.flags;14&o?function(e,t,n,i,o){var r=e.type,s=e.ref,a=e.props||Mr;if(o){var l=ds(e,r,a,n),c=l.$LI;ws(c,t,l.$CX,i),e.dom=c.dom,ys(e,s,l),l.$UPD=!1}else{var u=ps(r(a,n),e);ws(u,t,n,i),e.children=u,e.dom=u.dom,xs(a,s,t)}}(e,t,n,i,(4&o)>0):481&o?_s(e,t,n,i):16&o?function(e,t){if(3!==t.nodeType){var n=gs(e,null);e.dom=n,$r(t.parentNode,n,t)}else{var i=e.children;t.nodeValue!==i&&(t.nodeValue=i),e.dom=t}}(e,t):512&o?e.dom=t:(lr('hydrate() expects a valid VNode, instead it received an object with the type "'+typeof e+'".'),lr())}function Cs(e,t,n,i,o){ss(e),$r(n,fs(t,null,i,o),e.dom)}function Os(e,t,n,i,o){var r=0|t.flags;e.flags!==r||2048&r?Cs(e,t,n,i,o):481&r?function(e,t,n,i,o,r){var s=t.type;if(e.type!==s)Cs(e,t,n,i,o);else{var a,l=e.dom,c=e.props,u=t.props,h=!1,d=!1;if(t.dom=l,o=o||(32&r)>0,c!==u){var p=c||Mr;if((a=u||Mr)!==Mr)for(var f in(h=(448&r)>0)&&(d=os(a)),a){var g=p[f],m=a[f];g!==m&&us(f,g,m,l,o,d,e)}if(p!==Mr)for(var v in p)a.hasOwnProperty(v)||tr(p[v])||us(v,p[v],null,l,o,d,e)}var y=e.children,x=t.children,b=t.ref,_=e.className,w=t.className;fr(t),4096&r?function(e,t){e.textContent!==t.children&&(e.textContent=t.children)}(l,x):ks(e.childFlags,t.childFlags,y,x,l,i,o&&"foreignObject"!==s),h&&ns(r,t,l,a,!1,d),_!==w&&(tr(w)?l.removeAttribute("class"):o?l.setAttribute("class",w):l.className=w),ir(b)&&e.ref!==b?bs(l,b):or(b)&&lr('string "refs" are not supported in Inferno 1.0. Use callback "refs" instead.')}}(e,t,n,i,o,r):14&r?function(e,t,n,i,o,r){var s=t.type,a=e.key,l=t.key;if(e.type!==s||a!==l)Cs(e,t,n,i,o);else{var c=t.props||Mr;if(r){var u=e.children;u.$UPD=!0,u.$V=t,Es(u,u.state,t,c,n,i,o,!1,!1),u.$UPD=!1}else{var h=!0,d=e.props,p=t.ref,f=!tr(p),g=e.children;if(t.dom=e.dom,t.children=g,f&&ir(p.onComponentShouldUpdate)&&(h=p.onComponentShouldUpdate(d,c)),!1!==h){f&&ir(p.onComponentWillUpdate)&&p.onComponentWillUpdate(d,c);var m=s(c,i);m!==Go&&(Os(g,m=ps(m,t),n,i,o),t.children=m,t.dom=m.dom,f&&ir(p.onComponentDidUpdate)&&p.onComponentDidUpdate(d,c))}else 14&g.flags&&(g.parentVNode=t)}}}(e,t,n,i,o,(4&r)>0):16&r?function(e,t){var n=t.children,i=e.dom;n!==e.children&&(i.nodeValue=n);t.dom=i}(e,t):512&r?t.dom=e.dom:function(e,t,n){var i=e.type,o=t.type,r=t.children;if(ks(e.childFlags,t.childFlags,e.children,r,i,n,!1),t.dom=e.dom,i!==o&&!nr(r)){var s=r.dom;i.removeChild(s),o.appendChild(s)}}(e,t,i)}function ks(e,t,n,i,o,r,s){switch(e){case 2:switch(t){case 2:Os(n,i,o,r,s);break;case 1:rs(n,o);break;default:rs(n,o),vs(i,o,r,s)}break;case 1:switch(t){case 2:fs(i,o,r,s);break;case 1:break;default:vs(i,o,r,s)}break;default:if(12&t){var a=n.length,l=i.length;0===a?l>0&&vs(i,o,r,s):0===l?ls(o,n):8===t&&8===e?function(e,t,n,i,o,r,s){var a,l,c=r-1,u=s-1,h=0,d=e[h],p=t[h];e:{for(;d.key===p.key;){if(p.dom&&(t[h]=p=_r(p)),Os(d,p,n,i,o),e[h]=p,++h>c||h>u)break e;d=e[h],p=t[h]}for(d=e[c],p=t[u];d.key===p.key;){if(p.dom&&(t[u]=p=_r(p)),Os(d,p,n,i,o),e[c]=p,u--,h>--c||h>u)break e;d=e[c],p=t[u]}}if(h>c){if(h<=u)for(var f=(l=u+1)<s?t[l].dom:null;h<=u;)(p=t[h]).dom&&(t[h]=p=_r(p)),h++,Dr(n,fs(p,null,i,o),f)}else if(h>u)for(;h<=c;)rs(e[h++],n);else{var g=h,m=h,v=c-h+1,y=u-h+1,x=[];for(a=0;a<y;a++)x.push(0);var b=v===r,_=!1,w=0,C=0;if(s<4||(v|y)<32)for(a=g;a<=c;a++)if(d=e[a],C<y){for(h=m;h<=u;h++)if(p=t[h],d.key===p.key){if(x[h-m]=a+1,b)for(b=!1;a>g;)rs(e[g++],n);w>h?_=!0:w=h,p.dom&&(t[h]=p=_r(p)),Os(d,p,n,i,o),C++;break}!b&&h>u&&rs(d,n)}else b||rs(d,n);else{var O={};for(a=m;a<=u;a++)O[t[a].key]=a;for(a=g;a<=c;a++)if(d=e[a],C<y)if(void 0!==(h=O[d.key])){if(b)for(b=!1;a>g;)rs(e[g++],n);p=t[h],x[h-m]=a+1,w>h?_=!0:w=h,p.dom&&(t[h]=p=_r(p)),Os(d,p,n,i,o),C++}else b||rs(d,n);else b||rs(d,n)}if(b)ls(n,e),vs(t,n,i,o);else if(_){var k=function(e){var t,n,i,o,r,s=e.slice(),a=[0],l=e.length;for(t=0;t<l;t++){var c=e[t];if(0!==c){if(e[n=a[a.length-1]]<c){s[t]=n,a.push(t);continue}for(i=0,o=a.length-1;i<o;)e[a[r=(i+o)/2|0]]<c?i=r+1:o=r;c<e[a[i]]&&(i>0&&(s[t]=a[i-1]),a[i]=t)}}i=a.length,o=a[i-1];for(;i-- >0;)a[i]=o,o=s[o];return a}(x);for(h=k.length-1,a=y-1;a>=0;a--)0===x[a]?((p=t[w=a+m]).dom&&(t[w]=p=_r(p)),l=w+1,Dr(n,fs(p,null,i,o),l<s?t[l].dom:null)):h<0||a!==k[h]?(l=(w=a+m)+1,Dr(n,(p=t[w]).dom,l<s?t[l].dom:null)):h--}else if(C!==y)for(a=y-1;a>=0;a--)0===x[a]&&((p=t[w=a+m]).dom&&(t[w]=p=_r(p)),l=w+1,Dr(n,fs(p,null,i,o),l<s?t[l].dom:null))}}(n,i,o,r,s,a,l):function(e,t,n,i,o,r,s){for(var a,l,c=r>s?s:r,u=0;u<c;u++)a=t[u],l=e[u],a.dom&&(a=t[u]=_r(a)),Os(l,a,n,i,o),e[u]=a;if(r<s)for(u=c;u<s;u++)(a=t[u]).dom&&(a=t[u]=_r(a)),fs(a,n,i,o);else if(r>s)for(u=c;u<r;u++)rs(e[u],n)}(n,i,o,r,s,a,l)}else 1===t?ls(o,n):2===t&&(ls(o,n),fs(i,o,r,s))}}function Es(e,t,n,i,o,r,s,a,l){var c,u=e.state,h=e.props;if(n.children=e,e.$UN)cr("Inferno Error: Can only update a mounted or mounting component. This usually means you called setState() or forceUpdate() on an unmounted component. This is a no-op.");else{if(h!==i||i===Mr){if(!l&&ir(e.componentWillReceiveProps)){if(e.$BR=!0,e.componentWillReceiveProps(i,r),e.$UN)return;e.$BR=!1}e.$PSS&&(t=ur(t,e.$PS),e.$PSS=!1,e.$PS=null)}var d=Boolean(e.shouldComponentUpdate);if(a||!d||d&&e.shouldComponentUpdate(i,t,r)){ir(e.componentWillUpdate)&&(e.$BS=!0,e.componentWillUpdate(i,t,r),e.$BS=!1),e.props=i,e.state=t,e.context=r,ir(kr.beforeRender)&&kr.beforeRender(e),c=e.render(i,t,r),ir(kr.afterRender)&&kr.afterRender(e);var p,f=c!==Go;if(ir(e.getChildContext)&&(p=e.getChildContext()),p=tr(p)?r:ur(r,p),e.$CX=p,f){var g=e.$LI,m=ps(c,n);Os(g,m,o,p,s),e.$LI=m,ir(e.componentDidUpdate)&&e.componentDidUpdate(h,u)}}else e.props=i,e.state=t,e.context=r;n.dom=e.$LI.dom}}Zo&&null===document.body&&cr('Inferno warning: you cannot initialize inferno without "document.body". Wait on "DOMContentLoaded" event, add script to bottom of body, or use async/defer attributes on script tag.');var Ss=Zo?document.body:null;function Rs(e,t,n){if(Ss===t&&lr('you cannot render() to the "document.body". Use an empty element as a container instead.'),e!==Go){var i=t.$V;return tr(i)?nr(e)||(e.dom&&(e=_r(e)),sr(t.firstChild)?(fs(e,t,Mr,!1),t.$V=e):function(e,t,n){var i=t.firstChild;if(!sr(i))for(nr(e)||ws(e,i,Mr,!1),i=t.firstChild;i=i.nextSibling;)t.removeChild(i);Ar.length>0&&jr(Ar),t.$V=e,ir(n)&&n()}(e,t),i=e):tr(e)?(rs(i,t),t.$V=null):(e.dom&&(e=_r(e)),Os(i,e,t,Mr,!1),i=t.$V=e),Ar.length>0&&jr(Ar),ir(n)&&n(),ir(kr.renderComplete)&&kr.renderComplete(i),i&&14&i.flags?i.children:void 0}}var Ts="undefined"==typeof Promise?null:Promise.resolve(),Ms="undefined"==typeof requestAnimationFrame?setTimeout:requestAnimationFrame.bind(window);function As(e,t,n,i){ir(t)&&(t=t(e.state,e.props,e.context));var o,r=e.$PS;if(tr(r))e.$PS=t;else for(var s in t)r[s]=t[s];if(e.$PSS||e.$BR)e.$PSS=!0,e.$BR&&ir(n)&&Ar.push(n.bind(e));else if(e.$UPD){var a=e.$QU;sr(a)&&(a=e.$QU=[],o=function(e,t){return function(){e.$QU=null,e.$UPD=!0,Ps(e,!1,(function(){for(var n=0,i=t.length;n<i;n++)t[n].call(e)})),e.$UPD=!1}}(e,a),Ts?Ts.then(o):Ms(o)),ir(n)&&a.push(n)}else e.$PSS=!0,e.$UPD=!0,Ps(e,i,n),e.$UPD=!1}function Ps(e,t,n){if(!e.$UN){if(t||!e.$BR){e.$PSS=!1;var i=e.$PS,o=ur(e.state,i),r=e.props,s=e.context;e.$PS=null;var a=e.$V,l=e.$LI;if(Es(e,o,a,r,l.dom&&l.dom.parentNode,s,(32&a.flags)>0,t,!0),e.$UN)return;if(!(1024&e.$LI.flags))for(var c=e.$LI.dom;!sr(a=a.parentVNode);)(14&a.flags)>0&&(a.dom=c);Ar.length>0&&jr(Ar)}else e.state=e.$PS,e.$PS=null;ir(n)&&n.call(e)}}var Ds=function(){function e(e,t){this.state=null,this.props=void 0,this.context=void 0,this.refs=void 0,this.$BR=!1,this.$BS=!0,this.$PSS=!1,this.$PS=null,this.$LI=null,this.$V=null,this.$UN=!1,this.$CX=null,this.$UPD=!0,this.$QU=null,this.props=e||Mr,this.context=t||Mr}var t=e.prototype;return t.forceUpdate=function(e){this.$UN||As(this,{},e,!0)},t.setState=function(e,t){this.$UN||(this.$BS?lr("cannot update state via setState() in componentWillUpdate() or constructor."):As(this,e,t,!1))},t.render=function(e,t,n){},e}();Ds.defaultProps=void 0;var $s=function(){};console.info("Inferno is in development mode."),-1===($s.name||$s.toString()).indexOf("testFn")&&cr("It looks like you're using a minified copy of the development build of Inferno. When deploying Inferno apps to production, make sure to use the production build which skips development warnings and is faster. See http://infernojs.org for more details.");var js='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 14.02 5.57" width="53" height="21" style="vertical-align:middle"><path fill="#000000" d="M1.88.92v.14c0 .41-.13.68-.4.8.33.14.46.44.46.86v.33c0 .61-.33.95-.95.95H0V0h.95c.65 0 .93.3.93.92zM.63.57v1.06h.24c.24 0 .38-.1.38-.43V.98c0-.28-.1-.4-.32-.4zm0 1.63v1.22h.36c.2 0 .32-.1.32-.39v-.35c0-.37-.12-.48-.4-.48H.63zM4.18.99v.52c0 .64-.31.98-.94.98h-.3V4h-.62V0h.92c.63 0 .94.35.94.99zM2.94.57v1.35h.3c.2 0 .3-.09.3-.37v-.6c0-.29-.1-.38-.3-.38h-.3zm2.89 2.27L6.25 0h.88v4h-.6V1.12L6.1 3.99h-.6l-.46-2.82v2.82h-.55V0h.87zM8.14 1.1V4h-.56V0h.79L9 2.4V0h.56v4h-.64zm2.49 2.29v.6h-.6v-.6zM12.12 1c0-.63.33-1 .95-1 .61 0 .95.37.95 1v2.04c0 .64-.34 1-.95 1-.62 0-.95-.37-.95-1zm.62 2.08c0 .28.13.39.33.39s.32-.1.32-.4V.98c0-.29-.12-.4-.32-.4s-.33.11-.33.4z"/><path fill="#000000" d="M0 4.53h14.02v1.04H0zM11.08 0h.63v.62h-.63zm.63 4V1h-.63v2.98z"/></svg>';
2 !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis: global() function
/plugin/fblogin/lib/
H A Dfb_ca_chain_bundle.crt2941 WDYcPQuBDRIrRhCA/ec8J9B6yKm2fnQwM6M6int0wHl5QpNt/7EpFIKrIYwvF/k/Ji/1WcbvgAa3
/plugin/html5video2/script/
H A Dvideo.min.js20Ji(e){var t;return e=Array.isArray(e)?(t=[],e.forEach(function(e){e=Ji(e),Array.isArray(e)?t=t.con… function
/plugin/c3chart/assets/
H A Dd3.min.js2Ji,m:Vi,M:Gi,p:function(t,n,e){var r=h.exec(n.slice(e));return r?(t.p=p[r[0].toLowerCase()],e+r[0]… function
/plugin/amcharts/assets/amcharts/plugins/export/libs/pdfmake/
H A Dpdfmake.min.js8Ji(t,e,n){n&&xn(t,e,n)&&(e=n=null);var r=null==t,i=null==e;if(null==n&&(i&&"boolean"==typeof t?(n=…
/plugin/datatables/assets/pdfmake/build/
H A Dpdfmake.min.js
/plugin/jplayer/vendor/happyworm/jplayer/lib/aurora/
H A Dvorbis.js10 …f=f|0;g=g|0;h=h|0;return fa(10,a|0,b|0,c|0,d|0,e|0,f|0,g|0,h|0)|0}function Ji(a,b,c,d,e,f,g,h){a=a… function
16 …a=[tl,tl,yi,tl,zi,tl,Ai,tl,Bi,tl,Ci,tl,Di,tl,Ei,tl,Fi,tl,Gi,tl,Hi,tl,Ii,tl,Ji,tl,Ki,tl,Li,tl,Mi,tl…
/plugin/dirtylittlehelper/script/
H A Dmermaid.min.js1Ji,ta)},map:function(t){return a(t,0,ea,na)},entries:function(t){return function t(n,a){if(++a>r.l… function

12